perf 各种问题修复

This commit is contained in:
DaxPay
2024-08-15 19:59:20 +08:00
parent 891e2aae6b
commit b90d4a4c72
18 changed files with 552 additions and 97 deletions

View File

@@ -42,17 +42,6 @@ async function dictDropDown(dictCode: string): Promise<LabeledValue[]> {
return { label: o.name, value: o.code }
})
}
/**
* 获取字典下拉框数据列表(value值为数字)
*/
async function dictDropDownNumber(dictCode: string): Promise<LabeledValue[]> {
const list = (await getDict()) || []
return list
.filter((dict) => dictCode === dict.dictCode)
.map((o) => {
return { label: o.name, value: Number(o.code) }
})
}
/**
* 字典hooks
@@ -63,6 +52,5 @@ export function useDict() {
return {
dictConvert,
dictDropDown,
dictDropDownNumber,
}
}

View File

@@ -20,10 +20,10 @@
<a-form-item label="主键" name="id" :hidden="true">
<a-input v-model:value="form.id" :disabled="showable" />
</a-form-item>
<a-form-item label="编码" name="code">
<a-form-item label="编码" validate-first name="code">
<a-input v-model:value="form.code" :disabled="showable" placeholder="请输入编码" />
</a-form-item>
<a-form-item label="名称" name="name">
<a-form-item label="名称" validate-first name="name">
<a-input v-model:value="form.name" :disabled="showable" placeholder="请输入名称" />
</a-form-item>
<a-form-item label="是否启用" name="enable">
@@ -86,7 +86,7 @@
const { existsByServer } = useValidate()
// 表单
const formRef = ref<FormInstance>()
let form = reactive({
let form = ref({
id: null,
code: '',
name: '',
@@ -115,7 +115,7 @@
if ([FormEditType.Edit, FormEditType.Show].includes(editType)) {
confirmLoading.value = true
get(id).then(({ data }) => {
form = data
form.value = data
confirmLoading.value = false
})
} else {
@@ -127,9 +127,9 @@
formRef.value?.validate().then(async () => {
confirmLoading.value = true
if (formEditType.value === FormEditType.Add) {
await add(form).finally(() => (confirmLoading.value = false))
await add(form.value).finally(() => (confirmLoading.value = false))
} else if (formEditType.value === FormEditType.Edit) {
await update(form).finally(() => (confirmLoading.value = false))
await update(form.value).finally(() => (confirmLoading.value = false))
}
handleCancel()
emits('ok')

View File

@@ -23,18 +23,18 @@
:loading="loading"
>
<vxe-column type="seq" width="60" />
<vxe-column field="code" title="字典项编码" />
<vxe-column field="name" title="字典项名称" />
<vxe-column field="enable" title="启用状态">
<vxe-column field="code" title="字典项编码" :min-width="150" />
<vxe-column field="name" title="字典项名称" :min-width="150" />
<vxe-column field="enable" title="启用状态" :min-width="80">
<template #default="{ row }">
<a-tag v-if="row.enable" color="green">启用</a-tag>
<a-tag v-else color="red">停用</a-tag>
</template>
</vxe-column>
<vxe-column field="sortNo" title="排序" />
<vxe-column field="remark" title="备注" />
<vxe-column field="createTime" title="创建时间" />
<vxe-column fixed="right" width="150" :showOverflow="false" title="操作">
<vxe-column field="sortNo" title="排序" :min-width="50" />
<vxe-column field="remark" title="备注" :min-width="170" />
<vxe-column field="createTime" title="创建时间" :min-width="170" />
<vxe-column fixed="right" :width="150" :showOverflow="false" title="操作">
<template #default="{ row }">
<span>
<a href="javascript:" @click="show(row)">查看</a>

View File

@@ -30,7 +30,7 @@
{ field: 'url', label: '存储和访问路径' },
{ field: 'ext', label: '文件扩展名' },
{ field: 'contentType', label: 'MIME类型' },
{ field: 'platform', label: '存储平台' },
{ field: 'platformName', label: '存储平台' },
{ field: 'createTime', label: '创建时间' },
] as DescItem[]

View File

@@ -41,7 +41,7 @@
</vxe-column>
<vxe-column field="ext" title="扩展名" :min-width="50" />
<vxe-column field="contentType" title="文件类型" :min-width="100" />
<vxe-column field="platform" title="存储平台" :min-width="70" />
<vxe-column field="platformName" title="存储平台" :min-width="70" />
<vxe-column field="fileSize" title="文件大小" :min-width="120" />
<vxe-column field="createTime" title="创建时间" :min-width="170" />
<vxe-column fixed="right" :width="170" :showOverflow="false" title="操作">

View File

@@ -35,7 +35,7 @@
{
field: 'client',
label: '业务类型',
render: (businessType) => dictConvert('LogBusinessType', businessType),
render: (businessType) => dictConvert('log_business_type', businessType),
},
{ field: 'requestMethod', label: '请求方式' },
{ field: 'operateUrl', label: '请求url' },

View File

@@ -32,23 +32,23 @@
:loading="loading"
>
<vxe-column type="seq" width="60" />
<vxe-column field="operateId" title="操作人员id" />
<vxe-column field="account" title="操作账号" />
<vxe-column field="title" title="操作模块" />
<vxe-column field="success" title="是否成功">
<vxe-column field="operateId" title="操作人员id" :min-width="120" />
<vxe-column field="account" title="操作账号" :min-width="120" />
<vxe-column field="title" title="操作模块" :min-width="100" />
<vxe-column field="success" title="是否成功" :min-width="70">
<template #default="{ row }">
<a-tag v-if="row.success" color="green">成功</a-tag>
<a-tag v-else color="red">失败</a-tag>
</template>
</vxe-column>
<vxe-column field="businessType" title="业务类型">
<vxe-column field="businessType" title="业务类型" :min-width="100">
<template #default="{ row }">
{{ dictConvert('LogBusinessType', row.businessType) }}
{{ dictConvert('log_business_type', row.businessType) }}
</template>
</vxe-column>
<vxe-column field="operateIp" title="操作ip" />
<vxe-column field="errorMsg" title="错误提示" />
<vxe-column field="operateTime" title="操作时间" />
<vxe-column field="operateIp" title="操作ip" :min-width="100" />
<vxe-column field="errorMsg" title="错误提示" :min-width="150" />
<vxe-column field="operateTime" title="操作时间" :min-width="170" />
<vxe-column fixed="right" width="60" :showOverflow="false" title="操作">
<template #default="{ row }">
<span>

View File

@@ -0,0 +1,7 @@
<template>
<div> 设计开发中 </div>
</template>
<script setup lang="ts"></script>
<style scoped lang="less"></style>

View File

@@ -63,8 +63,9 @@
</a-form-item>
<a-form-item label="签名方式" name="signType">
<a-radio-group v-model:value="form.signType" :disabled="showable" button-style="solid">
<a-radio-button value="HMAC_SHA256">HMAC_SHA256</a-radio-button>
<a-radio-button value="SM3">SM3</a-radio-button>
<a-radio-button v-for="item in signTypes" :key="item.value" :value="item.value">{{
item.label
}}</a-radio-button>
</a-radio-group>
</a-form-item>
<a-form-item label="签名秘钥" name="signSecret">
@@ -77,10 +78,12 @@
</a-form-item>
<a-form-item label="通知方式" name="notifyType">
<a-radio-group v-model:value="form.notifyType" :disabled="showable" button-style="solid">
<a-radio-button value="none">不启用</a-radio-button>
<a-radio-button value="http">http</a-radio-button>
<a-radio-button value="websocket">websocket</a-radio-button>
<a-radio-button disabled value="mq">消息队列</a-radio-button>
<a-radio-button
v-for="item in merchantNotifyTypes"
:key="item.value"
:value="item.value"
>{{ item.label }}</a-radio-button
>
</a-radio-group>
</a-form-item>
<a-form-item label="通知地址" name="notifyUrl" v-if="form.notifyType !== 'none'">
@@ -118,6 +121,7 @@
import { buildUUID } from '@/utils/uuid'
import { dropdown as merchantDropdown } from '@/views/daxpay/admin/merchant/info/Merchant.api'
import { LabeledValue } from 'ant-design-vue/lib/select'
import { useDict } from '@/hooks/bootx/useDict'
const {
initFormEditType,
@@ -131,16 +135,19 @@
showable,
formEditType,
} = useFormEdit()
const { dictDropDown } = useDict()
// 表单
const formRef = ref<FormInstance>()
const form = ref<MchApp>({
notifyType: 'none',
signType: 'HMAC_SHA256',
signType: 'hmac_sha256',
limitAmount: 200.0,
orderTimeout: 5,
reqSign: true,
})
const signTypes = ref<LabeledValue[]>([])
const merchantNotifyTypes = ref<LabeledValue[]>([])
const mchNoOptions = ref<LabeledValue[]>([])
// 校验
@@ -161,7 +168,7 @@
* 入口
*/
function init(id, editType: FormEditType) {
initMerchant()
initData()
initFormEditType(editType)
resetForm()
getInfo(id, editType)
@@ -170,10 +177,19 @@
/**
* 初始化商户列表信息
*/
function initMerchant() {
function initData() {
// 商户
merchantDropdown().then(({ data }) => {
mchNoOptions.value = data
})
// 签名方式
dictDropDown('sign_type').then((data) => {
signTypes.value = data
})
// 商户通知方式
dictDropDown('merchant_notify_type').then((data) => {
merchantNotifyTypes.value = data
})
}
/**

View File

@@ -37,15 +37,10 @@
</vxe-column>
<vxe-column field="notifyType" title="通知类型" :min-width="80">
<template #default="{ row }">
<a-tag>{{ dictConvert('notify_type', row.notifyType) || '空' }}</a-tag>
<a-tag>{{ dictConvert('merchant_notify_type', row.notifyType) || '空' }}</a-tag>
</template>
</vxe-column>
<vxe-column field="notifyUrl" title="通知地址" :min-width="220" />
<vxe-column field="status" title="状态" :min-width="80">
<template #default="{ row }">
<a-tag>{{ dictConvert('mach_app_status', row.status) || '空' }}</a-tag>
</template>
</vxe-column>
<vxe-column field="createTime" title="创建时间" :min-width="120" />
<vxe-column fixed="right" :width="180" :showOverflow="false" title="操作">
<template #default="{ row }">

View File

@@ -69,16 +69,20 @@ export interface Merchant extends BaseEntity {
mchName?: string
// 公司名称
companyName?: string
// 证件类型
idType?: string
// 证件号
idNo?: string
// 联系方式
contact?: string
// 公司联系方式
companyContact?: string
// 公司地址
companyAddress?: string
// 公司信用编码
companyCode?: string
// 法人名称
legalPerson?: string
// 法人证件号码
legalPersonIdNo?: string
// 法人证件类型
idType?: string
// 法人证件号
idNo?: string
// 法人联系方式
contact?: string
// 状态
status?: string
}

View File

@@ -28,28 +28,32 @@
<a-input v-model:value="form.mchName" :disabled="showable" placeholder="请输入商户名称" />
</a-form-item>
<a-form-item label="公司名称" name="companyName">
<a-input v-model:value="form.mchName" :disabled="showable" placeholder="请输入公司名称" />
</a-form-item>
<a-form-item label="证件类型" name="idType">
<a-select
v-model:value="form.idType"
<a-input
v-model:value="form.companyName"
:disabled="showable"
allow-clear
placeholder="请选择证件类型"
>
<a-select-option value="1">身份证</a-select-option>
<a-select-option value="2">护照</a-select-option>
<a-select-option value="3">港澳居民来往内地通行证</a-select-option>
<a-select-option value="4">台湾居民来往大陆通行证</a-select-option>
<a-select-option value="5">户口簿</a-select-option>
<a-select-option value="6">军人证</a-select-option>
</a-select>
placeholder="请输入公司名称"
/>
</a-form-item>
<a-form-item label="证件号" name="idNo">
<a-input v-model:value="form.idNo" :disabled="showable" placeholder="请输入证件号" />
<a-form-item label="公司联系方式" name="companyContact">
<a-input
v-model:value="form.companyContact"
:disabled="showable"
placeholder="请输入公司联系方式"
/>
</a-form-item>
<a-form-item label="联系方式" name="contact">
<a-input v-model:value="form.contact" :disabled="showable" placeholder="请输入联系方式" />
<a-form-item label="公司信用编码" name="companyCode">
<a-input
v-model:value="form.companyCode"
:disabled="showable"
placeholder="请输入公司信用编码"
/>
</a-form-item>
<a-form-item label="公司地址" name="companyAddress">
<a-textarea
v-model:value="form.companyAddress"
:disabled="showable"
placeholder="请输入公司地址"
/>
</a-form-item>
<a-form-item label="法人名称" name="legalPerson">
<a-input
@@ -58,9 +62,16 @@
placeholder="请输入法人名称"
/>
</a-form-item>
<a-form-item label="法人证件号" name="legalPersonIdNo">
<a-form-item label="证件号" name="idNo">
<a-input v-model:value="form.idNo" :disabled="showable" placeholder="请输入证件号" />
</a-form-item>
<a-form-item label="联系方式" name="contact">
<a-input v-model:value="form.contact" :disabled="showable" placeholder="请输入联系方式" />
</a-form-item>
<a-form-item label="法人证件号码" name="idNo">
<a-input
v-model:value="form.legalPersonIdNo"
v-model:value="form.idNo"
:disabled="showable"
placeholder="请输入法人证件号码"
/>
@@ -90,6 +101,8 @@
import { FormInstance, Rule } from 'ant-design-vue/lib/form'
import { FormEditType } from '@/enums/formTypeEnum'
import { BasicDrawer } from '@/components/Drawer'
import { useDict } from '@/hooks/bootx/useDict'
import { LabeledValue } from 'ant-design-vue/lib/select'
const {
initFormEditType,
@@ -108,6 +121,9 @@
const formRef = ref<FormInstance>()
let form = ref<Merchant>({})
const { dictDropDown } = useDict()
const idTypes = ref<LabeledValue[]>([])
// 校验
const rules = reactive({
mchName: [{ required: true, message: '请输入商户名称' }],
@@ -117,11 +133,21 @@
const emits = defineEmits(['ok'])
// 入口
function init(id, editType: FormEditType) {
initData()
initFormEditType(editType)
resetForm()
getInfo(id, editType)
}
/**
* 初始化数据
*/
function initData() {
dictDropDown('id_type').then((data) => {
idTypes.value = data
})
}
/**
* 获取信息
*/

View File

@@ -27,18 +27,12 @@
:loading="loading"
>
<vxe-column type="seq" :width="60" />
<vxe-column field="mchNo" title="编码" :min-width="100" />
<vxe-column field="mchName" title="名称" :min-width="100" />
<vxe-column field="companyName" title="公司名称" :min-width="150" />
<vxe-column field="idType" title="证件类型" :min-width="80">
<template #default="{ row }">
<a-tag color="green">{{ dictConvert('idType', row.idType) || '无' }}</a-tag>
</template>
</vxe-column>
<vxe-column field="tel" title="联系方式" :min-width="100" />
<vxe-column field="legalPerson" title="法人名称" :min-width="80" />
<vxe-column field="tel" title="联系方式" :min-width="100" />
<vxe-column field="createTime" title="创建时间" :min-width="80" />
<vxe-column field="mchNo" title="商户号" :min-width="150" />
<vxe-column field="mchName" title="商户名称" :min-width="150" />
<vxe-column field="companyName" title="公司名称" :min-width="180" />
<vxe-column field="companyContact" title="联系方式" :min-width="120" />
<vxe-column field="companyCode" title="信用编码" :min-width="180" />
<vxe-column field="createTime" title="创建时间" :min-width="170" />
<vxe-column fixed="right" :width="150" :showOverflow="false" title="操作">
<template #default="{ row }">
<span>
@@ -91,7 +85,6 @@
loading,
} = useTablePage(queryPage)
const { createMessage, createConfirm } = useMessage()
const { dictConvert } = useDict()
// 查询条件
const fields = [
{ field: 'mchName', type: STRING, name: '商户名称', placeholder: '请输入商户名称' },

View File

@@ -36,7 +36,7 @@
<vxe-column field="title" title="标题" :min-width="230" />
<vxe-column field="channel" title="支付通道" :min-width="120">
<template #default="{ row }">
{{ dictConvert('PayChannel', row.channel) }}
{{ dictConvert('channel', row.channel) }}
</template>
</vxe-column>
<vxe-column field="bizOrderNo" title="商户订单号" :min-width="230" />
@@ -52,12 +52,12 @@
</vxe-column>
<vxe-column field="status" title="支付状态" :min-width="120">
<template #default="{ row }">{{
dictConvert('PayStatus', row.status) || '无'
dictConvert('pay_status', row.status) || '无'
}}</template>
</vxe-column>
<vxe-column field="refundStatus" title="退款终态" :min-width="120">
<template #default="{ row }">{{
dictConvert('PayOrderRefundStatus', row.refundStatus) || '无'
dictConvert('pay_order_refund_status', row.refundStatus) || '无'
}}</template>
</vxe-column>
<vxe-column field="allocation" title="分账" :min-width="160">

