喻忠伟 2 years ago
commit fdbfefcd11
  1. 2
      ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue
  2. 19
      ant-design-vue-jeecg/src/views/goodsaccessories/GoodsAccessoriesList.vue
  3. 239
      ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesForm.vue
  4. 31
      ant-design-vue-jeecg/src/views/goodsaccessories/modules/GoodsAccessoriesModal.vue
  5. 19
      ant-design-vue-jeecg/src/views/goodsfabric/GoodsFabricList.vue
  6. 291
      ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricForm.vue
  7. 31
      ant-design-vue-jeecg/src/views/goodsfabric/modules/GoodsFabricModal.vue
  8. 30
      ant-design-vue-jeecg/src/views/product/productModule/ProductModuleList.vue
  9. 305
      ant-design-vue-jeecg/src/views/product/productSample/ProductSampleList.vue
  10. 125
      ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleDetail.vue
  11. 229
      ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleForm.vue
  12. 60
      ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal.vue
  13. 84
      ant-design-vue-jeecg/src/views/product/productSample/modules/ZyClothSampleModal__Style#Drawer.vue
  14. 2
      ant-design-vue-jeecg/src/views/team/StationMachineList.vue
  15. 4
      ant-design-vue-jeecg/src/views/team/StationToolList.vue
  16. 19
      ant-design-vue-jeecg/src/views/zyorders/ZyOrdersList.vue
  17. 25
      ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue
  18. 13
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsaccessories/controller/GoodsAccessoriesController.java
  19. 13
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/goodsfabric/controller/GoodsFabricController.java
  20. 18
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyorders/controller/ZyOrdersController.java
  21. 7
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java
  22. 9
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java
  23. 5
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java
  24. 5
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationTool.java
  25. 6
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java

@ -5,7 +5,7 @@
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :sm="5">
<a-form-model-item label="设备编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="id">
<a-form-model-item label="设备编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="code">
<a-input v-model="queryParam.code" placeholder="请输入设备编号"></a-input>
</a-form-model-item>
</a-col>

