|
|
@ -32,13 +32,13 @@
|
|
|
|
<template v-if="column.key === 'action'">
|
|
|
|
<template v-if="column.key === 'action'">
|
|
|
|
<TableAction :actions="getActionOptList(record)" />
|
|
|
|
<TableAction :actions="getActionOptList(record)" />
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<template v-if="column.dataIndex == 'invoiceNumber'">
|
|
|
|
<template v-if="column.dataIndex == 'reimbursementId'">
|
|
|
|
<span>{{ record.invoiceNumber || '' }}</span>
|
|
|
|
<span>{{ record.reimbursementId || '' }}</span>
|
|
|
|
<i
|
|
|
|
<i
|
|
|
|
class="iconfont icon-fuzhi3"
|
|
|
|
class="iconfont icon-fuzhi3"
|
|
|
|
style="color: #257afa; font-size: 14px; margin-left: 4px; cursor: pointer"
|
|
|
|
style="color: #257afa; font-size: 14px; margin-left: 4px; cursor: pointer"
|
|
|
|
v-if="record.invoiceNumber"
|
|
|
|
v-if="record.reimbursementId"
|
|
|
|
@click="copyHandle(record)"
|
|
|
|
@click.stop="copyHandle(record)"
|
|
|
|
></i>
|
|
|
|
></i>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<template v-if="column.dataIndex == 'reimbursementType'">
|
|
|
|
<template v-if="column.dataIndex == 'reimbursementType'">
|
|
|
@ -56,6 +56,7 @@
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
|
|
<script setup lang="ts">
|
|
|
|
|
|
|
|
import { unref, h } from 'vue'
|
|
|
|
import { ReimbursementGetList, ReimbursementDelete } from './api.js'
|
|
|
|
import { ReimbursementGetList, ReimbursementDelete } from './api.js'
|
|
|
|
import { BasicTable, useTable, TableAction, ActionItem } from '/@/components/Table'
|
|
|
|
import { BasicTable, useTable, TableAction, ActionItem } from '/@/components/Table'
|
|
|
|
import { formatParams } from '/@/hooks/web/common'
|
|
|
|
import { formatParams } from '/@/hooks/web/common'
|
|
|
@ -121,14 +122,12 @@
|
|
|
|
const canEditable = [0, 2, 4].includes(record.reimbursementType)
|
|
|
|
const canEditable = [0, 2, 4].includes(record.reimbursementType)
|
|
|
|
return [
|
|
|
|
return [
|
|
|
|
{
|
|
|
|
{
|
|
|
|
icon: canEditable ? 'clarity:note-edit-line' : 'ant-design:file-text-outlined',
|
|
|
|
customIcon: h('i', {
|
|
|
|
/* icon: canEditable
|
|
|
|
class: 'iconfont icon-chakan',
|
|
|
|
? 'clarity:note-edit-line'
|
|
|
|
style: { color: '#257afa', fontSize: '16px' },
|
|
|
|
: h('i', {
|
|
|
|
}),
|
|
|
|
class: 'iconfont icon-chakan',
|
|
|
|
icon: 'clarity:note-edit-line',
|
|
|
|
style: { color: '#257afa', fontSize: '16px' },
|
|
|
|
isCustomIcon: !canEditable,
|
|
|
|
}), */
|
|
|
|
|
|
|
|
// isCustomIcon: !canEditable,
|
|
|
|
|
|
|
|
tooltip: canEditable ? '编辑' : '查看',
|
|
|
|
tooltip: canEditable ? '编辑' : '查看',
|
|
|
|
onClick: GoDetailed.bind(null, record),
|
|
|
|
onClick: GoDetailed.bind(null, record),
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -158,8 +157,8 @@
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
const copyHandle = (row: BillItem) => {
|
|
|
|
const copyHandle = (row: BillItem) => {
|
|
|
|
const { clipboardRef, isSuccessRef } = useCopyToClipboard(row.invoiceNumber)
|
|
|
|
const { clipboardRef, isSuccessRef } = useCopyToClipboard(row.reimbursementId)
|
|
|
|
clipboardRef.value = row.invoiceNumber
|
|
|
|
clipboardRef.value = row.reimbursementId
|
|
|
|
if (unref(isSuccessRef)) {
|
|
|
|
if (unref(isSuccessRef)) {
|
|
|
|
createMessage.success('复制成功!')
|
|
|
|
createMessage.success('复制成功!')
|
|
|
|
}
|
|
|
|
}
|
|
|
|