Bug Fixing
This commit is contained in:
		| @@ -128,7 +128,7 @@ export const ProductComponent = observer((props) => { | |||||||
|       ), |       ), | ||||||
|     }, |     }, | ||||||
|   ]; |   ]; | ||||||
|   if (store.authentication.userData.role !== "Admin") columns.pop(); |   //if (store.authentication.userData.role !== "Admin") columns.pop(); | ||||||
|   //if (store.authentication.userData.role === "Admin Partner") delete columns[2]; |   //if (store.authentication.userData.role === "Admin Partner") delete columns[2]; | ||||||
|   if (store.authentication.userData.role === "Admin Partner") delete columns[3]; |   if (store.authentication.userData.role === "Admin Partner") delete columns[3]; | ||||||
|   if (store.authentication.userData.role != "Admin Partner") delete columns[4]; |   if (store.authentication.userData.role != "Admin Partner") delete columns[4]; | ||||||
| @@ -136,7 +136,7 @@ export const ProductComponent = observer((props) => { | |||||||
|   if (store.authentication.userData.role !== "Admin") delete columns[2]; |   if (store.authentication.userData.role !== "Admin") delete columns[2]; | ||||||
|   if (store.authentication.userData.role !== "Admin") delete columns[5]; |   if (store.authentication.userData.role !== "Admin") delete columns[5]; | ||||||
|   if (store.authentication.userData.role === "Admin Partner") delete columns[7]; |   if (store.authentication.userData.role === "Admin Partner") delete columns[7]; | ||||||
|   if (store.authentication.userData.role !== "Admin") delete columns[8]; |   //if (store.authentication.userData.role !== "Admin") delete columns[8]; | ||||||
|   //if (store.authentication.userData.role === "Admin Partner") delete columns[5]; |   //if (store.authentication.userData.role === "Admin Partner") delete columns[5]; | ||||||
|  |  | ||||||
|   const deleteData = async (id) => { |   const deleteData = async (id) => { | ||||||
|   | |||||||
| @@ -412,8 +412,8 @@ export const DetailUser = observer(() => { | |||||||
|             Detail User |             Detail User | ||||||
|           </Title> |           </Title> | ||||||
|           <Col |           <Col | ||||||
|             lg={store.authentication.userData.role === "Admin" ? 18 : 13} |             lg={store.authentication.userData.role === "Admin" ? 18 : 17} | ||||||
|             xs={store.authentication.userData.role === "Admin" ? 18 : 13} |             xs={store.authentication.userData.role === "Admin" ? 18 : 17} | ||||||
|             style={{ textAlign: "right" }} |             style={{ textAlign: "right" }} | ||||||
|           > |           > | ||||||
|             <Space |             <Space | ||||||
|   | |||||||
| @@ -201,6 +201,7 @@ export const Membership = observer(() => { | |||||||
|       key: "action", |       key: "action", | ||||||
|       render: (text, record) => ( |       render: (text, record) => ( | ||||||
|         <Space size="middle"> |         <Space size="middle"> | ||||||
|  |           {store.authentication.userData.role === "Admin" && ( | ||||||
|             <Button |             <Button | ||||||
|               onClick={() => { |               onClick={() => { | ||||||
|                 setDestination(record?.id); |                 setDestination(record?.id); | ||||||
| @@ -210,6 +211,7 @@ export const Membership = observer(() => { | |||||||
|             > |             > | ||||||
|               <DownloadOutlined /> Top Up Saldo |               <DownloadOutlined /> Top Up Saldo | ||||||
|             </Button> |             </Button> | ||||||
|  |           )} | ||||||
|           <Button |           <Button | ||||||
|             onClick={async () => { |             onClick={async () => { | ||||||
|               await store.transaction.getDataHistoryTopUp(record.id); |               await store.transaction.getDataHistoryTopUp(record.id); | ||||||
| @@ -226,7 +228,7 @@ export const Membership = observer(() => { | |||||||
|     }, |     }, | ||||||
|   ]; |   ]; | ||||||
|  |  | ||||||
|   if (store.authentication.userData.role === "Customer Service") columns.pop(); |   //if (store.authentication.userData.role === "Customer Service") columns.pop(); | ||||||
|   const routeData = [ |   const routeData = [ | ||||||
|     { |     { | ||||||
|       route: LINKS.HOME, |       route: LINKS.HOME, | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user