From dc4f763959c803935059c645c1468c5df0caf423 Mon Sep 17 00:00:00 2001 From: liuxiaoxu <1793812695@qq.com> Date: Mon, 28 Oct 2024 13:48:52 +0800 Subject: [PATCH] =?UTF-8?q?[fix]=E5=B7=A5=E7=A8=8B=E7=AE=A1=E7=90=86=20?= =?UTF-8?q?=E7=89=A9=E6=96=99=E4=BF=A1=E6=81=AF=E6=96=B0=E5=A2=9E=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E4=BF=AE=E6=94=B9=E4=B9=8B=E5=89=8D=E6=A0=B9=E6=8D=AE?= =?UTF-8?q?=E6=96=99=E5=8F=B71-9=E5=BC=80=E5=A4=B4=E7=BB=91=E5=AE=9A?= =?UTF-8?q?=E7=89=A9=E6=96=99=E7=B1=BB=E5=9E=8B=E5=92=8C=E5=8A=A0=E5=B7=A5?= =?UTF-8?q?=E6=96=B9=E5=BC=8F=E7=9A=84=E6=96=B9=E6=B3=95=EF=BC=8C=E6=8C=89?= =?UTF-8?q?=E7=85=A7=E6=96=B0=E7=89=88prd=E8=B0=83=E6=95=B4=EF=BC=9A1-4?= =?UTF-8?q?=E5=AF=B9=E5=BA=94=E9=87=87=E8=B4=AD=EF=BC=9B5-6=E5=AF=B9?= =?UTF-8?q?=E5=BA=94=E9=87=87=E8=B4=AD=E3=80=81=E5=A7=94=E5=A4=96=E5=8A=A0?= =?UTF-8?q?=E5=B7=A5=E3=80=81=E5=A7=94=E5=A4=96=E5=8A=A0=E5=B7=A5=E6=88=96?= =?UTF-8?q?=E9=87=87=E8=B4=AD=EF=BC=9B7=E5=AF=B9=E5=BA=94=E7=94=9F?= =?UTF-8?q?=E4=BA=A7=E8=A3=85=E9=85=8D=E3=80=81=E7=94=9F=E4=BA=A7=E5=8A=A0?= =?UTF-8?q?=E5=B7=A5=EF=BC=9B8=E5=AF=B9=E5=BA=94=E7=94=9F=E4=BA=A7?= =?UTF-8?q?=E5=8A=A0=E5=B7=A5=EF=BC=9B9=E5=AF=B9=E5=BA=94=E9=87=87?= =?UTF-8?q?=E8=B4=AD=E3=80=81=E7=94=9F=E4=BA=A7=E5=8A=A0=E5=B7=A5=E3=80=81?= =?UTF-8?q?=E7=94=9F=E4=BA=A7=E8=A3=85=E9=85=8D=E3=80=81=E5=A7=94=E5=A4=96?= =?UTF-8?q?=E5=8A=A0=E5=B7=A5=20=E7=89=A9=E6=96=99=E5=8A=A0=E5=B7=A5?= =?UTF-8?q?=E6=96=B9=E5=BC=8F=E6=96=B0=E5=A2=9E4-=E5=A7=94=E5=A4=96?= =?UTF-8?q?=E5=8A=A0=E5=B7=A5=E6=88=96=E9=87=87=E8=B4=AD=20=E7=89=A9?= =?UTF-8?q?=E6=96=99=E5=AE=9E=E4=BD=93=E7=B1=BB=E7=9A=84=E7=89=A9=E6=96=99?= =?UTF-8?q?=E5=8A=A0=E5=B7=A5=E6=96=B9=E5=BC=8F=E5=AD=97=E6=AE=B5=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E5=A4=87=E6=B3=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/ruoyi/erp/domain/ErpMaterial.java | 2 +- .../resources/templates/erp/material/add.html | 20 +++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpMaterial.java b/ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpMaterial.java index 9c23a9d1..06b8f218 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpMaterial.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpMaterial.java @@ -57,7 +57,7 @@ public class ErpMaterial extends BaseEntity @Excel(name = "物料类型名称",sort = 5) private String materialTypeName; - /** 加工方式 */ + /** 加工方式(0采购、1生产加工、2委外加工、3生产装配、4委外加工或采购) */ @Excel(name = "加工方式",sort = 9,dictType = "processMethod") private String processMethod; diff --git a/ruoyi-admin/src/main/resources/templates/erp/material/add.html b/ruoyi-admin/src/main/resources/templates/erp/material/add.html index 624b9e16..fb8ea3ec 100644 --- a/ruoyi-admin/src/main/resources/templates/erp/material/add.html +++ b/ruoyi-admin/src/main/resources/templates/erp/material/add.html @@ -228,6 +228,8 @@ engineer(); $("#add-process-text").hide(); $("#add-process").hide(); + + //监听物料的料号开头的数字,加工方式和物料类型进行绑定 $("#materialNo").on('input', function (event) { var value = $(this).val(); reloadSelections(); @@ -244,18 +246,28 @@ $processMethodSelect.find('option[value="1"]').remove(); $processMethodSelect.find('option[value="2"]').remove(); $processMethodSelect.find('option[value="3"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '2': materialType = 'bzjgj'; $processMethodSelect.find('option[value="1"]').remove(); $processMethodSelect.find('option[value="2"]').remove(); $processMethodSelect.find('option[value="3"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '3': materialType = 'scy'; + $processMethodSelect.find('option[value="1"]').remove(); + $processMethodSelect.find('option[value="2"]').remove(); + $processMethodSelect.find('option[value="3"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '4': materialType = 'fscy'; + $processMethodSelect.find('option[value="1"]').remove(); + $processMethodSelect.find('option[value="2"]').remove(); + $processMethodSelect.find('option[value="3"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '5': materialType = 'dbmcljgj'; @@ -269,12 +281,20 @@ break; case '7': materialType = 'zhj'; + $processMethodSelect.find('option[value="0"]').remove(); + $processMethodSelect.find('option[value="2"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '8': materialType = 'chcpsb'; + $processMethodSelect.find('option[value="0"]').remove(); + $processMethodSelect.find('option[value="2"]').remove(); + $processMethodSelect.find('option[value="3"]').remove(); + $processMethodSelect.find('option[value="4"]').remove(); break; case '9': materialType = 'qtyflswl'; + $processMethodSelect.find('option[value="4"]').remove(); break; default: materialType = ''; // 默认情况下不设置