Commit 1eb1379f8d212ecc9f145125ee67e1db4803398f

Authored by 谭毅彬
2 parents 63183767 6fb44f72

Merge branch 'develop' of http://www.huahengrobot.com:90/wms/wms4.git into develop

ant-design-vue-jeecg/src/api/api.js
... ... @@ -104,7 +104,7 @@ export const getZoneList = (params) => getAction('/config/zone/getZoneList', par
104 104 //获取容器类型列表
105 105 export const getContainerTypeList = (params) => getAction('/config/containerType/getContainerTypeList', params);
106 106 //获取库位类型列表
107   -export const getLocationTypeList = (params) => getAction('/config/locationType/getLocationTypeList', params);
  107 +export const getLocationTypeList = (params) => getAction('/config/zone/getZoneList', params);
108 108 //获取库位类高度列表
109 109 export const getLocationHighList = (params) => postAction('/config/locationHigh/getLocationHighList', params);
110 110 //获取货主列表
... ... @@ -177,6 +177,8 @@ export const getPrintContainer = (params) => postAction('/config/container/getPr
177 177 export const getPrintLocation = (params) => postAction('/config/location/getPrintContent?ids=' + params, params);
178 178 //获取物料打印数据
179 179 export const getMaterialLocation = (params) => postAction('/config/material/getPrintContent?ids=' + params, params);
  180 +//获取物料类别列表
  181 +export const getMaterialTypeList = (params) => getAction('/config/materialType/getMaterialTypeList', params);
180 182 //根据出库单头ID查询出库单详情
181 183 export const listShipmentByShipmentDetailId = (params) => postAction('/shipment/shipmentCombination/listShipmentByShipmentDetailId', params);
182 184 //根据出库单详情选取库存
... ...
ant-design-vue-jeecg/src/views/system/config/BomDetailList.vue
... ... @@ -129,11 +129,11 @@ export default {
129 129 return parseInt(index) + 1;
130 130 }
131 131 },
132   - {
133   - title: '货主',
134   - align: "center",
135   - dataIndex: 'companyCode'
136   - },
  132 + // {
  133 + // title: '货主',
  134 + // align: "center",
  135 + // dataIndex: 'companyCode'
  136 + // },
137 137 {
138 138 title: '物料编码',
139 139 align: "center",
... ...
ant-design-vue-jeecg/src/views/system/config/BomHeaderList.vue
... ... @@ -62,6 +62,12 @@
62 62 :customRow="clickThenSelect"
63 63 @change="handleTableChange">
64 64  
  65 + <span slot="companyCode" slot-scope="companyCode">
  66 + <a-tag :key="companyCode" color=blue>
  67 + {{ solutionCompany(companyCode) }}
  68 + </a-tag>
  69 + </span>
  70 +
65 71 <template slot="htmlSlot" slot-scope="text">
66 72 <div v-html="text"></div>
67 73 </template>
... ... @@ -120,6 +126,7 @@ import {getAction} from &#39;@/api/manage&#39;
120 126 import BomDetailList from './BomDetailList'
121 127 import {initDictOptions, filterMultiDictText} from '@/components/dict/JDictSelectUtil'
122 128 import '@/assets/less/TableExpand.less'
  129 +import { getCompanyList, getZoneList } from '@api/api'
123 130  
124 131 export default {
125 132 name: "BomHeaderList",
... ... @@ -130,13 +137,16 @@ export default {
130 137 },
131 138 data() {
132 139 return {
  140 + companyList: [],
133 141 description: 'bom主表管理页面',
134 142 // 表头
135 143 columns: [
136 144 {
137   - title: '货主',
138   - align: "center",
139   - dataIndex: 'companyCode'
  145 + title:'货主',
  146 + align:"center",
  147 + dataIndex: 'companyCode',
  148 + key: 'companyCode',
  149 + scopedSlots: {customRender: 'companyCode'}
140 150 },
141 151 {
142 152 title: '物料编码',
... ... @@ -219,6 +229,7 @@ export default {
219 229 }
220 230 },
221 231 created() {
  232 + this.loadFrom();
222 233 this.getSuperFieldList();
223 234 },
224 235 computed: {
... ... @@ -248,6 +259,13 @@ export default {
248 259 this.selectedRowKeys = selectedRowKeys;
249 260 this.selectionRows = selectionRows;
250 261 },
  262 + loadFrom() {
  263 + getCompanyList().then((res) => {
  264 + if (res.success) {
  265 + this.companyList = res.result
  266 + }
  267 + });
  268 + },
251 269 loadData(arg) {
252 270 if (!this.url.list) {
253 271 this.$message.error("请设置url.list属性!")
... ... @@ -271,6 +289,17 @@ export default {
271 289 this.loading = false;
272 290 })
273 291 },
  292 + solutionCompany(value) {
  293 + debugger
  294 + var actions = []
  295 + Object.keys(this.companyList).some((key) => {
  296 + if (this.companyList[key].code == ('' + value)) {
  297 + actions.push(this.companyList[key].name)
  298 + return true
  299 + }
  300 + })
  301 + return actions.join('')
  302 + },
274 303 getSuperFieldList() {
275 304 let fieldList = [];
276 305 fieldList.push({type: 'string', value: 'companyCode', text: '货主', dictCode: ''})
... ...
ant-design-vue-jeecg/src/views/system/config/modules/MaterialForm.vue
... ... @@ -30,7 +30,16 @@
30 30 </a-col>
31 31 <a-col :span="24">
32 32 <a-form-model-item label="类别" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="type">
33   - <a-input v-model="model.type" placeholder="请输入类别"></a-input>
  33 + <a-select
  34 + show-search
  35 + placeholder="请输入类别"
  36 + option-filter-prop="children"
  37 + v-model="model.type">
  38 + <a-select-option v-for="item in materialTypeList" :key="item.name" :value="item.code">{{
  39 + item.name
  40 + }}
  41 + </a-select-option>
  42 + </a-select>
34 43 </a-form-model-item>
35 44 </a-col>
36 45 <a-col :span="24">
... ... @@ -68,6 +77,7 @@
68 77  
69 78 import {httpAction, getAction} from '@/api/manage'
70 79 import {validateDuplicateValue} from '@/utils/util'
  80 +import {getMaterialTypeList} from '@/api/api'
71 81  
72 82 export default {
73 83 name: 'MaterialForm',
... ... @@ -82,6 +92,7 @@ export default {
82 92 },
83 93 data() {
84 94 return {
  95 + materialTypeList: [],
85 96 model: {},
86 97 labelCol: {
87 98 xs: {span: 24},
... ... @@ -121,6 +132,7 @@ export default {
121 132 created() {
122 133 //备份model原始值
123 134 this.modelDefault = JSON.parse(JSON.stringify(this.model));
  135 + this.loadFrom();
124 136 },
125 137 methods: {
126 138 add() {
... ... @@ -132,6 +144,13 @@ export default {
132 144 this.model = Object.assign({}, record);
133 145 this.visible = true;
134 146 },
  147 + loadFrom() {
  148 + getMaterialTypeList().then((res) => {
  149 + if (res.success) {
  150 + this.materialTypeList = res.result
  151 + }
  152 + });
  153 + },
135 154 submitForm() {
136 155 const that = this;
137 156 // 触发表单验证
... ...
ant-design-vue-jeecg/src/views/system/inventory/InventoryMaterialSummaryList.vue
... ... @@ -78,6 +78,12 @@
78 78 </a-tag>
79 79 </span>
80 80  
  81 + <span slot="zoneCode" slot-scope="zoneCode">
  82 + <a-tag :key="zoneCode" color=blue>
  83 + {{ solutionZoneCode(zoneCode) }}
  84 + </a-tag>
  85 + </span>
  86 +
81 87 <template slot="htmlSlot" slot-scope="text">
82 88 <div v-html="text"></div>
83 89 </template>
... ... @@ -116,7 +122,7 @@
116 122 import '@/assets/less/TableExpand.less'
117 123 import { mixinDevice } from '@/utils/mixin'
118 124 import { JeecgListMixin } from '@/mixins/JeecgListMixin'
119   - import {getCompanyList} from '@/api/api'
  125 + import { getCompanyList, getZoneList } from '@/api/api'
120 126 import InventoryDetailList from './InventoryDetailList'
121 127 import InventoryDetailSubTable from './subTables/InventoryDetailSubTable'
122 128  
... ... @@ -129,6 +135,7 @@
129 135 },
130 136 data () {
131 137 return {
  138 + zoneList: [],
132 139 selectedMainId: '',
133 140 description: '物料汇总主表管理页面',
134 141 // 表头
... ... @@ -145,9 +152,11 @@
145 152 // dataIndex: 'warehouseCode'
146 153 // },
147 154 {
148   - title:'库区',
149   - align:"center",
150   - dataIndex: 'zoneCode'
  155 + title: '库区',
  156 + align: "center",
  157 + dataIndex: 'zoneCode',
  158 + key: 'zoneCode',
  159 + scopedSlots: {customRender: 'zoneCode'}
151 160 },
152 161 {
153 162 title:'货主',
... ... @@ -202,7 +211,22 @@
202 211 },
203 212 },
204 213 methods: {
  214 + solutionZoneCode(value) {
  215 + var actions = []
  216 + Object.keys(this.zoneList).some((key) => {
  217 + if (this.zoneList[key].code == ('' + value)) {
  218 + actions.push(this.zoneList[key].name)
  219 + return true
  220 + }
  221 + })
  222 + return actions.join('')
  223 + },
205 224 loadFrom() {
  225 + getZoneList().then((res) => {
  226 + if (res.success) {
  227 + this.zoneList = res.result
  228 + }
  229 + });
206 230 getCompanyList().then((res) => {
207 231 if (res.success) {
208 232 this.companyList = res.result
... ...
ant-design-vue-jeecg/src/views/system/monitor/locationStatus.vue
... ... @@ -14,7 +14,7 @@
14 14 @change="refresh"
15 15 style="width: 200px">
16 16 <a-select-option selected="0" id="zoneCode" v-for="item in locationTypeList" :key="item.name"
17   - :value="item.code">{{ item.name }}
  17 + :value="item.locationTypeCode">{{ item.name }}
18 18 </a-select-option>
19 19 </a-select>
20 20 </li>
... ... @@ -189,7 +189,7 @@ export default {
189 189 if (res.success) {
190 190 this.locationTypeList = res.result;
191 191 if (this.locationTypeList.length > 0) {
192   - this.zoneCode = this.locationTypeList[0].code;
  192 + this.zoneCode = this.locationTypeList[0].locationTypeCode;
193 193 let _this = this;
194 194 this.resetAjax(this.zoneCode);
195 195 }
... ... @@ -228,7 +228,6 @@ export default {
228 228 $("#editable-num").append("<option value='" + i + "'>" + i + "</option>")
229 229 }
230 230 }
231   - alert($("#editable-select").val())
232 231  
233 232 let type = $("#zoneCode").val();
234 233 this.resetAjax(this.zoneCode);
... ...
ant-design-vue-jeecg/src/views/system/task/TaskDetailList.vue
... ... @@ -47,6 +47,12 @@
47 47 :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
48 48 @change="handleTableChange">
49 49  
  50 + <span slot='companyCode' slot-scope='companyCode'>
  51 + <a-tag :key='companyCode' color='blue'>
  52 + {{ solutionCompany(companyCode) }}
  53 + </a-tag>
  54 + </span>
  55 +
50 56 <template slot="htmlSlot" slot-scope="text">
51 57 <div v-html="text"></div>
52 58 </template>
... ... @@ -91,6 +97,7 @@
91 97 import {JeecgListMixin} from '@/mixins/JeecgListMixin'
92 98 import TaskDetailModal from './modules/TaskDetailModal'
93 99 import AdjustmentDocModal from "../stocktaking/modules/AdjustmentDocModal";
  100 +import { getCompanyList } from '@api/api'
94 101  
95 102 export default {
96 103 name: "TaskDetailList",
... ... @@ -120,6 +127,7 @@ export default {
120 127 return {
121 128 description: '任务表管理页面',
122 129 disableMixinCreated: true,
  130 + companyList: [],
123 131 // 表头
124 132 columns: [
125 133 {
... ... @@ -130,7 +138,9 @@ export default {
130 138 {
131 139 title: '货主',
132 140 align: "center",
133   - dataIndex: 'companyCode'
  141 + dataIndex: 'companyCode',
  142 + key: 'companyCode',
  143 + scopedSlots: {customRender: 'companyCode'}
134 144 },
135 145 {
136 146 title: '物料编码',
... ... @@ -212,6 +222,7 @@ export default {
212 222 }
213 223 },
214 224 created() {
  225 + this.loadFrom();
215 226 },
216 227 computed: {
217 228 importExcelUrl() {
... ... @@ -219,6 +230,23 @@ export default {
219 230 }
220 231 },
221 232 methods: {
  233 + loadFrom() {
  234 + getCompanyList().then((res) => {
  235 + if (res.success) {
  236 + this.companyList = res.result
  237 + }
  238 + });
  239 + },
  240 + solutionCompany(value) {
  241 + var actions = []
  242 + Object.keys(this.companyList).some((key) => {
  243 + if (this.companyList[key].code == ('' + value)) {
  244 + actions.push(this.companyList[key].name)
  245 + return true
  246 + }
  247 + })
  248 + return actions.join('')
  249 + },
222 250 clearList() {
223 251 this.dataSource = []
224 252 this.selectedRowKeys = []
... ...
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/config/locationMonitor/controller/LocationMonitorController.java
... ... @@ -92,7 +92,7 @@ public class LocationMonitorController {
92 92 HuahengJwtUtil.setWarehouseCode(locationLambdaQueryWrapper, Location.class, req);
93 93 locationLambdaQueryWrapper.eq(StringUtils.isNotEmpty(row), Location::getRow, row).eq(StringUtils.isNotEmpty(line), Location::getIcolumn, line)
94 94 .eq(StringUtils.isNotEmpty(layer), Location::getLayer, layer).eq(StringUtils.isNotEmpty(grid), Location::getGrid, grid)
95   - .eq(StringUtils.isNotEmpty(type), Location::getZoneCode, type);
  95 + .eq(StringUtils.isNotEmpty(type), Location::getLocationTypeCode, type);
96 96 List<Location> locations = locationService.list(locationLambdaQueryWrapper);
97 97 List<Location> locationList = new ArrayList<>();
98 98  
... ...
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/config/materialType/controller/MaterialTypeController.java
... ... @@ -10,9 +10,12 @@ import java.net.URLDecoder;
10 10 import javax.servlet.http.HttpServletRequest;
11 11 import javax.servlet.http.HttpServletResponse;
12 12  
  13 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  14 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
13 15 import org.apache.shiro.authz.annotation.RequiresPermissions;
14 16 import org.jeecg.common.api.vo.Result;
15 17 import org.jeecg.common.system.query.QueryGenerator;
  18 +import org.jeecg.modules.wms.config.receiptType.entity.ReceiptType;
16 19 import org.jeecg.utils.HuahengJwtUtil;
17 20 import org.jeecg.common.util.oConvertUtils;
18 21  
... ... @@ -170,4 +173,16 @@ public class MaterialTypeController extends JeecgController&lt;MaterialType, IMater
170 173 return super.importExcel(request, response, MaterialType.class);
171 174 }
172 175  
  176 +
  177 + /**
  178 + * 获取物料类别列表
  179 + */
  180 + @RequestMapping(value = "/getMaterialTypeList")
  181 + public Result<?> getMaterialTypeList(HttpServletRequest request) {
  182 + LambdaQueryWrapper<MaterialType> LambdaQueryWrapper = Wrappers.lambdaQuery();
  183 + HuahengJwtUtil.setWarehouseCode(LambdaQueryWrapper, MaterialType.class, request);
  184 + List<MaterialType> materialTypes = materialTypeService.list(LambdaQueryWrapper);
  185 + return Result.OK(materialTypes);
  186 + }
  187 +
173 188 }
... ...