no message

main
HUOJIN\92525 2025-11-14 13:35:53 +08:00
parent 3aa23d97f5
commit cfb4aaf5a4
3 changed files with 66 additions and 78 deletions

View File

@ -4,11 +4,6 @@
<template #detail> <template #detail>
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="AgvTaskForm"> <a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="AgvTaskForm">
<a-row> <a-row>
<a-col :span="24">
<a-form-item label="任务ID" v-bind="validateInfos.id" v-if="formData.id" id="AgvTaskForm-id" name="id">
<a-input v-model:value="formData.id" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="容器" v-bind="validateInfos.carrierCode" id="AgvTaskForm-carrierCode" name="carrierCode"> <a-form-item label="容器" v-bind="validateInfos.carrierCode" id="AgvTaskForm-carrierCode" name="carrierCode">
<JDictSelectTag v-model:value="formData.carrierCode" placeholder="请选择容器" dictCode="base_stock where iz_active=1 and del_flag=0,stock_code,stock_code" allowClear /> <JDictSelectTag v-model:value="formData.carrierCode" placeholder="请选择容器" dictCode="base_stock where iz_active=1 and del_flag=0,stock_code,stock_code" allowClear />
@ -95,7 +90,7 @@
priority: 99, priority: 99,
startCode: '', startCode: '',
endCode: '', endCode: '',
resMessage: '', agvVendor:'HIK',
tenantId: tenantId, tenantId: tenantId,
}); });
const { createMessage } = useMessage(); const { createMessage } = useMessage();

View File

