1. 统一化代码

2. 增加 DocAlert 关联文档
This commit is contained in:
YunaiV
2023-04-05 20:13:35 +08:00
parent bb88e3d77c
commit 4404554cfc
111 changed files with 640 additions and 567 deletions

View File

@ -86,9 +86,9 @@ const message = useMessage() // 消息弹窗
// 列表相关的变量
const [registerTable, { reload, deleteData, exportList }] = useXTable({
allSchemas: allSchemas,
getListApi: AppApi.getAppPageApi,
deleteApi: AppApi.deleteAppApi,
exportListApi: AppApi.exportAppApi
getListApi: AppApi.getAppPage,
deleteApi: AppApi.deleteApp,
exportListApi: AppApi.exportApp
})
// ========== CRUD 相关 ==========
@ -115,14 +115,14 @@ const handleCreate = () => {
const handleUpdate = async (rowId: number) => {
setDialogTile('update')
// 设置数据
const res = await AppApi.getAppApi(rowId)
const res = await AppApi.getApp(rowId)
unref(formRef)?.setValues(res)
}
// 详情操作
const handleDetail = async (rowId: number) => {
setDialogTile('detail')
const res = await AppApi.getAppApi(rowId)
const res = await AppApi.getApp(rowId)
detailData.value = res
}
@ -137,10 +137,10 @@ const submitForm = async () => {
try {
const data = unref(formRef)?.formModel as AppApi.AppVO
if (actionType.value === 'create') {
await AppApi.createAppApi(data)
await AppApi.createApp(data)
message.success(t('common.createSuccess'))
} else {
await AppApi.updateAppApi(data)
await AppApi.updateApp(data)
message.success(t('common.updateSuccess'))
}
dialogVisible.value = false

View File

@ -1,5 +1,5 @@
<template>
<content-wrap>
<ContentWrap>
<!-- 搜索工作栏 -->
<el-form
class="-mb-15px"
@ -77,10 +77,10 @@
</el-button>
</el-form-item>
</el-form>
</content-wrap>
</ContentWrap>
<!-- 列表 -->
<content-wrap>
<ContentWrap>
<el-table v-loading="loading" :data="list">
<el-table-column label="商户编号" align="center" prop="id" />
<el-table-column label="商户号" align="center" prop="no" />
@ -132,7 +132,7 @@
v-model:limit="queryParams.pageSize"
@pagination="getList"
/>
</content-wrap>
</ContentWrap>
<!-- 表单弹窗添加/修改 -->
<MerchantForm ref="formRef" @success="getList" />

View File

@ -49,8 +49,8 @@ const { t } = useI18n() // 国际化
// 列表相关的变量
const [registerTable, { exportList }] = useXTable({
allSchemas: allSchemas,
getListApi: OrderApi.getOrderPageApi,
exportListApi: OrderApi.exportOrderApi
getListApi: OrderApi.getOrderPage,
exportListApi: OrderApi.exportOrder
})
// ========== CRUD 相关 ==========
const actionLoading = ref(false) // 遮罩层
@ -73,7 +73,7 @@ const handleCreate = () => {
// 详情操作
const handleDetail = async (rowId: number) => {
setDialogTile('detail')
const res = await OrderApi.getOrderApi(rowId)
const res = await OrderApi.getOrder(rowId)
detailData.value = res
}
</script>

View File

@ -42,8 +42,8 @@ const { t } = useI18n() // 国际化
// 列表相关的变量
const [registerTable, { exportList }] = useXTable({
allSchemas: allSchemas,
getListApi: RefundApi.getRefundPageApi,
exportListApi: RefundApi.exportRefundApi
getListApi: RefundApi.getRefundPage,
exportListApi: RefundApi.exportRefund
})
// ========== CRUD 相关 ==========
@ -53,7 +53,7 @@ const detailData = ref() // 详情 Ref
// 详情操作
const handleDetail = async (rowId: number) => {
// 设置数据
detailData.value = RefundApi.getRefundApi(rowId)
detailData.value = RefundApi.getRefund(rowId)
dialogVisible.value = true
}
</script>