Merge remote-tracking branch 'origin/master'

zhc4dev
暖暖 2 years ago
commit a42880ab42
  1. 7
      ant-design-vue-jeecg/src/views/erp/fabric/ZyFabricList.vue
  2. 5
      ant-design-vue-jeecg/src/views/erp/fabric/modules/ZyFabricForm.vue
  3. 10
      jeecg-boot/jeecg-boot-module-erp/src/main/java/org/jeecg/modules/demo/fabric/controller/ZyFabricTypeController.java
  4. 7
      jeecg-boot/jeecg-boot-module-erp/src/main/java/org/jeecg/modules/demo/fabric/entity/ZyFabric.java

@ -250,7 +250,11 @@ import ZyFabricFormDetailModel from './modules/ZyFabricFormDetailModel'
dataIndex: 'qRcode', dataIndex: 'qRcode',
scopedSlots: {customRender: 'imgSlot'} scopedSlots: {customRender: 'imgSlot'}
}, },
{
title:'等级',
align:"center",
dataIndex: 'fabricGrade_dictText'
},
{ {
title:'供货商信息', title:'供货商信息',
align:"center", align:"center",
@ -310,6 +314,7 @@ import ZyFabricFormDetailModel from './modules/ZyFabricFormDetailModel'
fieldList.push({type:'string',value:'clothW',text:'幅宽',dictCode:'clothW,,'}) fieldList.push({type:'string',value:'clothW',text:'幅宽',dictCode:'clothW,,'})
fieldList.push({type:'string',value:'location',text:'所在地区',dictCode:''}) fieldList.push({type:'string',value:'location',text:'所在地区',dictCode:''})
fieldList.push({type:'int',value:'status',text:'状态 o 为下架 1为上架 ',dictCode:'fabric_status,,'}) fieldList.push({type:'int',value:'status',text:'状态 o 为下架 1为上架 ',dictCode:'fabric_status,,'})
fieldList.push({type:'int',value:'fabricGrade',text:'等级',dictCode:'fabric_grade,,'})
fieldList.push({type:'string',value:'qRcode',text:'二维码',dictCode:''}) fieldList.push({type:'string',value:'qRcode',text:'二维码',dictCode:''})
fieldList.push({type:'string',value:'name',text:'名称',dictCode:''}) fieldList.push({type:'string',value:'name',text:'名称',dictCode:''})
fieldList.push({type:'sel_depart',value:'supplierInfo',text:'供货商信息'}) fieldList.push({type:'sel_depart',value:'supplierInfo',text:'供货商信息'})

@ -91,6 +91,11 @@
<j-search-select-tag v-model="model.status" dict="fabric_status" /> <j-search-select-tag v-model="model.status" dict="fabric_status" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<!-- <a-col :span="24">-->
<!-- <a-form-model-item label="等级" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fabricGrade">-->
<!-- <j-search-select-tag v-model="model.fabricGrade" dict="fabric_grade" />-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24"> <a-col :span="24">
<a-form-model-item label="供货商" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierInfo"> <a-form-model-item label="供货商" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplierInfo">
<j-select-depart v-model="model.supplierInfo" multi /> <j-select-depart v-model="model.supplierInfo" multi />

@ -14,7 +14,9 @@ import com.sun.mail.util.QEncoderStream;
import org.jeecg.common.api.vo.Result; import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator; import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils; import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.demo.fabric.entity.ZyFabric;
import org.jeecg.modules.demo.fabric.entity.ZyFabricType; import org.jeecg.modules.demo.fabric.entity.ZyFabricType;
import org.jeecg.modules.demo.fabric.service.IZyFabricService;
import org.jeecg.modules.demo.fabric.service.IZyFabricTypeService; import org.jeecg.modules.demo.fabric.service.IZyFabricTypeService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
@ -51,6 +53,8 @@ import org.jeecg.common.aspect.annotation.AutoLog;
public class ZyFabricTypeController extends JeecgController<ZyFabricType, IZyFabricTypeService> { public class ZyFabricTypeController extends JeecgController<ZyFabricType, IZyFabricTypeService> {
@Autowired @Autowired
private IZyFabricTypeService zyFabricTypeService; private IZyFabricTypeService zyFabricTypeService;
@Autowired
private IZyFabricService zyFabricService; //面料表
/** /**
* 分页列表查询 * 分页列表查询
@ -133,6 +137,12 @@ public class ZyFabricTypeController extends JeecgController<ZyFabricType, IZyFab
@ApiOperation(value="zy_fabric_type-通过id删除", notes="zy_fabric_type-通过id删除") @ApiOperation(value="zy_fabric_type-通过id删除", notes="zy_fabric_type-通过id删除")
@DeleteMapping(value = "/delete") @DeleteMapping(value = "/delete")
public Result<?> delete(@RequestParam(name="id",required=true) String id) { public Result<?> delete(@RequestParam(name="id",required=true) String id) {
List<ZyFabric> zyFabricsList = zyFabricService.list();
for (ZyFabric zyFabric : zyFabricsList){
if (zyFabric.getTypeId().equals(id)){
return Result.error("此面料类型已被使用,禁止删除!");
}
}
zyFabricTypeService.removeById(id); zyFabricTypeService.removeById(id);
return Result.OK("删除成功!"); return Result.OK("删除成功!");
} }

@ -113,6 +113,11 @@ public class ZyFabric implements Serializable {
@Excel(name = "二维码", width = 15) @Excel(name = "二维码", width = 15)
@ApiModelProperty(value = "二维码") @ApiModelProperty(value = "二维码")
private java.lang.String qRcode; private java.lang.String qRcode;
/**等级*/
@Excel(name = "等级", width = 15,dictTable = "", dicText = "", dicCode = "fabric_grade")
@ApiModelProperty(value = "等级")
@Dict(dictTable = "", dicText = "", dicCode = "fabric_grade")
private java.lang.Integer fabricGrade;
/**名称*/ /**名称*/
@Excel(name = "名称", width = 15) @Excel(name = "名称", width = 15)
@ApiModelProperty(value = "名称") @ApiModelProperty(value = "名称")
@ -151,4 +156,6 @@ public class ZyFabric implements Serializable {
/**所属部门*/ /**所属部门*/
@ApiModelProperty(value = "所属部门") @ApiModelProperty(value = "所属部门")
private java.lang.String sysOrgCode; private java.lang.String sysOrgCode;
/**所属部门*/
} }

Loading…
Cancel
Save