From bf332f9494f657aebc38a391fe51fe1c31ab4159 Mon Sep 17 00:00:00 2001 From: ilham Date: Thu, 30 Dec 2021 22:21:32 +0700 Subject: [PATCH 1/5] fix: profile --- src/pages/Profile/Profile.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/Profile/Profile.js b/src/pages/Profile/Profile.js index ac999c2..c9c4144 100644 --- a/src/pages/Profile/Profile.js +++ b/src/pages/Profile/Profile.js @@ -224,7 +224,7 @@ export const Profile = observer(() => { {new Intl.NumberFormat("id-ID", { style: "currency", currency: "IDR", - }).format(store.authentication.profileData?.wallet || 0)} + }).format(store.authentication.profileData?.profit || 0)} From 0e12a22be38997466ca9cb34da813d69a382525f Mon Sep 17 00:00:00 2001 From: ilham Date: Thu, 30 Dec 2021 22:31:34 +0700 Subject: [PATCH 2/5] fix: get product --- src/component/ProductComponent.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/component/ProductComponent.js b/src/component/ProductComponent.js index 0ffcece..a5f6f93 100644 --- a/src/component/ProductComponent.js +++ b/src/component/ProductComponent.js @@ -129,11 +129,11 @@ export const ProductComponent = observer((props) => { }, ]; if (store.authentication.userData.role !== "Admin") columns.pop(); - if (store.authentication.userData.role !== "Admin") 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[4]; if (store.authentication.userData.role !== "Admin") delete columns[6]; if (store.authentication.userData.role === "Admin Partner") delete columns[7]; - if (store.authentication.userData.role === "Admin") delete columns[4]; if (store.authentication.userData.role !== "Admin") delete columns[8]; if (store.authentication.userData.role === "Admin Partner") delete columns[5]; From a444623d0dfc58e2b82ad0035ad564688db06269 Mon Sep 17 00:00:00 2001 From: ilham Date: Fri, 31 Dec 2021 00:18:52 +0700 Subject: [PATCH 3/5] fix: membership and config partner --- src/component/PartnerComponent.js | 2 +- src/pages/Membership/Membership.js | 2 +- src/store/membership.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/component/PartnerComponent.js b/src/component/PartnerComponent.js index cfddd6f..29c3a46 100644 --- a/src/component/PartnerComponent.js +++ b/src/component/PartnerComponent.js @@ -391,7 +391,7 @@ export const PartnerComponent = observer((props) => { )} {((idData && isChangePassword) || !idData) && ( { value={filterMembership} > {store.membership.data.map((item) => ( - ))} diff --git a/src/store/membership.js b/src/store/membership.js index 197eb89..a9f78cb 100644 --- a/src/store/membership.js +++ b/src/store/membership.js @@ -21,7 +21,7 @@ export class Membership { async getData() { try { - const response = await http.get(`/users?page=${this.page}&pageSize=${this.pageSize}&superrior=${this.filterMembership}&type=${this.filterPartner}`); + const response = await http.get(`/users?page=${this.page}&pageSize=${this.pageSize}&superior=${this.filterMembership}&type=${this.filterPartner}`); // console.log(this.filterMembership) // console.log(this.filterPartner) // console.log(response) From 71840f249702a2145e5a03eee164fa0c2889ca17 Mon Sep 17 00:00:00 2001 From: ilham Date: Fri, 31 Dec 2021 00:25:04 +0700 Subject: [PATCH 4/5] add: profit in profile --- src/pages/Profile/Profile.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/Profile/Profile.js b/src/pages/Profile/Profile.js index c9c4144..d073070 100644 --- a/src/pages/Profile/Profile.js +++ b/src/pages/Profile/Profile.js @@ -224,7 +224,7 @@ export const Profile = observer(() => { {new Intl.NumberFormat("id-ID", { style: "currency", currency: "IDR", - }).format(store.authentication.profileData?.profit || 0)} + }).format(store.authentication.profileData?.wallet || 0)} @@ -244,7 +244,7 @@ export const Profile = observer(() => { {new Intl.NumberFormat("id-ID", { style: "currency", currency: "IDR", - }).format(store.authentication.profileData?.wallet || 0)} + }).format(store.authentication.profileData?.profit || 0)} From fb0ccd0509c5f5682ddb246d49279ecc59a4f130 Mon Sep 17 00:00:00 2001 From: ilham Date: Fri, 31 Dec 2021 01:11:13 +0700 Subject: [PATCH 5/5] fix: profile --- src/pages/Profile/Profile.js | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/pages/Profile/Profile.js b/src/pages/Profile/Profile.js index d073070..724c17d 100644 --- a/src/pages/Profile/Profile.js +++ b/src/pages/Profile/Profile.js @@ -119,13 +119,13 @@ export const Profile = observer(() => { }, { title: "Tujuan", - dataIndex: "tujuan", - key: "tujuan", + dataIndex: "transaction_destination", + key: "transaction_destination", }, { - title: "ID Transaksi", - dataIndex: "id_transaksi", - key: "id_transaksi", + title: "Kode Transaksi", + dataIndex: "transaction_code", + key: "transaction_code", }, { title: "Status", @@ -134,13 +134,13 @@ export const Profile = observer(() => { }, { title: "No Seri", - dataIndex: "no_seri", - key: "no_seri", + dataIndex: "seri_number", + key: "seri_number", }, { title: "IDTrx Mitra", - dataIndex: "idtrx_mitra", - key: "idtrx_mitra", + dataIndex: "partner_transaction_code", + key: "partner_transaction_code", }, { title: "Transaction Date",