@ -81,28 +81,18 @@
</template>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<!-- <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>
<a @click="handleDetail(record)">详情</a>
</a-menu-item>
<a-menu-item>
<a-divider type="vertical" />-->
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>
</a-table>
</div>
<goods-accessories-modal ref="modalForm" @ok="modalFormOk"></goods-accessories-modal>
<goods-accessories-modal ref="modalForm" @ok="modalFormOk" @valueChange="valueChange"></goods-accessories-modal>
</a-card>
</template>
@ -197,6 +187,9 @@
}
});
},
valueChange(value) {
if (value) this.loadData()
},
initDictConfig(){
},
getSuperFieldList(){

@ -1,115 +1,188 @@
<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="商品" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="goodsId">
<j-dict-select-tag type="list" v-model="model.goodsId" :dictCode="goods" placeholder="请选择商品" />
</a-form-model-item>
<a-card :bordered="false">
<!-- 查询区域 -->
<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="辅料编号">
<a-input placeholder="请输入辅料编号" v-model="queryParam.nums"></a-input>
</a-form-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="辅料" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="accessoriesId">
<j-dict-select-tag type="list" v-model="model.accessoriesId" dictCode="zy_accessories,contents,id" placeholder="请选择辅料" />
</a-form-model-item>
<a-col :xl="10" :lg="7" :md="8" :sm="24">
<a-form-item label="辅料名称">
<a-input placeholder="请输入辅料名称" v-model="queryParam.contents"></a-input>
</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-model>
</j-form-container>
</a-spin>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- 操作按钮区域 -->
<!-- <div class="table-operator">-->
<!-- </div>-->
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a
style="font-weight: 600">{{ selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-table
ref="table"
size="middle"
:scroll="{x:true}"
bordered
rowKey="id"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange1}"
class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" height="25px" alt=""
style="max-width:80px;font-size: 12px;font-style: italic;"/>
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button
v-else
:ghost="true"
type="primary"
icon="download"
size="small"
@click="downloadFile(text)">
下载
</a-button>
</template>
</a-table>
</div>
</a-card>
</template>
<script>
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
import '@/assets/less/TableExpand.less'
import {mixinDevice} from '@/utils/mixin'
import {JeecgListMixin} from '@/mixins/JeecgListMixin'
export default {
name: 'GoodsAccessoriesForm',
mixins: [JeecgListMixin, mixinDevice],
components: {
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
},
data() {
return {
goods:"zy_goods,goods_name,id,id="+this.$route.query.goodsid,
model:{
description: 'zy_accessories管理页面',
//
columns: [
{
title: '#',
dataIndex: '',
key: 'rowIndex',
width: 60,
align: "center",
customRender: function (t, r, index) {
return parseInt(index) + 1;
}
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
{
title: '类型',
align: "center",
dataIndex: 'typeId_dictText'
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
{
title: '编号',
align: "center",
dataIndex: 'nums'
},
confirmLoading: false,
validatorRules: {
goodsId: [
{ required: true, message: '请选择商品!'},
],
accessoriesId: [
{ required: true, message: '请选择辅料!'},
],
{
title: '名称',
align: "center",
dataIndex: 'contents',
// width:10,
// colspan:2
},
{
title: '图片',
align: "center",
dataIndex: 'picture'
},
{
title: '材质',
align: "center",
dataIndex: 'material'
},
{
title: '规格',
align: "center",
dataIndex: 'specs'
},
],
url: {
add: "/goodsaccessories/goodsAccessories/add",
edit: "/goodsaccessories/goodsAccessories/edit",
queryById: "/goodsaccessories/goodsAccessories/queryById"
}
list: "/accessories/zyAccessories/list",
delete: "/accessories/zyAccessories/delete",
deleteBatch: "/accessories/zyAccessories/deleteBatch",
exportXlsUrl: "/accessories/zyAccessories/exportXls",
importExcelUrl: "accessories/zyAccessories/importExcel",
},
dictOptions: {},
superFieldList: [],
}
},
computed: {
formDisabled(){
return this.disabled
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
created() {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
this.getSuperFieldList();
},
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';
onSelectChange1(selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys;
this.selectionRows = selectionRows;
let ids = "";
for (var a = 0; a < this.selectedRowKeys.length; a++) {
ids += this.selectedRowKeys[a] + ",";
}
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;
})
}
})
this.$emit('onChangeRowKey', ids)
},
add() {
},
initDictConfig() {
},
getSuperFieldList() {
let fieldList = [];
fieldList.push({type: 'string', value: 'typeId', text: '类型id'})
fieldList.push({type: 'string', value: 'nums', text: '编号'})
fieldList.push({type: 'string', value: 'contents', text: '名称'})
fieldList.push({type: 'string', value: 'picture', text: '图片'})
fieldList.push({type: 'string', value: 'material', text: '材质'})
fieldList.push({type: 'string', value: 'specs', text: '规格'})
fieldList.push({type: 'int', value: 'store', text: '库存量'})
fieldList.push({type: 'string', value: 'supplierInfo', text: '供货商信息'})
this.superFieldList = fieldList
},
}
}

@ -8,13 +8,14 @@
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
@cancel="handleCancel"
cancelText="关闭">
<goods-accessories-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></goods-accessories-form>
<goods-accessories-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" @onChangeRowKey="chuancan"></goods-accessories-form>
</j-modal>
</template>
<script>
import GoodsAccessoriesForm from './GoodsAccessoriesForm'
import {postAction} from "../../../api/manage";
export default {
name: 'GoodsAccessoriesModal',
components: {
@ -22,14 +23,24 @@
},
data () {
return {
model: {
goodsId:'',
accessoriesId:''
},
url: {
add: "/goodsaccessories/goodsAccessories/add",
edit: "/goodsaccessories/goodsAccessories/edit",
queryById: "/goodsaccessories/goodsAccessories/queryById"
},
title:'',
width:800,
width:1500,
visible: false,
disableSubmit: false
}
},
methods: {
add () {
this.model.goodsId = this.$route.query.goodsid;
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.add();
@ -46,7 +57,16 @@
this.visible = false;
},
handleOk () {
this.$refs.realForm.submitForm();
postAction(this.url.add,this.model).then((res)=>{
if(res.success){
this.$message.success(res.message);
}else{
this.$message.warning(res.message);
}
this.$emit('valueChange',1)
this.close()
})
},
submitCallback(){
this.$emit('ok');
@ -54,7 +74,10 @@
},
handleCancel () {
this.close()
}
},
chuancan(res) {
this.model.accessoriesId = res;
},
}
}
</script>

@ -81,28 +81,18 @@
</template>
<span slot="action" slot-scope="text, record">
<a @click="handleEdit(record)">编辑</a>
<!-- <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>
<a @click="handleDetail(record)">详情</a>
</a-menu-item>
<a-menu-item>
<a-divider type="vertical" />-->
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>
</a-table>
</div>
<goods-fabric-modal ref="modalForm" @ok="modalFormOk"></goods-fabric-modal>
<goods-fabric-modal ref="modalForm" @ok="modalFormOk" @valueChange="valueChange"></goods-fabric-modal>
</a-card>
</template>
@ -199,6 +189,9 @@
},
initDictConfig(){
},
valueChange(value) {
if (value) this.loadData()
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'goodsId',text:'商品',dictCode:'zy_goods,goods_name,id'})

