E2e fixes
gitea/salix/pipeline/head There was a failure building this commit Details

This commit is contained in:
Joan Sanchez 2023-04-18 11:33:36 +02:00
parent fded7d062b
commit a0d8ed1433
5 changed files with 19 additions and 22 deletions

View File

@ -3,10 +3,17 @@ INSERT INTO `salix`.`ACL` (model, property, accessType, permission, principalTyp
('VnUser', '*', '*', 'ALLOW', 'ROLE', 'employee'), ('VnUser', '*', '*', 'ALLOW', 'ROLE', 'employee'),
('VnUser','acl','READ','ALLOW','ROLE','account'), ('VnUser','acl','READ','ALLOW','ROLE','account'),
('VnUser','getCurrentUserData','READ','ALLOW','ROLE','account'), ('VnUser','getCurrentUserData','READ','ALLOW','ROLE','account'),
('VnUser','changePassword', 'WRITE', 'ALLOW', 'ROLE', 'account'); ('VnUser','changePassword', 'WRITE', 'ALLOW', 'ROLE', 'account'),
('Account','exists','READ','ALLOW','ROLE','account');
INSERT INTO `salix`.`ACL` (model, property, accessType, permission, principalType, principalId)
VALUES
('Account','exists','READ','ALLOW','ROLE','account');
DELETE FROM `salix`.`ACL` WHERE (model, property) = ('Account', 'acl'); DELETE FROM `salix`.`ACL` WHERE (model, property) = ('Account', 'acl');
DELETE FROM `salix`.`ACL` WHERE (model, property) = ('Account', 'getCurrentUserData'); DELETE FROM `salix`.`ACL` WHERE (model, property) = ('Account', 'getCurrentUserData');
DELETE FROM `salix`.`ACL` WHERE (model, property) = ('Account', 'changePassword');
DELETE FROM `salix`.`ACL` WHERE model = 'UserAccount';
UPDATE `hedera`.`imageCollection` t UPDATE `hedera`.`imageCollection` t
SET t.model = 'VnUser' SET t.model = 'VnUser'

View File

@ -23,7 +23,7 @@ describe('Account ACL path', () => {
it('should create new acl', async() => { it('should create new acl', async() => {
await page.autocompleteSearch(selectors.accountAcl.role, 'sysadmin'); await page.autocompleteSearch(selectors.accountAcl.role, 'sysadmin');
await page.autocompleteSearch(selectors.accountAcl.model, 'UserAccount'); await page.autocompleteSearch(selectors.accountAcl.model, 'Account');
await page.autocompleteSearch(selectors.accountAcl.accessType, '*'); await page.autocompleteSearch(selectors.accountAcl.accessType, '*');
await page.autocompleteSearch(selectors.accountAcl.permission, 'ALLOW'); await page.autocompleteSearch(selectors.accountAcl.permission, 'ALLOW');
await page.waitToClick(selectors.accountAcl.save); await page.waitToClick(selectors.accountAcl.save);

View File

@ -14,25 +14,25 @@
<vn-textfield <vn-textfield
label="User" label="User"
ng-model="$ctrl.user.name" ng-model="$ctrl.user.name"
rule rule="VnUser"
vn-focus> vn-focus>
</vn-textfield> </vn-textfield>
<vn-textfield <vn-textfield
label="Nickname" label="Nickname"
ng-model="$ctrl.user.nickname" ng-model="$ctrl.user.nickname"
rule> rule="VnUser">
</vn-textfield> </vn-textfield>
<vn-textfield <vn-textfield
label="Personal email" label="Personal email"
ng-model="$ctrl.user.email" ng-model="$ctrl.user.email"
rule> rule="VnUser">
</vn-textfield> </vn-textfield>
<vn-autocomplete <vn-autocomplete
label="Language" label="Language"
ng-model="$ctrl.user.lang" ng-model="$ctrl.user.lang"
url="Languages" url="Languages"
value-field="code" value-field="code"
rule> rule="VnUser">
</vn-autocomplete> </vn-autocomplete>
</vn-vertical> </vn-vertical>
</vn-card> </vn-card>

View File

@ -14,24 +14,24 @@
<vn-textfield <vn-textfield
label="Name" label="Name"
ng-model="$ctrl.user.name" ng-model="$ctrl.user.name"
rule rule="VnUser"
vn-focus> vn-focus>
</vn-textfield> </vn-textfield>
<vn-textfield <vn-textfield
label="Nickname" label="Nickname"
ng-model="$ctrl.user.nickname" ng-model="$ctrl.user.nickname"
rule> rule="VnUser">
</vn-textfield> </vn-textfield>
<vn-textfield <vn-textfield
label="Email" label="Email"
ng-model="$ctrl.user.email" ng-model="$ctrl.user.email"
rule> rule="VnUser">
</vn-textfield> </vn-textfield>
<vn-autocomplete <vn-autocomplete
label="Role" label="Role"
ng-model="$ctrl.user.roleFk" ng-model="$ctrl.user.roleFk"
url="Roles" url="Roles"
rule> rule="VnUser">
</vn-autocomplete> </vn-autocomplete>
<vn-textfield <vn-textfield
label="Password" label="Password"

View File

@ -149,19 +149,9 @@ export default class Controller extends Section {
case 'lines': case 'lines':
return {'lines': value}; return {'lines': value};
case 'ipt': case 'ipt':
return {or: return {'ipt': {like: `%${value}%`}};
[
{'ipt': {like: `%${value}%`}},
{'ipt': null}
]
};
case 'futureIpt': case 'futureIpt':
return {or: return {'futureIpt': {like: `%${value}%`}};
[
{'futureIpt': {like: `%${value}%`}},
{'futureIpt': null}
]
};
} }
} }
} }