Commit 340410c45648a77c361b6f4b2cd500b6784defad
Merge branch 'develop' of http://172.16.29.40:8010/wms/wms2 into develop
Showing
31 changed files
with
594 additions
and
219 deletions
src/main/java/com/huaheng/pc/config/FilterConfigDetail/controller/FilterConfigDetailController.java
... | ... | @@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
5 | 5 | import com.baomidou.mybatisplus.core.metadata.IPage; |
6 | 6 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
7 | 7 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
8 | +import com.huaheng.common.exception.service.ServiceException; | |
8 | 9 | import com.huaheng.common.support.Convert; |
9 | 10 | import com.huaheng.common.utils.StringUtils; |
10 | 11 | import com.huaheng.common.utils.security.ShiroUtils; |
... | ... | @@ -17,6 +18,8 @@ import com.huaheng.framework.web.page.TableDataInfo; |
17 | 18 | import com.huaheng.framework.web.page.TableSupport; |
18 | 19 | import com.huaheng.pc.config.FilterConfigDetail.domain.FilterConfigDetail; |
19 | 20 | import com.huaheng.pc.config.FilterConfigDetail.service.FilterConfigDetailService; |
21 | +import com.huaheng.pc.config.FilterConfigHeader.domain.FilterConfigHeader; | |
22 | +import com.huaheng.pc.config.FilterConfigHeader.service.FilterConfigHeaderService; | |
20 | 23 | import io.swagger.annotations.Api; |
21 | 24 | import io.swagger.annotations.ApiOperation; |
22 | 25 | import io.swagger.annotations.ApiParam; |
... | ... | @@ -45,6 +48,8 @@ public class FilterConfigDetailController extends BaseController { |
45 | 48 | |
46 | 49 | @Autowired |
47 | 50 | private FilterConfigDetailService filterConfigDetailService; |
51 | + @Autowired | |
52 | + private FilterConfigHeaderService filterConfigHeaderService; | |
48 | 53 | |
49 | 54 | |
50 | 55 | @RequiresPermissions("config:filterConfigDetail:view") |
... | ... | @@ -112,6 +117,12 @@ public class FilterConfigDetailController extends BaseController { |
112 | 117 | @PostMapping("/add") |
113 | 118 | @ResponseBody |
114 | 119 | public AjaxResult addSave(FilterConfigDetail filterConfigDetail) { |
120 | + FilterConfigHeader configHeader = filterConfigHeaderService.getById(filterConfigDetail.getHeaderId()); | |
121 | + if(configHeader == null){ | |
122 | + throw new ServiceException("找不到主表"); | |
123 | + } | |
124 | + filterConfigDetail.setModuleType(configHeader.getModuleType()); | |
125 | + filterConfigDetail.setRecordType(configHeader.getRecordType()); | |
115 | 126 | filterConfigDetail.setWarehouseCode(ShiroUtils.getWarehouseCode()); |
116 | 127 | filterConfigDetail.setCreatedBy(ShiroUtils.getLoginName()); |
117 | 128 | filterConfigDetail.setLastUpdatedBy(ShiroUtils.getLoginName()); |
... | ... |
src/main/java/com/huaheng/pc/config/FilterConfigDetail/service/FilterConfigDetailService.java
... | ... | @@ -18,10 +18,10 @@ public class FilterConfigDetailService extends ServiceImpl<FilterConfigDetailMap |
18 | 18 | * 查询定位自定义sql,供前端页面选择使用 |
19 | 19 | * @return |
20 | 20 | */ |
21 | - public List<Map<String, Object>> queryFilterConfigDetail(String moduleType){ | |
21 | + public List<Map<String, Object>> queryFilterConfigDetail(String recordType){ | |
22 | 22 | LambdaQueryWrapper<FilterConfigDetail> lambdaQueryWrapper = Wrappers.lambdaQuery(); |
23 | 23 | lambdaQueryWrapper.select(FilterConfigDetail::getCode, FilterConfigDetail::getDescription) |
24 | - .eq(FilterConfigDetail::getModuleType,moduleType) | |
24 | + .eq(FilterConfigDetail::getRecordType, recordType) | |
25 | 25 | .eq(FilterConfigDetail::getWarehouseCode, ShiroUtils.getWarehouseCode()); |
26 | 26 | return this.listMaps(lambdaQueryWrapper); |
27 | 27 | } |
... | ... |
src/main/java/com/huaheng/pc/config/FilterConfigHeader/service/FilterConfigHeaderService.java
1 | 1 | package com.huaheng.pc.config.FilterConfigHeader.service; |
2 | 2 | |
3 | +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | |
4 | +import com.baomidou.mybatisplus.core.toolkit.Wrappers; | |
3 | 5 | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
6 | +import com.huaheng.common.utils.security.ShiroUtils; | |
4 | 7 | import com.huaheng.pc.config.FilterConfigHeader.domain.FilterConfigHeader; |
5 | 8 | import com.huaheng.pc.config.FilterConfigHeader.mapper.FilterConfigHeaderMapper; |
6 | 9 | import org.springframework.stereotype.Service; |
7 | 10 | |
8 | -@Service | |
11 | +import java.util.List; | |
12 | + | |
13 | +@Service("filterConfigHeaderService") | |
9 | 14 | public class FilterConfigHeaderService extends ServiceImpl<FilterConfigHeaderMapper, FilterConfigHeader> { |
10 | 15 | |
16 | + | |
17 | + //根据模块和类型查找具体规则 | |
18 | + public List<FilterConfigHeader> getFilterConfigHeaderService(String moduleType,String recordType){ | |
19 | + LambdaQueryWrapper<FilterConfigHeader> lam = Wrappers.lambdaQuery(); | |
20 | + lam.eq(FilterConfigHeader::getModuleType,moduleType) | |
21 | + .eq(FilterConfigHeader::getRecordType,recordType) | |
22 | + .eq(FilterConfigHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()); | |
23 | + return this.list(lam); | |
24 | + } | |
11 | 25 | } |
... | ... |
src/main/java/com/huaheng/pc/config/shipmentPreference/service/ShipmentPreferenceService.java
... | ... | @@ -2,8 +2,14 @@ package com.huaheng.pc.config.shipmentPreference.service; |
2 | 2 | |
3 | 3 | import com.baomidou.mybatisplus.extension.service.IService; |
4 | 4 | import com.huaheng.pc.config.shipmentPreference.domain.ShipmentPreference; |
5 | +import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader; | |
6 | + | |
7 | +import java.util.List; | |
5 | 8 | |
6 | 9 | public interface ShipmentPreferenceService extends IService<ShipmentPreference>{ |
7 | 10 | |
8 | 11 | |
12 | + //查看出库此操作是否符合出库首选项的出库流程 | |
13 | + List<ShipmentHeader> checkShipmentProcess(String ids, Integer code); | |
14 | + | |
9 | 15 | } |
... | ... |
src/main/java/com/huaheng/pc/config/shipmentPreference/service/ShipmentPreferenceServiceImpl.java
1 | 1 | package com.huaheng.pc.config.shipmentPreference.service; |
2 | 2 | |
3 | +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | |
4 | +import com.baomidou.mybatisplus.core.toolkit.Wrappers; | |
3 | 5 | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
6 | +import com.huaheng.common.exception.service.ServiceException; | |
7 | +import com.huaheng.common.support.Convert; | |
8 | +import com.huaheng.common.utils.StringUtils; | |
9 | +import com.huaheng.common.utils.security.ShiroUtils; | |
4 | 10 | import com.huaheng.pc.config.shipmentPreference.domain.ShipmentPreference; |
5 | 11 | import com.huaheng.pc.config.shipmentPreference.mapper.ShipmentPreferenceMapper; |
12 | +import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail; | |
13 | +import com.huaheng.pc.config.statusFlow.domain.StatusFlowHeader; | |
14 | +import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService; | |
15 | +import com.huaheng.pc.config.statusFlow.service.StatusFlowHeaderService; | |
16 | +import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader; | |
17 | +import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService; | |
18 | +import org.springframework.beans.factory.annotation.Autowired; | |
6 | 19 | import org.springframework.stereotype.Service; |
7 | 20 | |
21 | +import java.util.ArrayList; | |
22 | +import java.util.List; | |
23 | + | |
8 | 24 | @Service("shipmentPreference") |
9 | 25 | public class ShipmentPreferenceServiceImpl extends ServiceImpl<ShipmentPreferenceMapper, ShipmentPreference> implements ShipmentPreferenceService { |
10 | 26 | |
27 | + @Autowired | |
28 | + private ShipmentPreferenceService shipmentPreferenceService; | |
29 | + @Autowired | |
30 | + private StatusFlowHeaderService statusFlowHeaderService; | |
31 | + @Autowired | |
32 | + private StatusFlowDetailService statusFlowDetailService; | |
33 | + @Autowired | |
34 | + private ShipmentHeaderService shipmentHeaderService; | |
35 | + | |
36 | + | |
37 | + /** | |
38 | + * 1、找出出库首选项 | |
39 | + * 2、查看出库首选项的出库流程 | |
40 | + * 3、找到该状态流的出库流程明细 | |
41 | + * 4、判断单据是否按出库流程操作 | |
42 | + * | |
43 | + * @param ids 出库单id | |
44 | + * @param code 状态流 | |
45 | + * @return | |
46 | + */ | |
47 | + @Override | |
48 | + public List<ShipmentHeader> checkShipmentProcess(String ids, Integer code) { | |
49 | + //查找出库首选项 | |
50 | + ShipmentPreference shipmentPreference = shipmentPreferenceService.list().get(0); | |
51 | + if(shipmentPreference == null){ | |
52 | + throw new ServiceException("系统没有设置出库首选"); | |
53 | + } | |
54 | + if(StringUtils.isEmpty(shipmentPreference.getShippingFlow())){ | |
55 | + throw new ServiceException("出库首选没有绑定出库流程"); | |
56 | + } | |
57 | + | |
58 | + //查看出库流程 | |
59 | + LambdaQueryWrapper<StatusFlowHeader> statusFlowHeaderLam = Wrappers.lambdaQuery(); | |
60 | + statusFlowHeaderLam.eq(StatusFlowHeader::getCode,shipmentPreference.getShippingFlow()) | |
61 | + .eq(StatusFlowHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()); | |
62 | + StatusFlowHeader statusFlowHeader = statusFlowHeaderService.getOne(statusFlowHeaderLam); | |
63 | + if(statusFlowHeader == null){ | |
64 | + throw new ServiceException("出库首选绑定的出库流程不在系统中"); | |
65 | + } | |
66 | + //查看流程明细 | |
67 | + LambdaQueryWrapper<StatusFlowDetail> statusFlowDetailLamb = Wrappers.lambdaQuery(); | |
68 | + statusFlowDetailLamb.eq(StatusFlowDetail::getHeaderId,statusFlowHeader.getId()) | |
69 | + .eq(StatusFlowDetail::getWarehouseCode,ShiroUtils.getWarehouseCode()) | |
70 | + .eq(StatusFlowDetail::getFlowCode,code.toString()); | |
71 | + StatusFlowDetail statusFlowDetail = statusFlowDetailService.getOne(statusFlowDetailLamb); | |
72 | + | |
73 | + List<ShipmentHeader> shipmentHeaderList = new ArrayList<>(); | |
74 | + if(statusFlowDetail != null && statusFlowDetail.getNessary() == 1){ | |
75 | + for (Integer id : Convert.toIntArray(ids)) | |
76 | + { | |
77 | + //判断单据是否按出库流程操作 | |
78 | + ShipmentHeader shipmentHeader = shipmentHeaderService.getById(id); | |
79 | + if(shipmentHeader == null || shipmentHeader.getFirstStatus()<code){ | |
80 | + throw new ServiceException("单据状态不对,此操作不符合出库流程,请按照出库流程出库"); | |
81 | + } | |
82 | + shipmentHeaderList.add(shipmentHeader); | |
83 | + } | |
84 | + } | |
85 | + return shipmentHeaderList; | |
86 | + } | |
11 | 87 | } |
... | ... |
src/main/java/com/huaheng/pc/config/statusFlow/controller/StatusFlowDetailController.java
... | ... | @@ -109,6 +109,8 @@ public class StatusFlowDetailController extends BaseController { |
109 | 109 | @ResponseBody |
110 | 110 | public AjaxResult addSave(@ApiParam(name = "containerType", value = "流程明细", required = true) |
111 | 111 | StatusFlowDetail statusFlowDetail) { |
112 | + StatusFlowHeader statusFlowHeader = statusFlowHeaderService.getById(statusFlowDetail.getHeaderId()); | |
113 | + statusFlowDetail.setModuleType(statusFlowHeader.getModuleType()); | |
112 | 114 | statusFlowDetail.setWarehouseCode(ShiroUtils.getWarehouseCode()); |
113 | 115 | statusFlowDetail.setCreatedBy(ShiroUtils.getLoginName()); |
114 | 116 | statusFlowDetail.setLastUpdatedBy(ShiroUtils.getLoginName()); |
... | ... |
src/main/java/com/huaheng/pc/config/statusFlow/service/StatusFlowHeaderService.java
... | ... | @@ -2,6 +2,7 @@ package com.huaheng.pc.config.statusFlow.service; |
2 | 2 | |
3 | 3 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
4 | 4 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
5 | +import com.huaheng.common.utils.security.ShiroUtils; | |
5 | 6 | import org.springframework.aop.aspectj.AspectJPrecedenceInformation; |
6 | 7 | import org.springframework.stereotype.Service; |
7 | 8 | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
... | ... | @@ -20,4 +21,13 @@ public class StatusFlowHeaderService extends ServiceImpl<StatusFlowHeaderMapper, |
20 | 21 | .eq(StatusFlowHeader::getRecordType, recordType); |
21 | 22 | return this.listMaps(lambda); |
22 | 23 | } |
24 | + | |
25 | + | |
26 | + //根据模块区分出入库流程 | |
27 | + public List<StatusFlowHeader> shipmentStatusFlowHeaders(String moduleType){ | |
28 | + LambdaQueryWrapper<StatusFlowHeader> lambda = Wrappers.lambdaQuery(); | |
29 | + lambda.eq(StatusFlowHeader::getModuleType,moduleType) | |
30 | + .eq(StatusFlowHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()); | |
31 | + return this.list(lambda); | |
32 | + } | |
23 | 33 | } |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentContainerHeader/service/ShipmentContainerHeaderServiceImpl.java
... | ... | @@ -10,6 +10,7 @@ import com.huaheng.pc.config.location.domain.Location; |
10 | 10 | import com.huaheng.pc.config.location.service.LocationService; |
11 | 11 | import com.huaheng.pc.config.material.domain.Material; |
12 | 12 | import com.huaheng.pc.config.material.service.MaterialService; |
13 | +import com.huaheng.pc.config.shipmentPreference.service.ShipmentPreferenceService; | |
13 | 14 | import com.huaheng.pc.inventory.inventoryDetail.domain.InventoryDetail; |
14 | 15 | import com.huaheng.pc.inventory.inventoryDetail.service.InventoryDetailService; |
15 | 16 | import com.huaheng.pc.shipment.shipmentContainerDetail.domain.ShipmentContainerDetail; |
... | ... | @@ -67,6 +68,8 @@ public class ShipmentContainerHeaderServiceImpl extends ServiceImpl<ShipmentCont |
67 | 68 | private TaskDetailService taskDetailService; |
68 | 69 | @Autowired |
69 | 70 | private WaveService waveService; |
71 | + @Autowired | |
72 | + private ShipmentPreferenceService shipmentPreferenceService; | |
70 | 73 | |
71 | 74 | |
72 | 75 | @Override |
... | ... | @@ -392,6 +395,15 @@ public class ShipmentContainerHeaderServiceImpl extends ServiceImpl<ShipmentCont |
392 | 395 | @Override |
393 | 396 | @Transactional |
394 | 397 | public AjaxResult autoCombination(String shipmentCode) { |
398 | + LambdaQueryWrapper<ShipmentHeader> shipmentHeaderLam = Wrappers.lambdaQuery(); | |
399 | + shipmentHeaderLam.eq(ShipmentHeader::getWarehouseCode,ShiroUtils.getWarehouseCode()) | |
400 | + .eq(ShipmentHeader::getCode,shipmentCode); | |
401 | + ShipmentHeader shipmentHeader = shipmentHeaderService.getOne(shipmentHeaderLam); | |
402 | + if(shipmentHeader == null){ | |
403 | + throw new ServiceException("系统没有此单据"); | |
404 | + } | |
405 | + shipmentPreferenceService.checkShipmentProcess(shipmentHeader.getId().toString(),100); | |
406 | + | |
395 | 407 | LambdaQueryWrapper<ShipmentDetail> lambdaQueryWrapper = Wrappers.lambdaQuery(); |
396 | 408 | lambdaQueryWrapper.eq(ShipmentDetail::getShipmentCode, shipmentCode) |
397 | 409 | .eq(ShipmentDetail::getWarehouseCode, ShiroUtils.getWarehouseCode()); |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentDetail/service/ShipmentDetailServiceImpl.java
... | ... | @@ -10,6 +10,12 @@ import com.huaheng.common.utils.security.ShiroUtils; |
10 | 10 | import com.huaheng.framework.web.domain.AjaxResult; |
11 | 11 | import com.huaheng.pc.config.material.domain.Material; |
12 | 12 | import com.huaheng.pc.config.material.service.MaterialService; |
13 | +import com.huaheng.pc.config.shipmentPreference.domain.ShipmentPreference; | |
14 | +import com.huaheng.pc.config.shipmentPreference.service.ShipmentPreferenceService; | |
15 | +import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail; | |
16 | +import com.huaheng.pc.config.statusFlow.domain.StatusFlowHeader; | |
17 | +import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService; | |
18 | +import com.huaheng.pc.config.statusFlow.service.StatusFlowHeaderService; | |
13 | 19 | import com.huaheng.pc.config.waveMaster.domain.WaveMaster; |
14 | 20 | import com.huaheng.pc.config.waveMaster.service.WaveMasterService; |
15 | 21 | import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader; |
... | ... | @@ -43,6 +49,12 @@ public class ShipmentDetailServiceImpl extends ServiceImpl<ShipmentDetailMapper, |
43 | 49 | private WaveMasterService waveMasterService; |
44 | 50 | @Autowired |
45 | 51 | private WaveService waveService; |
52 | + @Autowired | |
53 | + private ShipmentPreferenceService shipmentPreferenceService; | |
54 | + @Autowired | |
55 | + private StatusFlowHeaderService statusFlowHeaderService; | |
56 | + @Autowired | |
57 | + private StatusFlowDetailService statusFlowDetailService; | |
46 | 58 | |
47 | 59 | /** |
48 | 60 | * 新增出库明细 |
... | ... | @@ -152,6 +164,7 @@ public class ShipmentDetailServiceImpl extends ServiceImpl<ShipmentDetailMapper, |
152 | 164 | |
153 | 165 | |
154 | 166 | /** |
167 | + * 查看选中的单据状态是否符合出库流程 | |
155 | 168 | * 选中的单据加入波次 |
156 | 169 | * 根据选中的主单ID和波次主表的code,判断主单之和是否符合波次的限制条件, |
157 | 170 | * 看此code的波次是否建成未开始执行,如果是则只需修改波次属性,否则创建新的波次, |
... | ... | @@ -160,6 +173,9 @@ public class ShipmentDetailServiceImpl extends ServiceImpl<ShipmentDetailMapper, |
160 | 173 | @Override |
161 | 174 | @Transactional |
162 | 175 | public void saveWave(String ids, String code) { |
176 | + Integer status = 100; | |
177 | + List<ShipmentHeader> shipmentHeaderList =shipmentPreferenceService.checkShipmentProcess(ids,status); | |
178 | + | |
163 | 179 | //找到波次主表,看系统是否有此波次 |
164 | 180 | LambdaQueryWrapper<WaveMaster> lam=Wrappers.lambdaQuery(); |
165 | 181 | lam.eq(WaveMaster::getCode,code) |
... | ... | @@ -248,12 +264,8 @@ public class ShipmentDetailServiceImpl extends ServiceImpl<ShipmentDetailMapper, |
248 | 264 | throw new ServiceException("出库子单加入波次失败"); |
249 | 265 | } |
250 | 266 | |
251 | - List<ShipmentHeader> shipmentHeaderList=new ArrayList<>(); | |
252 | - //修改主单状态 | |
253 | - for (Integer id : Convert.toIntArray(ids)){ | |
254 | - ShipmentHeader shipmentHeader = shipmentHeaderService.getById(id); | |
267 | + for(ShipmentHeader shipmentHeader :shipmentHeaderList){ | |
255 | 268 | shipmentHeader.setLastStatus(200); |
256 | - shipmentHeaderList.add(shipmentHeader); | |
257 | 269 | } |
258 | 270 | flag = shipmentHeaderService.updateBatchById(shipmentHeaderList); |
259 | 271 | if(flag == false){ |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentHeader/controller/ShipmentHeaderController.java
... | ... | @@ -184,6 +184,22 @@ public class ShipmentHeaderController extends BaseController |
184 | 184 | return AjaxResult.success("删除成功!"); |
185 | 185 | } |
186 | 186 | |
187 | + | |
188 | + /** | |
189 | + * 审核出库主单 | |
190 | + */ | |
191 | + @RequiresPermissions("shipment:bill:edit") | |
192 | + @Log(title = "出库-出库单", operating="审核出库主单", action = BusinessType.UPDATE) | |
193 | + @PostMapping("/review") | |
194 | + @ResponseBody | |
195 | + public AjaxResult review(String ids) | |
196 | + { | |
197 | + if (StringUtils.isEmpty(ids)) { | |
198 | + return AjaxResult.error("id不能为空"); | |
199 | + } | |
200 | + return shipmentHeaderService.review(ids); | |
201 | + } | |
202 | + | |
187 | 203 | /** |
188 | 204 | * 出库单报表打印 |
189 | 205 | * @return |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentHeader/service/ShipmentHeaderService.java
... | ... | @@ -11,7 +11,6 @@ public interface ShipmentHeaderService extends IService<ShipmentHeader>{ |
11 | 11 | //新增出库主单 |
12 | 12 | AjaxResult<Boolean> saveHeader(ShipmentHeader shipmentHeader) ; |
13 | 13 | |
14 | - | |
15 | 14 | //根据单据类型建单据号 |
16 | 15 | String createCode(String shipmentType); |
17 | 16 | |
... | ... | @@ -20,4 +19,7 @@ public interface ShipmentHeaderService extends IService<ShipmentHeader>{ |
20 | 19 | |
21 | 20 | AjaxResult addHistory(ShipmentHeader shipmentHeader) throws InvocationTargetException, IllegalAccessException; |
22 | 21 | |
22 | + //审核出库单 | |
23 | + AjaxResult review(String ids); | |
24 | + | |
23 | 25 | } |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentHeader/service/ShipmentHeaderServiceImpl.java
... | ... | @@ -3,6 +3,7 @@ package com.huaheng.pc.shipment.shipmentHeader.service; |
3 | 3 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
4 | 4 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
5 | 5 | import com.huaheng.common.exception.service.ServiceException; |
6 | +import com.huaheng.common.support.Convert; | |
6 | 7 | import com.huaheng.common.utils.security.ShiroUtils; |
7 | 8 | import com.huaheng.framework.web.domain.AjaxResult; |
8 | 9 | import com.huaheng.pc.shipment.shipmentContainerHeader.service.ShipmentContainerHeaderService; |
... | ... | @@ -169,4 +170,59 @@ public class ShipmentHeaderServiceImpl extends ServiceImpl<ShipmentHeaderMapper, |
169 | 170 | } |
170 | 171 | return null; |
171 | 172 | } |
173 | + | |
174 | + /**审核出库单,加入订单池 | |
175 | + * 1、找到主单,确定主单的状态是否小于100 | |
176 | + * 2.小于100时,把主单和相应的子单加入到list中,大于等于100时,直接跳过 | |
177 | + * 3.将修改后的主单列表和子单列表进行修改,加入订单池 | |
178 | + * | |
179 | + * @param ids | |
180 | + * @return | |
181 | + */ | |
182 | + | |
183 | + @Override | |
184 | + public AjaxResult review(String ids) { | |
185 | + | |
186 | + List<ShipmentHeader> shipmentHeaders = new ArrayList<>(); | |
187 | + List<ShipmentDetail> shipmentDetails = new ArrayList<>(); | |
188 | + | |
189 | + //1、找到主单,确定主单的状态是否小于100 | |
190 | + for (Integer id : Convert.toIntArray(ids)){ | |
191 | + ShipmentHeader shipmentHeader = this.getById(id); | |
192 | + if(shipmentHeader == null){ | |
193 | + return AjaxResult.error("id为"+id+"的主单在系统不存在"); | |
194 | + } | |
195 | + | |
196 | + //2.小于100时,把主单和相应的子单加入到list中,大于等于100时,直接跳过 | |
197 | + if(shipmentHeader.getFirstStatus() < 100 && shipmentHeader.getLastStatus() <100){ | |
198 | + shipmentHeader.setFirstStatus(100); | |
199 | + shipmentHeader.setLastStatus(100); | |
200 | + shipmentHeaders.add(shipmentHeader); | |
201 | + | |
202 | + LambdaQueryWrapper<ShipmentDetail> lam = Wrappers.lambdaQuery(); | |
203 | + lam.eq(ShipmentDetail::getShipmentId,id) | |
204 | + .eq(ShipmentDetail::getWarehouseCode,ShiroUtils.getWarehouseCode()); | |
205 | + List<ShipmentDetail> shipmentDetailList = shipmentDetailService.list(lam); | |
206 | + if(shipmentDetailList != null){ | |
207 | + for(ShipmentDetail shipmentDetail : shipmentDetailList){ | |
208 | + shipmentDetail.setStatus(100); | |
209 | + } | |
210 | + shipmentDetails.addAll(shipmentDetailList); | |
211 | + }else { | |
212 | + return AjaxResult.error("id为"+id+"的出库明细在系统不存在"); | |
213 | + } | |
214 | + } | |
215 | + } | |
216 | + | |
217 | + // 3.将修改后的主单列表和子单列表进行修改,加入订单池 | |
218 | + Boolean flag = this.updateBatchById(shipmentHeaders); | |
219 | + if (flag == false){ | |
220 | + throw new ServiceException("修改主单状态失败"); | |
221 | + } | |
222 | + flag = shipmentDetailService.updateBatchById(shipmentDetails); | |
223 | + if (flag == false){ | |
224 | + throw new ServiceException("修改明细状态失败"); | |
225 | + } | |
226 | + return AjaxResult.success("订单审核成功,成功加入订单池"); | |
227 | + } | |
172 | 228 | } |
... | ... |
src/main/resources/static/huaheng/js/huahengUI.js
... | ... | @@ -194,6 +194,15 @@ |
194 | 194 | }); |
195 | 195 | return actions.join(''); |
196 | 196 | }, |
197 | + selectWhetherLabel: function(_value) { | |
198 | + var actions = []; | |
199 | + if (_value == 0) { | |
200 | + actions.push("<span class='badge badge-primary'>是</span>"); | |
201 | + } else { | |
202 | + actions.push("<span class='badge badge-danger'>否</span>") | |
203 | + } | |
204 | + return actions.join(''); | |
205 | + }, | |
197 | 206 | // 回显数据绑定的表格 |
198 | 207 | selectIdToName: function(_datas, _value) { |
199 | 208 | var actions = []; |
... | ... |
src/main/resources/templates/config/filterConfigDetail/add.html
... | ... | @@ -12,18 +12,18 @@ |
12 | 12 | <input id="code" name="code" class="form-control" type="text"> |
13 | 13 | </div> |
14 | 14 | </div> |
15 | - <div class="form-group"> | |
16 | - <label class="col-sm-3 control-label">模块:</label> | |
17 | - <div class="col-sm-8"> | |
18 | - <input id="moduleType" name="moduleType" class="form-control" type="text"> | |
19 | - </div> | |
20 | - </div> | |
21 | - <div class="form-group"> | |
22 | - <label class="col-sm-3 control-label">类型:</label> | |
23 | - <div class="col-sm-8"> | |
24 | - <input id="recordType" name="recordType" class="form-control" type="text"> | |
25 | - </div> | |
26 | - </div> | |
15 | + <!--<div class="form-group">--> | |
16 | + <!--<label class="col-sm-3 control-label">模块:</label>--> | |
17 | + <!--<div class="col-sm-8">--> | |
18 | + <!--<input id="moduleType" name="moduleType" class="form-control" type="text">--> | |
19 | + <!--</div>--> | |
20 | + <!--</div>--> | |
21 | + <!--<div class="form-group">--> | |
22 | + <!--<label class="col-sm-3 control-label">类型:</label>--> | |
23 | + <!--<div class="col-sm-8">--> | |
24 | + <!--<input id="recordType" name="recordType" class="form-control" type="text">--> | |
25 | + <!--</div>--> | |
26 | + <!--</div>--> | |
27 | 27 | <div class="form-group"> |
28 | 28 | <label class="col-sm-3 control-label">条件名:</label> |
29 | 29 | <div class="col-sm-8"> |
... | ... | @@ -45,28 +45,24 @@ |
45 | 45 | <div class="form-group"> |
46 | 46 | <label class="col-sm-3 control-label">是否系统创建:</label> |
47 | 47 | <div class="col-sm-8"> |
48 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
49 | - <input type="radio" id="systemCreated1" name="systemCreated" value="true" checked="checked" | |
50 | - class="radio_select"> | |
51 | - <label for="systemCreated1">是</label> | |
52 | - </div> | |
53 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
54 | - <input type="radio" id="systemCreated2" name="systemCreated" value="false"> | |
55 | - <label for="systemCreated2">否</label> | |
48 | + <div class="onoffswitch"> | |
49 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="systemCreated" name="systemCreated"> | |
50 | + <label class="onoffswitch-label" for="systemCreated"> | |
51 | + <span class="onoffswitch-inner"></span> | |
52 | + <span class="onoffswitch-switch"></span> | |
53 | + </label> | |
56 | 54 | </div> |
57 | 55 | </div> |
58 | 56 | </div> |
59 | 57 | <div class="form-group"> |
60 | 58 | <label class="col-sm-3 control-label">是否自定义SQL:</label> |
61 | 59 | <div class="col-sm-8"> |
62 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
63 | - <input type="radio" id="customSql1" name="customSql" value="true" checked="checked" | |
64 | - class="radio_select"> | |
65 | - <label for="customSql1">是</label> | |
66 | - </div> | |
67 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
68 | - <input type="radio" id="customSql2" name="customSql" value="false"> | |
69 | - <label for="customSql2">否</label> | |
60 | + <div class="onoffswitch"> | |
61 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="customSql" name="customSql"> | |
62 | + <label class="onoffswitch-label" for="customSql"> | |
63 | + <span class="onoffswitch-inner"></span> | |
64 | + <span class="onoffswitch-switch"></span> | |
65 | + </label> | |
70 | 66 | </div> |
71 | 67 | </div> |
72 | 68 | </div> |
... | ... | @@ -86,12 +82,12 @@ |
86 | 82 | code:{ |
87 | 83 | required:true, |
88 | 84 | }, |
89 | - moduleType:{ | |
90 | - required:true, | |
91 | - }, | |
92 | - recordType:{ | |
93 | - required:true, | |
94 | - }, | |
85 | + // moduleType:{ | |
86 | + // required:true, | |
87 | + // }, | |
88 | + // recordType:{ | |
89 | + // required:true, | |
90 | + // }, | |
95 | 91 | filterCode:{ |
96 | 92 | required:true, |
97 | 93 | }, |
... | ... | @@ -99,6 +95,8 @@ |
99 | 95 | submitHandler: function(form) { |
100 | 96 | // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize()); |
101 | 97 | var tableValue = $.common.getTableValue("#form-filterConfigDetail-add"); |
98 | + tableValue = formValueReplace(tableValue, "systemCreated", $("input[name='systemCreated']").is(':checked')); | |
99 | + tableValue = formValueReplace(tableValue, "customSql", $("input[name='customSql']").is(':checked')); | |
102 | 100 | $.operate.save(prefix + "/add", tableValue); |
103 | 101 | } |
104 | 102 | }); |
... | ... |
src/main/resources/templates/config/filterConfigDetail/edit.html
... | ... | @@ -13,18 +13,18 @@ |
13 | 13 | <input id="code" name="code" class="form-control" type="text" th:field="*{code}"> |
14 | 14 | </div> |
15 | 15 | </div> |
16 | - <div class="form-group"> | |
17 | - <label class="col-sm-3 control-label">模块:</label> | |
18 | - <div class="col-sm-8"> | |
19 | - <input id="moduleType" name="moduleType" class="form-control" type="text" th:field="*{moduleType}"> | |
20 | - </div> | |
21 | - </div> | |
22 | - <div class="form-group"> | |
23 | - <label class="col-sm-3 control-label">类型:</label> | |
24 | - <div class="col-sm-8"> | |
25 | - <input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}"> | |
26 | - </div> | |
27 | - </div> | |
16 | + <!--<div class="form-group">--> | |
17 | + <!--<label class="col-sm-3 control-label">模块:</label>--> | |
18 | + <!--<div class="col-sm-8">--> | |
19 | + <!--<input id="moduleType" name="moduleType" class="form-control" type="text" th:field="*{moduleType}">--> | |
20 | + <!--</div>--> | |
21 | + <!--</div>--> | |
22 | + <!--<div class="form-group">--> | |
23 | + <!--<label class="col-sm-3 control-label">类型:</label>--> | |
24 | + <!--<div class="col-sm-8">--> | |
25 | + <!--<input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}">--> | |
26 | + <!--</div>--> | |
27 | + <!--</div>--> | |
28 | 28 | <div class="form-group"> |
29 | 29 | <label class="col-sm-3 control-label">条件名:</label> |
30 | 30 | <div class="col-sm-8"> |
... | ... | @@ -46,28 +46,24 @@ |
46 | 46 | <div class="form-group"> |
47 | 47 | <label class="col-sm-3 control-label">是否系统创建:</label> |
48 | 48 | <div class="col-sm-8"> |
49 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
50 | - <input type="radio" id="systemCreated1" name="systemCreated" value="true" th:field="*{systemCreated}" | |
51 | - class="radio_select"> | |
52 | - <label for="systemCreated1">是</label> | |
53 | - </div> | |
54 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
55 | - <input type="radio" id="systemCreated2" name="systemCreated" value="false" th:field="*{systemCreated}"> | |
56 | - <label for="systemCreated2">否</label> | |
49 | + <div class="onoffswitch"> | |
50 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="systemCreated" name="systemCreated"> | |
51 | + <label class="onoffswitch-label" for="systemCreated"> | |
52 | + <span class="onoffswitch-inner"></span> | |
53 | + <span class="onoffswitch-switch"></span> | |
54 | + </label> | |
57 | 55 | </div> |
58 | 56 | </div> |
59 | 57 | </div> |
60 | 58 | <div class="form-group"> |
61 | 59 | <label class="col-sm-3 control-label">是否自定义SQL:</label> |
62 | 60 | <div class="col-sm-8"> |
63 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
64 | - <input type="radio" id="customSql1" name="customSql" value="true" th:field="*{customSql}" | |
65 | - class="radio_select"> | |
66 | - <label for="customSql1">是</label> | |
67 | - </div> | |
68 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
69 | - <input type="radio" id="customSql2" name="customSql" value="false" th:field="*{customSql}"> | |
70 | - <label for="customSql2">否</label> | |
61 | + <div class="onoffswitch"> | |
62 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="customSql" name="customSql"> | |
63 | + <label class="onoffswitch-label" for="customSql"> | |
64 | + <span class="onoffswitch-inner"></span> | |
65 | + <span class="onoffswitch-switch"></span> | |
66 | + </label> | |
71 | 67 | </div> |
72 | 68 | </div> |
73 | 69 | </div> |
... | ... | @@ -87,12 +83,12 @@ |
87 | 83 | code:{ |
88 | 84 | required:true, |
89 | 85 | }, |
90 | - moduleType:{ | |
91 | - required:true, | |
92 | - }, | |
93 | - recordType:{ | |
94 | - required:true, | |
95 | - }, | |
86 | + // moduleType:{ | |
87 | + // required:true, | |
88 | + // }, | |
89 | + // recordType:{ | |
90 | + // required:true, | |
91 | + // }, | |
96 | 92 | filterCode:{ |
97 | 93 | required:true, |
98 | 94 | }, |
... | ... | @@ -100,6 +96,8 @@ |
100 | 96 | submitHandler: function(form) { |
101 | 97 | // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize()); |
102 | 98 | var tableValue = $.common.getTableValue("#form-filterConfigDetail-edit"); |
99 | + tableValue = formValueReplace(tableValue, "systemCreated", $("input[name='systemCreated']").is(':checked')); | |
100 | + tableValue = formValueReplace(tableValue, "customSql", $("input[name='customSql']").is(':checked')); | |
103 | 101 | $.operate.save(prefix + "/edit", tableValue); |
104 | 102 | } |
105 | 103 | }); |
... | ... |
src/main/resources/templates/config/filterConfigDetail/filterConfigDetail.html
... | ... | @@ -22,6 +22,8 @@ |
22 | 22 | var prefix = ctx + "config/filterConfigDetail"; |
23 | 23 | var editFlag = [[${@permission.hasPermi('config:filterConfigDetail:edit')}]]; |
24 | 24 | var removeFlag = [[${@permission.hasPermi('config:filterConfigDetail:remove')}]]; |
25 | + var moduleType = [[${@dict.getType('moduleType')}]]; | |
26 | + var recordType = [[${@dict.getType('recordType')}]]; | |
25 | 27 | var datas = [[${@dict.getType('sys_normal_disable')}]]; |
26 | 28 | var nessaryDatas = [[${@dict.getType('nessary')}]]; |
27 | 29 | $(function() { |
... | ... | @@ -63,11 +65,19 @@ |
63 | 65 | }, |
64 | 66 | { |
65 | 67 | field : 'moduleType', |
66 | - title : '模块' | |
68 | + title : '模块', | |
69 | + align : "center", | |
70 | + formatter: function (value, item, index) { | |
71 | + return $.table.selectDictLabel(moduleType, value); | |
72 | + } | |
67 | 73 | }, |
68 | 74 | { |
69 | 75 | field : 'recordType', |
70 | - title : '类型' | |
76 | + title : '类型', | |
77 | + align : "center", | |
78 | + formatter: function (value, item, index) { | |
79 | + return $.table.selectDictLabel(recordType, value); | |
80 | + } | |
71 | 81 | }, |
72 | 82 | { |
73 | 83 | field : 'filterCode', |
... | ... |
src/main/resources/templates/config/filterConfigHeader/add.html
... | ... | @@ -9,14 +9,16 @@ |
9 | 9 | <label class="col-sm-3 control-label">模块:</label> |
10 | 10 | <div class="col-sm-8"> |
11 | 11 | <select class="form-control" name="moduleType" th:with="moduleType=${@dict.getType('moduleType')}"> |
12 | - <option th:each="e : ${moduleType}" th:text="${e['dictLabel']}" th:value="${e['dictValue']}"></option> | |
12 | + <option th:each="item : ${moduleType}" th:text="${item['dictLabel']}" th:value="${item['dictValue']}"></option> | |
13 | 13 | </select> |
14 | 14 | </div> |
15 | 15 | </div> |
16 | 16 | <div class="form-group"> |
17 | 17 | <label class="col-sm-3 control-label">类型:</label> |
18 | 18 | <div class="col-sm-8"> |
19 | - <input id="recordType" name="recordType" class="form-control" type="text"> | |
19 | + <select id="recordType" name="recordType" class="form-control" th:with="recordType=${@dict.getType('recordType')}"> | |
20 | + <option th:each="item : ${recordType}" th:text="${item['dictLabel']}" th:value="${item['dictValue']}"></option> | |
21 | + </select> | |
20 | 22 | </div> |
21 | 23 | </div> |
22 | 24 | <div class="form-group"> |
... | ... | @@ -46,14 +48,12 @@ |
46 | 48 | <div class="form-group"> |
47 | 49 | <label class="col-sm-3 control-label">是否系统创建:</label> |
48 | 50 | <div class="col-sm-8"> |
49 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
50 | - <input type="radio" id="systemCreated1" name="systemCreated" value="true" checked="checked" | |
51 | - class="radio_select"> | |
52 | - <label for="systemCreated1">是</label> | |
53 | - </div> | |
54 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
55 | - <input type="radio" id="systemCreated2" name="systemCreated" value="false"> | |
56 | - <label for="systemCreated2">否</label> | |
51 | + <div class="onoffswitch"> | |
52 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="systemCreated" name="systemCreated"> | |
53 | + <label class="onoffswitch-label" for="systemCreated"> | |
54 | + <span class="onoffswitch-inner"></span> | |
55 | + <span class="onoffswitch-switch"></span> | |
56 | + </label> | |
57 | 57 | </div> |
58 | 58 | </div> |
59 | 59 | </div> |
... | ... | @@ -83,7 +83,8 @@ |
83 | 83 | submitHandler: function (form) { |
84 | 84 | // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize()); |
85 | 85 | var tableValue = $.common.getTableValue("#form-filterConfigHeader-add"); |
86 | - tableValue = formValueReplace(tableValue, "moduleType", $("#moduleType option:selected").val()); | |
86 | + // tableValue = formValueReplace(tableValue, "moduleType", $("#moduleType option:selected").val()); | |
87 | + tableValue = formValueReplace(tableValue, "systemCreated", $("input[name='systemCreated']").is(':checked')); | |
87 | 88 | $.operate.save(prefix + "/add", tableValue); |
88 | 89 | } |
89 | 90 | }); |
... | ... |
src/main/resources/templates/config/filterConfigHeader/edit.html
... | ... | @@ -6,20 +6,20 @@ |
6 | 6 | <div class="wrapper wrapper-content animated fadeInRight ibox-content"> |
7 | 7 | <form class="form-horizontal m" id="form-filterConfigHeader-edit" th:object="${filterConfigHeader}"> |
8 | 8 | <input name="id" th:field="*{id}" type="hidden"> |
9 | - <div class="form-group"> | |
10 | - <label class="col-sm-3 control-label">模块:</label> | |
11 | - <div class="col-sm-8"> | |
12 | - <select class="form-control" name="moduleType" th:with="moduleType=${@dict.getType('moduleType')}" th:field="*{moduleType}"> | |
13 | - <option th:each="e : ${moduleType}" th:text="${e['dictLabel']}" th:value="${e['dictValue']}"></option> | |
14 | - </select> | |
15 | - </div> | |
16 | - </div> | |
17 | - <div class="form-group"> | |
18 | - <label class="col-sm-3 control-label">类型:</label> | |
19 | - <div class="col-sm-8"> | |
20 | - <input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}"> | |
21 | - </div> | |
22 | - </div> | |
9 | + <!--<div class="form-group">--> | |
10 | + <!--<label class="col-sm-3 control-label">模块:</label>--> | |
11 | + <!--<div class="col-sm-8">--> | |
12 | + <!--<select class="form-control" name="moduleType" th:with="moduleType=${@dict.getType('moduleType')}" th:field="*{moduleType}">--> | |
13 | + <!--<option th:each="e : ${moduleType}" th:text="${e['dictLabel']}" th:value="${e['dictValue']}"></option>--> | |
14 | + <!--</select>--> | |
15 | + <!--</div>--> | |
16 | + <!--</div>--> | |
17 | + <!--<div class="form-group">--> | |
18 | + <!--<label class="col-sm-3 control-label">类型:</label>--> | |
19 | + <!--<div class="col-sm-8">--> | |
20 | + <!--<input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}">--> | |
21 | + <!--</div>--> | |
22 | + <!--</div>--> | |
23 | 23 | <div class="form-group"> |
24 | 24 | <label class="col-sm-3 control-label">条件名:</label> |
25 | 25 | <div class="col-sm-8"> |
... | ... | @@ -38,29 +38,16 @@ |
38 | 38 | <input id="description" name="description" class="form-control" type="text" th:field="*{description}"> |
39 | 39 | </div> |
40 | 40 | </div> |
41 | - <!--<div class="form-group">--> | |
42 | - <!--<label class="col-sm-3 control-label">是否系统创建:</label>--> | |
43 | - <!--<div class="col-sm-8">--> | |
44 | - <!--<div class="onoffswitch">--> | |
45 | - <!--<input type="checkbox" th:checked="${systemCreated}" class="onoffswitch-checkbox" id="systemCreated" name="systemCreated">--> | |
46 | - <!--<label class="onoffswitch-label" for="systemCreated">--> | |
47 | - <!--<span class="onoffswitch-inner"></span>--> | |
48 | - <!--<span class="onoffswitch-switch"></span>--> | |
49 | - <!--</label>--> | |
50 | - <!--</div>--> | |
51 | - <!--</div>--> | |
52 | - <!--</div>--> | |
41 | + | |
53 | 42 | <div class="form-group"> |
54 | 43 | <label class="col-sm-3 control-label">是否系统创建:</label> |
55 | 44 | <div class="col-sm-8"> |
56 | - <div class="radio radio-info radio-inline" style="transform: scale(1.1, 1.1);"> | |
57 | - <input type="radio" id="systemCreated1" name="systemCreated" value="true" th:field="*{systemCreated}" | |
58 | - class="radio_select"> | |
59 | - <label for="systemCreated1">是</label> | |
60 | - </div> | |
61 | - <div class="radio radio-danger radio-inline " style="transform: scale(1.1, 1.1);"> | |
62 | - <input type="radio" id="systemCreated2" name="systemCreated" value="false" th:field="*{systemCreated}"> | |
63 | - <label for="systemCreated2">否</label> | |
45 | + <div class="onoffswitch"> | |
46 | + <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="systemCreated" name="systemCreated"> | |
47 | + <label class="onoffswitch-label" for="systemCreated"> | |
48 | + <span class="onoffswitch-inner"></span> | |
49 | + <span class="onoffswitch-switch"></span> | |
50 | + </label> | |
64 | 51 | </div> |
65 | 52 | </div> |
66 | 53 | </div> |
... | ... | @@ -92,7 +79,8 @@ |
92 | 79 | }, |
93 | 80 | submitHandler: function(form) { |
94 | 81 | var tableValue = $.common.getTableValue("#form-filterConfigHeader-edit"); |
95 | - tableValue = formValueReplace(tableValue, "moduleType", $("#moduleType option:selected").val()); | |
82 | + // tableValue = formValueReplace(tableValue, "moduleType", $("#moduleType option:selected").val()); | |
83 | + tableValue = formValueReplace(tableValue, "systemCreated", $("input[name='systemCreated']").is(':checked')); | |
96 | 84 | $.operate.save(prefix + "/edit", tableValue); |
97 | 85 | } |
98 | 86 | }); |
... | ... |
src/main/resources/templates/config/filterConfigHeader/filterConfigHeader.html
... | ... | @@ -75,6 +75,7 @@ |
75 | 75 | var removeFlag = [[${@permission.hasPermi('config:filterConfigHeader:remove')}]]; |
76 | 76 | var datas = [[${@dict.getType('sys_normal_disable')}]]; |
77 | 77 | var moduleType = [[${@dict.getType('moduleType')}]]; |
78 | + var recordType = [[${@dict.getType('recordType')}]]; | |
78 | 79 | $(function() { |
79 | 80 | var options = { |
80 | 81 | url: prefix + "/list", |
... | ... | @@ -105,7 +106,11 @@ |
105 | 106 | }, |
106 | 107 | { |
107 | 108 | field : 'recordType', |
108 | - title : '类型' | |
109 | + title : '类型', | |
110 | + align : "center", | |
111 | + formatter: function (value, item, index) { | |
112 | + return $.table.selectDictLabel(recordType, value); | |
113 | + } | |
109 | 114 | }, |
110 | 115 | { |
111 | 116 | field : 'filterCode', |
... | ... |
src/main/resources/templates/config/receiptPreference/add.html
... | ... | @@ -38,8 +38,8 @@ |
38 | 38 | <label class="col-sm-3 control-label">允许超收:</label> |
39 | 39 | <div class="col-sm-8"> |
40 | 40 | <select id="allowOverReceiving" name="allowOverReceiving" class="form-control"> |
41 | - <option value="0">允许</option> | |
42 | - <option value="1">不允许</option> | |
41 | + <option value="1">允许</option> | |
42 | + <option value="0">不允许</option> | |
43 | 43 | </select> |
44 | 44 | </div> |
45 | 45 | </div> |
... | ... | @@ -82,7 +82,7 @@ |
82 | 82 | <div class="form-group"> |
83 | 83 | <label class="col-sm-3 control-label">定位规则:</label> |
84 | 84 | <div class="col-sm-8"> |
85 | - <select id="locatingRule" name="locatingRule" class="form-control" th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('入库')}"> | |
85 | + <select id="locationRule" name="locationRule" class="form-control" th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('locationRule')}"> | |
86 | 86 | <option value="">请选择</option> |
87 | 87 | <option th:each="item : ${list}" th:text="${item['description']}" th:value="${item['code']}"></option> |
88 | 88 | </select> |
... | ... | @@ -92,7 +92,7 @@ |
92 | 92 | <label class="col-sm-3 control-label">空库位规则:</label> |
93 | 93 | <div class="col-sm-8"> |
94 | 94 | <select id="emptyLocRule" name="emptyLocRule" class="form-control" |
95 | - th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('空库位规则')}"> | |
95 | + th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('emptyLocRule')}"> | |
96 | 96 | <option value="">请选择</option> |
97 | 97 | <option th:each="item : ${list}" th:text="${item['description']}" th:value="${item['code']}"></option> |
98 | 98 | </select> |
... | ... | @@ -137,7 +137,10 @@ |
137 | 137 | <div class="form-group"> |
138 | 138 | <label class="col-sm-3 control-label">RF快速上架:</label> |
139 | 139 | <div class="col-sm-8"> |
140 | - <input id="allowQuickPutaway" name="allowQuickPutaway" class="form-control" type="text"> | |
140 | + <select id="allowQuickPutaway" name="allowQuickPutaway" class="form-control"> | |
141 | + <option value="0">是</option> | |
142 | + <option value="1">否</option> | |
143 | + </select> | |
141 | 144 | </div> |
142 | 145 | </div> |
143 | 146 | <div class="form-group"> |
... | ... | @@ -149,7 +152,10 @@ |
149 | 152 | <div class="form-group"> |
150 | 153 | <label class="col-sm-3 control-label">快速入库:</label> |
151 | 154 | <div class="col-sm-8"> |
152 | - <input id="useQuickCheckIn" name="useQuickCheckIn" class="form-control" type="text"> | |
155 | + <select id="useQuickCheckIn" name="useQuickCheckIn" class="form-control"> | |
156 | + <option value="0">是</option> | |
157 | + <option value="1">否</option> | |
158 | + </select> | |
153 | 159 | </div> |
154 | 160 | </div> |
155 | 161 | <!--<div class="form-group"> |
... | ... | @@ -284,12 +290,14 @@ |
284 | 290 | submitHandler: function(form) { |
285 | 291 | var tableValue = $.common.getTableValue("#form-receiptPreference-add"); |
286 | 292 | tableValue = formValueReplace(tableValue, "allowOverReceiving", $("#allowOverReceiving option:selected").val()); |
287 | - tableValue = formValueReplace(tableValue, "receiptFlow", $("#receiptFlow option:selected").val()); | |
293 | + tableValue = formValueReplace(tableValue, "receivingFlow", $("#receivingFlow option:selected").val()); | |
288 | 294 | tableValue = formValueReplace(tableValue, "autoAssignLPN", $("#autoAssignLPN option:selected").val()); |
289 | 295 | tableValue = formValueReplace(tableValue, "autoLocate", $("#autoLocate option:selected").val()); |
290 | 296 | tableValue = formValueReplace(tableValue, "showOpenQty", $("#showOpenQty option:selected").val()); |
291 | - tableValue = formValueReplace(tableValue, "locatingRule", $("#locatingRule option:selected").val()); | |
297 | + tableValue = formValueReplace(tableValue, "locationRule", $("#locationRule option:selected").val()); | |
292 | 298 | tableValue = formValueReplace(tableValue, "emptyLocRule", $("#emptyLocRule option:selected").val()); |
299 | + tableValue = formValueReplace(tableValue, "useQuickCheckIn", $("#useQuickCheckIn option:selected").val()); | |
300 | + tableValue = formValueReplace(tableValue, "allowQuickPutaway", $("#allowQuickPutaway option:selected").val()); | |
293 | 301 | $.operate.save(prefix + "/add", tableValue); |
294 | 302 | } |
295 | 303 | }); |
... | ... |
src/main/resources/templates/config/receiptPreference/edit.html
... | ... | @@ -5,7 +5,7 @@ |
5 | 5 | <body class="white-bg"> |
6 | 6 | <div class="wrapper wrapper-content animated fadeInRight ibox-content"> |
7 | 7 | <form class="form-horizontal m" id="form-receiptPreference-edit" th:object="${receiptPreference}"> |
8 | - <input id="id" name="id" th:field="*{id}"> | |
8 | + <input id="id" name="id" th:field="*{id}" type="hidden"> | |
9 | 9 | <div class="form-group"> |
10 | 10 | <label class="col-sm-3 control-label">编码:</label> |
11 | 11 | <div class="col-sm-8"> |
... | ... | @@ -21,26 +21,27 @@ |
21 | 21 | <div class="form-group"> |
22 | 22 | <label class="col-sm-3 control-label">入库流程:</label> |
23 | 23 | <div class="col-sm-8"> |
24 | - <input id="receiptFlow" name="receiptFlow" class="form-control" type="text" th:field="*{receiptFlow}"> | |
24 | + <select id="receivingFlow" name="receivingFlow" class="form-control" th:with="statusFlowList=${@StatusFlow.flowList('入库单')}" th:field="*{receivingFlow}"> | |
25 | + <option th:each="flow : ${statusFlowList}" th:text="${flow['name']}" th:value="${flow['code']}"></option> | |
26 | + </select> | |
25 | 27 | </div> |
26 | 28 | </div> |
27 | 29 | <div class="form-group"> |
28 | 30 | <label class="col-sm-3 control-label">自动生成托盘号:</label> |
29 | 31 | <div class="col-sm-8"> |
30 | - <input id="autoAssignLPN" name="autoAssignLPN" class="form-control" type="text" th:field="*{autoAssignLPN}"> | |
32 | + <select id="autoAssignLPN" name="autoAssignLPN" class="form-control" th:field="*{autoAssignLPN}"> | |
33 | + <option value="0">自动生成</option> | |
34 | + <option value="1">不自动生成</option> | |
35 | + </select> | |
31 | 36 | </div> |
32 | 37 | </div> |
33 | 38 | <div class="form-group"> |
34 | 39 | <label class="col-sm-3 control-label">允许超收:</label> |
35 | 40 | <div class="col-sm-8"> |
36 | - <div class="onoffswitch"> | |
37 | - <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="allowOverReceiving" | |
38 | - name="allowOverReceiving" th:field="*{allowOverReceiving}"> | |
39 | - <label class="onoffswitch-label" for="allowOverReceiving"> | |
40 | - <span class="onoffswitch-inner"></span> | |
41 | - <span class="onoffswitch-switch"></span> | |
42 | - </label> | |
43 | - </div> | |
41 | + <select id="allowOverReceiving" name="allowOverReceiving" class="form-control" th:field="*{allowOverReceiving}"> | |
42 | + <option value="1">允许</option> | |
43 | + <option value="0">不允许</option> | |
44 | + </select> | |
44 | 45 | </div> |
45 | 46 | </div> |
46 | 47 | <div class="form-group"> |
... | ... | @@ -52,13 +53,19 @@ |
52 | 53 | <div class="form-group"> |
53 | 54 | <label class="col-sm-3 control-label">自动定位:</label> |
54 | 55 | <div class="col-sm-8"> |
55 | - <input id="autoLocate" name="autoLocate" class="form-control" type="text" th:field="*{autoLocate}"> | |
56 | + <select id="autoLocate" name="autoLocate" th:field="*{autoLocate}" class="form-control"> | |
57 | + <option value="0">是</option> | |
58 | + <option value="1">否</option> | |
59 | + </select> | |
56 | 60 | </div> |
57 | 61 | </div> |
58 | 62 | <div class="form-group"> |
59 | 63 | <label class="col-sm-3 control-label">RF显示未收数量:</label> |
60 | 64 | <div class="col-sm-8"> |
61 | - <input id="showOpenQty" name="showOpenQty" class="form-control" type="text" th:field="*{showOpenQty}"> | |
65 | + <select id="showOpenQty" name="showOpenQty" class="form-control" th:field="*{showOpenQty}"> | |
66 | + <option value="0">是</option> | |
67 | + <option value="1">否</option> | |
68 | + </select> | |
62 | 69 | </div> |
63 | 70 | </div> |
64 | 71 | <div class="form-group"> |
... | ... | @@ -76,13 +83,21 @@ |
76 | 83 | <div class="form-group"> |
77 | 84 | <label class="col-sm-3 control-label">定位规则:</label> |
78 | 85 | <div class="col-sm-8"> |
79 | - <input id="locationRule" name="locationRule" class="form-control" type="text" th:field="*{locationRule}"> | |
86 | + <select id="locationRule" name="locationRule" class="form-control" | |
87 | + th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('locationRule')}" th:field="*{locationRule}"> | |
88 | + <option value="">请选择</option> | |
89 | + <option th:each="item : ${list}" th:text="${item['description']}" th:value="${item['code']}"></option> | |
90 | + </select> | |
80 | 91 | </div> |
81 | 92 | </div> |
82 | 93 | <div class="form-group"> |
83 | 94 | <label class="col-sm-3 control-label">空库位规则:</label> |
84 | 95 | <div class="col-sm-8"> |
85 | - <input id="emptyLocRule" name="emptyLocRule" class="form-control" type="text" th:field="*{emptyLocRule}"> | |
96 | + <select id="emptyLocRule" name="emptyLocRule" class="form-control" | |
97 | + th:with="list=${@FilterConfigDetailService.queryFilterConfigDetail('emptyLocRule')}" th:field="*{emptyLocRule}"> | |
98 | + <option value="">请选择</option> | |
99 | + <option th:each="item : ${list}" th:text="${item['description']}" th:value="${item['code']}"></option> | |
100 | + </select> | |
86 | 101 | </div> |
87 | 102 | </div> |
88 | 103 | <div class="form-group"> |
... | ... | @@ -124,7 +139,10 @@ |
124 | 139 | <div class="form-group"> |
125 | 140 | <label class="col-sm-3 control-label">RF快速上架:</label> |
126 | 141 | <div class="col-sm-8"> |
127 | - <input id="allowQuickPutaway" name="allowQuickPutaway" class="form-control" type="text" th:field="*{allowQuickPutaway}"> | |
142 | + <select id="allowQuickPutaway" name="allowQuickPutaway" class="form-control" th:field="*{allowQuickPutaway}"> | |
143 | + <option value="0">是</option> | |
144 | + <option value="1">否</option> | |
145 | + </select> | |
128 | 146 | </div> |
129 | 147 | </div> |
130 | 148 | <div class="form-group"> |
... | ... | @@ -136,7 +154,10 @@ |
136 | 154 | <div class="form-group"> |
137 | 155 | <label class="col-sm-3 control-label">快速入库:</label> |
138 | 156 | <div class="col-sm-8"> |
139 | - <input id="useQuickCheckIn" name="useQuickCheckIn" class="form-control" type="text" th:field="*{useQuickCheckIn}"> | |
157 | + <select id="useQuickCheckIn" name="useQuickCheckIn" class="form-control" th:field="*{useQuickCheckIn}"> | |
158 | + <option value="0">是</option> | |
159 | + <option value="1">否</option> | |
160 | + </select> | |
140 | 161 | </div> |
141 | 162 | </div> |
142 | 163 | <!--<div class="form-group"> |
... | ... | @@ -269,8 +290,14 @@ |
269 | 290 | } |
270 | 291 | }, |
271 | 292 | submitHandler: function(form) { |
272 | - var tableValue = $.common.getTableValue("#form-receiptPreference-edi"); | |
293 | + var tableValue = $.common.getTableValue("#form-receiptPreference-edit"); | |
273 | 294 | tableValue = formValueReplace(tableValue, "allowOverReceiving", $("input[name='allowOverReceiving']").is(':checked')); |
295 | + tableValue = formValueReplace(tableValue, "receivingFlow", $("#receivingFlow option:selected").val()); | |
296 | + tableValue = formValueReplace(tableValue, "autoAssignLPN", $("#autoAssignLPN option:selected").val()); | |
297 | + tableValue = formValueReplace(tableValue, "autoLocate", $("#autoLocate option:selected").val()); | |
298 | + tableValue = formValueReplace(tableValue, "showOpenQty", $("#showOpenQty option:selected").val()); | |
299 | + tableValue = formValueReplace(tableValue, "locationRule", $("#locationRule option:selected").val()); | |
300 | + tableValue = formValueReplace(tableValue, "emptyLocRule", $("#emptyLocRule option:selected").val()); | |
274 | 301 | $.operate.save(prefix + "/edit", tableValue); |
275 | 302 | } |
276 | 303 | }); |
... | ... |
src/main/resources/templates/config/receiptPreference/receiptPreference.html
... | ... | @@ -90,11 +90,19 @@ |
90 | 90 | }, |
91 | 91 | { |
92 | 92 | field : 'autoAssignLPN', |
93 | - title : '自动生成托盘号' | |
93 | + title : '自动生成托盘号', | |
94 | + align : "center", | |
95 | + formatter : function(value, row, index) { | |
96 | + return $.table.selectWhetherLabel(value); | |
97 | + }, | |
94 | 98 | }, |
95 | 99 | { |
96 | 100 | field : 'allowOverReceiving', |
97 | - title : '允许超收' | |
101 | + title : '允许超收', | |
102 | + align : "center", | |
103 | + formatter : function(value, row, index) { | |
104 | + if (value){return "<span class='badge badge-primary'>是</span>";} else {return "<span class='badge badge-danger'>否</span>";} | |
105 | + }, | |
98 | 106 | }, |
99 | 107 | { |
100 | 108 | field : 'allowOverReceivingQty', |
... | ... | @@ -102,11 +110,19 @@ |
102 | 110 | }, |
103 | 111 | { |
104 | 112 | field : 'autoLocate', |
105 | - title : '自动定位' | |
113 | + title : '自动定位', | |
114 | + align : "center", | |
115 | + formatter : function(value, row, index) { | |
116 | + return $.table.selectWhetherLabel(value); | |
117 | + }, | |
106 | 118 | }, |
107 | 119 | { |
108 | 120 | field : 'showOpenQty', |
109 | - title : 'RF显示未收数量' | |
121 | + title : 'RF显示未收数量', | |
122 | + align : "center", | |
123 | + formatter : function(value, row, index) { | |
124 | + return $.table.selectWhetherLabel(value); | |
125 | + }, | |
110 | 126 | }, |
111 | 127 | { |
112 | 128 | field : 'receiptTypes', |
... | ... | @@ -114,11 +130,18 @@ |
114 | 130 | }, |
115 | 131 | { |
116 | 132 | field : 'groupPutaway', |
117 | - title : 'RF组车收货' | |
133 | + title : 'RF组车收货', | |
134 | + align : "center", | |
135 | + formatter : function(value, row, index) { | |
136 | + return $.table.selectWhetherLabel(value); | |
137 | + }, | |
118 | 138 | }, |
119 | 139 | { |
120 | 140 | field : 'manuallyBuildLPN', |
121 | - title : '人工组盘' | |
141 | + title : '人工组盘', | |
142 | + formatter : function(value, row, index) { | |
143 | + return $.table.selectWhetherLabel(value); | |
144 | + }, | |
122 | 145 | }, |
123 | 146 | { |
124 | 147 | field : 'locationRule', |
... | ... | @@ -130,11 +153,19 @@ |
130 | 153 | }, |
131 | 154 | { |
132 | 155 | field : 'checkinByPiece', |
133 | - title : 'RF逐件收货' | |
156 | + title : 'RF逐件收货', | |
157 | + align : "center", | |
158 | + formatter : function(value, row, index) { | |
159 | + return $.table.selectWhetherLabel(value); | |
160 | + }, | |
134 | 161 | }, |
135 | 162 | { |
136 | 163 | field : 'pieceConfirm', |
137 | - title : 'RF自动提交收货' | |
164 | + title : 'RF自动提交收货', | |
165 | + align : "center", | |
166 | + formatter : function(value, row, index) { | |
167 | + return $.table.selectWhetherLabel(value); | |
168 | + }, | |
138 | 169 | }, |
139 | 170 | { |
140 | 171 | field : 'abcClass', |
... | ... | @@ -154,7 +185,11 @@ |
154 | 185 | }, |
155 | 186 | { |
156 | 187 | field : 'allowQuickPutaway', |
157 | - title : 'RF快速上架' | |
188 | + title : 'RF快速上架', | |
189 | + align : "center", | |
190 | + formatter : function(value, row, index) { | |
191 | + return $.table.selectWhetherLabel(value); | |
192 | + }, | |
158 | 193 | }, |
159 | 194 | { |
160 | 195 | field : 'attributeTemplateCode', |
... | ... | @@ -162,7 +197,11 @@ |
162 | 197 | }, |
163 | 198 | { |
164 | 199 | field : 'useQuickCheckIn', |
165 | - title : '快速入库' | |
200 | + title : '快速入库', | |
201 | + align : "center", | |
202 | + formatter : function(value, row, index) { | |
203 | + return $.table.selectWhetherLabel(value); | |
204 | + }, | |
166 | 205 | }, |
167 | 206 | { |
168 | 207 | field : 'created', |
... | ... |
src/main/resources/templates/config/shipmentPreference/add.html
... | ... | @@ -20,19 +20,25 @@ |
20 | 20 | <div class="form-group"> |
21 | 21 | <label class="col-sm-3 control-label">出库流程:</label> |
22 | 22 | <div class="col-sm-8"> |
23 | - <input id="receiptFlow" name="shippingFlow" class="form-control" type="text"> | |
23 | + <select id="shippingFlow" name="shippingFlow" class="form-control" th:with="shippingFlow=${@StatusFlow.shipmentStatusFlowHeaders('shipment')}"> | |
24 | + <option th:each="item : ${shippingFlow}" th:text="${item['name']}" th:value="${item['code']}"></option> | |
25 | + </select> | |
24 | 26 | </div> |
25 | 27 | </div> |
26 | 28 | <div class="form-group"> |
27 | 29 | <label class="col-sm-3 control-label">库存分配规则:</label> |
28 | 30 | <div class="col-sm-8"> |
29 | - <input id="allocationRule" name="allocationRule" class="form-control" type="text"> | |
31 | + <select id="allocationRule" name="allocationRule" class="form-control" th:with="allocationRule=${@filterConfigHeaderService.getFilterConfigHeaderService('shipment','allocationRule')}"> | |
32 | + <option th:each="item : ${allocationRule}" th:text="${item['filterName']}" th:value="${item['filterCode']}"></option> | |
33 | + </select> | |
30 | 34 | </div> |
31 | 35 | </div> |
32 | 36 | <div class="form-group"> |
33 | 37 | <label class="col-sm-3 control-label">拣货规则:</label> |
34 | 38 | <div class="col-sm-8"> |
35 | - <input id="shipmentPickingRule" name="shipmentPickingRule" class="form-control" type="text"> | |
39 | + <select id="shipmentPickingRule" name="shipmentPickingRule" class="form-control" th:with="shipmentPickingRule=${@filterConfigHeaderService.getFilterConfigHeaderService('shipment','shipmentPickingRule')}"> | |
40 | + <option th:each="item : ${shipmentPickingRule}" th:text="${item['filterName']}" th:value="${item['filterCode']}"></option> | |
41 | + </select> | |
36 | 42 | </div> |
37 | 43 | </div> |
38 | 44 | <div class="form-group"> |
... | ... |
src/main/resources/templates/config/shipmentPreference/edit.html
... | ... | @@ -18,24 +18,24 @@ |
18 | 18 | <input id="name" name="name" class="form-control" type="text" th:field="*{name}"> |
19 | 19 | </div> |
20 | 20 | </div> |
21 | - <div class="form-group"> | |
22 | - <label class="col-sm-3 control-label">出库流程:</label> | |
23 | - <div class="col-sm-8"> | |
24 | - <input id="shippingFlow" name="shippingFlow" class="form-control" type="text" th:field="*{shippingFlow}"> | |
25 | - </div> | |
26 | - </div> | |
27 | - <div class="form-group"> | |
28 | - <label class="col-sm-3 control-label">库存分配规则:</label> | |
29 | - <div class="col-sm-8"> | |
30 | - <input id="allocationRule" name="allocationRule" class="form-control" type="text" th:field="*{allocationRule}"> | |
31 | - </div> | |
32 | - </div> | |
33 | - <div class="form-group"> | |
34 | - <label class="col-sm-3 control-label">拣货规则:</label> | |
35 | - <div class="col-sm-8"> | |
36 | - <input id="shipmentPickingRule" name="shipmentPickingRule" class="form-control" type="text" th:field="*{shipmentPickingRule}"> | |
37 | - </div> | |
38 | - </div> | |
21 | + <!--<div class="form-group">--> | |
22 | + <!--<label class="col-sm-3 control-label">出库流程:</label>--> | |
23 | + <!--<div class="col-sm-8">--> | |
24 | + <!--<input id="shippingFlow" name="shippingFlow" class="form-control" type="text" th:field="*{shippingFlow}">--> | |
25 | + <!--</div>--> | |
26 | + <!--</div>--> | |
27 | + <!--<div class="form-group">--> | |
28 | + <!--<label class="col-sm-3 control-label">库存分配规则:</label>--> | |
29 | + <!--<div class="col-sm-8">--> | |
30 | + <!--<input id="allocationRule" name="allocationRule" class="form-control" type="text" th:field="*{allocationRule}">--> | |
31 | + <!--</div>--> | |
32 | + <!--</div>--> | |
33 | + <!--<div class="form-group">--> | |
34 | + <!--<label class="col-sm-3 control-label">拣货规则:</label>--> | |
35 | + <!--<div class="col-sm-8">--> | |
36 | + <!--<input id="shipmentPickingRule" name="shipmentPickingRule" class="form-control" type="text" th:field="*{shipmentPickingRule}">--> | |
37 | + <!--</div>--> | |
38 | + <!--</div>--> | |
39 | 39 | <div class="form-group"> |
40 | 40 | <label class="col-sm-3 control-label">拣货库位范围规则:</label> |
41 | 41 | <div class="col-sm-8"> |
... | ... | @@ -236,18 +236,18 @@ |
236 | 236 | name:{ |
237 | 237 | required: true, |
238 | 238 | }, |
239 | - shippingFlow:{ | |
240 | - required: true, | |
241 | - }, | |
242 | - shipmentPickingRule:{ | |
243 | - required: true, | |
244 | - }, | |
239 | + // shippingFlow:{ | |
240 | + // required: true, | |
241 | + // }, | |
242 | + // shipmentPickingRule:{ | |
243 | + // required: true, | |
244 | + // }, | |
245 | 245 | shipmentPickingLocRange:{ |
246 | 246 | required: true, |
247 | 247 | }, |
248 | - allocationRule: { | |
249 | - required: true, | |
250 | - }, | |
248 | + // allocationRule: { | |
249 | + // required: true, | |
250 | + // }, | |
251 | 251 | autoAssignLPN: { |
252 | 252 | required: true, |
253 | 253 | }, |
... | ... |
src/main/resources/templates/config/shipmentPreference/shipmentPreference.html
... | ... | @@ -52,7 +52,9 @@ |
52 | 52 | var editFlag = [[${@permission.hasPermi('config:shipmentPreference:edit')}]]; |
53 | 53 | var removeFlag = [[${@permission.hasPermi('config:shipmentPreference:remove')}]]; |
54 | 54 | var prefix = ctx + "config/shipmentPreference"; |
55 | - var datas = [[${@dict.getType('sys_normal_disable')}]]; | |
55 | + var StatusFlow = [[${@StatusFlow.shipmentStatusFlowHeaders('shipment')}]]; | |
56 | + var shipmentPickingRule = [[${@filterConfigHeaderService.getFilterConfigHeaderService('shipment','shipmentPickingRule')}]]; | |
57 | + var allocationRule = [[${@filterConfigHeaderService.getFilterConfigHeaderService('shipment','allocationRule')}]]; | |
56 | 58 | $(function() { |
57 | 59 | var options = { |
58 | 60 | url: prefix + "/list", |
... | ... | @@ -83,15 +85,45 @@ |
83 | 85 | }, |
84 | 86 | { |
85 | 87 | field : 'shippingFlow', |
86 | - title : '出库流程' | |
88 | + title : '出库流程', | |
89 | + formatter: function (value, item, index) { | |
90 | + var actions = []; | |
91 | + $.each(StatusFlow, function(index, dict) { | |
92 | + if (dict.code == value) { | |
93 | + actions.push("<span class='badge badge-" + dict.code + "'>" + dict.name + "</span>"); | |
94 | + return false; | |
95 | + } | |
96 | + }); | |
97 | + return actions.join(''); | |
98 | + } | |
87 | 99 | }, |
88 | 100 | { |
89 | 101 | field : 'allocationRule', |
90 | 102 | title : '库存分配规则', |
103 | + formatter: function (value, item, index) { | |
104 | + var actions = []; | |
105 | + $.each(allocationRule, function(index, dict) { | |
106 | + if (dict.filterCode == value) { | |
107 | + actions.push("<span class='badge badge-" + dict.filterCode + "'>" + dict.filterName + "</span>"); | |
108 | + return false; | |
109 | + } | |
110 | + }); | |
111 | + return actions.join(''); | |
112 | + } | |
91 | 113 | }, |
92 | 114 | { |
93 | 115 | field : 'shipmentPickingRule', |
94 | 116 | title : '拣货规则', |
117 | + formatter: function (value, item, index) { | |
118 | + var actions = []; | |
119 | + $.each(shipmentPickingRule, function(index, dict) { | |
120 | + if (dict.filterCode == value) { | |
121 | + actions.push("<span class='badge badge-" + dict.filterCode + "'>" + dict.filterName + "</span>"); | |
122 | + return false; | |
123 | + } | |
124 | + }); | |
125 | + return actions.join(''); | |
126 | + } | |
95 | 127 | }, |
96 | 128 | { |
97 | 129 | field : 'shipmentPickingLocRange', |
... | ... |
src/main/resources/templates/config/statusFlowDetail/statusFlowDetail.html
... | ... | @@ -23,7 +23,9 @@ |
23 | 23 | var editFlag = [[${@permission.hasPermi('config:statusFlowDetails:edit')}]]; |
24 | 24 | var removeFlag = [[${@permission.hasPermi('config:statusFlowDetails:remove')}]]; |
25 | 25 | var datas = [[${@dict.getType('sys_normal_disable')}]]; |
26 | + var moduleType = [[${@dict.getType('moduleType')}]]; | |
26 | 27 | var nessaryDatas = [[${@dict.getType('nessary')}]]; |
28 | + | |
27 | 29 | $(function() { |
28 | 30 | var options = { |
29 | 31 | url: prefix + "/list", |
... | ... | @@ -67,7 +69,11 @@ |
67 | 69 | }, |
68 | 70 | { |
69 | 71 | field : 'moduleType', |
70 | - title : '模块' | |
72 | + title : '模块', | |
73 | + align : "center", | |
74 | + formatter: function (value, item, index) { | |
75 | + return $.table.selectDictLabel(moduleType, value); | |
76 | + } | |
71 | 77 | }, |
72 | 78 | { |
73 | 79 | field : 'recordType', |
... | ... |
src/main/resources/templates/config/statusFlowHeader/add.html
... | ... | @@ -28,7 +28,9 @@ |
28 | 28 | <div class="form-group"> |
29 | 29 | <label class="col-sm-3 control-label">类型:</label> |
30 | 30 | <div class="col-sm-8"> |
31 | - <input id="recordType" name="recordType" class="form-control" type="text"> | |
31 | + <select id="recordType" name="recordType" class="form-control" th:with="recordType=${@dict.getType('recordType')}"> | |
32 | + <option th:each="item : ${recordType}" th:text="${item['dictLabel']}" th:value="${item['dictValue']}"></option> | |
33 | + </select> | |
32 | 34 | </div> |
33 | 35 | </div> |
34 | 36 | <!--<div class="form-group">--> |
... | ... |
src/main/resources/templates/config/statusFlowHeader/edit.html
... | ... | @@ -18,18 +18,20 @@ |
18 | 18 | <input id="name" name="name" class="form-control" type="text" th:field="*{name}"> |
19 | 19 | </div> |
20 | 20 | </div> |
21 | - <div class="form-group"> | |
22 | - <label class="col-sm-3 control-label">模块:</label> | |
23 | - <div class="col-sm-8"> | |
24 | - <input id="moduleType" name="moduleType" class="form-control" readonly="readonly"> | |
25 | - </div> | |
26 | - </div> | |
27 | - <div class="form-group"> | |
28 | - <label class="col-sm-3 control-label">类型:</label> | |
29 | - <div class="col-sm-8"> | |
30 | - <input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}"> | |
31 | - </div> | |
32 | - </div> | |
21 | + <!--<div class="form-group">--> | |
22 | + <!--<label class="col-sm-3 control-label">模块:</label>--> | |
23 | + <!--<div class="col-sm-8">--> | |
24 | + <!--<select id="moduleType" name="moduleType" class="form-control" th:with="moduleTyped=${@dict.getType('moduleType')}" th:field="*{moduleType}">--> | |
25 | + <!--<option th:each="item : ${moduleType}" th:text="${item['dictLabel']}" th:value="${item['dictValue']}"></option>--> | |
26 | + <!--</select>--> | |
27 | + <!--</div>--> | |
28 | + <!--</div>--> | |
29 | + <!--<div class="form-group">--> | |
30 | + <!--<label class="col-sm-3 control-label">类型:</label>--> | |
31 | + <!--<div class="col-sm-8">--> | |
32 | + <!--<input id="recordType" name="recordType" class="form-control" type="text" th:field="*{recordType}">--> | |
33 | + <!--</div>--> | |
34 | + <!--</div>--> | |
33 | 35 | <!--<div class="form-group">--> |
34 | 36 | <!-- <label class="col-sm-3 control-label">数据版本:</label>--> |
35 | 37 | <!-- <div class="col-sm-8">--> |
... | ... |
src/main/resources/templates/config/statusFlowHeader/statusFlowHeader.html
... | ... | @@ -27,7 +27,7 @@ |
27 | 27 | 模块:<input type="text" name="moduleType" th:value="${moduleType}"/> |
28 | 28 | </li> |
29 | 29 | <li> |
30 | - 类型:<input type="text" name="recordType"/> | |
30 | + 类型:<input type="text" name="recordType" th:value="${recordType}"/> | |
31 | 31 | </li> |
32 | 32 | <li class="time"> |
33 | 33 | <label>创建时间: </label> |
... | ... | @@ -77,7 +77,8 @@ |
77 | 77 | var editFlag = [[${@permission.hasPermi('config:statusFlowHeader:edit')}]]; |
78 | 78 | var removeFlag = [[${@permission.hasPermi('config:statusFlowHeader:remove')}]]; |
79 | 79 | var datas = [[${@dict.getType('sys_normal_disable')}]]; |
80 | - | |
80 | + var moduleType = [[${@dict.getType('moduleType')}]]; | |
81 | + var recordType = [[${@dict.getType('recordType')}]]; | |
81 | 82 | $(function() { |
82 | 83 | var options = { |
83 | 84 | url: prefix + "/list", |
... | ... | @@ -112,11 +113,19 @@ |
112 | 113 | }, |
113 | 114 | { |
114 | 115 | field : 'moduleType', |
115 | - title : '模块' | |
116 | + title : '模块', | |
117 | + align : "center", | |
118 | + formatter: function (value, item, index) { | |
119 | + return $.table.selectDictLabel(moduleType, value); | |
120 | + } | |
116 | 121 | }, |
117 | 122 | { |
118 | 123 | field : 'recordType', |
119 | - title : '类型' | |
124 | + title : '类型', | |
125 | + align : "center", | |
126 | + formatter: function (value, item, index) { | |
127 | + return $.table.selectDictLabel(recordType, value); | |
128 | + } | |
120 | 129 | }, |
121 | 130 | { |
122 | 131 | field : 'enable', |
... | ... |
src/main/resources/templates/config/waveMaster/waveMaster.html
... | ... | @@ -48,7 +48,7 @@ |
48 | 48 | </div> |
49 | 49 | |
50 | 50 | <div class="btn-group hidden-xs" id="toolbar" role="group"> |
51 | - <a class="btn btn-outline btn-success btn-rounded" onclick="$.operate.add()" shiro:hasPermission="config:waveMaster:add"> | |
51 | + <a class="btn btn-outline btn-success btn-rounded" onclick="matserAdd()" shiro:hasPermission="config:waveMaster:add"> | |
52 | 52 | <i class="fa fa-plus"></i> 新增 |
53 | 53 | </a> |
54 | 54 | <a class="btn btn-outline btn-danger btn-rounded" onclick="$.operate.batRemove()" shiro:hasPermission="config:waveMaster:remove"> |
... | ... | @@ -512,6 +512,11 @@ |
512 | 512 | headerId = rowId; |
513 | 513 | detail(); |
514 | 514 | } |
515 | + | |
516 | + function matserAdd() { | |
517 | + var url = prefix+"/add"; | |
518 | + $.modal.open("添加" + $.table._option.modalName, url); | |
519 | + } | |
515 | 520 | </script> |
516 | 521 | </body> |
517 | 522 | </html> |
518 | 523 | \ No newline at end of file |
... | ... |
src/main/resources/templates/shipment/shipmentHeader/shipmentHeader.html
... | ... | @@ -87,10 +87,10 @@ |
87 | 87 | shiro:hasPermission="shipment:bill:remove"> |
88 | 88 | <i class="fa fa-trash-o"></i> 删除 |
89 | 89 | </a> |
90 | - <!--<a class="btn btn-outline btn-success btn-rounded" onclick="analysis()"--> | |
91 | - <!--shiro:hasPermission="shipment:bill:analysis">--> | |
92 | - <!--<i class="fa fa-plus"></i> 订单分析--> | |
93 | - <!--</a>--> | |
90 | + <a class="btn btn-outline btn-success btn-rounded" onclick="review()" | |
91 | + shiro:hasPermission="shipment:bill:edit"> | |
92 | + <i class="fa fa-plus"></i> 订单审核 | |
93 | + </a> | |
94 | 94 | <a class="btn btn-outline btn-success btn-rounded" onclick="wave()" |
95 | 95 | shiro:hasPermission="shipment:bill:wave"> |
96 | 96 | <i class="fa fa-plus"></i> 加入波次 |
... | ... | @@ -214,7 +214,8 @@ |
214 | 214 | var uploadStatus=[[${@dict.getType('uploadStatus')}]]; |
215 | 215 | var detailCreateUrl=prefix_detail+"/add"; |
216 | 216 | var detailRemoveUrl=prefix_detail+"/remove"; |
217 | - var detailanalysisUrl=prefix+"/analysis"; | |
217 | + var reviewUrl=prefix+"/review"; | |
218 | + var analysisUrl=prefix+"/analysis"; | |
218 | 219 | var inventoryStatus=[[${@dict.getType('inventoryStatus')}]]; |
219 | 220 | var rossDoccking = [[${@permission.hasPermi('shipment:bill:rossDoccking')}]]; |
220 | 221 | var rossDocckingUrl =prefix_detail+"/rossDoccking"; |
... | ... | @@ -640,10 +641,22 @@ |
640 | 641 | }); |
641 | 642 | } |
642 | 643 | |
644 | + /* 订单审核 */ | |
645 | + function review() { | |
646 | + var rows=$("#bootstrap-table").bootstrapTable('getSelections'); | |
647 | + if (rows.length == 0) { | |
648 | + $.modal.alertWarning("请至少选择一条记录"); | |
649 | + return; | |
650 | + } | |
651 | + var url = reviewUrl; | |
652 | + var data = { "ids": rows.map(function(v){return v.id;}).join(',') }; | |
653 | + localSubmit(url, "post", "json", data); | |
654 | + } | |
655 | + | |
643 | 656 | |
644 | 657 | /* 订单分析 */ |
645 | 658 | function analysis() { |
646 | - var rows=$("#bootstrap-table-detail").bootstrapTable('getSelections'); | |
659 | + var rows=$("#bootstrap-table").bootstrapTable('getSelections'); | |
647 | 660 | if (rows.length == 0) { |
648 | 661 | $.modal.alertWarning("请至少选择一条记录"); |
649 | 662 | return; |
... | ... |