Merge remote-tracking branch 'origin/master'

zhc4dev
YTD 2 years ago
commit 3f2cba0a3c
  1. 5
      ant-design-vue-jeecg/src/mixins/JeecgListMixin.js
  2. 2
      ant-design-vue-jeecg/src/views/personel/shift/ZyShiftList.vue
  3. 27
      ant-design-vue-jeecg/src/views/zyclothsstyle/ZyClothsStyleList.vue
  4. 32
      ant-design-vue-jeecg/src/views/zystylemodule/ZyStyleModuleList.vue
  5. 29
      ant-design-vue-jeecg/src/views/zystylemodule/modules/ZyStyleModuleForm.vue
  6. 4
      ant-design-vue-jeecg/src/views/zystylemodule/modules/ZyStyleModuleModal.vue
  7. 5
      jeecg-boot/jeecg-boot-module-personnel/src/main/java/org/jeecg/modules/person/entity/ZyShift.java
  8. 1
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/system/rule/OrderNumberRule.java
  9. 1
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zyclothsample/mapper/ZyClothSampleMapper.java
  10. 35
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodule/controller/ZyStyleModuleController.java
  11. 13
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodule/entity/NewStyleModule.java
  12. 1
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodule/mapper/ZyStyleModuleMapper.java
  13. 4
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodule/mapper/xml/ZyStyleModuleMapper.xml

