Piranha CMS Want to extend the Users with new Data?

Viewed 237

I wanted to Customize the Manager Area, specific the User. I added a new Column(PhoneNumber) in the Database and the Data of this field gets in the UserEditModel. I added an new text field in the Edit.cshtml.

<div class="col-sm-6">
    <div class="form-group">
        <label>@Localizer.General["Email address"]</label>
        <input type="email" v-model="userModel.user.email" class="form-control small" maxlength="128" required />
        <div class="invalid-feedback">
            @Localizer.General["Email address is mandatory."]
        </div>
    </div>
</div>
<div class="col-sm-6">
    <div class="form-group">
        <label>@Localizer.General["PhoneNumber"]</label>
        <input v-model="userModel.user.PhoneNumber" class="form-control maxlength="128" required />
        <div class="invalid-feedback">
            @Localizer.General["PhoneNumber is mandatory."]
        </div>
    </div>
</div>

In the Model the PhoneNumber is filled with the Data from the Database, but the Phonenumber Field doesnt get the Data from the Model. Do i need to declare the Field somewhere? Do i need to change something in the piranha.useredit.js? I hope somebody can help me.

2 Answers
Related