diff --git a/jeecg-boot/db/mes-material-menu.sql b/jeecg-boot/db/mes-material-menu.sql index 62937cd..bf1adc9 100644 --- a/jeecg-boot/db/mes-material-menu.sql +++ b/jeecg-boot/db/mes-material-menu.sql @@ -11,9 +11,9 @@ menu_type=VALUES(menu_type), perms=VALUES(perms), perms_type=VALUES(perms_type), is_route=VALUES(is_route), is_leaf=VALUES(is_leaf), hidden=VALUES(hidden), status=VALUES(status), del_flag=VALUES(del_flag), always_show=VALUES(always_show), keep_alive=VALUES(keep_alive), internal_or_external=VALUES(internal_or_external); --- 二级菜单:物料信息 +-- 二级菜单:胶料信息 INSERT INTO sys_permission(id, parent_id, name, url, component, component_name, menu_type, perms, perms_type, sort_no, is_route, is_leaf, hidden, status, del_flag, keep_alive, internal_or_external, create_by, create_time) -VALUES ('1860000000000000011', '1860000000000000001', '物料信息', '/mes/materialinfo', 'mes/materialinfo/index', 'MesMaterialList', 1, NULL, '1', 1, 1, 1, 0, '1', 0, 1, 0, 'admin', NOW()) +VALUES ('1860000000000000011', '1860000000000000001', '胶料信息', '/mes/materialinfo', 'mes/materialinfo/index', 'MesMaterialList', 1, NULL, '1', 1, 1, 1, 0, '1', 0, 1, 0, 'admin', NOW()) ON DUPLICATE KEY UPDATE parent_id=VALUES(parent_id), name=VALUES(name), url=VALUES(url), component=VALUES(component), component_name=VALUES(component_name), menu_type=VALUES(menu_type), perms=VALUES(perms), perms_type=VALUES(perms_type), sort_no=VALUES(sort_no), diff --git a/jeecg-boot/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mes/material/controller/MesMaterialController.java b/jeecg-boot/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mes/material/controller/MesMaterialController.java index 5273520..ab4090a 100644 --- a/jeecg-boot/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mes/material/controller/MesMaterialController.java +++ b/jeecg-boot/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/mes/material/controller/MesMaterialController.java @@ -22,7 +22,7 @@ import org.springframework.web.bind.annotation.*; import org.springframework.web.servlet.ModelAndView; @Slf4j -@Tag(name = "MES-物料信息") +@Tag(name = "MES-胶料信息") @RestController @RequestMapping("/mes/material/material") public class MesMaterialController extends JeecgController { @@ -39,8 +39,8 @@ public class MesMaterialController extends JeecgController add(@RequestBody MesMaterial model) { @@ -49,8 +49,8 @@ public class MesMaterialController extends JeecgController edit(@RequestBody MesMaterial model) { @@ -59,8 +59,8 @@ public class MesMaterialController extends JeecgController delete(@RequestParam(name = "id") String id) { @@ -72,8 +72,8 @@ public class MesMaterialController extends JeecgController deleteBatch(@RequestParam(name = "ids") String ids) { @@ -94,7 +94,7 @@ public class MesMaterialController extends JeecgController useStatusText(text), + }, + { + title: '是否为特种胶', + align: 'center', + width: 120, + dataIndex: 'isSpecialRubber', + customRender: ({ text }) => specialRubberText(text), + }, ]; export const searchFormSchema: FormSchema[] = [ - { label: '物料编码', field: 'materialCode', component: 'Input', colProps: { span: 6 } }, - { label: '物料名称', field: 'materialName', component: 'Input', colProps: { span: 6 } }, + { label: '胶料名称', field: 'materialName', component: 'Input', colProps: { span: 6 } }, { - label: '分类', + label: '胶料类别', field: 'categoryId', + component: 'ApiSelect', + componentProps: glueCategoryProps, + colProps: { span: 6 }, + }, + { + label: '胶料客户', + field: 'customerId', component: 'JDictSelectTag', - componentProps: { dictCode: 'mes_material_category,category_name,id' }, + componentProps: { dictCode: 'mes_xsl_customer,customer_name,id' }, + colProps: { span: 6 }, + }, + { label: 'ERP编号', field: 'erpCode', component: 'Input', colProps: { span: 6 } }, + { + label: '使用状态', + field: 'enableFlag', + component: 'Select', + componentProps: { options: useStatusOptions }, + colProps: { span: 6 }, + }, + { + label: '是否为特种胶', + field: 'isSpecialRubber', + component: 'Select', + componentProps: { options: specialRubberOptions }, colProps: { span: 6 }, }, ]; export const formSchema: FormSchema[] = [ { label: '', field: 'id', component: 'Input', show: false }, - { label: '物料编码', field: 'materialCode', component: 'Input', required: true }, - { label: '物料名称', field: 'materialName', component: 'Input', required: true }, - { label: '别名', field: 'aliasName', component: 'Input' }, - { label: '简称', field: 'shortName', component: 'Input' }, + { label: '胶料名称', field: 'materialName', component: 'Input', required: true }, { - label: '分类', + label: '胶料类别', field: 'categoryId', - component: 'JDictSelectTag', + component: 'ApiSelect', required: true, - componentProps: { dictCode: 'mes_material_category,category_name,id' }, + componentProps: glueCategoryProps, }, + { label: '胶料别名', field: 'aliasName', component: 'Input' }, { - label: '基础单位', - field: 'baseUnitId', + label: '胶料客户', + field: 'customerId', component: 'JDictSelectTag', - required: true, - componentProps: { dictCode: 'mes_unit,unit_name,id' }, + componentProps: { dictCode: 'mes_xsl_customer,customer_name,id', placeholder: '请选择胶料客户' }, + }, + { label: 'ERP编号', field: 'erpCode', component: 'Input' }, + { + label: '终炼胶保质期(天)', + field: 'finalShelfLifeDays', + component: 'InputNumber', + componentProps: { min: 0, precision: 0 }, }, { - label: '统计单位', - field: 'statUnitId', - component: 'JDictSelectTag', - componentProps: { dictCode: 'mes_unit,unit_name,id' }, + label: '母炼胶保质期(天)', + field: 'masterShelfLifeDays', + component: 'InputNumber', + componentProps: { min: 0, precision: 0 }, }, - { label: '计划价格', field: 'planPrice', component: 'InputNumber' }, - { label: '最小库存', field: 'minStock', component: 'InputNumber' }, - { label: '最大库存', field: 'maxStock', component: 'InputNumber' }, - { label: '换算系数', field: 'unitConvertRate', component: 'InputNumber', defaultValue: 1 }, { - label: '状态', + label: '最小停放时间(时)', + field: 'minStandingHours', + component: 'InputNumber', + componentProps: { min: 0, precision: 0 }, + }, + { + label: '使用状态', field: 'enableFlag', component: 'Select', defaultValue: 1, - componentProps: { - options: [ - { label: '启用', value: 1 }, - { label: '停用', value: 0 }, - ], - }, + componentProps: { options: useStatusOptions }, + }, + { + label: '是否为特种胶', + field: 'isSpecialRubber', + component: 'Select', + defaultValue: 0, + componentProps: { options: specialRubberOptions }, }, - { label: '备注', field: 'remark', component: 'InputTextArea' }, ]; diff --git a/jeecgboot-vue3/src/views/mes/material/MesMaterialList.vue b/jeecgboot-vue3/src/views/mes/material/MesMaterialList.vue index ecbf552..b6c74ff 100644 --- a/jeecgboot-vue3/src/views/mes/material/MesMaterialList.vue +++ b/jeecgboot-vue3/src/views/mes/material/MesMaterialList.vue @@ -33,14 +33,14 @@ import { batchDelete, deleteOne, getExportUrl, getImportUrl, list } from './MesM const [registerModal, { openModal }] = useModal(); const { tableContext, onExportXls, onImportXls } = useListPage({ tableProps: { - title: '物料信息', + title: '胶料信息', api: list, columns, canResize: true, formConfig: { labelWidth: 120, schemas: searchFormSchema, autoSubmitOnEnter: true, showAdvancedButton: true }, actionColumn: { width: 120 }, }, - exportConfig: { name: '物料信息', url: getExportUrl }, + exportConfig: { name: '胶料信息', url: getExportUrl }, importConfig: { url: getImportUrl, success: handleSuccess }, }); const [registerTable, { reload }, { rowSelection, selectedRowKeys }] = tableContext; diff --git a/jeecgboot-vue3/src/views/mes/material/modules/MesMaterialModal.vue b/jeecgboot-vue3/src/views/mes/material/modules/MesMaterialModal.vue index c53c0f1..968a146 100644 --- a/jeecgboot-vue3/src/views/mes/material/modules/MesMaterialModal.vue +++ b/jeecgboot-vue3/src/views/mes/material/modules/MesMaterialModal.vue @@ -30,7 +30,7 @@ const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data setProps({ disabled: !data?.showFooter }); }); -const title = computed(() => (!unref(isUpdate) ? '新增物料' : '编辑物料')); +const title = computed(() => (!unref(isUpdate) ? '新增胶料' : '编辑胶料')); async function handleSubmit() { try {