Cleaned up Sales role rights, was funky
This commit is contained in:
@@ -32,13 +32,6 @@ namespace AyaNova.Biz
|
||||
//CoreBizObject add here
|
||||
|
||||
|
||||
//TODO: BIZ objects, fine tune this stuff, best guess first pass here
|
||||
//I'm wondering about seperate bizroles for workorderitem as well as workorder
|
||||
//like, is that really useful or not
|
||||
//controller could just check rights to workorder
|
||||
//but then I'm wondering if some items under workorder might have seperate roles...
|
||||
//maybe it's workorder by default unless something needs an override
|
||||
|
||||
//BizRules will handle finer grained rights, this is just the big picture rights or default if no finer required
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
@@ -82,11 +75,11 @@ namespace AyaNova.Biz
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin
|
||||
| AuthorizationRoles.Service
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.Tech
|
||||
| AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted
|
||||
| AuthorizationRoles.ServiceRestricted
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.SalesRestricted
|
||||
| AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
@@ -116,11 +109,11 @@ namespace AyaNova.Biz
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin
|
||||
| AuthorizationRoles.Service
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.Tech
|
||||
| AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted
|
||||
| AuthorizationRoles.ServiceRestricted
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.SalesRestricted
|
||||
| AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
@@ -282,11 +275,11 @@ namespace AyaNova.Biz
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin
|
||||
| AuthorizationRoles.Service
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.Tech
|
||||
| AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted
|
||||
| AuthorizationRoles.ServiceRestricted
|
||||
| AuthorizationRoles.Sales
|
||||
| AuthorizationRoles.SalesRestricted
|
||||
| AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
@@ -374,8 +367,8 @@ namespace AyaNova.Biz
|
||||
//
|
||||
roles.Add(AyaType.Unit, new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Sales | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.Sales | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
});
|
||||
|
||||
@@ -384,8 +377,8 @@ namespace AyaNova.Biz
|
||||
//
|
||||
roles.Add(AyaType.UnitModel, new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Sales | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.Sales | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
});
|
||||
|
||||
@@ -394,8 +387,8 @@ namespace AyaNova.Biz
|
||||
//
|
||||
roles.Add(AyaType.UnitMeterReading, new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Sales | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Tech | AuthorizationRoles.Accounting,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.Sales | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
});
|
||||
|
||||
@@ -404,8 +397,8 @@ namespace AyaNova.Biz
|
||||
//
|
||||
roles.Add(AyaType.Vendor, new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Sales | AuthorizationRoles.Tech | AuthorizationRoles.Accounting | AuthorizationRoles.Inventory,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service | AuthorizationRoles.Tech | AuthorizationRoles.Accounting | AuthorizationRoles.Inventory,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.Sales | AuthorizationRoles.SalesRestricted | AuthorizationRoles.TechRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
});
|
||||
|
||||
@@ -586,7 +579,7 @@ namespace AyaNova.Biz
|
||||
//
|
||||
roles.Add(AyaType.QuoteStatus, new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Sales | AuthorizationRoles.Service,
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Sales | AuthorizationRoles.Accounting | AuthorizationRoles.Service,
|
||||
ReadFullRecord = AuthorizationRoles.All,
|
||||
Select = AuthorizationRoles.All//sub restricted by client and biz rules as status has it's own role settings so just keep it open for everyone to potentially access
|
||||
});
|
||||
@@ -600,7 +593,7 @@ namespace AyaNova.Biz
|
||||
var pmBizRoleSet = new BizRoleSet()
|
||||
{
|
||||
Change = AuthorizationRoles.BizAdmin | AuthorizationRoles.Service,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.SalesRestricted,
|
||||
ReadFullRecord = AuthorizationRoles.BizAdminRestricted | AuthorizationRoles.ServiceRestricted | AuthorizationRoles.Sales | AuthorizationRoles.SalesRestricted,
|
||||
Select = AuthorizationRoles.All
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user