Merge branch 'develop' into 'devops-staging'
fix: change hide action button in memberhship See merge request empatnusabangsa/ppob/ppob-frontend!13
This commit is contained in:
commit
bbe020ae4d
|
@ -165,13 +165,13 @@ export const Membership = observer(() => {
|
||||||
key: "action",
|
key: "action",
|
||||||
render: (text, record) => (
|
render: (text, record) => (
|
||||||
<Space size="middle">
|
<Space size="middle">
|
||||||
<Button
|
{store.authentication.userData.role === "Admin" && <Button
|
||||||
type={record?.isActive === true ? "danger" : "primary"}
|
type={record?.isActive === true ? "danger" : "primary"}
|
||||||
onClick={() => changeStatus(record?.id, record?.isActive)}
|
onClick={() => changeStatus(record?.id, record?.isActive)}
|
||||||
>
|
>
|
||||||
{record?.isActive === true ? "Inactive" : "Active"}
|
{record?.isActive === true ? "Inactive" : "Active"}
|
||||||
</Button>
|
</Button>}
|
||||||
{store.authentication.userData.role === ('Admin' && 'Supervisor') && <Button
|
<Button
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
setDestination(record?.id);
|
setDestination(record?.id);
|
||||||
console.log(record?.id);
|
console.log(record?.id);
|
||||||
|
@ -179,8 +179,8 @@ export const Membership = observer(() => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<DownloadOutlined/> Top Up Saldo
|
<DownloadOutlined/> Top Up Saldo
|
||||||
</Button>}
|
</Button>
|
||||||
<Button
|
{store.authentication.userData.role === "Admin" && <Button
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
let record2 = record;
|
let record2 = record;
|
||||||
delete record2.password;
|
delete record2.password;
|
||||||
|
@ -194,8 +194,8 @@ export const Membership = observer(() => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Edit
|
Edit
|
||||||
</Button>
|
</Button>}
|
||||||
<Button
|
{store.authentication.userData.role === "Admin" && <Button
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
let record2 = record;
|
let record2 = record;
|
||||||
delete record2.password;
|
delete record2.password;
|
||||||
|
@ -209,7 +209,7 @@ export const Membership = observer(() => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Ganti Password
|
Ganti Password
|
||||||
</Button>
|
</Button>}
|
||||||
<Button
|
<Button
|
||||||
onClick={async () => {
|
onClick={async () => {
|
||||||
await store.transaction.getDataHistoryTopUp(record.id)
|
await store.transaction.getDataHistoryTopUp(record.id)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user