Merge branch 'develop' into 'devops-staging'
Develop See merge request empatnusabangsa/ppob/ppob-frontend!58
This commit is contained in:
commit
686ab10bbd
|
@ -13,7 +13,9 @@ import {
|
||||||
Tag,
|
Tag,
|
||||||
Divider,
|
Divider,
|
||||||
Image,
|
Image,
|
||||||
|
Avatar,
|
||||||
} from "antd";
|
} from "antd";
|
||||||
|
import { UserOutlined } from "@ant-design/icons";
|
||||||
import { BreadcumbComponent } from "../../component/BreadcumbComponent";
|
import { BreadcumbComponent } from "../../component/BreadcumbComponent";
|
||||||
import { LINKS } from "../../routes/app";
|
import { LINKS } from "../../routes/app";
|
||||||
import { useStore } from "../../utils/useStore";
|
import { useStore } from "../../utils/useStore";
|
||||||
|
@ -346,69 +348,71 @@ export const DetailUser = observer(() => {
|
||||||
<Row style={{ marginBottom: 20 }}>
|
<Row style={{ marginBottom: 20 }}>
|
||||||
<Col lg={12} xs={24}>
|
<Col lg={12} xs={24}>
|
||||||
<Row>
|
<Row>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Name</Text>
|
<Text strong>Name</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>{store.authentication.dataProfit.userDetail?.name}</Text>
|
<Text>{store.authentication.dataProfit.userDetail?.name}</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Username</Text>
|
<Text strong>Username</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>{store.authentication.dataProfit.username}</Text>
|
<Text>{store.authentication.dataProfit.username}</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Role</Text>
|
<Text strong>Role</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>{store.authentication.dataProfit.roles?.name}</Text>
|
<Text>{store.authentication.dataProfit.roles?.name}</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Phone Number</Text>
|
<Text strong>Phone Number</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>
|
<Text>
|
||||||
{store.authentication.dataProfit.userDetail?.phone_number}
|
{store.authentication.dataProfit.userDetail?.phone_number}
|
||||||
</Text>
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Id Number</Text>
|
<Text strong>Id Number</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>
|
<Text>
|
||||||
{store.authentication.dataProfit.userDetail?.identity_number}
|
{store.authentication.dataProfit.userDetail?.identity_number}
|
||||||
</Text>
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Status</Text>
|
<Text strong>Status</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text>
|
<Text>
|
||||||
{store.authentication.dataProfit.isActive === true
|
{store.authentication.dataProfit.isActive === true
|
||||||
? "Aktif"
|
? "Aktif"
|
||||||
: "Inaktif"}
|
: "Inaktif"}
|
||||||
</Text>
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Image identity</Text>
|
<Text strong>Foto Identitas</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
<Text strong>Image Store</Text>
|
<Text strong>Foto Toko</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
|
<Text>
|
||||||
<Image
|
<Image
|
||||||
src={`${appConfig.apiUrl}/config/image/${store.authentication.dataProfit.userDetail?.image_identity}`}
|
src={`${appConfig.apiUrl}/config/image/${store.authentication.dataProfit.userDetail?.image_identity}`}
|
||||||
style={{ width: "5vw" }}
|
style={{ width: "10vw" }}
|
||||||
alt={store.authentication.dataProfit.userDetail?.name}
|
|
||||||
/>
|
/>
|
||||||
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={10}>
|
<Col span={12}>
|
||||||
|
<Text>
|
||||||
<Image
|
<Image
|
||||||
src={`${appConfig.apiUrl}/config/image/${store.authentication.dataProfit.userDetail?.image_store}`}
|
src={`${appConfig.apiUrl}/config/image/${store.authentication.dataProfit.userDetail?.image_store}`}
|
||||||
style={{ width: "5vw" }}
|
style={{ width: "10vw" }}
|
||||||
alt={store.authentication.dataProfit.userDetail?.name}
|
|
||||||
/>
|
/>
|
||||||
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
</Col>
|
</Col>
|
||||||
|
|
|
@ -12,6 +12,7 @@ import {
|
||||||
Input,
|
Input,
|
||||||
Divider,
|
Divider,
|
||||||
List,
|
List,
|
||||||
|
Image,
|
||||||
Tag,
|
Tag,
|
||||||
} from "antd";
|
} from "antd";
|
||||||
import moment from "moment";
|
import moment from "moment";
|
||||||
|
@ -21,6 +22,8 @@ import { useStore } from "../../utils/useStore";
|
||||||
import { observer } from "mobx-react-lite";
|
import { observer } from "mobx-react-lite";
|
||||||
import { FilterOutlined } from "@ant-design/icons";
|
import { FilterOutlined } from "@ant-design/icons";
|
||||||
import { format, parseISO } from "date-fns";
|
import { format, parseISO } from "date-fns";
|
||||||
|
import { appConfig } from "../../config/app";
|
||||||
|
|
||||||
import { ModalLoaderContext } from "../../utils/modal";
|
import { ModalLoaderContext } from "../../utils/modal";
|
||||||
|
|
||||||
const { Title, Text } = Typography;
|
const { Title, Text } = Typography;
|
||||||
|
@ -74,13 +77,17 @@ export const Profile = observer(() => {
|
||||||
|
|
||||||
const handleSubmitFilter = async () => {
|
const handleSubmitFilter = async () => {
|
||||||
const data = form.getFieldsValue();
|
const data = form.getFieldsValue();
|
||||||
console.log(data.start_date)
|
console.log(data.start_date);
|
||||||
console.log(data.end_date)
|
console.log(data.end_date);
|
||||||
|
|
||||||
const awal=store.transaction.filterStart = moment(data.start_date).format('YYYY-MM-DD HH:mm:ss');
|
const awal = (store.transaction.filterStart = moment(
|
||||||
const akhir=store.transaction.filterEnd = moment(data.end_date).format('YYYY-MM-DD HH:mm:ss');
|
data.start_date
|
||||||
console.log(awal)
|
).format("YYYY-MM-DD HH:mm:ss"));
|
||||||
console.log(akhir)
|
const akhir = (store.transaction.filterEnd = moment(data.end_date).format(
|
||||||
|
"YYYY-MM-DD HH:mm:ss"
|
||||||
|
));
|
||||||
|
console.log(awal);
|
||||||
|
console.log(akhir);
|
||||||
// store.transaction.filterStart = data.start_date;
|
// store.transaction.filterStart = data.start_date;
|
||||||
// store.transaction.filterEnd = data.end_date;
|
// store.transaction.filterEnd = data.end_date;
|
||||||
modalLoader.setLoading(true);
|
modalLoader.setLoading(true);
|
||||||
|
@ -120,7 +127,6 @@ export const Profile = observer(() => {
|
||||||
title: "Price",
|
title: "Price",
|
||||||
dataIndex: "price",
|
dataIndex: "price",
|
||||||
key: "price",
|
key: "price",
|
||||||
|
|
||||||
render: (text) =>
|
render: (text) =>
|
||||||
new Intl.NumberFormat("id-ID", {
|
new Intl.NumberFormat("id-ID", {
|
||||||
style: "currency",
|
style: "currency",
|
||||||
|
@ -176,19 +182,20 @@ export const Profile = observer(() => {
|
||||||
dataIndex: "partner_transaction_code",
|
dataIndex: "partner_transaction_code",
|
||||||
key: "partner_transaction_code",
|
key: "partner_transaction_code",
|
||||||
},
|
},
|
||||||
{
|
|
||||||
title: "Tanggal Transaksi",
|
|
||||||
dataIndex: "created_at",
|
|
||||||
key: "created_at",
|
|
||||||
render: (text, record) => {
|
|
||||||
return <Text>{format(parseISO(record.created_at), "dd-MM-yyyy")}</Text>;
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
title: "Alasan Gagal",
|
title: "Alasan Gagal",
|
||||||
dataIndex: "failed_reason",
|
dataIndex: "failed_reason",
|
||||||
key: "failed_reason",
|
key: "failed_reason",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
title: "Tanggal Transaksi",
|
||||||
|
dataIndex: "created_at",
|
||||||
|
key: "created_at",
|
||||||
|
|
||||||
|
render: (text, record) => {
|
||||||
|
return <Text>{format(parseISO(record.created_at), "dd-MM-yyyy")}</Text>;
|
||||||
|
},
|
||||||
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
const styleSaldoTitle = store.ui.mediaQuery.isDesktop
|
const styleSaldoTitle = store.ui.mediaQuery.isDesktop
|
||||||
|
@ -249,6 +256,24 @@ export const Profile = observer(() => {
|
||||||
{store.authentication.profileData.superior?.username}
|
{store.authentication.profileData.superior?.username}
|
||||||
</Text>
|
</Text>
|
||||||
</Col>
|
</Col>
|
||||||
|
<Col span={12}>
|
||||||
|
<Text strong>Foto Identitas</Text>
|
||||||
|
</Col>
|
||||||
|
<Col span={12}>
|
||||||
|
<Text strong>Foto Toko</Text>
|
||||||
|
</Col>
|
||||||
|
<Col span={12}>
|
||||||
|
<Image
|
||||||
|
src={`${appConfig.apiUrl}/config/image/${store.authentication.profileData.userDetail?.image_identity}`}
|
||||||
|
style={{ width: "10vw" }}
|
||||||
|
/>
|
||||||
|
</Col>
|
||||||
|
<Col span={12}>
|
||||||
|
<Image
|
||||||
|
src={`${appConfig.apiUrl}/config/image/${store.authentication.profileData.userDetail?.image_store}`}
|
||||||
|
style={{ width: "10vw" }}
|
||||||
|
/>
|
||||||
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
</Col>
|
</Col>
|
||||||
<Col span={store.ui.mediaQuery.isMobile ? 24 : 5}>
|
<Col span={store.ui.mediaQuery.isMobile ? 24 : 5}>
|
||||||
|
@ -310,6 +335,8 @@ export const Profile = observer(() => {
|
||||||
<Table
|
<Table
|
||||||
columns={columns}
|
columns={columns}
|
||||||
bordered
|
bordered
|
||||||
|
scroll={{ x: 1300 }}
|
||||||
|
//scroll={{ x: 1500, y: 300 }}
|
||||||
dataSource={store.transaction.dataHistoryTransaction}
|
dataSource={store.transaction.dataHistoryTransaction}
|
||||||
pagination={{
|
pagination={{
|
||||||
pageSize: store.transaction.pageSizeHistoryTransaction,
|
pageSize: store.transaction.pageSizeHistoryTransaction,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user