View File

@@ -0,0 +1,82 @@
import { defHttp } from '@/utils/http/axios'
import { PageResult, Result } from '#/axios'
import { MchEntity } from '#/web'
/**
* 任务分页
*/
export function page(params) {
return defHttp.get<Result<PageResult<ReconcileDiscrepancy[]>>>({
url: '/reconcile/discrepancy/page',
method: 'get',
params,
})
}
/**
* 获取单条
*/
export function get(id) {
return defHttp.get<Result<ReconcileDiscrepancy>>({
url: '/reconcile/discrepancy/findById',
params: { id },
})
}
/**
* 对账差异记录
*/
export interface ReconcileDiscrepancy extends MchEntity {
/** 对账单ID */
reconcileId?: string
/** 对账号 */
reconcileNo?: string
/** 对账日期 */
reconcileDate?: string
/** 支付通道 */
channel?: string
/** 差异类型 */
discrepancyType?: string
/* 平台侧信息 */
/** 平台交易号 */
TradeNo?: string
/** 商户订单号 */
bizTradeNo?: string
/**
* 交易类型
* @see TradeTypeEnum
*/
tradeType?: string
/** 交易金额 */
tradeAmount?: number
/** 交易状态 */
tradeStatus?: string
/** 交易时间 */
tradeTime?: string
/* 通道侧信息 */
/** 通道交易号 */
channelTradeNo?: string
/** 通道交易类型 */
channelTradeType?: string
/** 通道交易金额 */
channelTradeAmount?: number
/** 通道交易状态 */
channelTradeStatus?: string
/** 通道交易时间 */
channelTradeTime?: string
}

