Merge remote-tracking branch 'origin/master'

zhc4dev
赵灿 2 years ago
commit 21d9fec1bd
  1. 82
      ant-design-vue-jeecg/src/components/procedure/processFabric.vue
  2. 47
      ant-design-vue-jeecg/src/views/cloths/modules/ZyProcessFabricFormDetail.vue
  3. 12
      ant-design-vue-jeecg/src/views/erp/accessories/modules/ZyAccessoriesFormDetail.vue
  4. 11
      ant-design-vue-jeecg/src/views/erp/fabric/ZyFabricList.vue
  5. 1
      ant-design-vue-jeecg/src/views/erp/fabric/modules/ZyFabricForm.vue
  6. 247
      ant-design-vue-jeecg/src/views/erp/fabric/modules/ZyFabricFormDetailModel.vue
  7. 74
      ant-design-vue-jeecg/src/views/process/ZyProcessList.vue
  8. 7
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessForm.vue
  9. 138
      ant-design-vue-jeecg/src/views/zyclothsample/ZyClothSampleList.vue
  10. 257
      ant-design-vue-jeecg/src/views/zyclothsample/modules/ZyClothSampleForm.vue
  11. 39
      ant-design-vue-jeecg/src/views/zyclothsstyle/ZyClothsStyleList.vue
  12. 60
      ant-design-vue-jeecg/src/views/zystylefabric/ZyStyleFabricList.vue
  13. 293
      ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue
  14. 168
      ant-design-vue-jeecg/src/views/zystylemodel/modules/ZyStyleModelForm.vue
  15. 84
      ant-design-vue-jeecg/src/views/zystylemodel/modules/ZyStyleModelModal.Style#Drawer.vue
  16. 60
      ant-design-vue-jeecg/src/views/zystylemodel/modules/ZyStyleModelModal.vue
  17. 60
      ant-design-vue-jeecg/src/views/zystylemodule/ZyStyleModuleList.vue
  18. 5
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/controller/ZyProcessController.java
  19. 1
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/entity/ZyProcess.java
  20. 19
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zyclothsample/controller/ZyClothSampleController.java
  21. 20
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zyclothsample/entity/ZyClothSample.java
  22. 5
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylefabric/controller/ZyStyleFabricController.java
  23. 189
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/controller/ZyStyleModelController.java
  24. 100
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java
  25. 17
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/mapper/ZyStyleModelMapper.java
  26. 5
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/mapper/xml/ZyStyleModelMapper.xml
  27. 15
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/service/IZyStyleModelService.java
  28. 20
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/service/impl/ZyStyleModelServiceImpl.java
  29. 6
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodule/controller/ZyStyleModuleController.java

