You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
1.3 KiB
58 lines
1.3 KiB
|
|
module.exports = function (pCtx, coll) {
|
|
|
|
coll.formCreate = [
|
|
{
|
|
size: '',
|
|
list: [
|
|
{
|
|
field: 'username',
|
|
label: 'Nom d\'utilisateur',
|
|
type: 'text',
|
|
rules: {required: 'Nom manquant', regex: '[a-zA-Z0-9_-];i;Le nom doit respecter le format [a-zA-Z0-9]'}
|
|
},
|
|
{ field: 'email', label: 'Courriel', type: 'text', rules: {required: 'Courriel manquant'} }
|
|
]
|
|
}
|
|
]
|
|
|
|
coll.form = [
|
|
{
|
|
label: 'General',
|
|
field: '',
|
|
form: [
|
|
{
|
|
size: '',
|
|
list: [
|
|
{ field: 'username', label: 'Nom d\'utilisateur', type: 'text' },
|
|
{ field: 'email', label: 'Courriel', type: 'text' }
|
|
]
|
|
},
|
|
{
|
|
size: '',
|
|
list: [
|
|
{ field: 'avatar', label: 'Avatar', type: 'media' }
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
label: 'Details',
|
|
field: 'details',
|
|
form: [
|
|
{
|
|
size: '',
|
|
list: [
|
|
{ field: 'firstname', label: 'Prénom', type: 'text' },
|
|
{ field: 'lastname', label: 'Nom', type: 'text' }
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
|
|
coll.listingHeader = [
|
|
{ text: 'Username', align: 'left', value: 'username' },
|
|
{ text: 'Courriel', align: 'center', value: 'email' }
|
|
]
|
|
}
|