Commit b632ea944c7178dbd603cec65e505a07e84a21ac

Authored by pengcheng
2 parents 0c614208 b9abda20

Merge remote-tracking branch 'origin/develop' into develop

Showing 53 changed files with 2834 additions and 95 deletions
.idea/MyBatisCodeHelperDatasource.xml
... ... @@ -6,9 +6,9 @@
6 6 <option name="addSerializeUid" value="true" />
7 7 <option name="generateService" value="true" />
8 8 <option name="generateServiceInterface" value="true" />
9   - <option name="javaMapperPackage" value="com.huaheng.pc.config.containerCapacityl.mapper" />
  9 + <option name="javaMapperPackage" value="com.huaheng.pc.task.taskPreference.mapper" />
10 10 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" />
11   - <option name="javaModelPackage" value="com.huaheng.pc.config.containerCapacityl.domain" />
  11 + <option name="javaModelPackage" value="com.huaheng.pc.task.taskPreference.domain" />
12 12 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" />
13 13 <option name="lastDatabaseCrudChooseModuleName" value="huaheng" />
14 14 <option name="moduleNameToPackageAndPathMap">
... ... @@ -30,15 +30,15 @@
30 30 <entry key="huaheng">
31 31 <value>
32 32 <UserPackageAndPathInfoByModule>
33   - <option name="javaMapperPackage" value="com.huaheng.pc.config.containerCapacityl.mapper" />
  33 + <option name="javaMapperPackage" value="com.huaheng.pc.task.taskPreference.mapper" />
34 34 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" />
35   - <option name="javaModelPacakge" value="com.huaheng.pc.config.containerCapacityl.domain" />
  35 + <option name="javaModelPacakge" value="com.huaheng.pc.task.taskPreference.domain" />
36 36 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" />
37   - <option name="javaServiceInterfacePackage" value="com.huaheng.pc.config.containerCapacityl.service" />
  37 + <option name="javaServiceInterfacePackage" value="com.huaheng.pc.task.taskPreference.service" />
38 38 <option name="javaServiceInterfacePath" value="$PROJECT_DIR$/src/main/java" />
39   - <option name="javaServicePackage" value="com.huaheng.pc.config.containerCapacityl.service" />
  39 + <option name="javaServicePackage" value="com.huaheng.pc.task.taskPreference.service" />
40 40 <option name="javaServicePath" value="$PROJECT_DIR$/src/main/java" />
41   - <option name="xmlPackage" value="config" />
  41 + <option name="xmlPackage" value="task" />
42 42 <option name="xmlPath" value="E:\code\wms2\src\main\resources\mybatis" />
43 43 </UserPackageAndPathInfoByModule>
44 44 </value>
... ... @@ -47,6 +47,16 @@
47 47 </option>
48 48 <option name="tableGenerateConfigs">
49 49 <map>
  50 + <entry key="wms_v2:bom_detail">
  51 + <value>
  52 + <TableGenerateConfig>
  53 + <option name="generatedKey" value="id" />
  54 + <option name="javaModelName" value="BomDetail" />
  55 + <option name="moduleName" value="huaheng" />
  56 + <option name="useActualColumnName" value="true" />
  57 + </TableGenerateConfig>
  58 + </value>
  59 + </entry>
50 60 <entry key="wms_v2:bom_header">
51 61 <value>
52 62 <TableGenerateConfig>
... ... @@ -277,6 +287,36 @@
277 287 </TableGenerateConfig>
278 288 </value>
279 289 </entry>
  290 + <entry key="wms_v2:task_detail">
  291 + <value>
  292 + <TableGenerateConfig>
  293 + <option name="generatedKey" value="id" />
  294 + <option name="javaModelName" value="TaskDetail" />
  295 + <option name="moduleName" value="huaheng" />
  296 + <option name="useActualColumnName" value="true" />
  297 + </TableGenerateConfig>
  298 + </value>
  299 + </entry>
  300 + <entry key="wms_v2:task_header">
  301 + <value>
  302 + <TableGenerateConfig>
  303 + <option name="generatedKey" value="id" />
  304 + <option name="javaModelName" value="TaskHeader" />
  305 + <option name="moduleName" value="huaheng" />
  306 + <option name="useActualColumnName" value="true" />
  307 + </TableGenerateConfig>
  308 + </value>
  309 + </entry>
  310 + <entry key="wms_v2:task_preference">
  311 + <value>
  312 + <TableGenerateConfig>
  313 + <option name="generatedKey" value="id" />
  314 + <option name="javaModelName" value="TaskPreference" />
  315 + <option name="moduleName" value="huaheng" />
  316 + <option name="useActualColumnName" value="true" />
  317 + </TableGenerateConfig>
  318 + </value>
  319 + </entry>
280 320 <entry key="wms_v2:zone_capacity">
281 321 <value>
282 322 <TableGenerateConfig>
... ... @@ -293,7 +333,7 @@
293 333 <option name="useLomBokOnModel" value="true" />
294 334 <option name="useSwagger" value="true" />
295 335 <option name="userMybatisPlus" value="true" />
296   - <option name="xmlMapperPackage" value="config" />
  336 + <option name="xmlMapperPackage" value="task" />
297 337 <option name="xmlMapperPath" value="E:\code\wms2\src\main\resources\mybatis" />
298 338 </ProjectProfile>
299 339 </option>
... ...
.idea/workspace.xml
... ... @@ -2,16 +2,19 @@
2 2 <project version="4">
3 3 <component name="ChangeListManager">
4 4 <list default="true" id="9ff7b25e-dc1a-4859-8a0c-00039489e359" name="Default Changelist" comment="">
  5 + <change afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomDetail/add.html" afterDir="false" />
  6 + <change afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomDetail/bomDetail.html" afterDir="false" />
  7 + <change afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomDetail/edit.html" afterDir="false" />
  8 + <change afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomHeader/add.html" afterDir="false" />
  9 + <change afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomHeader/edit.html" afterDir="false" />
5 10 <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
6   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/company/service/CompanyService.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/company/service/CompanyService.java" afterDir="false" />
7   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/company/service/CompanyServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/company/service/CompanyServiceImpl.java" afterDir="false" />
8   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/domain/Material.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/domain/Material.java" afterDir="false" />
9   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/materialUnit/service/MaterialUnitService.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/materialUnit/service/MaterialUnitService.java" afterDir="false" />
10   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/materialUnit/service/MaterialUnitServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/materialUnit/service/MaterialUnitServiceImpl.java" afterDir="false" />
11   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/system/role/domain/Role.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/system/role/domain/Role.java" afterDir="false" />
12   - <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/system/user/controller/UserController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/system/user/controller/UserController.java" afterDir="false" />
13   - <change beforePath="$PROJECT_DIR$/src/main/resources/templates/general/material/add.html" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/resources/templates/general/material/add.html" afterDir="false" />
14   - <change beforePath="$PROJECT_DIR$/src/main/resources/templates/general/material/edit.html" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/resources/templates/general/material/edit.html" afterDir="false" />
  11 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeService.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeService.java" afterDir="false" />
  12 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeServiceImpl.java" afterDir="false" />
  13 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/bom/controller/BomDetailController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/bom/controller/BomDetailController.java" afterDir="false" />
  14 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/bom/controller/BomHeaderController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/bom/controller/BomHeaderController.java" afterDir="false" />
  15 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/location/service/LocationServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/location/service/LocationServiceImpl.java" afterDir="false" />
  16 + <change beforePath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/controller/MaterialController.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/controller/MaterialController.java" afterDir="false" />
  17 + <change beforePath="$PROJECT_DIR$/src/main/resources/templates/general/bomHeader/bomHeader.html" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/resources/templates/general/bomHeader/bomHeader.html" afterDir="false" />
15 18 </list>
16 19 <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
17 20 <option name="SHOW_DIALOG" value="false" />
... ... @@ -51,7 +54,14 @@
51 54 <item name="@172.16.29.45" type="feb32156:DbDataSourceImpl" />
52 55 <item name="schemas" type="d4e8921:DatabaseStructure$FamilyGroup" />
53 56 <item name="wms_v2: schema" type="76f4a085:MysqlImplModel$Schema" />
54   - <item name="company: table" type="285a2a93:MysqlImplModel$Table" />
  57 + <item name="bom_detail: table" type="285a2a93:MysqlImplModel$Table" />
  58 + </path>
  59 + <path>
  60 + <item name="Database" type="3277223f:DatabaseStructure$DbRootGroup" />
  61 + <item name="@172.16.29.45" type="feb32156:DbDataSourceImpl" />
  62 + <item name="schemas" type="d4e8921:DatabaseStructure$FamilyGroup" />
  63 + <item name="wms_v2: schema" type="76f4a085:MysqlImplModel$Schema" />
  64 + <item name="location_type: table" type="285a2a93:MysqlImplModel$Table" />
55 65 </path>
56 66 </expand>
57 67 <select />
... ... @@ -60,6 +70,7 @@
60 70 <option name="RECENT_TEMPLATES">
61 71 <list>
62 72 <option value="Class" />
  73 + <option value="HTML File" />
63 74 </list>
64 75 </option>
65 76 </component>
... ... @@ -85,6 +96,7 @@
85 96 <component name="PropertiesComponent">
86 97 <property name="ASKED_ADD_EXTERNAL_FILES" value="true" />
87 98 <property name="DatabaseDriversLRU" value="mysql" />
  99 + <property name="DefaultHtmlFileTemplate" value="HTML File" />
88 100 <property name="ExpandSpringBootJavaOptionsPanel" value="true" />
89 101 <property name="RequestMappingsPanelOrder0" value="0" />
90 102 <property name="RequestMappingsPanelOrder1" value="1" />
... ... @@ -100,6 +112,7 @@
100 112 <property name="node.js.path.for.package.tslint" value="project" />
101 113 <property name="node.js.selected.package.eslint" value="(autodetect)" />
102 114 <property name="node.js.selected.package.tslint" value="(autodetect)" />
  115 + <property name="nodejs_package_manager_path" value="npm" />
103 116 <property name="settings.editor.selected.configurable" value="preferences.pluginManager" />
104 117 </component>
105 118 <component name="RecentsManager">
... ... @@ -153,7 +166,7 @@
153 166 <expand>
154 167 <path>
155 168 <item name="services root" type="e789fda9:ObjectUtils$Sentinel" />
156   - <item name="com.intellij.execution.services.ServiceModel$ServiceGroupNode@21a8d0c6" type="7427dc5b:ServiceModel$ServiceGroupNode" />
  169 + <item name="com.intellij.execution.services.ServiceModel$ServiceGroupNode@6299c693" type="7427dc5b:ServiceModel$ServiceGroupNode" />
157 170 </path>
158 171 </expand>
159 172 <select />
... ... @@ -179,7 +192,10 @@
179 192 <workItem from="1565328536669" duration="797000" />
180 193 <workItem from="1565345715376" duration="452000" />
181 194 <workItem from="1565570424829" duration="11663000" />
182   - <workItem from="1565587737758" duration="4606000" />
  195 + <workItem from="1565587737758" duration="12961000" />
  196 + <workItem from="1565657307503" duration="115000" />
  197 + <workItem from="1565657439247" duration="2447000" />
  198 + <workItem from="1565662229227" duration="19207000" />
183 199 </task>
184 200 <task id="LOCAL-00001" summary="添加库位、库位类型增删改查接口">
185 201 <created>1565226427512</created>
... ... @@ -223,7 +239,35 @@
223 239 <option name="project" value="LOCAL" />
224 240 <updated>1565578920011</updated>
225 241 </task>
226   - <option name="localTasksCounter" value="7" />
  242 + <task id="LOCAL-00007" summary="添加物料页面">
  243 + <created>1565593159103</created>
  244 + <option name="number" value="00007" />
  245 + <option name="presentableId" value="LOCAL-00007" />
  246 + <option name="project" value="LOCAL" />
  247 + <updated>1565593159103</updated>
  248 + </task>
  249 + <task id="LOCAL-00008" summary="添加商品详情">
  250 + <created>1565598117104</created>
  251 + <option name="number" value="00008" />
  252 + <option name="presentableId" value="LOCAL-00008" />
  253 + <option name="project" value="LOCAL" />
  254 + <updated>1565598117104</updated>
  255 + </task>
  256 + <task id="LOCAL-00009" summary="添加物料时判断单位是否存在,不存在则添加物料单位">
  257 + <created>1565659672152</created>
  258 + <option name="number" value="00009" />
  259 + <option name="presentableId" value="LOCAL-00009" />
  260 + <option name="project" value="LOCAL" />
  261 + <updated>1565659672152</updated>
  262 + </task>
  263 + <task id="LOCAL-00010" summary="添加task实体类">
  264 + <created>1565665525508</created>
  265 + <option name="number" value="00010" />
  266 + <option name="presentableId" value="LOCAL-00010" />
  267 + <option name="project" value="LOCAL" />
  268 + <updated>1565665525508</updated>
  269 + </task>
  270 + <option name="localTasksCounter" value="11" />
227 271 <servers />
228 272 </component>
229 273 <component name="TypeScriptGeneratedFilesManager">
... ... @@ -263,15 +307,29 @@
263 307 <MESSAGE value="Merge branch 'develop' of http://172.16.29.40:8010/wms/wms2 into develop&#10;&#10;# Conflicts:&#10;#&#9;.idea/workspace.xml" />
264 308 <MESSAGE value="添加userWarehouse" />
265 309 <MESSAGE value="添加containerCapacity" />
266   - <option name="LAST_COMMIT_MESSAGE" value="添加containerCapacity" />
  310 + <MESSAGE value="添加物料页面" />
  311 + <MESSAGE value="添加商品详情" />
  312 + <MESSAGE value="添加物料时判断单位是否存在,不存在则添加物料单位" />
  313 + <MESSAGE value="添加task实体类" />
  314 + <option name="LAST_COMMIT_MESSAGE" value="添加task实体类" />
267 315 </component>
268 316 <component name="XDebuggerManager">
269 317 <breakpoint-manager>
270 318 <breakpoints>
271 319 <line-breakpoint enabled="true" type="java-line">
  320 + <url>file://$PROJECT_DIR$/src/main/java/com/huaheng/pc/system/user/controller/UserController.java</url>
  321 + <line>88</line>
  322 + <option name="timeStamp" value="3" />
  323 + </line-breakpoint>
  324 + <line-breakpoint enabled="true" type="java-line">
  325 + <url>file://$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/controller/MaterialController.java</url>
  326 + <line>69</line>
  327 + <option name="timeStamp" value="6" />
  328 + </line-breakpoint>
  329 + <line-breakpoint enabled="true" type="java-line">
272 330 <url>file://$PROJECT_DIR$/src/main/java/com/huaheng/pc/general/material/controller/MaterialController.java</url>
273   - <line>107</line>
274   - <option name="timeStamp" value="1" />
  331 + <line>123</line>
  332 + <option name="timeStamp" value="7" />
275 333 </line-breakpoint>
276 334 </breakpoints>
277 335 </breakpoint-manager>
... ...
src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeService.java
... ... @@ -7,4 +7,6 @@ import java.util.List;
7 7 import java.util.Map;
8 8  
9 9 public interface LocationTypeService extends IService<LocationType>{
  10 +
  11 + public List<Map<String, Object>> getLocationPrefix();
10 12 }
... ...
src/main/java/com/huaheng/pc/config/locationType/service/LocationTypeServiceImpl.java
... ... @@ -2,11 +2,11 @@ package com.huaheng.pc.config.locationType.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;
6   -import org.springframework.stereotype.Service;
7 5 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
8   -import com.huaheng.pc.config.locationType.mapper.LocationTypeMapper;
  6 +import com.huaheng.common.utils.security.ShiroUtils;
9 7 import com.huaheng.pc.config.locationType.domain.LocationType;
  8 +import com.huaheng.pc.config.locationType.mapper.LocationTypeMapper;
  9 +import org.springframework.stereotype.Service;
10 10  
11 11 import java.util.List;
12 12 import java.util.Map;
... ... @@ -14,4 +14,11 @@ import java.util.Map;
14 14 @Service("locationType")
15 15 public class LocationTypeServiceImpl extends ServiceImpl<LocationTypeMapper, LocationType> implements LocationTypeService{
16 16  
  17 + public List<Map<String, Object>> getLocationPrefix(){
  18 + LambdaQueryWrapper<LocationType> lambdaQueryWrapper = Wrappers.lambdaQuery();
  19 + lambdaQueryWrapper.eq(LocationType::getWarehouseCode, ShiroUtils.getWarehouseCode())
  20 + .eq(LocationType::getEnable, false)
  21 + .eq(LocationType::getEnable, true);
  22 + return this.listMaps(lambdaQueryWrapper);
  23 + }
17 24 }
... ...
src/main/java/com/huaheng/pc/general/bom/controller/BomDetailController.java
1 1 package com.huaheng.pc.general.bom.controller;
2 2  
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.metadata.IPage;
  5 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
  6 +import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  7 +import com.huaheng.common.support.Convert;
  8 +import com.huaheng.common.utils.StringUtils;
  9 +import com.huaheng.common.utils.security.ShiroUtils;
  10 +import com.huaheng.framework.aspectj.lang.annotation.Log;
  11 +import com.huaheng.framework.aspectj.lang.constant.BusinessType;
  12 +import com.huaheng.framework.web.controller.BaseController;
  13 +import com.huaheng.framework.web.domain.AjaxResult;
  14 +import com.huaheng.framework.web.page.PageDomain;
  15 +import com.huaheng.framework.web.page.TableDataInfo;
  16 +import com.huaheng.framework.web.page.TableSupport;
3 17 import com.huaheng.pc.general.bom.domain.BomDetail;
4 18 import com.huaheng.pc.general.bom.service.BomDetailService;
  19 +import com.huaheng.pc.general.material.domain.Material;
  20 +import com.huaheng.pc.general.material.service.MaterialService;
  21 +import io.swagger.annotations.ApiOperation;
  22 +import io.swagger.annotations.ApiParam;
  23 +import org.apache.shiro.authz.annotation.RequiresPermissions;
5 24 import org.springframework.stereotype.Controller;
6   -import org.springframework.web.bind.annotation.RequestMapping;
  25 +import org.springframework.ui.ModelMap;
  26 +import org.springframework.web.bind.annotation.*;
7 27  
8 28 import javax.annotation.Resource;
  29 +import java.util.ArrayList;
  30 +import java.util.List;
9 31  
10 32 @Controller
11 33 @RequestMapping("/general/bomDetail")
12   -public class BomDetailController {
  34 +public class BomDetailController extends BaseController {
13 35  
14 36 private String prefix = "general/bomDetail";
15 37  
16 38 @Resource
17 39 private BomDetailService bomDetailService;
  40 + @Resource
  41 + private MaterialService materialService;
  42 +
  43 + @RequiresPermissions("general:bomHeader:view")
  44 + @Log(title = "管理-推送详情列表", operating = "推送详情列表", action = BusinessType.GRANT)
  45 + @GetMapping("/list/{id}")
  46 + public String list(@PathVariable("id")Integer id, ModelMap mmap) {
  47 + mmap.put("bomHeaderId",id);
  48 + return prefix+"/bomDetail";
  49 + }
  50 +
  51 + /**
  52 + * 查询商品详情
  53 + */
  54 + @ApiOperation(value="查看商品列表", notes="根据商品id获取商品详情信息", httpMethod = "POST")
  55 + @RequiresPermissions("general:bomHeader:list")
  56 + @Log(title = "通用-商品管理", operating = "查看商品列表", action = BusinessType.GRANT)
  57 + @PostMapping("/list")
  58 + @ResponseBody
  59 + public TableDataInfo list(@ApiParam(name="bomId",value="商品ID") Integer bomId) {
  60 + LambdaQueryWrapper<BomDetail> lambdaQueryWrapper = Wrappers.lambdaQuery();
  61 + PageDomain pageDomain = TableSupport.buildPageRequest();
  62 + Integer pageNum = pageDomain.getPageNum();
  63 + Integer pageSize = pageDomain.getPageSize();
  64 + lambdaQueryWrapper.eq(BomDetail::getBomId, bomId);
  65 + if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
  66 + /*使用分页查询*/
  67 + Page<BomDetail> page = new Page<>(pageNum, pageSize);
  68 + IPage<BomDetail> iPage = bomDetailService.page(page, lambdaQueryWrapper);
  69 + return getMpDataTable(iPage.getRecords(), iPage.getTotal());
  70 + } else {
  71 + List<BomDetail> list = bomDetailService.list(lambdaQueryWrapper);
  72 + return getDataTable(list);
  73 + }
  74 + }
  75 +
  76 + /**
  77 + * 新增商品详情
  78 + */
  79 + @GetMapping("/add")
  80 + public String add() {
  81 + return prefix + "/add";
  82 + }
  83 +
  84 + /**
  85 + * 新增保存商品
  86 + */
  87 + @ApiOperation(value="新增商品详情", notes="新增商品详情", httpMethod = "POST")
  88 + @RequiresPermissions("general:bomDetail:add")
  89 + @Log(title = "通用-商品", operating = "新增商品", action = BusinessType.INSERT)
  90 + @PostMapping("/add")
  91 + @ResponseBody
  92 + public AjaxResult addSave(@ApiParam(name = "containerType", value = "商品详情", required = true)
  93 + BomDetail bomDetail) {
  94 + LambdaQueryWrapper<Material> lamdba = Wrappers.lambdaQuery();
  95 + lamdba.eq(Material::getCode, bomDetail.getMaterialCode());
  96 + Material material = materialService.getOne(lamdba);
  97 + if ( material == null){
  98 + return AjaxResult.error("不存在物料编码"+bomDetail.getMaterialCode());
  99 + } else {
  100 + bomDetail.setCompanyCode(material.getCompanyCode());
  101 + bomDetail.setWarehouseCode(material.getWarehouseCode());
  102 + bomDetail.setMaterialCode(material.getCode());
  103 + bomDetail.setMaterialName(material.getName());
  104 + bomDetail.setMaterialUnit(material.getUnit());
  105 + bomDetail.setCreatedBy(ShiroUtils.getLoginName());
  106 + bomDetail.setLastUpdatedBy(ShiroUtils.getLoginName());
  107 + }
  108 + return toAjax(bomDetailService.save(bomDetail));
  109 + }
  110 +
  111 + /**
  112 + * 修改商品详情
  113 + */
  114 + @GetMapping("/edit/{id}")
  115 + public String edit(@PathVariable("id") Integer id, ModelMap mmap) {
  116 + mmap.put("bomDetail", bomDetailService.getById(id));
  117 + return prefix + "/edit";
  118 + }
  119 +
  120 + /**
  121 + * 修改保存商品详情
  122 + */
  123 + @ApiOperation(value="修改商品详情", notes="修改商品详情", httpMethod = "POST")
  124 + @RequiresPermissions("general:BomDetail:edit")
  125 + @Log(title = "通用-商品详情", operating = "修改商品详情", action = BusinessType.UPDATE)
  126 + @PostMapping("/edit")
  127 + @ResponseBody
  128 + public AjaxResult editSave(
  129 + @ApiParam(name = "BomDetail", value = "商品详情实体类", required = true)BomDetail bomDetail) {
  130 + return toAjax(bomDetailService.updateById(bomDetail));
  131 + }
  132 +
  133 + /**
  134 + * 删除商品详情
  135 + */
  136 + @ApiOperation(value="删除商品详情", notes="根据id批量删除商品详情,参数示例1,2,3", httpMethod = "POST")
  137 + @RequiresPermissions("general:BomDetail:remove")
  138 + @Log(title = "通用-商品", operating = "删除商品", action = BusinessType.DELETE)
  139 + @PostMapping( "/remove")
  140 + @ResponseBody
  141 + public AjaxResult remove(String ids) {
  142 + if (StringUtils.isEmpty(ids)){
  143 + return AjaxResult.error("id不能为空");
  144 + }
  145 + List<Integer> list = new ArrayList<>();
  146 + for (Integer id : Convert.toIntArray(ids)) {
  147 + list.add(id);
  148 + }
  149 + return toAjax(bomDetailService.removeByIds(list));
  150 + }
18 151 }
... ...
src/main/java/com/huaheng/pc/general/bom/controller/BomHeaderController.java
... ... @@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
6 6 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
7 7 import com.huaheng.common.support.Convert;
8 8 import com.huaheng.common.utils.StringUtils;
  9 +import com.huaheng.common.utils.security.ShiroUtils;
9 10 import com.huaheng.framework.aspectj.lang.annotation.Log;
10 11 import com.huaheng.framework.aspectj.lang.constant.BusinessType;
11 12 import com.huaheng.framework.web.controller.BaseController;
... ... @@ -17,6 +18,8 @@ import com.huaheng.pc.general.bom.domain.BomDetail;
17 18 import com.huaheng.pc.general.bom.domain.BomHeader;
18 19 import com.huaheng.pc.general.bom.service.BomDetailService;
19 20 import com.huaheng.pc.general.bom.service.BomHeaderService;
  21 +import com.huaheng.pc.general.material.domain.Material;
  22 +import com.huaheng.pc.general.material.service.MaterialService;
20 23 import io.swagger.annotations.ApiOperation;
21 24 import io.swagger.annotations.ApiParam;
22 25 import org.apache.shiro.authz.annotation.RequiresPermissions;
... ... @@ -40,9 +43,13 @@ public class BomHeaderController extends BaseController {
40 43 @Resource
41 44 private BomDetailService bomDetailService;
42 45  
  46 + @Resource
  47 + private MaterialService materialService;
  48 +
43 49 @RequiresPermissions("general:bomHeader:view")
44 50 @GetMapping()
45   - public String company() {
  51 + public String bomHeader() {
  52 + System.out.println("商品管理");
46 53 return prefix + "/bomHeader";
47 54 }
48 55  
... ... @@ -97,6 +104,22 @@ public class BomHeaderController extends BaseController {
97 104 @ResponseBody
98 105 public AjaxResult addSave(@ApiParam(name = "containerType", value = "商品类型", required = true)
99 106 BomHeader bomHeader) {
  107 +
  108 + LambdaQueryWrapper<Material> lamdba = Wrappers.lambdaQuery();
  109 + lamdba.eq(Material::getCode, bomHeader.getMaterialCode());
  110 + Material material = materialService.getOne(lamdba);
  111 + if ( material == null){
  112 + return AjaxResult.error("不存在物料编码"+bomHeader.getMaterialCode());
  113 + } else {
  114 + bomHeader.setCompanyCode(material.getCompanyCode());
  115 + bomHeader.setWarehouseCode(material.getWarehouseCode());
  116 + bomHeader.setMaterialCode(material.getCode());
  117 + bomHeader.setMaterialName(material.getName());
  118 + bomHeader.setMaterialSpec(material.getSpec());
  119 + bomHeader.setMaterialUnit(material.getUnit());
  120 + bomHeader.setCreatedBy(ShiroUtils.getLoginName());
  121 + bomHeader.setLastUpdatedBy(ShiroUtils.getLoginName());
  122 + }
100 123 return toAjax(bomHeaderService.save(bomHeader));
101 124 }
102 125  
... ...
src/main/java/com/huaheng/pc/general/company/service/CompanyService.java
... ... @@ -11,7 +11,7 @@ public interface CompanyService extends IService&lt;Company&gt;{
11 11  
12 12 public List<Company> selectCompanyByCurrentUserId();
13 13  
14   - public List<Company> selectCompanyByUserId();
  14 + public List<Company> selectCompanyByUserId(Integer id);
15 15  
16 16 public AjaxResult addCompany(Company company);
17 17  
... ...
src/main/java/com/huaheng/pc/general/company/service/CompanyServiceImpl.java
... ... @@ -39,9 +39,9 @@ public class CompanyServiceImpl extends ServiceImpl&lt;CompanyMapper, Company&gt; impl
39 39 * @return
40 40 */
41 41 @Override
42   - public List<Company> selectCompanyByUserId() {
  42 + public List<Company> selectCompanyByUserId(Integer id) {
43 43 UserCompany condition = new UserCompany();
44   - condition.setUserId(ShiroUtils.getUserId());
  44 + condition.setUserId(id);
45 45 List<UserCompany> userCompanys = userCompanyMapper.selectListEntityByEqual(condition);
46 46 Company company = new Company();
47 47 company.setWarehouseCode(ShiroUtils.getWarehouseCode());
... ...
src/main/java/com/huaheng/pc/general/location/service/LocationServiceImpl.java
... ... @@ -51,7 +51,7 @@ public class LocationServiceImpl extends ServiceImpl&lt;LocationMapper, Location&gt; i
51 51 throw new ServiceException("库区编码不存在");
52 52 }
53 53  
54   -
  54 + String prefix = location.getLocationType().substring(1);
55 55 List<Location> locations = new ArrayList<>();
56 56 for (int i=1; i<=location.getIRow().intValue(); i++) {
57 57 for (int j=1; j<=location.getIColumn().intValue(); j++) {
... ... @@ -70,7 +70,7 @@ public class LocationServiceImpl extends ServiceImpl&lt;LocationMapper, Location&gt; i
70 70 param.setCreatedBy(ShiroUtils.getLoginName());
71 71 param.setLastUpdatedBy(ShiroUtils.getLoginName());
72 72 String code = MessageFormat.format("{0}{1}-{2}-{3}-{4}",
73   - location.getLocationType(),
  73 + prefix,
74 74 String.format("%02d", i),
75 75 String.format("%02d", j),
76 76 String.format("%02d", k),
... ...
src/main/java/com/huaheng/pc/general/material/controller/MaterialController.java
... ... @@ -18,6 +18,8 @@ import com.huaheng.pc.general.location.domain.Location;
18 18 import com.huaheng.pc.general.location.service.LocationService;
19 19 import com.huaheng.pc.general.material.domain.Material;
20 20 import com.huaheng.pc.general.material.service.MaterialService;
  21 +import com.huaheng.pc.general.materialUnit.domain.MaterialUnit;
  22 +import com.huaheng.pc.general.materialUnit.service.MaterialUnitService;
21 23 import com.huaheng.pc.receipt.receiptDetail.domain.ReceiptDetail;
22 24 import io.swagger.annotations.Api;
23 25 import io.swagger.annotations.ApiOperation;
... ... @@ -41,6 +43,9 @@ public class MaterialController extends BaseController {
41 43 @Resource
42 44 private MaterialService materialService;
43 45  
  46 + @Resource
  47 + private MaterialUnitService materialUnitService;
  48 +
44 49 @RequiresPermissions("general:material:view")
45 50 @GetMapping()
46 51 public String material() {
... ... @@ -74,7 +79,7 @@ public class MaterialController extends BaseController {
74 79 .like(StringUtils.isNotEmpty(material.getSpec()), Material::getSpec, material.getSpec())
75 80 .eq(Material::getWarehouseCode, ShiroUtils.getWarehouseCode())
76 81 .in(Material::getCompanyCode, ShiroUtils.getCompanyCodeList())
77   - .ne(Material::getDeleted, false);
  82 + .eq(Material::getDeleted, false);
78 83  
79 84 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
80 85 /*使用分页查询*/
... ... @@ -113,6 +118,22 @@ public class MaterialController extends BaseController {
113 118 if (map != null) {
114 119 return AjaxResult.error("物料已经存在");
115 120 }
  121 + LambdaQueryWrapper<MaterialUnit> lambdaQueryWrapper = Wrappers.lambdaQuery();
  122 + lambdaQueryWrapper.eq(MaterialUnit::getMaterialCode, material.getCode())
  123 + .eq(MaterialUnit::getUnit, material.getUnit());
  124 + if (materialUnitService.getOne(lambdaQueryWrapper) == null){
  125 + MaterialUnit materialUnit = new MaterialUnit();
  126 + materialUnit.setMaterialCode(material.getCode());
  127 + materialUnit.setMaterialName(material.getName());
  128 + materialUnit.setMaterialSpec(material.getSpec());
  129 + materialUnit.setCompanyCode(material.getCompanyCode());
  130 + materialUnit.setWarehouseCode(ShiroUtils.getWarehouseCode());
  131 + materialUnit.setUnit(material.getUnit());
  132 + materialUnit.setCreatedBy(ShiroUtils.getLoginName());
  133 + materialUnit.setLastUpdatedBy(ShiroUtils.getLoginName());
  134 +
  135 + materialUnitService.save(materialUnit);
  136 + }
116 137  
117 138 material.setWarehouseCode(ShiroUtils.getWarehouseCode());
118 139 material.setCreatedBy(ShiroUtils.getLoginName());
... ...
src/main/java/com/huaheng/pc/general/warehouse/domain/Warehouse.java
... ... @@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.annotation.TableField;
5 5 import com.baomidou.mybatisplus.annotation.TableId;
6 6 import com.baomidou.mybatisplus.annotation.TableName;
7 7 import lombok.Data;
  8 +import org.springframework.transaction.annotation.Transactional;
8 9  
9 10 import java.io.Serializable;
10 11 import java.util.Date;
... ... @@ -84,6 +85,15 @@ public class Warehouse implements Serializable {
84 85 @TableField(value = "email")
85 86 private String email;
86 87  
  88 + public boolean isFlag() {
  89 + return flag;
  90 + }
  91 +
  92 + public Warehouse setFlag(boolean flag) {
  93 + this.flag = flag;
  94 + return this;
  95 + }
  96 +
87 97 /**
88 98 * 上位系统url地址
89 99 */
... ... @@ -189,6 +199,10 @@ public class Warehouse implements Serializable {
189 199 @TableField(value = "deleted")
190 200 private Boolean deleted;
191 201  
  202 + /** 用户是否存在此仓库标识 默认不存在 */
  203 + @TableField(exist = false)
  204 + private boolean flag = false;
  205 +
192 206 private static final long serialVersionUID = 1L;
193 207  
194 208 public static final String COL_ADDRESS1 = "address1";
... ...
src/main/java/com/huaheng/pc/general/warehouse/mapper/WarehouseMapper.java
... ... @@ -2,6 +2,16 @@ package com.huaheng.pc.general.warehouse.mapper;
2 2  
3 3 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4 4 import com.huaheng.pc.general.warehouse.domain.Warehouse;
  5 +import com.huaheng.pc.system.role.domain.Role;
  6 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
  7 +
  8 +import java.util.List;
5 9  
6 10 public interface WarehouseMapper extends BaseMapper<Warehouse> {
  11 +
  12 + public List<SysUserWarehouse> wareHouseAll();
  13 +
  14 + public List<Warehouse> selectWarehouseByUserId(Integer userId);
  15 +
  16 + public List<Warehouse> selectWarehouseAll();
7 17 }
8 18 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/general/warehouse/service/WarehouseService.java
... ... @@ -2,6 +2,7 @@ package com.huaheng.pc.general.warehouse.service;
2 2  
3 3 import com.huaheng.pc.general.warehouse.domain.Warehouse;
4 4 import com.baomidou.mybatisplus.extension.service.IService;
  5 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
5 6  
6 7 import java.util.List;
7 8 import java.util.Map;
... ... @@ -9,4 +10,9 @@ import java.util.Map;
9 10 public interface WarehouseService extends IService<Warehouse>{
10 11  
11 12 List<Map<String,Object>> getWarehouseList(Integer id);
  13 +
  14 + public List<Warehouse> selectWarehouseByUserId(Integer userId);
  15 +
  16 +
  17 +
12 18 }
... ...
src/main/java/com/huaheng/pc/general/warehouse/service/WarehouseServiceImpl.java
... ... @@ -2,8 +2,11 @@ package com.huaheng.pc.general.warehouse.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 com.huaheng.pc.general.warehouseCopany.domain.WarehouseCompany;
6 7 import com.huaheng.pc.general.warehouseCopany.service.WarehouseCompanyService;
  8 +import com.huaheng.pc.system.role.domain.Role;
  9 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
7 10 import org.springframework.stereotype.Service;
8 11 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
9 12 import com.huaheng.pc.general.warehouse.mapper.WarehouseMapper;
... ... @@ -47,4 +50,24 @@ public class WarehouseServiceImpl extends ServiceImpl&lt;WarehouseMapper, Warehouse
47 50 }
48 51 return warehouseList;
49 52 }
  53 +
  54 + @Override
  55 + public List<Warehouse> selectWarehouseByUserId(Integer userId)
  56 + {
  57 + List<Warehouse> userWarhouses = warehouseMapper.selectWarehouseByUserId(userId);
  58 + List<Warehouse> warehouses = warehouseMapper.selectWarehouseAll();
  59 + for (Warehouse warehouse : warehouses)
  60 + {
  61 + for (Warehouse userWarehouse: userWarhouses)
  62 + {
  63 + if (warehouse.getCode().equals(userWarehouse.getCode()))
  64 + {
  65 + warehouse.setFlag(true);
  66 + break;
  67 + }
  68 + }
  69 + }
  70 + return warehouses;
  71 + }
  72 +
50 73 }
... ...
src/main/java/com/huaheng/pc/system/user/controller/UserController.java
... ... @@ -2,11 +2,22 @@ package com.huaheng.pc.system.user.controller;
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.constant.Constants;
  6 +import com.huaheng.common.utils.MessageUtils;
  7 +import com.huaheng.common.utils.SystemLogUtils;
5 8 import com.huaheng.common.utils.security.ShiroUtils;
  9 +import com.huaheng.framework.shiro.web.filter.LogoutFilter;
6 10 import com.huaheng.pc.general.company.domain.Company;
7 11 import com.huaheng.pc.general.company.service.CompanyService;
  12 +import com.huaheng.pc.general.warehouse.domain.Warehouse;
  13 +import com.huaheng.pc.general.warehouse.mapper.WarehouseMapper;
  14 +import com.huaheng.pc.general.warehouse.service.WarehouseService;
  15 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
8 16 import org.apache.shiro.authz.annotation.RequiresPermissions;
  17 +import org.apache.shiro.session.SessionException;
  18 +import org.apache.shiro.subject.Subject;
9 19 import org.springframework.beans.factory.annotation.Autowired;
  20 +import org.springframework.boot.web.servlet.server.Session;
10 21 import org.springframework.stereotype.Controller;
11 22 import org.springframework.transaction.annotation.Transactional;
12 23 import org.springframework.ui.ModelMap;
... ... @@ -25,7 +36,14 @@ import com.huaheng.framework.web.page.TableDataInfo;
25 36 import com.huaheng.pc.system.role.service.IRoleService;
26 37 import com.huaheng.pc.system.user.domain.User;
27 38 import com.huaheng.pc.system.user.service.IUserService;
  39 +
  40 +import javax.annotation.Resource;
  41 +import javax.servlet.ServletRequest;
  42 +import javax.servlet.ServletResponse;
28 43 import java.util.List;
  44 +import java.util.Map;
  45 +
  46 +import static javax.security.auth.Subject.getSubject;
29 47  
30 48 /**
31 49 * 用户信息
... ... @@ -47,6 +65,12 @@ public class UserController extends BaseController
47 65 @Autowired
48 66 private CompanyService companyService;
49 67  
  68 + @Autowired
  69 + private WarehouseService warehouseService;
  70 +
  71 + @Resource
  72 + private WarehouseMapper warehouseMapper;
  73 +
50 74 @RequiresPermissions("system:user:view")
51 75 @GetMapping()
52 76 public String user()
... ... @@ -94,6 +118,13 @@ public class UserController extends BaseController
94 118 mmap.put("roles", roleService.selectRoleAll());
95 119 LambdaQueryWrapper<Company> lambdaQueryWrapper = Wrappers.lambdaQuery(company);
96 120 mmap.put("companys", companyService.list(lambdaQueryWrapper));
  121 + LambdaQueryWrapper<Warehouse> warehouse = Wrappers.lambdaQuery();
  122 + warehouse.select(Warehouse::getCode,Warehouse::getName,Warehouse::getEnable);
  123 + List<Map<String, Object>> warehouseList = warehouseService.listMaps(warehouse);
  124 + for (Map<String, Object> item : warehouseList){
  125 + item.put("value",item.get("code").toString());
  126 + }
  127 + mmap.put("warehouseList",warehouseList);
97 128 return prefix + "/add";
98 129 }
99 130  
... ... @@ -123,7 +154,8 @@ public class UserController extends BaseController
123 154 {
124 155 mmap.put("user", userService.selectUserById(id));
125 156 mmap.put("roles", roleService.selectRolesByUserId(id));
126   - mmap.put("companys", companyService.selectCompanyByUserId());
  157 + mmap.put("companys", companyService.selectCompanyByUserId(id));
  158 + mmap.put("warehouses", warehouseService.selectWarehouseByUserId(id));
127 159 return prefix + "/edit";
128 160 }
129 161  
... ... @@ -137,11 +169,16 @@ public class UserController extends BaseController
137 169 @ResponseBody
138 170 public AjaxResult editSave(User user)
139 171 {
  172 +
140 173 if (StringUtils.isNotNull(user.getId()) && User.isAdmin(user.getId()))
141 174 {
142 175 return error("不允许修改超级管理员用户");
143 176 }
144 177 AjaxResult ajaxResult = toAjax(userService.updateUser(user));
  178 +
  179 + if (ShiroUtils.getLoginName().equals(user.getUserName()))
  180 + ShiroUtils.logout();
  181 +
145 182 return ajaxResult;
146 183 }
147 184  
... ...
src/main/java/com/huaheng/pc/system/userWarehouse/domain/SysUserWarehouse.java renamed to src/main/java/com/huaheng/pc/system/user/domain/SysUserWarehouse.java
1   -package com.huaheng.pc.system.userWarehouse.domain;
  1 +package com.huaheng.pc.system.user.domain;
2 2  
3 3 import com.baomidou.mybatisplus.annotation.IdType;
4 4 import com.baomidou.mybatisplus.annotation.TableField;
... ... @@ -6,9 +6,10 @@ import com.baomidou.mybatisplus.annotation.TableId;
6 6 import com.baomidou.mybatisplus.annotation.TableName;
7 7 import io.swagger.annotations.ApiModel;
8 8 import io.swagger.annotations.ApiModelProperty;
9   -import java.io.Serializable;
10 9 import lombok.Data;
11 10  
  11 +import java.io.Serializable;
  12 +
12 13 @ApiModel(value="com.huaheng.pc.system.userWarehousel.domain.SysUserWarehouse")
13 14 @Data
14 15 @TableName(value = "sys_user_warehouse")
... ...
src/main/java/com/huaheng/pc/system/user/domain/User.java
... ... @@ -112,6 +112,9 @@ public class User
112 112 /** 货主编码列表 */
113 113 private List<String> companyCodeList;
114 114  
  115 + /** 仓库编码列表 */
  116 + private List<String> warehouseCodeList;
  117 +
115 118 /** 搜索值 */
116 119 private String searchValue;
117 120  
... ...
src/main/java/com/huaheng/pc/system/user/mapper/SysUserWarehouseMapper.java 0 → 100644
  1 +package com.huaheng.pc.system.user.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
  5 +import org.apache.ibatis.annotations.Param;
  6 +
  7 +import java.util.List;
  8 +
  9 +
  10 +public interface SysUserWarehouseMapper extends BaseMapper<SysUserWarehouse> {
  11 +
  12 + public int batchUserWarehouse(@Param("userWarehouseList") List<SysUserWarehouse> userWarehouseList);
  13 +
  14 + public int deleteUserWarehouseByUserId(Integer userId);
  15 +
  16 +}
0 17 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/system/user/mapper/UserMapper.java
... ... @@ -132,6 +132,14 @@ public interface UserMapper
132 132 */
133 133 public List<Map<String, Object>> getWarehouseByUserCode(@Param("loginName")String loginName);
134 134  
  135 +
  136 + /**
  137 + * 根据用户编码查询该用户所有仓库
  138 + * @param loginName
  139 + * @return
  140 + */
  141 + public List<Map<String, Object>> getWarehouseByUserName(@Param("loginName")String loginName);
  142 +
135 143 /**
136 144 * 更新用户维护日期
137 145 * @param date
... ...
src/main/java/com/huaheng/pc/system/user/service/IUserService.java
... ... @@ -2,8 +2,10 @@ package com.huaheng.pc.system.user.service;
2 2  
3 3 import com.huaheng.framework.web.domain.AjaxResult;
4 4 import com.huaheng.pc.system.user.domain.ClientType;
  5 +import com.huaheng.pc.system.user.domain.SysUserWarehouse;
5 6 import com.huaheng.pc.system.user.domain.User;
6 7 import io.swagger.models.auth.In;
  8 +import org.apache.ibatis.annotations.Param;
7 9  
8 10 import java.util.Date;
9 11 import java.util.List;
... ... @@ -195,6 +197,8 @@ public interface IUserService
195 197 * @return
196 198 */
197 199 public User selectmen(String loginName);
  200 +
  201 + public int batchUserWarehouse(@Param("userWarehouseList") List<SysUserWarehouse> userWarehouseList);
198 202 }
199 203  
200 204  
... ...
src/main/java/com/huaheng/pc/system/user/service/UserServiceImpl.java
... ... @@ -13,8 +13,8 @@ import com.huaheng.pc.general.company.mapper.CompanyMapper;
13 13 import com.huaheng.pc.general.company.service.CompanyService;
14 14 import com.huaheng.pc.general.warehouse.service.WarehouseService;
15 15 import com.huaheng.pc.general.warehouse.domain.Warehouse;
16   -import com.huaheng.pc.system.user.domain.ClientType;
17   -import com.huaheng.pc.system.user.domain.UserCompany;
  16 +import com.huaheng.pc.system.user.domain.*;
  17 +import com.huaheng.pc.system.user.mapper.SysUserWarehouseMapper;
18 18 import com.huaheng.pc.system.user.mapper.UserCompanyMapper;
19 19 import org.apache.shiro.SecurityUtils;
20 20 import org.apache.shiro.authc.AuthenticationException;
... ... @@ -29,8 +29,6 @@ import com.huaheng.common.utils.security.ShiroUtils;
29 29 import com.huaheng.framework.shiro.service.PasswordService;
30 30 import com.huaheng.pc.system.role.domain.Role;
31 31 import com.huaheng.pc.system.role.mapper.RoleMapper;
32   -import com.huaheng.pc.system.user.domain.User;
33   -import com.huaheng.pc.system.user.domain.UserRole;
34 32 import com.huaheng.pc.system.user.mapper.UserMapper;
35 33 import com.huaheng.pc.system.user.mapper.UserRoleMapper;
36 34  
... ... @@ -68,11 +66,14 @@ public class UserServiceImpl implements IUserService
68 66 @Resource
69 67 private WarehouseService warehouseService;
70 68  
  69 + @Resource
  70 + private SysUserWarehouseMapper sysUserWarehouseMapper;
  71 +
71 72 /**
72 73 * 登陆验证
73 74 * @param username 用户名
74 75 * @param password 密 码
75   - * @param warehouseId 仓库id
  76 +// * @param warehouseId 仓库id
76 77 * @param warehouseCode 仓库编码
77 78 * @return
78 79 */
... ... @@ -262,6 +263,8 @@ public class UserServiceImpl implements IUserService
262 263 insertUserCompany(user);
263 264 // 新增用户与角色管理
264 265 insertUserRole(user);
  266 + // 新增用户与仓库管理
  267 + insertUserWarehouse(user);
265 268 return rows;
266 269 }
267 270  
... ... @@ -284,6 +287,11 @@ public class UserServiceImpl implements IUserService
284 287 userCompanyMapper.deleteUserCompanyByUserId(userId);
285 288 // 新增用户与货主管理
286 289 insertUserCompany(user);
  290 + // 删除用户与仓库关联
  291 + sysUserWarehouseMapper.deleteUserWarehouseByUserId(userId);
  292 + // 新增用户与仓库管理
  293 + insertUserWarehouse(user);
  294 +
287 295 return userMapper.updateUser(user);
288 296 }
289 297  
... ... @@ -335,6 +343,29 @@ public class UserServiceImpl implements IUserService
335 343 }
336 344 }
337 345  
  346 +
  347 + /**
  348 + * 新增用户仓库信息
  349 + *
  350 + * @param user 用户对象
  351 + */
  352 + public void insertUserWarehouse(User user)
  353 + {
  354 + // 新增用户与仓库管理
  355 + List<SysUserWarehouse> list = new ArrayList<SysUserWarehouse>();
  356 + if (user.getWarehouseCodeList() != null) {
  357 + for (String warehouseCode : user.getWarehouseCodeList()) {
  358 + SysUserWarehouse warehouse = new SysUserWarehouse();
  359 + warehouse.setUserId(user.getId());
  360 + warehouse.setWarehouseCode(warehouseCode);
  361 + list.add(warehouse);
  362 + }
  363 + if (list.size() > 0) {
  364 + sysUserWarehouseMapper.batchUserWarehouse(list);
  365 + }
  366 + }
  367 + }
  368 +
338 369 /**
339 370 * 新增用户货主信息
340 371 *
... ... @@ -469,7 +500,11 @@ public class UserServiceImpl implements IUserService
469 500 }
470 501 else
471 502 {
472   - list = userMapper.getWarehouseByUserCode(loginName);
  503 + list = userMapper.getWarehouseByUserName(loginName);
  504 + if (list.size()==1)
  505 + list=userMapper.getWarehouseByUserCode(loginName);
  506 +
  507 +
473 508 }
474 509 return list;
475 510 }
... ... @@ -552,4 +587,9 @@ public class UserServiceImpl implements IUserService
552 587 return user;
553 588 }
554 589  
  590 + @Override
  591 + public int batchUserWarehouse(List<SysUserWarehouse> userWarehouseList) {
  592 + return sysUserWarehouseMapper.batchUserWarehouse(userWarehouseList);
  593 + }
  594 +
555 595 }
... ...
src/main/java/com/huaheng/pc/system/userWarehouse/mapper/SysUserWarehouseMapper.java deleted
1   -package com.huaheng.pc.system.userWarehouse.mapper;
2   -
3   -import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4   -import com.huaheng.pc.system.userWarehouse.domain.SysUserWarehouse;
5   -
6   -public interface SysUserWarehouseMapper extends BaseMapper<SysUserWarehouse> {
7   -}
8 0 \ No newline at end of file
src/main/java/com/huaheng/pc/system/userWarehouse/service/SysUserWarehouseService.java deleted
1   -package com.huaheng.pc.system.userWarehouse.service;
2   -
3   -import com.huaheng.pc.system.userWarehouse.domain.SysUserWarehouse;
4   -import com.baomidou.mybatisplus.extension.service.IService;
5   -public interface SysUserWarehouseService extends IService<SysUserWarehouse>{
6   -
7   -
8   -}
src/main/java/com/huaheng/pc/system/userWarehouse/service/SysUserWarehouseServiceImpl.java deleted
1   -package com.huaheng.pc.system.userWarehouse.service;
2   -
3   -import org.springframework.stereotype.Service;
4   -import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
5   -import com.huaheng.pc.system.userWarehouse.mapper.SysUserWarehouseMapper;
6   -import com.huaheng.pc.system.userWarehouse.domain.SysUserWarehouse;
7   -
8   -@Service
9   -public class SysUserWarehouseServiceImpl extends ServiceImpl<SysUserWarehouseMapper, SysUserWarehouse> implements SysUserWarehouseService{
10   -
11   -}
src/main/java/com/huaheng/pc/task/taskDetail/domain/TaskDetail.java 0 → 100644
  1 +package com.huaheng.pc.task.taskDetail.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.task.taskDetail.domain.TaskDetail")
  14 +@Data
  15 +@TableName(value = "task_detail")
  16 +public class TaskDetail implements Serializable {
  17 + /**
  18 + * ID
  19 + */
  20 + @TableId(value = "id", type = IdType.AUTO)
  21 + @ApiModelProperty(value="ID")
  22 + private Integer id;
  23 +
  24 + /**
  25 + * 任务头内部号
  26 + */
  27 + @TableField(value = "taskId")
  28 + @ApiModelProperty(value="任务头内部号")
  29 + private Integer taskId;
  30 +
  31 + /**
  32 + * 任务号
  33 + */
  34 + @TableField(value = "taskCode")
  35 + @ApiModelProperty(value="任务号")
  36 + private String taskCode;
  37 +
  38 + /**
  39 + * 任务类型
  40 + */
  41 + @TableField(value = "taskType")
  42 + @ApiModelProperty(value="任务类型")
  43 + private String taskType;
  44 +
  45 + /**
  46 + * 任务类型
  47 + */
  48 + @TableField(value = "internalTaskType")
  49 + @ApiModelProperty(value="任务类型")
  50 + private String internalTaskType;
  51 +
  52 + /**
  53 + * 仓库
  54 + */
  55 + @TableField(value = "warehouseCode")
  56 + @ApiModelProperty(value="仓库")
  57 + private String warehouseCode;
  58 +
  59 + /**
  60 + * 货主
  61 + */
  62 + @TableField(value = "companyCode")
  63 + @ApiModelProperty(value="货主")
  64 + private String companyCode;
  65 +
  66 + /**
  67 + * 物料
  68 + */
  69 + @TableField(value = "materialCode")
  70 + @ApiModelProperty(value="物料")
  71 + private String materialCode;
  72 +
  73 + /**
  74 + * 物料明细
  75 + */
  76 + @TableField(value = "materialName")
  77 + @ApiModelProperty(value="物料明细")
  78 + private String materialName;
  79 +
  80 + /**
  81 + * 物料
  82 + */
  83 + @TableField(value = "materialSpec")
  84 + @ApiModelProperty(value="物料")
  85 + private String materialSpec;
  86 +
  87 + /**
  88 + * 物料明细
  89 + */
  90 + @TableField(value = "materialUnit")
  91 + @ApiModelProperty(value="物料明细")
  92 + private String materialUnit;
  93 +
  94 + /**
  95 + * 数量
  96 + */
  97 + @TableField(value = "qty")
  98 + @ApiModelProperty(value="数量")
  99 + private Integer qty;
  100 +
  101 + /**
  102 + * 从货位
  103 + */
  104 + @TableField(value = "fromLocation")
  105 + @ApiModelProperty(value="从货位")
  106 + private String fromLocation;
  107 +
  108 + /**
  109 + * 到货位
  110 + */
  111 + @TableField(value = "toLocation")
  112 + @ApiModelProperty(value="到货位")
  113 + private String toLocation;
  114 +
  115 + /**
  116 + * 容器编码
  117 + */
  118 + @TableField(value = "containerCode")
  119 + @ApiModelProperty(value="容器编码")
  120 + private String containerCode;
  121 +
  122 + /**
  123 + * 从区域
  124 + */
  125 + @TableField(value = "fromZone")
  126 + @ApiModelProperty(value="从区域")
  127 + private String fromZone;
  128 +
  129 + /**
  130 + * 到区域
  131 + */
  132 + @TableField(value = "toZone")
  133 + @ApiModelProperty(value="到区域")
  134 + private String toZone;
  135 +
  136 + /**
  137 + * 属性号
  138 + */
  139 + @TableField(value = "attributeId")
  140 + @ApiModelProperty(value="属性号")
  141 + private Integer attributeId;
  142 +
  143 + /**
  144 + * 状态
  145 + */
  146 + @TableField(value = "enable")
  147 + @ApiModelProperty(value="状态")
  148 + private Integer enable;
  149 +
  150 + /**
  151 + * 参考单号
  152 + */
  153 + @TableField(value = "referenceCode")
  154 + @ApiModelProperty(value="参考单号")
  155 + private String referenceCode;
  156 +
  157 + /**
  158 + * 参考内部号
  159 + */
  160 + @TableField(value = "referenceId")
  161 + @ApiModelProperty(value="参考内部号")
  162 + private Integer referenceId;
  163 +
  164 + /**
  165 + * 参考内部行号
  166 + */
  167 + @TableField(value = "referenceLineId")
  168 + @ApiModelProperty(value="参考内部行号")
  169 + private Integer referenceLineId;
  170 +
  171 + /**
  172 + * 指派用户
  173 + */
  174 + @TableField(value = "assignedUser")
  175 + @ApiModelProperty(value="指派用户")
  176 + private String assignedUser;
  177 +
  178 + /**
  179 + * 属性1
  180 + */
  181 + @TableField(value = "attribute1")
  182 + @ApiModelProperty(value="属性1")
  183 + private String attribute1;
  184 +
  185 + /**
  186 + * 属性2
  187 + */
  188 + @TableField(value = "attribute2")
  189 + @ApiModelProperty(value="属性2")
  190 + private String attribute2;
  191 +
  192 + /**
  193 + * 属性3
  194 + */
  195 + @TableField(value = "attribute3")
  196 + @ApiModelProperty(value="属性3")
  197 + private String attribute3;
  198 +
  199 + /**
  200 + * 属性4
  201 + */
  202 + @TableField(value = "attribute4")
  203 + @ApiModelProperty(value="属性4")
  204 + private String attribute4;
  205 +
  206 + /**
  207 + * 批次
  208 + */
  209 + @TableField(value = "batch")
  210 + @ApiModelProperty(value="批次")
  211 + private String batch;
  212 +
  213 + /**
  214 + * 批号
  215 + */
  216 + @TableField(value = "lot")
  217 + @ApiModelProperty(value="批号")
  218 + private String lot;
  219 +
  220 + /**
  221 + * 项目号
  222 + */
  223 + @TableField(value = "projectNo")
  224 + @ApiModelProperty(value="项目号")
  225 + private String projectNo;
  226 +
  227 + /**
  228 + * 质检
  229 + */
  230 + @TableField(value = "qcCheck")
  231 + @ApiModelProperty(value="质检")
  232 + private String qcCheck;
  233 +
  234 + /**
  235 + * 生产日期
  236 + */
  237 + @TableField(value = "manufactureDate")
  238 + @ApiModelProperty(value="生产日期")
  239 + private Date manufactureDate;
  240 +
  241 + /**
  242 + * 失效日期
  243 + */
  244 + @TableField(value = "expirationDate")
  245 + @ApiModelProperty(value="失效日期")
  246 + private Date expirationDate;
  247 +
  248 + /**
  249 + * 入库日期
  250 + */
  251 + @TableField(value = "agingDate")
  252 + @ApiModelProperty(value="入库日期")
  253 + private Date agingDate;
  254 +
  255 + /**
  256 + * 库存状态
  257 + */
  258 + @TableField(value = "inventorySts")
  259 + @ApiModelProperty(value="库存状态")
  260 + private String inventorySts;
  261 +
  262 + /**
  263 + * 波次号
  264 + */
  265 + @TableField(value = "waveId")
  266 + @ApiModelProperty(value="波次号")
  267 + private Integer waveId;
  268 +
  269 + /**
  270 + * 分配的库存ID
  271 + */
  272 + @TableField(value = "fromInventoryId")
  273 + @ApiModelProperty(value="分配的库存ID")
  274 + private Integer fromInventoryId;
  275 +
  276 + @TableField(value = "toInventoryId")
  277 + @ApiModelProperty(value="null")
  278 + private Integer toInventoryId;
  279 +
  280 + /**
  281 + * 确认用户
  282 + */
  283 + @TableField(value = "confirmedBy")
  284 + @ApiModelProperty(value="确认用户")
  285 + private String confirmedBy;
  286 +
  287 + /**
  288 + * 组号
  289 + */
  290 + @TableField(value = "groupNum")
  291 + @ApiModelProperty(value="组号")
  292 + private Integer groupNum;
  293 +
  294 + /**
  295 + * 序号
  296 + */
  297 + @TableField(value = "groupIndex")
  298 + @ApiModelProperty(value="序号")
  299 + private Integer groupIndex;
  300 +
  301 + /**
  302 + * 创建时间
  303 + */
  304 + @TableField(value = "created")
  305 + @ApiModelProperty(value="创建时间")
  306 + private Date created;
  307 +
  308 + /**
  309 + * 创建用户
  310 + */
  311 + @TableField(value = "createdBy")
  312 + @ApiModelProperty(value="创建用户")
  313 + private String createdBy;
  314 +
  315 + /**
  316 + * 创建时间
  317 + */
  318 + @TableField(value = "lastUpdated")
  319 + @ApiModelProperty(value="创建时间")
  320 + private Date lastUpdated;
  321 +
  322 + /**
  323 + * 更新用户
  324 + */
  325 + @TableField(value = "lastUpdatedBy")
  326 + @ApiModelProperty(value="更新用户")
  327 + private String lastUpdatedBy;
  328 +
  329 + /**
  330 + * 数据版本
  331 + */
  332 + @TableField(value = "version")
  333 + @ApiModelProperty(value="数据版本")
  334 + private Integer version;
  335 +
  336 + /**
  337 + * kitFlag标志 Y/N AGV专用
  338 + */
  339 + @TableField(value = "userDef1")
  340 + @ApiModelProperty(value="kitFlag标志 Y/N AGV专用")
  341 + private String userDef1;
  342 +
  343 + /**
  344 + * unit 单位 AGV专用
  345 + */
  346 + @TableField(value = "userDef2")
  347 + @ApiModelProperty(value="unit 单位 AGV专用")
  348 + private String userDef2;
  349 +
  350 + /**
  351 + * 自定义字段3
  352 + */
  353 + @TableField(value = "userDef3")
  354 + @ApiModelProperty(value="自定义字段3")
  355 + private String userDef3;
  356 +
  357 + /**
  358 + * 自定义字段4
  359 + */
  360 + @TableField(value = "userDef4")
  361 + @ApiModelProperty(value="自定义字段4")
  362 + private String userDef4;
  363 +
  364 + /**
  365 + * 自定义字段5
  366 + */
  367 + @TableField(value = "userDef5")
  368 + @ApiModelProperty(value="自定义字段5")
  369 + private String userDef5;
  370 +
  371 + /**
  372 + * 自定义字段6
  373 + */
  374 + @TableField(value = "userDef6")
  375 + @ApiModelProperty(value="自定义字段6")
  376 + private String userDef6;
  377 +
  378 + /**
  379 + * 自定义字段7
  380 + */
  381 + @TableField(value = "userDef7")
  382 + @ApiModelProperty(value="自定义字段7")
  383 + private String userDef7;
  384 +
  385 + /**
  386 + * 自定义字段8
  387 + */
  388 + @TableField(value = "userDef8")
  389 + @ApiModelProperty(value="自定义字段8")
  390 + private String userDef8;
  391 +
  392 + /**
  393 + * 处理标记
  394 + */
  395 + @TableField(value = "processStamp")
  396 + @ApiModelProperty(value="处理标记")
  397 + private String processStamp;
  398 +
  399 + private static final long serialVersionUID = 1L;
  400 +
  401 + public static final String COL_ID = "id";
  402 +
  403 + public static final String COL_TASKID = "taskId";
  404 +
  405 + public static final String COL_TASKCODE = "taskCode";
  406 +
  407 + public static final String COL_TASKTYPE = "taskType";
  408 +
  409 + public static final String COL_INTERNALTASKTYPE = "internalTaskType";
  410 +
  411 + public static final String COL_WAREHOUSECODE = "warehouseCode";
  412 +
  413 + public static final String COL_COMPANYCODE = "companyCode";
  414 +
  415 + public static final String COL_MATERIALCODE = "materialCode";
  416 +
  417 + public static final String COL_MATERIALNAME = "materialName";
  418 +
  419 + public static final String COL_MATERIALSPEC = "materialSpec";
  420 +
  421 + public static final String COL_MATERIALUNIT = "materialUnit";
  422 +
  423 + public static final String COL_QTY = "qty";
  424 +
  425 + public static final String COL_FROMLOCATION = "fromLocation";
  426 +
  427 + public static final String COL_TOLOCATION = "toLocation";
  428 +
  429 + public static final String COL_CONTAINERCODE = "containerCode";
  430 +
  431 + public static final String COL_FROMZONE = "fromZone";
  432 +
  433 + public static final String COL_TOZONE = "toZone";
  434 +
  435 + public static final String COL_ATTRIBUTEID = "attributeId";
  436 +
  437 + public static final String COL_ENABLE = "enable";
  438 +
  439 + public static final String COL_REFERENCECODE = "referenceCode";
  440 +
  441 + public static final String COL_REFERENCEID = "referenceId";
  442 +
  443 + public static final String COL_REFERENCELINEID = "referenceLineId";
  444 +
  445 + public static final String COL_ASSIGNEDUSER = "assignedUser";
  446 +
  447 + public static final String COL_ATTRIBUTE1 = "attribute1";
  448 +
  449 + public static final String COL_ATTRIBUTE2 = "attribute2";
  450 +
  451 + public static final String COL_ATTRIBUTE3 = "attribute3";
  452 +
  453 + public static final String COL_ATTRIBUTE4 = "attribute4";
  454 +
  455 + public static final String COL_BATCH = "batch";
  456 +
  457 + public static final String COL_LOT = "lot";
  458 +
  459 + public static final String COL_PROJECTNO = "projectNo";
  460 +
  461 + public static final String COL_QCCHECK = "qcCheck";
  462 +
  463 + public static final String COL_MANUFACTUREDATE = "manufactureDate";
  464 +
  465 + public static final String COL_EXPIRATIONDATE = "expirationDate";
  466 +
  467 + public static final String COL_AGINGDATE = "agingDate";
  468 +
  469 + public static final String COL_INVENTORYSTS = "inventorySts";
  470 +
  471 + public static final String COL_WAVEID = "waveId";
  472 +
  473 + public static final String COL_FROMINVENTORYID = "fromInventoryId";
  474 +
  475 + public static final String COL_TOINVENTORYID = "toInventoryId";
  476 +
  477 + public static final String COL_CONFIRMEDBY = "confirmedBy";
  478 +
  479 + public static final String COL_GROUPNUM = "groupNum";
  480 +
  481 + public static final String COL_GROUPINDEX = "groupIndex";
  482 +
  483 + public static final String COL_CREATED = "created";
  484 +
  485 + public static final String COL_CREATEDBY = "createdBy";
  486 +
  487 + public static final String COL_LASTUPDATED = "lastUpdated";
  488 +
  489 + public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";
  490 +
  491 + public static final String COL_VERSION = "version";
  492 +
  493 + public static final String COL_USERDEF1 = "userDef1";
  494 +
  495 + public static final String COL_USERDEF2 = "userDef2";
  496 +
  497 + public static final String COL_USERDEF3 = "userDef3";
  498 +
  499 + public static final String COL_USERDEF4 = "userDef4";
  500 +
  501 + public static final String COL_USERDEF5 = "userDef5";
  502 +
  503 + public static final String COL_USERDEF6 = "userDef6";
  504 +
  505 + public static final String COL_USERDEF7 = "userDef7";
  506 +
  507 + public static final String COL_USERDEF8 = "userDef8";
  508 +
  509 + public static final String COL_PROCESSSTAMP = "processStamp";
  510 +}
0 511 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskDetail/mapper/TaskDetailMapper.java 0 → 100644
  1 +package com.huaheng.pc.task.taskDetail.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.task.taskDetail.domain.TaskDetail;
  5 +
  6 +public interface TaskDetailMapper extends BaseMapper<TaskDetail> {
  7 +}
0 8 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskDetail/service/TaskDetailService.java 0 → 100644
  1 +package com.huaheng.pc.task.taskDetail.service;
  2 +
  3 +import com.huaheng.pc.task.taskDetail.domain.TaskDetail;
  4 +import com.baomidou.mybatisplus.extension.service.IService;
  5 +public interface TaskDetailService extends IService<TaskDetail>{
  6 +
  7 +
  8 +}
... ...
src/main/java/com/huaheng/pc/task/taskDetail/service/TaskDetailServiceImpl.java 0 → 100644
  1 +package com.huaheng.pc.task.taskDetail.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.task.taskDetail.mapper.TaskDetailMapper;
  8 +import com.huaheng.pc.task.taskDetail.domain.TaskDetail;
  9 +import com.huaheng.pc.task.taskDetail.service.TaskDetailService;
  10 +@Service
  11 +public class TaskDetailServiceImpl extends ServiceImpl<TaskDetailMapper, TaskDetail> implements TaskDetailService{
  12 +
  13 +}
... ...
src/main/java/com/huaheng/pc/task/taskHeader/domain/TaskHeader.java 0 → 100644
  1 +package com.huaheng.pc.task.taskHeader.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.task.taskHeader.domain.TaskHeader")
  14 +@Data
  15 +@TableName(value = "task_header")
  16 +public class TaskHeader implements Serializable {
  17 + /**
  18 + * ID
  19 + */
  20 + @TableId(value = "id", type = IdType.AUTO)
  21 + @ApiModelProperty(value="ID")
  22 + private Integer id;
  23 +
  24 + /**
  25 + * 任务
  26 + */
  27 + @TableField(value = "code")
  28 + @ApiModelProperty(value="任务")
  29 + private String code;
  30 +
  31 + /**
  32 + * 仓库
  33 + */
  34 + @TableField(value = "warehouseCode")
  35 + @ApiModelProperty(value="仓库")
  36 + private String warehouseCode;
  37 +
  38 + /**
  39 + * 货主
  40 + */
  41 + @TableField(value = "companyCode")
  42 + @ApiModelProperty(value="货主")
  43 + private String companyCode;
  44 +
  45 + /**
  46 + * 任务类型
  47 + */
  48 + @TableField(value = "taskType")
  49 + @ApiModelProperty(value="任务类型")
  50 + private String taskType;
  51 +
  52 + /**
  53 + * 内部类型
  54 + */
  55 + @TableField(value = "internalTaskType")
  56 + @ApiModelProperty(value="内部类型")
  57 + private String internalTaskType;
  58 +
  59 + /**
  60 + * 参考单内部号
  61 + */
  62 + @TableField(value = "referenceId")
  63 + @ApiModelProperty(value="参考单内部号")
  64 + private Integer referenceId;
  65 +
  66 + /**
  67 + * 参考单号
  68 + */
  69 + @TableField(value = "referenceCode")
  70 + @ApiModelProperty(value="参考单号")
  71 + private String referenceCode;
  72 +
  73 + /**
  74 + * 分配用户
  75 + */
  76 + @TableField(value = "assignedUser")
  77 + @ApiModelProperty(value="分配用户")
  78 + private String assignedUser;
  79 +
  80 + /**
  81 + * 确认用户
  82 + */
  83 + @TableField(value = "confirmedBy")
  84 + @ApiModelProperty(value="确认用户")
  85 + private String confirmedBy;
  86 +
  87 + /**
  88 + * 状态
  89 + */
  90 + @TableField(value = "enable")
  91 + @ApiModelProperty(value="状态")
  92 + private Integer enable;
  93 +
  94 + /**
  95 + * 波次号
  96 + */
  97 + @TableField(value = "waveId")
  98 + @ApiModelProperty(value="波次号")
  99 + private Integer waveId;
  100 +
  101 + /**
  102 + * 车号
  103 + */
  104 + @TableField(value = "pickingCartCode")
  105 + @ApiModelProperty(value="车号")
  106 + private String pickingCartCode;
  107 +
  108 + /**
  109 + * 位置号
  110 + */
  111 + @TableField(value = "pickingCartPos")
  112 + @ApiModelProperty(value="位置号")
  113 + private String pickingCartPos;
  114 +
  115 + /**
  116 + * 容器号
  117 + */
  118 + @TableField(value = "containerCode")
  119 + @ApiModelProperty(value="容器号")
  120 + private String containerCode;
  121 +
  122 + /**
  123 + * 开始拣货时间
  124 + */
  125 + @TableField(value = "startPickDateTime")
  126 + @ApiModelProperty(value="开始拣货时间")
  127 + private Date startPickDateTime;
  128 +
  129 + /**
  130 + * 截至拣货时间
  131 + */
  132 + @TableField(value = "endPickDateTime")
  133 + @ApiModelProperty(value="截至拣货时间")
  134 + private Date endPickDateTime;
  135 +
  136 + /**
  137 + * 合流货位
  138 + */
  139 + @TableField(value = "rebatchLoc")
  140 + @ApiModelProperty(value="合流货位")
  141 + private String rebatchLoc;
  142 +
  143 + /**
  144 + * 是否完成合流
  145 + */
  146 + @TableField(value = "finishRebatch")
  147 + @ApiModelProperty(value="是否完成合流")
  148 + private Integer finishRebatch;
  149 +
  150 + /**
  151 + * 合流组唯一号
  152 + */
  153 + @TableField(value = "rebatchGroupCode")
  154 + @ApiModelProperty(value="合流组唯一号")
  155 + private String rebatchGroupCode;
  156 +
  157 + /**
  158 + * 是否允许合流
  159 + */
  160 + @TableField(value = "allowRebatch")
  161 + @ApiModelProperty(value="是否允许合流")
  162 + private Integer allowRebatch;
  163 +
  164 + /**
  165 + * 任务处理类型
  166 + */
  167 + @TableField(value = "taskProcessType")
  168 + @ApiModelProperty(value="任务处理类型")
  169 + private String taskProcessType;
  170 +
  171 + /**
  172 + * 二次分拣工作台
  173 + */
  174 + @TableField(value = "rebinBench")
  175 + @ApiModelProperty(value="二次分拣工作台")
  176 + private String rebinBench;
  177 +
  178 + /**
  179 + * 二次分拣完成
  180 + */
  181 + @TableField(value = "rebined")
  182 + @ApiModelProperty(value="二次分拣完成")
  183 + private Integer rebined;
  184 +
  185 + /**
  186 + * 二次分拣开始时间
  187 + */
  188 + @TableField(value = "startRebinDateTime")
  189 + @ApiModelProperty(value="二次分拣开始时间")
  190 + private Date startRebinDateTime;
  191 +
  192 + /**
  193 + * 二次分拣结束时间
  194 + */
  195 + @TableField(value = "endRebinDateTime")
  196 + @ApiModelProperty(value="二次分拣结束时间")
  197 + private Date endRebinDateTime;
  198 +
  199 + /**
  200 + * 二次分拣人
  201 + */
  202 + @TableField(value = "rebinedBy")
  203 + @ApiModelProperty(value="二次分拣人")
  204 + private String rebinedBy;
  205 +
  206 + /**
  207 + * 异常原因
  208 + */
  209 + @TableField(value = "exceptionCode")
  210 + @ApiModelProperty(value="异常原因")
  211 + private String exceptionCode;
  212 +
  213 + /**
  214 + * 异常处理人
  215 + */
  216 + @TableField(value = "exceptionHandledBy")
  217 + @ApiModelProperty(value="异常处理人")
  218 + private String exceptionHandledBy;
  219 +
  220 + /**
  221 + * 创建时间
  222 + */
  223 + @TableField(value = "created")
  224 + @ApiModelProperty(value="创建时间")
  225 + private Date created;
  226 +
  227 + /**
  228 + * 创建用户
  229 + */
  230 + @TableField(value = "createdBy")
  231 + @ApiModelProperty(value="创建用户")
  232 + private String createdBy;
  233 +
  234 + /**
  235 + * 创建时间
  236 + */
  237 + @TableField(value = "lastUpdated")
  238 + @ApiModelProperty(value="创建时间")
  239 + private Date lastUpdated;
  240 +
  241 + /**
  242 + * 更新用户
  243 + */
  244 + @TableField(value = "lastUpdatedBy")
  245 + @ApiModelProperty(value="更新用户")
  246 + private String lastUpdatedBy;
  247 +
  248 + /**
  249 + * 数据版本
  250 + */
  251 + @TableField(value = "version")
  252 + @ApiModelProperty(value="数据版本")
  253 + private Integer version;
  254 +
  255 + /**
  256 + * AGV区域任务标志 =‘AGV’
  257 + */
  258 + @TableField(value = "userDef1")
  259 + @ApiModelProperty(value="AGV区域任务标志 =‘AGV’")
  260 + private String userDef1;
  261 +
  262 + /**
  263 + * 自定义字段2
  264 + */
  265 + @TableField(value = "userDef2")
  266 + @ApiModelProperty(value="自定义字段2")
  267 + private String userDef2;
  268 +
  269 + /**
  270 + * 同步标志 0:需要同步 10:同步成功 20:同步失败
  271 + */
  272 + @TableField(value = "userDef3")
  273 + @ApiModelProperty(value="同步标志 0:需要同步 10:同步成功 20:同步失败")
  274 + private String userDef3;
  275 +
  276 + /**
  277 + * 自定义字段4
  278 + */
  279 + @TableField(value = "userDef4")
  280 + @ApiModelProperty(value="自定义字段4")
  281 + private String userDef4;
  282 +
  283 + /**
  284 + * 自定义字段5
  285 + */
  286 + @TableField(value = "userDef5")
  287 + @ApiModelProperty(value="自定义字段5")
  288 + private String userDef5;
  289 +
  290 + /**
  291 + * 自定义字段6
  292 + */
  293 + @TableField(value = "userDef6")
  294 + @ApiModelProperty(value="自定义字段6")
  295 + private String userDef6;
  296 +
  297 + /**
  298 + * 自定义字段7
  299 + */
  300 + @TableField(value = "userDef7")
  301 + @ApiModelProperty(value="自定义字段7")
  302 + private String userDef7;
  303 +
  304 + /**
  305 + * 自定义字段8
  306 + */
  307 + @TableField(value = "userDef8")
  308 + @ApiModelProperty(value="自定义字段8")
  309 + private String userDef8;
  310 +
  311 + /**
  312 + * 处理标记
  313 + */
  314 + @TableField(value = "processStamp")
  315 + @ApiModelProperty(value="处理标记")
  316 + private String processStamp;
  317 +
  318 + private static final long serialVersionUID = 1L;
  319 +
  320 + public static final String COL_ID = "id";
  321 +
  322 + public static final String COL_CODE = "code";
  323 +
  324 + public static final String COL_WAREHOUSECODE = "warehouseCode";
  325 +
  326 + public static final String COL_COMPANYCODE = "companyCode";
  327 +
  328 + public static final String COL_TASKTYPE = "taskType";
  329 +
  330 + public static final String COL_INTERNALTASKTYPE = "internalTaskType";
  331 +
  332 + public static final String COL_REFERENCEID = "referenceId";
  333 +
  334 + public static final String COL_REFERENCECODE = "referenceCode";
  335 +
  336 + public static final String COL_ASSIGNEDUSER = "assignedUser";
  337 +
  338 + public static final String COL_CONFIRMEDBY = "confirmedBy";
  339 +
  340 + public static final String COL_ENABLE = "enable";
  341 +
  342 + public static final String COL_WAVEID = "waveId";
  343 +
  344 + public static final String COL_PICKINGCARTCODE = "pickingCartCode";
  345 +
  346 + public static final String COL_PICKINGCARTPOS = "pickingCartPos";
  347 +
  348 + public static final String COL_CONTAINERCODE = "containerCode";
  349 +
  350 + public static final String COL_STARTPICKDATETIME = "startPickDateTime";
  351 +
  352 + public static final String COL_ENDPICKDATETIME = "endPickDateTime";
  353 +
  354 + public static final String COL_REBATCHLOC = "rebatchLoc";
  355 +
  356 + public static final String COL_FINISHREBATCH = "finishRebatch";
  357 +
  358 + public static final String COL_REBATCHGROUPCODE = "rebatchGroupCode";
  359 +
  360 + public static final String COL_ALLOWREBATCH = "allowRebatch";
  361 +
  362 + public static final String COL_TASKPROCESSTYPE = "taskProcessType";
  363 +
  364 + public static final String COL_REBINBENCH = "rebinBench";
  365 +
  366 + public static final String COL_REBINED = "rebined";
  367 +
  368 + public static final String COL_STARTREBINDATETIME = "startRebinDateTime";
  369 +
  370 + public static final String COL_ENDREBINDATETIME = "endRebinDateTime";
  371 +
  372 + public static final String COL_REBINEDBY = "rebinedBy";
  373 +
  374 + public static final String COL_EXCEPTIONCODE = "exceptionCode";
  375 +
  376 + public static final String COL_EXCEPTIONHANDLEDBY = "exceptionHandledBy";
  377 +
  378 + public static final String COL_CREATED = "created";
  379 +
  380 + public static final String COL_CREATEDBY = "createdBy";
  381 +
  382 + public static final String COL_LASTUPDATED = "lastUpdated";
  383 +
  384 + public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";
  385 +
  386 + public static final String COL_VERSION = "version";
  387 +
  388 + public static final String COL_USERDEF1 = "userDef1";
  389 +
  390 + public static final String COL_USERDEF2 = "userDef2";
  391 +
  392 + public static final String COL_USERDEF3 = "userDef3";
  393 +
  394 + public static final String COL_USERDEF4 = "userDef4";
  395 +
  396 + public static final String COL_USERDEF5 = "userDef5";
  397 +
  398 + public static final String COL_USERDEF6 = "userDef6";
  399 +
  400 + public static final String COL_USERDEF7 = "userDef7";
  401 +
  402 + public static final String COL_USERDEF8 = "userDef8";
  403 +
  404 + public static final String COL_PROCESSSTAMP = "processStamp";
  405 +}
0 406 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskHeader/mapper/TaskHeaderMapper.java 0 → 100644
  1 +package com.huaheng.pc.task.taskHeader.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.task.taskHeader.domain.TaskHeader;
  5 +
  6 +public interface TaskHeaderMapper extends BaseMapper<TaskHeader> {
  7 +}
0 8 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskHeader/service/TaskHeaderService.java 0 → 100644
  1 +package com.huaheng.pc.task.taskHeader.service;
  2 +
  3 +import com.huaheng.pc.task.taskHeader.domain.TaskHeader;
  4 +import com.baomidou.mybatisplus.extension.service.IService;
  5 +public interface TaskHeaderService extends IService<TaskHeader>{
  6 +
  7 +
  8 +}
... ...
src/main/java/com/huaheng/pc/task/taskHeader/service/TaskHeaderServiceImpl.java 0 → 100644
  1 +package com.huaheng.pc.task.taskHeader.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.task.taskHeader.domain.TaskHeader;
  8 +import com.huaheng.pc.task.taskHeader.mapper.TaskHeaderMapper;
  9 +import com.huaheng.pc.task.taskHeader.service.TaskHeaderService;
  10 +@Service
  11 +public class TaskHeaderServiceImpl extends ServiceImpl<TaskHeaderMapper, TaskHeader> implements TaskHeaderService{
  12 +
  13 +}
... ...
src/main/java/com/huaheng/pc/task/taskPreference/domain/TaskPreference.java 0 → 100644
  1 +package com.huaheng.pc.task.taskPreference.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.task.taskPreference.domain.TaskPreference")
  14 +@Data
  15 +@TableName(value = "task_preference")
  16 +public class TaskPreference implements Serializable {
  17 + /**
  18 + * ID
  19 + */
  20 + @TableId(value = "id", type = IdType.AUTO)
  21 + @ApiModelProperty(value="ID")
  22 + private Integer id;
  23 +
  24 + /**
  25 + * 首选项
  26 + */
  27 + @TableField(value = "name")
  28 + @ApiModelProperty(value="首选项")
  29 + private String name;
  30 +
  31 + /**
  32 + * 仓库编码
  33 + */
  34 + @TableField(value = "warehouseCode")
  35 + @ApiModelProperty(value="仓库编码")
  36 + private String warehouseCode;
  37 +
  38 + /**
  39 + * 内部任务类型
  40 + */
  41 + @TableField(value = "internalTaskType")
  42 + @ApiModelProperty(value="内部任务类型")
  43 + private String internalTaskType;
  44 +
  45 + /**
  46 + * 任务类型
  47 + */
  48 + @TableField(value = "taskType")
  49 + @ApiModelProperty(value="任务类型")
  50 + private String taskType;
  51 +
  52 + /**
  53 + * 区域
  54 + */
  55 + @TableField(value = "zoneCode")
  56 + @ApiModelProperty(value="区域")
  57 + private String zoneCode;
  58 +
  59 + /**
  60 + * 任务开始方式
  61 + */
  62 + @TableField(value = "taskInitMethod")
  63 + @ApiModelProperty(value="任务开始方式")
  64 + private String taskInitMethod;
  65 +
  66 + /**
  67 + * 任务方向方式
  68 + */
  69 + @TableField(value = "taskDirectedMethod")
  70 + @ApiModelProperty(value="任务方向方式")
  71 + private String taskDirectedMethod;
  72 +
  73 + /**
  74 + * 拣货顺序?
  75 + */
  76 + @TableField(value = "fromAssignMethod")
  77 + @ApiModelProperty(value="拣货顺序?")
  78 + private String fromAssignMethod;
  79 +
  80 + /**
  81 + * 上架顺序?
  82 + */
  83 + @TableField(value = "toAssignMethod")
  84 + @ApiModelProperty(value="上架顺序?")
  85 + private String toAssignMethod;
  86 +
  87 + /**
  88 + * PICK方式
  89 + */
  90 + @TableField(value = "pickMethod")
  91 + @ApiModelProperty(value="PICK方式")
  92 + private String pickMethod;
  93 +
  94 + /**
  95 + * 启动RF操作成功消息
  96 + */
  97 + @TableField(value = "rfSuccessEnabled")
  98 + @ApiModelProperty(value="启动RF操作成功消息")
  99 + private Integer rfSuccessEnabled;
  100 +
  101 + /**
  102 + * 消息字段
  103 + */
  104 + @TableField(value = "rfSuccessField")
  105 + @ApiModelProperty(value="消息字段")
  106 + private String rfSuccessField;
  107 +
  108 + /**
  109 + * 消息格式
  110 + */
  111 + @TableField(value = "rfSuccessMessage")
  112 + @ApiModelProperty(value="消息格式")
  113 + private String rfSuccessMessage;
  114 +
  115 + /**
  116 + * 默认LPN作为出库箱号
  117 + */
  118 + @TableField(value = "DEFAULTLpAsShipCont")
  119 + @ApiModelProperty(value="默认LPN作为出库箱号")
  120 + private Integer DEFAULTLpAsShipCont;
  121 +
  122 + /**
  123 + * 多人拣选方式
  124 + */
  125 + @TableField(value = "multiPickMethod")
  126 + @ApiModelProperty(value="多人拣选方式")
  127 + private Integer multiPickMethod;
  128 +
  129 + /**
  130 + * 允许部分拣选
  131 + */
  132 + @TableField(value = "allowPartial")
  133 + @ApiModelProperty(value="允许部分拣选")
  134 + private String allowPartial;
  135 +
  136 + /**
  137 + * 接力货位
  138 + */
  139 + @TableField(value = "pickDropLoc")
  140 + @ApiModelProperty(value="接力货位")
  141 + private String pickDropLoc;
  142 +
  143 + /**
  144 + * 显示物料信息
  145 + */
  146 + @TableField(value = "displayItemInfo")
  147 + @ApiModelProperty(value="显示物料信息")
  148 + private String displayItemInfo;
  149 +
  150 + /**
  151 + * 创建时间
  152 + */
  153 + @TableField(value = "created")
  154 + @ApiModelProperty(value="创建时间")
  155 + private Date created;
  156 +
  157 + /**
  158 + * 创建用户
  159 + */
  160 + @TableField(value = "createdBy")
  161 + @ApiModelProperty(value="创建用户")
  162 + private String createdBy;
  163 +
  164 + /**
  165 + * 创建时间
  166 + */
  167 + @TableField(value = "lastUpdated")
  168 + @ApiModelProperty(value="创建时间")
  169 + private Date lastUpdated;
  170 +
  171 + /**
  172 + * 更新用户
  173 + */
  174 + @TableField(value = "lastUpdatedBy")
  175 + @ApiModelProperty(value="更新用户")
  176 + private String lastUpdatedBy;
  177 +
  178 + /**
  179 + * 数据版本
  180 + */
  181 + @TableField(value = "version")
  182 + @ApiModelProperty(value="数据版本")
  183 + private Integer version;
  184 +
  185 + /**
  186 + * 自定义字段1
  187 + */
  188 + @TableField(value = "userDef1")
  189 + @ApiModelProperty(value="自定义字段1")
  190 + private String userDef1;
  191 +
  192 + /**
  193 + * 自定义字段2
  194 + */
  195 + @TableField(value = "userDef2")
  196 + @ApiModelProperty(value="自定义字段2")
  197 + private String userDef2;
  198 +
  199 + /**
  200 + * 自定义字段3
  201 + */
  202 + @TableField(value = "userDef3")
  203 + @ApiModelProperty(value="自定义字段3")
  204 + private String userDef3;
  205 +
  206 + /**
  207 + * 自定义字段4
  208 + */
  209 + @TableField(value = "userDef4")
  210 + @ApiModelProperty(value="自定义字段4")
  211 + private String userDef4;
  212 +
  213 + /**
  214 + * 自定义字段5
  215 + */
  216 + @TableField(value = "userDef5")
  217 + @ApiModelProperty(value="自定义字段5")
  218 + private String userDef5;
  219 +
  220 + /**
  221 + * 自定义字段6
  222 + */
  223 + @TableField(value = "userDef6")
  224 + @ApiModelProperty(value="自定义字段6")
  225 + private String userDef6;
  226 +
  227 + /**
  228 + * 自定义字段7
  229 + */
  230 + @TableField(value = "userDef7")
  231 + @ApiModelProperty(value="自定义字段7")
  232 + private String userDef7;
  233 +
  234 + /**
  235 + * 自定义字段8
  236 + */
  237 + @TableField(value = "userDef8")
  238 + @ApiModelProperty(value="自定义字段8")
  239 + private String userDef8;
  240 +
  241 + /**
  242 + * 处理标记
  243 + */
  244 + @TableField(value = "processStamp")
  245 + @ApiModelProperty(value="处理标记")
  246 + private String processStamp;
  247 +
  248 + /**
  249 + * RF显示待处理任务
  250 + */
  251 + @TableField(value = "showOpenTask")
  252 + @ApiModelProperty(value="RF显示待处理任务")
  253 + private Integer showOpenTask;
  254 +
  255 + private static final long serialVersionUID = 1L;
  256 +
  257 + public static final String COL_ID = "id";
  258 +
  259 + public static final String COL_NAME = "name";
  260 +
  261 + public static final String COL_WAREHOUSECODE = "warehouseCode";
  262 +
  263 + public static final String COL_INTERNALTASKTYPE = "internalTaskType";
  264 +
  265 + public static final String COL_TASKTYPE = "taskType";
  266 +
  267 + public static final String COL_ZONECODE = "zoneCode";
  268 +
  269 + public static final String COL_TASKINITMETHOD = "taskInitMethod";
  270 +
  271 + public static final String COL_TASKDIRECTEDMETHOD = "taskDirectedMethod";
  272 +
  273 + public static final String COL_FROMASSIGNMETHOD = "fromAssignMethod";
  274 +
  275 + public static final String COL_TOASSIGNMETHOD = "toAssignMethod";
  276 +
  277 + public static final String COL_PICKMETHOD = "pickMethod";
  278 +
  279 + public static final String COL_RFSUCCESSENABLED = "rfSuccessEnabled";
  280 +
  281 + public static final String COL_RFSUCCESSFIELD = "rfSuccessField";
  282 +
  283 + public static final String COL_RFSUCCESSMESSAGE = "rfSuccessMessage";
  284 +
  285 + public static final String COL_DEFAULTLPASSHIPCONT = "DEFAULTLpAsShipCont";
  286 +
  287 + public static final String COL_MULTIPICKMETHOD = "multiPickMethod";
  288 +
  289 + public static final String COL_ALLOWPARTIAL = "allowPartial";
  290 +
  291 + public static final String COL_PICKDROPLOC = "pickDropLoc";
  292 +
  293 + public static final String COL_DISPLAYITEMINFO = "displayItemInfo";
  294 +
  295 + public static final String COL_CREATED = "created";
  296 +
  297 + public static final String COL_CREATEDBY = "createdBy";
  298 +
  299 + public static final String COL_LASTUPDATED = "lastUpdated";
  300 +
  301 + public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";
  302 +
  303 + public static final String COL_VERSION = "version";
  304 +
  305 + public static final String COL_USERDEF1 = "userDef1";
  306 +
  307 + public static final String COL_USERDEF2 = "userDef2";
  308 +
  309 + public static final String COL_USERDEF3 = "userDef3";
  310 +
  311 + public static final String COL_USERDEF4 = "userDef4";
  312 +
  313 + public static final String COL_USERDEF5 = "userDef5";
  314 +
  315 + public static final String COL_USERDEF6 = "userDef6";
  316 +
  317 + public static final String COL_USERDEF7 = "userDef7";
  318 +
  319 + public static final String COL_USERDEF8 = "userDef8";
  320 +
  321 + public static final String COL_PROCESSSTAMP = "processStamp";
  322 +
  323 + public static final String COL_SHOWOPENTASK = "showOpenTask";
  324 +}
0 325 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskPreference/mapper/TaskPreferenceMapper.java 0 → 100644
  1 +package com.huaheng.pc.task.taskPreference.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.task.taskPreference.domain.TaskPreference;
  5 +
  6 +public interface TaskPreferenceMapper extends BaseMapper<TaskPreference> {
  7 +}
0 8 \ No newline at end of file
... ...
src/main/java/com/huaheng/pc/task/taskPreference/service/TaskPreferenceService.java 0 → 100644
  1 +package com.huaheng.pc.task.taskPreference.service;
  2 +
  3 +import com.huaheng.pc.task.taskPreference.domain.TaskPreference;
  4 +import com.baomidou.mybatisplus.extension.service.IService;
  5 +public interface TaskPreferenceService extends IService<TaskPreference>{
  6 +
  7 +
  8 +}
... ...
src/main/java/com/huaheng/pc/task/taskPreference/service/TaskPreferenceServiceImpl.java 0 → 100644
  1 +package com.huaheng.pc.task.taskPreference.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.task.taskPreference.mapper.TaskPreferenceMapper;
  8 +import com.huaheng.pc.task.taskPreference.domain.TaskPreference;
  9 +import com.huaheng.pc.task.taskPreference.service.TaskPreferenceService;
  10 +@Service
  11 +public class TaskPreferenceServiceImpl extends ServiceImpl<TaskPreferenceMapper, TaskPreference> implements TaskPreferenceService{
  12 +
  13 +}
... ...
src/main/resources/mybatis/general/WarehouseMapper.xml
... ... @@ -34,6 +34,26 @@
34 34 <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
35 35 <result column="deleted" jdbcType="BIT" property="deleted" />
36 36 </resultMap>
  37 + <select id="wareHouseAll" resultType="com.huaheng.pc.system.user.domain.SysUserWarehouse">
  38 + select * from warehouse
  39 + </select>
  40 +
  41 + <select id="selectWarehouseByUserId"
  42 + resultType="com.huaheng.pc.general.warehouse.domain.Warehouse">
  43 + SELECT r.`name`, r.code
  44 + FROM sys_user u
  45 + LEFT JOIN sys_user_warehouse ur ON u.id = ur.userId
  46 + LEFT JOIN warehouse r ON ur.warehouseCode = r.code
  47 + WHERE ur.userId =#{userId}
  48 + </select>
  49 +
  50 + <select id="selectWarehouseAll"
  51 + resultType="com.huaheng.pc.general.warehouse.domain.Warehouse">
  52 + select * from warehouse
  53 + </select>
  54 +
  55 +
  56 +
37 57 <sql id="Base_Column_List">
38 58 <!--@mbg.generated-->
39 59 code, address1, address2, city, `state`, district, country, postalCode, attentionTo,
... ...
src/main/resources/mybatis/system/SysUserWarehouseMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.system.user.mapper.SysUserWarehouseMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.system.user.domain.SysUserWarehouse">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="userId" jdbcType="INTEGER" property="userId" />
  8 + <result column="warehouseId" jdbcType="INTEGER" property="warehouseId" />
  9 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  10 + </resultMap>
  11 +
  12 + <sql id="Base_Column_List">
  13 + <!--@mbg.generated-->
  14 + id, userId, warehouseId, warehouseCode
  15 + </sql>
  16 +
  17 + <insert id="batchUserWarehouse">
  18 + insert into sys_user_warehouse(userId, warehouseCode) values
  19 + <foreach item="item" index="index" collection="userWarehouseList" separator=",">
  20 + (#{item.userId},#{item.warehouseCode})
  21 + </foreach>
  22 + </insert>
  23 +
  24 + <delete id="deleteUserWarehouseByUserId" parameterType="Integer">
  25 + delete from sys_user_warehouse where userId=#{userId}
  26 + </delete>
  27 +
  28 +
  29 +</mapper>
  30 +
... ...
src/main/resources/mybatis/system/UserMapper.xml
... ... @@ -191,6 +191,14 @@
191 191 INNER JOIN sys_role ON sys_user_role.roleId = sys_role.id AND sys_user_role.userId = sys_user.Id AND sys_role.enable = TRUE
192 192 INNER JOIN warehouse ON sys_role.warehouseCode = warehouse.code AND warehouse.enable = TRUE
193 193 </select>
  194 +
  195 + <select id="getWarehouseByUserName" resultType="java.util.HashMap">
  196 + SELECT r.`name`, r.code
  197 + FROM sys_user u
  198 + LEFT JOIN sys_user_warehouse ur ON u.id = ur.userId
  199 + LEFT JOIN warehouse r ON ur.warehouseCode = r.code
  200 + WHERE u.loginName=#{loginName,jdbcType=VARCHAR}
  201 + </select>
194 202  
195 203 <update id="insertupdateTime" >
196 204 update sys_user set updateTime = #{date} where loginName = #{cPersonCode}
... ...
src/main/resources/mybatis/task/TaskDetailMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.task.taskDetail.mapper.TaskDetailMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.task.taskDetail.domain.TaskDetail">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="taskId" jdbcType="INTEGER" property="taskId" />
  8 + <result column="taskCode" jdbcType="VARCHAR" property="taskCode" />
  9 + <result column="taskType" jdbcType="VARCHAR" property="taskType" />
  10 + <result column="internalTaskType" jdbcType="VARCHAR" property="internalTaskType" />
  11 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  12 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  13 + <result column="materialCode" jdbcType="VARCHAR" property="materialCode" />
  14 + <result column="materialName" jdbcType="VARCHAR" property="materialName" />
  15 + <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" />
  16 + <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" />
  17 + <result column="qty" jdbcType="INTEGER" property="qty" />
  18 + <result column="fromLocation" jdbcType="VARCHAR" property="fromLocation" />
  19 + <result column="toLocation" jdbcType="VARCHAR" property="toLocation" />
  20 + <result column="containerCode" jdbcType="VARCHAR" property="containerCode" />
  21 + <result column="fromZone" jdbcType="VARCHAR" property="fromZone" />
  22 + <result column="toZone" jdbcType="VARCHAR" property="toZone" />
  23 + <result column="attributeId" jdbcType="INTEGER" property="attributeId" />
  24 + <result column="enable" jdbcType="INTEGER" property="enable" />
  25 + <result column="referenceCode" jdbcType="VARCHAR" property="referenceCode" />
  26 + <result column="referenceId" jdbcType="INTEGER" property="referenceId" />
  27 + <result column="referenceLineId" jdbcType="INTEGER" property="referenceLineId" />
  28 + <result column="assignedUser" jdbcType="VARCHAR" property="assignedUser" />
  29 + <result column="attribute1" jdbcType="VARCHAR" property="attribute1" />
  30 + <result column="attribute2" jdbcType="VARCHAR" property="attribute2" />
  31 + <result column="attribute3" jdbcType="VARCHAR" property="attribute3" />
  32 + <result column="attribute4" jdbcType="VARCHAR" property="attribute4" />
  33 + <result column="batch" jdbcType="VARCHAR" property="batch" />
  34 + <result column="lot" jdbcType="VARCHAR" property="lot" />
  35 + <result column="projectNo" jdbcType="VARCHAR" property="projectNo" />
  36 + <result column="qcCheck" jdbcType="VARCHAR" property="qcCheck" />
  37 + <result column="manufactureDate" jdbcType="DATE" property="manufactureDate" />
  38 + <result column="expirationDate" jdbcType="DATE" property="expirationDate" />
  39 + <result column="agingDate" jdbcType="DATE" property="agingDate" />
  40 + <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" />
  41 + <result column="waveId" jdbcType="INTEGER" property="waveId" />
  42 + <result column="fromInventoryId" jdbcType="INTEGER" property="fromInventoryId" />
  43 + <result column="toInventoryId" jdbcType="INTEGER" property="toInventoryId" />
  44 + <result column="confirmedBy" jdbcType="VARCHAR" property="confirmedBy" />
  45 + <result column="groupNum" jdbcType="INTEGER" property="groupNum" />
  46 + <result column="groupIndex" jdbcType="INTEGER" property="groupIndex" />
  47 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  48 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  49 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  50 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  51 + <result column="version" jdbcType="INTEGER" property="version" />
  52 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  53 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  54 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  55 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  56 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  57 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  58 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  59 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  60 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  61 + </resultMap>
  62 + <sql id="Base_Column_List">
  63 + <!--@mbg.generated-->
  64 + id, taskId, taskCode, taskType, internalTaskType, warehouseCode, companyCode, materialCode,
  65 + materialName, materialSpec, materialUnit, qty, fromLocation, toLocation, containerCode,
  66 + fromZone, toZone, attributeId, `enable`, referenceCode, referenceId, referenceLineId,
  67 + assignedUser, attribute1, attribute2, attribute3, attribute4, batch, lot, projectNo,
  68 + qcCheck, manufactureDate, expirationDate, agingDate, inventorySts, waveId, fromInventoryId,
  69 + toInventoryId, confirmedBy, groupNum, groupIndex, created, createdBy, lastUpdated,
  70 + lastUpdatedBy, version, userDef1, userDef2, userDef3, userDef4, userDef5, userDef6,
  71 + userDef7, userDef8, processStamp
  72 + </sql>
  73 +</mapper>
0 74 \ No newline at end of file
... ...
src/main/resources/mybatis/task/TaskHeaderMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.task.taskHeader.mapper.TaskHeaderMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.task.taskHeader.domain.TaskHeader">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="code" jdbcType="VARCHAR" property="code" />
  8 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  9 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  10 + <result column="taskType" jdbcType="VARCHAR" property="taskType" />
  11 + <result column="internalTaskType" jdbcType="VARCHAR" property="internalTaskType" />
  12 + <result column="referenceId" jdbcType="INTEGER" property="referenceId" />
  13 + <result column="referenceCode" jdbcType="VARCHAR" property="referenceCode" />
  14 + <result column="assignedUser" jdbcType="VARCHAR" property="assignedUser" />
  15 + <result column="confirmedBy" jdbcType="VARCHAR" property="confirmedBy" />
  16 + <result column="enable" jdbcType="INTEGER" property="enable" />
  17 + <result column="waveId" jdbcType="INTEGER" property="waveId" />
  18 + <result column="pickingCartCode" jdbcType="VARCHAR" property="pickingCartCode" />
  19 + <result column="pickingCartPos" jdbcType="VARCHAR" property="pickingCartPos" />
  20 + <result column="containerCode" jdbcType="VARCHAR" property="containerCode" />
  21 + <result column="startPickDateTime" jdbcType="TIMESTAMP" property="startPickDateTime" />
  22 + <result column="endPickDateTime" jdbcType="TIMESTAMP" property="endPickDateTime" />
  23 + <result column="rebatchLoc" jdbcType="VARCHAR" property="rebatchLoc" />
  24 + <result column="finishRebatch" jdbcType="INTEGER" property="finishRebatch" />
  25 + <result column="rebatchGroupCode" jdbcType="VARCHAR" property="rebatchGroupCode" />
  26 + <result column="allowRebatch" jdbcType="INTEGER" property="allowRebatch" />
  27 + <result column="taskProcessType" jdbcType="VARCHAR" property="taskProcessType" />
  28 + <result column="rebinBench" jdbcType="VARCHAR" property="rebinBench" />
  29 + <result column="rebined" jdbcType="INTEGER" property="rebined" />
  30 + <result column="startRebinDateTime" jdbcType="TIMESTAMP" property="startRebinDateTime" />
  31 + <result column="endRebinDateTime" jdbcType="TIMESTAMP" property="endRebinDateTime" />
  32 + <result column="rebinedBy" jdbcType="VARCHAR" property="rebinedBy" />
  33 + <result column="exceptionCode" jdbcType="VARCHAR" property="exceptionCode" />
  34 + <result column="exceptionHandledBy" jdbcType="VARCHAR" property="exceptionHandledBy" />
  35 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  36 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  37 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  38 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  39 + <result column="version" jdbcType="INTEGER" property="version" />
  40 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  41 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  42 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  43 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  44 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  45 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  46 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  47 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  48 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  49 + </resultMap>
  50 + <sql id="Base_Column_List">
  51 + <!--@mbg.generated-->
  52 + id, code, warehouseCode, companyCode, taskType, internalTaskType, referenceId, referenceCode,
  53 + assignedUser, confirmedBy, `enable`, waveId, pickingCartCode, pickingCartPos, containerCode,
  54 + startPickDateTime, endPickDateTime, rebatchLoc, finishRebatch, rebatchGroupCode,
  55 + allowRebatch, taskProcessType, rebinBench, rebined, startRebinDateTime, endRebinDateTime,
  56 + rebinedBy, exceptionCode, exceptionHandledBy, created, createdBy, lastUpdated, lastUpdatedBy,
  57 + version, userDef1, userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8,
  58 + processStamp
  59 + </sql>
  60 +</mapper>
0 61 \ No newline at end of file
... ...
src/main/resources/mybatis/task/TaskPreferenceMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.task.taskPreference.mapper.TaskPreferenceMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.task.taskPreference.domain.TaskPreference">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="name" jdbcType="VARCHAR" property="name" />
  8 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  9 + <result column="internalTaskType" jdbcType="VARCHAR" property="internalTaskType" />
  10 + <result column="taskType" jdbcType="VARCHAR" property="taskType" />
  11 + <result column="zoneCode" jdbcType="VARCHAR" property="zoneCode" />
  12 + <result column="taskInitMethod" jdbcType="VARCHAR" property="taskInitMethod" />
  13 + <result column="taskDirectedMethod" jdbcType="VARCHAR" property="taskDirectedMethod" />
  14 + <result column="fromAssignMethod" jdbcType="VARCHAR" property="fromAssignMethod" />
  15 + <result column="toAssignMethod" jdbcType="VARCHAR" property="toAssignMethod" />
  16 + <result column="pickMethod" jdbcType="VARCHAR" property="pickMethod" />
  17 + <result column="rfSuccessEnabled" jdbcType="INTEGER" property="rfSuccessEnabled" />
  18 + <result column="rfSuccessField" jdbcType="VARCHAR" property="rfSuccessField" />
  19 + <result column="rfSuccessMessage" jdbcType="VARCHAR" property="rfSuccessMessage" />
  20 + <result column="DEFAULTLpAsShipCont" jdbcType="INTEGER" property="DEFAULTLpAsShipCont" />
  21 + <result column="multiPickMethod" jdbcType="INTEGER" property="multiPickMethod" />
  22 + <result column="allowPartial" jdbcType="VARCHAR" property="allowPartial" />
  23 + <result column="pickDropLoc" jdbcType="VARCHAR" property="pickDropLoc" />
  24 + <result column="displayItemInfo" jdbcType="VARCHAR" property="displayItemInfo" />
  25 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  26 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  27 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  28 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  29 + <result column="version" jdbcType="INTEGER" property="version" />
  30 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  31 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  32 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  33 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  34 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  35 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  36 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  37 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  38 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  39 + <result column="showOpenTask" jdbcType="INTEGER" property="showOpenTask" />
  40 + </resultMap>
  41 + <sql id="Base_Column_List">
  42 + <!--@mbg.generated-->
  43 + id, `name`, warehouseCode, internalTaskType, taskType, zoneCode, taskInitMethod,
  44 + taskDirectedMethod, fromAssignMethod, toAssignMethod, pickMethod, rfSuccessEnabled,
  45 + rfSuccessField, rfSuccessMessage, DEFAULTLpAsShipCont, multiPickMethod, allowPartial,
  46 + pickDropLoc, displayItemInfo, created, createdBy, lastUpdated, lastUpdatedBy, version,
  47 + userDef1, userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8, processStamp,
  48 + showOpenTask
  49 + </sql>
  50 +</mapper>
0 51 \ No newline at end of file
... ...
src/main/resources/templates/general/bomDetail/add.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body class="white-bg">
  6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-bomDetail-add">
  8 + <div class="form-group">
  9 + <label class="col-sm-3 control-label"> 物料编码:</label>
  10 + <div class="col-sm-8">
  11 + <input id="materialCode" name="materialCode" class="form-control" type="text">
  12 + </div>
  13 + </div>
  14 + <div class="form-group">
  15 + <label class="col-sm-3 control-label">数量:</label>
  16 + <div class="col-sm-8">
  17 + <input id="qty" name="qty" class="form-control" type="text">
  18 + </div>
  19 + </div>
  20 + <div class="form-group">
  21 + <label class="col-sm-3 control-label">组套层次:</label>
  22 + <div class="col-sm-8">
  23 + <input id="buildLevel" name="buildLevel" class="form-control" type="text">
  24 + </div>
  25 + </div>
  26 + <div class="form-group">
  27 + <label class="col-sm-3 control-label">序号:</label>
  28 + <div class="col-sm-8">
  29 + <input id="buildSequence" name="buildSequence" class="form-control" type="text">
  30 + </div>
  31 + </div>
  32 + <div class="form-group">
  33 + <label class="col-sm-3 control-label">分配规则:</label>
  34 + <div class="col-sm-8">
  35 + <input id="allocationRule" name="allocationRule" class="form-control" type="text">
  36 + </div>
  37 + </div>
  38 + <div class="form-group">
  39 + <label class="col-sm-3 control-label">从货位:</label>
  40 + <div class="col-sm-8">
  41 + <input id="fromLocation" name="fromLocation" class="form-control" type="text">
  42 + </div>
  43 + </div>
  44 + <div class="form-group">
  45 + <div class="form-control-static col-sm-offset-9">
  46 + <button type="submit" class="btn btn-primary">提交</button>
  47 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
  48 + </div>
  49 + </div>
  50 + </form>
  51 +</div>
  52 +<div th:include="include::footer"></div>
  53 +<script type="text/javascript">
  54 + var prefix = ctx + "general/bomDetail";
  55 + $("#form-bomDetail-add").validate({
  56 + rules:{
  57 + materialCode:{
  58 + required:true
  59 + },
  60 + },
  61 + submitHandler: function(form) {
  62 + var tableValue = $("#form-bomDetail-add").serialize();
  63 + $.operate.save(prefix + "/add", tableValue);
  64 + }
  65 + });
  66 +</script>
  67 +</body>
  68 +</html>
... ...
src/main/resources/templates/general/bomDetail/bomDetail.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body>
  6 +
  7 +<div class="btn-group hidden-xs" id="toolbar" role="group">
  8 + <a class="btn btn-outline btn-success btn-rounded" onclick="$.operate.add()" shiro:hasPermission="general:bomDetail:add">
  9 + <i class="fa fa-plus"></i> 新增
  10 + </a>
  11 + <a class="btn btn-outline btn-danger btn-rounded" onclick="$.operate.batRemove()" shiro:hasPermission="general:bomDetail:remove">
  12 + <i class="fa fa-trash-o"></i> 删除
  13 + </a>
  14 +</div>
  15 +<div class="col-sm-12">
  16 + <table id="bootstrap-table" data-mobile-responsive="true" class="table table-bordered table-hover"></table>
  17 +</div>
  18 +
  19 +
  20 +<div th:include="include :: footer"></div>
  21 +<script th:inline="javascript">
  22 + var prefix = ctx + "general/bomDetail";
  23 + var editFlag = [[${@permission.hasPermi('general:bomDetail:edit')}]];
  24 + var removeFlag = [[${@permission.hasPermi('general:bomDetail:remove')}]];
  25 + var datas = [[${@dict.getType('sys_normal_disable')}]];
  26 + $(function() {
  27 + var options = {
  28 + url: prefix + "/list",
  29 + createUrl: prefix + "/add",
  30 + updateUrl: prefix + "/edit/{id}",
  31 + removeUrl: prefix + "/remove",
  32 + modalName: "商品详情",
  33 + queryParams:"bomId="+[[${bomHeaderId}]],
  34 + search: false,
  35 + sortName: "id",
  36 + sortOrder: "desc",
  37 + columns: [{
  38 + checkbox: true
  39 + },
  40 + {
  41 + field : 'id',
  42 + title : 'id'
  43 + },
  44 + {
  45 + field : 'warehouseCode',
  46 + title : '仓库代码'
  47 + },
  48 + {
  49 + field : 'companyCode',
  50 + title : '货主'
  51 + },
  52 + {
  53 + field : 'bomId',
  54 + title : '物料清单内部号' ,
  55 + visible:false
  56 + },
  57 + {
  58 + field : 'materialName',
  59 + title : '物料名称'
  60 + },
  61 + {
  62 + field : 'materialUnit',
  63 + title : '物料单位'
  64 + },
  65 + {
  66 + field : 'buildLevel',
  67 + title : '组套层次'
  68 + },
  69 + {
  70 + field : 'buildSequence',
  71 + title : '序号'
  72 + },
  73 + {
  74 + field : 'qty',
  75 + title : '数量'
  76 + },
  77 + {
  78 + field : 'allocationRule',
  79 + title : '分配规则'
  80 + },
  81 + {
  82 + field : 'fromLocation',
  83 + title : '分配规则'
  84 + },
  85 + {
  86 + field : 'enable',
  87 + title : '是否有效',
  88 + align: 'center',
  89 + formatter: function(value, row, index) {
  90 + return $.table.selectDictLabel(datas, value);
  91 + }
  92 + },
  93 + {
  94 + field : 'created',
  95 + title : '创建时间'
  96 + },
  97 + {
  98 + field : 'createdBy',
  99 + title : '创建用户'
  100 + },
  101 + {
  102 + field : 'lastUpdated',
  103 + title : '更新时间'
  104 + },
  105 + {
  106 + field : 'lastUpdatedBy',
  107 + title : '更新用户'
  108 + },
  109 + {
  110 + field : 'userDef1',
  111 + title : '自定义字段1' ,
  112 + visible:false
  113 + },
  114 + {
  115 + field : 'userDef2',
  116 + title : '自定义字段2' ,
  117 + visible:false
  118 + },
  119 + {
  120 + field : 'userDef3',
  121 + title : '自定义字段3' ,
  122 + visible:false
  123 + },
  124 + {
  125 + title: '操作',
  126 + align: 'center',
  127 + formatter: function(value, row, index) {
  128 + var actions = [];
  129 + actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
  130 + actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a>');
  131 + return actions.join('');
  132 + }
  133 + }]
  134 + };
  135 + $.table.init(options);
  136 + });
  137 +</script>
  138 +</body>
  139 +</html>
0 140 \ No newline at end of file
... ...
src/main/resources/templates/general/bomDetail/edit.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body class="white-bg">
  6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-bomDetail-add" th:object="${bomDetail}">
  8 + <div class="form-group">
  9 + <label class="col-sm-3 control-label"> 物料编码:</label>
  10 + <div class="col-sm-8">
  11 + <input id="materialCode" name="materialCode" class="form-control" type="text" th:field="*{materialCode}">
  12 + </div>
  13 + </div>
  14 + <div class="form-group">
  15 + <label class="col-sm-3 control-label">数量:</label>
  16 + <div class="col-sm-8">
  17 + <input id="qty" name="qty" class="form-control" type="text" th:field="*{qty}">
  18 + </div>
  19 + </div>
  20 + <div class="form-group">
  21 + <label class="col-sm-3 control-label">组套层次:</label>
  22 + <div class="col-sm-8">
  23 + <input id="buildLevel" name="buildLevel" class="form-control" type="text" th:field="*{buildLevel}">
  24 + </div>
  25 + </div>
  26 + <div class="form-group">
  27 + <label class="col-sm-3 control-label">序号:</label>
  28 + <div class="col-sm-8">
  29 + <input id="buildSequence" name="buildSequence" class="form-control" type="text" th:field="*{buildSequence}">
  30 + </div>
  31 + </div>
  32 + <div class="form-group">
  33 + <label class="col-sm-3 control-label">分配规则:</label>
  34 + <div class="col-sm-8">
  35 + <input id="allocationRule" name="allocationRule" class="form-control" type="text" th:field="*{allocationRule}">
  36 + </div>
  37 + </div>
  38 + <div class="form-group">
  39 + <label class="col-sm-3 control-label">从货位:</label>
  40 + <div class="col-sm-8">
  41 + <input id="fromLocation" name="fromLocation" class="form-control" type="text" th:field="*{fromLocation}" >
  42 + </div>
  43 + </div>
  44 + <div class="form-group">
  45 + <div class="form-control-static col-sm-offset-9">
  46 + <button type="submit" class="btn btn-primary">提交</button>
  47 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
  48 + </div>
  49 + </div>
  50 + </form>
  51 +</div>
  52 +<div th:include="include::footer"></div>
  53 +<script type="text/javascript">
  54 + var prefix = ctx + "general/bomDetail";
  55 + $("#form-bomDetail-add").validate({
  56 + rules:{
  57 + materialCode:{
  58 + required:true
  59 + },
  60 + },
  61 + submitHandler: function(form) {
  62 + var tableValue = $("#form-bomDetail-add").serialize();
  63 + $.operate.save(prefix + "/add", tableValue);
  64 + }
  65 + });
  66 +</script>
  67 +</body>
  68 +</html>
... ...
src/main/resources/templates/general/bomHeader/add.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body class="white-bg">
  6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-bomHeader-add">
  8 + <div class="form-group">
  9 + <label class="col-sm-3 control-label"> 物料编码:</label>
  10 + <div class="col-sm-8">
  11 + <input id="materialCode" name="materialCode" class="form-control" type="text">
  12 + </div>
  13 + </div>
  14 + <div class="form-group">
  15 + <label class="col-sm-3 control-label">数量:</label>
  16 + <div class="col-sm-8">
  17 + <input id="qty" name="qty" class="form-control" type="text">
  18 + </div>
  19 + </div>
  20 + <div class="form-group">
  21 + <label class="col-sm-3 control-label">修正号码:</label>
  22 + <div class="col-sm-8">
  23 + <input id="revisionNum" name="revisionNum" class="form-control" type="text">
  24 + </div>
  25 + </div>
  26 + <div class="form-group">
  27 + <label class="col-sm-3 control-label">加工说明:</label>
  28 + <div class="col-sm-8">
  29 + <input id="buildInstructions" name="buildInstructions" class="form-control" type="text">
  30 + </div>
  31 + </div>
  32 + <div class="form-group">
  33 + <label class="col-sm-3 control-label">加工货位:</label>
  34 + <div class="col-sm-8">
  35 + <input id="buildLoc" name="buildLoc" class="form-control" type="text">
  36 + </div>
  37 + </div>
  38 + <div class="form-group">
  39 + <label class="col-sm-3 control-label">有效起始日期:</label>
  40 + <div class="col-sm-8">
  41 + <input id="validFromDate" name="validFromDate" class="form-control" type="text">
  42 + </div>
  43 + </div>
  44 + <div class="form-group">
  45 + <label class="col-sm-3 control-label">有效结束日期:</label>
  46 + <div class="col-sm-8">
  47 + <input id="validEndDate" name="validEndDate" class="form-control" type="text">
  48 + </div>
  49 + </div>
  50 + <div class="form-group">
  51 + <label class="col-sm-3 control-label">优先级:</label>
  52 + <div class="col-sm-8">
  53 + <input id="priority" name="priority" class="form-control" type="text">
  54 + </div>
  55 + </div>
  56 + <div class="form-group">
  57 + <label class="col-sm-3 control-label">是否有效:</label>
  58 + <div class="col-sm-8">
  59 + <select id="enable" name="enable" class="form-control" >
  60 + <option value="0">有效</option>
  61 + <option value="1">无效</option>
  62 + </select>
  63 + </div>
  64 + </div>
  65 + <div class="form-group">
  66 + <label class="col-sm-3 control-label">是否虚拟商品:</label>
  67 + <div class="col-sm-8">
  68 + <select id="isVirtualBom" name="isVirtualBom" class="form-control">
  69 + <option value="0">不是</option>
  70 + <option value="1">是</option>
  71 + </select>
  72 + </div>
  73 + </div>
  74 + <div class="form-group">
  75 + <div class="form-control-static col-sm-offset-9">
  76 + <button type="submit" class="btn btn-primary">提交</button>
  77 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
  78 + </div>
  79 + </div>
  80 + </form>
  81 +</div>
  82 +<div th:include="include::footer"></div>
  83 +<script type="text/javascript">
  84 + var prefix = ctx + "general/bomHeader";
  85 + $("#form-bomHeader-add").validate({
  86 + rules:{
  87 + materialCode:{
  88 + required:true
  89 + },
  90 + },
  91 + submitHandler: function(form) {
  92 + var tableValue = $("#form-bomHeader-add").serialize();
  93 + tableValue = formValueReplace(tableValue, "enable", $("#enable option:selected").val());
  94 + tableValue = formValueReplace(tableValue, "isVirtualBom", $("#isVirtualBom option:selected").val());
  95 + $.operate.save(prefix + "/add", tableValue);
  96 + }
  97 + });
  98 + $(function () {
  99 + layui.use('laydate', function() {
  100 + var laydate = layui.laydate;
  101 + laydate.render({ elem: '#validFromDate', theme: 'molv', format: 'yyyy-MM-dd' });
  102 + laydate.render({ elem: '#validEndDate', theme: 'molv', format: 'yyyy-MM-dd' });
  103 + });
  104 + });
  105 +</script>
  106 +</body>
  107 +</html>
... ...
src/main/resources/templates/general/bomHeader/bomHeader.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body class="gray-bg">
  6 +
  7 +<div class="container-div">
  8 + <div class="row">
  9 + <div class="col-sm-12 select-info">
  10 + <ul id="myTab" class="nav nav-tabs">
  11 + <li class="active"><a href="#tabHeader" data-toggle="tab">主表</a></li>
  12 + <li><a href="#tabDetail" data-toggle="tab">明细</a></li>
  13 + </ul>
  14 + <div id="myTabContent" class="tab-content">
  15 + <div class="tab-pane fade in active" id="tabHeader">
  16 + <div class="col-sm-12 select-info">
  17 + <form id="alarmFlow-form">
  18 + <div class="select-list">
  19 + <ul>
  20 + <li>
  21 + 物料名称:<input type="text" name="materialName"/>
  22 + </li>
  23 + <li>
  24 + 物料编码:<input type="text" name="materialCode"/>
  25 + </li>
  26 + <li class="time">
  27 + <label>创建时间: </label>
  28 + <input type="text" class="time-input" id="startTime" placeholder="开始时间"
  29 + name="params[createdBegin]"/>
  30 + <span>-</span>
  31 + <input type="text" class="time-input" id="endTime" placeholder="结束时间"
  32 + name="params[createdEnd]"/>
  33 + </li>
  34 + <li>
  35 + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
  36 + class="fa fa-search"></i>&nbsp;搜索</a>
  37 + <!--<a class="btn btn-success btn-rounded btn-sm" onclick="$.table.exportExcel()" shiro:hasPermission="system:role:export"><i class="fa fa-download"></i>&nbsp;导出</a>-->
  38 + </li>
  39 + </ul>
  40 + </div>
  41 + </form>
  42 + </div>
  43 +
  44 +
  45 + <div class="btn-group hidden-xs" id="toolbar" role="group">
  46 + <a class="btn btn-outline btn-success btn-rounded" onclick="$.operate.add()"
  47 + shiro:hasPermission="general:bomHeader:add">
  48 + <i class="fa fa-plus"></i> 新增
  49 + </a>
  50 + <a class="btn btn-outline btn-danger btn-rounded" onclick="$.operate.batRemove()"
  51 + shiro:hasPermission="general:bomHeader:remove">
  52 + <i class="fa fa-trash-o"></i> 删除
  53 + </a>
  54 + </div>
  55 +
  56 + <table id="bootstrap-table" data-mobile-responsive="true" class="table table-bordered table-hover"></table>
  57 + </div>
  58 +
  59 + <div class="tab-pane fade" id="tabDetail">
  60 + <table id="bootstrap-table1" data-mobile-responsive="true"
  61 + class="table table-bordered table-hover"></table>
  62 + </div>
  63 + </div>
  64 + </div>
  65 + </div>
  66 +</div>
  67 +<div th:include="include :: footer"></div>
  68 +<script th:inline="javascript">
  69 + var prefix = ctx + "general/bomHeader";
  70 + var prefix1 = ctx + "general/bomDetail";
  71 + var editFlag = [[${@permission.hasPermi('general:bomHeader:edit')}]];
  72 + var removeFlag = [[${@permission.hasPermi('general:bomHeader:remove')}]];
  73 + $(function() {
  74 + var options = {
  75 + url: prefix + "/list",
  76 + createUrl: prefix + "/add",
  77 + updateUrl: prefix + "/edit/{id}",
  78 + removeUrl: prefix + "/remove",
  79 + modalName: "商品",
  80 + search: false,
  81 + sortName: "id",
  82 + sortOrder: "desc",
  83 + columns: [{
  84 + checkbox: true
  85 + },
  86 + {
  87 + field : 'id',
  88 + title : 'id'
  89 + },
  90 + {
  91 + field : 'materialCode',
  92 + title : '物料编码'
  93 + },
  94 + {
  95 + field : 'materialName',
  96 + title : '物料名称'
  97 + },
  98 + {
  99 + field : 'warehouseCode',
  100 + title : '仓库代码'
  101 + },
  102 + {
  103 + field : 'companyCode',
  104 + title : '货主编码'
  105 + },
  106 + {
  107 + field : 'materialSpec',
  108 + title : '物料规格'
  109 + },
  110 + {
  111 + field : 'materialUnit',
  112 + title : ' 物料单位'
  113 + },
  114 + {
  115 + field : 'qty',
  116 + title : '数量'
  117 + },
  118 + {
  119 + field : 'revisionNum',
  120 + title : '修正号码'
  121 + },
  122 + {
  123 + field : 'buildInstructions',
  124 + title : '加工说明'
  125 + },
  126 + {
  127 + field : 'buildLoc',
  128 + title : '加工货位'
  129 + },
  130 + {
  131 + field : 'validFromDate',
  132 + title : '有效起止日期'
  133 + },
  134 + {
  135 + field : 'validEndDate',
  136 + title : '有效结束日期'
  137 + },
  138 + {
  139 + field : 'priority',
  140 + title : '优先级'
  141 + },
  142 + {
  143 + field : 'version',
  144 + title : '数据版本',
  145 + visible : false
  146 + },
  147 + {
  148 + field : 'isVirtualBom',
  149 + title : '是否为虚拟商品',
  150 + visible : false
  151 + },
  152 + {
  153 + field : 'created',
  154 + title : '创建时间',
  155 + visible : false
  156 + },
  157 + {
  158 + field : 'createdBy',
  159 + title : '创建用户',
  160 + visible : false
  161 + },
  162 + {
  163 + field : 'lastUpdated',
  164 + title : '更新时间',
  165 + visible : false
  166 + },
  167 + {
  168 + field : 'lastUpdatedBy',
  169 + title : '更新用户',
  170 + visible : false
  171 + },
  172 + {
  173 + field : 'userDef1',
  174 + title : '自定义字段1' ,
  175 + visible:false
  176 + },
  177 + {
  178 + field : 'userDef2',
  179 + title : '自定义字段2' ,
  180 + visible:false
  181 + },
  182 + {
  183 + field : 'userDef3',
  184 + title : '自定义字段3' ,
  185 + visible:false
  186 + },
  187 + {
  188 + title: '操作',
  189 + align: 'center',
  190 + formatter: function(value, row, index) {
  191 + var actions = [];
  192 + actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
  193 + actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a>');
  194 + return actions.join('');
  195 + }
  196 + }]
  197 + };
  198 + $.table.init(options);
  199 + });
  200 +
  201 + function detail(id, code) {
  202 + // console.log(id);
  203 + // dictid=id;
  204 + var url = prefix1+"/list/" + id;
  205 + createtable(url);
  206 + }
  207 +
  208 + function createtable(url) {
  209 + $("#tabDetail").children().remove();
  210 + $("#myTab li").removeClass("active");
  211 + var height = $(document).height()-100 + 'px';
  212 + var str = '<iframe class="huaheng_iframe" name="iframe" width="100%" height="' + height + '" src="' + url + '" frameborder="0" data-id="' + url + '" seamless></iframe>';
  213 + $("#tabDetail").append(str);
  214 + $(".tab-pane").removeClass("in active");
  215 + $("#myTab li:eq(1)").addClass("active");
  216 + $("#tabDetail").addClass("in active");
  217 + }
  218 +</script>
  219 +</body>
  220 +</html>
0 221 \ No newline at end of file
... ...
src/main/resources/templates/general/bomHeader/edit.html 0 → 100644
  1 +<!DOCTYPE HTML>
  2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org">
  3 +<meta charset="utf-8">
  4 +<head th:include="include :: header"></head>
  5 +<body class="white-bg">
  6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-bomHeader-edit" th:object="${bomHeader}">
  8 + <div class="form-group">
  9 + <label class="col-sm-3 control-label"> 物料编码:</label>
  10 + <div class="col-sm-8">
  11 + <input id="materialCode" name="materialCode" class="form-control" type="text" th:field="*{materialCode}">
  12 + </div>
  13 + </div>
  14 + <div class="form-group">
  15 + <label class="col-sm-3 control-label">数量:</label>
  16 + <div class="col-sm-8">
  17 + <input id="qty" name="qty" class="form-control" type="text" th:field="*{qty}">
  18 + </div>
  19 + </div>
  20 + <div class="form-group">
  21 + <label class="col-sm-3 control-label">修正号码:</label>
  22 + <div class="col-sm-8">
  23 + <input id="revisionNum" name="revisionNum" class="form-control" type="text" th:field="*{revisionNum}">
  24 + </div>
  25 + </div>
  26 + <div class="form-group">
  27 + <label class="col-sm-3 control-label">加工说明:</label>
  28 + <div class="col-sm-8">
  29 + <input id="buildInstructions" name="buildInstructions" class="form-control" type="text" th:field="*{buildInstructions}">
  30 + </div>
  31 + </div>
  32 + <div class="form-group">
  33 + <label class="col-sm-3 control-label">加工货位:</label>
  34 + <div class="col-sm-8">
  35 + <input id="buildLoc" name="buildLoc" class="form-control" type="text" th:field="*{buildLoc}">
  36 + </div>
  37 + </div>
  38 + <div class="form-group">
  39 + <label class="col-sm-3 control-label">有效起始日期:</label>
  40 + <div class="col-sm-8">
  41 + <input id="validFromDate" name="validFromDate" class="time-input" type="text" th:field="*{validFromDate}">
  42 + </div>
  43 + </div>
  44 + <div class="form-group">
  45 + <label class="col-sm-3 control-label">有效结束日期:</label>
  46 + <div class="col-sm-8">
  47 + <input id="validEndDate" name="validEndDate" class="time-input" type="text" th:field="*{validEndDate}">
  48 + </div>
  49 + </div>
  50 + <div class="form-group">
  51 + <label class="col-sm-3 control-label">优先级:</label>
  52 + <div class="col-sm-8">
  53 + <input id="priority" name="priority" class="form-control" type="text" th:field="*{priority}">
  54 + </div>
  55 + </div>
  56 + <div class="form-group">
  57 + <label class="col-sm-3 control-label">是否有效:</label>
  58 + <div class="col-sm-8">
  59 + <select id="enable" name="enable" class="form-control" th:field="*{enable}">
  60 + <option value="0">有效</option>
  61 + <option value="1">无效</option>
  62 + </select>
  63 + </div>
  64 + </div>
  65 + <div class="form-group">
  66 + <label class="col-sm-3 control-label">是否虚拟商品:</label>
  67 + <div class="col-sm-8">
  68 + <select id="isVirtualBom" name="isVirtualBom" class="form-control" th:field="*{isVirtualBom}" >
  69 + <option value="0">不是</option>
  70 + <option value="1">是</option>
  71 + </select>
  72 + </div>
  73 + </div>
  74 + <!--<div class="form-group"> -->
  75 + <!--<label class="col-sm-3 control-label">自定义字段1:</label>-->
  76 + <!--<div class="col-sm-8">-->
  77 + <!--<input id="userDef1" name="userDef1" class="form-control" type="text">-->
  78 + <!--</div>-->
  79 + <!--</div>-->
  80 + <!--<div class="form-group"> -->
  81 + <!--<label class="col-sm-3 control-label">自定义字段2:</label>-->
  82 + <!--<div class="col-sm-8">-->
  83 + <!--<input id="userDef2" name="userDef2" class="form-control" type="text">-->
  84 + <!--</div>-->
  85 + <!--</div>-->
  86 + <!--<div class="form-group"> -->
  87 + <!--<label class="col-sm-3 control-label">自定义字段3:</label>-->
  88 + <!--<div class="col-sm-8">-->
  89 + <!--<input id="userDef3" name="userDef3" class="form-control" type="text">-->
  90 + <!--</div>-->
  91 + <!--</div>-->
  92 + <div class="form-group">
  93 + <div class="form-control-static col-sm-offset-9">
  94 + <button type="submit" class="btn btn-primary">提交</button>
  95 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
  96 + </div>
  97 + </div>
  98 + </form>
  99 +</div>
  100 +<div th:include="include::footer"></div>
  101 +<script type="text/javascript">
  102 + var prefix = ctx + "general/bomHeader";
  103 + $("#form-bomHeader-add").validate({
  104 + rules:{
  105 + materialCode:{
  106 + required:true
  107 + },
  108 + },
  109 + submitHandler: function(form) {
  110 + var tableValue = $("#form-bomHeader-add").serialize();
  111 + tableValue = formValueReplace(tableValue, "enable", $("#enable option:selected").val());
  112 + tableValue = formValueReplace(tableValue, "isVirtualBom", $("#isVirtualBom option:selected").val());
  113 + $.operate.save(prefix + "/add", tableValue);
  114 + }
  115 + });
  116 +
  117 + $(function () {
  118 + layui.use('laydate', function() {
  119 + var laydate = layui.laydate;
  120 + laydate.render({ elem: '#validFromDate', theme: 'molv', format: 'yyyy-MM-dd' });
  121 + laydate.render({ elem: '#validEndDate', theme: 'molv', format: 'yyyy-MM-dd' });
  122 + });
  123 + });
  124 +</script>
  125 +</body>
  126 +</html>
... ...
src/main/resources/templates/general/company/add.html
... ... @@ -91,6 +91,8 @@
91 91 <input id="email" name="email" class="form-control" type="text">
92 92 </div>
93 93 </div>
  94 +
  95 + <input id="filePath" name="filePath" class="form-control" type="file">
94 96 <!--<div class="form-group"> -->
95 97 <!--<label class="col-sm-3 control-label">自定义字段1:</label>-->
96 98 <!--<div class="col-sm-8">-->
... ...
src/main/resources/templates/general/material/add.html
... ... @@ -14,7 +14,9 @@
14 14 <div class="form-group">
15 15 <label class="col-sm-3 control-label">货主编码:</label>
16 16 <div class="col-sm-8">
17   - <input id="companyCode" name="companyCode" class="form-control" type="text">
  17 + <select id="companyCode" name="companyCode" class="form-control" th:with="companyList=${@companyService.selectCompanyByCurrentUserId()}">
  18 + <option th:each="company : ${companyList}" th:text="${company['name']}" th:value="${company['code']}"></option>
  19 + </select>
18 20 </div>
19 21 </div>
20 22 <div class="form-group">
... ... @@ -32,9 +34,7 @@
32 34 <div class="form-group">
33 35 <label class="col-sm-3 control-label">单位:</label>
34 36 <div class="col-sm-8">
35   - <select id="unit" name="unit" class="form-control" th:with="materialUnit=${@materialUnitService.getUnit()}">
36   - <option th:each="item : ${materialUnit}" th:text="${item['unit']}" th:value="${item['unit']}"></option>
37   - </select>
  37 + <input id="unit" name="unit" class="form-control" type="text">
38 38 </div>
39 39 </div>
40 40 <div class="form-group">
... ... @@ -257,6 +257,7 @@
257 257 // var tableValue = $.common.getTableValue("#form-material-add");
258 258 // $.operate.save(prefix + "/add", tableValue);
259 259 var tableValue = $("#form-material-add").serialize();
  260 + tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val())
260 261 tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));
261 262 $.operate.save(prefix + "/add", tableValue);
262 263 }
... ...
src/main/resources/templates/general/material/material.html
... ... @@ -169,26 +169,26 @@
169 169 title : '收货预警天数' ,
170 170 visible:false
171 171 },
172   - {
173   - field : "version",
174   - title: "数据版本"
175   - },
176   - {
177   - field : 'created',
178   - title : '创建时间'
179   - },
180   - {
181   - field : 'createdBy',
182   - title : '创建用户'
183   - },
184   - {
185   - field : 'lastUpdated',
186   - title : '更新时间'
187   - },
188   - {
189   - field : 'lastUpdatedBy',
190   - title : '更新用户'
191   - },
  172 + // {
  173 + // field : "version",
  174 + // title: "数据版本"
  175 + // },
  176 + // {
  177 + // field : 'created',
  178 + // title : '创建时间'
  179 + // },
  180 + // {
  181 + // field : 'createdBy',
  182 + // title : '创建用户'
  183 + // },
  184 + // {
  185 + // field : 'lastUpdated',
  186 + // title : '更新时间'
  187 + // },
  188 + // {
  189 + // field : 'lastUpdatedBy',
  190 + // title : '更新用户'
  191 + // },
192 192 {
193 193 field : 'enable',
194 194 title : '状态' ,
... ...
src/main/resources/templates/system/user/add.html
... ... @@ -71,6 +71,16 @@
71 71 </label>
72 72 </div>
73 73 </div>
  74 +
  75 + <div class="form-group">
  76 + <label class="col-sm-3 control-label">仓库:</label>
  77 + <div class="col-sm-8">
  78 + <label th:each="warehouse:${warehouseList}" class="checkbox-inline i-checks">
  79 + <input name="warehouseCode" type="checkbox" th:value="${warehouse.value}" th:text=" ${warehouse.name}" th:disabled="${warehouse.enable == false} ">
  80 + </label>
  81 + </div>
  82 + </div>
  83 +
74 84 <div class="form-group">
75 85 <label class="col-sm-3 control-label">角色:</label>
76 86 <div class="col-sm-8">
... ... @@ -188,6 +198,7 @@
188 198 var sex = $("#sex option:selected").val();
189 199 var enable = $("input[name='enable']").is(':checked') == true ? 1 : 0;
190 200 var roleIds = $.form.selectCheckeds("role");
  201 + var warehouseCodeList = $.form.selectCheckeds("warehouseCode");
191 202 var companyIdList = $.form.selectCheckeds("company");
192 203 $.ajax({
193 204 cache : true,
... ... @@ -204,6 +215,7 @@
204 215 "sex": sex,
205 216 "enable": enable,
206 217 "roleIds": roleIds,
  218 + "warehouseCodeList": warehouseCodeList,
207 219 "companyIdList": companyIdList
208 220 },
209 221 async : false,
... ...
src/main/resources/templates/system/user/edit.html
... ... @@ -66,6 +66,16 @@
66 66 </label>
67 67 </div>
68 68 </div>
  69 +
  70 + <div class="form-group">
  71 + <label class="col-sm-3 control-label">仓库:</label>
  72 + <div class="col-sm-8">
  73 + <label th:each="warehouse:${warehouses}" class="checkbox-inline i-checks">
  74 + <input name="warehouse" type="checkbox" th:value="${warehouse.code}" th:text="${warehouse.name}" th:checked="${warehouse.flag}" th:disabled="${warehouse.enable == false}">
  75 + </label>
  76 + </div>
  77 + </div>
  78 +
69 79 <div class="form-group">
70 80 <label class="col-sm-3 control-label">角色:</label>
71 81 <div class="col-sm-8">
... ... @@ -160,6 +170,7 @@
160 170 var sex = $("#sex option:selected").val();
161 171 var enable = $("input[name='enable']").is(':checked') == true ? 1 : 0;
162 172 var roleIds = $.form.selectCheckeds("role");
  173 + var warehouseCodeList = $.form.selectCheckeds("warehouse");
163 174 var companyIdList = $.form.selectCheckeds("company");
164 175 $.ajax({
165 176 cache : true,
... ... @@ -174,6 +185,7 @@
174 185 "sex": sex,
175 186 "enable": enable,
176 187 "roleIds": roleIds,
  188 + "warehouseCodeList": warehouseCodeList,
177 189 "companyIdList": companyIdList
178 190 },
179 191 async : false,
... ...