From 2c40d0007fa8bfea4d61f94a4fe59af123bc8f19 Mon Sep 17 00:00:00 2001 From: zhc077 <565291854> Date: Fri, 6 Jan 2023 18:56:39 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E5=B7=A5=E4=BD=8D=E8=AE=BE=E5=A4=87?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E4=BF=AE=E6=94=B9=201.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue b/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue index 0299a93c..19ba153a 100644 --- a/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue +++ b/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue @@ -5,8 +5,8 @@ - - + + @@ -79,7 +79,7 @@ export default { { title:'设备编号', align:"center", - dataIndex: 'code' + dataIndex: 'typeCode' }, { title: '名称', From 77f01e81da1d562f90d391d2115cc509920fbabc Mon Sep 17 00:00:00 2001 From: Gitea Date: Sat, 7 Jan 2023 11:10:39 +0800 Subject: [PATCH 2/5] =?UTF-8?q?=E8=AE=A2=E5=8D=95=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E6=89=80=E6=9C=89=E6=A8=A1=E5=9D=97=E4=BB=A5=E5=8F=8A=E5=95=86?= =?UTF-8?q?=E5=93=81=E7=AE=A1=E7=90=86BUG=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../goodsaccessories/GoodsAccessoriesList.vue | 27 +- .../modules/GoodsAccessoriesForm.vue | 249 ++++++++++----- .../modules/GoodsAccessoriesModal.vue | 31 +- .../src/views/goodsfabric/GoodsFabricList.vue | 27 +- .../goodsfabric/modules/GoodsFabricForm.vue | 301 +++++++++++++----- .../goodsfabric/modules/GoodsFabricModal.vue | 31 +- .../src/views/zyorders/ZyOrdersList.vue | 19 ++ .../GoodsAccessoriesController.java | 15 +- .../controller/GoodsFabricController.java | 15 +- .../controller/ZyOrdersController.java | 30 +- 10 files changed, 518 insertions(+), 227 deletions(-) diff --git a/ant-design-vue-jeecg/src/views/goodsaccessories/GoodsAccessoriesList.vue b/ant-design-vue-jeecg/src/views/goodsaccessories/GoodsAccessoriesList.vue index c6817e6c..c856a740 100644 --- a/ant-design-vue-jeecg/src/views/goodsaccessories/GoodsAccessoriesList.vue +++ b/ant-design-vue-jeecg/src/views/goodsaccessories/GoodsAccessoriesList.vue @@ -81,28 +81,18 @@ - 编辑 - + + + 删除 + - - + @@ -197,6 +187,9 @@ } }); }, + valueChange(value) { + if (value) this.loadData() + }, initDictConfig(){ }, getSuperFieldList(){ diff --git a/ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesForm.vue b/ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesForm.vue index 148ff6df..de289f27 100644 --- a/ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesForm.vue +++ b/ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesForm.vue @@ -1,115 +1,188 @@ \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/goodsfabric/GoodsFabricList.vue b/ant-design-vue-jeecg/src/views/goodsfabric/GoodsFabricList.vue index 33991483..f5cb3666 100644 --- a/ant-design-vue-jeecg/src/views/goodsfabric/GoodsFabricList.vue +++ b/ant-design-vue-jeecg/src/views/goodsfabric/GoodsFabricList.vue @@ -81,28 +81,18 @@ - 编辑 - + + + 删除 + - - + @@ -199,6 +189,9 @@ }, initDictConfig(){ }, + valueChange(value) { + if (value) this.loadData() + }, getSuperFieldList(){ let fieldList=[]; fieldList.push({type:'string',value:'goodsId',text:'商品',dictCode:'zy_goods,goods_name,id'}) diff --git a/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricForm.vue b/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricForm.vue index 1ffa010a..878b510d 100644 --- a/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricForm.vue +++ b/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricForm.vue @@ -1,116 +1,243 @@ \ No newline at end of file + + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricModal.vue b/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricModal.vue index e839f0b3..f1ed1ea1 100644 --- a/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricModal.vue +++ b/ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricModal.vue @@ -8,13 +8,14 @@ :okButtonProps="{ class:{'jee-hidden': disableSubmit} }" @cancel="handleCancel" cancelText="关闭"> - + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/zyorders/ZyOrdersList.vue b/ant-design-vue-jeecg/src/views/zyorders/ZyOrdersList.vue index 40d3efa2..a47256a5 100644 --- a/ant-design-vue-jeecg/src/views/zyorders/ZyOrdersList.vue +++ b/ant-design-vue-jeecg/src/views/zyorders/ZyOrdersList.vue @@ -139,6 +139,8 @@ 拆单 + 生产 + 编辑 详情 @@ -374,6 +376,7 @@ exportXlsUrl: "/zyorders/zyOrders/exportXls", importExcelUrl: "zyorders/zyOrders/importExcel", chaidan:"/zyorders/zyOrders/chaidan", + shengchan:"zyorders/zyOrders/shengchan", }, dictOptions:{}, @@ -405,6 +408,22 @@ this.$message.warning("该订单为子单,不可进行拆单!"); } }, + shengchan(record){ + console.log(record) + if(record.goodsQuantity===1&&record.deliveryStatus===1){ + getAction(this.url.shengchan,{id:record.id}).then((res) => { + if (res.success) { + this.$message.success("生产成功!"); + this.loadData(); + }else{ + this.$message.error(res.message); + } + }) + }else{ + this.$message.warning("该订单不可生产!"); + } + + }, getPcaText(code){ return this.pcaData.getText(code); }, diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsaccessories/controller/GoodsAccessoriesController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsaccessories/controller/GoodsAccessoriesController.java index 75b400f5..3fe266ad 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsaccessories/controller/GoodsAccessoriesController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsaccessories/controller/GoodsAccessoriesController.java @@ -82,8 +82,19 @@ public class GoodsAccessoriesController extends JeecgController add(@RequestBody GoodsAccessories goodsAccessories) { - goodsAccessoriesService.save(goodsAccessories); + public Result add(@RequestBody GoodsAccessories goodsAccessories,HttpServletRequest req) { + String[] split = goodsAccessories.getAccessoriesId().split(","); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(goodsAccessories, req.getParameterMap()); + queryWrapper.eq("goods_id",goodsAccessories.getGoodsId()); + for (String s : split) { + goodsAccessories.setAccessoriesId(s); + goodsAccessories.setId(null); + queryWrapper.eq("accessories_id", goodsAccessories.getAccessoriesId()); + int a = goodsAccessoriesService.count(queryWrapper); + if (a >= 1) + return Result.error("存在已添加过的数据!"); + goodsAccessoriesService.save(goodsAccessories); + } return Result.OK("添加成功!"); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsfabric/controller/GoodsFabricController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsfabric/controller/GoodsFabricController.java index ccdd9de1..385a140a 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsfabric/controller/GoodsFabricController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsfabric/controller/GoodsFabricController.java @@ -82,8 +82,19 @@ public class GoodsFabricController extends JeecgController add(@RequestBody GoodsFabric goodsFabric) { - goodsFabricService.save(goodsFabric); + public Result add(@RequestBody GoodsFabric goodsFabric,HttpServletRequest req) { + String[] split = goodsFabric.getFabricId().split(","); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(goodsFabric, req.getParameterMap()); + queryWrapper.eq("goods_id",goodsFabric.getGoodsId()); + for (String s : split) { + goodsFabric.setFabricId(s); + goodsFabric.setId(null); + queryWrapper.eq("fabric_id", goodsFabric.getFabricId()); + int a = goodsFabricService.count(queryWrapper); + if (a >= 1) + return Result.error("存在已添加过的数据!"); + goodsFabricService.save(goodsFabric); + } return Result.OK("添加成功!"); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyorders/controller/ZyOrdersController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyorders/controller/ZyOrdersController.java index 58349ca7..ebb6cc66 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyorders/controller/ZyOrdersController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyorders/controller/ZyOrdersController.java @@ -133,21 +133,39 @@ public class ZyOrdersController extends JeecgController queryById(@RequestParam(name="id",required=true) String id) { + @AutoLog(value = "生产") + @ApiOperation(value="生产", notes="生产") + @GetMapping(value = "/shengchan") + public Result shengchan(@RequestParam(name="id",required=true) String id) { ZyOrders zyOrders = zyOrdersService.getById(id); if(zyOrders==null) { return Result.error("未找到对应数据"); } - return Result.OK(zyOrders); + zyOrders.setDeliveryStatus(2); + zyOrdersService.updateById(zyOrders); + return Result.OK("成功"); } + /** + * 通过id查询 + * + * @param id + * @return + */ + @AutoLog(value = "订单基本信息管理-通过id查询") + @ApiOperation(value="订单基本信息管理-通过id查询", notes="订单基本信息管理-通过id查询") + @GetMapping(value = "/queryById") + public Result queryById(@RequestParam(name="id",required=true) String id) { + ZyOrders zyOrders = zyOrdersService.getById(id); + if(zyOrders==null) { + return Result.error("未找到对应数据"); + } + return Result.OK(zyOrders); + } /** * 生成订单编号 * From 357bfb40434b023db6abbd4234656f4b4f1908f4 Mon Sep 17 00:00:00 2001 From: mors <3067699729@qq.com> Date: Sat, 7 Jan 2023 11:52:39 +0800 Subject: [PATCH 3/5] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=A7=E5=93=81?= =?UTF-8?q?=E7=AE=A1=E7=90=86=20=E4=BA=A7=E5=93=81=E6=A8=A1=E5=9D=97=20?= =?UTF-8?q?=E6=A0=B7=E6=9D=BF=E7=AE=A1=E7=90=86=E9=83=A8=E5=88=86=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productModule/ProductModuleList.vue | 40 ++- .../productSample/ProductSampleList.vue | 305 ++++++++++++++++++ .../modules/ZyClothSampleDetail.vue | 125 +++++++ .../modules/ZyClothSampleForm.vue | 229 +++++++++++++ .../modules/ZyClothSampleModal.vue | 60 ++++ .../ZyClothSampleModal__Style#Drawer.vue | 84 +++++ .../views/zystylemodel/ZyStyleModelList.vue | 27 +- 7 files changed, 836 insertions(+), 34 deletions(-) create mode 100644 ant-design-vue-jeecg/src/views/product/productSample/ProductSampleList.vue create mode 100644 ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleDetail.vue create mode 100644 ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleForm.vue create mode 100644 ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal.vue create mode 100644 ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal__Style#Drawer.vue diff --git a/ant-design-vue-jeecg/src/views/product/productModule/ProductModuleList.vue b/ant-design-vue-jeecg/src/views/product/productModule/ProductModuleList.vue index cc9623c8..fbce5ab8 100644 --- a/ant-design-vue-jeecg/src/views/product/productModule/ProductModuleList.vue +++ b/ant-design-vue-jeecg/src/views/product/productModule/ProductModuleList.vue @@ -17,13 +17,13 @@ 导入 - - - - 删除 - - 批量操作 - + + + + + + + @@ -69,21 +69,12 @@ 编辑 - - - 更多 - - - 详情 - - - - 删除 - - - - + 详情 + + + 删除 + @@ -141,6 +132,11 @@ align:"center", dataIndex: 'place' }, + { + title: '创建时间', + align: "center", + dataIndex: 'createTime' + }, { title: '操作', dataIndex: 'action', @@ -156,7 +152,7 @@ deleteBatch: "/productModule/productModule/deleteBatch", exportXlsUrl: "/productModule/productModule/exportXls", importExcelUrl: "productModule/productModule/importExcel", - + }, dictOptions:{}, superFieldList:[], diff --git a/ant-design-vue-jeecg/src/views/product/productSample/ProductSampleList.vue b/ant-design-vue-jeecg/src/views/product/productSample/ProductSampleList.vue new file mode 100644 index 00000000..33d6fea1 --- /dev/null +++ b/ant-design-vue-jeecg/src/views/product/productSample/ProductSampleList.vue @@ -0,0 +1,305 @@ + + + + + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleDetail.vue b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleDetail.vue new file mode 100644 index 00000000..1d3afeab --- /dev/null +++ b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleDetail.vue @@ -0,0 +1,125 @@ + + + diff --git a/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleForm.vue b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleForm.vue new file mode 100644 index 00000000..af0d52be --- /dev/null +++ b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleForm.vue @@ -0,0 +1,229 @@ + + + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal.vue b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal.vue new file mode 100644 index 00000000..39aa49bf --- /dev/null +++ b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal.vue @@ -0,0 +1,60 @@ + + + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal__Style#Drawer.vue b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal__Style#Drawer.vue new file mode 100644 index 00000000..407f7ab2 --- /dev/null +++ b/ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal__Style#Drawer.vue @@ -0,0 +1,84 @@ + + + + + \ No newline at end of file diff --git a/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue b/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue index b82a502c..c2cc0ee3 100644 --- a/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue +++ b/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue @@ -118,7 +118,7 @@ export default { columns: [ { title: '服装款式', - width: '150px', + width: '110px', fixed: 'left', key: 'styleId', type: JVXETypes.select, @@ -132,17 +132,17 @@ export default { { title: '是否默认尺码', align: "center", - width: '50px', + width: '130px', key: 'isdefault', type: JVXETypes.select, dictCode: 'isdefault', defaultValue: 0, }, - {key: 'modelNumber', title: '型号编码', dictCode: 'modenumber', width: '120px', type: JVXETypes.select}, - {key: 'size', title: '码数', width: '90px', dictCode: 'size', type: JVXETypes.select}, - {key: 'anumbers', title: '型', width: '80px', dictCode: 'hsize', type: JVXETypes.select}, - {key: 'bnumbers', title: '号', width: '80px', dictCode: 'xsize', type: JVXETypes.select}, - {key: 'collarLarge', title: '领大', width: '80px', type: JVXETypes.input}, + {key: 'modelNumber', title: '型号编码', dictCode: 'modenumber', width: '100px', type: JVXETypes.select}, + {key: 'size', title: '码数', width: '85px', dictCode: 'size', type: JVXETypes.select}, + {key: 'anumbers', title: '型', width: '85px', dictCode: 'hsize', type: JVXETypes.select}, + {key: 'bnumbers', title: '号', width: '85px', dictCode: 'xsize', type: JVXETypes.select}, + {key: 'collarLarge', title: '领大', width: '70px', type: JVXETypes.input}, {key: 'bust', title: '胸围', width: '80px', type: JVXETypes.input}, {key: 'sleeveLength', title: '袖长', width: '80px', type: JVXETypes.input}, {key: 'shslLength', title: '连肩袖长', width: '100px', type: JVXETypes.input}, @@ -151,14 +151,14 @@ export default { {key: 'cuff', title: '袖口', width: '80px', type: JVXETypes.input}, {key: 'waistline', title: '腰围', width: '80px', type: JVXETypes.input}, {key: 'hem', title: '下摆', width: '80px', type: JVXETypes.input}, - {key: 'createTime', title: '创建时间', width: '100px', type: JVXETypes.datetime}, + {key: 'createTime', title: '创建时间', width: '60px', type: JVXETypes.datetime}, { title: '操作', key: 'action', type: JVXETypes.slot, fixed: 'right', - minWidth: '80px', + minWidth: '100px', align: 'center', slotName: 'action', } @@ -203,18 +203,21 @@ export default { let method = 'post'; //httpUrl += this.url.add; //method = 'post'; + let that = this; httpAction(httpUrl, event.row, method).then((res) => { if (res.success) { - this.$message.success(res.message); + that.reCalculatePage(1); + that.$message.success(res.message); this.$emit('ok'); + that.loadData(); } else { this.$message.warning(res.message); } }) }, - //数据发生变化时事件 + //数据发生变化时事件 即 编辑 handleValueChange(event) { - + //this.submitForm(event) console.log("//数据发生变化时事件", event); //const str = event.row.id; From 038bf7dfb87a8efaa7b834fec220c3fc47327dc8 Mon Sep 17 00:00:00 2001 From: zhc077 <565291854> Date: Sat, 7 Jan 2023 11:53:05 +0800 Subject: [PATCH 4/5] =?UTF-8?q?=E5=B7=A5=E4=BD=8D=E8=AE=BE=E5=A4=87?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E4=BF=AE=E6=94=B9=201.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/device/ZyDeviceListRef.vue | 6 +++--- .../src/views/team/StationMachineList.vue | 2 +- .../src/views/team/StationToolList.vue | 4 ++-- .../team/controller/StationMachineController.java | 7 +++++++ .../team/controller/StationToolController.java | 15 ++++++++++++--- .../jeecg/modules/team/entity/StationMachine.java | 5 +++++ .../jeecg/modules/team/entity/StationTool.java | 5 +++++ 7 files changed, 35 insertions(+), 9 deletions(-) diff --git a/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue b/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue index 19ba153a..f05a7621 100644 --- a/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue +++ b/ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue @@ -5,8 +5,8 @@ - - + + @@ -79,7 +79,7 @@ export default { { title:'设备编号', align:"center", - dataIndex: 'typeCode' + dataIndex: 'code' }, { title: '名称', diff --git a/ant-design-vue-jeecg/src/views/team/StationMachineList.vue b/ant-design-vue-jeecg/src/views/team/StationMachineList.vue index 8bff2842..ed14de28 100644 --- a/ant-design-vue-jeecg/src/views/team/StationMachineList.vue +++ b/ant-design-vue-jeecg/src/views/team/StationMachineList.vue @@ -149,7 +149,7 @@ export default { { title: '设备编号', align: "center", - dataIndex: 'machineId' + dataIndex: 'code' }, { title: '设备名称', diff --git a/ant-design-vue-jeecg/src/views/team/StationToolList.vue b/ant-design-vue-jeecg/src/views/team/StationToolList.vue index 7aa6b5fb..ef038d48 100644 --- a/ant-design-vue-jeecg/src/views/team/StationToolList.vue +++ b/ant-design-vue-jeecg/src/views/team/StationToolList.vue @@ -145,9 +145,9 @@ export default { dataIndex: 'stationName', }, { - title: '工具编号', + title: '工具编码', align: "center", - dataIndex: 'toolsId' + dataIndex: 'nums' }, { title: '工具名称', diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java index b20ec41d..a43a0458 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java @@ -66,6 +66,13 @@ public class StationMachineController extends JeecgController queryWrapper = QueryGenerator.initQueryWrapper(stationMachine, req.getParameterMap()); Page page = new Page(pageNo, pageSize); IPage pageList = stationMachineService.page(page, queryWrapper); + List records = pageList.getRecords(); + if (!ObjectUtils.isEmpty(records)) { + records.forEach(e -> { + ZyDevice zyDevice = iZyDeviceService.getById(e.getMachineId()); + e.setCode(StringUtils.isNotBlank(zyDevice.getCode()) ? zyDevice.getCode() : ""); + }); + } return Result.OK(pageList); } diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java index 24865124..80a49783 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java @@ -15,7 +15,9 @@ import org.jeecg.common.system.base.controller.JeecgController; import org.jeecg.common.system.query.QueryGenerator; import org.jeecg.modules.demo.tool.entity.ZyTool; import org.jeecg.modules.demo.tool.service.IZyToolService; +import org.jeecg.modules.device.entity.ZyDevice; import org.jeecg.modules.device.service.IZyDeviceService; +import org.jeecg.modules.team.entity.StationMachine; import org.jeecg.modules.team.entity.StationTool; import org.jeecg.modules.team.service.IStationToolService; import org.jeecg.modules.team.vo.StationToolVo; @@ -69,6 +71,13 @@ public class StationToolController extends JeecgController queryWrapper = QueryGenerator.initQueryWrapper(stationTool, req.getParameterMap()); Page page = new Page(pageNo, pageSize); IPage pageList = stationToolService.page(page, queryWrapper); + List records = pageList.getRecords(); + if (!ObjectUtils.isEmpty(records)) { + records.forEach(e -> { + ZyTool zyTool = iZyToolService.getById(e.getToolsId()); + e.setNums(StringUtils.isNotBlank(zyTool.getNums()) ? zyTool.getNums() : ""); + }); + } return Result.OK(pageList); } @@ -77,14 +86,14 @@ public class StationToolController extends JeecgController list2(StationTool stationTool, // @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, // @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, - HttpServletRequest req) { + HttpServletRequest req) { // QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(stationTool, req.getParameterMap()); // Page page = new Page(pageNo, pageSize); // IPage pageList = stationToolService.page(page, queryWrapper); List voList = new LinkedList<>(); List toolList = stationToolService.list(new LambdaQueryWrapper().eq(StationTool::getStationId, stationTool.getStationId())); - if(!ObjectUtils.isEmpty(toolList)){ - toolList.forEach(en->{ + if (!ObjectUtils.isEmpty(toolList)) { + toolList.forEach(en -> { StationToolVo stationVo = new StationToolVo(); stationVo.setId(en.getToolsId()); stationVo.setValue(en.getToolsId()); diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java index 6f12feaa..9412d07e 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java @@ -1,6 +1,7 @@ package org.jeecg.modules.team.entity; import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import com.fasterxml.jackson.annotation.JsonFormat; @@ -47,6 +48,10 @@ public class StationMachine { @ApiModelProperty(value = "设备id,uuid,FK,设备表") @Dict(dictTable = "zy_device", dicText = "name", dicCode = "id") private String machineId; + + @TableField(exist = false) + @ApiModelProperty(value = "设备编码") + private String code; /** * 创建日期 */ diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationTool.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationTool.java index 2e93af62..32f68688 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationTool.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationTool.java @@ -1,6 +1,7 @@ package org.jeecg.modules.team.entity; import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import com.fasterxml.jackson.annotation.JsonFormat; @@ -47,6 +48,10 @@ public class StationTool { @ApiModelProperty(value = "工具id,uuid,FK,工具表") @Dict(dictTable = "zy_tool", dicText = "name", dicCode = "id") private String toolsId; + + @TableField(exist = false) + @ApiModelProperty(value = "工具编码") + private String nums; /** * 创建日期 */ From 06b1f1f262d456a6874b024dd9641655663da0fe Mon Sep 17 00:00:00 2001 From: mors <3067699729@qq.com> Date: Sat, 7 Jan 2023 16:08:51 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=A7=E5=93=81?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E9=83=A8=E5=88=86=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/zystylemodel/ZyStyleModelList.vue | 2 +- .../org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue b/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue index c2cc0ee3..5f9de618 100644 --- a/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue +++ b/ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue @@ -217,7 +217,7 @@ export default { }, //数据发生变化时事件 即 编辑 handleValueChange(event) { - + //this.submitForm(event) console.log("//数据发生变化时事件", event); //const str = event.row.id; diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java index 9d8a5be8..8398c789 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java @@ -112,5 +112,11 @@ public class ZyStyleModel implements Serializable { @ApiModelProperty(value = "创建时间") private java.util.Date createTime; + /**更新时间*/ + @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss") + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + @ApiModelProperty(value = "更新时间") + private java.util.Date updateTime; + }