喻忠伟 2 years ago
commit f4f0520205
  1. 2
      ant-design-vue-jeecg/src/views/erp/accessories/ZyAccessoriesList.vue
  2. 11
      ant-design-vue-jeecg/src/views/erp/accessories/modules/ZyAccessoriesForm.vue
  3. 14
      ant-design-vue-jeecg/src/views/erp/fabric/modules/ZyFabricForm.vue
  4. 3
      ant-design-vue-jeecg/src/views/process/modules/ZyClothActionForm.vue
  5. 31
      ant-design-vue-jeecg/src/views/process/modules/ZyClothsTypeForm.vue
  6. 7
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessActionList.vue
  7. 129
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessForm.vue
  8. 2
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessModal.vue
  9. 1
      jeecg-boot/jeecg-boot-module-erp/src/main/java/org/jeecg/modules/demo/accessories/entity/ZyAccessories.java
  10. 12
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyClothsTypeController.java
  11. 4
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/mapper/ZyClothsTypeMapper.java
  12. 2
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/IZyClothsTypeService.java
  13. 9
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/service/impl/ZyClothsTypeServiceImpl.java
  14. 2
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/mapper/ZyProcessActionMapper.java

@ -177,7 +177,7 @@
{
title:'供货商信息',
align:"center",
dataIndex: 'supplierInfo'
dataIndex: 'supplierInfo_dictText'
},
{
title: '操作',

@ -52,9 +52,14 @@
<a-input-number v-model="model.store" placeholder="请输入库存量" style="width: 100%" />
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">-->
<!-- <a-form-model-item label="供货商信息" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierInfo">-->
<!-- <a-input v-model="model.supplierInfo" placeholder="请输入供货商信息" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-form-model-item label="供货商信息" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierInfo">
<a-input v-model="model.supplierInfo" placeholder="请输入供货商信息" ></a-input>
<j-select-depart v-model="model.supplierInfo" placeholder="请输入供货商信息" />
</a-form-model-item>
</a-col>
</a-row>
@ -104,6 +109,10 @@
contents: [
{ required: true, message: '请输入名称!'},
],
store: [
{
pattern: /^\d*\.?\d+$/,message:'请输入正数'
}],
},
url: {
add: "/accessories/zyAccessories/add",

@ -63,12 +63,12 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="零售价" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="retailPrice">
<a-form-model-item label="零售价(元)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="retailPrice">
<a-input-number v-model="model.retailPrice" placeholder="请输入零售价" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="unit">
<a-form-model-item label="单位(元)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="unit">
<j-dict-select-tag v-model="model.unit" type="radioButton" title="单位" dictCode="unit1" />
</a-form-model-item>
</a-col>
@ -83,7 +83,7 @@
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="幅宽" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="clothW">
<a-form-model-item label="幅宽(米)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="clothW">
<j-search-select-tag v-model="model.clothW" dict="clothW" />
</a-form-model-item>
</a-col>
@ -189,6 +189,14 @@
name: [
{ required: true, message: '请输入名称!'},
],
money: [
{ required: true, message: '请输入单价!'},
{pattern: /^\d+$/,message:'请输入正整数'}
],
retailPrice: [
{ required: true, message: '请输入零售价!'},
{pattern: /^\d+$/,message:'请输入正整数'}
],
// money: [
// { required: false},
// { pattern: /^\d{0,11}$/, message: '11'},

@ -75,12 +75,15 @@
validatorRules: {
freq: [
{ required: true, message: '请输入频率!'},
{pattern: /^\d+$/,message:'请输入正整数'}
],
machineTmu: [
{ required: true, message: '请输入机器TMU!'},
{pattern: /^\d+$/,message:'请输入正整数'}
],
manualTmu: [
{ required: true, message: '请输入手工TMU!'},
{pattern: /^\d+$/,message:'请输入正整数'}
],
nums: [
{ required: true, message: '请输入编号!'},

@ -5,7 +5,12 @@
<a-row>
<a-col :span="24">
<a-form-model-item label="企业" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="enterpriseId">
<j-select-depart v-model="model.enterpriseId" />
<j-select-depart v-model="model.enterpriseId" @change="bianhao" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="nums">
<a-input v-model="model.nums" placeholder="请输入编号" disabled ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
@ -18,11 +23,7 @@
{{ typeId }}
</a-form-item>
</a-col>
<!-- <a-col :span="24">-->
<!-- <a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="nums">-->
<!-- <a-input v-model="model.nums" placeholder="请输入编号" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-form-model-item label="类型名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeName">
<a-input v-model="model.typeName" placeholder="请输入类型名称" ></a-input>
@ -62,6 +63,7 @@
data () {
return {
model:{
nums:''
},
typeId:"",
labelCol: {
@ -88,7 +90,8 @@
url: {
add: "/base/zyClothsType/add",
edit: "/base/zyClothsType/edit",
queryById: "/base/zyClothsType/queryById"
queryById: "/base/zyClothsType/queryById",
weiyi:"/base/zyClothsType/weiyi"
}
}
},
@ -102,6 +105,20 @@
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
bianhao(){
var n=6
getAction(this.url.weiyi,null).then((res)=>{
var num=parseInt(res.result,10)+1
console.log(num)
num=num.toString()
while(num.length<n){
num="0"+num
}
console.log(num)
this.model.nums="QIYE"+num;
})
},
add () {
this.edit(this.modelDefault);
},

@ -157,6 +157,11 @@
align:"center",
dataIndex: 'nums'
},
{
title:'顺序',
align:"center",
dataIndex: 'sortAction'
},
{
title:'动作',
align:"center",
@ -207,6 +212,7 @@
up(id){
getAction(this.url.up,{id:id}).then((res)=>{
if(res.success){
this.loadData();
this.$message.success(res.message);
}else{
this.$message.warning(res.message);
@ -215,6 +221,7 @@
down(id){
getAction(this.url.down,{id:id}).then((res)=>{
if(res.success){
this.loadData();
this.$message.success(res.message);
}else{
this.$message.warning(res.message);

@ -1,14 +1,14 @@
<template>
<a-spin :spinning="confirmLoading">
<a-spin :spinning="confirmLoading" style="padding: 10px 20px">
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<a-row>
<a-col :span="24">
<a-row type="flex" justify="space-between">
<a-col :span="11">
<a-form-model-item label="企业" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="enterpriseId">
<j-select-depart v-model="model.enterpriseId" placeholder="请输入企业名称" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="服装类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId">
<j-popup
v-model="model.typeName"
@ -22,43 +22,36 @@
</a-form-model-item>
<a-input v-model="model.styleId" hidden/>
</a-col>
<a-col :span="24">
<a-col :span="11">
<a-form-model-item label="工序代码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processCode">
<a-input v-model="model.processCode" placeholder="请输入工序代码" disabled></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="工序名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processName">
<a-input v-model="model.processName" placeholder="请输入工序名称" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="工艺描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processDescribe">
<a-textarea v-model="model.processDescribe" rows="4" placeholder="请输入工艺描述"/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="做工说明" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="mkExplain">
<a-textarea v-model="model.mkExplain" rows="4" placeholder="请输入做工说明"/>
</a-form-model-item>
</a-col>
<a-col :span="24">
</a-row>
<a-row type="flex" justify="space-between">
<a-col :span="11">
<a-form-model-item label="品质要求" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="qualityRequire">
<a-input v-model="model.qualityRequire" placeholder="请输入品质要求" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="工序时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processTime">
<a-col :span="12">
<a-form-model-item label="工序时间(秒)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processTime">
<a-input v-model="model.processTime" placeholder="请输入工序时间" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="工序单价" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="price">
<a-col :span="11">
<a-form-model-item label="工序单价(元)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="price">
<a-input-number v-model="model.price" placeholder="请输入工序单价" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="工序等级" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="grade">
<a-col :span="12">
<a-form-model-item label="工序等级(键值对)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="grade">
<a-input v-model="model.grade" placeholder="请输入工序等级" ></a-input>
</a-form-model-item>
</a-col>
@ -72,38 +65,38 @@
<!-- <a-input v-model="model.fabricGrade" placeholder="请输入面料等级" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-col :span="11">
<a-form-model-item label="针距(针/厘米)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="needlePitch">
<a-input-number v-model="model.needlePitch" placeholder="请输入针距(针/厘米)" style="width: 100%" />
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">-->
<!-- <a-col :span="11">-->
<!-- <a-form-model-item label="机器名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineId">-->
<!-- <j-dict-select-tag type="list" v-model="model.machineId" dictCode="zy_devicetype,name,id" placeholder="请选择机器名" />-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-form-model-item label="手工宽放" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="manualWide">
<a-col :span="12">
<a-form-model-item label="手工宽放(毫米)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="manualWide">
<a-input v-model="model.manualWide" placeholder="请输入手工宽放" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="手工时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="manualTime">
<a-col :span="11">
<a-form-model-item label="手工时间(秒)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="manualTime">
<a-input-number v-model="model.manualTime" placeholder="请输入手工时间" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="机器转速" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineSpeed">
<a-col :span="12">
<a-form-model-item label="机器转速(转/分钟)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineSpeed">
<a-input-number v-model="model.machineSpeed" placeholder="请输入机器转速" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="机器宽放" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineWide">
<a-col :span="11">
<a-form-model-item label="机器宽放(毫米)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineWide">
<a-input v-model="model.machineWide" placeholder="请输入机器宽放" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="机器时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineTime">
<a-col :span="12">
<a-form-model-item label="机器时间(秒)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="machineTime">
<a-input-number v-model="model.machineTime" placeholder="请输入机器时间" style="width: 100%" />
</a-form-model-item>
</a-col>
@ -112,12 +105,12 @@
<!-- <a-input v-model="model.machineFloat" placeholder="请输入机器浮于" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-form-model-item label="绑包宽放" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bundleWide">
<a-col :span="11">
<a-form-model-item label="绑包宽放(毫米)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bundleWide">
<a-input v-model="model.bundleWide" placeholder="请输入绑包宽放" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="绑包时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bundleTime">
<a-input v-model="model.bundleTime" placeholder="请输入绑包时间" ></a-input>
</a-form-model-item>
@ -153,12 +146,12 @@
<!-- <j-dict-select-tag v-model="model.styleId" placeholder="请输入款式名称" dictCode="zy_cloths_style,style_names,id" />-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-col :span="11">
<a-form-model-item label="工段代码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="worksectionCode">
<a-input v-model="model.worksectionCode" placeholder="请输入工段代码" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="工序类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="processType">
<j-dict-select-tag type="radio" v-model="model.processType" dictCode="processType" placeholder="" />
</a-form-model-item>
@ -168,37 +161,54 @@
<!-- <a-input v-model="model.contractNum" placeholder="请输入合同号" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-col :span="11">
<a-form-model-item label="合计(手工TMU)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="totalManualTmu">
<a-input-number v-model="model.totalManualTmu" placeholder="请输入合计(手工TMU)" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="合计(机器TMU)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="totalMachineTmu">
<a-input-number v-model="model.totalMachineTmu" placeholder="请输入合计(机器TMU)" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="11">
<a-form-model-item label="合计(手工秒)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="totalMaunal">
<a-input-number v-model="model.totalMaunal" placeholder="请输入合计(手工秒)" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="12">
<a-form-model-item label="合计(机器秒)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="totalMachine">
<a-input-number v-model="model.totalMachine" placeholder="请输入合计(机器秒)" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24" class='coin'>
</a-row>
<a-row>
<a-col :span="48">
<a-form-model-item label="工艺描述" :labelCol="labelCol1" :wrapperCol="wrapperCol1" prop="processDescribe">
<a-textarea v-model="model.processDescribe" rows="2" placeholder="请输入工艺描述"/>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col :span="48">
<a-form-model-item label="做工说明" :labelCol="labelCol1" :wrapperCol="wrapperCol1" prop="mkExplain">
<a-textarea v-model="model.mkExplain" rows="2" placeholder="请输入做工说明"/>
</a-form-model-item>
</a-col>
</a-row>
<a-row type="flex" align="middle" class="imageDiv">
<a-col :span="8">
<a-form-model-item label="图片" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="image" >
<j-image-upload isMultiple v-model="model.image" ></j-image-upload>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-col :span="8">
<a-form-model-item label="视频" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="vedio">
<j-upload v-model="model.vedio" ></j-upload>
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</j-form-container>
</a-spin>
@ -236,12 +246,30 @@
xs: { span: 24 },
sm: { span: 16 },
},
labelCol1: {
xs: { span: 24 },
sm: { span: 3 },
},
wrapperCol1: {
xs: { span: 24 },
sm: { span: 21 },
},
labelCol2: {
xs: { span: 24 },
sm: { span: 3 },
},
wrapperCol2: {
xs: { span: 24 },
sm: { span: 21 },
},
confirmLoading: false,
validatorRules: {
fabricNum: [
{ required: true, message: '请输入面料代码!'},
],
price:[{
pattern: /^\d*\.?\d+$/,message:'请输入正数'
},],
processCode: [
{ required: true, message: '请输入工序代码!'},
],
@ -324,4 +352,9 @@
},
}
}
</script>
</script>
<style scoped>
/deep/ .imageDiv .ant-row{
margin-bottom: 0;
}
</style>

@ -23,7 +23,7 @@
data () {
return {
title:'',
width:800,
width:1000,
visible: false,
disableSubmit: false
}

@ -67,6 +67,7 @@ public class ZyAccessories implements Serializable {
/**供货商信息*/
@Excel(name = "供货商信息", width = 15)
@ApiModelProperty(value = "供货商信息")
@Dict(dictTable = "sys_depart", dicText = "depart_name", dicCode = "id")
private java.lang.String supplierInfo;
/**创建人*/

@ -96,7 +96,7 @@ public class ZyClothsTypeController extends JeecgController<ZyClothsType, IZyClo
zyClothsType.setTypeId(null);
}
//生成编号 nums,编号,varchar,10,非空,不重复,企业缩写(4)+顺序号(6)在service层处理
zyClothsType.setNums(zyClothsTypeService.generateNumber());
// zyClothsType.setNums(zyClothsTypeService.generateNumber());
zyClothsTypeService.save(zyClothsType);
return Result.OK("添加成功!");
}
@ -183,4 +183,14 @@ public class ZyClothsTypeController extends JeecgController<ZyClothsType, IZyClo
return super.importExcel(request, response, ZyClothsType.class);
}
@GetMapping(value = "/weiyi")
public Result<?> weiyi() {
String a=zyClothsTypeService.sort();
if(a==null){
return Result.OK("0");
}
return Result.OK(a.substring(4));
}
}

@ -3,6 +3,7 @@ package org.jeecg.modules.demo.base.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.jeecg.modules.demo.base.entity.ZyClothsType;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
@ -17,4 +18,7 @@ public interface ZyClothsTypeMapper extends BaseMapper<ZyClothsType> {
List<String> selectNumsList();
List<String> listByTypeId(String typeId);
@Select("select nums from zy_cloths_type where nums like 'QIYE%' order by nums desc limit 0,1 ")
String sort();
}

@ -13,4 +13,6 @@ public interface IZyClothsTypeService extends IService<ZyClothsType> {
/**nums,编号,varchar,10,非空,不重复,企业缩写(4)+顺序号(6)*/
String generateNumber();
String sort();
}

@ -40,6 +40,15 @@ public class ZyClothsTypeServiceImpl extends ServiceImpl<ZyClothsTypeMapper, ZyC
return nums + format;
}
/*
* 顺序号
* */
@Override
public String sort() {
return zyClothsTypeMapper.sort();
}
private Long orderNumber() {
List<String> listString = zyClothsTypeMapper.selectNumsList();
//System.out.println(listString);

@ -22,7 +22,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
public interface ZyProcessActionMapper extends BaseMapper<ZyProcessAction> {
@Select("<script>select * from zy_process_action <where><if test=\" p != null\">process_id in (select id from zy_process where process_name like #{p})</if><if test=\" m != null\"> and action_id in (select id from zy_cloth_action where descr like #{m})</if></where></script>")
IPage<ZyProcessAction> page(Page<ZyProcessAction> page, @Param("p") String s, @Param("m") String t);
@Select("<script>select a.*,b.process_code,c.nums from zy_process_action as a,zy_process as b,zy_cloth_action as c <where> a.process_id=b.id and a.action_id=c.id and a.process_id =#{p}<if test=\" m != null\"> and action_id in (select id from zy_cloth_action where descr like #{m})</if></where></script>")
@Select("<script>select a.*,b.process_code,c.nums from zy_process_action as a,zy_process as b,zy_cloth_action as c <where> a.process_id=b.id and a.action_id=c.id and a.process_id =#{p}<if test=\" m != null\"> and action_id in (select id from zy_cloth_action where descr like #{m})</if></where> order by sort_action desc</script>")
IPage<ZyProcessAction> page1(Page<ZyProcessAction> page, @Param("p") String s, @Param("m") String t);
@Select("select * from zy_cloth_action where id in (select action_id from zy_process_action where process_id=#{id}) ")
List<ZyClothAction> selectByid(String id);

Loading…
Cancel
Save