Browse Source

update all_project condition

pull/1/head
wahyuun 8 months ago
parent
commit
d712508ade
  1. 6
      src/views/SimproV2/CreatedProyek/index.js

6
src/views/SimproV2/CreatedProyek/index.js

@ -418,12 +418,12 @@ const CreatedProyek = ({ params, ...props }) => {
paging: { start: start, length: rowsPerPage }, paging: { start: start, length: rowsPerPage },
}; };
if (all_project !== null && all_project === true) { if (role_name !== 'Super Admin' && all_project === 'true') {
payload.columns.push( payload.columns.push(
{ name: "company_id", logic_operator: "like", value: company_id, operator: "AND" } { name: "company_id", logic_operator: "like", value: parseInt(company_id), operator: "AND" }
); );
} }
if (role_name !== 'Super Admin') { if (role_name !== 'Super Admin' && all_project === 'null') {
payload.columns.push( payload.columns.push(
{ name: "created_by_id", logic_operator: "IN", value: [JSON.parse(hierarchy)], operator: "AND" } { name: "created_by_id", logic_operator: "IN", value: [JSON.parse(hierarchy)], operator: "AND" }
); );

Loading…
Cancel
Save