波次设置

master
e 2020-02-01 16:21:43 +08:00
parent f0ee3fdc08
commit f4861056f8
9 changed files with 0 additions and 1168 deletions

View File

@ -1,406 +0,0 @@
package com.zzjee.ba.controller;
import com.zzjee.ba.entity.WmsWaveConfEntity;
import com.zzjee.ba.service.WmsWaveConfServiceI;
import java.util.ArrayList;
import java.util.List;
import java.text.SimpleDateFormat;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView;
import org.jeecgframework.core.common.controller.BaseController;
import org.jeecgframework.core.common.exception.BusinessException;
import org.jeecgframework.core.common.hibernate.qbc.CriteriaQuery;
import org.jeecgframework.core.common.model.common.TreeChildCount;
import org.jeecgframework.core.common.model.json.AjaxJson;
import org.jeecgframework.core.common.model.json.DataGrid;
import org.jeecgframework.core.constant.Globals;
import org.jeecgframework.core.util.StringUtil;
import org.jeecgframework.tag.core.easyui.TagUtil;
import org.jeecgframework.web.system.pojo.base.TSDepart;
import org.jeecgframework.web.system.service.SystemService;
import org.jeecgframework.core.util.MyBeanUtils;
import java.io.OutputStream;
import org.jeecgframework.core.util.BrowserUtils;
import org.jeecgframework.poi.excel.ExcelExportUtil;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.entity.TemplateExportParams;
import org.jeecgframework.poi.excel.entity.vo.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.vo.TemplateExcelConstants;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.jeecgframework.core.util.ResourceUtil;
import java.io.IOException;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import java.util.Map;
import java.util.HashMap;
import org.jeecgframework.core.util.ExceptionUtil;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.ResponseStatus;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
import org.jeecgframework.core.beanvalidator.BeanValidators;
import java.util.Set;
import javax.validation.ConstraintViolation;
import javax.validation.Validator;
import java.net.URI;
import org.springframework.http.MediaType;
import org.springframework.web.util.UriComponentsBuilder;
/**
* @Title: Controller
* @Description:
* @author onlineGenerator
* @date 2019-12-11 09:08:25
* @version V1.0
*
*/
@Controller
@RequestMapping("/wmsWaveConfController")
public class WmsWaveConfController extends BaseController {
/**
* Logger for this class
*/
private static final Logger logger = Logger.getLogger(WmsWaveConfController.class);
@Autowired
private WmsWaveConfServiceI wmsWaveConfService;
@Autowired
private SystemService systemService;
@Autowired
private Validator validator;
/**
*
*
* @return
*/
@RequestMapping(params = "list")
public ModelAndView list(HttpServletRequest request) {
return new ModelAndView("com/zzjee/ba/wmsWaveConfList");
}
/**
* easyui AJAX
*
* @param request
* @param response
* @param dataGrid
* @param user
*/
@RequestMapping(params = "datagrid")
public void datagrid(WmsWaveConfEntity wmsWaveConf,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) {
CriteriaQuery cq = new CriteriaQuery(WmsWaveConfEntity.class, dataGrid);
//查询条件组装器
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, wmsWaveConf, request.getParameterMap());
try{
//自定义追加查询条件
}catch (Exception e) {
throw new BusinessException(e.getMessage());
}
cq.add();
this.wmsWaveConfService.getDataGridReturn(cq, true);
TagUtil.datagrid(response, dataGrid);
}
/**
*
*
* @return
*/
@RequestMapping(params = "doDel")
@ResponseBody
public AjaxJson doDel(WmsWaveConfEntity wmsWaveConf, HttpServletRequest request) {
String message = null;
AjaxJson j = new AjaxJson();
wmsWaveConf = systemService.getEntity(WmsWaveConfEntity.class, wmsWaveConf.getId());
message = "波次配置删除成功";
try{
wmsWaveConfService.delete(wmsWaveConf);
systemService.addLog(message, Globals.Log_Type_DEL, Globals.Log_Leavel_INFO);
}catch(Exception e){
e.printStackTrace();
message = "波次配置删除失败";
throw new BusinessException(e.getMessage());
}
j.setMsg(message);
return j;
}
/**
*
*
* @return
*/
@RequestMapping(params = "doBatchDel")
@ResponseBody
public AjaxJson doBatchDel(String ids,HttpServletRequest request){
String message = null;
AjaxJson j = new AjaxJson();
message = "波次配置删除成功";
try{
for(String id:ids.split(",")){
WmsWaveConfEntity wmsWaveConf = systemService.getEntity(WmsWaveConfEntity.class,
id
);
wmsWaveConfService.delete(wmsWaveConf);
systemService.addLog(message, Globals.Log_Type_DEL, Globals.Log_Leavel_INFO);
}
}catch(Exception e){
e.printStackTrace();
message = "波次配置删除失败";
throw new BusinessException(e.getMessage());
}
j.setMsg(message);
return j;
}
/**
*
*
* @param ids
* @return
*/
@RequestMapping(params = "doAdd")
@ResponseBody
public AjaxJson doAdd(WmsWaveConfEntity wmsWaveConf, HttpServletRequest request) {
String message = null;
AjaxJson j = new AjaxJson();
message = "波次配置添加成功";
try{
wmsWaveConfService.save(wmsWaveConf);
systemService.addLog(message, Globals.Log_Type_INSERT, Globals.Log_Leavel_INFO);
}catch(Exception e){
e.printStackTrace();
message = "波次配置添加失败";
throw new BusinessException(e.getMessage());
}
j.setMsg(message);
return j;
}
/**
*
*
* @param ids
* @return
*/
@RequestMapping(params = "doUpdate")
@ResponseBody
public AjaxJson doUpdate(WmsWaveConfEntity wmsWaveConf, HttpServletRequest request) {
String message = null;
AjaxJson j = new AjaxJson();
message = "波次配置更新成功";
WmsWaveConfEntity t = wmsWaveConfService.get(WmsWaveConfEntity.class, wmsWaveConf.getId());
try {
MyBeanUtils.copyBeanNotNull2Bean(wmsWaveConf, t);
wmsWaveConfService.saveOrUpdate(t);
systemService.addLog(message, Globals.Log_Type_UPDATE, Globals.Log_Leavel_INFO);
} catch (Exception e) {
e.printStackTrace();
message = "波次配置更新失败";
throw new BusinessException(e.getMessage());
}
j.setMsg(message);
return j;
}
/**
*
*
* @return
*/
@RequestMapping(params = "goAdd")
public ModelAndView goAdd(WmsWaveConfEntity wmsWaveConf, HttpServletRequest req) {
if (StringUtil.isNotEmpty(wmsWaveConf.getId())) {
wmsWaveConf = wmsWaveConfService.getEntity(WmsWaveConfEntity.class, wmsWaveConf.getId());
req.setAttribute("wmsWaveConfPage", wmsWaveConf);
}
return new ModelAndView("com/zzjee/ba/wmsWaveConf-add");
}
/**
*
*
* @return
*/
@RequestMapping(params = "goUpdate")
public ModelAndView goUpdate(WmsWaveConfEntity wmsWaveConf, HttpServletRequest req) {
if (StringUtil.isNotEmpty(wmsWaveConf.getId())) {
wmsWaveConf = wmsWaveConfService.getEntity(WmsWaveConfEntity.class, wmsWaveConf.getId());
req.setAttribute("wmsWaveConfPage", wmsWaveConf);
}
return new ModelAndView("com/zzjee/ba/wmsWaveConf-update");
}
/**
*
*
* @return
*/
@RequestMapping(params = "upload")
public ModelAndView upload(HttpServletRequest req) {
req.setAttribute("controller_name","wmsWaveConfController");
return new ModelAndView("common/upload/pub_excel_upload");
}
/**
* excel
*
* @param request
* @param response
*/
@RequestMapping(params = "exportXls")
public String exportXls(WmsWaveConfEntity wmsWaveConf,HttpServletRequest request,HttpServletResponse response
, DataGrid dataGrid,ModelMap modelMap) {
CriteriaQuery cq = new CriteriaQuery(WmsWaveConfEntity.class, dataGrid);
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, wmsWaveConf, request.getParameterMap());
List<WmsWaveConfEntity> wmsWaveConfs = this.wmsWaveConfService.getListByCriteriaQuery(cq,false);
modelMap.put(NormalExcelConstants.FILE_NAME,"波次配置");
modelMap.put(NormalExcelConstants.CLASS,WmsWaveConfEntity.class);
modelMap.put(NormalExcelConstants.PARAMS,new ExportParams("波次配置列表", "导出人:"+ResourceUtil.getSessionUserName().getRealName(),
"导出信息"));
modelMap.put(NormalExcelConstants.DATA_LIST,wmsWaveConfs);
return NormalExcelConstants.JEECG_EXCEL_VIEW;
}
/**
* excel 使
*
* @param request
* @param response
*/
@RequestMapping(params = "exportXlsByT")
public String exportXlsByT(WmsWaveConfEntity wmsWaveConf,HttpServletRequest request,HttpServletResponse response
, DataGrid dataGrid,ModelMap modelMap) {
modelMap.put(NormalExcelConstants.FILE_NAME,"波次配置");
modelMap.put(NormalExcelConstants.CLASS,WmsWaveConfEntity.class);
modelMap.put(NormalExcelConstants.PARAMS,new ExportParams("波次配置列表", "导出人:"+ResourceUtil.getSessionUserName().getRealName(),
"导出信息"));
modelMap.put(NormalExcelConstants.DATA_LIST,new ArrayList());
return NormalExcelConstants.JEECG_EXCEL_VIEW;
}
@SuppressWarnings("unchecked")
@RequestMapping(params = "importExcel", method = RequestMethod.POST)
@ResponseBody
public AjaxJson importExcel(HttpServletRequest request, HttpServletResponse response) {
AjaxJson j = new AjaxJson();
MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
MultipartFile file = entity.getValue();// 获取上传文件对象
ImportParams params = new ImportParams();
params.setTitleRows(2);
params.setHeadRows(1);
params.setNeedSave(true);
try {
List<WmsWaveConfEntity> listWmsWaveConfEntitys = ExcelImportUtil.importExcel(file.getInputStream(),WmsWaveConfEntity.class,params);
for (WmsWaveConfEntity wmsWaveConf : listWmsWaveConfEntitys) {
wmsWaveConfService.save(wmsWaveConf);
}
j.setMsg("文件导入成功!");
} catch (Exception e) {
j.setMsg("文件导入失败!");
logger.error(ExceptionUtil.getExceptionMessage(e));
}finally{
try {
file.getInputStream().close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
return j;
}
@RequestMapping(method = RequestMethod.GET)
@ResponseBody
public List<WmsWaveConfEntity> list() {
List<WmsWaveConfEntity> listWmsWaveConfs=wmsWaveConfService.getList(WmsWaveConfEntity.class);
return listWmsWaveConfs;
}
@RequestMapping(value = "/{id}", method = RequestMethod.GET)
@ResponseBody
public ResponseEntity<?> get(@PathVariable("id") String id) {
WmsWaveConfEntity task = wmsWaveConfService.get(WmsWaveConfEntity.class, id);
if (task == null) {
return new ResponseEntity(HttpStatus.NOT_FOUND);
}
return new ResponseEntity(task, HttpStatus.OK);
}
@RequestMapping(method = RequestMethod.POST, consumes = MediaType.APPLICATION_JSON_VALUE)
@ResponseBody
public ResponseEntity<?> create(@RequestBody WmsWaveConfEntity wmsWaveConf, UriComponentsBuilder uriBuilder) {
//调用JSR303 Bean Validator进行校验如果出错返回含400错误码及json格式的错误信息.
Set<ConstraintViolation<WmsWaveConfEntity>> failures = validator.validate(wmsWaveConf);
if (!failures.isEmpty()) {
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
}
//保存
try{
wmsWaveConfService.save(wmsWaveConf);
} catch (Exception e) {
e.printStackTrace();
return new ResponseEntity(HttpStatus.NO_CONTENT);
}
//按照Restful风格约定创建指向新任务的url, 也可以直接返回id或对象.
String id = wmsWaveConf.getId();
URI uri = uriBuilder.path("/rest/wmsWaveConfController/" + id).build().toUri();
HttpHeaders headers = new HttpHeaders();
headers.setLocation(uri);
return new ResponseEntity(headers, HttpStatus.CREATED);
}
@RequestMapping(value = "/{id}", method = RequestMethod.PUT, consumes = MediaType.APPLICATION_JSON_VALUE)
public ResponseEntity<?> update(@RequestBody WmsWaveConfEntity wmsWaveConf) {
//调用JSR303 Bean Validator进行校验如果出错返回含400错误码及json格式的错误信息.
Set<ConstraintViolation<WmsWaveConfEntity>> failures = validator.validate(wmsWaveConf);
if (!failures.isEmpty()) {
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
}
//保存
try{
wmsWaveConfService.saveOrUpdate(wmsWaveConf);
} catch (Exception e) {
e.printStackTrace();
return new ResponseEntity(HttpStatus.NO_CONTENT);
}
//按Restful约定返回204状态码, 无内容. 也可以返回200状态码.
return new ResponseEntity(HttpStatus.NO_CONTENT);
}
@RequestMapping(value = "/{id}", method = RequestMethod.DELETE)
@ResponseStatus(HttpStatus.NO_CONTENT)
public void delete(@PathVariable("id") String id) {
wmsWaveConfService.deleteEntityById(WmsWaveConfEntity.class, id);
}
}

View File

@ -1,312 +0,0 @@
package com.zzjee.ba.entity;
import java.math.BigDecimal;
import java.util.Date;
import java.lang.String;
import java.lang.Double;
import java.lang.Integer;
import java.math.BigDecimal;
import javax.xml.soap.Text;
import java.sql.Blob;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import org.hibernate.annotations.GenericGenerator;
import javax.persistence.SequenceGenerator;
import org.jeecgframework.poi.excel.annotation.Excel;
/**
* @Title: Entity
* @Description:
* @author onlineGenerator
* @date 2019-12-11 09:08:25
* @version V1.0
*
*/
@Entity
@Table(name = "wms_wave_conf", schema = "")
@SuppressWarnings("serial")
public class WmsWaveConfEntity implements java.io.Serializable {
/**主键*/
private String id;
/**创建人名称*/
private String createName;
/**创建人登录名称*/
private String createBy;
/**创建日期*/
private Date createDate;
/**更新人名称*/
private String updateName;
/**更新人登录名称*/
private String updateBy;
/**更新日期*/
private Date updateDate;
/**所属部门*/
private String sysOrgCode;
/**所属公司*/
private String sysCompanyCode;
/**流程状态*/
private String bpmStatus;
/**配送点*/
@Excel(name="配送点")
private String peisondian;
/**波次类型*/
@Excel(name="波次类型")
private String waveType;
/**备用1*/
@Excel(name="备用1")
private String wvBy1;
/**备用2*/
@Excel(name="备用2")
private String wvBy2;
/**备用3*/
@Excel(name="备用3")
private String wvBy3;
/**
*: java.lang.String
*@return: java.lang.String
*/
@Id
@GeneratedValue(generator = "paymentableGenerator")
@GenericGenerator(name = "paymentableGenerator", strategy = "uuid")
@Column(name ="ID",nullable=false,length=36)
public String getId(){
return this.id;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setId(String id){
this.id = id;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="CREATE_NAME",nullable=true,length=50)
public String getCreateName(){
return this.createName;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setCreateName(String createName){
this.createName = createName;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="CREATE_BY",nullable=true,length=50)
public String getCreateBy(){
return this.createBy;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setCreateBy(String createBy){
this.createBy = createBy;
}
/**
*: java.util.Date
*@return: java.util.Date
*/
@Column(name ="CREATE_DATE",nullable=true,length=20)
public Date getCreateDate(){
return this.createDate;
}
/**
*: java.util.Date
*@param: java.util.Date
*/
public void setCreateDate(Date createDate){
this.createDate = createDate;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="UPDATE_NAME",nullable=true,length=50)
public String getUpdateName(){
return this.updateName;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setUpdateName(String updateName){
this.updateName = updateName;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="UPDATE_BY",nullable=true,length=50)
public String getUpdateBy(){
return this.updateBy;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setUpdateBy(String updateBy){
this.updateBy = updateBy;
}
/**
*: java.util.Date
*@return: java.util.Date
*/
@Column(name ="UPDATE_DATE",nullable=true,length=20)
public Date getUpdateDate(){
return this.updateDate;
}
/**
*: java.util.Date
*@param: java.util.Date
*/
public void setUpdateDate(Date updateDate){
this.updateDate = updateDate;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="SYS_ORG_CODE",nullable=true,length=50)
public String getSysOrgCode(){
return this.sysOrgCode;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setSysOrgCode(String sysOrgCode){
this.sysOrgCode = sysOrgCode;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="SYS_COMPANY_CODE",nullable=true,length=50)
public String getSysCompanyCode(){
return this.sysCompanyCode;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setSysCompanyCode(String sysCompanyCode){
this.sysCompanyCode = sysCompanyCode;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="BPM_STATUS",nullable=true,length=32)
public String getBpmStatus(){
return this.bpmStatus;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setBpmStatus(String bpmStatus){
this.bpmStatus = bpmStatus;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="PEISONDIAN",nullable=true,length=32)
public String getPeisondian(){
return this.peisondian;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setPeisondian(String peisondian){
this.peisondian = peisondian;
}
/**
*: java.lang.String
*@return: java.lang.String
*/
@Column(name ="WAVE_TYPE",nullable=true,length=32)
public String getWaveType(){
return this.waveType;
}
/**
*: java.lang.String
*@param: java.lang.String
*/
public void setWaveType(String waveType){
this.waveType = waveType;
}
/**
*: java.lang.String
*@return: java.lang.String 1
*/
@Column(name ="WV_BY1",nullable=true,length=32)
public String getWvBy1(){
return this.wvBy1;
}
/**
*: java.lang.String
*@param: java.lang.String 1
*/
public void setWvBy1(String wvBy1){
this.wvBy1 = wvBy1;
}
/**
*: java.lang.String
*@return: java.lang.String 2
*/
@Column(name ="WV_BY2",nullable=true,length=32)
public String getWvBy2(){
return this.wvBy2;
}
/**
*: java.lang.String
*@param: java.lang.String 2
*/
public void setWvBy2(String wvBy2){
this.wvBy2 = wvBy2;
}
/**
*: java.lang.String
*@return: java.lang.String 3
*/
@Column(name ="WV_BY3",nullable=true,length=32)
public String getWvBy3(){
return this.wvBy3;
}
/**
*: java.lang.String
*@param: java.lang.String 3
*/
public void setWvBy3(String wvBy3){
this.wvBy3 = wvBy3;
}
}

View File

@ -1,15 +0,0 @@
package com.zzjee.ba.service;
import com.zzjee.ba.entity.WmsWaveConfEntity;
import org.jeecgframework.core.common.service.CommonService;
import java.io.Serializable;
public interface WmsWaveConfServiceI extends CommonService{
public void delete(WmsWaveConfEntity entity) throws Exception;
public Serializable save(WmsWaveConfEntity entity) throws Exception;
public void saveOrUpdate(WmsWaveConfEntity entity) throws Exception;
}

View File

@ -1,146 +0,0 @@
package com.zzjee.ba.service.impl;
import com.zzjee.ba.service.WmsWaveConfServiceI;
import org.jeecgframework.core.common.service.impl.CommonServiceImpl;
import com.zzjee.ba.entity.WmsWaveConfEntity;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
import java.io.Serializable;
import org.jeecgframework.core.util.ApplicationContextUtil;
import org.jeecgframework.core.util.MyClassLoader;
import org.jeecgframework.core.util.StringUtil;
import org.jeecgframework.web.cgform.enhance.CgformEnhanceJavaInter;
@Service("wmsWaveConfService")
@Transactional
public class WmsWaveConfServiceImpl extends CommonServiceImpl implements WmsWaveConfServiceI {
public void delete(WmsWaveConfEntity entity) throws Exception{
super.delete(entity);
//执行删除操作增强业务
this.doDelBus(entity);
}
public Serializable save(WmsWaveConfEntity entity) throws Exception{
Serializable t = super.save(entity);
//执行新增操作增强业务
this.doAddBus(entity);
return t;
}
public void saveOrUpdate(WmsWaveConfEntity entity) throws Exception{
super.saveOrUpdate(entity);
//执行更新操作增强业务
this.doUpdateBus(entity);
}
/**
*
* @param t
* @return
*/
private void doAddBus(WmsWaveConfEntity t) throws Exception{
//-----------------sql增强 start----------------------------
//-----------------sql增强 end------------------------------
//-----------------java增强 start---------------------------
//-----------------java增强 end-----------------------------
}
/**
*
* @param t
* @return
*/
private void doUpdateBus(WmsWaveConfEntity t) throws Exception{
//-----------------sql增强 start----------------------------
//-----------------sql增强 end------------------------------
//-----------------java增强 start---------------------------
//-----------------java增强 end-----------------------------
}
/**
*
* @param id
* @return
*/
private void doDelBus(WmsWaveConfEntity t) throws Exception{
//-----------------sql增强 start----------------------------
//-----------------sql增强 end------------------------------
//-----------------java增强 start---------------------------
//-----------------java增强 end-----------------------------
}
private Map<String,Object> populationMap(WmsWaveConfEntity t){
Map<String,Object> map = new HashMap<String,Object>();
map.put("id", t.getId());
map.put("create_name", t.getCreateName());
map.put("create_by", t.getCreateBy());
map.put("create_date", t.getCreateDate());
map.put("update_name", t.getUpdateName());
map.put("update_by", t.getUpdateBy());
map.put("update_date", t.getUpdateDate());
map.put("sys_org_code", t.getSysOrgCode());
map.put("sys_company_code", t.getSysCompanyCode());
map.put("bpm_status", t.getBpmStatus());
map.put("peisondian", t.getPeisondian());
map.put("wave_type", t.getWaveType());
map.put("wv_by1", t.getWvBy1());
map.put("wv_by2", t.getWvBy2());
map.put("wv_by3", t.getWvBy3());
return map;
}
/**
* sql
* @param sql
* @param t
* @return
*/
public String replaceVal(String sql,WmsWaveConfEntity t){
sql = sql.replace("#{id}",String.valueOf(t.getId()));
sql = sql.replace("#{create_name}",String.valueOf(t.getCreateName()));
sql = sql.replace("#{create_by}",String.valueOf(t.getCreateBy()));
sql = sql.replace("#{create_date}",String.valueOf(t.getCreateDate()));
sql = sql.replace("#{update_name}",String.valueOf(t.getUpdateName()));
sql = sql.replace("#{update_by}",String.valueOf(t.getUpdateBy()));
sql = sql.replace("#{update_date}",String.valueOf(t.getUpdateDate()));
sql = sql.replace("#{sys_org_code}",String.valueOf(t.getSysOrgCode()));
sql = sql.replace("#{sys_company_code}",String.valueOf(t.getSysCompanyCode()));
sql = sql.replace("#{bpm_status}",String.valueOf(t.getBpmStatus()));
sql = sql.replace("#{peisondian}",String.valueOf(t.getPeisondian()));
sql = sql.replace("#{wave_type}",String.valueOf(t.getWaveType()));
sql = sql.replace("#{wv_by1}",String.valueOf(t.getWvBy1()));
sql = sql.replace("#{wv_by2}",String.valueOf(t.getWvBy2()));
sql = sql.replace("#{wv_by3}",String.valueOf(t.getWvBy3()));
sql = sql.replace("#{UUID}",UUID.randomUUID().toString());
return sql;
}
/**
* JAVA
*/
private void executeJavaExtend(String cgJavaType,String cgJavaValue,Map<String,Object> data) throws Exception {
if(StringUtil.isNotEmpty(cgJavaValue)){
Object obj = null;
try {
if("class".equals(cgJavaType)){
//因新增时已经校验了实例化是否可以成功,所以这块就不需要再做一次判断
obj = MyClassLoader.getClassByScn(cgJavaValue).newInstance();
}else if("spring".equals(cgJavaType)){
obj = ApplicationContextUtil.getContext().getBean(cgJavaValue);
}
if(obj instanceof CgformEnhanceJavaInter){
CgformEnhanceJavaInter javaInter = (CgformEnhanceJavaInter) obj;
javaInter.execute("wms_wave_conf",data);
}
} catch (Exception e) {
e.printStackTrace();
throw new Exception("执行JAVA增强出现异常");
}
}
}
}

View File

@ -1,103 +0,0 @@
<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<!DOCTYPE html>
<html>
<head>
<title>波次配置</title>
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<script type="text/javascript">
//编写自定义JS代码
</script>
</head>
<body>
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="wmsWaveConfController.do?doAdd" >
<input id="id" name="id" type="hidden" value="${wmsWaveConfPage.id }"/>
<input id="createName" name="createName" type="hidden" value="${wmsWaveConfPage.createName }"/>
<input id="createBy" name="createBy" type="hidden" value="${wmsWaveConfPage.createBy }"/>
<input id="createDate" name="createDate" type="hidden" value="${wmsWaveConfPage.createDate }"/>
<input id="updateName" name="updateName" type="hidden" value="${wmsWaveConfPage.updateName }"/>
<input id="updateBy" name="updateBy" type="hidden" value="${wmsWaveConfPage.updateBy }"/>
<input id="updateDate" name="updateDate" type="hidden" value="${wmsWaveConfPage.updateDate }"/>
<input id="sysOrgCode" name="sysOrgCode" type="hidden" value="${wmsWaveConfPage.sysOrgCode }"/>
<input id="sysCompanyCode" name="sysCompanyCode" type="hidden" value="${wmsWaveConfPage.sysCompanyCode }"/>
<input id="bpmStatus" name="bpmStatus" type="hidden" value="${wmsWaveConfPage.bpmStatus }"/>
<table style="width: 600px;" cellpadding="0" cellspacing="1" class="formtable">
<tr>
<td align="right">
<label class="Validform_label">
配送点:
</label>
</td>
<td class="value">
<input id="peisondian" name="peisondian" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
/>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">配送点</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
波次类型:
</label>
</td>
<td class="value">
<input id="waveType" name="waveType" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
/>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">波次类型</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用1:
</label>
</td>
<td class="value">
<input id="wvBy1" name="wvBy1" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
/>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用1</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用2:
</label>
</td>
<td class="value">
<input id="wvBy2" name="wvBy2" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
/>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用2</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用3:
</label>
</td>
<td class="value">
<input id="wvBy3" name="wvBy3" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
/>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用3</label>
</td>
</tr>
</table>
</t:formvalid>
</body>
<script src = "webpage/com/zzjee/ba/wmsWaveConf.js"></script>

View File

@ -1,98 +0,0 @@
<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<!DOCTYPE html>
<html>
<head>
<title>波次配置</title>
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<script type="text/javascript">
//编写自定义JS代码
</script>
</head>
<body>
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="wmsWaveConfController.do?doUpdate" >
<input id="id" name="id" type="hidden" value="${wmsWaveConfPage.id }">
<input id="createName" name="createName" type="hidden" value="${wmsWaveConfPage.createName }">
<input id="createBy" name="createBy" type="hidden" value="${wmsWaveConfPage.createBy }">
<input id="createDate" name="createDate" type="hidden" value="${wmsWaveConfPage.createDate }">
<input id="updateName" name="updateName" type="hidden" value="${wmsWaveConfPage.updateName }">
<input id="updateBy" name="updateBy" type="hidden" value="${wmsWaveConfPage.updateBy }">
<input id="updateDate" name="updateDate" type="hidden" value="${wmsWaveConfPage.updateDate }">
<input id="sysOrgCode" name="sysOrgCode" type="hidden" value="${wmsWaveConfPage.sysOrgCode }">
<input id="sysCompanyCode" name="sysCompanyCode" type="hidden" value="${wmsWaveConfPage.sysCompanyCode }">
<input id="bpmStatus" name="bpmStatus" type="hidden" value="${wmsWaveConfPage.bpmStatus }">
<table style="width: 600px;" cellpadding="0" cellspacing="1" class="formtable">
<tr>
<td align="right">
<label class="Validform_label">
配送点:
</label>
</td>
<td class="value">
<input id="peisondian" name="peisondian" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
value='${wmsWaveConfPage.peisondian}'>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">配送点</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
波次类型:
</label>
</td>
<td class="value">
<input id="waveType" name="waveType" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
value='${wmsWaveConfPage.waveType}'>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">波次类型</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用1:
</label>
</td>
<td class="value">
<input id="wvBy1" name="wvBy1" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
value='${wmsWaveConfPage.wvBy1}'>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用1</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用2:
</label>
</td>
<td class="value">
<input id="wvBy2" name="wvBy2" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
value='${wmsWaveConfPage.wvBy2}'>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用2</label>
</td>
</tr>
<tr>
<td align="right">
<label class="Validform_label">
备用3:
</label>
</td>
<td class="value">
<input id="wvBy3" name="wvBy3" type="text" style="width: 150px" class="inputxt"
ignore="ignore"
value='${wmsWaveConfPage.wvBy3}'>
<span class="Validform_checktip"></span>
<label class="Validform_label" style="display: none;">备用3</label>
</td>
</tr>
</table>
</t:formvalid>
</body>
<script src = "webpage/com/zzjee/ba/wmsWaveConf.js"></script>

View File

@ -1,32 +0,0 @@
//通用弹出式文件上传
function commonUpload(callback){
$.dialog({
content: "url:systemController.do?commonUpload",
lock : true,
title:"文件上传",
zIndex:2100,
width:700,
height: 200,
parent:windowapi,
cache:false,
ok: function(){
var iframe = this.iframe.contentWindow;
iframe.uploadCallback(callback);
return true;
},
cancelVal: '关闭',
cancel: function(){
}
});
}
function browseImages(inputId, Img) {// 图片管理器,可多个上传共用
}
function browseFiles(inputId, file) {// 文件管理器,可多个上传共用
}
function decode(value, id) {//value传入值,id接受值
var last = value.lastIndexOf("/");
var filename = value.substring(last + 1, value.length);
$("#" + id).text(decodeURIComponent(filename));
}

View File

@ -1,56 +0,0 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<div class="easyui-layout" fit="true">
<div region="center" style="padding:0px;border:0px">
<t:datagrid name="wmsWaveConfList" checkbox="false" pagination="true" fitColumns="false" title="波次配置" actionUrl="wmsWaveConfController.do?datagrid" idField="id" fit="true" queryMode="group">
<t:dgCol title="主键" field="id" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="创建人名称" field="createName" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="创建人登录名称" field="createBy" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="创建日期" field="createDate" formatter="yyyy-MM-dd" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="更新人名称" field="updateName" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="更新人登录名称" field="updateBy" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="更新日期" field="updateDate" formatter="yyyy-MM-dd" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="所属部门" field="sysOrgCode" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="所属公司" field="sysCompanyCode" hidden="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="流程状态" field="bpmStatus" hidden="true" queryMode="single" dictionary="bpm_status" width="120"></t:dgCol>
<t:dgCol title="配送点" field="peisondian" query="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="波次类型" field="waveType" query="true" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="备用1" field="wvBy1" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="备用2" field="wvBy2" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="备用3" field="wvBy3" queryMode="single" width="120"></t:dgCol>
<t:dgCol title="操作" field="opt" width="100"></t:dgCol>
<t:dgDelOpt title="删除" url="wmsWaveConfController.do?doDel&id={id}" urlclass="ace_button" urlfont="fa-trash-o"/>
<t:dgToolBar title="录入" icon="icon-add" url="wmsWaveConfController.do?goAdd" funname="add"></t:dgToolBar>
<t:dgToolBar title="编辑" icon="icon-edit" url="wmsWaveConfController.do?goUpdate" funname="update"></t:dgToolBar>
<%--<t:dgToolBar title="批量删除" icon="icon-remove" url="wmsWaveConfController.do?doBatchDel" funname="deleteALLSelect"></t:dgToolBar>--%>
<t:dgToolBar title="查看" icon="icon-search" url="wmsWaveConfController.do?goUpdate" funname="detail"></t:dgToolBar>
<t:dgToolBar title="导入" icon="icon-put" funname="ImportXls"></t:dgToolBar>
<t:dgToolBar title="导出" icon="icon-putout" funname="ExportXls"></t:dgToolBar>
<t:dgToolBar title="模板下载" icon="icon-putout" funname="ExportXlsByT"></t:dgToolBar>
</t:datagrid>
</div>
</div>
<script src = "webpage/com/zzjee/ba/wmsWaveConfList.js"></script>
<script type="text/javascript">
$(document).ready(function(){
});
//导入
function ImportXls() {
openuploadwin('Excel导入', 'wmsWaveConfController.do?upload', "wmsWaveConfList");
}
//导出
function ExportXls() {
JeecgExcelExport("wmsWaveConfController.do?exportXls","wmsWaveConfList");
}
//模板下载
function ExportXlsByT() {
JeecgExcelExport("wmsWaveConfController.do?exportXlsByT","wmsWaveConfList");
}
</script>