added setting for users
This commit is contained in:
@@ -4,23 +4,27 @@
|
||||
<BaseTable v-bind="tblProps" @register="submit" ref="tbl">
|
||||
<template #action="{ record }">
|
||||
<div class="flex items-center justify-center gap-2">
|
||||
<a-tooltip placement="bottom">
|
||||
<a-tooltip
|
||||
placement="bottom"
|
||||
class="cursor-pointer"
|
||||
:get-popup-container="tooltipContainer"
|
||||
@click="openAssetFunds(record)"
|
||||
>
|
||||
<template #title><span>قلکهای این دارایی</span></template>
|
||||
<Icon
|
||||
class="cursor-pointer"
|
||||
icon="vuesax-linear:safe-home"
|
||||
color="#7C3AED"
|
||||
@click="openAssetFunds(record)"
|
||||
/>
|
||||
<span class="inline-flex">
|
||||
<Icon icon="vuesax-linear:safe-home" color="#7C3AED" />
|
||||
</span>
|
||||
</a-tooltip>
|
||||
<a-tooltip placement="bottom">
|
||||
<a-tooltip
|
||||
placement="bottom"
|
||||
class="cursor-pointer"
|
||||
:get-popup-container="tooltipContainer"
|
||||
@click="openAssetTx(record)"
|
||||
>
|
||||
<template #title><span>تراکنشهای این دارایی</span></template>
|
||||
<Icon
|
||||
class="cursor-pointer"
|
||||
icon="vuesax-linear:receipt-2"
|
||||
color="#4572E9"
|
||||
@click="openAssetTx(record)"
|
||||
/>
|
||||
<span class="inline-flex">
|
||||
<Icon icon="vuesax-linear:receipt-2" color="#4572E9" />
|
||||
</span>
|
||||
</a-tooltip>
|
||||
</div>
|
||||
</template>
|
||||
@@ -59,6 +63,7 @@ import {
|
||||
} from '@/api/user'
|
||||
import BasicActionSheet from '@/components/BasicActionSheet.vue'
|
||||
import BasicShowContext from '@/components/BasicShowContext.vue'
|
||||
import { toJalali } from '@core/utils/useDataTime'
|
||||
|
||||
const [submit, reload] = useBaseTable()
|
||||
const [assetFundsSubmit] = useBaseTable()
|
||||
@@ -106,7 +111,13 @@ const assetTxCols = [
|
||||
{ title: 'نوع', dataIndex: 'type_str', key: 'type_str', type: 'Text' },
|
||||
{ title: 'طلا', dataIndex: 'gold', key: 'gold', type: 'Number' },
|
||||
{ title: 'ریال', dataIndex: 'cash', key: 'cash', type: 'Number' },
|
||||
{ title: 'تاریخ', dataIndex: 'created_at', key: 'created_at', type: 'Text' }
|
||||
{
|
||||
title: 'تاریخ',
|
||||
dataIndex: 'created_at',
|
||||
key: 'created_at',
|
||||
type: 'DateTime',
|
||||
customRender: (r: any) => (r.record?.created_at ? toJalali(r.record.created_at) : '—')
|
||||
}
|
||||
]
|
||||
|
||||
const assetTxTblProps = computed(() => ({
|
||||
@@ -133,8 +144,17 @@ function openAssetTx(record: any) {
|
||||
assetTxVisible.value = true
|
||||
}
|
||||
|
||||
const tooltipContainer = () => document.body
|
||||
|
||||
const fetch = () => reload()
|
||||
defineExpose({ fetch })
|
||||
|
||||
onMounted(() => {})
|
||||
</script>
|
||||
|
||||
<style lang="less">
|
||||
.ant-popover,
|
||||
.ant-tooltip {
|
||||
z-index: 1001 !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -4,14 +4,16 @@
|
||||
<BaseTable v-bind="tblProps" @register="submit" ref="tbl">
|
||||
<template #action="{ record }">
|
||||
<div class="flex items-center justify-center gap-2">
|
||||
<a-tooltip placement="bottom">
|
||||
<a-tooltip
|
||||
placement="bottom"
|
||||
class="cursor-pointer"
|
||||
:get-popup-container="tooltipContainer"
|
||||
@click="openDetails(record)"
|
||||
>
|
||||
<template #title><span>مشخصات / تراکنشها</span></template>
|
||||
<Icon
|
||||
class="cursor-pointer"
|
||||
icon="vuesax-linear:info-circle"
|
||||
color="#4572E9"
|
||||
@click="openDetails(record)"
|
||||
/>
|
||||
<span class="inline-flex">
|
||||
<Icon icon="vuesax-linear:info-circle" color="#4572E9" />
|
||||
</span>
|
||||
</a-tooltip>
|
||||
</div>
|
||||
</template>
|
||||
@@ -96,6 +98,15 @@ function openDetails(record: any) {
|
||||
detailsVisible.value = true
|
||||
}
|
||||
|
||||
const tooltipContainer = () => document.body
|
||||
|
||||
const fetch = () => reload()
|
||||
defineExpose({ fetch })
|
||||
</script>
|
||||
|
||||
<style lang="less">
|
||||
.ant-popover,
|
||||
.ant-tooltip {
|
||||
z-index: 1001 !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user