@ -1,116 +1,243 @@
<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="商品" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="goodsId">
<j-dict-select-tag type="list" v-model="model.goodsId" :dictCode="goods" placeholder="请选择商品" />
</a-form-model-item>
<a-card :bordered="false">
<!-- 查询区域 -->
<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-search-select-tag placeholder="请选择花样" v-model="queryParam.pattern" dict="pattern"/>-->
<!-- </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.typeId"></a-input>
</a-form-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="面料" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="fabricId">
<j-dict-select-tag type="list" v-model="model.fabricId" dictCode="zy_fabric,name,id" placeholder="请选择面料" />
</a-form-model-item>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="编号">
<a-input placeholder="编号" v-model="queryParam.fabricNumber"></a-input>
</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.name"></a-input>
</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.color"></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="花样">
<j-search-select-tag placeholder="请选择花样" v-model="queryParam.pattern" dict="pattern"/>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="材质">
<j-search-select-tag placeholder="请选择材质" v-model="queryParam.material" dict="material"/>
</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-model>
</j-form-container>
</a-spin>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- 操作按钮区域 -->
<div class="table-operator">
</div>
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-table
ref="table"
size="middle"
:scroll="{x:true}"
bordered
rowKey="id"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange1}"
class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<img v-else :src="getImgView(text)" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
</template>
<template slot="imgeSlot" slot-scope="text">
<img :src="text" height="" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button
v-else
:ghost="true"
type="primary"
icon="download"
size="small"
@click="downloadFile(text)">
下载
</a-button>
</template>
<script>
</a-table>
</div>
</a-card>
</template>
<script>
import '@/assets/less/TableExpand.less'
import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
export default {
name: 'GoodsFabricForm',
mixins:[JeecgListMixin, mixinDevice],
components: {
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
},
data () {
return {
goods:"zy_goods,goods_name,id,id="+this.$route.query.goodsid,
model:{
description: '面料表管理页面',
//
columns: [
{
title: '#',
dataIndex: '',
key:'rowIndex',
width:60,
align:"center",
customRender:function (t,r,index) {
return parseInt(index)+1;
}
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
{
title:'类型',
align:"center",
dataIndex: 'typeId_dictText'
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
{
title:'编号',
align:"center",
dataIndex: 'fabricNumber'
},
confirmLoading: false,
validatorRules: {
goodsId: [
{ required: true, message: '请选择商品!'},
],
fabricId: [
{ required: true, message: '请选择面料!'},
],
{
title:'名称',
align:"center",
dataIndex: 'name'
},
{
title:'颜色',
align:"center",
dataIndex: 'color'
},
{
title:'花样',
align:"center",
dataIndex: 'pattern_dictText'
},
{
title:'材质',
align:"center",
dataIndex: 'material_dictText'
},
{
title:'厚度',
align:"center",
dataIndex: 'ply_dictText'
},
{
title:'单价',
align:"center",
dataIndex: 'money'
},
{
title:'零售价',
align:"center",
dataIndex: 'retailPrice'
},
],
url: {
add: "/goodsfabric/goodsFabric/add",
edit: "/goodsfabric/goodsFabric/edit",
queryById: "/goodsfabric/goodsFabric/queryById"
}
list: "/fabric/zyFabric/list",
delete: "/fabric/zyFabric/delete",
deleteBatch: "/fabric/zyFabric/deleteBatch",
exportXlsUrl: "/fabric/zyFabric/exportXls",
importExcelUrl: "/fabric/zyFabric/importExcel",
},
dictOptions:{},
superFieldList:[],
}
},
computed: {
formDisabled(){
return this.disabled
importExcelUrl: function(){
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
created() {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
this.getSuperFieldList();
},
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;
})
initDictConfig(){
},
onSelectChange1(selectedRowKeys, selectionRows) {
this.selectedRowKeys = selectedRowKeys;
this.selectionRows = selectionRows;
let ids = "";
for (var a = 0; a < this.selectedRowKeys.length; a++) {
ids += this.selectedRowKeys[a] + ",";
}
})
this.$emit('onChangeRowKey',ids)
},
add () {
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'color',text:'颜色',dictCode:''})
fieldList.push({type:'sel_search',value:'pattern',text:'花样',dictTable:'', dictText:'', dictCode:'pattern'})
fieldList.push({type:'sel_search',value:'material',text:'材质',dictTable:'', dictText:'', dictCode:'material'})
fieldList.push({type:'sel_search',value:'ply',text:'厚度',dictTable:'ply', dictText:'', dictCode:''})
fieldList.push({type:'int',value:'money',text:'单价',dictCode:''})
fieldList.push({type:'string',value:'imageUrl',text:'图片地址',dictCode:''})
fieldList.push({type:'popup',value:'typeId',text:'面料类型id', popup:{code:'zy_fabric_type',field:'id',orgFields:'id',destFields:'content'}})
fieldList.push({type:'sel_search',value:'brandId',text:'材料品牌id',dictTable:'brand', dictText:'', dictCode:''})
fieldList.push({type:'string',value:'fabricNumber',text:'材料编号',dictCode:''})
fieldList.push({type:'int',value:'unit',text:'1、为m。2:kg,等',dictCode:'unit1,,'})
fieldList.push({type:'int',value:'retailPrice',text:'零售价',dictCode:''})
fieldList.push({type:'sel_search',value:'density',text:'密度',dictTable:'density', dictText:'', dictCode:''})
fieldList.push({type:'string',value:'clothW',text:'幅宽',dictCode:'clothW,,'})
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:'fabricGrade',text:'等级',dictCode:'fabric_grade,,'})
fieldList.push({type:'string',value:'qRcode',text:'二维码',dictCode:''})
fieldList.push({type:'string',value:'name',text:'名称',dictCode:''})
fieldList.push({type:'sel_depart',value:'supplierInfo',text:'供货商信息'})
fieldList.push({type:'string',value:'createTime',text:'创建时间',dictCode:''})
this.superFieldList = fieldList
},
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>