View File

@@ -0,0 +1,222 @@
<template>
<div>
<div class="m-3 p-3 pt-5 bg-white">
<b-query
:query-params="model.queryParam"
:default-item-count="3"
:fields="fields"
@query="queryPage"
@reset="resetQueryParams"
/>
</div>
<div class="m-3 p-3 bg-white">
<vxe-toolbar ref="xToolbar" custom :refresh="{ queryMethod: queryPage }" />
<vxe-table
row-id="id"
ref="xTable"
:data="pagination.records"
:loading="loading"
:sort-config="{ remote: true, trigger: 'cell' }"
@sort-change="sortChange"
>
<vxe-column type="seq" title="序号" width="60" />
<vxe-column field="title" title="订单标题" :min-width="120" />
<vxe-column field="reconcileDate" title="对账日期" sortable :min-width="120" />
<vxe-column field="channel" title="通道" :min-width="120">
<template #default="{ row }">
<a-tag>{{ dictConvert('PayChannel', row.channel) }}</a-tag>
</template>
</vxe-column>
<vxe-column field="tradeType" title="交易类型" :min-width="120">
<template #default="{ row }">
<a-tag>{{ dictConvert('PaymentType', row.tradeType) }}</a-tag>
</template>
</vxe-column>
<vxe-column field="diffType" title="差异类型" :min-width="120">
<template #default="{ row }">
<a-tag>{{ dictConvert('ReconcileDiffType', row.diffType) }}</a-tag>
</template>
</vxe-column>
<vxe-column field="tradeNo" title="本地交易号" :min-width="230">
<template #default="{ row }">
<a-link @click="showTrade(row)">{{ row.tradeNo }}</a-link>
</template>
</vxe-column>
<vxe-column field="outTradeNo" title="通道交易号" :min-width="230" />
<vxe-column field="amount" title="交易金额(元)" sortable :min-width="130">
<template #default="{ row }">
{{ row.amount ? (row.amount / 100).toFixed(2) : '无' }}
</template>
</vxe-column>
<vxe-column field="outAmount" title="通道交易金额(元)" sortable :min-width="150">
<template #default="{ row }">
{{ row.outAmount ? (row.outAmount / 100).toFixed(2) : '无' }}
</template>
</vxe-column>
<vxe-column field="tradeTime" title="交易时间" sortable :min-width="150" />
<vxe-column field="reconcileNo" title="对账单号" :min-width="230">
<template #default="{ row }">
<a-link @click="showReconcile(row)">{{ row.reconcileNo }}</a-link>
</template>
</vxe-column>
<vxe-column fixed="right" width="100" :showOverflow="false" title="操作">
<template #default="{ row }">
<a-link @click="show(row)">查看</a-link>
</template>
</vxe-column>
</vxe-table>
<vxe-pager
size="medium"
:loading="loading"
:current-page="pagination.current"
:page-size="pagination.size"
:total="pagination.total"
@page-change="handleTableChange"
/>
</div>
</div>
</template>
<script setup lang="ts">
import { computed, nextTick, onMounted } from 'vue'
import { page } from './ReconcileDiscrepancy.api'
import useTablePage from '@/hooks/bootx/useTablePage'
import { VxeTable, VxeTableInstance, VxeToolbarInstance } from 'vxe-table'
import { useMessage } from '@/hooks/web/useMessage'
import { LIST, QueryField, STRING } from '@/components/Bootx/Query/Query'
import BQuery from '/@/components/Bootx/Query/BQuery.vue'
import { LabeledValue } from 'ant-design-vue/lib/select'
import { useDict } from '@/hooks/bootx/useDict'
// 使用hooks
const {
handleTableChange,
pageQueryResHandel,
resetQueryParams,
sortChange,
pagination,
pages,
sortParam,
model,
loading,
} = useTablePage(queryPage)
const { notification, createMessage } = useMessage()
const { dictDropDown, dictConvert } = useDict()
let tradeTypeList = ref<LabeledValue[]>([])
let diffTypeList = ref<LabeledValue[]>([])
let payChannelList = ref<LabeledValue[]>([])
// 查询条件
const fields = computed(() => {
return [
{ field: 'reconcileNo', type: STRING, name: '对账单号', placeholder: '请输入对账单号' },
{ field: 'title', type: STRING, name: '订单名称', placeholder: '请输入订单名称' },
{
field: 'tradeType',
type: LIST,
name: '交易类型',
placeholder: '请选择交易类型',
selectList: tradeTypeList,
},
{
field: 'diffType',
type: LIST,
name: '差异类型',
placeholder: '请选择差异类型',
selectList: diffTypeList,
},
{
field: 'channel',
type: LIST,
name: '对账通道',
placeholder: '请选择对账',
selectList: payChannelList,
},
{ field: 'tradeNo', type: STRING, name: '本地交易号', placeholder: '请输入本地交易号' },
{ field: 'outOrderNo', type: STRING, name: '通道交易号', placeholder: '请输入通道交易号' },
] as QueryField[]
})
const xTable = ref<VxeTableInstance>()
const xToolbar = ref<VxeToolbarInstance>()
const reconcileDiffInfo = ref<any>()
const payOrderInfo = ref<any>()
const refundOrderInfo = ref<any>()
const reconcileDetailInfo = ref<any>()
nextTick(() => {
xTable?.connect(xToolbar as VxeToolbarInstance)
})
onMounted(() => {
initData()
init()
})
/**
* 初始化基础数据
*/
async function initData() {
tradeTypeList = await dictDropDown('PaymentType')
diffTypeList = await dictDropDown('ReconcileDiffType')
payChannelList = await dictDropDown('PayChannel')
}
/**
* 入口
*/
function init() {
model.queryParam = {}
xTable?.clearSort()
queryPage()
}
/**
* 分页查询
*/
function queryPage() {
loading.value = true
page({
...model.queryParam,
...pages,
...sortParam,
}).then(({ data }) => {
pageQueryResHandel(data)
})
}
/**
* 查看
*/
function show(record) {
reconcileDiffInfo.init(record)
}
/**
* 查看对账单
*/
function showReconcile(record) {
reconcileDiffInfo.init(record)
}
/**
* 查看交易单
*/
function showTrade(record) {
if (record.callbackType === 'pay') {
payOrderInfo.init(record.tradeNo)
} else {
refundOrderInfo.init(record.tradeNo)
}
}
/**
* 查看通道交易信息
*/
function showOutTrade(record) {
reconcileDetailInfo.init(record.outTradeNo)
}
defineExpose({
init,
})
</script>
<style scoped lang="less"></style>

