ticket descriptor update acl
gitea/salix/2079-acl_update_ticket_weekly This commit looks good Details

This commit is contained in:
Bernat Exposito Domenech 2020-02-13 08:31:29 +01:00
parent a3e0d0d628
commit 4b48a89eaa
3 changed files with 9 additions and 2 deletions

View File

@ -0,0 +1,3 @@
INSERT INTO salix.ACL (model, property, accessType, permission, principalType, principalId)
VALUES ('TicketWeekly', '*', 'WRITE', 'ALLOW', 'ROLE', 'buyer');
UPDATE salix.ACL SET accessType = 'READ' WHERE (id = '91');

View File

@ -8,7 +8,7 @@ describe('Ticket descriptor path', () => {
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'ticket');
await page.loginAndModule('buyer', 'ticket');
await page.accessToSection('ticket.weekly.index');
});

View File

@ -7,7 +7,11 @@ class Controller extends Component {
this.aclService = aclService;
this.$httpParamSerializer = $httpParamSerializer;
this.moreOptions = [
{name: 'Add turn', callback: this.showAddTurnDialog},
{
name: 'Add turn',
acl: 'buyer',
callback: this.showAddTurnDialog
},
{name: 'Show Delivery Note', callback: this.showDeliveryNote},
{name: 'Send Delivery Note', callback: this.confirmDeliveryNote},
{name: 'Delete ticket', callback: this.showDeleteTicketDialog},