@ -8,13 +8,14 @@
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
@cancel="handleCancel"
cancelText="关闭">
<goods-fabric-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></goods-fabric-form>
<goods-fabric-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" @onChangeRowKey="chuancan"></goods-fabric-form>
</j-modal>
</template>
<script>
import GoodsFabricForm from './GoodsFabricForm'
import {postAction} from "../../../api/manage";
export default {
name: 'GoodsFabricModal',
components: {
@ -22,14 +23,24 @@
},
data () {
return {
model:{
goodsId:'',
fabricId:''
},
url: {
add: "/goodsfabric/goodsFabric/add",
edit: "/goodsfabric/goodsFabric/edit",
queryById: "/goodsfabric/goodsFabric/queryById"
},
title:'',
width:800,
width:1500,
visible: false,
disableSubmit: false
}
},
methods: {
add () {
this.model.goodsId = this.$route.query.goodsid;
this.visible=true
this.$nextTick(()=>{
this.$refs.realForm.add();
@ -46,7 +57,16 @@
this.visible = false;
},
handleOk () {
this.$refs.realForm.submitForm();
postAction(this.url.add,this.model).then((res)=>{
if(res.success){
this.$message.success(res.message);
}else{
this.$message.warning(res.message);
}
this.$emit('valueChange',1)
this.close()
})
},
submitCallback(){
this.$emit('ok');
@ -54,7 +74,10 @@
},
handleCancel () {
this.close()
}
},
chuancan(res){
this.model.fabricId=res;
},
}
}
</script>

@ -17,13 +17,13 @@
<a-button type="primary" icon="import">导入</a-button>
</a-upload>
<!-- 高级查询区域 -->
<j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>
<a-dropdown v-if="selectedRowKeys.length > 0">
<a-menu slot="overlay">
<a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
</a-menu>
<a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
</a-dropdown>
<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>-->
<!-- <a-dropdown v-if="selectedRowKeys.length > 0">-->
<!-- <a-menu slot="overlay">-->
<!-- <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>-->
<!-- </a-menu>-->
<!-- <a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>-->
<!-- </a-dropdown>-->
</div>
<!-- table区域-begin -->
@ -69,21 +69,12 @@
<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>
<a @click="handleDetail(record)">详情</a>
</a-menu-item>
<a-menu-item>
<a-divider type="vertical" />
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>
</a-table>
@ -141,6 +132,11 @@
align:"center",
dataIndex: 'place'
},
{
title: '创建时间',
align: "center",
dataIndex: 'createTime'
},
{
title: '操作',
dataIndex: 'action',

@ -0,0 +1,305 @@
<template>
<!--成衣样板管理页面 这是成衣样板的主表单 即在侧边点击成衣样板所显示的表单-->
<a-card :bordered="false">
<!-- 查询区域 -->
<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="编号">
<a-input placeholder="请输入编号" v-model="queryParam.nums"></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="服装款式">
<j-dict-select-tag v-model="queryParam.styleId"
placeholder="请选择服装款式"
dict-code="zy_cloths_style,style_names,nums">
</j-dict-select-tag>
<!-- <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">
<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>
<!-- <a @click="handleToggleSearch" style="margin-left: 8px">
{{ toggleSearchStatus ? '收起' : '展开' }}
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
</a>-->
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-END -->
<!-- 操作按钮区域 -->
<div class="table-operator">
<!-- <a-button @click="handleAdd" 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>-->
<!-- </a-upload>-->
<!-- 高级查询区域 -->
<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal"-->
<!-- @handleSuperQuery="handleSuperQuery"></j-super-query>-->
<!-- <a-dropdown v-if="selectedRowKeys.length > 0">-->
<!-- <a-menu slot="overlay">-->
<!-- <a-menu-item key="1" @click="batchDel">-->
<!-- <a-icon type="delete"/>-->
<!-- 删除-->
<!-- </a-menu-item>-->
<!-- </a-menu>-->
<!-- <a-button style="margin-left: 8px"> 批量操作-->
<!-- <a-icon type="down"/>-->
<!-- </a-button>-->
<!-- </a-dropdown>-->
</div>
<!-- table区域-begin -->
<div>
<div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
<i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a
style="font-weight: 600">{{ selectedRowKeys.length }}</a>
<a style="margin-left: 24px" @click="onClearSelected">清空</a>
</div>
<a-table
ref="table"
size="middle"
:scroll="{x:true}"
bordered
rowKey="id"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
class="j-table-force-nowrap"
@change="handleTableChange">
<template slot="htmlSlot" slot-scope="text">
<div v-html="text"></div>
</template>
<template slot="imgSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
<span v-else style="font-size: 12px;font-style: italic;">
<img :src="getImgView(text)" height="25px" alt=""
style="max-width:80px;font-size: 12px;font-style: italic;"/>
<a-divider type="vertical"/>
<a-button
:ghost="true"
type="primary"
size="small"
@click="lookFile(text)">
在线查看
</a-button>
</span>
</template>
<template slot="fileSlot" slot-scope="text">
<span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
<a-button
v-else
:ghost="true"
type="primary"
icon="download"
size="small"
@click="downloadFile(text)">
下载
</a-button>
</template>
<!--跳转到模块样板-->
<!-- <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 @click="fuzhi(record)">复制</a>-->
<!-- <a-divider type="vertical" />-->
<!-- <a @click="handleDetail(record.id)">详情</a>-->
<!-- <a @click="handleDetail(record)">详情</a>-->
<a-divider type="vertical"/>
<!-- <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">-->
<!-- <a>删除</a>-->
<!-- </a-popconfirm>-->
</span>
</a-table>
</div>
<ZyClothSampleDetail ref="ZyClothSampleDetail"></ZyClothSampleDetail>
<zy-cloth-sample-modal ref="modalForm" @ok="modalFormOk" v-bind="superFieldList"></zy-cloth-sample-modal>
</a-card>
</template>
<script>
import '@/assets/less/TableExpand.less'
import {mixinDevice} from '@/utils/mixin'
import {JeecgListMixin} from '@/mixins/JeecgListMixin'
import ZyClothSampleModal from './modules/ZyClothSampleModal'
import ZyClothSampleDetail from '@views/product/productSample/modules/ZyClothSampleDetail'
export default {
name: "ProductSampleList", //
mixins: [JeecgListMixin, mixinDevice],
components: {
ZyClothSampleModal,
ZyClothSampleDetail
},
data() {
return {
description: '成衣样板管理页面',
//
columns: [
{
title: '#',
dataIndex: '',
key: 'rowIndex',
width: 60,
align: "center",
customRender: function (t, r, index) {
return parseInt(index) + 1;
}
},
{
title: '编号',
align: "center",
dataIndex: 'nums'
},
{
title: '服装款式',
align: "center",
dataIndex: 'styleId_dictText',
},
{
title: '款式型号',
align: "center",
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",
dataIndex: 'userId_dictText'
},
{
title: '创建时间',
align: "center",
dataIndex: 'createTime'
},
/*{
title: '图片',
align: "center",
dataIndex: 'url',
scopedSlots: {customRender: 'imgSlot'}
},*/
// {
// title: '',
// dataIndex: 'action1',
// align: "center",
// fixed: "right",
// width: 110,
// scopedSlots: {customRender: 'action1'}
// },
// {
// title: '',
// dataIndex: 'action',
// align: "center",
// fixed: "right",
// width: 147,
// scopedSlots: {customRender: 'action'}
// }
],
url: {
list: "/zyclothsample/zyClothSample/list",
edit: "/zyclothsample/zyClothSample/edit",
delete: "/zyclothsample/zyClothSample/delete",
deleteBatch: "/zyclothsample/zyClothSample/deleteBatch",
exportXlsUrl: "/zyclothsample/zyClothSample/exportXls",
importExcelUrl: "zyclothsample/zyClothSample/importExcel",
},
dictOptions: {},
superFieldList: [],
}
},
created() {
this.getSuperFieldList();
}
,
computed: {
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
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: '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>
<style scoped>
@import '~@assets/less/common.less';
</style>

@ -0,0 +1,125 @@
<template>
<div>
<a-modal
title="成衣样板-详情"
:visible="visible"
:confirm-loading="confirmLoading"
:width='1000'
@ok="handleOk"
@cancel="handleCancel"
style="display:flex;"
>
<a-spin :spinning="confirmLoading">
<j-form-container :disabled="formDisabled">
<a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
<!-- <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-descriptions bordered size="small" class="coin">
<a-descriptions-item label="编号" :span="2">
{{model.nums}}
</a-descriptions-item>
<a-descriptions-item label="客户" >
{{model.userId}}
</a-descriptions-item>
<a-descriptions-item label="成衣名称">
{{model.clothName}}
</a-descriptions-item>
<a-descriptions-item label="描述" >
{{model.descr}}
</a-descriptions-item>
<a-descriptions-item label="客户类型">
{{model.type}}
</a-descriptions-item>
<a-descriptions-item label="图片">
<j-image-upload isMultiple v-model="model.url" ></j-image-upload>
</a-descriptions-item>
</a-descriptions>
</a-form-model>
</j-form-container>
</a-spin>
</a-modal>
</div>
</template>
<script>
import { httpAction, getAction } from '@/api/manage'
import { validateDuplicateValue } from '@/utils/util'
export default {
name: 'ZyClothSampleDetail',
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: {
},
visible: false,
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));
},
methods: {
showModal(id) {
// console.log(this.selectId)
this.visible = true;
this.$http.get('/zyclothsample/zyClothSample/queryById?id='+id).then(
res=>{
this.model = res.result
console.log(this.data)
}
)
},
handleOk(e) {
this.ModalText = 'The modal will be closed after two seconds';
this.confirmLoading = true;
console.log(this.data)
setTimeout(() => {
this.visible = false;
this.confirmLoading = false;
}, 1);
},
handleCancel(e) {
console.log('Clicked cancel button');
this.visible = false;
},
}
}
</script>

