feat:智能柜流程代码生成

This commit is contained in:
dzc committed 2025-04-14 16:23:36 +08:00
1 parent da26e142b3
commit c75d825ece
3 files changed
+133

No files matched your search

+40
View File
@@ -0,0 +1,40 @@
import request from "/@/utils/request"
export function fetchList(query?: Object) {
return request({
url: "/hard/hard-door-flow/page",
method: "get",
params: query,
})
}
export function addObj(obj?: Object) {
return request({
url: "/hard/hard-door-flow",
method: "post",
data: obj,
})
}
export function getObj(id?: string) {
return request({
url: "/hard/hard-door-flow/" + id,
method: "get",
})
}
export function delObjs(ids?: Object) {
return request({
url: "/hard/hard-door-flow",
method: "delete",
data: ids,
})
}
export function putObj(obj?: Object) {
return request({
url: "/hard/hard-door-flow",
method: "put",
data: obj,
})
}
+92
View File
@@ -0,0 +1,92 @@
<template>
<div class="layout-padding">
<div class="layout-padding-auto layout-padding-view">
<el-row>
<div class="mb8" style="width: 100%">
<right-toolbar
v-model:showSearch="showSearch"
:export="'dzc_hardDoorFlow_export'"
@exportExcel="exportExcel"
class="ml10 mr20"
style="float: right"
@queryTable="getDataList"
></right-toolbar>
</div>
</el-row>
<el-table
:data="state.dataList"
v-loading="state.loading"
border
:cell-style="tableStyle.cellStyle"
:header-cell-style="tableStyle.headerCellStyle"
@selection-change="selectionChangHandle"
@sort-change="sortChangeHandle"
>
<el-table-column type="selection" width="40" align="center" />
<el-table-column type="index" label="#" width="40" />
<el-table-column prop="orderId" label="订单编号" show-overflow-tooltip />
<el-table-column prop="authId" label="授权编号" show-overflow-tooltip />
<el-table-column prop="openEventId" label="开门事件编号" show-overflow-tooltip />
<el-table-column prop="openOutOpenNo" label="商户自定义开门请求号" show-overflow-tooltip />
<el-table-column prop="openCallbackRes" label="开门回调结果" show-overflow-tooltip />
<el-table-column prop="openCallbackTime" label="开门回调时间" show-overflow-tooltip />
<el-table-column prop="videoCallbackRes" label="视频回调结果" show-overflow-tooltip />
<el-table-column prop="videoCallbackTime" label="视频回调时间" show-overflow-tooltip />
<el-table-column prop="skuKsRecogId" label="识别任务唯一ID,用于结果获取,重新发起售后识别" show-overflow-tooltip />
<el-table-column prop="skuSubmitTime" label="sku识别提交时间" show-overflow-tooltip />
<el-table-column prop="skuCallbackRes" label="sku识别回调结果" show-overflow-tooltip />
<el-table-column prop="skuCallbackTime" label="sku识别回调时间" show-overflow-tooltip />
<el-table-column prop="skuDrivingRes" label="sku识别主动获取结果" show-overflow-tooltip />
<el-table-column prop="skuDrivingTime" label="sku识别主动获取时间" show-overflow-tooltip />
<el-table-column label="操作" width="150"> </el-table-column>
</el-table>
<pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" />
</div>
</div>
</template>
<script setup lang="ts" name="systemHardDoorFlow">
import { BasicTableProps, useTable } from "/@/hooks/table"
import * as hardDoorFlow from "/@/api/hard/hard-door-flow"
import { useMessage, useMessageBox } from "/@/hooks/message"
import { useDict } from "/@/hooks/dict"
// 引入组件
// 定义查询字典
// 定义变量内容
// 搜索变量
const queryRef = ref()
const showSearch = ref(true)
// 多选变量
const selectObjs = ref([]) as any
const multiple = ref(true)
const state: BasicTableProps = reactive<BasicTableProps>({
queryForm: {},
pageList: hardDoorFlow.fetchList,
})
// table hook
const { getDataList, currentChangeHandle, sizeChangeHandle, sortChangeHandle, downBlobFile, tableStyle } = useTable(state)
// 清空搜索条件
const resetQuery = () => {
// 清空搜索条件
queryRef.value?.resetFields()
// 清空多选
selectObjs.value = []
getDataList()
}
// 导出excel
const exportExcel = () => {
downBlobFile("/dzc/hardDoorFlow/export", Object.assign(state.queryForm, { ids: selectObjs }), "hardDoorFlow.xlsx")
}
// 多选事件
const selectionChangHandle = (objs: { id: string }[]) => {
selectObjs.value = objs.map(({ id }) => id)
multiple.value = !objs.length
}
</script>
+1
View File
@@ -103,6 +103,7 @@ const form = reactive({
hardId: "",
spuCategoryId: "",
name: "",
cover: "",
pic: "",
specsTaste: "",
specsCapacity: "",