@ -266,6 +266,11 @@ export const JeecgListMixin = {
this.$refs.modalForm.title = "新增";
this.$refs.modalForm.disableSubmit = false;
},
styleModuleHandleAdd: function (id) {
this.$refs.modalForm.add(id);
this.$refs.modalForm.title = "新增";
this.$refs.modalForm.disableSubmit = false;
},
handleAdd1: function (id) {
this.$refs.modalForm.add1(id);
this.$refs.modalForm.title = "新增";

@ -116,7 +116,7 @@
},
data () {
return {
description: 'zy_shift管理页面',
description: '班次管理 zy_shift管理页面',
//
columns: [
{

@ -155,30 +155,32 @@
}
},
{
title:'服装类型',
title:'款式名称',
align:"center",
dataIndex: 'typeId'
dataIndex: 'styleNames'
},
{
title:'形式',
title:'编号',
align:"center",
dataIndex: 'shape_dictText'
dataIndex: 'nums'
},
{
title:'编号',
title:'规格',
align:"center",
dataIndex: 'nums'
dataIndex: 'specification'
},
{
title:'名称',
title:'服装类型',
align:"center",
dataIndex: 'styleNames'
dataIndex: 'typeId'
},
{
title:'规格',
title:'形式',
align:"center",
dataIndex: 'specification'
dataIndex: 'shape_dictText'
},
{
title:'企业',
align:"center",
@ -229,14 +231,17 @@
methods: {
initDictConfig(){
},
//
jumpPage1(record) {
this.$router.push({
path: '/src/views/zystylemodule/ZyStyleModuleList',
query: { //
'id': record.id,
//'typeId': record.typeId,
}
});
},
//
jumpPage2(record) {
this.$router.push({
path: '/src/views/zystylefabric/ZyStyleFabricList',
@ -245,6 +250,7 @@
}
});
},
//
jumpPage4(record) {
this.$router.push({
path: '/src/views/zystylemodel/ZyStyleModelList',
@ -253,6 +259,7 @@
}
});
},
//
jumpPage5(record) {
this.$router.push({
path: '/process/ZyProcessList',

@ -35,7 +35,7 @@
<!-- 操作按钮区域 -->
<div class="table-operator">
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
<a-button @click="styleModuleHandleAdd(id)" type="primary" icon="plus">新增</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('款式模块表')">导出</a-button>
<!-- <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
<a-button type="primary" icon="import">导入</a-button>
@ -147,9 +147,9 @@ export default {
}
},
{
title: '服装类型',
title: '款式名称',
align: "center",
dataIndex: 'typeName'
dataIndex: 'styleNames'
},
{
title: '款式编号',
@ -157,9 +157,14 @@ export default {
dataIndex: 'styleNums'
},
{
title: '款式名称',
title: '服装类型',
align: "center",
dataIndex: 'styleNames'
dataIndex: 'typeName'
},
{
title: '模块名称',
align: "center",
dataIndex: 'modularName'
},
{
title: '模块编号',
@ -167,10 +172,11 @@ export default {
dataIndex: 'modularNums'
},
{
title: '模块名称',
title: '创建时间',
align: "center",
dataIndex: 'modularName'
dataIndex: 'createTime'
},
{
title: '操作',
dataIndex: 'action',
@ -209,15 +215,17 @@ export default {
},
//
loadParameter() {
if (this.loadRouteType == false) {
if (this.loadRouteType === false) {
this.id = this.$route.query.id;
console.log(this.id)
//this.typeId = this.$route.query.typeId;
console.log('********id对应的为款式style_id: '+this.id);
console.log('******typeId此为类型typeId: '+this.typeId);
this.loadRouteType = true;
}
},
loadData(arg) {
if(!this.url.list){
this.$message.error("请设置url.list属性!")
this.$message.error("请设置url.list属性!");
return
}
// 1
@ -256,7 +264,8 @@ export default {
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.id=this.id;
//param.id=this.id;
param.id=this.$route.query.id;
return filterObj(param);
},
getSuperFieldList() {
@ -264,6 +273,7 @@ export default {
fieldList.push({type: 'string', value: 'typeId', text: '类型id', dictCode: "zy_cloths_type,id,type_name"})
fieldList.push({type: 'string', value: 'styleId', text: '款式id', dictCode: "zy_cloths_style,id,style_names"})
fieldList.push({type: 'string', value: 'modularId', text: '模块id', dictCode: "zy_cloths_modular ,id,modular_name"})
fieldList.push({type: 'string', value: 'createTime', text: '创建时间'})
this.superFieldList = fieldList
}
}

@ -3,16 +3,18 @@
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<a-row>
<a-col :span="24">
<a-form-model-item label="类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId">
<j-dict-select-tag type="list" v-model="model.typeId" dictCode="zy_cloths_type,type_name,id" placeholder="请选择类型" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="款式" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="styleId">
<!-- <a-col :span="24">
<a-form-model-item label="款式名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="styleId">
<j-dict-select-tag type="list" v-model="model.styleId" dictCode="zy_cloths_style,style_names,id" placeholder="请选择款式" />
</a-form-model-item>
</a-col>
</a-col>-->
<!-- <a-col :span="24">
<a-form-model-item label="服装类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId">
<j-dict-select-tag type="list" v-model="model.typeId" dictCode="zy_cloths_type,type_name,id" placeholder="请选择类型" />
</a-form-model-item>
</a-col>-->
<a-col :span="24">
<a-form-model-item label="模块" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="modularId">
<j-dict-select-tag type="list" v-model="model.modularId" dictCode="zy_cloths_modular ,modular_name,id" placeholder="请选择模块" />
@ -44,6 +46,8 @@
data () {
return {
model:{
typeId: '',
styleId: '',
},
labelCol: {
xs: { span: 24 },
@ -55,9 +59,9 @@
},
confirmLoading: false,
validatorRules: {
typeId: [
/*typeId: [
{ required: true, message: '请输入类型id!'},
],
],*/
styleId: [
{ required: true, message: '请输入款式id!'},
],
@ -82,8 +86,11 @@
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
add () {
add (id) {
this.edit(this.modelDefault);
//this.model.typeId = typeId;
this.model.styleId = id;
},
edit (record) {
this.model = Object.assign({}, record);

@ -29,10 +29,10 @@
}
},
methods: {
add () {
add (id) {
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.add();
this.$refs.realForm.add(id);
})
},
edit (record) {

@ -7,6 +7,11 @@ import lombok.Data;
import java.util.Date;
/**
* 这是人员管理子系统下面的班组管理下面的班次管理
* 对应数据库表为 zy_shift
*/
@Data
public class ZyShift {

@ -32,5 +32,4 @@ public class OrderNumberRule implements IFillRuleHandler {
}
return value;
}
}

@ -14,4 +14,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
public interface ZyClothSampleMapper extends BaseMapper<ZyClothSample> {
}

@ -8,8 +8,11 @@ import java.util.stream.Collectors;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils;
@ -28,6 +31,7 @@ import org.jeecg.modules.zyclothsstyle.service.IZyClothsStyleService;
import org.jeecg.modules.zystylefabric.entity.NewZyStyleFabric;
import org.jeecg.modules.zystylemodule.entity.NewStyleModule;
import org.jeecg.modules.zystylemodule.entity.ZyStyleModule;
import org.jeecg.modules.zystylemodule.mapper.ZyStyleModuleMapper;
import org.jeecg.modules.zystylemodule.service.INewZyStyleModuleService;
import org.jeecg.modules.zystylemodule.service.IZyStyleModuleService;
import org.jeecgframework.poi.excel.ExcelImportUtil;
@ -66,6 +70,7 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
@Autowired
private IZyClothsTypeService zyClothsTypeService;
/**
* 分页列表查询
*
@ -82,6 +87,13 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
HttpServletRequest req) {
/*LambdaQueryWrapper<ZyStyleModule> lambdaQueryWrapper = new LambdaQueryWrapper<>();
lambdaQueryWrapper.eq(ZyStyleModule::getStyleId,id);
Page<NewStyleModule> page = new Page<>(pageNo,pageSize);
Page<NewStyleModule> pageList = zyStyleModuleService.page(page, lambdaQueryWrapper);
System.out.println(pageList.getRecords());
return Result.OK(pageList);*/
List<NewStyleModule> listNewStyleModules = new ArrayList<>();
QueryWrapper<ZyStyleModule> queryWrapper = new QueryWrapper<>();
if (id != null) {
@ -99,6 +111,7 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
}
}
List<ZyStyleModule> list = zyStyleModuleService.list(queryWrapper);
//System.out.println(list);
for (ZyStyleModule zyStyleModule : list) {
NewStyleModule newSeMo = new NewStyleModule();
//编辑回显
@ -119,13 +132,22 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
//服装类型
String typeId = zyStyleModule.getTypeId();
ZyClothsType typeById = zyClothsTypeService.getById(typeId);
newSeMo.setCreateTime(zyStyleModule.getCreateTime());
if (typeById != null){
newSeMo.setTypeName(typeById.getTypeName());
} else {
newSeMo.setTypeName("typeName为空");
}
listNewStyleModules.add(newSeMo);
}
IPage<NewStyleModule> pageList = new Page<>(pageNo, pageSize, list.size());
IPage<NewStyleModule> pageList = new Page<>(pageNo, pageSize, listNewStyleModules.size());
pageList.setRecords(listNewStyleModules);
System.out.println(pageList.getRecords());
return Result.OK(pageList);
}
/**
* 分页列表查询
*
@ -147,7 +169,7 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
Page<ZyStyleModule> page = new Page<ZyStyleModule>(pageNo, pageSize);
IPage<ZyStyleModule> pageList = zyStyleModuleService.page(page, queryWrapper);
System.out.println(zyStyleModule);
//System.out.println(zyStyleModule);
return Result.OK(pageList);
}
@ -162,6 +184,15 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_module:add")
@PostMapping(value = "/add")
public Result<String> add(@RequestBody ZyStyleModule zyStyleModule) {
//根据styleId到原表 zy cloths style直接把名字拿过来,再根据名字到另一个表 zy cloths type 中把id拿过来
String styleId = zyStyleModule.getStyleId();
ZyClothsStyle zyClothsStyle = zyClothsStyleService.getById(styleId);
LambdaQueryWrapper<ZyClothsType> lambdaQueryWrapper = new LambdaQueryWrapper<>();
lambdaQueryWrapper.eq(ZyClothsType::getTypeName,zyClothsStyle.getTypeId());
ZyClothsType zyClothsType = zyClothsTypeService.getOne(lambdaQueryWrapper);
zyStyleModule.setTypeId(zyClothsType.getId());
zyStyleModuleService.save(zyStyleModule);
return Result.OK("添加成功!");
}

@ -2,11 +2,19 @@ package org.jeecg.modules.zystylemodule.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
/**
* 增强ZyStyleModule
* 原有的属性太少
*/
@Data
public class NewStyleModule {
/**主键*/
@ -48,4 +56,9 @@ public class NewStyleModule {
@Excel(name = "模块名称", width = 15)
@ApiModelProperty(value = "模块名称")
private java.lang.String modularName;
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
}

@ -15,4 +15,5 @@ import org.jeecg.modules.zystylemodule.entity.ZyStyleModule;
*/
public interface ZyStyleModuleMapper extends BaseMapper<ZyStyleModule> {
List<ZyStyleModule> handWritingList(String id);
}

@ -2,4 +2,8 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.zystylemodule.mapper.ZyStyleModuleMapper">
<select id="handWritingList" resultType="org.jeecg.modules.zystylemodule.entity.ZyStyleModule" parameterType="string">
select * from zy_style_module
where style_id = #{id}
</select>
</mapper>
Loading…
Cancel
Save