View File

@@ -0,0 +1,111 @@
import { defHttp } from '@/utils/http/axios'
import { PageResult, Result } from '#/axios'
import { MchEntity } from '#/web'
/**
* 任务分页
*/
export function page(params) {
return defHttp.get<Result<PageResult<ReconcileStatement[]>>>({
url: '/reconcile/statement/page',
method: 'get',
params,
})
}
/**
* 获取单条
*/
export function get(id) {
return defHttp.get<Result<ReconcileStatement>>({
url: '/reconcile/statement/findById',
params: { id },
})
}
/**
* 手动创建对账订单
*/
export function create(params: ReconcileCreatParam) {
return defHttp.post<Result<ReconcileStatement>>({
url: '/reconcile/statement/create',
data: params,
})
}
/**
* 手动触发对账文件下载
*/
/**
* 手动触发交易对账单比对
*/
/**
* 对账差异记录
*/
export interface ReconcileStatement extends MchEntity {
/** 对账单ID */
reconcileId?: string
/** 对账号 */
reconcileNo?: string
/** 对账日期 */
reconcileDate?: string
/** 支付通道 */
channel?: string
/** 差异类型 */
discrepancyType?: string
/* 平台侧信息 */
/** 平台交易号 */
TradeNo?: string
/** 商户订单号 */
bizTradeNo?: string
/**
* 交易类型
* @see TradeTypeEnum
*/
tradeType?: string
/** 交易金额 */
tradeAmount?: number
/** 交易状态 */
tradeStatus?: string
/** 交易时间 */
tradeTime?: string
/* 通道侧信息 */
/** 通道交易号 */
channelTradeNo?: string
/** 通道交易类型 */
channelTradeType?: string
/** 通道交易金额 */
channelTradeAmount?: number
/** 通道交易状态 */
channelTradeStatus?: string
/** 通道交易时间 */
channelTradeTime?: string
}
export interface ReconcileCreatParam {
/** 名称 */
name?: string
/** 对账日期 */
reconcileDate?: string
/** 支付通道 */
channel?: string
}

View File

@@ -0,0 +1,11 @@
<script setup lang="ts">
</script>
<template>
</template>
<style scoped lang="less">
</style>