@ -4,14 +4,14 @@
<template #detail> <template #detail>
<a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="AgvTaskForm"> <a-form ref="formRef" class="antd-modal-form" :labelCol="labelCol" :wrapperCol="wrapperCol" name="AgvTaskForm">
<a-row> <a-row>
<a-col :span="24">
<a-form-item label="任务ID" v-bind="validateInfos.id" v-if="formData.id" id="AgvTaskForm-id" name="id">
<a-input v-model:value="formData.id" allow-clear ></a-input>
</a-form-item>
</a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="容器" v-bind="validateInfos.carrierCode" id="AgvTaskForm-carrierCode" name="carrierCode"> <a-form-item label="容器" v-bind="validateInfos.carrierCode" id="AgvTaskForm-carrierCode" name="carrierCode">
<JDictSelectTag v-model:value="formData.carrierCode" placeholder="请选择容器" dictCode="base_stock where iz_active=1 and del_flag=0,stock_code,stock_code" allowClear /> <JDictSelectTag
v-model:value="formData.carrierCode"
placeholder="请选择容器"
dictCode="base_stock where iz_active=1 and del_flag=0,stock_code,stock_code"
allowClear
/>
</a-form-item> </a-form-item>
</a-col> </a-col>
<!-- <a-col :span="24"> <!-- <a-col :span="24">
@ -21,22 +21,12 @@
</a-col>--> </a-col>-->
<a-col :span="24"> <a-col :span="24">
<a-form-item label="业务类型" v-bind="validateInfos.type" id="AgvTaskForm-type" name="type"> <a-form-item label="业务类型" v-bind="validateInfos.type" id="AgvTaskForm-type" name="type">
<JDictSelectTag <JDictSelectTag type="select" v-model:value="formData.type" dictCode="business_type" placeholder="请选择业务类型" />
type="select"
v-model:value="formData.type"
dictCode="business_type"
placeholder="请选择业务类型"
/>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="任务状态" v-bind="validateInfos.status" id="AgvTaskForm-status" name="status"> <a-form-item label="任务状态" v-bind="validateInfos.status" id="AgvTaskForm-status" name="status">
<JDictSelectTag <JDictSelectTag type="select" v-model:value="formData.status" dictCode="agv_task_status" placeholder="请选择任务状态" />
type="select"
v-model:value="formData.status"
dictCode="agv_task_status"
placeholder="请选择任务状态"
/>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
@ -46,7 +36,12 @@
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="目标库位" v-bind="validateInfos.endCode" id="AgvTaskForm-endCode" name="endCode"> <a-form-item label="目标库位" v-bind="validateInfos.endCode" id="AgvTaskForm-endCode" name="endCode">
<JDictSelectTag v-model:value="formData.endCode" placeholder="请选择目标库位" dictCode="base_point where iz_active=1 and del_flag=0 ,point_code,point_code" allowClear /> <JDictSelectTag
v-model:value="formData.endCode"
placeholder="请选择目标库位"
dictCode="base_point where iz_active=1 and del_flag=0 ,point_code,point_code"
allowClear
/>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
@ -70,10 +65,11 @@
import { Form } from 'ant-design-vue'; import { Form } from 'ant-design-vue';
import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue'; import JFormContainer from '/@/components/Form/src/container/JFormContainer.vue';
import { JDictSelectTag } from '@/components/Form'; import { JDictSelectTag } from '@/components/Form';
const props = defineProps({ const props = defineProps({
formDisabled: { type: Boolean, default: false }, formDisabled: { type: Boolean, default: false },
formData: { type: Object, default: () => ({}) }, formData: { type: Object, default: () => ({}) },
formBpm: { type: Boolean, default: true } formBpm: { type: Boolean, default: true },
}); });
const formRef = ref(); const formRef = ref();
const useForm = Form.useForm; const useForm = Form.useForm;
@ -90,7 +86,7 @@
priority: 3, priority: 3,
startCode: '', startCode: '',
endCode: '', endCode: '',
resMessage: '', agvVendor: 'TES',
tenantId: tenantId, tenantId: tenantId,
}); });
const { createMessage } = useMessage(); const { createMessage } = useMessage();
@ -99,16 +95,15 @@
const confirmLoading = ref<boolean>(false); const confirmLoading = ref<boolean>(false);
// //
const validatorRules = reactive({ const validatorRules = reactive({
carrierCode: [{ required: true, message: '请选择容器!'},], carrierCode: [{ required: true, message: '请选择容器!' }],
type: [{ required: true, message: '请选择业务类型!'},], type: [{ required: true, message: '请选择业务类型!' }],
priority: [{ required: true, message: '请输入优先级!'},], priority: [{ required: true, message: '请输入优先级!' }],
endCode: [{ required: true, message: '请选择目标库位!'},], endCode: [{ required: true, message: '请选择目标库位!' }],
status: [{ required: true, message: '请选择任务状态!'},] status: [{ required: true, message: '请选择任务状态!' }],
}); });
const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false }); const { resetFields, validate, validateInfos } = useForm(formData, validatorRules, { immediate: false });
// //
const fieldPickers = reactive({ const fieldPickers = reactive({});
});
// //
const disabled = computed(() => { const disabled = computed(() => {
@ -122,7 +117,6 @@
return props.formDisabled; return props.formDisabled;
}); });
/** /**
* 新增 * 新增
*/ */
@ -139,9 +133,9 @@
const tmpData = {}; const tmpData = {};
Object.keys(formData).forEach((key) => { Object.keys(formData).forEach((key) => {
if (record.hasOwnProperty(key)) { if (record.hasOwnProperty(key)) {
tmpData[key] = record[key] tmpData[key] = record[key];
} }
}) });
// //
Object.assign(formData, tmpData); Object.assign(formData, tmpData);
}); });
@ -197,7 +191,6 @@
}); });
} }
defineExpose({ defineExpose({
add, add,
edit, edit,

View File

@ -33,18 +33,18 @@
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="排" v-bind="validateInfos.row" id="PointForm-row" name="row"> <a-form-item label="排" v-bind="validateInfos.rows" id="PointForm-rows" name="rows">
<a-input v-model:value="formData.row" placeholder="请输入排" allow-clear></a-input> <a-input v-model:value="formData.rows" placeholder="请输入排" allow-clear></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="列" v-bind="validateInfos.col" id="PointForm-col" name="col"> <a-form-item label="列" v-bind="validateInfos.cols" id="PointForm-cols" name="cols">
<a-input v-model:value="formData.col" placeholder="请输入列" allow-clear></a-input> <a-input v-model:value="formData.cols" placeholder="请输入列" allow-clear></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-item label="层" v-bind="validateInfos.layer" id="PointForm-layer" name="layer"> <a-form-item label="层" v-bind="validateInfos.layers" id="PointForm-layers" name="layers">
<a-input v-model:value="formData.layer" placeholder="请输入层" allow-clear></a-input> <a-input v-model:value="formData.layers" placeholder="请输入层" allow-clear></a-input>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
@ -87,12 +87,12 @@
let tenantId = getTenantId(); let tenantId = getTenantId();
const formData = reactive<Record<string, any>>({ const formData = reactive<Record<string, any>>({
id: '', id: '',
areaId: undefined, areaId: '',
pointCode: '', pointCode: '',
status: 0, status: 0,
row: '00', rows: '00',
col: '00', cols: '00',
layer: '00', layers: '00',
description: '', description: '',
delFlag: 0, delFlag: 0,
izActive: 1, izActive: 1,