@ -0,0 +1,229 @@
<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="企业" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="enterpriseId">
<j-select-depart v-model="model.userId" @change="kuanshi" />
</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">
<j-dict-select-tag v-model="model.styleId" placeholder="请输入款式"
:dict-code="dict" @change="xiugai"></j-dict-select-tag>
</a-form-model-item>
<!--编码也是唯一的和id一样 -->
</a-col>
<a-col :span="24">
<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" @change="gaibian"></j-dict-select-tag>
</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 || this.nums" placeholder="请输入编号"></a-input>-->
<a-input v-model="model.nums" placeholder="请输入编号" disabled></a-input>
</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="userId">-->
<!-- &lt;!&ndash; <a-input v-model="model.userId" placeholder="请输入用户名"></a-input>&ndash;&gt;-->
<!-- <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="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="url">
<j-image-upload isMultiple v-model="model.url"></j-image-upload>
</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: 'ZyClothSampleForm',
components: {},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
},
superFieldList: [], // table
},
data() {
return {
nums: '',
selectedKey: '', // id
typeid: '', // ,
serialNumber: '', //
model: {
nums:'',
},
dict:"zy_cloths_style,style_names,nums",
labelCol: {
xs: {span: 24},
sm: {span: 5},
},
wrapperCol: {
xs: {span: 24},
sm: {span: 16},
},
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,20}$/, 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: '文本长度过长'},
]
},
url: {
add: "/zyclothsample/zyClothSample/add",
edit: "/zyclothsample/zyClothSample/edit",
queryById: "/zyclothsample/zyClothSample/queryById",
sort:"/zyclothsample/zyClothSample/sort"
}
}
},
computed: {
formDisabled() {
return this.disabled;
}
},
created() {
//model
this.modelDefault = JSON.parse(JSON.stringify(this.model));
},
mounted() {
// -
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);
},
//
kuanshi(){
this.dict="zy_cloths_style,style_names,nums,enterprise_id="+"'"+this.model.userId+"'";
this.model.styleId=null
},
xiugai(){
if(this.model.stylemodelId!=null&&this.model.userId!=null){
this.gaibian()
}
},
gaibian(){
var n=3;
console.log(this.model)
getAction(this.url.sort,this.model).then((res)=>{
console.log(res)
if(this.model.id!=null){
var num=parseInt(res.result,10)
}else{
var num=parseInt(res.result,10)+1
}
num=num.toString()
while(num.length<n){
num="0"+num
}
this.model.nums=this.model.styleId+this.model.stylemodelId+num;
console.log( this.model.nums)
})},
// select
handleSelect(selectedKeys) {
this.selectedKey = selectedKeys;
},
// change
handletypeSelect(selectedKeys) {
this.type = selectedKeys;
},
edit(record) {
this.model = Object.assign({}, record);
this.dict="zy_cloths_style,style_names,nums,enterprise_id="+"'"+this.model.userId+"'";
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,60 @@
<template>
<j-modal
:title="title"
:width="width"
:visible="visible"
switchFullscreen
@ok="handleOk"
:okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
@cancel="handleCancel"
cancelText="关闭">
<zy-cloth-sample-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></zy-cloth-sample-form>
</j-modal>
</template>
<script>
import ZyClothSampleForm from './ZyClothSampleForm'
export default {
name: 'ZyClothSampleModal',
components: {
ZyClothSampleForm
},
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>

@ -0,0 +1,84 @@
<template>
<a-drawer
:title="title"
:width="width"
placement="right"
:closable="false"
@close="close"
destroyOnClose
:visible="visible">
<zy-cloth-sample-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></zy-cloth-sample-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 ZyClothSampleForm from './ZyClothSampleForm'
export default {
name: 'ZyClothSampleModal',
components: {
ZyClothSampleForm
},
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>

@ -149,7 +149,7 @@ export default {
{
title: '设备编号',
align: "center",
dataIndex: 'machineId'
dataIndex: 'code'
},
{
title: '设备名称',

@ -145,9 +145,9 @@ export default {
dataIndex: 'stationName',
},
{
title: '工具编',
title: '工具编',
align: "center",
dataIndex: 'toolsId'
dataIndex: 'nums'
},
{
title: '工具名称',

@ -139,6 +139,8 @@
<span slot="action" slot-scope="text, record">
<a @click="chaidan(record)">拆单</a>
<a-divider type="vertical" />
<a @click="shengchan(record)">生产</a>
<a-divider type="vertical" />
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical" />
<a @click="handleDetail(record)">详情</a>
@ -374,6 +376,7 @@
exportXlsUrl: "/zyorders/zyOrders/exportXls",
importExcelUrl: "zyorders/zyOrders/importExcel",
chaidan:"/zyorders/zyOrders/chaidan",
shengchan:"zyorders/zyOrders/shengchan",
},
dictOptions:{},
@ -405,6 +408,22 @@
this.$message.warning("该订单为子单,不可进行拆单!");
}
},
shengchan(record){
console.log(record)
if(record.goodsQuantity===1&&record.deliveryStatus===1){
getAction(this.url.shengchan,{id:record.id}).then((res) => {
if (res.success) {
this.$message.success("生产成功!");
this.loadData();
}else{
this.$message.error(res.message);
}
})
}else{
this.$message.warning("该订单不可生产!");
}
},
getPcaText(code){
return this.pcaData.getText(code);
},

@ -118,7 +118,7 @@ export default {
columns: [
{
title: '服装款式',
width: '150px',
width: '110px',
fixed: 'left',
key: 'styleId',
type: JVXETypes.select,
@ -132,17 +132,17 @@ export default {
{
title: '是否默认尺码',
align: "center",
width: '50px',
width: '130px',
key: 'isdefault',
type: JVXETypes.select,
dictCode: 'isdefault',
defaultValue: 0,
},
{key: 'modelNumber', title: '型号编码', dictCode: 'modenumber', width: '120px', type: JVXETypes.select},
{key: 'size', title: '码数', width: '90px', dictCode: 'size', type: JVXETypes.select},
{key: 'anumbers', title: '型', width: '80px', dictCode: 'hsize', type: JVXETypes.select},
{key: 'bnumbers', title: '号', width: '80px', dictCode: 'xsize', type: JVXETypes.select},
{key: 'collarLarge', title: '领大', width: '80px', type: JVXETypes.input},
{key: 'modelNumber', title: '型号编码', dictCode: 'modenumber', width: '100px', type: JVXETypes.select},
{key: 'size', title: '码数', width: '85px', dictCode: 'size', type: JVXETypes.select},
{key: 'anumbers', title: '型', width: '85px', dictCode: 'hsize', type: JVXETypes.select},
{key: 'bnumbers', title: '号', width: '85px', dictCode: 'xsize', type: JVXETypes.select},
{key: 'collarLarge', title: '领大', width: '70px', 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},
@ -151,14 +151,14 @@ export default {
{key: 'cuff', title: '袖口', width: '80px', type: JVXETypes.input},
{key: 'waistline', title: '腰围', width: '80px', type: JVXETypes.input},
{key: 'hem', title: '下摆', width: '80px', type: JVXETypes.input},
{key: 'createTime', title: '创建时间', width: '100px', type: JVXETypes.datetime},
{key: 'createTime', title: '创建时间', width: '60px', type: JVXETypes.datetime},
{
title: '操作',
key: 'action',
type: JVXETypes.slot,
fixed: 'right',
minWidth: '80px',
minWidth: '100px',
align: 'center',
slotName: 'action',
}
@ -203,16 +203,19 @@ export default {
let method = 'post';
//httpUrl += this.url.add;
//method = 'post';
let that = this;
httpAction(httpUrl, event.row, method).then((res) => {
if (res.success) {
this.$message.success(res.message);
that.reCalculatePage(1);
that.$message.success(res.message);
this.$emit('ok');
that.loadData();
} else {
this.$message.warning(res.message);
}
})
},
//
//
handleValueChange(event) {
//this.submitForm(event)

@ -82,8 +82,19 @@ public class GoodsAccessoriesController extends JeecgController<GoodsAccessories
@AutoLog(value = "商品辅料表-添加")
@ApiOperation(value="商品辅料表-添加", notes="商品辅料表-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody GoodsAccessories goodsAccessories) {
public Result<?> add(@RequestBody GoodsAccessories goodsAccessories,HttpServletRequest req) {
String[] split = goodsAccessories.getAccessoriesId().split(",");
QueryWrapper<GoodsAccessories> queryWrapper = QueryGenerator.initQueryWrapper(goodsAccessories, req.getParameterMap());
queryWrapper.eq("goods_id",goodsAccessories.getGoodsId());
for (String s : split) {
goodsAccessories.setAccessoriesId(s);
goodsAccessories.setId(null);
queryWrapper.eq("accessories_id", goodsAccessories.getAccessoriesId());
int a = goodsAccessoriesService.count(queryWrapper);
if (a >= 1)
return Result.error("存在已添加过的数据!");
goodsAccessoriesService.save(goodsAccessories);
}
return Result.OK("添加成功!");
}

@ -82,8 +82,19 @@ public class GoodsFabricController extends JeecgController<GoodsFabric, IGoodsFa
@AutoLog(value = "商品面料表-添加")
@ApiOperation(value="商品面料表-添加", notes="商品面料表-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody GoodsFabric goodsFabric) {
public Result<?> add(@RequestBody GoodsFabric goodsFabric,HttpServletRequest req) {
String[] split = goodsFabric.getFabricId().split(",");
QueryWrapper<GoodsFabric> queryWrapper = QueryGenerator.initQueryWrapper(goodsFabric, req.getParameterMap());
queryWrapper.eq("goods_id",goodsFabric.getGoodsId());
for (String s : split) {
goodsFabric.setFabricId(s);
goodsFabric.setId(null);
queryWrapper.eq("fabric_id", goodsFabric.getFabricId());
int a = goodsFabricService.count(queryWrapper);
if (a >= 1)
return Result.error("存在已添加过的数据!");
goodsFabricService.save(goodsFabric);
}
return Result.OK("添加成功!");
}

@ -132,6 +132,24 @@ public class ZyOrdersController extends JeecgController<ZyOrders, IZyOrdersServi
return Result.OK("批量删除成功!");
}
/**
* 生产
*
* @param id
* @return
*/
@AutoLog(value = "生产")
@ApiOperation(value="生产", notes="生产")
@GetMapping(value = "/shengchan")
public Result<?> shengchan(@RequestParam(name="id",required=true) String id) {
ZyOrders zyOrders = zyOrdersService.getById(id);
if(zyOrders==null) {
return Result.error("未找到对应数据");
}
zyOrders.setDeliveryStatus(2);
zyOrdersService.updateById(zyOrders);
return Result.OK("成功");
}
/**
* 通过id查询
*

@ -66,6 +66,13 @@ public class StationMachineController extends JeecgController<StationMachine, IS
QueryWrapper<StationMachine> queryWrapper = QueryGenerator.initQueryWrapper(stationMachine, req.getParameterMap());
Page<StationMachine> page = new Page<StationMachine>(pageNo, pageSize);
IPage<StationMachine> pageList = stationMachineService.page(page, queryWrapper);
List<StationMachine> records = pageList.getRecords();
if (!ObjectUtils.isEmpty(records)) {
records.forEach(e -> {
ZyDevice zyDevice = iZyDeviceService.getById(e.getMachineId());
e.setCode(StringUtils.isNotBlank(zyDevice.getCode()) ? zyDevice.getCode() : "");
});
}
return Result.OK(pageList);
}

@ -15,7 +15,9 @@ import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.demo.tool.entity.ZyTool;
import org.jeecg.modules.demo.tool.service.IZyToolService;
import org.jeecg.modules.device.entity.ZyDevice;
import org.jeecg.modules.device.service.IZyDeviceService;
import org.jeecg.modules.team.entity.StationMachine;
import org.jeecg.modules.team.entity.StationTool;
import org.jeecg.modules.team.service.IStationToolService;
import org.jeecg.modules.team.vo.StationToolVo;
@ -69,6 +71,13 @@ public class StationToolController extends JeecgController<StationTool, IStation
QueryWrapper<StationTool> queryWrapper = QueryGenerator.initQueryWrapper(stationTool, req.getParameterMap());
Page<StationTool> page = new Page<StationTool>(pageNo, pageSize);
IPage<StationTool> pageList = stationToolService.page(page, queryWrapper);
List<StationTool> records = pageList.getRecords();
if (!ObjectUtils.isEmpty(records)) {
records.forEach(e -> {
ZyTool zyTool = iZyToolService.getById(e.getToolsId());
e.setNums(StringUtils.isNotBlank(zyTool.getNums()) ? zyTool.getNums() : "");
});
}
return Result.OK(pageList);
}

@ -1,6 +1,7 @@
package org.jeecg.modules.team.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
@ -47,6 +48,10 @@ public class StationMachine {
@ApiModelProperty(value = "设备id,uuid,FK,设备表")
@Dict(dictTable = "zy_device", dicText = "name", dicCode = "id")
private String machineId;
@TableField(exist = false)
@ApiModelProperty(value = "设备编码")
private String code;
/**
* 创建日期
*/

@ -1,6 +1,7 @@
package org.jeecg.modules.team.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
@ -47,6 +48,10 @@ public class StationTool {
@ApiModelProperty(value = "工具id,uuid,FK,工具表")
@Dict(dictTable = "zy_tool", dicText = "name", dicCode = "id")
private String toolsId;
@TableField(exist = false)
@ApiModelProperty(value = "工具编码")
private String nums;
/**
* 创建日期
*/

@ -112,5 +112,11 @@ public class ZyStyleModel implements Serializable {
@ApiModelProperty(value = "创建时间")
private java.util.Date createTime;
/**更新时间*/
@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;
}

Loading…
Cancel
Save