@ -1,38 +1,40 @@
<template>
<div>
<div style="padding: 15px 25px;">
<el-descriptions class="margin-top" :column="3" border style="margin-top: 50px">
<div style="">
<div style="padding: 15px 0;" v-for="(item,index) in tableModel" :key="index">
<p style="font-size: 18px;" v-if="!flag">辅料信息</p>
<p style="font-size: 16px;margin-bottom: 0" v-if="flag">辅料{{index+1}}信息</p>
<el-descriptions class="margin-top" :column="3" border style="margin: 30px 0">
<el-descriptions-item>
<template slot="label"><i class="el-icon-receiving"></i>类型id</template>
{{tableModel.typeId}}
{{item.typeId}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-coin"></i>编号</template>
{{tableModel.nums}}
{{item.nums}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-postcard"></i>名称</template>
{{tableModel.contents}}
{{item.contents}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-copy-document"></i>图片</template>
{{tableModel.picture}}
{{item.picture}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-price-tag"></i>材质</template>
{{tableModel.material}}
{{item.material}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-files"></i>规格</template>
{{tableModel.specs}}
{{item.specs}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-takeaway-box"></i>库存量</template>
{{tableModel.store}}
{{item.store}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-location-outline"></i>供货商</template>
{{tableModel.supplierInfo}}
{{item.supplierInfo}}
</el-descriptions-item>
</el-descriptions>
</div>
@ -42,7 +44,30 @@
<script>
export default {
name: 'processFabric',
props:['model','fabricId'],
// props:['model','fabricId'],
props:{
model:{
type: Array,
default: function () {
return [
{
contents: "MZN600-287-800",
createBy: null,
createTime: null,
id: "1458996032118022146",
material: "厚",
nums: "MZN600-287-800",
picture: "12",
specs: "21",
store: 21,
supplierInfo: "河南驻马店",
typeId: "12",
updateBy: null,
updateTime: null,}
]
}
}
},
data () {
return {
img:'',//
@ -50,6 +75,7 @@
mp4:'',//
tableModel:[],
id:'',
flag:true,
visible: false,
confirmLoading: false,
validatorRules: {
@ -62,17 +88,29 @@
// cData
model: function(newVal,oldVal){
this.tableModel= newVal
//
if(newVal == null){
this.tableModel = [
{
contents: "MZN600-287-800",
createBy: null,
createTime: null,
id: "1458996032118022146",
material: "厚",
nums: "MZN600-287-800",
picture: "12",
specs: "21",
store: 21,
supplierInfo: "河南驻马店",
typeId: "12",
updateBy: null,
updateTime: null,}
]
}
if(this.tableModel.length == 1){
this.flag = false
}
},
fabricId: function(newVal,oldVal){
this.id = newVal
// this.$http.get('/accessories/zyAccessories/queryById?id='+this.id).then(
// res=>{
// // this.model = res.result
// console.log(this.id)
// console.log(res)
// console.log(res.result)
// })
}
},
methods: {
getTableModel(){

@ -3,26 +3,12 @@
title="工序辅料-详情"
:visible="visible"
:confirm-loading="confirmLoading"
:width='1000'
:width='1400'
@ok="handleOk"
@cancel="handleCancel">
<h1 style="text-align: center;margin-bottom: 50px;border-bottom: 1px solid #e8e8e8;padding-bottom: 20px;font-size: 22px">黄淮学院服装智能制造管理平台 - <span>工序辅料</span></h1>
<!-- <processFabric :model="model"></processFabric>-->
<div style="padding: 15px 25px;display: flex;justify-content: space-between">
<img :src="img == ''?img1:img" style="width:30%;">
<video v-if="mp4 != ''" :src="mp4" style="border:1px solid #d9d9d9;width:30%;"/>
<p v-else style="padding-top: 20px"> 暂无视频</p>
<table border="1" style="font-size:14px;" class="table" >
<tr>
<td style="text-align: center">工序:</td>
<td>{{model.processId}}</td>
</tr>
<tr>
<td style="text-align: center">面料:</td>
<td>{{model.fabricId}}</td>
</tr>
</table>
</div>
<h1 style="text-align: center;margin-bottom: 0px;padding-bottom: 20px;font-size: 22px">黄淮学院服装智能制造管理平台 - <span>工序辅料</span></h1>
<zyProcess :data="processData" style="border: 1px solid #e8e8e8;padding: 30px 25px;margin-bottom:30px;"></zyProcess>
<processFabric :model ="fabricData" style="padding:0 20px;border: 1px solid #e8e8e8;"></processFabric>
</a-modal>
</template>
@ -31,10 +17,11 @@
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
import processFabric from '@/components/procedure/processFabric'
import zyProcess from '@/components/procedure/zyProcess'
export default {
name: 'ZyProcessFabricFormDetail',
components: {
processFabric
processFabric,zyProcess
},
data () {
return {
@ -45,6 +32,10 @@ import processFabric from '@/components/procedure/processFabric'
mp4:'',//
model:{
},
processData:{},
fabricData:[],
processId:'',
fabricId:'',
visible:false,
labelCol: {
xs: { span: 24 },
@ -61,10 +52,22 @@ import processFabric from '@/components/procedure/processFabric'
},
methods: {
showModal(id) {
this.visible = true;
this.visible = true;//
this.$http.get('/pro/zyProcessFabric/queryById?id='+id).then(
res=>{
this.model = res.result
this.fabricId = res.result.fabricId
this.processId = res.result.processId
this.$http.get('/base/zyProcess/queryById?id='+this.processId).then(
res=>{
this.processData = res.result.zyProcess
})
this.$http.get('/accessories/zyAccessories/queryById?id='+this.fabricId).then(
res=>{
this.fabricData = res.result
console.log(res.result)
console.log(this.fabricData)
console.log(this.fabricId)
})
}
)
},
@ -85,4 +88,6 @@ import processFabric from '@/components/procedure/processFabric'
.table{border-color:#d9d9d9;border-radius: 3px}
.table td{padding: 10px 20px;max-width: 380px; }
.table td span{color: #333}
.coin{width: 96%;margin:0 auto 30px;border: 1px solid #e8e8e8;}
.coin h2{text-align: left;border-bottom: 1px solid #e8e8e8;padding: 20px;background: rgba(247,247,247,1);margin: 0;}
</style>

@ -9,7 +9,8 @@
@cancel="handleCancel"
>
<h1 style="text-align: center;margin-bottom: 30px;border-bottom: 1px solid #e8e8e8;padding-bottom: 20px;font-size: 22px;">黄淮学院服装智能制造管理平台 - <span>辅料管理</span></h1>
<processFabric :model="model"></processFabric>
<div style="border: 1px solid #e8e8e8;padding: 15px;">
<processFabric :model="model"></processFabric></div>
</a-modal>
</div>
</template>
@ -26,8 +27,7 @@ import processFabric from '@/components/procedure/processFabric'
},
data () {
return {
model:{
},
model:[],
visible: false,
confirmLoading: false,
validatorRules: {
@ -39,7 +39,11 @@ import processFabric from '@/components/procedure/processFabric'
this.visible = true;
this.$http.get('/accessories/zyAccessories/queryById?id='+id).then(
res=>{
this.model = res.result
if(this.model == ''){
this.model.push(res.result)
console.log(1)
}
})
},
handleOk() {

@ -124,7 +124,7 @@
<a @click="fuzhi(record)">复制</a>
<a-divider type="vertical" />
<a @click="handleDetail(record)">详情</a>
<a @click="handleDetail(record.id)">详情</a>
<a-divider type="vertical" />
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
@ -136,6 +136,7 @@
</div>
<ZyFabricFormDetail ref="ZyFabricFormDetail"></ZyFabricFormDetail>
<zy-fabric-modal ref="modalForm" @ok="modalFormOk"></zy-fabric-modal>
<ZyFabricFormDetailModel ref="ZyFabricFormDetailModel"></ZyFabricFormDetailModel>
</a-card>
</template>
@ -147,12 +148,14 @@
import ZyFabricModal from './modules/ZyFabricModal'
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
import ZyFabricFormDetail from './modules/ZyFabricFormDetail'
import ZyFabricFormDetailModel from './modules/ZyFabricFormDetailModel'
export default {
name: 'ZyFabricList',
mixins:[JeecgListMixin, mixinDevice],
components: {
ZyFabricModal,
ZyFabricFormDetail
ZyFabricFormDetail,
ZyFabricFormDetailModel
},
data () {
return {
@ -328,6 +331,10 @@ import ZyFabricFormDetail from './modules/ZyFabricFormDetail'
fieldList.push({type:'sel_depart',value:'supplierInfo',text:'供货商信息'})
fieldList.push({type:'string',value:'createTime',text:'创建时间',dictCode:''})
this.superFieldList = fieldList
},
handleDetail(id){
this.$refs.ZyFabricFormDetailModel.showModal(id)
// this.$children[0].showModal(id)
}
}
}

@ -209,6 +209,7 @@
created () {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
console.log(this.model)
},
methods: {
add () {

@ -0,0 +1,247 @@
<template>
<div>
<a-modal
title="面料管理-详情"
:visible="visible"
:confirm-loading="confirmLoading"
:width='1400'
@ok="handleOk"
@cancel="handleCancel"
style="display:flex;"
>
<div style="width: 96%;margin:0 auto 40px;padding-bottom: 30px">
<h1 style="text-align: center;margin-bottom: 0px;padding-bottom: 20px">黄淮学院服装智能制造管理平台 - <span>面料管理</span></h1>
<div>
<el-descriptions class="margin-top" :column="4" border style="margin-top: 50px">
<el-descriptions-item>
<template slot="label"><i class="el-icon-receiving"></i>面料类型</template>
{{model.typeId}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-coin"></i>编号</template>
{{model.fabricNumber}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-postcard"></i>名称</template>
{{model.name}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-copy-document"></i>颜色</template>
{{model.color}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-copy-document"></i>花样</template>
{{model.pattern}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-price-tag"></i>材质</template>
{{model.material}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-files"></i>厚度</template>
{{model.ply}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-files"></i>单价</template>
{{model.money}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-files"></i>零售价</template>
{{model.money}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-files"></i>品牌</template>
{{model.brandId}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-receiving"></i>单位</template>
{{model.unit}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-coin"></i>密度</template>
{{model.density}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-postcard"></i>名称</template>
{{model.clothW}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-copy-document"></i>幅宽</template>
{{model.clothW}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-copy-document"></i>销售地区</template>
{{model.location}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-price-tag"></i>状态</template>
{{model.status}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-location-outline"></i>供货商</template>
{{model.supplierInfo}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-picture-outline"></i>图片</template>
{{model.imageUrl}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label"><i class="el-icon-paperclip"></i>二维码</template>
{{model.qRcode}}
</el-descriptions-item>
</el-descriptions></div>
</div>
</a-modal>
</div>
<!-- <a-form-model-item label="面料类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId">-->
<!-- <j-popup-->
<!-- v-model="model.typeId"-->
<!-- field="id"-->
<!-- org-fields="id"-->
<!-- dest-fields="id"-->
<!-- code="zy_fabric_type"-->
<!-- :multi="false"-->
<!-- @input="popupCallback"-->
<!-- <a-form-model-item label="编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fabricNumber">-->
<!-- <a-input v-model="model.fabricNumber" placeholder="请输入编号" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- <a-form-model-item label="花样" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="pattern">-->
<!-- <j-search-select-tag v-model="model.pattern" dict="pattern" />-->
<!-- </a-form-model-item>-->
<!-- <a-form-model-item label="材质" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="material">-->
<!-- <j-search-select-tag v-model="model.material" dict="material" />-->
<!-- </a-form-model-item>-->
<!-- <a-form-model-item label="单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="unit">-->
<!-- <j-search-select-tag v-model="model.unit" dict="unit1" />-->
<!-- </a-form-model-item>-->
<!-- <a-form-model-item label="密度" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="density">-->
<!-- <j-search-select-tag v-model="model.density" dict="density" />-->
<!-- </a-form-model-item>-->
<!-- <a-col :span="24">-->
<!-- <a-form-model-item label="状态" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="status">-->
<!-- <j-search-select-tag v-model="model.status" dict="fabric_status" />-->
<!-- </a-form-model-item>-->
<!-- <a-col :span="24">-->
<!-- <a-form-model-item label="图片地址" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="imageUrl">-->
<!-- <j-image-upload isMultiple v-model="model.imageUrl" ></j-image-upload>-->
<!-- </a-form-model-item>-->
</template>
<script>
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
import OnlineCamera from './Components/OnlineCamera'
export default {
name: 'ZyFabricFormDetailModel',
components: {
OnlineCamera
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
},
data () {
return {
model:{
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
},
confirmLoading: false,
validatorRules: {
typeId: [
{ required: true, message: '请选择类型!'},
],
color: [
{ required: true, message: '请输入颜色!'},
],
pattern: [
{ required: true, message: '请输入花样!'},
],
fabricNumber: [
{ required: true, message: '请输入面料编号!'},
],
name: [
{ required: true, message: '请输入名称!'},
],
money: [
{ required: false},
{ pattern: /^\d{0,11}$/, message: '长度不能超过11位数字'},
],
retailPrice: [
{ required: false},
{ pattern: /^\d{0,11}$/, message: '长度不能超过11位数字'},
],
location: [
{ required: false},
{ pattern: /^.{0,30}$/, message: '长度不能超过30位字符'},
],
},
url: {
add: "/fabric/zyFabric/add",
edit: "/fabric/zyFabric/edit",
queryById: "/fabric/zyFabric/queryById"
},
visible:false
}
},
computed: {
formDisabled(){
return this.disabled
},
},
created () {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
showModal(id) {
this.visible = true;
this.$http.get('/fabric/zyFabric/queryById?id='+id).then(
res=>{
this.model = res.result
console.log(this.model)
}
)
},
handleOk() {
this.ModalText = 'The modal will be closed after two seconds';
this.confirmLoading = true;
setTimeout(() => {
this.visible = false;
this.confirmLoading = false;
}, 1);
},
handleCancel() {
this.visible = false;
},
}
}
</script>
<style scoped>
.margin-top i{margin-right: 5px}
</style>

@ -4,6 +4,17 @@
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="服装款式">
<j-dict-select-tag placeholder="请选择服装款式" dictCode="zy_cloths_style,style_names,id" v-model="queryParam.styleId" ></j-dict-select-tag>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
@ -127,6 +138,8 @@
import ZyProcessModal5 from './modules/ZyProcessModal5'
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
import ZyProcessDetail from './modules/ZyProcessDetail'
import {getAction} from "@api/manage";
import {filterObj} from "@/utils/util";
export default {
name: 'ZyProcessList',
mixins:[JeecgListMixin, mixinDevice],
@ -212,7 +225,7 @@
{
title:'款式名称',
align:"center",
dataIndex: 'styleId'
dataIndex: 'styleId_dictText'
},
{
title:'工段代码',
@ -274,12 +287,17 @@
importExcelUrl: "base/zyProcess/importExcel",
},
//
loadRouteType:false,
styleId:"",
dictOptions:{},
superFieldList:[],
}
},
created() {
this.getSuperFieldList();
// queryParam.styleId=this.styleId
// this.getSuperFieldList();
this.loadParameter() ;
},
computed: {
importExcelUrl: function(){
@ -289,6 +307,58 @@
methods: {
initDictConfig(){
},
//
loadParameter() {
if (this.loadRouteType == false) {
this.styleId = this.$route.query.styleId;
console.log(this.styleId)
this.loadRouteType = true;
}
},
loadData(arg) {
if(!this.url.list){
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
//update-begin---author:zhangyafei Date:20201118 for------------
this.dataSource = res.result.records||res.result;
if(res.result.total)
{
this.ipagination.total = res.result.total;
}else{
this.ipagination.total = 0;
}
//update-end---author:zhangyafei Date:20201118 for------------
}else{
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
})
},
getQueryParams() {
//
let sqp = {}
if(this.superQueryParams){
sqp['superQueryParams']=encodeURI(this.superQueryParams)
sqp['superQueryMatchType'] = this.superQueryMatchType
}
var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.styleId=this.styleId;
return filterObj(param);
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'processCode',text:'工序代码',dictCode:''})

@ -122,10 +122,15 @@
<!-- <a-form-model-item label="工具名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="toolId">-->
<!-- <j-dict-select-tag type="list" v-model="model.toolId" dictCode="zy_tool,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-input v-model="model.styleId" placeholder="请输入款式名称" ></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<a-col :span="24">
<a-form-model-item label="款式名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="styleId">
<a-input v-model="model.styleId" placeholder="请输入款式名称" ></a-input>
<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">

@ -11,8 +11,8 @@
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="成衣名称">
<a-input placeholder="请输入成衣名称" v-model="queryParam.clothName"></a-input>
<a-form-item label="款式">
<a-input placeholder="请输入款式" v-model="queryParam.styleId"></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
@ -108,45 +108,50 @@
</a-button>
</template>
<span slot="action" slot-scope="text,record">
// TODO:
<span slot="action1" slot-scope="text, record">
<a @click="jumpPage(record)">模块样板</a>
</span>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical" />
<a-divider type="vertical"/>
<!-- <a @click="fuzhi(record)">复制</a>-->
<!-- <a-divider type="vertical" />-->
<!-- <a @click="fuzhi(record)">复制</a>-->
<!-- <a-divider type="vertical" />-->
<!-- <a @click="handleDetail(record.id)">详情</a>-->
<a @click="handleDetail(record)">详情</a>
<a-divider type="vertical" />
<a-divider type="vertical"/>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</span>
<!-- <span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical"/>
<a-dropdown>
<a class="ant-dropdown-link">更多 <a-icon type="down"/></a>
<a-menu slot="overlay">
<a-menu-item>
&lt;!&ndash;<a @click="handleDetail(record)">详情</a>&ndash;&gt;
<a @click="openDetail(record.id)">详情</a>
</a-menu-item>
<a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>-->
<!-- <span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical"/>
<a-dropdown>
<a class="ant-dropdown-link">更多 <a-icon type="down"/></a>
<a-menu slot="overlay">
<a-menu-item>
&lt;!&ndash;<a @click="handleDetail(record)">详情</a>&ndash;&gt;
<a @click="openDetail(record.id)">详情</a>
</a-menu-item>
<a-menu-item>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>-->
</a-table>
</div>
<ZyClothSampleDetail ref="ZyClothSampleDetail"></ZyClothSampleDetail>
<zy-cloth-sample-modal ref="modalForm" @ok="modalFormOk"></zy-cloth-sample-modal>
<zy-cloth-sample-modal ref="modalForm" @ok="modalFormOk" v-bind="superFieldList"></zy-cloth-sample-modal>
</a-card>
</template>
@ -188,23 +193,27 @@ export default {
{
title: '款式',
align: "center",
dataIndex: 'styleId'
dataIndex: 'styleId',
},
{
title: '型号',
align: "center",
dataIndex: 'stylemodelId'
},
/*{
title: '模块样板',
align: "center",
dataIndex: 'modelSample'
},*/
{
title: '模块样板',
align: "center",
dataIndex: 'modelSample_dictText'
dataIndex: 'stylemodelId_dictText',
//dictCode: 'modenumber',
},
// {
// title: '',
// align: "center",
// dataIndex: 'modelSample_dictText'
// },
// {
// title: '',
// dataIndex: 'action1',
// align: "center",
// fixed: "right",
// width: 110,
// scopedSlots: {customRender: 'action1'}
// },
{
title: '用户名',
align: "center",
@ -216,27 +225,21 @@ export default {
dataIndex: 'createTime'
},
/*{
title: '成衣名称',
align: "center",
dataIndex: 'clothName'
},*/
/*{
title: '描述',
align: "center",
dataIndex: 'descr'
},*/
/*{
title: '图片',
align: "center",
dataIndex: 'url',
scopedSlots: {customRender: 'imgSlot'}
},*/
/*{
title: '用户类型',
{
title: '管理模块',
dataIndex: 'action1',
align: "center",
dataIndex: 'type'
},*/
fixed: "right",
width: 110,
scopedSlots: {customRender: 'action1'}
},
{
title: '操作',
@ -249,6 +252,7 @@ export default {
],
url: {
list: "/zyclothsample/zyClothSample/list",
edit: "/zyclothsample/zyClothSample/edit",
delete: "/zyclothsample/zyClothSample/delete",
deleteBatch: "/zyclothsample/zyClothSample/deleteBatch",
exportXlsUrl: "/zyclothsample/zyClothSample/exportXls",
@ -261,7 +265,8 @@ export default {
},
created() {
this.getSuperFieldList();
},
}
,
computed: {
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
@ -270,27 +275,42 @@ export default {
methods: {
initDictConfig() {
},
jumpPage(record) {
this.$router.push({
path: '/src/views/sample/ZyModuleSampleList',
// query: { //
// 'id': record.id,
// }
});
},
lookFile(fileUrl) {
let file = window._CONFIG['domianURL'] + "/sys/common/static/" + fileUrl
let Base64 = require('js-base64').Base64;
let url = window._CONFIG['onlinePreviewDomainURL'] + '/onlinePreview?url=' + encodeURIComponent(Base64.encode(file))
window.open(url);
},
}
,
getSuperFieldList() {
let fieldList = [];
fieldList.push({type: 'string', value: 'nums', text: '编号', dictCode: ''})
fieldList.push({type: 'string', value: 'styleId', text: '款式', dictCode: ''})
fieldList.push({type: 'string', value: 'stylemodelId', text: '型号', dictCode: ''})
fieldList.push({type: 'string', value: 'nums', text: '编号', dictCode:''})
fieldList.push({type: 'string', value: 'styleId', text: '款式', dictCode:''})
fieldList.push({type: 'string', value: 'stylemodelId', text: '型号', dictCode: 'modenumber'})
fieldList.push({type: 'string', value: 'modelSample', text: '模块样板', dictCode: ''})
fieldList.push({type: 'string', value: 'userId', text: '用户名', dictCode: ''})
fieldList.push({type: 'string', value: 'createTime', text: '创建时间', dictCode: ''})
this.superFieldList = fieldList
},
}
,
openDetail(id) {
this.$refs.ZyClothSampleDetail.showModal(id)
// this.$children[0].showModal(id)
}
,
// handleDetail(id){
// this.$refs.ZyClothSampleDetail.showModal(id)
// }
}
}
</script>

@ -5,53 +5,53 @@
<a-row>
<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-input v-model="model.nums || this.nums" placeholder="请输入编号"></a-input>-->
<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="clothName">
<a-input v-model="model.clothName" placeholder="请输入成衣名称" ></a-input>
</a-form-model-item>
</a-col>-->
<!--关联服装款式表 zy_cloths_style 关联列名称 传值id-->
<a-col :span="24">
<a-form-model-item label="款式" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="styleId">
<a-input v-model="model.styleId" placeholder="请输入款式" ></a-input>
<j-dict-select-tag v-model="model.styleId" placeholder="请输入款式"
dict-code="zy_cloths_style,style_names,style_names"></j-dict-select-tag>
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">
<a-form-model-item label="描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="descr">
<a-input v-model="model.descr" placeholder="请输入描述" ></a-input>
</a-form-model-item>
</a-col>-->
<a-col :span="24">
<a-form-model-item label="型号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="stylemodelId">
<a-input v-model="model.stylemodelId" placeholder="请输入型号" ></a-input>
<a-form-model-item label="款式型号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="stylemodelId">
<!-- <a-input v-model="model.stylemodelId" placeholder="请输入款式型号" @change="(vaule) => handletypeSelect(value)"></a-input>-->
<!-- <j-dict-select-tag v-model="model.stylemodelId" placeholder="请输入款式型号"-->
<!-- dict-code="zy_style_model,model_number,model_number"></j-dict-select-tag>-->
<j-dict-select-tag v-model="model.stylemodelId" placeholder="请选择款式型号"
dictCode="modenumber"></j-dict-select-tag>
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">
<a-form-model-item label="图片" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="url">
<j-image-upload isMultiple v-model="model.url" ></j-image-upload>
</a-form-model-item>
</a-col>-->
<!--<j-dict-select-tag v-model="model.modelSample" placeholder="请选择模块样板"-->
<!-- dict-code="zy_module_sample, module_name, id"></j-dict-select-tag>-->
<!-- <j-search-select-tag v-model="model.modelSample" dict="zy_module_sample" dictText="module_name", dictCode="id" />-->
<!-- </a-form-model-item>-->
<a-col :span="24">
<a-form-model-item label="模块样板" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="modelSample">
<!-- <j-image-upload isMultiple v-model="model.url" ></j-image-upload>-->
<!-- <a-input v-model="model.modelSample" placeholder="请输入模块样板" ></a-input>-->
<j-dict-select-tag v-model="model.modelSample" placeholder="请选择模块样板"
dictCode="zy_module_sample,module_name,id"/>
<!-- <j-search-select-tag v-model="model.modelSample" dict="zy_module_sample" dictText="module_name", dictCode="id" />-->
<a-form-model-item label="用户名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="userId">
<!-- <a-input v-model="model.userId" placeholder="请输入用户名"></a-input>-->
<j-dict-select-tag v-model="model.userId" placeholder="请输入用户名"
dict-code="sys_user,username,username"></j-dict-select-tag>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="用户名" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="userId">
<a-input v-model="model.userId" placeholder="请输入用户名" ></a-input>
<a-form-model-item label="描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="descr">
<a-textarea v-model="model.descr" placeholder="请输入描述"></a-textarea>
</a-form-model-item>
</a-col>
<!-- <a-col :span="24">
<a-form-model-item label="用户类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="type">
<a-input v-model="model.type" placeholder="请输入用户类型" ></a-input>
<a-col :span="24">
<a-form-model-item label="图片" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="url">
<j-image-upload isMultiple v-model="model.url"></j-image-upload>
</a-form-model-item>
</a-col>-->
</a-col>
</a-row>
</a-form-model>
</j-form-container>
@ -60,90 +60,131 @@
<script>
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
import {httpAction, getAction} from '@/api/manage'
import {validateDuplicateValue} from '@/utils/util'
export default {
name: 'ZyClothSampleForm',
components: {
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
export default {
name: 'ZyClothSampleForm',
components: {},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
},
data () {
return {
model:{
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
},
confirmLoading: false,
validatorRules: {
},
url: {
add: "/zyclothsample/zyClothSample/add",
edit: "/zyclothsample/zyClothSample/edit",
queryById: "/zyclothsample/zyClothSample/queryById"
}
}
},
computed: {
formDisabled(){
return this.disabled
superFieldList: [], // table
},
data() {
return {
nums: '',
selectedKey: '', // id
typeid: '', // ,
serialNumber: '', //
model: {},
labelCol: {
xs: {span: 24},
sm: {span: 5},
},
},
created () {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
add () {
this.edit(this.modelDefault);
wrapperCol: {
xs: {span: 24},
sm: {span: 16},
},
edit (record) {
this.model = Object.assign({}, record);
this.visible = true;
confirmLoading: false,
/*效验规则*/
validatorRules: {
nums: [
//{pattern: /^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{4}$/, message: '4wei'},
{ required:true, message: '编号不能为空'},
{ pattern: /^[0-9A-Za-z]{0,10}$/, message: '编号太长'},
//{pattern: /^(?=.*([0-9a-zA-Z]){5}).[A-Za-z0-9]+$/, message: ''},
],
styleId: [
{required: true, message: '款式不能为空'},
],
stylemodelId: [
{required: true, message: '款式型号不能为空'},
],
userId: [
{required: true, message: '用户名不能为空'},// required:false
//{ pattern: /^\d{6,16}$/, message: '616!'}
],
descr: [
{pattern: /^[0-9A-Za-z\u4e00-\u9fa5]{0,200}$/, message: '文本长度过长'},
]
},
submitForm () {
const that = this;
url: {
add: "/zyclothsample/zyClothSample/add",
edit: "/zyclothsample/zyClothSample/edit",
queryById: "/zyclothsample/zyClothSample/queryById",
}
}
},
computed: {
formDisabled() {
return this.disabled;
}
},
created() {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
mounted() {
// TODO: -
const str = `${this.selectedKey}${this.typeid}${''}`;
// const str = undefined;
str ? this.nums = str : this.nums = this.nums;
console.log(this.props, 'superFieldList')
},
methods: {
add() {
this.edit(this.modelDefault);
},
//
//
this.$refs.form.validate(valid => {
if (valid) {
that.confirmLoading = true;
let httpurl = '';
let method = '';
if(!this.model.id){
httpurl+=this.url.add;
method = 'post';
}else{
httpurl+=this.url.edit;
method = 'put';
}
httpAction(httpurl,this.model,method).then((res)=>{
if(res.success){
that.$message.success(res.message);
that.$emit('ok');
}else{
that.$message.warning(res.message);
}
}).finally(() => {
that.confirmLoading = false;
})
// select
handleSelect(selectedKeys) {
this.selectedKey = selectedKeys;
},
// change
handletypeSelect(selectedKeys) {
this.type = selectedKeys;
},
edit(record) {
this.model = Object.assign({}, record);
this.visible = true;
}
,
submitForm() {
const that = this;
//
this.$refs.form.validate(valid => {
if (valid) {
that.confirmLoading = true;
let httpurl = '';
let method = '';
if (!this.model.id) {
httpurl += this.url.add;
method = 'post';
} else {
httpurl += this.url.edit;
method = 'put';
}
})
},
httpAction(httpurl, this.model, method).then((res) => {
if (res.success) {
that.$message.success(res.message);
that.$emit('ok');
} else {
that.$message.warning(res.message);
}
}).finally(() => {
that.confirmLoading = false;
})
}
})
}
,
}
}
</script>

@ -99,15 +99,15 @@
</template>
<span slot="action1" slot-scope="text, record">
<a @click="jumpPage(record)" >管理模块</a>
<a @click="jumpPage1(record)" >管理模块</a>
<a-divider type="vertical" />
<a @click="jumpPage(record)" >管理面料</a>
<a @click="jumpPage2(record)" >管理面料</a>
<a-divider type="vertical" />
<a @click="jumpPage(record)" >管理辅料</a>
<a @click="jumpPage3(record)" >管理辅料</a>
<a-divider type="vertical" />
<a @click="jumpPage(record)" >管理型号</a>
<a @click="jumpPage4(record)" >管理型号</a>
<a-divider type="vertical" />
<a @click="jumpPage(record)" >管理工序</a>
<a @click="jumpPage5(record)" >管理工序</a>
</span>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
@ -229,15 +229,38 @@
methods: {
initDictConfig(){
},
jumpPage(record)
{
jumpPage1(record) {
this.$router.push({
path: '/xxx/xxx',
path: '/src/views/zystylemodule/ZyStyleModuleList',
query: { //
'id': record.id,
}
});
},
jumpPage2(record) {
this.$router.push({
path: '/src/views/zystylefabric/ZyStyleFabricList',
query: { //
'id': record.id,
}
});
},
jumpPage4(record) {
this.$router.push({
path: '/src/views/zystylemodel/ZyStyleModelList',
query: { //
'id': record.id,
}
});
},
jumpPage5(record) {
this.$router.push({
path: '/process/ZyProcessList',
query: { //
'styleId': record.id,
}
});
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'popup',value:'typeId',text:'类型id', popup:{code:'zy_cloths_type',field:'type_name',orgFields:'type_name',destFields:'id'}})

@ -106,6 +106,8 @@
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import ZyStyleFabricModal from './modules/ZyStyleFabricModal'
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
import {getAction} from "@api/manage";
import {filterObj} from "@/utils/util";
export default {
name: 'ZyStyleFabricList',
@ -165,12 +167,16 @@
importExcelUrl: "zystylefabric/zyStyleFabric/importExcel",
},
//
loadRouteType:false,
id:"",
dictOptions:{},
superFieldList:[],
}
},
created() {
this.getSuperFieldList();
//this.getSuperFieldList();
this.loadParameter() ;
},
computed: {
importExcelUrl: function(){
@ -180,6 +186,58 @@
methods: {
initDictConfig(){
},
//
loadParameter() {
if (this.loadRouteType == false) {
this.id = this.$route.query.id;
console.log(this.id)
this.loadRouteType = true;
}
},
loadData(arg) {
if(!this.url.list){
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
//update-begin---author:zhangyafei Date:20201118 for------------
this.dataSource = res.result.records||res.result;
if(res.result.total)
{
this.ipagination.total = res.result.total;
}else{
this.ipagination.total = 0;
}
//update-end---author:zhangyafei Date:20201118 for------------
}else{
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
})
},
getQueryParams() {
//
let sqp = {}
if(this.superQueryParams){
sqp['superQueryParams']=encodeURI(this.superQueryParams)
sqp['superQueryMatchType'] = this.superQueryMatchType
}
var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.id=this.id;
return filterObj(param);
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'styleId',text:'款式id',dictCode:"zy_cloths_style,id,style_names"})

@ -0,0 +1,293 @@
<template>
<a-card :bordered="false">
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- table区域-begin -->
<div>
<j-vxe-table
toolbar
:toolbarConfig="toolbarConfig"
row-number
row-selection
keep-source
async-remove
:height="340"
:loading="loading"
:columns="columns"
:dataSource="dataSource"
:pagination="pagination"
style="margin-top: 8px;"
@pageChange="handlePageChange"
>
<template v-slot:action="props">
<a @click="submitForm(props)">保存</a>
<a-divider type="vertical"/>
<a-popconfirm title="确定删除吗?" @confirm="handleDelete(props.rowId)">
<a>删除</a>
</a-popconfirm>
</template>
</j-vxe-table>
</div>
<zy-style-model-modal ref="modalForm" @ok="modalFormOk"></zy-style-model-modal>
</a-card>
</template>
<script>
import '@/assets/less/TableExpand.less'
import { JVXETypes } from '@/components/jeecg/JVxeTable'
import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import ZyStyleModelModal from './modules/ZyStyleModelModal'
import {deleteAction, getAction, postAction, putAction, postFormAction, httpAction} from "@api/manage";
import store from "@/store";
import {filterObj, validateDuplicateValue} from '@/utils/util'
export default {
name: 'ZyStyleModelList',
mixins:[JeecgListMixin, mixinDevice],
components: {
ZyStyleModelModal
},
data () {
return {
description: 'zy_style_model管理页面',
//
//
toolbarConfig: {
// add remove clearSelection
btn: ['add']
},
validatorRules: {
styleId: [
{ required: true, message: '请选择服装类型!'},
],
},
//
loading: false,
//
pagination: {
//
current: 1,
//
pageSize: 10,
//
pageSizeOptions: ['10', '20', '30', '100', '200'],
// 0
total: 0,
showQuickJumper: true,
showSizeChanger: true,
id:null
},
//
columns: [
{
title: '款式',
width: '150px',
fixed: 'left',
key: 'styleId',
type: JVXETypes.select,
placeholder: '请输入${title}',
dictCode: 'zy_cloths_style,style_names,id',
validateRules: [{required: true, message: '${title}不能为空'}]
},
{
title:'是否默认尺码',
align:"center",
width: '150px',
key: 'isdefault',
type: JVXETypes.select,
dictCode: 'isdefault',
defaultValue : 0,
},
{key: 'modelNumber', title: '型号编码', dictCode: 'modenumber',width: '120px', type: JVXETypes.select},
{key: 'size', title: '码数', width: '100px',dictCode: 'size', type: JVXETypes.select},
{key: 'anumbers', title: '型', width: '100px',dictCode: 'xsize', type: JVXETypes.select},
{key: 'bnumbers', title: '号', width: '100px',dictCode: 'hsize', type: JVXETypes.select},
{key: 'collarLarge', title: '领大', width: '80px', 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},
{key: 'tsWidth', title: '总肩宽', width: '80px', type: JVXETypes.input},
{key: 'cuff', title: '袖口', width: '80px', type: JVXETypes.input},
{key: 'waistline', title: '腰围', width: '80px', type: JVXETypes.input},
{key: 'hem', title: '下摆', width: '80px', type: JVXETypes.input},
{
title: '操作',
key: 'action',
type: JVXETypes.slot,
fixed: 'right',
minWidth: '100px',
align: 'center',
slotName: 'action',
}
],
url: {
list: "/zystylemodel/zyStyleModel/list",
delete: "/zystylemodel/zyStyleModel/delete",
add: "/zystylemodel/zyStyleModel/add",
edit: "/zystylemodel/zyStyleModel/edit",
deleteBatch: "/zystylemodel/zyStyleModel/deleteBatch",
exportXlsUrl: "/zystylemodel/zyStyleModel/exportXls",
importExcelUrl: "zystylemodel/zyStyleModel/importExcel",
},
//
loadRouteType:false,
id:null,
rowId:'',
dictOptions:{},
superFieldList:[],
}
},
created() {
//this.loadData();
this.loadParameter() ;
//model
//this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
computed: {
importExcelUrl: function(){
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
methods: {
handleDelete: function (id) {
if(!this.url.delete){
this.$message.error("请设置url.delete属性!")
return
}
var that = this;
deleteAction(that.url.delete, {id: id}).then((res) => {
if (res.success) {
//
that.reCalculatePage(1)
that.$message.success(res.message);
that.loadData();
} else {
that.$message.warning(res.message);
}
});
},
submitForm (props) {
this.model = Object.assign({}, props);
var str = props.rowId;
let httpurl = '';
let method = '';
if (str.search("row") != -1) {
httpurl += this.url.add;
method = 'post';
} else {
httpurl += this.url.edit;
method = 'put';
}
httpAction(httpurl, props.row, method).then((res) => {
if (res.success) {
this.$message.success(res.message);
this.$emit('ok');
} else {
this.$message.warning(res.message);
}
})
},
//
loadParameter() {
if (this.loadRouteType == false) {
this.id = this.$route.query.id;
this.loadRouteType = true;
}
},
//
loadData(arg) {
// 1
if (arg === 1) {
this.pagination.current = 1;
}
//
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then(res => {
if (res.success) {
/*// 后台查询回来的 total数据总数量
this.pagination.total = res.result.total*/
// dataSource
this.dataSource = res.result.records||res.result;
console.log(this.dataSource,'abc')
if(res.result.total)
{
this.pagination.total = res.result.total;
}else{
this.pagination.total = 0;
}
//this.dataSource = res.result.records
} else {
this.$error({title: '主表查询失败', content: res.message})
}
}).finally(() => {
// loading
this.loading = false
})
},
//
handlePageChange(event) {
//
this.pagination.current = event.current
this.pagination.pageSize = event.pageSize
//
this.loadData()
},
initDictConfig(){
},
getQueryParams() {
//
let sqp = {}
if(this.superQueryParams){
sqp['superQueryParams']=encodeURI(this.superQueryParams)
sqp['superQueryMatchType'] = this.superQueryMatchType
}
var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.styleId=this.id
return filterObj(param);
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'styleId',text:'款式id',dictCode:''})
fieldList.push({type:'int',value:'isdefault',text:'是否默认尺码',dictCode:''})
fieldList.push({type:'int',value:'modelNumber',text:'型号编码',dictCode:''})
fieldList.push({type:'int',value:'size',text:'码数',dictCode:''})
fieldList.push({type:'string',value:'anumbers',text:'型',dictCode:''})
fieldList.push({type:'string',value:'bnumbers',text:'号',dictCode:''})
fieldList.push({type:'double',value:'collarLarge',text:'领大',dictCode:''})
fieldList.push({type:'double',value:'bust',text:'胸围',dictCode:''})
fieldList.push({type:'double',value:'sleeveLength',text:'袖长',dictCode:''})
fieldList.push({type:'double',value:'shslLength',text:'连肩袖长',dictCode:''})
fieldList.push({type:'double',value:'tsWidth',text:'总肩宽',dictCode:''})
fieldList.push({type:'double',value:'cuff',text:'袖口',dictCode:''})
fieldList.push({type:'double',value:'waistline',text:'腰围',dictCode:''})
fieldList.push({type:'double',value:'hem',text:'下摆',dictCode:''})
this.superFieldList = fieldList
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>

@ -0,0 +1,168 @@
<template>
<a-spin :spinning="confirmLoading">
<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="款式id" :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 :span="24">
<a-form-model-item label="是否默认尺码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="isdefault">
<a-input-number v-model="model.isdefault" placeholder="请输入是否默认尺码" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="型号编码" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="modelNumber">
<a-input-number v-model="model.modelNumber" placeholder="请输入型号编码" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="码数" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="size">
<a-input-number v-model="model.size" placeholder="请输入码数" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="anumbers">
<a-input v-model="model.anumbers" placeholder="请输入型" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bnumbers">
<a-input v-model="model.bnumbers" placeholder="请输入号" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="领大" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="collarLarge">
<a-input-number v-model="model.collarLarge" placeholder="请输入领大" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="胸围" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bust">
<a-input-number v-model="model.bust" placeholder="请输入胸围" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="袖长" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sleeveLength">
<a-input-number v-model="model.sleeveLength" placeholder="请输入袖长" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="连肩袖长" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shslLength">
<a-input-number v-model="model.shslLength" placeholder="请输入连肩袖长" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="总肩宽" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="tsWidth">
<a-input-number v-model="model.tsWidth" placeholder="请输入总肩宽" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="袖口" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="cuff">
<a-input-number v-model="model.cuff" placeholder="请输入袖口" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="腰围" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="waistline">
<a-input-number v-model="model.waistline" placeholder="请输入腰围" style="width: 100%" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="下摆" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="hem">
<a-input-number v-model="model.hem" placeholder="请输入下摆" style="width: 100%" />
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</j-form-container>
</a-spin>
</template>
<script>
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
export default {
name: 'ZyStyleModelForm',
components: {
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
},
data () {
return {
model:{
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
},
confirmLoading: false,
validatorRules: {
},
url: {
add: "/zystylemodel/zyStyleModel/add",
edit: "/zystylemodel/zyStyleModel/edit",
queryById: "/zystylemodel/zyStyleModel/queryById"
}
}
},
computed: {
formDisabled(){
return this.disabled
},
},
created () {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
methods: {
add () {
this.edit(this.modelDefault);
},
edit (record) {
this.model = Object.assign({}, record);
this.visible = true;
},
submitForm () {
const that = this;
//
this.$refs.form.validate(valid => {
if (valid) {
that.confirmLoading = true;
let httpurl = '';
let method = '';
if(!this.model.id){
httpurl+=this.url.add;
method = 'post';
}else{
httpurl+=this.url.edit;
method = 'put';
}
httpAction(httpurl,this.model,method).then((res)=>{
if(res.success){
that.$message.success(res.message);
that.$emit('ok');
}else{
that.$message.warning(res.message);
}
}).finally(() => {
that.confirmLoading = false;
})
}
})
},
}
}
</script>

@ -0,0 +1,84 @@
<template>
<a-drawer
:title="title"
:width="width"
placement="right"
:closable="false"
@close="close"
destroyOnClose
:visible="visible">
<zy-style-model-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></zy-style-model-form>
<div class="drawer-footer">
<a-button @click="handleCancel" style="margin-bottom: 0;">关闭</a-button>
<a-button v-if="!disableSubmit" @click="handleOk" type="primary" style="margin-bottom: 0;">提交</a-button>
</div>
</a-drawer>
</template>
<script>
import ZyStyleModelForm from './ZyStyleModelForm'
export default {
name: 'ZyStyleModelModal',
components: {
ZyStyleModelForm
},
data () {
return {
title:"操作",
width:800,
visible: false,
disableSubmit: false
}
},
methods: {
add () {
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.add();
})
},
edit (record) {
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.edit(record);
});
},
close () {
this.$emit('close');
this.visible = false;
},
submitCallback(){
this.$emit('ok');
this.visible = false;
},
handleOk () {
this.$refs.realForm.submitForm();
},
handleCancel () {
this.close()
}
}
}
</script>
<style lang="less" scoped>
/** Button按钮间距 */
.ant-btn {
margin-left: 30px;
margin-bottom: 30px;
float: right;
}
.drawer-footer{
position: absolute;
bottom: -8px;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
</style>

@ -0,0 +1,60 @@
<template>
<j-modal
:title="title"
:width="width"
:visible="visible"
switchFullscreen
@ok="handleOk"
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
@cancel="handleCancel"
cancelText="关闭">
<zy-style-model-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></zy-style-model-form>
</j-modal>
</template>
<script>
import ZyStyleModelForm from './ZyStyleModelForm'
export default {
name: 'ZyStyleModelModal',
components: {
ZyStyleModelForm
},
data () {
return {
title:'',
width:800,
visible: false,
disableSubmit: false
}
},
methods: {
add () {
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.add();
})
},
edit (record) {
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.edit(record);
})
},
close () {
this.$emit('close');
this.visible = false;
},
handleOk () {
this.$refs.realForm.submitForm();
},
submitCallback(){
this.$emit('ok');
this.visible = false;
},
handleCancel () {
this.close()
}
}
}
</script>

@ -122,6 +122,8 @@ import {mixinDevice} from '@/utils/mixin'
import {JeecgListMixin} from '@/mixins/JeecgListMixin'
import ZyStyleModuleModal from './modules/ZyStyleModuleModal'
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
import {getAction} from "@api/manage";
import {filterObj} from "@/utils/util";
export default {
name: 'ZyStyleModuleList',
@ -186,12 +188,16 @@ export default {
importExcelUrl: "zystylemodule/zyStyleModule/importExcel",
},
//
loadRouteType:false,
id:"",
dictOptions: {},
superFieldList: [],
}
},
created() {
this.getSuperFieldList();
//this.getSuperFieldList();
this.loadParameter() ;
},
computed: {
importExcelUrl: function () {
@ -201,6 +207,58 @@ export default {
methods: {
initDictConfig() {
},
//
loadParameter() {
if (this.loadRouteType == false) {
this.id = this.$route.query.id;
console.log(this.id)
this.loadRouteType = true;
}
},
loadData(arg) {
if(!this.url.list){
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
//update-begin---author:zhangyafei Date:20201118 for------------
this.dataSource = res.result.records||res.result;
if(res.result.total)
{
this.ipagination.total = res.result.total;
}else{
this.ipagination.total = 0;
}
//update-end---author:zhangyafei Date:20201118 for------------
}else{
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
})
},
getQueryParams() {
//
let sqp = {}
if(this.superQueryParams){
sqp['superQueryParams']=encodeURI(this.superQueryParams)
sqp['superQueryMatchType'] = this.superQueryMatchType
}
var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters);
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.id=this.id;
return filterObj(param);
},
getSuperFieldList() {
let fieldList = [];
fieldList.push({type: 'string', value: 'typeId', text: '类型id', dictCode: "zy_cloths_type,id,type_name"})

@ -5,6 +5,7 @@ import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.demo.accessories.entity.ZyAccessories;
import org.jeecg.modules.demo.base.entity.ZyAllProcess;
import org.jeecg.modules.demo.base.entity.ZyClothAction;
@ -71,8 +72,8 @@ public class ZyProcessController extends JeecgController<ZyProcess, IZyProcessSe
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
//QueryWrapper<ZyProcess> queryWrapper = QueryGenerator.initQueryWrapper(zyProcess, req.getParameterMap());
QueryWrapper queryWrapper = new QueryWrapper();
QueryWrapper<ZyProcess> queryWrapper = QueryGenerator.initQueryWrapper(zyProcess, req.getParameterMap());
//QueryWrapper queryWrapper = new QueryWrapper();
Page<ZyProcess> page = new Page<ZyProcess>(pageNo, pageSize);
IPage<ZyProcess> pageList = zyProcessService.page(page, queryWrapper);
return Result.OK(pageList);

@ -141,6 +141,7 @@ public class ZyProcess implements Serializable {
/**款式名称*/
@Excel(name = "款式名称", width = 15)
@ApiModelProperty(value = "款式名称")
@Dict(dictTable = "zy_cloths_style", dicText = "style_names", dicCode = "id")
private java.lang.String styleId;
/**工段代码*/
@Excel(name = "工段代码", width = 15)

@ -82,6 +82,11 @@ public class ZyClothSampleController extends JeecgController<ZyClothSample, IZyC
@ApiOperation(value="成衣样板-添加", notes="成衣样板-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody ZyClothSample zyClothSample) {
/*if (zyClothSample.getStyleId()==null){
return Result.error("款式不能为空");
}
if (zyClothSample.getModelSample()==null)
return Result.error("模块样板不能为空");*/
zyClothSampleService.save(zyClothSample);
return Result.OK("添加成功!");
}
@ -96,8 +101,20 @@ public class ZyClothSampleController extends JeecgController<ZyClothSample, IZyC
@ApiOperation(value="成衣样板-编辑", notes="成衣样板-编辑")
@PutMapping(value = "/edit")
public Result<?> edit(@RequestBody ZyClothSample zyClothSample) {
//查询所有
List<ZyClothSample> zyClothSampleList = zyClothSampleService.list();
//查询编辑行的数据
ZyClothSample clothSample = zyClothSampleService.getById(zyClothSample.getId());
//移除编辑行数据
zyClothSampleList.remove(clothSample);
//将编辑行数据与其它数据比较 如果重复 报错
for (ZyClothSample cloth: zyClothSampleList) {
if (cloth.getNums().equals(zyClothSample.getNums())){
return Result.error("编号重复,请重新输入");
}
}
zyClothSampleService.updateById(zyClothSample);
return Result.OK("编辑成功!");
return Result.OK("编辑成功");
}
/**

@ -13,6 +13,7 @@ import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.Date;
@ -38,13 +39,20 @@ public class ZyClothSample implements Serializable {
@Excel(name = "编号", width = 15)
@ApiModelProperty(value = "编号")
private String nums;
/**款式*/
/**
* 款式
* 关联服装款式表 zy_cloths_style
* 把数据id转换成style_names 因为前端一些问题 这里已不在需要
*/
@Excel(name = "款式", width = 15)
@ApiModelProperty(value = "款式")
//@Dict(dicCode = "id",dictTable = "zy_cloths_style",dicText = "style_names")
private String styleId;
/**型号*/
@Excel(name = "型号", width = 15)
@ApiModelProperty(value = "型号")
@Dict(dicCode = "modenumber", dictTable = "", dicText = "")
private String stylemodelId;
/**管理模块样板*/
@ -56,6 +64,7 @@ public class ZyClothSample implements Serializable {
@Excel(name = "模块样板", width = 15)
@ApiModelProperty(value = "模块样板")
@Dict(dicCode = "id",dictTable = "zy_module_sample",dicText = "module_name")
//@NotBlank(message = "模块样板不能为空")
private String modelSample;
/**用户*/
@Excel(name = "用户", width = 15)
@ -66,7 +75,14 @@ public class ZyClothSample implements Serializable {
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
@ApiModelProperty(value = "更新人")
private java.lang.String updateBy;
/**更新日期*/
@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;
/**成衣名称*/
@Excel(name = "成衣名称", width = 15)

@ -81,11 +81,14 @@ public class ZyStyleFabricController extends JeecgController<ZyStyleFabric, IZyS
//@AutoLog(value = "款式面料表-分页列表查询")
@ApiOperation(value="款式面料表-分页列表查询", notes="款式面料表-分页列表查询")
@GetMapping(value = "/list")
public Result<IPage<NewZyStyleFabric>> queryPageList(ZyStyleFabric zyStyleFabric,
public Result<IPage<NewZyStyleFabric>> queryPageList(ZyStyleFabric zyStyleFabric,String id,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
QueryWrapper<ZyStyleFabric> queryWrapper = new QueryWrapper<>();
if(id!=null){
queryWrapper.eq("style_id",id);
}
if(zyStyleFabric.getStyleId()!=null || zyStyleFabric.getFabricId()!=null ){
if(zyStyleFabric.getStyleId()!=null){
queryWrapper.eq("style_id",zyStyleFabric.getStyleId());

@ -0,0 +1,189 @@
package org.jeecg.modules.zystylemodel.controller;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.alibaba.fastjson.JSONObject;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModel;
import org.jeecg.modules.zystylemodel.service.IZyStyleModelService;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
import org.jeecg.common.system.base.controller.JeecgController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import org.springframework.web.servlet.ModelAndView;
import com.alibaba.fastjson.JSON;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.jeecg.common.aspect.annotation.AutoLog;
/**
* @Description: zy_style_model
* @Author: jeecg-boot
* @Date: 2022-09-17
* @Version: V1.0
*/
@Api(tags="zy_style_model")
@RestController
@RequestMapping("/zystylemodel/zyStyleModel")
@Slf4j
public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZyStyleModelService> {
@Autowired
private IZyStyleModelService zyStyleModelService;
/**
* 分页列表查询
*
* @param zyStyleModel
* @param pageNo
* @param pageSize
* @param req
* @return
*/
//@AutoLog(value = "zy_style_model-分页列表查询")
@ApiOperation(value="zy_style_model-分页列表查询", notes="zy_style_model-分页列表查询")
@GetMapping(value = "/list")
public Result<IPage<ZyStyleModel>> queryPageList(ZyStyleModel zyStyleModel,String id,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
QueryWrapper<ZyStyleModel> queryWrapper = QueryGenerator.initQueryWrapper(zyStyleModel, req.getParameterMap());
System.out.println(zyStyleModel.getStyleId());
//queryWrapper.eq("style_id", id);
Page<ZyStyleModel> page = new Page<ZyStyleModel>(pageNo, pageSize);
IPage<ZyStyleModel> pageList = zyStyleModelService.page(page, queryWrapper);
return Result.OK(pageList);
}
/**
* 添加
*
* @param zyStyleModel
* @return
*/
@AutoLog(value = "zy_style_model-添加")
@ApiOperation(value="zy_style_model-添加", notes="zy_style_model-添加")
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:add")
@PostMapping(value = "/add")
public Result<String> add(@RequestBody ZyStyleModel zyStyleModel) {
zyStyleModel.setId(null);
System.out.println(zyStyleModel);
zyStyleModelService.save(zyStyleModel);
return Result.OK("添加成功!");
}
/**
* 编辑
*
* @param zyStyleModel
* @return
*/
@AutoLog(value = "zy_style_model-编辑")
@ApiOperation(value="zy_style_model-编辑", notes="zy_style_model-编辑")
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:edit")
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
public Result<String> edit(@RequestBody ZyStyleModel zyStyleModel) {
zyStyleModelService.updateById(zyStyleModel);
return Result.OK("编辑成功!");
}
/**
* 通过id删除
*
* @param id
* @return
*/
@AutoLog(value = "zy_style_model-通过id删除")
@ApiOperation(value="zy_style_model-通过id删除", notes="zy_style_model-通过id删除")
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:delete")
@RequestMapping(value = "/delete")
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
zyStyleModelService.removeById(id);
return Result.OK("删除成功!");
}
/**
* 批量删除
*
* @param
* @return
*/
@AutoLog(value = "zy_style_model-批量删除")
@ApiOperation(value="zy_style_model-批量删除", notes="zy_style_model-批量删除")
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:deleteBatch")
@DeleteMapping(value = "/deleteBatch" )
public Result<String> deleteBatch(@RequestBody Map map) {
List<String> idList = (List<String>) map.get("id");
// List<Integer> list = Arrays.asList(ids);
zyStyleModelService.removeByIds(idList);
System.out.println(map);
//this.zyStyleModelService.removeByIds(Arrays.asList(map.get("deleteIds").split(",")));
return Result.OK("批量删除成功!");
}
/**
* 通过id查询
*
* @param id
* @return
*/
//@AutoLog(value = "zy_style_model-通过id查询")
@ApiOperation(value="zy_style_model-通过id查询", notes="zy_style_model-通过id查询")
@GetMapping(value = "/queryById")
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
ZyStyleModel zyStyleModel = zyStyleModelService.getById(id);
if(zyStyleModel==null) {
return Result.error("未找到对应数据");
}
return Result.OK(zyStyleModel);
}
/**
* 导出excel
*
* @param request
* @param zyStyleModel
*/
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:exportXls")
@RequestMapping(value = "/exportXls")
public ModelAndView exportXls(HttpServletRequest request, ZyStyleModel zyStyleModel) {
return super.exportXls(request, zyStyleModel, ZyStyleModel.class, "zy_style_model");
}
/**
* 通过excel导入数据
*
* @param request
* @param response
* @return
*/
//@RequiresPermissions("zy_style_model:importExcel")
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
return super.importExcel(request, response, ZyStyleModel.class);
}
}

@ -0,0 +1,100 @@
package org.jeecg.modules.zystylemodel.entity;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
/**
* @Description: zy_style_model
* @Author: jeecg-boot
* @Date: 2022-09-17
* @Version: V1.0
*/
@Data
@TableName("zy_style_model")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="zy_style_model对象", description="zy_style_model")
public class ZyStyleModel implements Serializable {
private static final long serialVersionUID = 1L;
/**内部编号*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "内部编号")
private java.lang.String id;
/**款式id*/
@Excel(name = "款式id", width = 15)
@Dict(dictTable = "zy_cloths_style", dicText = "style_names", dicCode = "id")
@ApiModelProperty(value = "款式id")
private java.lang.String styleId;
/**是否默认尺码*/
@Excel(name = "是否默认尺码", width = 15)
@ApiModelProperty(value = "是否默认尺码")
private java.lang.Integer isdefault;
/**型号编码*/
@Excel(name = "型号编码", width = 15)
@ApiModelProperty(value = "型号编码")
private java.lang.Integer modelNumber;
/**码数*/
@Excel(name = "码数", width = 15)
@ApiModelProperty(value = "码数")
private java.lang.Integer size;
/**型*/
@Excel(name = "型", width = 15)
@ApiModelProperty(value = "型")
private java.lang.String anumbers;
/**号*/
@Excel(name = "号", width = 15)
@ApiModelProperty(value = "号")
private java.lang.String bnumbers;
/**领大*/
@Excel(name = "领大", width = 15)
@ApiModelProperty(value = "领大")
private java.lang.Float collarLarge;
/**胸围*/
@Excel(name = "胸围", width = 15)
@ApiModelProperty(value = "胸围")
private java.lang.Float bust;
/**袖长*/
@Excel(name = "袖长", width = 15)
@ApiModelProperty(value = "袖长")
private java.lang.Float sleeveLength;
/**连肩袖长*/
@Excel(name = "连肩袖长", width = 15)
@ApiModelProperty(value = "连肩袖长")
private java.lang.Float shslLength;
/**总肩宽*/
@Excel(name = "总肩宽", width = 15)
@ApiModelProperty(value = "总肩宽")
private java.lang.Float tsWidth;
/**袖口*/
@Excel(name = "袖口", width = 15)
@ApiModelProperty(value = "袖口")
private java.lang.Float cuff;
/**腰围*/
@Excel(name = "腰围", width = 15)
@ApiModelProperty(value = "腰围")
private java.lang.Float waistline;
/**下摆*/
@Excel(name = "下摆", width = 15)
@ApiModelProperty(value = "下摆")
private java.lang.Float hem;
/**创建时间*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern="yyyy-MM-dd")
@ApiModelProperty(value = "创建时间")
private java.util.Date createTime;
}

@ -0,0 +1,17 @@
package org.jeecg.modules.zystylemodel.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModel;
/**
* @Description: zy_style_model
* @Author: jeecg-boot
* @Date: 2022-09-17
* @Version: V1.0
*/
public interface ZyStyleModelMapper extends BaseMapper<ZyStyleModel> {
}

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.zystylemodel.mapper.ZyStyleModelMapper">
</mapper>

@ -0,0 +1,15 @@
package org.jeecg.modules.zystylemodel.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModel;
/**
* @Description: zy_style_model
* @Author: jeecg-boot
* @Date: 2022-09-17
* @Version: V1.0
*/
public interface IZyStyleModelService extends IService<ZyStyleModel> {
}

@ -0,0 +1,20 @@
package org.jeecg.modules.zystylemodel.service.impl;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModel;
import org.jeecg.modules.zystylemodel.mapper.ZyStyleModelMapper;
import org.jeecg.modules.zystylemodel.service.IZyStyleModelService;
import org.springframework.stereotype.Service;
/**
* @Description: zy_style_model
* @Author: jeecg-boot
* @Date: 2022-09-17
* @Version: V1.0
*/
@Service
public class ZyStyleModelServiceImpl extends ServiceImpl<ZyStyleModelMapper, ZyStyleModel> implements IZyStyleModelService {
}

@ -77,13 +77,15 @@ public class ZyStyleModuleController extends JeecgController<ZyStyleModule, IZyS
@AutoLog(value = "款式模块表-分页列表查询")
@ApiOperation(value="款式模块表-分页列表查询", notes="款式模块表-分页列表查询")
@GetMapping(value = "/list")
public Result<?> queryPageList(ZyStyleModule zyStyleModule2,
public Result<?> queryPageList(ZyStyleModule zyStyleModule2,String id,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
List<NewStyleModule> listNewStyleModules = new ArrayList<>();
QueryWrapper<ZyStyleModule> queryWrapper = new QueryWrapper<>();
if(id!=null){
queryWrapper.eq("style_id",id);
}
if(zyStyleModule2.getStyleId()!=null || zyStyleModule2.getModularId()!=null || zyStyleModule2.getTypeId()!=null){
if(zyStyleModule2.getStyleId()!=null){
queryWrapper.eq("style_id",zyStyleModule2.getStyleId());

Loading…
Cancel
Save