-
-
+
diff --git a/src/views/device/deviceMaintenance/components/listApprovalAdd.vue b/src/views/device/deviceMaintenance/components/listApprovalAdd.vue
index 5b7e7c7..f9c88a4 100644
--- a/src/views/device/deviceMaintenance/components/listApprovalAdd.vue
+++ b/src/views/device/deviceMaintenance/components/listApprovalAdd.vue
@@ -271,7 +271,7 @@
type: 'warning',
},
).then(() => {
- formInline.value.time = formInline.value.checkDate
+ formInline.value.time = formInline.value.checkDate as string
if (pageType.value === 'add') { // 新建
addAcceptanceCheck(formInline.value).then((res) => {
if (res.code === 200) {
diff --git a/src/views/device/deviceMaintenance/components/maintenanceDetail.vue b/src/views/device/deviceMaintenance/components/maintenanceDetail.vue
index 3e0498c..4d35520 100644
--- a/src/views/device/deviceMaintenance/components/maintenanceDetail.vue
+++ b/src/views/device/deviceMaintenance/components/maintenanceDetail.vue
@@ -16,7 +16,9 @@
import addRow from '@/views/device/stateManage/components/selectDevice.vue'
import ApprovalDialog from '@/components/Approval/ApprovalDialog.vue'
import ApprovalRecord from '@/components/ApprovalRecord/ApprovalRecord.vue'
+import useUserStore from '@/store/modules/user'
+const user = useUserStore() // 用户信息
const approvalRecord = ref() // 审批流程组件ref
const infoId = ref('') // id
const from = ref('') // reject代表未通过-驳回
@@ -431,6 +433,12 @@
getInfo()
}
onMounted(async () => {
+ formInline.value.applyName = '设备检修申请' // 申请名称固定
+ formInline.value.applyUnit = user.deptId // 申请单位
+ formInline.value.applyUnitName = user.deptName // 申请单位名称
+ formInline.value.applyPerson = user.id // 申请人
+ formInline.value.applyPersonName = user.name // 申请人名称
+ formInline.value.time = dayjs().format('YYYY-MM-DD HH:mm:ss') // 申请时间
await fetchUserList()
await fetchDeptTreeList()
formInline.value.processId = $route.params.processId as string // 任务id
@@ -475,27 +483,32 @@
-
+
-
-
+
+
-
-
+
+
diff --git a/src/views/device/receive/apply/applyEdit.vue b/src/views/device/receive/apply/applyEdit.vue
index 5e2b089..66427b8 100644
--- a/src/views/device/receive/apply/applyEdit.vue
+++ b/src/views/device/receive/apply/applyEdit.vue
@@ -23,7 +23,9 @@
import { getUserList } from '@/api/system/user'
import { fetchApproval, submitApproval } from '@/api/approval'
import ApprovalRecord from '@/components/ApprovalRecord/ApprovalRecord.vue'
+import useUserStore from '@/store/modules/user'
+const user = useUserStore() // 用户信息
const $route = useRoute()
const approvalDialog = ref() // 审批对话框显隐
const typeValue = ref() // add、edit、detail
@@ -48,9 +50,12 @@
taskId: '', // 任务id(审批用)
id: '',
processId: '', // 流程id--查询审批记录使用
+ applyNo: '', // 申请编号
applyName: '', // 申请名称
applyUnit: '', // 申请单位
+ applyUnitName: '', // 申请单位名称
applyPerson: '', // 申请人
+ applyPersonName: '', // 申请人名称
time: '', // 领用时间
applyDesc: '', // 申请说明
})
@@ -70,8 +75,8 @@
// 表单校验规则
const rules = reactive({
applyName: [{ required: true, message: '申请名称不能为空', trigger: 'blur' }],
- applyUnit: [{ required: true, message: '申请单位不能为空', trigger: 'change' }],
- applyPerson: [{ required: true, message: '申请人不能为空', trigger: 'change' }],
+ applyUnitName: [{ required: true, message: '申请单位不能为空', trigger: 'change' }],
+ applyPersonName: [{ required: true, message: '申请人不能为空', trigger: 'change' }],
time: [{ type: 'date', required: true, message: '领用时间不能为空', trigger: 'change' }],
applyDesc: [{ required: true, message: '申请说明不能为空', trigger: 'blur' }],
})
@@ -221,8 +226,10 @@
const params = {
applyName: form.value.applyName, // 申请名称
applyUnit: form.value.applyUnit, // 申请单位
- processId: form.value.processId,
+ applyUnitName: form.value.applyUnitName, // 申请单位名称
+ processId: form.value.processId, // 流程实例id
applyPerson: form.value.applyPerson, // 申请人
+ applyPersonName: form.value.applyPersonName, // 申请人名称
time: form.value.time, // 领用时间
applyDesc: form.value.applyDesc, // 申请说明
applyType: '1', // 申请类型 领用1
@@ -315,8 +322,11 @@
const fetchReceiveApplyListDetail = () => {
getReceiveApplyListDetail({ id: form.value.id }).then((res) => {
form.value.applyUnit = res.data.applyUnit // 部门
+ form.value.applyUnitName = res.data.applyUnitName || user.deptName // 部门名称
form.value.applyName = res.data.applyName // 申请名称
form.value.applyPerson = res.data.applyPerson// 申请人
+ form.value.applyPersonName = res.data.applyPersonName || user.name// 申请人名称
+ form.value.applyNo = res.data.applyNo// 申请编号
form.value.time = res.data.time // 领用时间
form.value.applyDesc = res.data.applyDesc // 申请说明
list.value = res.data.equipmentInfoList.map((item: IdeviceList) => {
@@ -366,6 +376,12 @@
form.value.processId = $route.query.processId as string // 任务id
approvalStatus.value = $route.query.approvalStatus // 审批类型
approvalStatusName.value = $route.query.approvalStatusName // 审批类型名称
+ form.value.applyName = '设备领用申请' // 申请名称固定
+ form.value.applyUnit = user.deptId // 申请单位
+ form.value.applyUnitName = user.deptName // 申请单位名称
+ form.value.applyPerson = user.id // 申请人
+ form.value.applyPersonName = user.name // 申请人名称
+ form.value.time = dayjs().format('YYYY-MM-DD HH:mm:ss') // 申请时间
// 编辑、详情获取详情页信息
if (typeValue.value === 'edit' || typeValue.value === 'detail') {
fetchReceiveApplyListDetail() // 获取详细信息
@@ -419,29 +435,43 @@
>
-
+
+
+
+
+
+
-
-
+
+
-
-
+
+
diff --git a/src/views/device/standardEquipment/components/listApply/listPage.vue b/src/views/device/standardEquipment/components/listApply/listPage.vue
index 10d6a51..0ebc982 100644
--- a/src/views/device/standardEquipment/components/listApply/listPage.vue
+++ b/src/views/device/standardEquipment/components/listApply/listPage.vue
@@ -34,9 +34,9 @@
default: '', // 审批状态 ‘’代表全部
},
})
-const emit = defineEmits(['setData'])
const { proxy } = getCurrentInstance() as any
-// 关闭
+// 从路由中获取页面类型参数
+const $route = useRoute()
// 查询条件
const listQuery: Ref = ref({
applyUnit: '', // 申请部门
@@ -57,8 +57,6 @@
const useDeptList = ref([])
// 初始化路由
const $router = useRouter()
-// 控制是否显示新增页面
-const show = ref(true)
// 表格数据。
const list = ref([])
// 总数
@@ -334,6 +332,7 @@
// 点击重置
const clearList = () => {
listQuery.value = {
+ applyUnit: '', // 申请部门
applyNo: '', // 申请编号
applyStatus: '', // 申请状态
applyType: props.applyType, // 申请类型
@@ -391,11 +390,11 @@
}
})
if (checkoutList.value.length <= 0 && list.value.length > 0) {
- printJSON(list.value, properties, '标准装置申请列表')
+ printJSON(list.value, properties, `标准装置${$route.meta.title}列表`)
}
else if (checkoutList.value.length > 0) {
const printList = list.value.filter((item: ICheckoutList) => checkoutList.value.includes(item))
- printJSON(printList, properties, '标准装置申请列表')
+ printJSON(printList, properties, `标准装置${$route.meta.title}列表`)
}
else {
ElMessage.warning('无可打印内容')
diff --git a/src/views/device/standardEquipment/components/listApply/listPageAdd.vue b/src/views/device/standardEquipment/components/listApply/listPageAdd.vue
index 12e69ec..4668128 100644
--- a/src/views/device/standardEquipment/components/listApply/listPageAdd.vue
+++ b/src/views/device/standardEquipment/components/listApply/listPageAdd.vue
@@ -1,12 +1,12 @@
-
+
@@ -161,7 +158,12 @@
:list-loading="loadingTable" @change="changePage"
>
-
+
+
+ {{ (listQuery.offset - 1) * listQuery.limit + scope.$index + 1 }}
+
+
+
diff --git a/src/views/device/standardEquipment/components/listApply/userListDialog.vue b/src/views/device/standardEquipment/components/listApply/userListDialog.vue
index cfad14e..795c1c0 100644
--- a/src/views/device/standardEquipment/components/listApply/userListDialog.vue
+++ b/src/views/device/standardEquipment/components/listApply/userListDialog.vue
@@ -119,7 +119,7 @@
-
+
diff --git a/src/views/device/standardEquipment/components/standardList/baseInfo.vue b/src/views/device/standardEquipment/components/standardList/baseInfo.vue
index 59a986f..916397b 100644
--- a/src/views/device/standardEquipment/components/standardList/baseInfo.vue
+++ b/src/views/device/standardEquipment/components/standardList/baseInfo.vue
@@ -1,8 +1,8 @@
-
+