This commit is contained in:
parent
bbbc8d2157
commit
0718f28e5e
1 changed files with 14 additions and 14 deletions
|
|
@ -214,13 +214,13 @@ export class PermissionController extends Controller {
|
||||||
return {
|
return {
|
||||||
...baseAttr,
|
...baseAttr,
|
||||||
parentNode: actingAttr.parentNode,
|
parentNode: actingAttr.parentNode,
|
||||||
attrOwnership: actingAttr.attrOwnership,
|
attrOwnership: getHigherOwnership(actingAttr.attrOwnership, baseAttr.attrOwnership),
|
||||||
attrIsCreate: actingAttr.attrIsCreate,
|
attrIsCreate: actingAttr.attrIsCreate || baseAttr.attrIsCreate,
|
||||||
attrIsList: actingAttr.attrIsList,
|
attrIsList: actingAttr.attrIsList || baseAttr.attrIsList,
|
||||||
attrIsGet: actingAttr.attrIsGet,
|
attrIsGet: actingAttr.attrIsGet || baseAttr.attrIsGet,
|
||||||
attrIsUpdate: actingAttr.attrIsUpdate,
|
attrIsUpdate: actingAttr.attrIsUpdate || baseAttr.attrIsUpdate,
|
||||||
attrIsDelete: actingAttr.attrIsDelete,
|
attrIsDelete: actingAttr.attrIsDelete || baseAttr.attrIsDelete,
|
||||||
attrPrivilege: actingAttr.attrPrivilege,
|
attrPrivilege: getHigherPrivilege(actingAttr.attrPrivilege, baseAttr.attrPrivilege),
|
||||||
// เพิ่ม metadata เพื่อระบุว่ามาจาก acting
|
// เพิ่ม metadata เพื่อระบุว่ามาจาก acting
|
||||||
_isActing: true,
|
_isActing: true,
|
||||||
};
|
};
|
||||||
|
|
@ -1017,13 +1017,13 @@ export class PermissionController extends Controller {
|
||||||
return {
|
return {
|
||||||
...baseAttr,
|
...baseAttr,
|
||||||
parentNode: actingAttr.parentNode,
|
parentNode: actingAttr.parentNode,
|
||||||
attrOwnership: actingAttr.attrOwnership,
|
attrOwnership: getHigherOwnership(actingAttr.attrOwnership, baseAttr.attrOwnership),
|
||||||
attrIsCreate: actingAttr.attrIsCreate,
|
attrIsCreate: actingAttr.attrIsCreate || baseAttr.attrIsCreate,
|
||||||
attrIsList: actingAttr.attrIsList,
|
attrIsList: actingAttr.attrIsList || baseAttr.attrIsList,
|
||||||
attrIsGet: actingAttr.attrIsGet,
|
attrIsGet: actingAttr.attrIsGet || baseAttr.attrIsGet,
|
||||||
attrIsUpdate: actingAttr.attrIsUpdate,
|
attrIsUpdate: actingAttr.attrIsUpdate || baseAttr.attrIsUpdate,
|
||||||
attrIsDelete: actingAttr.attrIsDelete,
|
attrIsDelete: actingAttr.attrIsDelete || baseAttr.attrIsDelete,
|
||||||
attrPrivilege: actingAttr.attrPrivilege,
|
attrPrivilege: getHigherPrivilege(actingAttr.attrPrivilege, baseAttr.attrPrivilege),
|
||||||
_isActing: true,
|
_isActing: true,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue