喻忠伟 2 years ago
commit 2fe1d09cfa
  1. 4
      ant-design-vue-jeecg/src/components/jeecg/JVxeTable/index.js
  2. 195
      ant-design-vue-jeecg/src/views/device/ZyDeviceListRef.vue
  3. 544
      ant-design-vue-jeecg/src/views/devicetype/ZyDevicetypeListRef.vue
  4. 31
      ant-design-vue-jeecg/src/views/erp/tool/ZyToolListRef.vue
  5. 497
      ant-design-vue-jeecg/src/views/productplan/ZyPlanProcessDataList.vue
  6. 282
      ant-design-vue-jeecg/src/views/productplan/ZyPlanProcessDataList_back1223.vue
  7. 34
      ant-design-vue-jeecg/src/views/productplan/ZyPlanProcessList.vue
  8. 257
      ant-design-vue-jeecg/src/views/starehouse/admin/StarehouseList.vue
  9. 160
      ant-design-vue-jeecg/src/views/starehouse/admin/modules/StarehouseForm.vue
  10. 60
      ant-design-vue-jeecg/src/views/starehouse/admin/modules/StarehouseModal.vue
  11. 84
      ant-design-vue-jeecg/src/views/starehouse/admin/modules/StarehouseModal__Style#Drawer.vue
  12. 80
      ant-design-vue-jeecg/src/views/system/User2ListRef.vue
  13. 37
      ant-design-vue-jeecg/src/views/team/GroupxList.vue
  14. 65
      ant-design-vue-jeecg/src/views/team/GroupxMemberList.vue
  15. 42
      ant-design-vue-jeecg/src/views/team/StationList.vue
  16. 10
      ant-design-vue-jeecg/src/views/team/StationMachineList.vue
  17. 10
      ant-design-vue-jeecg/src/views/team/StationToolList.vue
  18. 62
      ant-design-vue-jeecg/src/views/team/modules/GroupxMemberModal.vue
  19. 2
      ant-design-vue-jeecg/src/views/team/modules/GroupxModal.vue
  20. 23
      ant-design-vue-jeecg/src/views/team/modules/StationMachineModal.vue
  21. 2
      ant-design-vue-jeecg/src/views/zyclothsample/ZyClothSampleList.vue
  22. 107
      ant-design-vue-jeecg/src/views/zystylemodel/ZyStyleModelList.vue
  23. 4
      jeecg-boot/jeecg-boot-module-erp/src/main/java/org/jeecg/modules/demo/tool/controller/ZyToolController.java
  24. 16
      jeecg-boot/jeecg-boot-module-erp/src/main/java/org/jeecg/modules/demo/zyStyleModular/entity/ZyStyleModular.java
  25. 8
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/entity/ZyClothsComponent.java
  26. 28
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/base/entity/ZyClothsModularCompent.java
  27. 16
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/controller/ZyProcessComponentController.java
  28. 10
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/entity/ZyProcessComponent.java
  29. 14
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/service/impl/ZyProcessComponentServiceImpl.java
  30. 172
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/controller/StarehouseController.java
  31. 99
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/entity/Starehouse.java
  32. 19
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/mapper/StarehouseMapper.java
  33. 5
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/mapper/xml/StarehouseMapper.xml
  34. 16
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/service/IStarehouseService.java
  35. 21
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/starehouse/service/impl/StarehouseServiceImpl.java
  36. 16
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/zyaccessories/entity/ZyStyleAccessories.java
  37. 6
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/maker/entity/ZyMaker.java
  38. 36
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/product/productModule/entity/ProductModule.java
  39. 13
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/productplan/controller/ZyPlanProcessController.java
  40. 9
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/productplan/entity/vo/ProcessDataVo.java
  41. 22
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/productplan/service/impl/ZyPlanProcessServiceImpl.java
  42. 28
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/system/controller/SysUserController.java
  43. 16
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/GroupxMemberController.java
  44. 23
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationController.java
  45. 28
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationMachineController.java
  46. 35
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/controller/StationToolController.java
  47. 3
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/GroupxMember.java
  48. 2
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/Station.java
  49. 2
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/entity/StationMachine.java
  50. 4
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/service/IStationService.java
  51. 28
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/service/impl/StationServiceImpl.java
  52. 16
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/vo/StationMachineVo.java
  53. 33
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/vo/StationToolVo.java
  54. 16
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/team/vo/StationVo.java
  55. 28
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zyProcessModular/entity/ZyProcessModular.java
  56. 2
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylefabric/mapper/ZyStyleFabricMapper.java
  57. 59
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/controller/ZyStyleModelController.java
  58. 6
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/entity/ZyStyleModel.java
  59. 4
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/zystylemodel/service/impl/ZyStyleModelServiceImpl.java

@ -30,8 +30,8 @@ export const AllCells = {
...mapCell(JVXETypes.select, JVxeSelectCell),
...mapCell(JVXETypes.selectSearch, JVxeSelectCell), // 下拉搜索
...mapCell(JVXETypes.selectMultiple, JVxeSelectCell), // 下拉多选
...mapCell(JVXETypes.date, JVxeDateCell),
...mapCell(JVXETypes.datetime, JVxeDateCell),
...mapCell(JVXETypes.date, JVxeDateCell),//yyyy-MM-dd 弹出日历提供选择 有日期没有时间
...mapCell(JVXETypes.datetime, JVxeDateCell),//yyyy-MM-dd HH:mm:ss 弹出日历提供选择 有日期有时间
...mapCell(JVXETypes.upload, JVxeUploadCell),
...mapCell(JVXETypes.textarea, JVxeTextareaCell),

@ -0,0 +1,195 @@
<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 :sm="5">
<a-form-model-item label="设备编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="id">
<a-input v-model="queryParam.code" placeholder="请输入设备编号"></a-input>
</a-form-model-item>
</a-col>
<a-col :sm="5">
<a-form-model-item label="设备名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="name">
<a-input v-model="queryParam.name" placeholder="请输入设备名称"></a-input>
</a-form-model-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>
<!-- 查询区域-END -->
<!-- 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">
</a-table>
</div>
<!-- <ZyDeviceDetail ref="ZyDeviceDetail"></ZyDeviceDetail>-->
<!-- <zy-device-modal ref="modalForm" @ok="modalFormOk"></zy-device-modal>-->
</a-card>
</template>
<script>
import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import {getAction} from "@api/manage";
export default {
name: 'ZyDeviceListRef',
mixins:[JeecgListMixin],
components: {},
data () {
return {
description: '设备信息管理页面',
labelCol: {
xs: {span: 24},
sm: {span: 5},
},
wrapperCol: {
xs: {span: 24},
sm: {span: 16},
},
//
columns: [
{
title:'设备编号',
align:"center",
dataIndex: 'code'
},
{
title: '名称',
align: "center",
dataIndex: 'name'
},
],
url: {
list: "/device/zyDevice/list",
delete: "/device/zyDevice/delete",
deleteBatch: "/device/zyDevice/deleteBatch",
exportXlsUrl: "/device/zyDevice/exportXls",
importExcelUrl: "device/zyDevice/importExcel",
},
dictOptions: {},
/* 分页参数 */
ipagination: {
current: 1,
pageSize: 5,
pageSizeOptions: ['5', '10', '50'],
showTotal: (total, range) => {
return range[0] + "-" + range[1] + " 共" + total + "条"
},
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
selectedMainId: '',
superFieldList: [],
selectedRowKeys: [],
}
},
created() {
// this.getSuperFieldList();
// console.log(this.superFieldList)
},
computed: {
importExcelUrl: function(){
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
methods: {
onSelectChange(selectedRowKeys) {
console.log('selectedRowKeys changed: ', selectedRowKeys);
this.selectedRowKeys = selectedRowKeys;
},
initDictConfig() {
},
clickThenSelect(record) {
return {
on: {
click: () => {
this.onSelectChange(record.id.split(","), [record]);
}
}
}
},
onClearSelected() {
this.selectedRowKeys = [];
this.selectionRows = [];
this.selectedMainId = ''
},
// onSelectChange(selectedRowKeys, selectionRows) {
// this.selectedMainId=selectedRowKeys[0]
// this.selectedRowKeys = selectedRowKeys;
// this.selectionRows = selectionRows;
// },
loadData(arg) {
if (!this.url.list) {
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
this.onClearSelected()
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
this.dataSource = res.result.records;
this.ipagination.total = res.result.total;
}
if (res.code === 510) {
this.$message.warning(res.message)
}
this.loading = false;
})
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'img',text:'设备图片',dictCode:''})
fieldList.push({type:'string',value:'typeid',text:'设备类型',dictCode:'zy_devicetype,name,id'})
fieldList.push({type:'string',value:'code',text:'设备编号',dictCode:''})
fieldList.push({type:'date',value:'buydate',text:'购买时间'})
fieldList.push({type:'sel_user',value:'agent',text:'经办人'})
fieldList.push({type:'string',value:'adress',text:'存放位置',dictCode:''})
fieldList.push({type:'string',value:'status',text:'设备状态',dictCode:''})
fieldList.push({type:'string',value:'maintenancecycle',text:'维护周期',dictCode:''})
fieldList.push({type:'sel_user',value:'administrator',text:'管理人'})
fieldList.push({type:'date',value:'maintenancedate',text:'上次维护时间'})
fieldList.push({type:'string',value:'img3d',text:'3d模型',dictCode:''})
this.superFieldList = fieldList
},
openDetail(id){
this.$refs.ZyDeviceDetail.showModal(id)
// this.$children[0].showModal(id)
}
}
}
</script>

@ -1,279 +1,301 @@
<template>
<a-card :bordered="false">
<!--<template>-->
<!-- <a-card :bordered="false">-->
<!-- &lt;!&ndash; 查询区域 &ndash;&gt;-->
<!-- &lt;!&ndash; <div class="table-page-search-wrapper">&ndash;&gt;-->
<!-- &lt;!&ndash; <a-form layout="inline" @keyup.enter.native="searchQuery">&ndash;&gt;-->
<!-- &lt;!&ndash; <a-row :gutter="24">&ndash;&gt;-->
<!-- &lt;!&ndash; </a-row>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-form>&ndash;&gt;-->
<!-- &lt;!&ndash; </div>&ndash;&gt;-->
<!-- &lt;!&ndash; 查询区域-END &ndash;&gt;-->
<!-- &lt;!&ndash; 查询区域 &ndash;&gt;-->
<!-- <div class="table-page-search-wrapper">-->
<!-- <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-input v-model="queryParam.id" placeholder="请输入设备编号"></a-input>-->
<!-- </a-form-model-item>-->
<!-- </a-col>-->
<!-- <a-col :sm="5">-->
<!-- <a-form-model-item label="设备名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="name">-->
<!-- <a-input v-model="queryParam.name" placeholder="请输入设备名称"></a-input>-->
<!-- </a-form-model-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>-->
<!-- &lt;!&ndash; 查询区域-END &ndash;&gt;-->
<!-- 操作按钮区域 -->
<!-- <div class="table-operator">-->
<!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>-->
<!-- </div>-->
<!-- &lt;!&ndash; 操作按钮区域 &ndash;&gt;-->
<!-- &lt;!&ndash; <div class="table-operator">&ndash;&gt;-->
<!-- &lt;!&ndash; <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>&ndash;&gt;-->
<!-- &lt;!&ndash; </div>&ndash;&gt;-->
<!-- &lt;!&ndash; table区域-begin &ndash;&gt;-->
<!-- <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>-->
<!-- 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"-->
<!-- bordered-->
<!-- rowKey="id"-->
<!-- class="j-table-force-nowrap"-->
<!-- :scroll="{x:true}"-->
<!-- :columns="columns"-->
<!-- :dataSource="dataSource"-->
<!-- :pagination="ipagination"-->
<!-- :loading="loading"-->
<!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"-->
<!-- :customRow="clickThenSelect"-->
<!-- @change="handleTableChange">-->
<a-table
ref="table"
size="middle"
bordered
rowKey="id"
class="j-table-force-nowrap"
:scroll="{x:true}"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
:customRow="clickThenSelect"
@change="handleTableChange">
<!-- &lt;!&ndash; <template slot="htmlSlot" slot-scope="text">&ndash;&gt;-->
<!-- &lt;!&ndash; <div v-html="text"></div>&ndash;&gt;-->
<!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- &lt;!&ndash; <template slot="imgSlot" slot-scope="text">&ndash;&gt;-->
<!-- &lt;!&ndash; <span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>&ndash;&gt;-->
<!-- &lt;!&ndash; <img v-else :src="getImgView(text)" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>&ndash;&gt;-->
<!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- &lt;!&ndash; <template slot="imgeSlot" slot-scope="text">&ndash;&gt;-->
<!-- &lt;!&ndash; <img :src="text" height="" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>&ndash;&gt;-->
<!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- &lt;!&ndash; <template slot="fileSlot" slot-scope="text">&ndash;&gt;-->
<!-- &lt;!&ndash; <span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>&ndash;&gt;-->
<!-- &lt;!&ndash; <a-button&ndash;&gt;-->
<!-- &lt;!&ndash; v-else&ndash;&gt;-->
<!-- &lt;!&ndash; :ghost="true"&ndash;&gt;-->
<!-- &lt;!&ndash; type="primary"&ndash;&gt;-->
<!-- &lt;!&ndash; icon="download"&ndash;&gt;-->
<!-- &lt;!&ndash; size="small"&ndash;&gt;-->
<!-- &lt;!&ndash; @click="downloadFile(text)">&ndash;&gt;-->
<!-- &lt;!&ndash; 下载&ndash;&gt;-->
<!-- &lt;!&ndash; </a-button>&ndash;&gt;-->
<!-- &lt;!&ndash; </template>&ndash;&gt;-->
<!-- <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>-->
<!-- &lt;!&ndash; <span slot="action" slot-scope="text, record">&ndash;&gt;-->
<!-- &lt;!&ndash; <a @click="handleEdit(record)">编辑</a>&ndash;&gt;-->
<!-- <span slot="action" slot-scope="text, record">-->
<!-- <a @click="handleEdit(record)">编辑</a>-->
<!-- &lt;!&ndash; <a-divider type="vertical" />&ndash;&gt;-->
<!-- &lt;!&ndash; <a-dropdown>&ndash;&gt;-->
<!-- &lt;!&ndash; <a class="ant-dropdown-link">更多 <a-icon type="down" /></a>&ndash;&gt;-->
<!-- &lt;!&ndash; <a-menu slot="overlay">&ndash;&gt;-->
<!-- &lt;!&ndash; <a-menu-item>&ndash;&gt;-->
<!-- &lt;!&ndash; <a @click="openDetail(record.id)">详情</a>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-menu-item>&ndash;&gt;-->
<!-- &lt;!&ndash; <a-menu-item>&ndash;&gt;-->
<!-- &lt;!&ndash; <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">&ndash;&gt;-->
<!-- &lt;!&ndash; <a>删除</a>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-popconfirm>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-menu-item>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-menu>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-dropdown>&ndash;&gt;-->
<!-- &lt;!&ndash; </span>&ndash;&gt;-->
<!-- <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="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>-->
</a-table>
</div>
<!-- &lt;!&ndash; <a-tabs defaultActiveKey="1">&ndash;&gt;-->
<!-- &lt;!&ndash; <a-tab-pane tab="类型参数" key="1" >&ndash;&gt;-->
<!-- &lt;!&ndash; <ZyTypeparametersList :mainId="selectedMainId" />&ndash;&gt;-->
<!-- &lt;!&ndash; </a-tab-pane>&ndash;&gt;-->
<!-- &lt;!&ndash; <a-tab-pane tab="运行参数" key="2" forceRender>&ndash;&gt;-->
<!-- &lt;!&ndash; <ZyOperationparametersList :mainId="selectedMainId" />&ndash;&gt;-->
<!-- &lt;!&ndash; </a-tab-pane>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-tabs>&ndash;&gt;-->
<!-- &lt;!&ndash; <ZyDevicetypeDetail ref="ZyDevicetypeDetail"></ZyDevicetypeDetail>&ndash;&gt;-->
<!-- &lt;!&ndash; <zyDevicetype-modal ref="modalForm" @ok="modalFormOk"></zyDevicetype-modal>&ndash;&gt;-->
<!-- </a-card>-->
<!--</template>-->
<!-- <a-tabs defaultActiveKey="1">-->
<!-- <a-tab-pane tab="类型参数" key="1" >-->
<!-- <ZyTypeparametersList :mainId="selectedMainId" />-->
<!-- </a-tab-pane>-->
<!-- <a-tab-pane tab="运行参数" key="2" forceRender>-->
<!-- <ZyOperationparametersList :mainId="selectedMainId" />-->
<!-- </a-tab-pane>-->
<!-- </a-tabs>-->
<!-- <ZyDevicetypeDetail ref="ZyDevicetypeDetail"></ZyDevicetypeDetail>-->
<!-- <zyDevicetype-modal ref="modalForm" @ok="modalFormOk"></zyDevicetype-modal>-->
</a-card>
</template>
<!--<script>-->
<script>
<!--import {JeecgListMixin} from '@/mixins/JeecgListMixin'-->
<!--import ZyDevicetypeModal from './modules/ZyDevicetypeModal'-->
<!--import {getAction} from '@/api/manage'-->
<!--import ZyTypeparametersList from './ZyTypeparametersList'-->
<!--import ZyOperationparametersList from './ZyOperationparametersList'-->
<!--import '@/assets/less/TableExpand.less'-->
<!--import ZyDevicetypeDetail from './modules/ZyDevicetypeDetail'-->
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import ZyDevicetypeModal from './modules/ZyDevicetypeModal'
import { getAction } from '@/api/manage'
import ZyTypeparametersList from './ZyTypeparametersList'
import ZyOperationparametersList from './ZyOperationparametersList'
import '@/assets/less/TableExpand.less'
import ZyDevicetypeDetail from './modules/ZyDevicetypeDetail'
export default {
name: "ZyDevicetypeList",
mixins:[JeecgListMixin],
components: {
ZyTypeparametersList,
ZyOperationparametersList,
ZyDevicetypeModal,
ZyDevicetypeDetail
},
data () {
return {
description: '设备类型管理页面',
//
columns: [
// {
// title:'',
// align:"center",
// dataIndex: 'code'
// },
{
title:'名称',
align:"center",
dataIndex: 'name'
},
// {
// title:'',
// align:"center",
// dataIndex: 'img',
// scopedSlots: {customRender: 'imgSlot'}
// },
// {
// title:"",
// align:"center",
// dataIndex: 'erweima',
// scopedSlots: {customRender: 'imgeSlot'}
// },
{
title:'类型品牌',
align:"center",
dataIndex: 'brand'
},
// {
// title:'',
// align:"center",
// dataIndex: 'model'
// },
{
title:'生产厂商',
align:"center",
dataIndex: 'manufacturer'
},
{
title:'供货商',
align:"center",
dataIndex: 'supplier'
},
// {
// title:'',
// align:"center",
// dataIndex: 'contact'
// },
// {
// title:'',
// align:"center",
// dataIndex: 'place'
// },
],
url: {
list: "/devicetype/zyDevicetype/list",
delete: "/devicetype/zyDevicetype/delete",
deleteBatch: "/devicetype/zyDevicetype/deleteBatch",
exportXlsUrl: "/devicetype/zyDevicetype/exportXls",
importExcelUrl: "devicetype/zyDevicetype/importExcel",
},
dictOptions:{
},
/* 分页参数 */
ipagination:{
current: 1,
pageSize: 5,
pageSizeOptions: ['5', '10', '50'],
showTotal: (total, range) => {
return range[0] + "-" + range[1] + " 共" + total + "条"
},
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
selectedMainId:'',
superFieldList:[],
selectedRowKeys: [],
}
},
created() {
this.getSuperFieldList();
},
computed: {
importExcelUrl: function(){
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
}
},
methods: {
onSelectChange(selectedRowKeys){
console.log('selectedRowKeys changed: ', selectedRowKeys);
this.selectedRowKeys = selectedRowKeys;
},
initDictConfig(){
},
clickThenSelect(record) {
return {
on: {
click: () => {
this.onSelectChange(record.id.split(","), [record]);
}
}
}
},
onClearSelected() {
this.selectedRowKeys = [];
this.selectionRows = [];
this.selectedMainId=''
},
// onSelectChange(selectedRowKeys, selectionRows) {
// this.selectedMainId=selectedRowKeys[0]
// this.selectedRowKeys = selectedRowKeys;
// this.selectionRows = selectionRows;
// },
loadData(arg) {
if(!this.url.list){
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
this.onClearSelected()
var params = this.getQueryParams();//
this.loading = true;
getAction(this.url.list, params).then((res) => {
if (res.success) {
this.dataSource = res.result.records;
this.ipagination.total = res.result.total;
}
if(res.code===510){
this.$message.warning(res.message)
}
this.loading = false;
})
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'string',value:'pid',text:'父级节点',dictCode:''})
fieldList.push({type:'string',value:'code',text:'类型编号',dictCode:''})
fieldList.push({type:'string',value:'name',text:'类型名称',dictCode:''})
fieldList.push({type:'string',value:'img',text:'类型图片',dictCode:''})
fieldList.push({type:'string',value:'brand',text:'类型品牌',dictCode:''})
fieldList.push({type:'string',value:'model',text:'型号',dictCode:''})
fieldList.push({type:'string',value:'manufacturer',text:'生产厂商',dictCode:''})
fieldList.push({type:'string',value:'supplier',text:'供货商',dictCode:''})
fieldList.push({type:'string',value:'contact',text:'联系人',dictCode:''})
fieldList.push({type:'string',value:'place',text:'产地',dictCode:''})
this.superFieldList = fieldList
},
openDetail(id){
this.$refs.ZyDevicetypeDetail.showModal(id)
<!--export default {-->
<!-- name: "ZyDevicetypeList",-->
<!-- mixins: [JeecgListMixin],-->
<!-- components: {-->
<!-- // ZyTypeparametersList,-->
<!-- // ZyOperationparametersList,-->
<!-- // ZyDevicetypeModal,-->
<!-- // ZyDevicetypeDetail-->
<!-- },-->
<!-- data() {-->
<!-- return {-->
<!-- description: '设备类型管理页面',-->
<!-- // -->
<!-- columns: [-->
<!-- {-->
<!-- title: '设备编号',-->
<!-- align: "center",-->
<!-- dataIndex: 'id'-->
<!-- },-->
<!-- {-->
<!-- title: '名称',-->
<!-- align: "center",-->
<!-- dataIndex: 'name'-->
<!-- },-->
<!-- // {-->
<!-- // title:'',-->
<!-- // align:"center",-->
<!-- // dataIndex: 'img',-->
<!-- // scopedSlots: {customRender: 'imgSlot'}-->
<!-- // },-->
<!-- // {-->
<!-- // title:"",-->
<!-- // align:"center",-->
<!-- // dataIndex: 'erweima',-->
<!-- // scopedSlots: {customRender: 'imgeSlot'}-->
<!-- // },-->
<!-- {-->
<!-- title: '类型品牌',-->
<!-- align: "center",-->
<!-- dataIndex: 'brand'-->
<!-- },-->
<!-- // {-->
<!-- // title:'',-->
<!-- // align:"center",-->
<!-- // dataIndex: 'model'-->
<!-- // },-->
<!-- {-->
<!-- title: '生产厂商',-->
<!-- align: "center",-->
<!-- dataIndex: 'manufacturer'-->
<!-- },-->
<!-- // {-->
<!-- // title:'',-->
<!-- // align:"center",-->
<!-- // dataIndex: 'supplier'-->
<!-- // },-->
<!-- // {-->
<!-- // title:'',-->
<!-- // align:"center",-->
<!-- // dataIndex: 'contact'-->
<!-- // },-->
<!-- // {-->
<!-- // title:'',-->
<!-- // align:"center",-->
<!-- // dataIndex: 'place'-->
<!-- // },-->
<!-- ],-->
<!-- url: {-->
<!-- list: "/devicetype/zyDevicetype/list",-->
<!-- delete: "/devicetype/zyDevicetype/delete",-->
<!-- deleteBatch: "/devicetype/zyDevicetype/deleteBatch",-->
<!-- exportXlsUrl: "/devicetype/zyDevicetype/exportXls",-->
<!-- importExcelUrl: "devicetype/zyDevicetype/importExcel",-->
<!-- },-->
<!-- dictOptions: {},-->
<!-- /* 分页参数 */-->
<!-- ipagination: {-->
<!-- current: 1,-->
<!-- pageSize: 5,-->
<!-- pageSizeOptions: ['5', '10', '50'],-->
<!-- showTotal: (total, range) => {-->
<!-- return range[0] + "-" + range[1] + " 共" + total + "条"-->
<!-- },-->
<!-- showQuickJumper: true,-->
<!-- showSizeChanger: true,-->
<!-- total: 0-->
<!-- },-->
<!-- selectedMainId: '',-->
<!-- superFieldList: [],-->
<!-- selectedRowKeys: [],-->
<!-- }-->
<!-- },-->
<!-- created() {-->
<!-- this.getSuperFieldList();-->
<!-- },-->
<!-- computed: {-->
<!-- importExcelUrl: function () {-->
<!-- return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;-->
<!-- }-->
<!-- },-->
<!-- methods: {-->
<!-- onSelectChange(selectedRowKeys) {-->
<!-- console.log('selectedRowKeys changed: ', selectedRowKeys);-->
<!-- this.selectedRowKeys = selectedRowKeys;-->
<!-- },-->
<!-- initDictConfig() {-->
<!-- },-->
<!-- clickThenSelect(record) {-->
<!-- return {-->
<!-- on: {-->
<!-- click: () => {-->
<!-- this.onSelectChange(record.id.split(","), [record]);-->
<!-- }-->
<!-- }-->
<!-- }-->
<!-- },-->
<!-- onClearSelected() {-->
<!-- this.selectedRowKeys = [];-->
<!-- this.selectionRows = [];-->
<!-- this.selectedMainId = ''-->
<!-- },-->
<!-- // onSelectChange(selectedRowKeys, selectionRows) {-->
<!-- // this.selectedMainId=selectedRowKeys[0]-->
<!-- // this.selectedRowKeys = selectedRowKeys;-->
<!-- // this.selectionRows = selectionRows;-->
<!-- // },-->
<!-- loadData(arg) {-->
<!-- if (!this.url.list) {-->
<!-- this.$message.error("请设置url.list属性!")-->
<!-- return-->
<!-- }-->
<!-- // 1-->
<!-- if (arg === 1) {-->
<!-- this.ipagination.current = 1;-->
<!-- }-->
<!-- this.onClearSelected()-->
<!-- var params = this.getQueryParams();//-->
<!-- this.loading = true;-->
<!-- getAction(this.url.list, params).then((res) => {-->
<!-- if (res.success) {-->
<!-- this.dataSource = res.result.records;-->
<!-- this.ipagination.total = res.result.total;-->
<!-- }-->
<!-- if (res.code === 510) {-->
<!-- this.$message.warning(res.message)-->
<!-- }-->
<!-- this.loading = false;-->
<!-- })-->
<!-- },-->
<!-- getSuperFieldList() {-->
<!-- let fieldList = [];-->
<!-- fieldList.push({type: 'string', value: 'pid', text: '父级节点', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'code', text: '类型编号', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'name', text: '类型名称', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'img', text: '类型图片', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'brand', text: '类型品牌', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'model', text: '型号', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'manufacturer', text: '生产厂商', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'supplier', text: '供货商', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'contact', text: '联系人', dictCode: ''})-->
<!-- fieldList.push({type: 'string', value: 'place', text: '产地', dictCode: ''})-->
<!-- this.superFieldList = fieldList-->
<!-- },-->
<!-- openDetail(id) {-->
<!-- this.$refs.ZyDevicetypeDetail.showModal(id)-->
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less'
</style>
<!-- }-->
<!-- }-->
<!--}-->
<!--</script>-->

@ -1,13 +1,28 @@
<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>-->
<!-- &lt;!&ndash; 查询区域-END &ndash;&gt;-->
<div class="table-page-search-wrapper">
<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-input v-model="queryParam.id" placeholder="请输入工具编号"></a-input>
</a-form-model-item>
</a-col>
<a-col :sm="5">
<a-form-model-item label="工具名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="name">
<a-input v-model="queryParam.name" placeholder="请输入工具名称"></a-input>
</a-form-model-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>
<!-- 操作按钮区域 -->
<!-- <div class="table-operator">-->
@ -116,7 +131,7 @@ export default {
{
title: '工具编号',
align: "center",
dataIndex: 'nums'
dataIndex: 'id'
},
{
title: '工具名称',

@ -1,111 +1,30 @@
<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 -->
<div class="table-operator">
<a-button type="primary" icon="download" @click="handleExportXls('计划工序')">导出</a-button>
<!-- <a-button type="primary" @click="handleTableSave($event)">保存</a-button>-->
<a-button type="primary" @click="fanHui()">返回</a-button>
</div>
<!-- table区域-begin -->
<div>
<a-table
ref="table"
size="middle"
:scroll="{x:true}"
bordered
rowKey="id"
<j-vxe-table
ref="xTable"
toolbar
:toolbarConfig="toolbarConfig"
row-number
row-selection
keep-source
:rowSelection="clickTrue"
:clickSelectRow="clickTrue"
:loading="loading"
:columns="columns"
@selectRowChange="handleSelectRowChange"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
class="j-table-force-nowrap"
@change="handleTableChange">
<span slot="stationList" slot-scope="stationList">
<a-select @change="getToolAndMachine" style="width: 180px" placeholder="请选择">
<a-select-option v-for="item in stationList" :value="item.id">
{{ item.stationName }}
</a-select-option>
</a-select>
</span>
<span slot="toolsList" slot-scope="toolsList">
<a-select style="width: 180px" placeholder="请选择">
<a-select-option v-for="item in toolsList" :value="item.id">
{{ item.name }}
</a-select-option>
</a-select>
</span>
<span slot="machineList" slot-scope="machineList">
<a-select style="width: 180px" placeholder="请选择">
<a-select-option v-for="item in machineList" :value="item.id">
{{ item.name }}
</a-select-option>
</a-select>
</span>
<span slot="proProcess" slot-scope="proProcess">
<j-search-select-tag type="list" dict="zy_process,process_name,id,id in(select process_id from zy_product_process where product_id='1')" pidField="pid"
pidValue="" placeholder="前导工序"/>
</span>
<span slot="postProcess" slot-scope="postProcess">
<j-search-select-tag type="list" dict="zy_process,process_name,id,id in(select process_id from zy_product_process where product_id='1')" pidField="pid"
pidValue="" placeholder="后导工序"/>
</span>
<span slot="inputProduct" slot-scope="inputProduct">
<a-input v-model="processIds" placeholder="请输入产品"></a-input>
</span>
<span slot="semiProduct" slot-scope="semiProduct">
<a-input v-model="semiProduct" placeholder="请输入成品/半成品"></a-input>
</span>
<!-- <template
v-for="col in columns"
:slot="col"
slot-scope="text, record, index"
>
<div :key="col">
<a-input
v-if="record.editable"
style="margin: -5px 0"
:value="text"
@change="e => handleChange(e.target.value, record.key, col)"
/>
<template v-else>
{{ text }}
</template>
</div>
</template>
<template slot="operation" slot-scope="text, record, index">
<div class="editable-row-operations">
<span v-if="record.editable">
<a @click="() => save(record)">Save</a>
<a-popconfirm title="Sure to cancel?" @confirm="() => cancel(record)">
<a>Cancel</a>
</a-popconfirm>
</span>
<span>
<a :disabled="editingKey !== ''" @click="() => edit(index)">Edit66</a>
</span> b
</div>
</template>-->
</a-table>
</div>
<div class="table-operator" style="text-align: right">
<a-button type="primary" @click="fanHui()">提交</a-button>
@valueChange="handleValueChange"
@save="handleTableSave"
/>
</div>
<!-- <zy-plan-process-modal @valueChange="valueChange" ref="modalForm" @ok="modalFormOk"></zy-plan-process-modal>-->
</a-card>
</template>
@ -114,189 +33,135 @@
import '@/assets/less/TableExpand.less'
import {mixinDevice} from '@/utils/mixin'
import {JeecgListMixin} from '@/mixins/JeecgListMixin'
import ZyPlanProcessModal from './modules/ZyPlanProcessModal2'
import {getAction} from "@api/manage";
import {filterObj} from "@/utils/util";
import {getAction, postAction} from "@api/manage";
import {filterObj, pushIfNotExist, randomNumber, randomUUID} from "@/utils/util";
import {JVXETypes} from '@/components/jeecg/JVxeTable'
export default {
name: 'ZyPlanProcessList',
name: 'ZyPlanProcessDataList',
mixins: [JeecgListMixin, mixinDevice],
components: {
ZyPlanProcessModal
},
data() {
// this.cacheData = this.dataSource.map(item => ({ ...item }));
this.cacheData = [];
return {
toolbarConfig: {
// add remove clearSelection
btn: ['save']
},
description: '生产计划工序管理页面',
loading: false,
//
// pagination: {
// //
// current: 1,
// //
// pageSize: 10,
// //
// pageSizeOptions: ['10', '20', '30', '50'],
// // 0
// total: 0,
// },
//
// selectedRows: [],
//
dataSource: [],
// columns,
//
columns: [
{
title: '#',
dataIndex: 'productProcessId',
key: 'rowIndex',
width: 60,
align: "center",
customRender: function (t, r, index) {
return parseInt(index) + 1;
}
},
/* {
title: '计划id',
align: "center",
dataIndex: 'planId'
},*/
{
title: '工单编号',
align: "center",
dataIndex: 'workOrderId',
scopedSlots: {customRender: 'workOrderId'}
},
/*{
title: '产品id',
align: "center",
dataIndex: 'productId'
},
{
title: '工序id',
align: "center",
dataIndex: 'productProcessId'
},*/
{
title: '产品',
align: "center",
dataIndex: 'productName'
},
{
title: '车间',
align: "center",
dataIndex: 'departName'
},
{
title: '工序',
align: "center",
dataIndex: 'processName'
},
{key: 'workOrderId', title: '工单编号', width: '180px'},
{key: 'productName', title: '产品名称', width: '180px'},
{key: 'departName', title: '车间名称', width: '180px'},
{key: 'processName', title: '工序名称', width: '180px'},
{
title: '工位列表',
align: "center",
dataIndex: 'stationList',
width: 150,
scopedSlots: {customRender: 'stationList'}
},
{
title: '工位工具列表',
align: "center",
dataIndex: 'toolsList',
width: 150,
// scopedSlots: {customRender: this.toolsList}
scopedSlots: {customRender: 'toolsList'}
},
{
title: '工具设备列表',
align: "center",
dataIndex: 'machineList',
width: 150,
scopedSlots: {customRender: 'machineList'}
key: 'stationId',
type: JVXETypes.select,
width: '200px',
options: [],
placeholder: '请选择${title}',
}, {
title: '设备列表',
key: 'machineIds',
type: JVXETypes.selectMultiple,
width: '200px',
options: [],
placeholder: '请选择${title}',
}, {
title: '工具列表',
key: 'toolsIds',
type: JVXETypes.selectMultiple,
width: '200px',
options: [],
placeholder: '请选择${title}',
},
{
key: 'proProcess',
title: '前导工序',
align: "center",
dataIndex: 'proProcess',
width: 150,
scopedSlots: {customRender: 'proProcess'}
dictCode: 'zy_process,process_name,id,id in(select process_id from zy_product_process where product_id="1")',
width: '150',
type: JVXETypes.select
},
{
title: '后导工序',
align: "center",
dataIndex: 'proProcess',
width: 150,
scopedSlots: {customRender: 'postProcess'}
},
{
title: '输入产品',
align: "center",
dataIndex: 'inputProduct',
width: 150,
scopedSlots: {customRender: 'inputProduct'}
},
{
title: '成品/半成品',
align: "center",
dataIndex: 'semiProduct',
width: 150,
scopedSlots: {customRender: 'semiProduct'}
},
// {
// title: 'operation',
// dataIndex: 'operation',
// scopedSlots: {customRender: 'operation'},
// },
// {
// title: '',
// dataIndex: 'action',
// align: "center",
// fixed: "right",
// width: 147,
// scopedSlots: {customRender: 'action'}
// }
{key: 'postProcess', title: '后导工序', width: '150', type: JVXETypes.select},
{key: 'inputProduct', title: '输入产品', width: '150', type: JVXETypes.input},
{key: 'semiProduct', title: '成品/半成品', width: '150', type: JVXETypes.input},
],
editingKey: '',
url: {
list: "/org.jeecg.modules.productplan/zyPlanProcess/getProcessDatalist",
stationToolslist: "/stationTool/list",
stationMachinelist: "/stationMachine/list",
// productPlanlist: "/org.jeecg.modules.productplan/zyProductPlan/list",
delete: "/org.jeecg.modules.productplan/zyPlanProcess/delete",
// deleteBatch: "/org.jeecg.modules.productplan/zyPlanProcess/deleteBatch",
// exportXlsUrl: "/org.jeecg.modules.productplan/zyPlanProcess/exportXls",
// importExcelUrl: "org.jeecg.modules.productplan/zyPlanProcess/importExcel",
stationToolslist: "/stationTool/list2",
stationMachinelist: "/stationMachine/list2",
addProcessBatch: "/org.jeecg.modules.productplan/zyPlanProcess/addProcessBatch",
},
loadRouteType: false,
planId: "",
dictOptions: {},
// superFieldList: [],
superFieldList: [],
stationList: [],
toolsList: [],
machineList: [],
clickTrue: true,
}
},
created() {
this.getSuperFieldList();
},
computed: {
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
methods: {
//
handleTableSave({$table, target}) {
console.log("保存开始-----")
//
$table.validate().then((errMap) => {
//
if (!errMap) {
//
let tableData = target.getTableData()
tableData.forEach(item => {
item.id = '';
})
console.log('当前保存的数据是:', tableData)
// //
// let newData = target.getNewData()
// console.log('-- ', newData)
// //
// let deleteData = target.getDeleteData()
// console.log('-- ', deleteData)
//
this.loading = true
postAction(this.url.addProcessBatch, tableData).then(res => {
if (res.success) {
this.$message.success(`保存成功!`)
} else {
this.$message.warn(`保存失败:` + res.message)
}
}).finally(() => {
this.loading = false
})
}
})
},
fanHui() {
this.$router.push({
path: '/productplan/ZyPlanProcessList',
});
},
getToolAndMachine(stationId) {
// alert("stationId=" + stationId);
getAction(this.url.stationToolslist, {"stationId": stationId}).then((res) => {
if (res.success) {
this.toolsList = res.result.records || res.result;
console.log("toolsList", JSON.stringify(this.toolsList))
} else {
this.$message.warning(res.message)
}
});
getAction(this.url.stationMachinelist, {"stationId": stationId}).then((res) => {
if (res.success) {
this.machineList = res.result.records || res.result;
console.log("machineList", JSON.stringify(this.toolsList))
} else {
this.$message.warning(res.message)
}
});
},
//
loadParameter() {
if (this.loadRouteType === false) {
@ -307,14 +172,16 @@ export default {
}
},
loadData(arg) {
console.log("the loadData---------开始");
// var that = this;
if (!this.url.list) {
this.$message.error("请设置url.list属性!")
return
}
// 1
if (arg === 1) {
this.ipagination.current = 1;
}
// if (arg === 1) {
// this.ipagination.current = 1;
// }
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
@ -322,19 +189,12 @@ export default {
getAction(this.url.list, params).then((res) => {
if (res.success) {
this.dataSource = res.result.records || res.result;
if (res.result.total) {
this.ipagination.total = res.result.total;
} else {
this.ipagination.total = 0;
}
this.stationList = this.dataSource[0].stationList;
} else {
// this.stationIdCode = "station,station_name,id,depart_id in (select workshop_id from zy_product_plan where id='" + this.planId + "')";
this.$message.warning(res.message)
}
}).finally(() => {
// this.dataSource.forEach(item => {
// item['stationName'] = this.stationName;
// item['stationNum'] = this.stationNum;
// })
this.loading = false
})
},
@ -352,78 +212,61 @@ export default {
param.planId = this.planId;
return filterObj(param);
},
// initDictConfig() {
// },
getSuperFieldList() {
// let fieldList = [];
// fieldList.push({type: 'string', value: 'id', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'planId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productName', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'stationId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'machineIds', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'toolsIds', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productProcessId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productProcessId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'userIds', text: 'id', dictCode: ''})
// this.superFieldList = fieldList
},
// handleChange(value, key, column) {
// const newData = [...this.data];
// const target = newData.find(item => key === item.key);
// if (target) {
// target[column] = value;
// this.data = newData;
// }
// },
edit(key) {
alert("the edit() record =" + JSON.stringify(key))
// const newData = [...this.data];
const newData = [...this.dataSource];
// const newData = record;
console.log("the edit() newData =", JSON.stringify(newData));
// this.editingKey = '0';
// record.editable = true;
// const target = newData.find(item => key === item.key);
const target = newData[0];
console.log("the edit() target =", JSON.stringify(target));
this.editingKey = key;
console.log("the edit() editingKey =", this.editingKey);
if (target) {
// debugger;
target.editable = true;
this.dataSource = newData;
}
},
save(key) {
// const newData = [...this.data];
const newData = this.dataSource;
console.log("save() newData=", JSON.stringify(newData))
const newCacheData = [...this.cacheData];
const target = newData.find(item => key === item.key);
const targetCache = newCacheData.find(item => key === item.key);
if (target && targetCache) {
delete target.editable;
this.dataSource = newData;
Object.assign(targetCache, target);
this.cacheData = newCacheData;
}
this.editingKey = '';
//
handleSelectRowChange(event) {
console.log("handleSelectRowChange")
console.log("handleSelectRowChange-event:", event)
const {type, row, column, value, target, $table} = event
console.log(JSON.stringify(this.stationList));
// target.$refs.vxe.columns[6].dictCode = this.stationIdCode;
target.$refs.vxe.columns[6].options = this.stationList;
//
// target.setValues([{
// rowKey: row.id,
// values: {machineIds: '', toolsIds: ''}
// }])
// target.$refs.vxe.columns[4].options = []
},
cancel(key) {
const newData = this.dataSource;
const target = newData.find(item => key === item.key);
this.editingKey = '';
if (target) {
Object.assign(target, this.cacheData.find(item => key === item.key));
delete target.editable;
this.dataSource = newData;
/** 当选项被改变时,联动其他组件 */
handleValueChange(event) {
const {type, row, column, value, target} = event
console.log("event", event)
console.log("row", row)
// if (type === JVXETypes.select) {
//
if (column.key === 'stationId') {
// options
console.log('this stationid(row.id):', row.stationId)
//
target.setValues([{
rowKey: row.id,
values: {machineIds: '', toolsIds: ''}
}])
target.$refs.vxe.columns[7].options = []
target.$refs.vxe.columns[8].options = []
getAction(this.url.stationMachinelist, {"stationId": row.stationId}).then((res) => {
if (res.success) {
this.machineList = res.result.records || res.result;
console.log("machineList", JSON.stringify(this.machineList))
target.$refs.vxe.columns[7].options = this.machineList;
} else {
this.$message.warning(res.message)
}
});
getAction(this.url.stationToolslist, {"stationId": row.stationId}).then((res) => {
if (res.success) {
this.toolsList = res.result.records || res.result;
console.log("toolsList", JSON.stringify(this.toolsList))
target.$refs.vxe.columns[8].options = this.toolsList;
} else {
this.$message.warning(res.message)
}
});
}
},
}
},
};
</script>
<style scoped>
.editable-row-operations a {
margin-right: 8px;
}
</style>

@ -1,52 +1,13 @@
<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 -->
<!-- 操作按钮区域 -->
<!-- <div class="table-operator">-->
<!--&lt;!&ndash; <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>&ndash;&gt;-->
<!-- <a-button type="primary" icon="download" @click="handleExportXls('生产计划工序')">导出</a-button>-->
<!-- &lt;!&ndash; <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"&ndash;&gt;-->
<!-- &lt;!&ndash; @change="handleImportExcel">&ndash;&gt;-->
<!-- &lt;!&ndash; <a-button type="primary" icon="import">导入</a-button>&ndash;&gt;-->
<!-- &lt;!&ndash; </a-upload>&ndash;&gt;-->
<!-- &lt;!&ndash; 高级查询区域 &ndash;&gt;-->
<!-- <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>-->
<div class="table-operator">
<!-- <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>-->
<!-- <a-button @click="zyStyleFabricHandleAdd(stationId)" type="primary" icon="plus">新增</a-button>-->
<a-button type="primary" icon="download" @click="handleExportXls('1')">导出</a-button>
<a-button type="primary" icon="download" @click="handleExportXls('计划工序')">导出</a-button>
<a-button type="primary" @click="fanHui()">保存</a-button>
<a-button type="primary" @click="fanHui()">返回</a-button>
</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"
@ -77,12 +38,59 @@
</span>
<span slot="machineList" slot-scope="machineList">
<a-select style="width: 180px" placeholder="请选择">
<a-select-option v-for="item in machineList" :value="item.id">
{{ item.name }}
</a-select-option>
</a-select>
<a-select style="width: 180px" placeholder="请选择">
<a-select-option v-for="item in machineList" :value="item.id">
{{ item.name }}
</a-select-option>
</a-select>
</span>
<span slot="proProcess" slot-scope="proProcess">
<j-search-select-tag type="list" dict="zy_process,process_name,id,id in(select process_id from zy_product_process where product_id='1')" pidField="pid"
pidValue="" placeholder="前导工序"/>
</span>
<span slot="postProcess" slot-scope="postProcess">
<j-search-select-tag type="list" dict="zy_process,process_name,id,id in(select process_id from zy_product_process where product_id='1')" pidField="pid"
pidValue="" placeholder="后导工序"/>
</span>
<span slot="inputProduct" slot-scope="inputProduct">
<a-input v-model="processIds" placeholder="请输入产品"></a-input>
</span>
<span slot="semiProduct" slot-scope="semiProduct">
<a-input v-model="semiProduct" placeholder="请输入成品/半成品"></a-input>
</span>
<!-- <template
v-for="col in columns"
:slot="col"
slot-scope="text, record, index"
>
<div :key="col">
<a-input
v-if="record.editable"
style="margin: -5px 0"
:value="text"
@change="e => handleChange(e.target.value, record.key, col)"
/>
<template v-else>
{{ text }}
</template>
</div>
</template>
<template slot="operation" slot-scope="text, record, index">
<div class="editable-row-operations">
<span v-if="record.editable">
<a @click="() => save(record)">Save</a>
<a-popconfirm title="Sure to cancel?" @confirm="() => cancel(record)">
<a>Cancel</a>
</a-popconfirm>
</span>
<span>
<a :disabled="editingKey !== ''" @click="() => edit(index)">Edit66</a>
</span> b
</div>
</template>-->
</a-table>
</div>
@ -110,13 +118,16 @@ export default {
ZyPlanProcessModal
},
data() {
// this.cacheData = this.dataSource.map(item => ({ ...item }));
this.cacheData = [];
return {
description: '生产计划工序管理页面',
// columns,
//
columns: [
{
title: '#',
dataIndex: '',
dataIndex: 'productProcessId',
key: 'rowIndex',
width: 60,
align: "center",
@ -124,21 +135,27 @@ export default {
return parseInt(index) + 1;
}
},
// {
// title: 'id',
// align: "center",
// dataIndex: 'planId'
// },
/* {
title: '计划id',
align: "center",
dataIndex: 'planId'
},*/
{
title: '工单编号',
align: "center",
dataIndex: 'workOrderId'
dataIndex: 'workOrderId',
scopedSlots: {customRender: 'workOrderId'}
},
{
/*{
title: '产品id',
align: "center",
dataIndex: 'productId'
},
{
title: '工序id',
align: "center",
dataIndex: 'productProcessId'
},*/
{
title: '产品',
align: "center",
@ -166,8 +183,8 @@ export default {
align: "center",
dataIndex: 'toolsList',
width: 150,
scopedSlots: {customRender: 'toolsList'}
// scopedSlots: {customRender: this.toolsList}
scopedSlots: {customRender: 'toolsList'}
},
{
title: '工具设备列表',
@ -177,14 +194,50 @@ export default {
scopedSlots: {customRender: 'machineList'}
},
{
title: '操作',
dataIndex: 'action',
title: '前导工序',
align: "center",
fixed: "right",
width: 147,
scopedSlots: {customRender: 'action'}
}
dataIndex: 'proProcess',
width: 150,
scopedSlots: {customRender: 'proProcess'}
},
{
title: '后导工序',
align: "center",
dataIndex: 'proProcess',
width: 150,
scopedSlots: {customRender: 'postProcess'}
},
{
title: '输入产品',
align: "center",
dataIndex: 'inputProduct',
width: 150,
scopedSlots: {customRender: 'inputProduct'}
},
{
title: '成品/半成品',
align: "center",
dataIndex: 'semiProduct',
width: 150,
scopedSlots: {customRender: 'semiProduct'}
},
// {
// title: 'operation',
// dataIndex: 'operation',
// scopedSlots: {customRender: 'operation'},
// },
// {
// title: '',
// dataIndex: 'action',
// align: "center",
// fixed: "right",
// width: 147,
// scopedSlots: {customRender: 'action'}
// }
],
editingKey: '',
url: {
list: "/org.jeecg.modules.productplan/zyPlanProcess/getProcessDatalist",
stationToolslist: "/stationTool/list",
@ -198,7 +251,7 @@ export default {
loadRouteType: false,
planId: "",
dictOptions: {},
superFieldList: [],
// superFieldList: [],
toolsList: [],
machineList: [],
}
@ -295,48 +348,75 @@ export default {
// initDictConfig() {
// },
getSuperFieldList() {
let fieldList = [];
fieldList.push({type: 'string', value: 'planId', text: '生产计划id', dictCode: ''})
fieldList.push({type: 'string', value: 'stationId', text: '工位id', dictCode: ''})
fieldList.push({type: 'string', value: 'machineIds', text: '设备id列表', dictCode: ''})
fieldList.push({type: 'string', value: 'toolsIds', text: '工具id列表', dictCode: ''})
fieldList.push({type: 'string', value: 'processIds', text: '工序id列表', dictCode: ''})
fieldList.push({type: 'string', value: 'userIds', text: '成员id列表', dictCode: ''})
this.superFieldList = fieldList
// let fieldList = [];
// fieldList.push({type: 'string', value: 'id', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'planId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productName', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'stationId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'machineIds', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'toolsIds', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productProcessId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'productProcessId', text: 'id', dictCode: ''})
// fieldList.push({type: 'string', value: 'userIds', text: 'id', dictCode: ''})
// this.superFieldList = fieldList
},
// jumpPage1(record) {
// this.$router.push({
// // path: '/productplan/ZyProductPlanList',
// path: '/productplan/ZyPlanProcessDataList',
//
// // query: { //
// // 'stationId': record.id,
// // 'stationName': record.stationName,
// // },
// });
// },
// pf(record) {
// this.$router.push({
// path: '/productplan/ZyPlanProcessAddList',
// query: { //
// }
// });
// getAction("productPlanlist", {id: record.id}).then((res) => {
// if (res.success) {
// this.$router.push({
// path: '/src/views/processassessment/assessmentCourse/ClassOpeningTaskList',
// query: { //
// }
// });
// } else {
// this.$message.error(res.message)
// handleChange(value, key, column) {
// const newData = [...this.data];
// const target = newData.find(item => key === item.key);
// if (target) {
// target[column] = value;
// this.data = newData;
// }
// });
// },
}
}
edit(key) {
alert("the edit() record =" + JSON.stringify(key))
// const newData = [...this.data];
const newData = [...this.dataSource];
// const newData = record;
console.log("the edit() newData =", JSON.stringify(newData));
// this.editingKey = '0';
// record.editable = true;
// const target = newData.find(item => key === item.key);
const target = newData[0];
console.log("the edit() target =", JSON.stringify(target));
this.editingKey = key;
console.log("the edit() editingKey =", this.editingKey);
if (target) {
// debugger;
target.editable = true;
this.dataSource = newData;
}
},
save(key) {
// const newData = [...this.data];
const newData = this.dataSource;
console.log("save() newData=", JSON.stringify(newData))
const newCacheData = [...this.cacheData];
const target = newData.find(item => key === item.key);
const targetCache = newCacheData.find(item => key === item.key);
if (target && targetCache) {
delete target.editable;
this.dataSource = newData;
Object.assign(targetCache, target);
this.cacheData = newCacheData;
}
this.editingKey = '';
},
cancel(key) {
const newData = this.dataSource;
const target = newData.find(item => key === item.key);
this.editingKey = '';
if (target) {
Object.assign(target, this.cacheData.find(item => key === item.key));
delete target.editable;
this.dataSource = newData;
}
},
},
};
</script>
<style scoped>
@import '~@assets/less/common.less';
.editable-row-operations a {
margin-right: 8px;
}
</style>

@ -20,17 +20,17 @@
<!-- 高级查询区域 -->
<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>
<!-- <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>-->
<!--&lt;!&ndash; <a-button style="margin-left: 8px"> 批量操作&ndash;&gt;-->
<!--&lt;!&ndash; <a-icon type="down"/>&ndash;&gt;-->
<!--&lt;!&ndash; </a-button>&ndash;&gt;-->
<!-- </a-dropdown>-->
</div>
<!-- table区域-begin -->
@ -171,12 +171,12 @@ export default {
dataIndex: 'toolsIds_dictText',
scopedSlots: {customRender: 'toolsIds_dictText'}
},
{
title: '成员',
align: "center",
dataIndex: 'userIds_dictText',
scopedSlots: {customRender: 'userIds_dictText'}
},
// {
// title: '',
// align: "center",
// dataIndex: 'userIds_dictText',
// scopedSlots: {customRender: 'userIds_dictText'}
// },
{
title:'前导工序',
align:"center",

@ -0,0 +1,257 @@
<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="更新日期">
<j-date :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择更新日期" v-model="queryParam.updateTime"></j-date>
</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.partmentId" dict="sys_depart,depart_name,id"/>
</a-form-item>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="是否专属">
<j-dict-select-tag placeholder="请选择是否专属" v-model="queryParam.exclusive" dictCode="yn"/>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="仓库存储规则">
<j-dict-select-tag placeholder="请选择仓库存储规则" v-model="queryParam.type" dictCode="goods_category"/>
</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.userId" dict="sys_user,realname,id"/>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="库存预定">
<j-dict-select-tag placeholder="请选择库存预定" v-model="queryParam.state" dictCode="yn"/>
</a-form-item>
</a-col>
</template>
<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>
<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>
<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-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</a-menu-item>
</a-menu>
</a-dropdown>
</span>
</a-table>
</div>
<starehouse-modal ref="modalForm" @ok="modalFormOk"></starehouse-modal>
</a-card>
</template>
<script>
import '@/assets/less/TableExpand.less'
import { mixinDevice } from '@/utils/mixin'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import StarehouseModal from './modules/StarehouseModal'
import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
export default {
name: 'StarehouseList',
mixins:[JeecgListMixin, mixinDevice],
components: {
StarehouseModal
},
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: 'updateTime'
},
{
title:'名称',
align:"center",
dataIndex: 'name'
},
{
title:'部门',
align:"center",
dataIndex: 'partmentId_dictText'
},
{
title:'是否专属',
align:"center",
dataIndex: 'exclusive_dictText'
},
{
title:'仓库存储规则',
align:"center",
dataIndex: 'type_dictText'
},
{
title:'地址',
align:"center",
dataIndex: 'address'
},
{
title:'管理员',
align:"center",
dataIndex: 'userId_dictText'
},
{
title:'库存预定',
align:"center",
dataIndex: 'state_dictText'
},
{
title: '操作',
dataIndex: 'action',
align:"center",
fixed:"right",
width:147,
scopedSlots: { customRender: 'action' }
}
],
url: {
list: "/starehouse/starehouse/list",
delete: "/starehouse/starehouse/delete",
deleteBatch: "/starehouse/starehouse/deleteBatch",
exportXlsUrl: "/starehouse/starehouse/exportXls",
importExcelUrl: "starehouse/starehouse/importExcel",
},
dictOptions:{},
superFieldList:[],
}
},
created() {
this.getSuperFieldList();
},
computed: {
importExcelUrl: function(){
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
},
},
methods: {
initDictConfig(){
},
getSuperFieldList(){
let fieldList=[];
fieldList.push({type:'datetime',value:'updateTime',text:'更新日期'})
fieldList.push({type:'string',value:'name',text:'名称',dictCode:''})
fieldList.push({type:'sel_search',value:'partmentId',text:'部门',dictTable:'sys_depart', dictText:'depart_name', dictCode:'id'})
fieldList.push({type:'popup',value:'partmentnae',text:'部门', popup:{code:'findckadmin',field:'id',orgFields:'id',destFields:'partment_id'}})
fieldList.push({type:'int',value:'exclusive',text:'是否专属',dictCode:'yn'})
fieldList.push({type:'string',value:'address',text:'地址',dictCode:''})
fieldList.push({type:'sel_search',value:'userId',text:'管理员',dictTable:'sys_user', dictText:'realname', dictCode:'id'})
fieldList.push({type:'popup',value:'username',text:'管理员', popup:{code:'findck',field:'id',orgFields:'id',destFields:'user_id'}})
fieldList.push({type:'string',value:'state',text:'库存预定',dictCode:'yn'})
this.superFieldList = fieldList
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>

@ -0,0 +1,160 @@
<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="updateTime">
<j-date placeholder="请选择更新日期" v-model="model.updateTime" :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" style="width: 100%" disabled/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="name">
<a-input v-model="model.name" placeholder="请输入名称" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="部门" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="partmentnae">
<j-popup
v-model="model.partmentnae"
field="partmentnae"
org-fields="id,depart_name"
dest-fields="partmentId,partmentnae"
code="findckadmin"
:multi="true"
@input="popupCallback"
/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="是否专属" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="exclusive">
<j-dict-select-tag type="radio" v-model="model.exclusive" dictCode="yn" placeholder="请选择是否专属" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="仓库存储规则" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="type">
<j-dict-select-tag type="list" v-model="model.type" dictCode="goods_category" placeholder="请选择仓库存储规则" />
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="地址" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="address">
<a-input v-model="model.address" placeholder="请输入地址" ></a-input>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="管理员" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="username">
<j-popup
v-model="model.username"
field="username"
org-fields="id,realname"
dest-fields="userId,username"
code="findck"
:multi="true"
@input="popupCallback"
/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="库存预定" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="state">
<j-dict-select-tag type="radio" v-model="model.state" dictCode="yn" placeholder="请选择库存预定" />
</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: 'StarehouseForm',
components: {
},
props: {
//
disabled: {
type: Boolean,
default: false,
required: false
}
},
data () {
return {
model:{
exclusive : "1",
state : "1"
},
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 },
},
confirmLoading: false,
validatorRules: {
},
url: {
add: "/starehouse/starehouse/add",
edit: "/starehouse/starehouse/edit",
queryById: "/starehouse/starehouse/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;
})
}
})
},
popupCallback(value,row){
this.model = Object.assign(this.model, row);
},
}
}
</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="关闭">
<starehouse-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></starehouse-form>
</j-modal>
</template>
<script>
import StarehouseForm from './StarehouseForm'
export default {
name: 'StarehouseModal',
components: {
StarehouseForm
},
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">
<starehouse-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit" normal></starehouse-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 StarehouseForm from './StarehouseForm'
export default {
name: 'StarehouseModal',
components: {
StarehouseForm
},
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>

@ -11,14 +11,17 @@
<a-table
ref="table"
bordered
size="middle"
bordered
rowKey="id"
class="j-table-force-nowrap"
:scroll="{x:true}"
:columns="columns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
:customRow="clickThenSelect"
@change="handleTableChange">
</a-table>
@ -40,10 +43,12 @@ import JSuperQuery from '@/components/jeecg/JSuperQuery'
import JThirdAppButton from '@/components/jeecgbiz/thirdApp/JThirdAppButton'
import UserModalDetail from './modules/UserModalDetail'
import {filterObj} from "@/utils/util";
import {mixinDevice} from '@/utils/mixin'
export default {
name: "User2ListRef",
mixins: [JeecgListMixin],
mixins: [JeecgListMixin, mixinDevice],
components: {
JThirdAppButton,
SysUserAgentModal,
@ -58,7 +63,7 @@ export default {
return {
description: '这是用户管理页面',
queryParam: {},
groupxId:'',
groupId:'',
recycleBinVisible: false,
columns: [
/*{
@ -138,19 +143,27 @@ export default {
// }
],
// superQueryFieldList: [
// {type: 'input', value: 'username', text: '',},
// {type: 'input', value: 'realname', text: '',},
// {type: 'select', value: 'sex', text: '', dictCode: 'sex'},
// ],
url: {
syncUser: "/act/process/extActProcess/doSyncUser",
listByDepartId: "/sys/user/listByDepartId",
delete: "/sys/user/delete",
deleteBatch: "/sys/user/deleteBatch",
exportXlsUrl: "/sys/user/exportXls",
importExcelUrl: "sys/user/importExcel",
list: "/sys/user/listByDepartId",
},
loadRouteType: false,
dictOptions:{
},
/* 分页参数 */
ipagination:{
current: 1,
pageSize: 5,
pageSizeOptions: ['5', '10', '50'],
showTotal: (total, range) => {
return range[0] + "-" + range[1] + " 共" + total + "条"
},
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
selectedMainId:'',
superFieldList:[],
selectedRowKeys: [],
}
},
computed: {
@ -158,23 +171,24 @@ export default {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
}
},
created() {
this.loadData();
},
// created() {
// this.loadData();
// },
methods: {
// valueChange(value) {
// if (value) this.loadData()
// },
//
loadParameter() {
if (this.loadRouteType === false) {
this.groupxId = this.$router.
this.groupId = this.$route.query.groupxId;
this.loadRouteType = true;
}
},
loadData2(groupxId) {
alert("loadData groupxId:"+groupxId)
if (!this.url.listByDepartId) {
loadData(arq) {
// alert("loadData groupId:"+arq)
if (!this.url.list) {
this.$message.error("请设置url.list属性!")
return
}
@ -182,11 +196,12 @@ export default {
// if (arg === 1) {
// this.ipagination.current = 1;
// }
this.onClearSelected();
this.loadParameter();
var params = this.getQueryParams();//
this.loading = true;
console.log("----------------the params:", params);
getAction(this.url.listByDepartId, params).then((res) => {
console.log("----------------loadData()-the params:", params);
getAction(this.url.list, params).then((res) => {
if (res.success) {
this.dataSource = res.result.records || res.result;
if (res.result.total) {
@ -198,10 +213,10 @@ export default {
this.$message.warning(res.message)
}
}).finally(() => {
this.dataSource.forEach(item => {
item['stationName'] = this.stationName;
item['stationNum'] = this.stationNum;
})
// this.dataSource.forEach(item => {
// item['stationName'] = this.stationName;
// item['stationNum'] = this.stationNum;
// })
this.loading = false
})
},
@ -216,7 +231,7 @@ export default {
param.field = this.getQueryField();
param.pageNo = this.ipagination.current;
param.pageSize = this.ipagination.pageSize;
param.groupxId = this.groupxId;
param.groupId = this.groupId;
return filterObj(param);
},
onClearSelected() {
@ -228,6 +243,15 @@ export default {
console.log('selectedRowKeys changed: ', selectedRowKeys);
this.selectedRowKeys = selectedRowKeys;
},
clickThenSelect(record) {
return {
on: {
click: () => {
this.onSelectChange(record.id.split(","), [record]);
}
}
}
},
}
}

@ -16,26 +16,31 @@
<a-input placeholder="请输入班组名称" v-model="queryParam.groupName"></a-input>
</a-form-item>
</a-col>
<template v-if="toggleSearchStatus">
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="负责人">
<a-input placeholder="请输入负责人" v-model="queryParam.enterprisesManager"></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.mobile"></a-input>
</a-form-item>
</a-col>
</template>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="手机号">
<a-input placeholder="请输入手机号" v-model="queryParam.mobile"></a-input>
</a-form-item>
</a-col>
<!-- <template v-if="toggleSearchStatus">-->
<!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">-->
<!-- <a-form-item label="负责人">-->
<!-- <a-input placeholder="请输入负责人" v-model="queryParam.enterprisesManager"></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.mobile"></a-input>-->
<!-- </a-form-item>-->
<!-- </a-col>-->
<!-- </template>-->
<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>
<!-- <a @click="handleToggleSearch" style="margin-left: 8px">-->
<!-- {{ toggleSearchStatus ? '收起' : '展开' }}-->
<!-- <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>-->
<!-- </a>-->
</span>
</a-col>

@ -1,65 +1,10 @@
<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="班组">-->
<!--&lt;!&ndash; <a-input placeholder="请输入班组ID" v-model="queryParam.groupxId"></a-input>&ndash;&gt;-->
<!-- <j-search-select-tag placeholder="请选择班组" v-model="queryParam.groupxId" dict="groupx,group_name,id"/>-->
<!-- </a-form-item>-->
<!-- </a-col>-->
<!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">-->
<!-- <a-form-item label="用户ID">-->
<!-- <a-input placeholder="请输入用户ID" v-model="queryParam.userId"></a-input>-->
<!-- </a-form-item>-->
<!-- </a-col>-->
<!--&lt;!&ndash; <template v-if="toggleSearchStatus">&ndash;&gt;-->
<!--&lt;!&ndash; <a-col :xl="6" :lg="7" :md="8" :sm="24">&ndash;&gt;-->
<!--&lt;!&ndash; <a-form-item label="加入时间">&ndash;&gt;-->
<!--&lt;!&ndash; &lt;!&ndash; <a-input placeholder="请输入加入时间" v-model="queryParam.joinTime"></a-input>&ndash;&gt;&ndash;&gt;-->
<!--&lt;!&ndash; <a-date-picker showTime valueFormat='YYYY-MM-DD HH:mm:ss' v-model="queryParam.joinTime"/>&ndash;&gt;-->
<!--&lt;!&ndash; </a-form-item>&ndash;&gt;-->
<!--&lt;!&ndash; </a-col>&ndash;&gt;-->
<!--&lt;!&ndash; </template>&ndash;&gt;-->
<!-- <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>-->
<!--&lt;!&ndash; <a @click="handleToggleSearch" style="margin-left: 8px">&ndash;&gt;-->
<!--&lt;!&ndash; {{ toggleSearchStatus ? '收起' : '展开' }}&ndash;&gt;-->
<!--&lt;!&ndash; <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>&ndash;&gt;-->
<!--&lt;!&ndash; </a>&ndash;&gt;-->
<!-- </span>-->
<!-- </a-col>-->
<!-- </a-row>-->
<!-- </a-form>-->
<!-- </div>-->
<!-- 操作按钮区域 -->
<div class="table-operator">
<!-- <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>-->
<a-button @click="zyStyleFabricHandleAdd(groupxId)" 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>-->
<!-- <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>-->
<a-button type="primary" @click="fanHui()">返回</a-button>
</div>
@ -141,12 +86,12 @@ export default {
{
title: '工号',
align: "center",
dataIndex: 'workNo_dictText'
dataIndex: 'workNo'
},
{
title: '成员名称',
align: "center",
dataIndex: 'userId_dictText'
dataIndex: 'userId'
},
{
title: '加入时间',
@ -253,6 +198,6 @@ export default {
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>
<!--<style scoped>-->
<!--@import '~@assets/less/common.less';-->
<!--</style>-->

@ -84,7 +84,9 @@
<template slot="content">
<p>{{ text }}</p>
</template>
<a style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;display: inline-block;width: 100px">{{ text }}</a>
<a style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;display: inline-block;width: 100px">{{
text
}}</a>
</a-popover>
</span>
<span slot="machineIds_dictText" slot-scope="text, record">
@ -92,12 +94,13 @@
<template slot="content">
<p>{{ text }}</p>
</template>
<a style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;display: inline-block;width: 100px">{{ text }}</a>
<a style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;display: inline-block;width: 100px">{{
text
}}</a>
</a-popover>
</span>
<span slot="action1" slot-scope="text, record">
<a @click="jumpPage1(record)">管理</a>
</span>
@ -112,6 +115,10 @@
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete2(record.id)">
<a>删除</a>
</a-popconfirm>
<a-divider type="vertical"/>
<a @click="up(record.id)">升序</a>
<a-divider type="vertical"/>
<a @click="down(record.id)">降序</a>
</span>
</a-table>
</div>
@ -214,6 +221,8 @@ export default {
url: {
list: "/team/station/list",
queryIsCanDelete: "/team/station/queryIsCanDelete",
up: "/team/station/up",
down: "/team/station/down",
delete: "/team/station/delete",
deleteBatch: "/team/station/deleteBatch",
exportXlsUrl: "/team/station/exportXls",
@ -279,9 +288,30 @@ export default {
}
})
},
up(id) {
getAction(this.url.up, {id: id}).then((res) => {
if (res.success) {
this.loadData();
this.$message.success(res.message);
} else {
this.$message.warning(res.message);
}
})
},
down(id) {
getAction(this.url.down, {id: id}).then((res) => {
if (res.success) {
this.loadData();
this.$message.success(res.message);
} else {
this.$message.warning(res.message);
}
})
},
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>
<!--<style scoped>-->
<!--@import '~@assets/less/common.less';-->
<!--</style>-->

@ -146,11 +146,11 @@ export default {
align: "center",
dataIndex: 'stationName',
},
// {
// title: 'ID',
// align: "center",
// dataIndex: 'machineId'
// },
{
title: '设备编号',
align: "center",
dataIndex: 'machineId'
},
{
title: '设备名称',
align: "center",

@ -144,11 +144,11 @@ export default {
align: "center",
dataIndex: 'stationName',
},
// {
// title: 'ID',
// align: "center",
// dataIndex: 'toolsId'
// },
{
title: '工具编号',
align: "center",
dataIndex: 'toolsId'
},
{
title: '工具名称',
align: "center",

@ -39,15 +39,16 @@ export default {
confirmLoading: false,
validatorRules: {
userId: [
{required: true, message: "成员不能为空"},
],
// userId: [
// {required: true, message: ""},
// ],
// joinTime: [
// {required: true},
// ]
},
url: {
add: "/groupxMember/add",
list: "/sys/user/listByDepartId",
addBatch: "/groupxMember/addBatch",
edit: "/groupxMember/edit",
}
@ -58,10 +59,9 @@ export default {
add(groupxId) {
this.model.groupxId = groupxId;
console.log("Modal层接收到上级参数-groupxId:" + this.model.groupxId);
this.$refs["modalForm"].loadData2(this.model.groupxId);
this.edit(this.model);
},
// add () {
// add() {
// //
// this.edit({});
// },
@ -76,13 +76,8 @@ export default {
this.$refs.form.clearValidate();
},
handleOk2() {
// this.$refs["modalForm2"].loadData(this.model.groupxId);
this.model.userId = this.$refs["modalForm"].selectedRowKeys.toString();
// console.log("model.toolids:"+this.model.toolsId);
const that = this;
//
// this.$refs.form.validate(valid => {
// if (valid) {
that.confirmLoading = true;
let httpurl = '';
let method = '';
@ -104,53 +99,12 @@ export default {
}).finally(() => {
that.confirmLoading = false;
that.close();
})
// } else {
// return false;
// }
// })
},
handleOk() {
const that = this;
//
this.$refs.form.validate(valid => {
if (valid) {
that.confirmLoading = true;
let httpurl = '';
let method = '';
if (!this.model.id) {
httpurl += this.url.addBatch;
method = 'post';
} else {
httpurl += this.url.edit;
method = 'put';
}
console.log("----------the add() model:", this.model);
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;
that.close();
})
} else {
return false;
}
that.loadData();
})
},
handleCancel() {
this.close()
},
}
},
}
</script>
<style lang="less" scoped>
</style>
</script>

@ -67,7 +67,7 @@ export default {
},
data() {
return {
enterprisesManager: "sys_user,username,id",
enterprisesManager: "sys_user,realname,id",
title: "操作",
visible: false,
// mobileVal: "",

@ -27,19 +27,18 @@
<!-- </a-form-model>-->
<!-- </a-spin>-->
<ZyDevicetypeListRef ref="modalForm2"></ZyDevicetypeListRef>
<ZyDeviceListRef ref="modalForm2"></ZyDeviceListRef>
</j-modal>
</template>
<script>
import {httpAction} from '@/api/manage'
import moment from "moment"
import ZyDevicetypeListRef from '@views/devicetype/ZyDevicetypeListRef'
import ZyDeviceListRef from '@views/device/ZyDeviceListRef'
export default {
name: "StationMachineModal",
components:{
ZyDevicetypeListRef
ZyDeviceListRef
},
data() {
return {
@ -49,14 +48,14 @@ export default {
stationId: '',
machineId:[],
},
labelCol: {
xs: {span: 24},
sm: {span: 5},
},
wrapperCol: {
xs: {span: 24},
sm: {span: 16},
},
// labelCol: {
// xs: {span: 24},
// sm: {span: 5},
// },
// wrapperCol: {
// xs: {span: 24},
// sm: {span: 16},
// },
confirmLoading: false,
validatorRules: {

@ -108,7 +108,7 @@
</a-button>
</template>
// TODO:
<!--跳转到模块样板-->
<span slot="action1" slot-scope="text, record">
<a @click="jumpPage(record)">模块样板</a>
</span>

@ -1,20 +1,20 @@
<template>
<a-card :bordered="false">
<p style="font-size: 30px;color:#333;padding-left: 40%">{{biaoTi}}</p>
<!-- 查询区域 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col>
<!-- <div class="table-page-search-wrapper">-->
<!-- <a-form layout="inline" @keyup.enter.native="searchQuery">-->
<!-- <a-row :gutter="24">-->
<!-- <a-col>-->
<!-- <a-button type="primary">{{biaoTi}}</a-button>-->
<p style="font-size: 30px;color:#333;padding-left: 40%">{{biaoTi}}</p>
</a-col>
</a-row>
</a-form>
</div>
<!-- </a-col>-->
<!-- </a-row>-->
<!-- </a-form>-->
<!-- </div>-->
<!-- 查询区域-END -->
<a-button type="primary" icon="rollback" @click="fanHui()">返回</a-button>
<!-- <a-button type="primary" icon="rollback" @click="fanHui()">返回</a-button>-->
<!-- table区域-begin -->
<div >
<j-vxe-table
@ -32,12 +32,22 @@
:pagination="pagination"
style="margin-top: 8px;"
@pageChange="handlePageChange"
@valueChange="handleValueChange"
@added="added"
>
<template v-slot:toolbarSuffix>
<a-button type="primary" icon="rollback" @click="fanHui()">返回</a-button>
<!-- <a-tooltip placement="top" title="获取值,忽略表单验证" :autoAdjustOverflow="true">-->
<!-- <a-button @click="handleTableGet">获取值</a-button>-->
<!-- </a-tooltip>-->
<!-- <a-tooltip placement="top" title="模拟加载1000条数据" :autoAdjustOverflow="true">-->
<!-- <a-button @click="handleTableSet">设置值</a-button>-->
<!-- </a-tooltip>-->
</template>
<template v-slot:action="props">
<a @click="submitForm(props)">保存</a>
<a-divider type="vertical"/>
<!-- <a @click="submitForm(props)">保存</a>-->
<!-- <a-divider type="vertical"/>-->
<a @click="viewDetail(props.rowId)">详情</a>
<a-divider type="vertical" />
<a-popconfirm title="确定删除吗?" @confirm="handleDelete(props.rowId)">
@ -82,9 +92,9 @@ export default {
btn: ['add'],
},
validatorRules: {
styleId: [
{required: true, message: '请选择服装类型!'},
],
// styleId: [
// {required: true, message: '!'},
// ],
},
//
loading: false,
@ -113,22 +123,25 @@ export default {
key: 'styleId',
type: JVXETypes.select,
placeholder: '请输入${title}',
dictCode: 'zy_cloths_style,style_names,id',
validateRules: [{required: true, message: '${title}不能为空'}]
//dictCode: 'zy_cloths_style,style_names,id',
validateRules: [
{required: true, message: '${title}不能为空'},
],
disabled: true,
},
{
title: '是否默认尺码',
align: "center",
width: '150px',
width: '50px',
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: 'hsize', type: JVXETypes.select},
{key: 'bnumbers', title: '号', width: '100px', dictCode: 'xsize', 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: 'bust', title: '胸围', width: '80px', type: JVXETypes.input},
{key: 'sleeveLength', title: '袖长', width: '80px', type: JVXETypes.input},
@ -138,13 +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},
{
title: '操作',
key: 'action',
type: JVXETypes.slot,
fixed: 'right',
minWidth: '100px',
minWidth: '80px',
align: 'center',
slotName: 'action',
}
@ -159,6 +173,7 @@ export default {
importExcelUrl: "zystylemodel/zyStyleModel/importExcel",
},
//
styleId: '',
loadRouteType: false,
id: null,
rowId: '',
@ -178,6 +193,46 @@ export default {
},
},
methods: {
//
added(event){
//this.styleId = this.$route.query.id;
event.row.styleId = this.$route.query.id;
console.log("新增触发事件", event)
let httpUrl = this.url.add;
let method = 'post';
//httpUrl += this.url.add;
//method = 'post';
httpAction(httpUrl, event.row, method).then((res) => {
if (res.success) {
this.$message.success(res.message);
this.$emit('ok');
} else {
this.$message.warning(res.message);
}
})
},
//
handleValueChange(event) {
//this.submitForm(event)
console.log("//数据发生变化时事件", event);
//const str = event.row.id;
let httpUrl = '';
let method = '';
httpUrl += this.url.edit;
method = 'put';
httpAction(httpUrl, event.row, method).then((res) => {
if (res.success) {
this.$message.success(res.message);
this.$emit('ok');
} else {
this.$message.warning(res.message);
}
})
},
//
viewDetail(id) {
this.$refs.ZyStyleModelListDetails.showModal(id)
@ -234,8 +289,9 @@ export default {
loadParameter() {
if (this.loadRouteType === false) {
this.id = this.$route.query.id;
//this.styleId = this.id;
this.biaoTi = this.$route.query.styleNames + "款式型号管理";
console.log("**********传递到此层的id:" + this.id);
//console.log("**********id" + this.id);
this.loadRouteType = true;
}
},
@ -271,6 +327,7 @@ export default {
this.loading = false
})
},
//
handlePageChange(event) {
//

@ -66,8 +66,8 @@ public class ZyToolController extends JeecgController<ZyTool, IZyToolService> {
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
//QueryWrapper<ZyTool> queryWrapper = QueryGenerator.initQueryWrapper(zyTool, req.getParameterMap());
QueryWrapper queryWrapper = new QueryWrapper();
QueryWrapper<ZyTool> queryWrapper = QueryGenerator.initQueryWrapper(zyTool, req.getParameterMap());
// QueryWrapper queryWrapper = new QueryWrapper();
Page<ZyTool> page = new Page<ZyTool>(pageNo, pageSize);
IPage<ZyTool> pageList = zyToolService.page(page, queryWrapper);
return Result.OK(pageList);

@ -43,14 +43,14 @@ public class ZyStyleModular implements Serializable {
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
// /**更新人*/
// @ApiModelProperty(value = "更新人")
// private String updateBy;
// /**更新日期*/
// @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
// @ApiModelProperty(value = "更新日期")
// private Date updateTime;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;

@ -70,10 +70,10 @@ public class ZyClothsComponent implements Serializable {
@Dict(dicCode = "zyModularType")
private java.lang.String modularType;
/**部件类型*/
@Excel(name = "部件类型", width = 15)
@ApiModelProperty(value = "部件类型")
private java.lang.String componentType;
// /**部件类型*/
// @Excel(name = "部件类型", width = 15)
// @ApiModelProperty(value = "部件类型")
// private java.lang.String componentType;
/**企业*/
@Excel(name = "企业", width = 15)

@ -34,25 +34,25 @@ public class ZyClothsModularCompent implements Serializable {
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**创建人*/
@ApiModelProperty(value = "创建人")
private String createBy;
// /**创建人*/
// @ApiModelProperty(value = "创建人")
// private String createBy;
/**创建日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;
// /**更新人*/
// @ApiModelProperty(value = "更新人")
// private String updateBy;
// /**更新日期*/
// @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
// @ApiModelProperty(value = "更新日期")
// private Date updateTime;
// /**所属部门*/
// @ApiModelProperty(value = "所属部门")
// private String sysOrgCode;
/**编码*/
@Excel(name = "编码", width = 15)
@ApiModelProperty(value = "编码")

@ -217,14 +217,14 @@ public class ZyProcessComponentController extends JeecgController<ZyProcessCompo
String processNameById = zyProcessMapper.getProcessNameById(processId);
zyProcessComponent.setProcessId(processNameById);
//瓶颈工序
String bottleneck = zyProcessComponent.getBottleneck();
if (bottleneck.equals("1")) {
zyProcessComponent.setBottleneck("是");
} else if (bottleneck.equals("2")) {
zyProcessComponent.setBottleneck("否");
} else {
zyProcessComponent.setBottleneck("可能为空或出错了");
}
// String bottleneck = zyProcessComponent.getBottleneck();
// if (bottleneck.equals("1")) {
// zyProcessComponent.setBottleneck("是");
// } else if (bottleneck.equals("2")) {
// zyProcessComponent.setBottleneck("否");
// } else {
// zyProcessComponent.setBottleneck("可能为空或出错了");
// }
return Result.OK(zyProcessComponent);
}

@ -44,11 +44,11 @@ public class ZyProcessComponent implements Serializable {
@Dict(dictTable = "zy_process", dicText = "process_name", dicCode = "id")
@ApiModelProperty(value = "工艺")
private String processId;
/**是否瓶颈工序*/
@Excel(name = "是否瓶颈工序", width = 15,dicCode = "pingjing")
@Dict(dicCode = "pingjing")
@ApiModelProperty(value = "是否瓶颈工序")
private String bottleneck;
// /**是否瓶颈工序*/
// @Excel(name = "是否瓶颈工序", width = 15,dicCode = "pingjing")
// @Dict(dicCode = "pingjing")
// @ApiModelProperty(value = "是否瓶颈工序")
// private String bottleneck;
/**序号*/
@Excel(name = "序号", width = 15,dicCode = "序号")
@ApiModelProperty(value = "序号")

@ -46,13 +46,13 @@ public class ZyProcessComponentServiceImpl extends ServiceImpl<ZyProcessComponen
}else{
processComponent.setComponentId("null");
}
if (processComponent.getBottleneck().equals("1")){
processComponent.setBottleneck("是");
}else if (processComponent.getBottleneck().equals("2")){
processComponent.setBottleneck("否");
}else {
processComponent.setBottleneck(null);
}
// if (processComponent.getBottleneck().equals("1")){
// processComponent.setBottleneck("是");
// }else if (processComponent.getBottleneck().equals("2")){
// processComponent.setBottleneck("否");
// }else {
// processComponent.setBottleneck(null);
// }
}
return zyProcessComponents;
}

@ -0,0 +1,172 @@
package org.jeecg.modules.demo.starehouse.controller;
import java.util.Arrays;
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 org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.demo.starehouse.entity.Starehouse;
import org.jeecg.modules.demo.starehouse.service.IStarehouseService;
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.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: 仓库管理
* @Author: jeecg-boot
* @Date: 2023-01-06
* @Version: V1.0
*/
@Api(tags="仓库管理")
@RestController
@RequestMapping("/starehouse/starehouse")
@Slf4j
public class StarehouseController extends JeecgController<Starehouse, IStarehouseService> {
@Autowired
private IStarehouseService starehouseService;
/**
* 分页列表查询
*
* @param starehouse
* @param pageNo
* @param pageSize
* @param req
* @return
*/
@AutoLog(value = "仓库管理-分页列表查询")
@ApiOperation(value="仓库管理-分页列表查询", notes="仓库管理-分页列表查询")
@GetMapping(value = "/list")
public Result<?> queryPageList(Starehouse starehouse,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
QueryWrapper<Starehouse> queryWrapper = QueryGenerator.initQueryWrapper(starehouse, req.getParameterMap());
Page<Starehouse> page = new Page<Starehouse>(pageNo, pageSize);
IPage<Starehouse> pageList = starehouseService.page(page, queryWrapper);
return Result.OK(pageList);
}
/**
* 添加
*
* @param starehouse
* @return
*/
@AutoLog(value = "仓库管理-添加")
@ApiOperation(value="仓库管理-添加", notes="仓库管理-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody Starehouse starehouse) {
starehouseService.save(starehouse);
return Result.OK("添加成功!");
}
/**
* 编辑
*
* @param starehouse
* @return
*/
@AutoLog(value = "仓库管理-编辑")
@ApiOperation(value="仓库管理-编辑", notes="仓库管理-编辑")
@PutMapping(value = "/edit")
public Result<?> edit(@RequestBody Starehouse starehouse) {
starehouseService.updateById(starehouse);
return Result.OK("编辑成功!");
}
/**
* 通过id删除
*
* @param id
* @return
*/
@AutoLog(value = "仓库管理-通过id删除")
@ApiOperation(value="仓库管理-通过id删除", notes="仓库管理-通过id删除")
@DeleteMapping(value = "/delete")
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
starehouseService.removeById(id);
return Result.OK("删除成功!");
}
/**
* 批量删除
*
* @param ids
* @return
*/
@AutoLog(value = "仓库管理-批量删除")
@ApiOperation(value="仓库管理-批量删除", notes="仓库管理-批量删除")
@DeleteMapping(value = "/deleteBatch")
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
this.starehouseService.removeByIds(Arrays.asList(ids.split(",")));
return Result.OK("批量删除成功!");
}
/**
* 通过id查询
*
* @param id
* @return
*/
@AutoLog(value = "仓库管理-通过id查询")
@ApiOperation(value="仓库管理-通过id查询", notes="仓库管理-通过id查询")
@GetMapping(value = "/queryById")
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
Starehouse starehouse = starehouseService.getById(id);
if(starehouse==null) {
return Result.error("未找到对应数据");
}
return Result.OK(starehouse);
}
/**
* 导出excel
*
* @param request
* @param starehouse
*/
@RequestMapping(value = "/exportXls")
public ModelAndView exportXls(HttpServletRequest request, Starehouse starehouse) {
return super.exportXls(request, starehouse, Starehouse.class, "仓库管理");
}
/**
* 通过excel导入数据
*
* @param request
* @param response
* @return
*/
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
return super.importExcel(request, response, Starehouse.class);
}
}

@ -0,0 +1,99 @@
package org.jeecg.modules.demo.starehouse.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: 仓库管理
* @Author: jeecg-boot
* @Date: 2023-01-06
* @Version: V1.0
*/
@Data
@TableName("starehouse")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="starehouse对象", description="仓库管理")
public class Starehouse implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**创建人*/
@ApiModelProperty(value = "创建人")
private String createBy;
/**创建日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;
/**名称*/
@Excel(name = "名称", width = 15)
@ApiModelProperty(value = "名称")
private String name;
/**部门*/
@Excel(name = "部门", width = 15, dictTable = "sys_depart", dicText = "depart_name", dicCode = "id")
@Dict(dictTable = "sys_depart", dicText = "depart_name", dicCode = "id")
@ApiModelProperty(value = "部门")
private String partmentId;
/**部门*/
@Excel(name = "部门", width = 15)
@ApiModelProperty(value = "部门")
private String partmentnae;
/**是否专属*/
@Excel(name = "是否专属", width = 15, dicCode = "yn")
@Dict(dicCode = "yn")
@ApiModelProperty(value = "是否专属")
private Integer exclusive;
/**仓库存储规则*/
@Excel(name = "仓库存储规则", width = 15, dicCode = "goods_category")
@Dict(dicCode = "goods_category")
@ApiModelProperty(value = "仓库存储规则")
private java.lang.String type;
/**地址*/
@Excel(name = "地址", width = 15)
@ApiModelProperty(value = "地址")
private String address;
/**管理员*/
@Excel(name = "管理员", width = 15, dictTable = "sys_user", dicText = "realname", dicCode = "id")
@Dict(dictTable = "sys_user", dicText = "realname", dicCode = "id")
@ApiModelProperty(value = "管理员")
private String userId;
/**管理员*/
@Excel(name = "管理员", width = 15)
@ApiModelProperty(value = "管理员")
private String username;
/**库存预定*/
@Excel(name = "库存预定", width = 15, dicCode = "yn")
@Dict(dicCode = "yn")
@ApiModelProperty(value = "库存预定")
private String state;
}

@ -0,0 +1,19 @@
package org.jeecg.modules.demo.starehouse.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.demo.starehouse.entity.Starehouse;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description: 仓库管理
* @Author: jeecg-boot
* @Date: 2023-01-06
* @Version: V1.0
*/
public interface StarehouseMapper extends BaseMapper<Starehouse> {
}

@ -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=".starehouse.mapper.StarehouseMapper">
</mapper>

@ -0,0 +1,16 @@
package org.jeecg.modules.demo.starehouse.service;
import org.jeecg.modules.demo.starehouse.entity.Starehouse;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* @Description: 仓库管理
* @Author: jeecg-boot
* @Date: 2023-01-06
* @Version: V1.0
*/
public interface IStarehouseService extends IService<Starehouse> {
}

@ -0,0 +1,21 @@
package org.jeecg.modules.demo.starehouse.service.impl;
import org.jeecg.modules.demo.starehouse.entity.Starehouse;
import org.jeecg.modules.demo.starehouse.mapper.StarehouseMapper;
import org.jeecg.modules.demo.starehouse.service.IStarehouseService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
/**
* @Description: 仓库管理
* @Author: jeecg-boot
* @Date: 2023-01-06
* @Version: V1.0
*/
@Service
public class StarehouseServiceImpl extends ServiceImpl<StarehouseMapper, Starehouse> implements IStarehouseService {
}

@ -44,14 +44,14 @@ public class ZyStyleAccessories implements Serializable {
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private java.util.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;
// /**更新人*/
// @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;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private java.lang.String sysOrgCode;

@ -51,9 +51,9 @@ public class ZyMaker implements Serializable {
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;
// /**所属部门*/
// @ApiModelProperty(value = "所属部门")
// private String sysOrgCode;
/**制单编号*/
@Excel(name = "制单编号", width = 15)
@ApiModelProperty(value = "制单编号")

@ -1,22 +1,20 @@
package org.jeecg.modules.product.productModule.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.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* @Description: 工单管理下面的产品模块
@ -44,17 +42,17 @@ public class ProductModule implements Serializable {
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;
// /**更新人*/
// @ApiModelProperty(value = "更新人")
// private String updateBy;
// /**更新日期*/
// @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
// @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
// @ApiModelProperty(value = "更新日期")
// private Date updateTime;
// /**所属部门*/
// @ApiModelProperty(value = "所属部门")
// private String sysOrgCode;
/**产品id*/
@Excel(name = "产品id", width = 15)
@ApiModelProperty(value = "产品id")

@ -4,7 +4,6 @@ package org.jeecg.modules.productplan.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.metadata.PageList;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@ -19,7 +18,6 @@ import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.productplan.entity.ZyPlanProcess;
import org.jeecg.modules.productplan.entity.vo.ProcessDataVo;
import org.jeecg.modules.productplan.service.IZyPlanProcessService;
import org.jeecg.modules.team.entity.GroupxMember;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;
@ -28,7 +26,9 @@ import org.springframework.web.servlet.ModelAndView;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.*;
import java.util.Arrays;
import java.util.LinkedList;
import java.util.List;
/**
* @Description: 生产计划工序
@ -156,12 +156,15 @@ public class ZyPlanProcessController extends JeecgController<ZyPlanProcess, IZyP
return Result.OK("添加成功!");
}
// @AutoLog(value = "生产计划工序-添加")
@ApiOperation(value = "计划工序管理-批量添加工序、工位、设备", notes = "计划工序管理-批量添加工序、工位、设备")
@PostMapping(value = "/addProcessBatch")
public Result<?> addProcessBatch(@RequestBody List<ZyPlanProcess> zyPlanProcessList) {
if (!ObjectUtils.isEmpty(zyPlanProcessList)) {
zyPlanProcessService.remove(new LambdaQueryWrapper<ZyPlanProcess>()
.eq(ZyPlanProcess::getPlanId, zyPlanProcessList.get(0).getPlanId()));
zyPlanProcessService.saveBatch(zyPlanProcessList);
zyPlanProcessService.saveBatch(zyPlanProcessList);
}
return Result.OK("添加成功!");
}

@ -3,9 +3,8 @@ package org.jeecg.modules.productplan.entity.vo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecg.modules.team.entity.GroupxMember;
import org.jeecg.modules.team.entity.Station;
import org.jeecg.modules.team.vo.StationVo;
import java.io.Serializable;
import java.util.List;
@ -21,6 +20,8 @@ public class ProcessDataVo implements Serializable {
//工单id
private String workOrderId;
private String planId;
//产品id
private String productId;
private String productName;
@ -31,13 +32,13 @@ public class ProcessDataVo implements Serializable {
private String departName;
//工位
private List<Station> stationList;
private List<StationVo> stationList;
//班组成员列表
private List<GroupxMember> groupMemberList;
//产品工序id
// @Dict(dictTable ="zy_process",dicText = "process_name",dicCode = "id")
private String productProcessId;
private String processId;
private String processName;
}

@ -19,6 +19,7 @@ import org.jeecg.modules.team.entity.GroupxMember;
import org.jeecg.modules.team.entity.Station;
import org.jeecg.modules.team.service.IGroupxMemberService;
import org.jeecg.modules.team.service.IStationService;
import org.jeecg.modules.team.vo.StationVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.ObjectUtils;
@ -69,16 +70,29 @@ public class ZyPlanProcessServiceImpl extends ServiceImpl<ZyPlanProcessMapper, Z
if (!ObjectUtils.isEmpty(productProcessesList)) {
SysDepart depart = iSysDepartService.getById(departId);
List<Station> stationList = iStationService.list(new LambdaQueryWrapper<Station>().eq(Station::getDepartId, departId));
List<StationVo> stationVoList = new LinkedList<>();
if (!ObjectUtils.isEmpty(stationList)) {
stationList.forEach(en -> {
StationVo stationVo = new StationVo();
stationVo.setId(en.getId());
stationVo.setValue(en.getId());
stationVo.setText(en.getStationName());
stationVo.setTitle(en.getStationName());
stationVoList.add(stationVo);
});
}
productProcessesList.forEach(e -> {
ProcessDataVo vo = new ProcessDataVo();
vo.setProductProcessId(e.getProcessId());
vo.setPlanId(planId);
vo.setProcessId(e.getProcessId());
vo.setProcessName(iZyProcessService.getById(e.getProcessId()).getProcessName());
vo.setProductId(e.getProductId());
vo.setProductName("产品名称");
vo.setWorkOrderId(productCode);
vo.setDepartId(departId);
vo.setDepartName(depart.getDepartName());
vo.setStationList(stationList);
vo.setStationList(stationVoList);
result.add(vo);
});
}
@ -106,8 +120,8 @@ public class ZyPlanProcessServiceImpl extends ServiceImpl<ZyPlanProcessMapper, Z
List<GroupxMember> groupxMemberList = iGroupxMemberService.list(new LambdaQueryWrapper<GroupxMember>().eq(GroupxMember::getGroupxId, zyProductPlan.getTeamId()));
productProcessesList.forEach(e -> {
ProcessDataVo vo = new ProcessDataVo();
// vo.setId()
vo.setProductProcessId(e.getProcessId());
vo.setPlanId(planId);
vo.setProcessId(e.getProcessId());
vo.setProcessName(iZyProcessService.getById(e.getProcessId()).getProcessName());
vo.setProductId(e.getProductId());
// vo.setProductName("产品名称")

@ -20,6 +20,7 @@ import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.aspect.annotation.PermissionData;
import org.jeecg.common.constant.CommonConstant;
import org.jeecg.common.exception.JeecgBootException;
import org.jeecg.common.system.api.ISysBaseAPI;
import org.jeecg.modules.base.service.BaseCommonService;
import org.jeecg.common.system.query.QueryGenerator;
@ -34,6 +35,10 @@ import org.jeecg.modules.system.model.SysUserSysDepartModel;
import org.jeecg.modules.system.service.*;
import org.jeecg.modules.system.vo.SysDepartUsersVO;
import org.jeecg.modules.system.vo.SysUserRoleVO;
import org.jeecg.modules.team.entity.Groupx;
import org.jeecg.modules.team.entity.Station;
import org.jeecg.modules.team.service.IGroupxService;
import org.jeecg.modules.team.service.IStationService;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
@ -41,6 +46,7 @@ import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
@ -95,6 +101,9 @@ public class SysUserController {
@Autowired
private ICollectTypeService collectTypeService;
@Autowired
private IGroupxService iGroupxService;
@Value("${jeecg.path.upload}")
private String upLoadPath;
@ -149,30 +158,19 @@ public class SysUserController {
*/
@RequestMapping(value = "/listByDepartId", method = RequestMethod.GET)
public Result<IPage<SysUser>> listByDepartId(SysUser user,
@RequestParam(name = "departId") String departId,
@RequestParam(name = "groupId") String groupId,
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
HttpServletRequest req) {
Result<IPage<SysUser>> result = new Result<IPage<SysUser>>();
// QueryWrapper<SysUser> queryWrapper = QueryGenerator.initQueryWrapper(user, req.getParameterMap());
// queryWrapper.ne("username", "_reserve_user_external");
Page<SysUser> page = new Page<SysUser>(pageNo, pageSize);
// IPage<SysUser> pageList = sysUserService.page(page, queryWrapper);
IPage<SysUser> pageList = sysUserService.getUserByDepId(page, departId, "");
//批量查询用户的所属部门
//step.1 先拿到全部的 useids
//step.2 通过 useids,一次性查询用户的所属部门名字
// List<String> userIds = pageList.getRecords().stream().map(SysUser::getId).collect(Collectors.toList());
// if (userIds != null && userIds.size() > 0) {
// Map<String, String> useDepNames = sysUserService.getDepNamesByUserIds(userIds);
// pageList.getRecords().forEach(item -> {
// item.setOrgCodeTxt(useDepNames.get(item.getId()));
// });
// }
Groupx group = iGroupxService.getById(groupId);
if (ObjectUtils.isEmpty(group)) throw new JeecgBootException(groupId + "不存在");
IPage<SysUser> pageList = sysUserService.getUserByDepId(page, group.getDepartId(), "");
result.setSuccess(true);
result.setResult(pageList);
// log.info(pageList.toString());
return result;
}

@ -11,11 +11,14 @@ import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.system.entity.SysUser;
import org.jeecg.modules.system.service.ISysUserService;
import org.jeecg.modules.team.entity.GroupxMember;
import org.jeecg.modules.team.entity.GroupxMember;
import org.jeecg.modules.team.service.IGroupxMemberService;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
@ -39,6 +42,9 @@ public class GroupxMemberController extends JeecgController<GroupxMember, IGroup
@Autowired
private IGroupxMemberService groupxMemberService;
@Autowired
private ISysUserService iSysUserService;
/**
* 分页列表查询
*
@ -55,6 +61,16 @@ public class GroupxMemberController extends JeecgController<GroupxMember, IGroup
QueryWrapper<GroupxMember> queryWrapper = QueryGenerator.initQueryWrapper(groupxMember, req.getParameterMap());
Page<GroupxMember> page = new Page<GroupxMember>(pageNo, pageSize);
IPage<GroupxMember> pageList = groupxMemberService.page(page, queryWrapper);
List<GroupxMember> records = pageList.getRecords();
if (!ObjectUtils.isEmpty(records)) {
records.forEach(e -> {
SysUser sysUser = iSysUserService.getById(e.getUserId());
if (!ObjectUtils.isEmpty(sysUser)) {
e.setUserId(sysUser.getRealname());
e.setWorkNo(sysUser.getWorkNo());
}
});
}
return Result.OK(pageList);
}

@ -7,12 +7,10 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.activiti.entity.ActBusiness;
import org.jeecg.modules.system.entity.SysDepart;
import org.jeecg.modules.system.service.ISysDepartService;
import org.jeecg.modules.team.entity.Station;
@ -28,9 +26,11 @@ import org.springframework.web.servlet.ModelAndView;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.*;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* @Description: 车间工位管理
@ -197,4 +197,19 @@ public class StationController extends JeecgController<Station, IStationService>
return super.importExcel(request, response, Station.class);
}
@ApiOperation(value = "排序", notes = "排序")
@GetMapping(value = "/up")
public Result<?> up(@RequestParam(name = "id", required = true) String id) {
stationService.up(id);
return Result.OK();
}
@AutoLog(value = "排序")
@ApiOperation(value = "排序", notes = "排序")
@GetMapping(value = "/down")
public Result<?> down(@RequestParam(name = "id", required = true) String id) {
stationService.down(id);
return Result.OK();
}
}

@ -1,5 +1,6 @@
package org.jeecg.modules.team.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@ -11,11 +12,15 @@ import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.common.system.query.QueryGenerator;
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.StationMachine;
import org.jeecg.modules.team.service.IStationMachineService;
import org.jeecg.modules.team.vo.StationMachineVo;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
@ -39,6 +44,9 @@ public class StationMachineController extends JeecgController<StationMachine, IS
@Autowired
private IStationMachineService stationMachineService;
@Autowired
private IZyDeviceService iZyDeviceService;
/**
* 分页列表查询
*
@ -61,6 +69,26 @@ public class StationMachineController extends JeecgController<StationMachine, IS
return Result.OK(pageList);
}
@ApiOperation(value = "工序工具管理-分页列表查询", notes = "工序工具管理-分页列表查询")
@GetMapping(value = "/list2")
public Result<?> list2(StationMachine stationMachine,
HttpServletRequest req) {
List<StationMachineVo> voList = new LinkedList<>();
List<StationMachine> toolList = stationMachineService.list(new LambdaQueryWrapper<StationMachine>().eq(StationMachine::getStationId, stationMachine.getStationId()));
if (!ObjectUtils.isEmpty(toolList)) {
toolList.forEach(en -> {
StationMachineVo stationMachineVo = new StationMachineVo();
stationMachineVo.setId(en.getMachineId());
stationMachineVo.setValue(en.getMachineId());
ZyDevice zyDevice = iZyDeviceService.getById(en.getMachineId());
stationMachineVo.setText(zyDevice.getName());
stationMachineVo.setTitle(zyDevice.getName());
voList.add(stationMachineVo);
});
}
return Result.OK(voList);
}
/**
* 添加
*

@ -1,5 +1,6 @@
package org.jeecg.modules.team.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@ -12,10 +13,16 @@ import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
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.service.IZyDeviceService;
import org.jeecg.modules.team.entity.StationTool;
import org.jeecg.modules.team.service.IStationToolService;
import org.jeecg.modules.team.vo.StationToolVo;
import org.jeecg.modules.team.vo.StationVo;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
@ -40,6 +47,9 @@ public class StationToolController extends JeecgController<StationTool, IStation
@Autowired
private IStationToolService stationToolService;
@Autowired
private IZyToolService iZyToolService;
/**
* 分页列表查询
*
@ -62,6 +72,31 @@ public class StationToolController extends JeecgController<StationTool, IStation
return Result.OK(pageList);
}
@ApiOperation(value = "工序工具管理-分页列表查询", notes = "工序工具管理-分页列表查询")
@GetMapping(value = "/list2")
public Result<?> list2(StationTool stationTool,
// @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
// @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
HttpServletRequest req) {
// QueryWrapper<StationTool> queryWrapper = QueryGenerator.initQueryWrapper(stationTool, req.getParameterMap());
// Page<StationTool> page = new Page<StationTool>(pageNo, pageSize);
// IPage<StationTool> pageList = stationToolService.page(page, queryWrapper);
List<StationToolVo> voList = new LinkedList<>();
List<StationTool> toolList = stationToolService.list(new LambdaQueryWrapper<StationTool>().eq(StationTool::getStationId, stationTool.getStationId()));
if(!ObjectUtils.isEmpty(toolList)){
toolList.forEach(en->{
StationToolVo stationVo = new StationToolVo();
stationVo.setId(en.getToolsId());
stationVo.setValue(en.getToolsId());
ZyTool zyTool = iZyToolService.getById(en.getToolsId());
stationVo.setText(zyTool.getName());
stationVo.setTitle(zyTool.getName());
voList.add(stationVo);
});
}
return Result.OK(voList);
}
/**
* 添加
*

@ -46,11 +46,10 @@ public class GroupxMember {
*/
@Excel(name = "用户id FK 用户表", width = 15)
@ApiModelProperty(value = "用户id FK 用户表")
@Dict(dictTable = "sys_user", dicText = "realname", dicCode = "id")
// @Dict(dictTable = "sys_user", dicText = "realname", dicCode = "id")
private String userId;
@TableField(exist = false)
@Dict(dictTable = "sys_user", dicText = "work_no", dicCode = "id")
private String workNo;
/**
* 加入时间

@ -87,7 +87,7 @@ public class Station {
@TableField(exist = false)
@ApiModelProperty(value = "设备id列表")
@Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@Dict(dictTable = "zy_device", dicText = "name", dicCode = "id")
private String machineIds;
/**
* 工具id列表

@ -45,7 +45,7 @@ public class StationMachine {
*/
@Excel(name = "设备id,uuid,FK,设备表", width = 15)
@ApiModelProperty(value = "设备id,uuid,FK,设备表")
@Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@Dict(dictTable = "zy_device", dicText = "name", dicCode = "id")
private String machineId;
/**
* 创建日期

@ -13,4 +13,8 @@ import org.jeecg.modules.team.entity.Station;
public interface IStationService extends IService<Station> {
int queryIsCanDelete(Station station);
void up(String id);
void down(String id);
}

@ -3,6 +3,7 @@ package org.jeecg.modules.team.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.common.exception.JeecgBootException;
import org.jeecg.modules.system.entity.SysDepart;
import org.jeecg.modules.team.entity.Station;
import org.jeecg.modules.team.entity.StationMachine;
@ -13,6 +14,7 @@ import org.jeecg.modules.team.service.IStationService;
import org.jeecg.modules.team.service.IStationToolService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.ObjectUtils;
/**
* @Description: 车间工位管理
@ -36,4 +38,30 @@ public class StationServiceImpl extends ServiceImpl<StationMapper, Station> impl
}
return count;
}
@Override
public void up(String id) {
Station entity = this.getById(id);
if (ObjectUtils.isEmpty(entity)) {
throw new JeecgBootException(id + "不存在");
}
Station station = new Station();
station.setId(id);
station.setStationNum(entity.getStationNum() + 1);
this.updateById(station);
}
@Override
public void down(String id) {
Station entity = this.getById(id);
if (ObjectUtils.isEmpty(entity)) {
throw new JeecgBootException(id + "不存在");
}
if (entity.getStationNum() > 1) {
Station station = new Station();
station.setId(id);
station.setStationNum(entity.getStationNum() - 1);
this.updateById(station);
}
}
}

@ -0,0 +1,16 @@
package org.jeecg.modules.team.vo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class StationMachineVo {
private String id;
private String value;
private String text;
private String title;
}

@ -0,0 +1,33 @@
package org.jeecg.modules.team.vo;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
/**
* @Description: 工序工具管理
* @Author: jeecg-boot
* @Date: 2022-12-06
* @Version: V1.0
*/
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class StationToolVo {
private String id;
private String value;
private String text;
private String title;
}

@ -0,0 +1,16 @@
package org.jeecg.modules.team.vo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class StationVo {
private String id;
private String value;
private String text;
private String title;
}

@ -33,25 +33,25 @@ public class ZyProcessModular implements Serializable {
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private java.lang.String id;
/**创建人*/
@ApiModelProperty(value = "创建人")
private java.lang.String createBy;
// /**创建人*/
// @ApiModelProperty(value = "创建人")
// private java.lang.String createBy;
/**创建日期*/
@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 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;
/**所属部门*/
@ApiModelProperty(value = "所属部门")
private java.lang.String sysOrgCode;
// /**更新人*/
// @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;
// /**所属部门*/
// @ApiModelProperty(value = "所属部门")
// private java.lang.String sysOrgCode;
/**模块ID*/
@Excel(name = "模块ID", width = 15)
@ApiModelProperty(value = "模块ID")

@ -2,6 +2,7 @@ package org.jeecg.modules.zystylefabric.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
@ -13,6 +14,7 @@ import org.jeecg.modules.zystylefabric.entity.ZyStyleFabric;
* @Date: 2022-09-15
* @Version: V1.0
*/
@Mapper
public interface ZyStyleFabricMapper extends BaseMapper<ZyStyleFabric> {

@ -1,46 +1,29 @@
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 io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.jeecg.modules.demo.zyaccessories.entity.ZyStyleAccDetailVO;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.modules.zystylefabric.mapper.ZyStyleFabricMapper;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModel;
import org.jeecg.modules.zystylemodel.entity.ZyStyleModelDetailsVO;
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;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Map;
/**
* @Description: zy_style_model
@ -55,6 +38,8 @@ import org.jeecg.common.aspect.annotation.AutoLog;
public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZyStyleModelService> {
@Autowired
private IZyStyleModelService zyStyleModelService;
@Autowired
private ZyStyleFabricMapper zyStyleFabricMapper;
/**
* 分页列表查询
@ -65,7 +50,7 @@ public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZySty
* @param req
* @return
*/
//@AutoLog(value = "zy_style_model-分页列表查询")
@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,
@ -73,15 +58,18 @@ public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZySty
@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);
List<ZyStyleModel> records = pageList.getRecords();
for (ZyStyleModel zy : records){
zy.setStyleId(zyStyleFabricMapper.getStyleNameByStyleId(zy.getStyleId()));
}
return Result.OK(pageList);
}
/**
* 添加
* 添加
*
* @param zyStyleModel
* @return
@ -91,8 +79,8 @@ public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZySty
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:add")
@PostMapping(value = "/add")
public Result<String> add(@RequestBody ZyStyleModel zyStyleModel) {
//System.err.println("zyStyleModel add: "+zyStyleModel+ LocalDateTime.now());
zyStyleModel.setId(null);
System.out.println("zyStyleModel add"+zyStyleModel);
zyStyleModelService.save(zyStyleModel);
return Result.OK("添加成功!");
}
@ -108,6 +96,7 @@ public class ZyStyleModelController extends JeecgController<ZyStyleModel, IZySty
//@RequiresPermissions("org.jeecg.modules.demo:zy_style_model:edit")
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
public Result<String> edit(@RequestBody ZyStyleModel zyStyleModel) {
//System.err.println("zyStyleModel edit: "+zyStyleModel+ LocalDateTime.now());
zyStyleModelService.updateById(zyStyleModel);
return Result.OK("编辑成功!");
}

@ -38,7 +38,7 @@ public class ZyStyleModel implements Serializable {
private java.lang.String id;
/**款式id*/
@Excel(name = "款式id", width = 15)
@Dict(dictTable = "zy_cloths_style", dicText = "style_names", dicCode = "id")
//@Dict(dictTable = "zy_cloths_style", dicText = "style_names", dicCode = "id")
@ApiModelProperty(value = "款式id")
private java.lang.String styleId;
/**是否默认尺码*/
@ -107,8 +107,8 @@ public class ZyStyleModel implements Serializable {
@ApiModelProperty(value = "下摆")
private java.lang.Float hem;
/**创建时间*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern="yyyy-MM-dd")
@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 createTime;

@ -66,11 +66,11 @@ public class ZyStyleModelServiceImpl extends ServiceImpl<ZyStyleModelMapper, ZyS
zy.setSize(zy.getSize()+36);
}
//型
if (!ObjectUtils.isEmpty(zy.getSize())){
if (!ObjectUtils.isEmpty(zy.getAnumbers())){
zy.setAnumbers(aHandleNumberA(zy.getAnumbers()));
}
//号
if (!ObjectUtils.isEmpty(zy.getSize())){
if (!ObjectUtils.isEmpty(zy.getBnumbers())){
zy.setBnumbers(bHandleNumberB(zy.getBnumbers()));
}

Loading…
Cancel
Save