diff --git a/ant-design-vue-jeecg/src/views/process/ZyClothsComponentList.vue b/ant-design-vue-jeecg/src/views/process/ZyClothsComponentList.vue
index 8aaf926c..2aa9d775 100644
--- a/ant-design-vue-jeecg/src/views/process/ZyClothsComponentList.vue
+++ b/ant-design-vue-jeecg/src/views/process/ZyClothsComponentList.vue
@@ -4,6 +4,34 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 查询
+ 重置
+
+
@@ -175,16 +203,16 @@ export default {
dataIndex: 'pictureUrl',
scopedSlots: {customRender: 'imgSlot'}
},
+ // {
+ // title: '模块',
+ // align: "center",
+ // dataIndex: 'modularId_dictText'
+ // },
{
- title: '模块',
+ title: '模块类型',
align: "center",
- dataIndex: 'modularId_dictText'
+ dataIndex: 'modularType_dictText'
},
- // {
- // title:'制衣模块类型',
- // align:"center",
- // dataIndex: 'modularType_dictText'
- // },
{
title: '企业',
align: "center",
diff --git a/ant-design-vue-jeecg/src/views/process/ZyProcessComponentList.vue b/ant-design-vue-jeecg/src/views/process/ZyProcessComponentList.vue
index 2cf1093e..3394ba02 100644
--- a/ant-design-vue-jeecg/src/views/process/ZyProcessComponentList.vue
+++ b/ant-design-vue-jeecg/src/views/process/ZyProcessComponentList.vue
@@ -142,7 +142,7 @@
}
},
{
- title:'部件',
+ title:'部件名称',
align:"center",
dataIndex: 'componentId_dictText'
},
diff --git a/ant-design-vue-jeecg/src/views/process/modules/ZyClothsComponentForm.vue b/ant-design-vue-jeecg/src/views/process/modules/ZyClothsComponentForm.vue
index dc5f966a..37cf61df 100644
--- a/ant-design-vue-jeecg/src/views/process/modules/ZyClothsComponentForm.vue
+++ b/ant-design-vue-jeecg/src/views/process/modules/ZyClothsComponentForm.vue
@@ -11,9 +11,17 @@
-
-
-
+
+
+
+
+
+
+
@@ -30,6 +38,16 @@
+
+
+
+
+
+
+
+
+
@@ -86,11 +104,7 @@
-
-
-
-
-
+
@@ -107,10 +121,12 @@
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
+ import JTreeSelect from '@/components/jeecg/JTreeSelect'
export default {
name: 'ZyClothsComponentForm',
components: {
+ JTreeSelect
},
props: {
//表单禁用
@@ -123,6 +139,7 @@
data () {
return {
model:{
+ nums: '',
},
labelCol: {
xs: { span: 24 },
@@ -138,14 +155,14 @@
// { required: true, message: '请输入编号!'},
// ],
clothsTypeId: [
- { required: true, message: '请选择服装类型!'},
+ { required: true, message: '请选择服装类型!'},
],
partsName: [
{ required: true, message: '请输入部件名称!'},
],
- modularId: [
- { required: true, message: '请选择模块!'},
- ],
+ // modularId: [
+ // { required: true, message: '请选择模块!'},
+ // ],
modularType: [
{ required: true, message: '请选择制衣模块类型!'},
],
@@ -154,7 +171,9 @@
url: {
add: "/base/zyClothsComponent/add",
edit: "/base/zyClothsComponent/edit",
- queryById: "/base/zyClothsComponent/queryById"
+ queryById: "/base/zyClothsComponent/queryById",
+ //编号
+ sort: "/base/zyClothsComponent/sort"
}
}
},
@@ -168,8 +187,35 @@
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
+ async getNumberClothsComponentList() {
+ const {data: res} = await this.$axios.get('/jeecg-boot/base/zyClothsComponent/sort?id=' + this.model.clothsTypeId)
+ if (res.code !== 200) {
+ this.$message({
+ type: 'error',
+ message: '未查询到数据!'
+ });
+ }
+ this.model.nums = res.result
+ console.log('res.result')
+ console.log(res.result)
+ //this.confirmLoading = false
+ // if (this.data.length === 0) {
+ // this.data.push(res.result)
+ // }
+
+ console.log("制衣部件List 编号 "+this.model.nums);
+ },
+ // bianHao() {
+ // getAction(this.url.sort, {id: this.model.clothsTypeId}).then((res) => {
+ // let number = res.result;
+ // console.log("制衣部件List id " + this.model.clothsTypeId)
+ // console.log("制衣部件List 编号 " +number)
+ // this.model.nums = number;
+ // })
+ // },
add () {
this.edit(this.modelDefault);
+
},
edit (record) {
this.model = Object.assign({}, record);
diff --git a/ant-design-vue-jeecg/src/views/process/modules/ZyProcessComponentForm.vue b/ant-design-vue-jeecg/src/views/process/modules/ZyProcessComponentForm.vue
index 55a576ee..4d3e3cf6 100644
--- a/ant-design-vue-jeecg/src/views/process/modules/ZyProcessComponentForm.vue
+++ b/ant-design-vue-jeecg/src/views/process/modules/ZyProcessComponentForm.vue
@@ -4,7 +4,7 @@
-
+
@@ -45,6 +45,7 @@
return {
model:{
componentId: '',
+ bottleneck: '1'
},
labelCol: {
xs: { span: 24 },
@@ -56,9 +57,9 @@
},
confirmLoading: false,
validatorRules: {
- componentId: [
- { required: true, message: '请选择部件!'},
- ],
+ // componentId: [
+ // { required: true, message: '请选择部件!'},
+ // ],
processId: [
{ required: true, message: '请选择工艺!'},
],
diff --git a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyClothsComponentController.java b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyClothsComponentController.java
index 82e3f9cd..4b73669a 100644
--- a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyClothsComponentController.java
+++ b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyClothsComponentController.java
@@ -18,6 +18,7 @@ import org.jeecg.modules.demo.base.entity.vo.ZyProcessVo;
import org.jeecg.modules.demo.base.service.IZyClothsComponentService;
import org.jeecg.modules.demo.base.service.IZyClothsModularService;
import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.util.StringUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
@@ -106,7 +107,10 @@ public class ZyClothsComponentController extends JeecgController add(@RequestBody ZyClothsComponent zyClothsComponent) {
//编码规则:服装类型(10)+序号(8)
- zyClothsComponent.setNums(zyClothsComponentService.generateNumber(zyClothsComponent));
+ //zyClothsComponent.setNums(zyClothsComponentService.generateNumber(zyClothsComponent));
+ if (StringUtils.isEmpty(zyClothsComponent.getClothsTypeId())) {
+ return Result.error("添加失败!服装类型不能为空");
+ }
//部件名称不能重复
LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>();
List zyClothsComponentList = zyClothsComponentService.list(queryWrapper);
@@ -119,9 +123,24 @@ public class ZyClothsComponentController extends JeecgController sort(@RequestParam(name = "id", required = true) String id) {
+ //编码规则:服装类型(10)+序号(8)
+ String sort = zyClothsComponentService.sort(id);
+ System.err.println(sort+ " 制衣部件 sort");
+ if (StringUtils.isEmpty(sort)) {
+ return Result.OK(0);
+ }
+ return Result.OK(sort);
+ }
+
/**
* 编辑
- *
* @param zyClothsComponent
* @return
*/
diff --git a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/IZyClothsComponentService.java b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/IZyClothsComponentService.java
index 934479d8..0bffe257 100644
--- a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/IZyClothsComponentService.java
+++ b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/IZyClothsComponentService.java
@@ -24,4 +24,6 @@ public interface IZyClothsComponentService extends IService {
String generateNumber(ZyClothsComponent zyClothsComponent);
ZyClothsComponentDetail queryDetail(String id);
+
+ String sort(String id);
}
diff --git a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/impl/ZyClothsComponentServiceImpl.java b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/impl/ZyClothsComponentServiceImpl.java
index e16c9f5e..2729cf0e 100644
--- a/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/impl/ZyClothsComponentServiceImpl.java
+++ b/jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/impl/ZyClothsComponentServiceImpl.java
@@ -41,6 +41,7 @@ public class ZyClothsComponentServiceImpl extends ServiceImpl selectList(String id) {
List list = baseMapper.selectlistid(id);
@@ -80,6 +81,13 @@ public class ZyClothsComponentServiceImpl extends ServiceImpl numsList = zyClothsStyleMapper.selectNumsList();
- /*
- System.out.println(numsList);
- System.out.println(numsList.size());
- */
List list = new ArrayList<>();
for (String nums : numsList) {
@@ -134,10 +130,6 @@ public class ZyClothsStyleServiceImpl extends ServiceImpl