代码优化调整
parent
3be8e44b1d
commit
83123bfb1d
|
@ -1,406 +0,0 @@
|
|||
package com.zzjee.sales.controller;
|
||||
import com.zzjee.sales.entity.ZzSalescountEntity;
|
||||
import com.zzjee.sales.service.ZzSalescountServiceI;
|
||||
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 erzhongxmu
|
||||
* @date 2017-07-16 15:23:55
|
||||
* @version V1.0
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/zzSalescountController")
|
||||
public class ZzSalescountController extends BaseController {
|
||||
/**
|
||||
* Logger for this class
|
||||
*/
|
||||
private static final Logger logger = Logger.getLogger(ZzSalescountController.class);
|
||||
|
||||
@Autowired
|
||||
private ZzSalescountServiceI zzSalescountService;
|
||||
@Autowired
|
||||
private SystemService systemService;
|
||||
@Autowired
|
||||
private Validator validator;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 销售排行列表 页面跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "list")
|
||||
public ModelAndView list(HttpServletRequest request) {
|
||||
return new ModelAndView("com/zzjee/sales/zzSalescountList");
|
||||
}
|
||||
|
||||
/**
|
||||
* easyui AJAX请求数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @param dataGrid
|
||||
* @param user
|
||||
*/
|
||||
|
||||
@RequestMapping(params = "datagrid")
|
||||
public void datagrid(ZzSalescountEntity zzSalescount,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) {
|
||||
CriteriaQuery cq = new CriteriaQuery(ZzSalescountEntity.class, dataGrid);
|
||||
//查询条件组装器
|
||||
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, zzSalescount, request.getParameterMap());
|
||||
try{
|
||||
//自定义追加查询条件
|
||||
}catch (Exception e) {
|
||||
throw new BusinessException(e.getMessage());
|
||||
}
|
||||
cq.add();
|
||||
this.zzSalescountService.getDataGridReturn(cq, true);
|
||||
TagUtil.datagrid(response, dataGrid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除销售排行
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "doDel")
|
||||
@ResponseBody
|
||||
public AjaxJson doDel(ZzSalescountEntity zzSalescount, HttpServletRequest request) {
|
||||
String message = null;
|
||||
AjaxJson j = new AjaxJson();
|
||||
zzSalescount = systemService.getEntity(ZzSalescountEntity.class, zzSalescount.getId());
|
||||
message = "销售排行删除成功";
|
||||
try{
|
||||
zzSalescountService.delete(zzSalescount);
|
||||
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(",")){
|
||||
ZzSalescountEntity zzSalescount = systemService.getEntity(ZzSalescountEntity.class,
|
||||
id
|
||||
);
|
||||
zzSalescountService.delete(zzSalescount);
|
||||
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(ZzSalescountEntity zzSalescount, HttpServletRequest request) {
|
||||
String message = null;
|
||||
AjaxJson j = new AjaxJson();
|
||||
message = "销售排行添加成功";
|
||||
try{
|
||||
zzSalescountService.save(zzSalescount);
|
||||
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(ZzSalescountEntity zzSalescount, HttpServletRequest request) {
|
||||
String message = null;
|
||||
AjaxJson j = new AjaxJson();
|
||||
message = "销售排行更新成功";
|
||||
ZzSalescountEntity t = zzSalescountService.get(ZzSalescountEntity.class, zzSalescount.getId());
|
||||
try {
|
||||
MyBeanUtils.copyBeanNotNull2Bean(zzSalescount, t);
|
||||
zzSalescountService.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(ZzSalescountEntity zzSalescount, HttpServletRequest req) {
|
||||
if (StringUtil.isNotEmpty(zzSalescount.getId())) {
|
||||
zzSalescount = zzSalescountService.getEntity(ZzSalescountEntity.class, zzSalescount.getId());
|
||||
req.setAttribute("zzSalescountPage", zzSalescount);
|
||||
}
|
||||
return new ModelAndView("com/zzjee/sales/zzSalescount-add");
|
||||
}
|
||||
/**
|
||||
* 销售排行编辑页面跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "goUpdate")
|
||||
public ModelAndView goUpdate(ZzSalescountEntity zzSalescount, HttpServletRequest req) {
|
||||
if (StringUtil.isNotEmpty(zzSalescount.getId())) {
|
||||
zzSalescount = zzSalescountService.getEntity(ZzSalescountEntity.class, zzSalescount.getId());
|
||||
req.setAttribute("zzSalescountPage", zzSalescount);
|
||||
}
|
||||
return new ModelAndView("com/zzjee/sales/zzSalescount-update");
|
||||
}
|
||||
|
||||
/**
|
||||
* 导入功能跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "upload")
|
||||
public ModelAndView upload(HttpServletRequest req) {
|
||||
req.setAttribute("controller_name","zzSalescountController");
|
||||
return new ModelAndView("common/upload/pub_excel_upload");
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
*/
|
||||
@RequestMapping(params = "exportXls")
|
||||
public String exportXls(ZzSalescountEntity zzSalescount,HttpServletRequest request,HttpServletResponse response
|
||||
, DataGrid dataGrid,ModelMap modelMap) {
|
||||
CriteriaQuery cq = new CriteriaQuery(ZzSalescountEntity.class, dataGrid);
|
||||
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, zzSalescount, request.getParameterMap());
|
||||
List<ZzSalescountEntity> zzSalescounts = this.zzSalescountService.getListByCriteriaQuery(cq,false);
|
||||
modelMap.put(NormalExcelConstants.FILE_NAME,"销售排行");
|
||||
modelMap.put(NormalExcelConstants.CLASS,ZzSalescountEntity.class);
|
||||
modelMap.put(NormalExcelConstants.PARAMS,new ExportParams("销售排行列表", "导出人:"+ResourceUtil.getSessionUserName().getRealName(),
|
||||
"导出信息"));
|
||||
modelMap.put(NormalExcelConstants.DATA_LIST,zzSalescounts);
|
||||
return NormalExcelConstants.JEECG_EXCEL_VIEW;
|
||||
}
|
||||
/**
|
||||
* 导出excel 使模板
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
*/
|
||||
@RequestMapping(params = "exportXlsByT")
|
||||
public String exportXlsByT(ZzSalescountEntity zzSalescount,HttpServletRequest request,HttpServletResponse response
|
||||
, DataGrid dataGrid,ModelMap modelMap) {
|
||||
modelMap.put(NormalExcelConstants.FILE_NAME,"销售排行");
|
||||
modelMap.put(NormalExcelConstants.CLASS,ZzSalescountEntity.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<ZzSalescountEntity> listZzSalescountEntitys = ExcelImportUtil.importExcel(file.getInputStream(),ZzSalescountEntity.class,params);
|
||||
for (ZzSalescountEntity zzSalescount : listZzSalescountEntitys) {
|
||||
zzSalescountService.save(zzSalescount);
|
||||
}
|
||||
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<ZzSalescountEntity> list() {
|
||||
List<ZzSalescountEntity> listZzSalescounts=zzSalescountService.getList(ZzSalescountEntity.class);
|
||||
return listZzSalescounts;
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", method = RequestMethod.GET)
|
||||
@ResponseBody
|
||||
public ResponseEntity<?> get(@PathVariable("id") String id) {
|
||||
ZzSalescountEntity task = zzSalescountService.get(ZzSalescountEntity.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 ZzSalescountEntity zzSalescount, UriComponentsBuilder uriBuilder) {
|
||||
//调用JSR303 Bean Validator进行校验,如果出错返回含400错误码及json格式的错误信息.
|
||||
Set<ConstraintViolation<ZzSalescountEntity>> failures = validator.validate(zzSalescount);
|
||||
if (!failures.isEmpty()) {
|
||||
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
|
||||
//保存
|
||||
try{
|
||||
zzSalescountService.save(zzSalescount);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return new ResponseEntity(HttpStatus.NO_CONTENT);
|
||||
}
|
||||
//按照Restful风格约定,创建指向新任务的url, 也可以直接返回id或对象.
|
||||
String id = zzSalescount.getId();
|
||||
URI uri = uriBuilder.path("/rest/zzSalescountController/" + 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 ZzSalescountEntity zzSalescount) {
|
||||
//调用JSR303 Bean Validator进行校验,如果出错返回含400错误码及json格式的错误信息.
|
||||
Set<ConstraintViolation<ZzSalescountEntity>> failures = validator.validate(zzSalescount);
|
||||
if (!failures.isEmpty()) {
|
||||
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
|
||||
//保存
|
||||
try{
|
||||
zzSalescountService.saveOrUpdate(zzSalescount);
|
||||
} 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) {
|
||||
zzSalescountService.deleteEntityById(ZzSalescountEntity.class, id);
|
||||
}
|
||||
}
|
|
@ -1,275 +0,0 @@
|
|||
package com.zzjee.sales.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 erzhongxmu
|
||||
* @date 2017-07-16 15:23:55
|
||||
* @version V1.0
|
||||
*
|
||||
*/
|
||||
@Entity
|
||||
@Table(name = "zz_salescount", schema = "")
|
||||
@SuppressWarnings("serial")
|
||||
public class ZzSalescountEntity implements java.io.Serializable {
|
||||
/**主键*/
|
||||
private java.lang.String id;
|
||||
/**创建人名称*/
|
||||
private java.lang.String createName;
|
||||
/**创建人登录名称*/
|
||||
private java.lang.String createBy;
|
||||
/**创建日期*/
|
||||
private java.util.Date createDate;
|
||||
/**更新人名称*/
|
||||
private java.lang.String updateName;
|
||||
/**更新人登录名称*/
|
||||
private java.lang.String updateBy;
|
||||
/**更新日期*/
|
||||
private java.util.Date updateDate;
|
||||
/**所属部门*/
|
||||
private java.lang.String sysOrgCode;
|
||||
/**所属公司*/
|
||||
private java.lang.String sysCompanyCode;
|
||||
/**销售年*/
|
||||
@Excel(name="销售年")
|
||||
private java.lang.String sdYear;
|
||||
/**销售月*/
|
||||
@Excel(name="销售月")
|
||||
private java.lang.String sdMonth;
|
||||
/**销售量*/
|
||||
@Excel(name="销售量")
|
||||
private java.lang.Double sdCount;
|
||||
/**销售额*/
|
||||
@Excel(name="销售额")
|
||||
private java.lang.Double sdCountm;
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 主键
|
||||
*/
|
||||
@Id
|
||||
@GeneratedValue(generator = "paymentableGenerator")
|
||||
@GenericGenerator(name = "paymentableGenerator", strategy = "uuid")
|
||||
@Column(name ="ID",nullable=false,length=36)
|
||||
public java.lang.String getId(){
|
||||
return this.id;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 主键
|
||||
*/
|
||||
public void setId(java.lang.String id){
|
||||
this.id = id;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 创建人名称
|
||||
*/
|
||||
@Column(name ="CREATE_NAME",nullable=true,length=50)
|
||||
public java.lang.String getCreateName(){
|
||||
return this.createName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 创建人名称
|
||||
*/
|
||||
public void setCreateName(java.lang.String createName){
|
||||
this.createName = createName;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 创建人登录名称
|
||||
*/
|
||||
@Column(name ="CREATE_BY",nullable=true,length=50)
|
||||
public java.lang.String getCreateBy(){
|
||||
return this.createBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 创建人登录名称
|
||||
*/
|
||||
public void setCreateBy(java.lang.String createBy){
|
||||
this.createBy = createBy;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.util.Date
|
||||
*@return: java.util.Date 创建日期
|
||||
*/
|
||||
@Column(name ="CREATE_DATE",nullable=true,length=20)
|
||||
public java.util.Date getCreateDate(){
|
||||
return this.createDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.util.Date
|
||||
*@param: java.util.Date 创建日期
|
||||
*/
|
||||
public void setCreateDate(java.util.Date createDate){
|
||||
this.createDate = createDate;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 更新人名称
|
||||
*/
|
||||
@Column(name ="UPDATE_NAME",nullable=true,length=50)
|
||||
public java.lang.String getUpdateName(){
|
||||
return this.updateName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 更新人名称
|
||||
*/
|
||||
public void setUpdateName(java.lang.String updateName){
|
||||
this.updateName = updateName;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 更新人登录名称
|
||||
*/
|
||||
@Column(name ="UPDATE_BY",nullable=true,length=50)
|
||||
public java.lang.String getUpdateBy(){
|
||||
return this.updateBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 更新人登录名称
|
||||
*/
|
||||
public void setUpdateBy(java.lang.String updateBy){
|
||||
this.updateBy = updateBy;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.util.Date
|
||||
*@return: java.util.Date 更新日期
|
||||
*/
|
||||
@Column(name ="UPDATE_DATE",nullable=true,length=20)
|
||||
public java.util.Date getUpdateDate(){
|
||||
return this.updateDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.util.Date
|
||||
*@param: java.util.Date 更新日期
|
||||
*/
|
||||
public void setUpdateDate(java.util.Date updateDate){
|
||||
this.updateDate = updateDate;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 所属部门
|
||||
*/
|
||||
@Column(name ="SYS_ORG_CODE",nullable=true,length=50)
|
||||
public java.lang.String getSysOrgCode(){
|
||||
return this.sysOrgCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 所属部门
|
||||
*/
|
||||
public void setSysOrgCode(java.lang.String sysOrgCode){
|
||||
this.sysOrgCode = sysOrgCode;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 所属公司
|
||||
*/
|
||||
@Column(name ="SYS_COMPANY_CODE",nullable=true,length=50)
|
||||
public java.lang.String getSysCompanyCode(){
|
||||
return this.sysCompanyCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 所属公司
|
||||
*/
|
||||
public void setSysCompanyCode(java.lang.String sysCompanyCode){
|
||||
this.sysCompanyCode = sysCompanyCode;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 销售年
|
||||
*/
|
||||
@Column(name ="SD_YEAR",nullable=true,length=32)
|
||||
public java.lang.String getSdYear(){
|
||||
return this.sdYear;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 销售年
|
||||
*/
|
||||
public void setSdYear(java.lang.String sdYear){
|
||||
this.sdYear = sdYear;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 销售月
|
||||
*/
|
||||
@Column(name ="SD_MONTH",nullable=true,length=32)
|
||||
public java.lang.String getSdMonth(){
|
||||
return this.sdMonth;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 销售月
|
||||
*/
|
||||
public void setSdMonth(java.lang.String sdMonth){
|
||||
this.sdMonth = sdMonth;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.Double
|
||||
*@return: java.lang.Double 销售量
|
||||
*/
|
||||
@Column(name ="SD_COUNT",nullable=true,scale=2,length=32)
|
||||
public java.lang.Double getSdCount(){
|
||||
return this.sdCount;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.Double
|
||||
*@param: java.lang.Double 销售量
|
||||
*/
|
||||
public void setSdCount(java.lang.Double sdCount){
|
||||
this.sdCount = sdCount;
|
||||
}
|
||||
/**
|
||||
*方法: 取得java.lang.Double
|
||||
*@return: java.lang.Double 销售额
|
||||
*/
|
||||
@Column(name ="SD_COUNTM",nullable=true,scale=2,length=32)
|
||||
public java.lang.Double getSdCountm(){
|
||||
return this.sdCountm;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.Double
|
||||
*@param: java.lang.Double 销售额
|
||||
*/
|
||||
public void setSdCountm(java.lang.Double sdCountm){
|
||||
this.sdCountm = sdCountm;
|
||||
}
|
||||
}
|
|
@ -1,15 +0,0 @@
|
|||
package com.zzjee.sales.service;
|
||||
import com.zzjee.sales.entity.ZzSalescountEntity;
|
||||
import org.jeecgframework.core.common.service.CommonService;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public interface ZzSalescountServiceI extends CommonService{
|
||||
|
||||
public void delete(ZzSalescountEntity entity) throws Exception;
|
||||
|
||||
public Serializable save(ZzSalescountEntity entity) throws Exception;
|
||||
|
||||
public void saveOrUpdate(ZzSalescountEntity entity) throws Exception;
|
||||
|
||||
}
|
|
@ -1,142 +0,0 @@
|
|||
package com.zzjee.sales.service.impl;
|
||||
import com.zzjee.sales.service.ZzSalescountServiceI;
|
||||
import org.jeecgframework.core.common.service.impl.CommonServiceImpl;
|
||||
import com.zzjee.sales.entity.ZzSalescountEntity;
|
||||
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("zzSalescountService")
|
||||
@Transactional
|
||||
public class ZzSalescountServiceImpl extends CommonServiceImpl implements ZzSalescountServiceI {
|
||||
|
||||
|
||||
public void delete(ZzSalescountEntity entity) throws Exception{
|
||||
super.delete(entity);
|
||||
//执行删除操作增强业务
|
||||
this.doDelBus(entity);
|
||||
}
|
||||
|
||||
public Serializable save(ZzSalescountEntity entity) throws Exception{
|
||||
Serializable t = super.save(entity);
|
||||
//执行新增操作增强业务
|
||||
this.doAddBus(entity);
|
||||
return t;
|
||||
}
|
||||
|
||||
public void saveOrUpdate(ZzSalescountEntity entity) throws Exception{
|
||||
super.saveOrUpdate(entity);
|
||||
//执行更新操作增强业务
|
||||
this.doUpdateBus(entity);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增操作增强业务
|
||||
* @param t
|
||||
* @return
|
||||
*/
|
||||
private void doAddBus(ZzSalescountEntity t) throws Exception{
|
||||
//-----------------sql增强 start----------------------------
|
||||
//-----------------sql增强 end------------------------------
|
||||
|
||||
//-----------------java增强 start---------------------------
|
||||
//-----------------java增强 end-----------------------------
|
||||
}
|
||||
/**
|
||||
* 更新操作增强业务
|
||||
* @param t
|
||||
* @return
|
||||
*/
|
||||
private void doUpdateBus(ZzSalescountEntity t) throws Exception{
|
||||
//-----------------sql增强 start----------------------------
|
||||
//-----------------sql增强 end------------------------------
|
||||
|
||||
//-----------------java增强 start---------------------------
|
||||
//-----------------java增强 end-----------------------------
|
||||
}
|
||||
/**
|
||||
* 删除操作增强业务
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
private void doDelBus(ZzSalescountEntity t) throws Exception{
|
||||
//-----------------sql增强 start----------------------------
|
||||
//-----------------sql增强 end------------------------------
|
||||
|
||||
//-----------------java增强 start---------------------------
|
||||
//-----------------java增强 end-----------------------------
|
||||
}
|
||||
|
||||
private Map<String,Object> populationMap(ZzSalescountEntity 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("sd_year", t.getSdYear());
|
||||
map.put("sd_month", t.getSdMonth());
|
||||
map.put("sd_count", t.getSdCount());
|
||||
map.put("sd_countm", t.getSdCountm());
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* 替换sql中的变量
|
||||
* @param sql
|
||||
* @param t
|
||||
* @return
|
||||
*/
|
||||
public String replaceVal(String sql,ZzSalescountEntity 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("#{sd_year}",String.valueOf(t.getSdYear()));
|
||||
sql = sql.replace("#{sd_month}",String.valueOf(t.getSdMonth()));
|
||||
sql = sql.replace("#{sd_count}",String.valueOf(t.getSdCount()));
|
||||
sql = sql.replace("#{sd_countm}",String.valueOf(t.getSdCountm()));
|
||||
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("zz_salescount",data);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new Exception("执行JAVA增强出现异常!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -32,7 +32,6 @@ 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.tag.core.easyui.TagUtil;
|
||||
import org.jeecgframework.web.system.pojo.base.TSUser;
|
||||
import org.jeecgframework.web.system.service.SystemService;
|
||||
import org.jeecgframework.web.system.sms.util.Constants;
|
||||
import com.zzjee.wmutil.wmUtil;
|
||||
|
@ -54,17 +53,13 @@ import org.springframework.http.ResponseEntity;
|
|||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
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;
|
||||
|
||||
|
@ -153,9 +148,6 @@ public class WmToDownGoodsController extends BaseController {
|
|||
map1.put("createDate", "desc");
|
||||
cq.setOrder(map1);
|
||||
cq.isNull("downSta");
|
||||
// cq.isNotNull("orderType");
|
||||
// TSUser user = ResourceUtil.getSessionUserName();
|
||||
// cq.notEq("createBy", user.getUserName());
|
||||
cq.add();
|
||||
this.wmToDownGoodsService.getDataGridReturn(cq, true);
|
||||
List<WmToDownGoodsEntity> resultnew = new ArrayList<WmToDownGoodsEntity>();
|
||||
|
@ -188,9 +180,6 @@ public class WmToDownGoodsController extends BaseController {
|
|||
map1.put("createDate", "desc");
|
||||
cq.setOrder(map1);
|
||||
cq.isNull("downSta");
|
||||
// cq.isNull("orderType");
|
||||
// TSUser user = ResourceUtil.getSessionUserName();
|
||||
// cq.notEq("createBy", user.getUserName());
|
||||
cq.add();
|
||||
this.wmToDownGoodsService.getDataGridReturn(cq, true);
|
||||
List<WmToDownGoodsEntity> resultnew = new ArrayList<WmToDownGoodsEntity>();
|
||||
|
@ -264,7 +253,7 @@ public class WmToDownGoodsController extends BaseController {
|
|||
//JeecgListDemoController.do?rowListDemo
|
||||
@RequestMapping(params = "delList")
|
||||
public ModelAndView delListDemo(HttpServletRequest request) {
|
||||
return new ModelAndView("com/zzjee/wm/del_rowedtior");
|
||||
return new ModelAndView("com/zzjee/wm/omconf");
|
||||
}
|
||||
@RequestMapping(params = "wavedelList")
|
||||
public ModelAndView wavedelListDemo(HttpServletRequest request) {
|
||||
|
@ -318,14 +307,8 @@ public class WmToDownGoodsController extends BaseController {
|
|||
if (StringUtil.isNotEmpty(jeecgDemo.getId())) {
|
||||
WmToDownGoodsEntity t =systemService.get(WmToDownGoodsEntity.class, jeecgDemo.getId());
|
||||
try {
|
||||
|
||||
|
||||
MyBeanUtils.copyBeanNotNull2Bean(jeecgDemo, t);
|
||||
|
||||
systemService.saveOrUpdate(t);
|
||||
|
||||
|
||||
// systemService.addLog(message, Globals.Log_Type_UPDATE, Globals.Log_Leavel_INFO);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
@ -351,48 +334,10 @@ public class WmToDownGoodsController extends BaseController {
|
|||
if (StringUtil.isNotEmpty(jeecgDemo.getId())) {
|
||||
WmToDownGoodsEntity t =systemService.get(WmToDownGoodsEntity.class, jeecgDemo.getId());
|
||||
try {
|
||||
|
||||
message = "装车复核成功";
|
||||
MyBeanUtils.copyBeanNotNull2Bean(jeecgDemo, t);
|
||||
|
||||
// MvGoodsEntity mvgoods = new MvGoodsEntity();
|
||||
// mvgoods = systemService.findUniqueByProperty(MvGoodsEntity.class, "goodsCode", t.getGoodsId()) ;
|
||||
// if(mvgoods!=null){
|
||||
// try {
|
||||
//
|
||||
// try {
|
||||
// if(!mvgoods.getBaseunit().equals(mvgoods.getShlDanWei())){
|
||||
// t.setBaseGoodscount(String.valueOf(Long.parseLong(mvgoods.getChlShl())*Long.parseLong(jeecgDemo.getGoodsQuaok())));
|
||||
// }else{
|
||||
t.setBaseGoodscount(jeecgDemo.getGoodsQuaok());
|
||||
// t.setGoodsQua(jeecgDemo.getGoodsQuaok());
|
||||
// }
|
||||
// } catch (Exception e) {
|
||||
// // TODO: handle exception
|
||||
// }
|
||||
//
|
||||
//
|
||||
//// wmImNoticeI.setGoodsWeight(String.valueOf(Long.parseLong(mdgoods.getZhlKg())*Long.parseLong(wmImNoticeI.getGoodsCount())));
|
||||
//// wmImNoticeI.setGoodsUnit(mdgoods.getShlDanWei());
|
||||
//
|
||||
// } catch (Exception e) {
|
||||
// // TODO: handle exception
|
||||
// }
|
||||
//
|
||||
|
||||
|
||||
// }
|
||||
|
||||
t.setDownSta(Constants.wm_sta5);
|
||||
systemService.saveOrUpdate(t);
|
||||
// try {
|
||||
// WmOmNoticeHEntity wmOmNoticeH = systemService.getEntity(WmOmNoticeHEntity.class, t.getOrderId());
|
||||
// wmOmNoticeH.setOmSta(Constants.wm_sta5);
|
||||
// systemService.saveOrUpdate(wmOmNoticeH);
|
||||
// } catch (Exception e) {
|
||||
// // TODO: handle exception
|
||||
// }
|
||||
|
||||
systemService.addLog(message, Globals.Log_Type_UPDATE, Globals.Log_Leavel_INFO);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
|
|
|
@ -1,531 +0,0 @@
|
|||
package com.zzjee.wm.controller;
|
||||
import com.sun.org.apache.bcel.internal.generic.NEWARRAY;
|
||||
import com.zzjee.md.entity.MdCusEntity;
|
||||
import com.zzjee.md.entity.MdGoodsEntity;
|
||||
import com.zzjee.wm.entity.WmImNoticeHEntity;
|
||||
import com.zzjee.wm.entity.WmImNoticeIEntity;
|
||||
import com.zzjee.wm.entity.WmInQmIEntity;
|
||||
import com.zzjee.wm.entity.WmToUpEntity;
|
||||
import com.zzjee.wm.service.WmToUpServiceI;
|
||||
import com.zzjee.wm.page.WmToUpPage;
|
||||
import com.zzjee.wm.entity.WmToUpGoodsEntity;
|
||||
|
||||
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.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
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.json.AjaxJson;
|
||||
import org.jeecgframework.core.common.model.json.DataGrid;
|
||||
import org.jeecgframework.core.constant.Globals;
|
||||
import org.jeecgframework.core.util.ExceptionUtil;
|
||||
import org.jeecgframework.core.util.ResourceUtil;
|
||||
import org.jeecgframework.core.util.StringUtil;
|
||||
import org.jeecgframework.core.util.oConvertUtils;
|
||||
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 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.vo.NormalExcelConstants;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Map;
|
||||
|
||||
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 erzhongxmu
|
||||
* @date 2017-08-15 23:18:14
|
||||
* @version V1.0
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/wmToUpController")
|
||||
public class WmToUpController extends BaseController {
|
||||
/**
|
||||
* Logger for this class
|
||||
*/
|
||||
private static final Logger logger = Logger.getLogger(WmToUpController.class);
|
||||
|
||||
@Autowired
|
||||
private WmToUpServiceI wmToUpService;
|
||||
@Autowired
|
||||
private SystemService systemService;
|
||||
@Autowired
|
||||
private Validator validator;
|
||||
|
||||
/**
|
||||
* 上架明细列表 页面跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "list")
|
||||
public ModelAndView list(HttpServletRequest request) {
|
||||
return new ModelAndView("com/zzjee/wm/wmToUpList");
|
||||
}
|
||||
|
||||
/**
|
||||
* easyui AJAX请求数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @param dataGrid
|
||||
* @param user
|
||||
*/
|
||||
|
||||
@RequestMapping(params = "listgoods")
|
||||
public ModelAndView listgoods(HttpServletRequest request) {
|
||||
return new ModelAndView("com/zzjee/wm/wminupList");
|
||||
}
|
||||
@RequestMapping(params = "datagridgoods")
|
||||
public void datagridgoods(WmToUpGoodsEntity wmToUpGoods,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) {
|
||||
CriteriaQuery cq = new CriteriaQuery(WmToUpGoodsEntity.class, dataGrid);
|
||||
//查询条件组装器
|
||||
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, wmToUpGoods);
|
||||
try{
|
||||
//自定义追加查询条件
|
||||
}catch (Exception e) {
|
||||
throw new BusinessException(e.getMessage());
|
||||
}
|
||||
cq.add();
|
||||
this.wmToUpService.getDataGridReturn(cq, true);
|
||||
TagUtil.datagrid(response, dataGrid);
|
||||
}
|
||||
|
||||
@RequestMapping(params = "datagrid")
|
||||
public void datagrid(WmToUpEntity wmToUp,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) {
|
||||
CriteriaQuery cq = new CriteriaQuery(WmToUpEntity.class, dataGrid);
|
||||
//查询条件组装器
|
||||
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, wmToUp);
|
||||
try{
|
||||
//自定义追加查询条件
|
||||
}catch (Exception e) {
|
||||
throw new BusinessException(e.getMessage());
|
||||
}
|
||||
cq.add();
|
||||
this.wmToUpService.getDataGridReturn(cq, true);
|
||||
TagUtil.datagrid(response, dataGrid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除上架明细
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "doDel")
|
||||
@ResponseBody
|
||||
public AjaxJson doDel(WmToUpEntity wmToUp, HttpServletRequest request) {
|
||||
AjaxJson j = new AjaxJson();
|
||||
wmToUp = systemService.getEntity(WmToUpEntity.class, wmToUp.getId());
|
||||
String message = "上架明细删除成功";
|
||||
try{
|
||||
wmToUpService.delMain(wmToUp);
|
||||
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){
|
||||
AjaxJson j = new AjaxJson();
|
||||
String message = "上架明细删除成功";
|
||||
try{
|
||||
for(String id:ids.split(",")){
|
||||
WmToUpEntity wmToUp = systemService.getEntity(WmToUpEntity.class,
|
||||
id
|
||||
);
|
||||
wmToUpService.delMain(wmToUp);
|
||||
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;
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(params = "doGetbinid", method = { RequestMethod.GET,
|
||||
RequestMethod.POST })
|
||||
@ResponseBody
|
||||
public AjaxJson doGetbinid(HttpServletRequest request) {
|
||||
AjaxJson j = new AjaxJson();
|
||||
String hql0 = "from WmInQmIEntity where binSta = 'N' AND tinId = ? ";
|
||||
System.out.println(oConvertUtils.getString(request
|
||||
.getParameter("binid")));
|
||||
List<WmInQmIEntity> WmInQmIEntityList = systemService.findHql(hql0,
|
||||
oConvertUtils.getString(request.getParameter("binid")));// 获取行项目
|
||||
List<WmInQmIEntity> WmInQmIEntityListout = new ArrayList<WmInQmIEntity>();
|
||||
if (WmInQmIEntityList.size() > 0) {
|
||||
for (WmInQmIEntity wmInQmIEntity : WmInQmIEntityList) {
|
||||
MdGoodsEntity mdgoods = systemService.findUniqueByProperty(
|
||||
MdGoodsEntity.class, "shpBianMa",
|
||||
wmInQmIEntity.getGoodsId());
|
||||
if (mdgoods != null) {
|
||||
wmInQmIEntity.setGoodsUnit(mdgoods.getShpMingCheng());
|
||||
}
|
||||
WmInQmIEntityListout.add(wmInQmIEntity);
|
||||
}
|
||||
j.setObj(WmInQmIEntityListout);
|
||||
MdCusEntity md = systemService.findUniqueByProperty(
|
||||
MdCusEntity.class, "keHuBianMa", WmInQmIEntityListout.get(0)
|
||||
.getCusCode());
|
||||
j.setMsg(md.getZhongWenQch());
|
||||
} else {
|
||||
j.setSuccess(false);
|
||||
j.setMsg("此托盘无需要上架数据");
|
||||
}
|
||||
return j;
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加上架明细
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "doAdd")
|
||||
@ResponseBody
|
||||
public AjaxJson doAdd(WmToUpEntity wmToUp,WmToUpPage wmToUpPage, HttpServletRequest request) {
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList = new ArrayList<WmToUpGoodsEntity>();
|
||||
String hql0 = "from WmInQmIEntity where binSta = 'N' AND tinId = ? and binId = ?";
|
||||
List<WmInQmIEntity> WmInQmIEntityList = systemService
|
||||
.findHql(hql0, wmToUp.getBinId(),wmToUp.getKuWeiBianMa());//获取行项目
|
||||
for (WmInQmIEntity wmInQmIEntity : WmInQmIEntityList) {
|
||||
WmToUpGoodsEntity wmToUpGoodsEntity = new WmToUpGoodsEntity();
|
||||
wmToUpGoodsEntity.setGoodsId(wmInQmIEntity.getGoodsId());
|
||||
wmToUpGoodsEntity.setGoodsProData(wmInQmIEntity.getProData());
|
||||
wmToUpGoodsEntity.setGoodsBatch(wmInQmIEntity.getGoodsBatch());
|
||||
wmToUpGoodsEntity.setGoodsQua(wmInQmIEntity.getQmOkQuat());
|
||||
wmToUpGoodsEntity.setGoodsUnit(wmInQmIEntity.getGoodsUnit());
|
||||
wmToUpGoodsEntity.setOrderIdI(wmInQmIEntity.getId());
|
||||
wmToUpGoodsEntity.setOrderId(wmInQmIEntity.getImNoticeId());
|
||||
wmInQmIEntity.setBinSta("Y");
|
||||
wmToUpGoodsList.add(wmToUpGoodsEntity);
|
||||
wmToUp.setCusCode(wmInQmIEntity.getCusCode());
|
||||
systemService.save(wmInQmIEntity);
|
||||
}
|
||||
AjaxJson j = new AjaxJson();
|
||||
String message = "添加成功";
|
||||
try{
|
||||
wmToUpService.addMain(wmToUp, wmToUpGoodsList);
|
||||
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(WmToUpEntity wmToUp,WmToUpPage wmToUpPage, HttpServletRequest request) {
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList = wmToUpPage.getWmToUpGoodsList();
|
||||
AjaxJson j = new AjaxJson();
|
||||
String message = "更新成功";
|
||||
try{
|
||||
wmToUpService.updateMain(wmToUp, wmToUpGoodsList);
|
||||
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(WmToUpEntity wmToUp, HttpServletRequest req) {
|
||||
if (StringUtil.isNotEmpty(wmToUp.getId())) {
|
||||
wmToUp = wmToUpService.getEntity(WmToUpEntity.class, wmToUp.getId());
|
||||
req.setAttribute("wmToUpPage", wmToUp);
|
||||
}
|
||||
return new ModelAndView("com/zzjee/wm/wmToUp-add");
|
||||
}
|
||||
|
||||
/**
|
||||
* 上架明细编辑页面跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "goUpdate")
|
||||
public ModelAndView goUpdate(WmToUpEntity wmToUp, HttpServletRequest req) {
|
||||
if (StringUtil.isNotEmpty(wmToUp.getId())) {
|
||||
wmToUp = wmToUpService.getEntity(WmToUpEntity.class, wmToUp.getId());
|
||||
req.setAttribute("wmToUpPage", wmToUp);
|
||||
}
|
||||
return new ModelAndView("com/zzjee/wm/wmToUp-update");
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 加载明细列表[上架商品明细]
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "wmToUpGoodsList")
|
||||
public ModelAndView wmToUpGoodsList(WmToUpEntity wmToUp, HttpServletRequest req) {
|
||||
|
||||
//===================================================================================
|
||||
//获取参数
|
||||
Object id0 = wmToUp.getId();
|
||||
//===================================================================================
|
||||
//查询-上架商品明细
|
||||
String hql0 = "from WmToUpGoodsEntity where 1 = 1 AND wmToUpId = ? ";
|
||||
try{
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsEntityList = systemService.findHql(hql0,id0);
|
||||
req.setAttribute("wmToUpGoodsList", wmToUpGoodsEntityList);
|
||||
}catch(Exception e){
|
||||
logger.info(e.getMessage());
|
||||
}
|
||||
return new ModelAndView("com/zzjee/wm/wmToUpGoodsList");
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
*/
|
||||
@RequestMapping(params = "exportXls")
|
||||
public String exportXls(WmToUpEntity wmToUp,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid,ModelMap map) {
|
||||
CriteriaQuery cq = new CriteriaQuery(WmToUpEntity.class, dataGrid);
|
||||
//查询条件组装器
|
||||
org.jeecgframework.core.extend.hqlsearch.HqlGenerateUtil.installHql(cq, wmToUp);
|
||||
try{
|
||||
//自定义追加查询条件
|
||||
}catch (Exception e) {
|
||||
throw new BusinessException(e.getMessage());
|
||||
}
|
||||
cq.add();
|
||||
List<WmToUpEntity> list=this.wmToUpService.getListByCriteriaQuery(cq, false);
|
||||
List<WmToUpPage> pageList=new ArrayList<WmToUpPage>();
|
||||
if(list!=null&&list.size()>0){
|
||||
for(WmToUpEntity entity:list){
|
||||
try{
|
||||
WmToUpPage page=new WmToUpPage();
|
||||
MyBeanUtils.copyBeanNotNull2Bean(entity,page);
|
||||
Object id0 = entity.getId();
|
||||
String hql0 = "from WmToUpGoodsEntity where 1 = 1 AND wmToUpId = ? ";
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsEntityList = systemService.findHql(hql0,id0);
|
||||
page.setWmToUpGoodsList(wmToUpGoodsEntityList);
|
||||
pageList.add(page);
|
||||
}catch(Exception e){
|
||||
logger.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
map.put(NormalExcelConstants.FILE_NAME,"上架明细");
|
||||
map.put(NormalExcelConstants.CLASS,WmToUpPage.class);
|
||||
map.put(NormalExcelConstants.PARAMS,new ExportParams("上架明细列表", "导出人:Jeecg",
|
||||
"导出信息"));
|
||||
map.put(NormalExcelConstants.DATA_LIST,pageList);
|
||||
return NormalExcelConstants.JEECG_EXCEL_VIEW;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
* @param request
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@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(2);
|
||||
params.setNeedSave(true);
|
||||
try {
|
||||
List<WmToUpPage> list = ExcelImportUtil.importExcel(file.getInputStream(), WmToUpPage.class, params);
|
||||
WmToUpEntity entity1=null;
|
||||
for (WmToUpPage page : list) {
|
||||
entity1=new WmToUpEntity();
|
||||
MyBeanUtils.copyBeanNotNull2Bean(page,entity1);
|
||||
wmToUpService.addMain(entity1, page.getWmToUpGoodsList());
|
||||
}
|
||||
j.setMsg("文件导入成功!");
|
||||
} catch (Exception e) {
|
||||
j.setMsg("文件导入失败!");
|
||||
logger.error(ExceptionUtil.getExceptionMessage(e));
|
||||
}finally{
|
||||
try {
|
||||
file.getInputStream().close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
return j;
|
||||
}
|
||||
/**
|
||||
* 导出excel 使模板
|
||||
*/
|
||||
@RequestMapping(params = "exportXlsByT")
|
||||
public String exportXlsByT(ModelMap map) {
|
||||
map.put(NormalExcelConstants.FILE_NAME,"上架明细");
|
||||
map.put(NormalExcelConstants.CLASS,WmToUpPage.class);
|
||||
map.put(NormalExcelConstants.PARAMS,new ExportParams("上架明细列表", "导出人:"+ ResourceUtil.getSessionUserName().getRealName(),
|
||||
"导出信息"));
|
||||
map.put(NormalExcelConstants.DATA_LIST,new ArrayList());
|
||||
return NormalExcelConstants.JEECG_EXCEL_VIEW;
|
||||
}
|
||||
/**
|
||||
* 导入功能跳转
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(params = "upload")
|
||||
public ModelAndView upload(HttpServletRequest req) {
|
||||
req.setAttribute("controller_name", "wmToUpController");
|
||||
return new ModelAndView("common/upload/pub_excel_upload");
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping(method = RequestMethod.GET)
|
||||
@ResponseBody
|
||||
public List<WmToUpEntity> list() {
|
||||
List<WmToUpEntity> listWmToUps=wmToUpService.getList(WmToUpEntity.class);
|
||||
return listWmToUps;
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/{id}", method = RequestMethod.GET)
|
||||
@ResponseBody
|
||||
public ResponseEntity<?> get(@PathVariable("id") String id) {
|
||||
WmToUpEntity task = wmToUpService.get(WmToUpEntity.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 WmToUpPage wmToUpPage, UriComponentsBuilder uriBuilder) {
|
||||
//调用JSR303 Bean Validator进行校验,如果出错返回含400错误码及json格式的错误信息.
|
||||
Set<ConstraintViolation<WmToUpPage>> failures = validator.validate(wmToUpPage);
|
||||
if (!failures.isEmpty()) {
|
||||
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
|
||||
//保存
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList = wmToUpPage.getWmToUpGoodsList();
|
||||
|
||||
WmToUpEntity wmToUp = new WmToUpEntity();
|
||||
try{
|
||||
MyBeanUtils.copyBeanNotNull2Bean(wmToUp,wmToUpPage);
|
||||
}catch(Exception e){
|
||||
logger.info(e.getMessage());
|
||||
}
|
||||
wmToUpService.addMain(wmToUp, wmToUpGoodsList);
|
||||
|
||||
//按照Restful风格约定,创建指向新任务的url, 也可以直接返回id或对象.
|
||||
String id = wmToUpPage.getId();
|
||||
URI uri = uriBuilder.path("/rest/wmToUpController/" + 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 WmToUpPage wmToUpPage) {
|
||||
//调用JSR303 Bean Validator进行校验,如果出错返回含400错误码及json格式的错误信息.
|
||||
Set<ConstraintViolation<WmToUpPage>> failures = validator.validate(wmToUpPage);
|
||||
if (!failures.isEmpty()) {
|
||||
return new ResponseEntity(BeanValidators.extractPropertyAndMessage(failures), HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
|
||||
//保存
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList = wmToUpPage.getWmToUpGoodsList();
|
||||
|
||||
WmToUpEntity wmToUp = new WmToUpEntity();
|
||||
try{
|
||||
MyBeanUtils.copyBeanNotNull2Bean(wmToUp,wmToUpPage);
|
||||
}catch(Exception e){
|
||||
logger.info(e.getMessage());
|
||||
}
|
||||
wmToUpService.updateMain(wmToUp, wmToUpGoodsList);
|
||||
|
||||
//按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) {
|
||||
WmToUpEntity wmToUp = wmToUpService.get(WmToUpEntity.class, id);
|
||||
wmToUpService.delMain(wmToUp);
|
||||
}
|
||||
}
|
|
@ -1,300 +0,0 @@
|
|||
package com.zzjee.wm.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 erzhongxmu
|
||||
* @date 2017-08-20 17:57:54
|
||||
* @version V1.0
|
||||
*
|
||||
*/
|
||||
@Entity
|
||||
@Table(name = "wm_to_up", schema = "")
|
||||
@SuppressWarnings("serial")
|
||||
public class WmToUpEntity implements java.io.Serializable {
|
||||
/**主键*/
|
||||
private java.lang.String id;
|
||||
/**创建人名称*/
|
||||
private java.lang.String createName;
|
||||
/**创建人登录名称*/
|
||||
private java.lang.String createBy;
|
||||
/**创建日期*/
|
||||
private java.util.Date createDate;
|
||||
/**更新人名称*/
|
||||
private java.lang.String updateName;
|
||||
/**更新人登录名称*/
|
||||
private java.lang.String updateBy;
|
||||
/**更新日期*/
|
||||
private java.util.Date updateDate;
|
||||
/**所属部门*/
|
||||
private java.lang.String sysOrgCode;
|
||||
/**所属公司*/
|
||||
private java.lang.String sysCompanyCode;
|
||||
/**托盘码*/
|
||||
@Excel(name="托盘码")
|
||||
private java.lang.String binId;
|
||||
/**库位编码*/
|
||||
@Excel(name="库位编码")
|
||||
private java.lang.String kuWeiBianMa;
|
||||
/**作业类型*/
|
||||
@Excel(name="作业类型")
|
||||
private java.lang.String actTypeCode;
|
||||
/**货主*/
|
||||
@Excel(name="货主")
|
||||
private java.lang.String cusCode;
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 主键
|
||||
*/
|
||||
@Id
|
||||
@GeneratedValue(generator = "paymentableGenerator")
|
||||
@GenericGenerator(name = "paymentableGenerator", strategy = "uuid")
|
||||
|
||||
@Column(name ="ID",nullable=false,length=36)
|
||||
public java.lang.String getId(){
|
||||
return this.id;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 主键
|
||||
*/
|
||||
public void setId(java.lang.String id){
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 创建人名称
|
||||
*/
|
||||
|
||||
@Column(name ="CREATE_NAME",nullable=true,length=50)
|
||||
public java.lang.String getCreateName(){
|
||||
return this.createName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 创建人名称
|
||||
*/
|
||||
public void setCreateName(java.lang.String createName){
|
||||
this.createName = createName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 创建人登录名称
|
||||
*/
|
||||
|
||||
@Column(name ="CREATE_BY",nullable=true,length=50)
|
||||
public java.lang.String getCreateBy(){
|
||||
return this.createBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 创建人登录名称
|
||||
*/
|
||||
public void setCreateBy(java.lang.String createBy){
|
||||
this.createBy = createBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.util.Date
|
||||
*@return: java.util.Date 创建日期
|
||||
*/
|
||||
|
||||
@Column(name ="CREATE_DATE",nullable=true,length=20)
|
||||
public java.util.Date getCreateDate(){
|
||||
return this.createDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.util.Date
|
||||
*@param: java.util.Date 创建日期
|
||||
*/
|
||||
public void setCreateDate(java.util.Date createDate){
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 更新人名称
|
||||
*/
|
||||
|
||||
@Column(name ="UPDATE_NAME",nullable=true,length=50)
|
||||
public java.lang.String getUpdateName(){
|
||||
return this.updateName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 更新人名称
|
||||
*/
|
||||
public void setUpdateName(java.lang.String updateName){
|
||||
this.updateName = updateName;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 更新人登录名称
|
||||
*/
|
||||
|
||||
@Column(name ="UPDATE_BY",nullable=true,length=50)
|
||||
public java.lang.String getUpdateBy(){
|
||||
return this.updateBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 更新人登录名称
|
||||
*/
|
||||
public void setUpdateBy(java.lang.String updateBy){
|
||||
this.updateBy = updateBy;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.util.Date
|
||||
*@return: java.util.Date 更新日期
|
||||
*/
|
||||
|
||||
@Column(name ="UPDATE_DATE",nullable=true,length=20)
|
||||
public java.util.Date getUpdateDate(){
|
||||
return this.updateDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.util.Date
|
||||
*@param: java.util.Date 更新日期
|
||||
*/
|
||||
public void setUpdateDate(java.util.Date updateDate){
|
||||
this.updateDate = updateDate;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 所属部门
|
||||
*/
|
||||
|
||||
@Column(name ="SYS_ORG_CODE",nullable=true,length=50)
|
||||
public java.lang.String getSysOrgCode(){
|
||||
return this.sysOrgCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 所属部门
|
||||
*/
|
||||
public void setSysOrgCode(java.lang.String sysOrgCode){
|
||||
this.sysOrgCode = sysOrgCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 所属公司
|
||||
*/
|
||||
|
||||
@Column(name ="SYS_COMPANY_CODE",nullable=true,length=50)
|
||||
public java.lang.String getSysCompanyCode(){
|
||||
return this.sysCompanyCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 所属公司
|
||||
*/
|
||||
public void setSysCompanyCode(java.lang.String sysCompanyCode){
|
||||
this.sysCompanyCode = sysCompanyCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 托盘码
|
||||
*/
|
||||
|
||||
@Column(name ="BIN_ID",nullable=true,length=32)
|
||||
public java.lang.String getBinId(){
|
||||
return this.binId;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 托盘码
|
||||
*/
|
||||
public void setBinId(java.lang.String binId){
|
||||
this.binId = binId;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 库位编码
|
||||
*/
|
||||
|
||||
@Column(name ="KU_WEI_BIAN_MA",nullable=true,length=32)
|
||||
public java.lang.String getKuWeiBianMa(){
|
||||
return this.kuWeiBianMa;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 库位编码
|
||||
*/
|
||||
public void setKuWeiBianMa(java.lang.String kuWeiBianMa){
|
||||
this.kuWeiBianMa = kuWeiBianMa;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 作业类型
|
||||
*/
|
||||
|
||||
@Column(name ="ACT_TYPE_CODE",nullable=true,length=32)
|
||||
public java.lang.String getActTypeCode(){
|
||||
return this.actTypeCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 作业类型
|
||||
*/
|
||||
public void setActTypeCode(java.lang.String actTypeCode){
|
||||
this.actTypeCode = actTypeCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 取得java.lang.String
|
||||
*@return: java.lang.String 货主
|
||||
*/
|
||||
|
||||
@Column(name ="CUS_CODE",nullable=true,length=32)
|
||||
public java.lang.String getCusCode(){
|
||||
return this.cusCode;
|
||||
}
|
||||
|
||||
/**
|
||||
*方法: 设置java.lang.String
|
||||
*@param: java.lang.String 货主
|
||||
*/
|
||||
public void setCusCode(java.lang.String cusCode){
|
||||
this.cusCode = cusCode;
|
||||
}
|
||||
|
||||
}
|
|
@ -1,44 +0,0 @@
|
|||
package com.zzjee.wm.service;
|
||||
import com.zzjee.wm.entity.WmToUpEntity;
|
||||
import com.zzjee.wm.entity.WmToUpGoodsEntity;
|
||||
|
||||
import java.util.List;
|
||||
import org.jeecgframework.core.common.service.CommonService;
|
||||
import java.io.Serializable;
|
||||
|
||||
public interface WmToUpServiceI extends CommonService{
|
||||
|
||||
public <T> void delete(T entity);
|
||||
/**
|
||||
* 添加一对多
|
||||
*
|
||||
*/
|
||||
public void addMain(WmToUpEntity wmToUp,
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList) ;
|
||||
/**
|
||||
* 修改一对多
|
||||
*
|
||||
*/
|
||||
public void updateMain(WmToUpEntity wmToUp,
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList);
|
||||
public void delMain (WmToUpEntity wmToUp);
|
||||
|
||||
/**
|
||||
* 默认按钮-sql增强-新增操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doAddSql(WmToUpEntity t);
|
||||
/**
|
||||
* 默认按钮-sql增强-更新操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doUpdateSql(WmToUpEntity t);
|
||||
/**
|
||||
* 默认按钮-sql增强-删除操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doDelSql(WmToUpEntity t);
|
||||
}
|
|
@ -1,160 +0,0 @@
|
|||
package com.zzjee.wm.service.impl;
|
||||
import com.zzjee.wm.service.WmToUpServiceI;
|
||||
import org.jeecgframework.core.common.service.impl.CommonServiceImpl;
|
||||
import com.zzjee.wm.entity.WmToUpEntity;
|
||||
import com.zzjee.wm.entity.WmToUpGoodsEntity;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import java.util.List;
|
||||
import org.jeecgframework.core.common.exception.BusinessException;
|
||||
import org.jeecgframework.core.common.service.impl.CommonServiceImpl;
|
||||
import org.jeecgframework.core.util.MyBeanUtils;
|
||||
import org.jeecgframework.core.util.StringUtil;
|
||||
import org.jeecgframework.core.util.oConvertUtils;
|
||||
import java.util.ArrayList;
|
||||
import java.util.UUID;
|
||||
import java.io.Serializable;
|
||||
|
||||
|
||||
@Service("wmToUpService")
|
||||
@Transactional
|
||||
public class WmToUpServiceImpl extends CommonServiceImpl implements WmToUpServiceI {
|
||||
|
||||
public <T> void delete(T entity) {
|
||||
super.delete(entity);
|
||||
//执行删除操作配置的sql增强
|
||||
this.doDelSql((WmToUpEntity)entity);
|
||||
}
|
||||
|
||||
public void addMain(WmToUpEntity wmToUp,
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList){
|
||||
//保存主信息
|
||||
this.save(wmToUp);
|
||||
|
||||
/**保存-上架商品明细*/
|
||||
for(WmToUpGoodsEntity wmToUpGoods:wmToUpGoodsList){
|
||||
//外键设置
|
||||
wmToUpGoods.setCusCode(wmToUp.getCusCode());
|
||||
wmToUpGoods.setKuWeiBianMa(wmToUp.getKuWeiBianMa());
|
||||
wmToUpGoods.setBinId(wmToUp.getBinId());
|
||||
wmToUpGoods.setActTypeCode(wmToUp.getActTypeCode());
|
||||
wmToUpGoods.setWmToUpId(wmToUp.getId());
|
||||
this.save(wmToUpGoods);
|
||||
}
|
||||
//执行新增操作配置的sql增强
|
||||
this.doAddSql(wmToUp);
|
||||
}
|
||||
|
||||
|
||||
public void updateMain(WmToUpEntity wmToUp,
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsList) {
|
||||
//保存主表信息
|
||||
this.saveOrUpdate(wmToUp);
|
||||
//===================================================================================
|
||||
//获取参数
|
||||
Object id0 = wmToUp.getId();
|
||||
//===================================================================================
|
||||
//1.查询出数据库的明细数据-上架商品明细
|
||||
String hql0 = "from WmToUpGoodsEntity where 1 = 1 AND wM_TO_UP_ID = ? ";
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsOldList = this.findHql(hql0,id0);
|
||||
//2.筛选更新明细数据-上架商品明细
|
||||
if(wmToUpGoodsList!=null&&wmToUpGoodsList.size()>0){
|
||||
for(WmToUpGoodsEntity oldE:wmToUpGoodsOldList){
|
||||
boolean isUpdate = false;
|
||||
for(WmToUpGoodsEntity sendE:wmToUpGoodsList){
|
||||
//需要更新的明细数据-上架商品明细
|
||||
if(oldE.getId().equals(sendE.getId())){
|
||||
try {
|
||||
MyBeanUtils.copyBeanNotNull2Bean(sendE,oldE);
|
||||
this.saveOrUpdate(oldE);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new BusinessException(e.getMessage());
|
||||
}
|
||||
isUpdate= true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!isUpdate){
|
||||
//如果数据库存在的明细,前台没有传递过来则是删除-上架商品明细
|
||||
super.delete(oldE);
|
||||
}
|
||||
|
||||
}
|
||||
//3.持久化新增的数据-上架商品明细
|
||||
for(WmToUpGoodsEntity wmToUpGoods:wmToUpGoodsList){
|
||||
if(oConvertUtils.isEmpty(wmToUpGoods.getId())){
|
||||
//外键设置
|
||||
wmToUpGoods.setWmToUpId(wmToUp.getId());
|
||||
this.save(wmToUpGoods);
|
||||
}
|
||||
}
|
||||
}
|
||||
//执行更新操作配置的sql增强
|
||||
this.doUpdateSql(wmToUp);
|
||||
}
|
||||
|
||||
|
||||
public void delMain(WmToUpEntity wmToUp) {
|
||||
//删除主表信息
|
||||
this.delete(wmToUp);
|
||||
//===================================================================================
|
||||
//获取参数
|
||||
Object id0 = wmToUp.getId();
|
||||
//===================================================================================
|
||||
//删除-上架商品明细
|
||||
String hql0 = "from WmToUpGoodsEntity where 1 = 1 AND wM_TO_UP_ID = ? ";
|
||||
List<WmToUpGoodsEntity> wmToUpGoodsOldList = this.findHql(hql0,id0);
|
||||
this.deleteAllEntitie(wmToUpGoodsOldList);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 默认按钮-sql增强-新增操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doAddSql(WmToUpEntity t){
|
||||
return true;
|
||||
}
|
||||
/**
|
||||
* 默认按钮-sql增强-更新操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doUpdateSql(WmToUpEntity t){
|
||||
return true;
|
||||
}
|
||||
/**
|
||||
* 默认按钮-sql增强-删除操作
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public boolean doDelSql(WmToUpEntity t){
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* 替换sql中的变量
|
||||
* @param sql
|
||||
* @return
|
||||
*/
|
||||
public String replaceVal(String sql,WmToUpEntity 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("#{bin_id}",String.valueOf(t.getBinId()));
|
||||
sql = sql.replace("#{ku_wei_bian_ma}",String.valueOf(t.getKuWeiBianMa()));
|
||||
sql = sql.replace("#{act_type_code}",String.valueOf(t.getActTypeCode()));
|
||||
sql = sql.replace("#{cus_code}",String.valueOf(t.getCusCode()));
|
||||
sql = sql.replace("#{UUID}",UUID.randomUUID().toString());
|
||||
return sql;
|
||||
}
|
||||
}
|
|
@ -102,20 +102,5 @@ a.a02:active, a.a01:hover{font-size:12px; font-family:verdana; width:90px; margi
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
//导入
|
||||
function ImportXls() {
|
||||
openuploadwin('Excel导入', 'mvCusCostController.do?upload', "mvCusCostList");
|
||||
}
|
||||
|
||||
//导出
|
||||
function ExportXls() {
|
||||
JeecgExcelExport("mvCusCostController.do?exportXls","mvCusCostList");
|
||||
}
|
||||
|
||||
//模板下载
|
||||
function ExportXlsByT() {
|
||||
JeecgExcelExport("mvCusCostController.do?exportXlsByT","mvCusCostList");
|
||||
}
|
||||
|
||||
</script>
|
|
@ -1,150 +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 lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>销售排行</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/vendor.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap-theme.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/app.css">
|
||||
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/style.css" type="text/css"/>
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/tablefrom.css" type="text/css"/>
|
||||
|
||||
<script type="text/javascript" src="plug-in/jquery/jquery-1.8.3.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/dataformat.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/jquery.easyui.min.1.3.2.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/locale/zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/syUtil.js"></script>
|
||||
<script type="text/javascript" src="plug-in/My97DatePicker/WdatePicker.js"></script>
|
||||
<script type="text/javascript" src="plug-in/lhgDialog/lhgdialog.min.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/curdtools_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/easyuiextend.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_v5.3.1_min_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_Datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/plugin/passwordStrength/passwordStrength-min.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.config.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.all.min.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
//编写自定义JS代码
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="zzSalescountController.do?doAdd" tiptype="1" >
|
||||
<input type="hidden" id="btn_sub" class="btn_sub"/>
|
||||
<input type="hidden" id="id" name="id"/>
|
||||
<div class="tab-wrapper">
|
||||
<!-- tab -->
|
||||
<ul class="nav nav-tabs">
|
||||
<li role="presentation" class="active"><a href="javascript:void(0);">销售排行</a></li>
|
||||
</ul>
|
||||
<!-- tab内容 -->
|
||||
<div class="con-wrapper" id="con-wrapper1" style="display: block;">
|
||||
<div class="row form-wrapper">
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售年:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdYear" name="sdYear" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售年</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售月:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdMonth" name="sdMonth" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售月</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdCount" name="sdCount" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售额:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdCountm" name="sdCountm" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售额</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" id = "sub_tr" style="display: none;">
|
||||
<div class="col-xs-12 layout-header">
|
||||
<div class="col-xs-6"></div>
|
||||
<div class="col-xs-6"><button type="button" onclick="neibuClick();" class="btn btn-default">提交</button></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="con-wrapper" id="con-wrapper2" style="display: block;"></div>
|
||||
</div>
|
||||
</t:formvalid>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
//查看模式情况下,删除和上传附件功能禁止使用
|
||||
if(location.href.indexOf("load=detail")!=-1){
|
||||
$(".jeecgDetail").hide();
|
||||
}
|
||||
|
||||
if(location.href.indexOf("mode=read")!=-1){
|
||||
//查看模式控件禁用
|
||||
$("#formobj").find(":input").attr("disabled","disabled");
|
||||
}
|
||||
if(location.href.indexOf("mode=onbutton")!=-1){
|
||||
//其他模式显示提交按钮
|
||||
$("#sub_tr").show();
|
||||
}
|
||||
});
|
||||
|
||||
var neibuClickFlag = false;
|
||||
function neibuClick() {
|
||||
neibuClickFlag = true;
|
||||
$('#btn_sub').trigger('click');
|
||||
}
|
||||
|
||||
</script>
|
||||
</body>
|
||||
<script src = "webpage/com/zzjee/sales/zzSalescount.js"></script>
|
||||
</html>
|
|
@ -1,150 +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 lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>销售排行</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/vendor.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap-theme.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/app.css">
|
||||
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/style.css" type="text/css"/>
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/tablefrom.css" type="text/css"/>
|
||||
|
||||
<script type="text/javascript" src="plug-in/jquery/jquery-1.8.3.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/dataformat.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/jquery.easyui.min.1.3.2.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/locale/zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/syUtil.js"></script>
|
||||
<script type="text/javascript" src="plug-in/My97DatePicker/WdatePicker.js"></script>
|
||||
<script type="text/javascript" src="plug-in/lhgDialog/lhgdialog.min.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/curdtools_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/easyuiextend.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_v5.3.1_min_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_Datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/plugin/passwordStrength/passwordStrength-min.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.config.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.all.min.js"></script>
|
||||
<script type="text/javascript">
|
||||
//编写自定义JS代码
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="zzSalescountController.do?doUpdate" tiptype="1" >
|
||||
<input type="hidden" id="btn_sub" class="btn_sub"/>
|
||||
<input type="hidden" name="id" value='${zzSalescountPage.id}' >
|
||||
|
||||
|
||||
<div class="tab-wrapper">
|
||||
<!-- tab -->
|
||||
<ul class="nav nav-tabs">
|
||||
<li role="presentation" class="active"><a href="javascript:void(0);">销售排行</a></li>
|
||||
</ul>
|
||||
<!-- tab内容 -->
|
||||
<div class="con-wrapper" id="con-wrapper1" style="display: block;">
|
||||
<div class="row form-wrapper">
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售年:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdYear" name="sdYear" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${zzSalescountPage.sdYear}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售年</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售月:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdMonth" name="sdMonth" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${zzSalescountPage.sdMonth}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售月</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdCount" name="sdCount" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${zzSalescountPage.sdCount}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>销售额:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="sdCountm" name="sdCountm" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${zzSalescountPage.sdCountm}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">销售额</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" id = "sub_tr" style="display: none;">
|
||||
<div class="col-xs-12 layout-header">
|
||||
<div class="col-xs-6"></div>
|
||||
<div class="col-xs-6"><button type="button" onclick="neibuClick();" class="btn btn-default">提交</button></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="con-wrapper" id="con-wrapper2" style="display: block;"></div>
|
||||
</div>
|
||||
</t:formvalid>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
//查看模式情况下,删除和上传附件功能禁止使用
|
||||
if(location.href.indexOf("load=detail")!=-1){
|
||||
$(".jeecgDetail").hide();
|
||||
}
|
||||
|
||||
if(location.href.indexOf("mode=read")!=-1){
|
||||
//查看模式控件禁用
|
||||
$("#formobj").find(":input").attr("disabled","disabled");
|
||||
}
|
||||
if(location.href.indexOf("mode=onbutton")!=-1){
|
||||
//其他模式显示提交按钮
|
||||
$("#sub_tr").show();
|
||||
}
|
||||
});
|
||||
|
||||
var neibuClickFlag = false;
|
||||
function neibuClick() {
|
||||
neibuClickFlag = true;
|
||||
$('#btn_sub').trigger('click');
|
||||
}
|
||||
|
||||
</script>
|
||||
</body>
|
||||
<script src = "webpage/com/zzjee/sales/zzSalescount.js"></script>
|
||||
</html>
|
|
@ -1,28 +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 decode(value, id) {//value传入值,id接受值
|
||||
var last = value.lastIndexOf("/");
|
||||
var filename = value.substring(last + 1, value.length);
|
||||
$("#" + id).text(decodeURIComponent(filename));
|
||||
}
|
|
@ -1,55 +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="zzSalescountList" checkbox="true" pagination="true" fitColumns="false" title="销售排行" actionUrl="zzSalescountController.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="sdYear" query="true" queryMode="single" width="120"></t:dgCol>
|
||||
<t:dgCol title="销售月" field="sdMonth" query="true" queryMode="single" width="120"></t:dgCol>
|
||||
<t:dgCol title="销售量" field="sdCount" queryMode="single" width="120"></t:dgCol>
|
||||
<t:dgCol title="销售额" field="sdCountm" queryMode="single" width="120"></t:dgCol>
|
||||
<t:dgCol title="操作" field="opt" width="100"></t:dgCol>
|
||||
<t:dgDelOpt title="删除" url="zzSalescountController.do?doDel&id={id}" urlclass="ace_button" urlfont="fa-trash-o"/>
|
||||
<t:dgToolBar title="录入" icon="icon-add" url="zzSalescountController.do?goAdd" funname="add"></t:dgToolBar>
|
||||
<t:dgToolBar title="编辑" icon="icon-edit" url="zzSalescountController.do?goUpdate" funname="update"></t:dgToolBar>
|
||||
<t:dgToolBar title="批量删除" icon="icon-remove" url="zzSalescountController.do?doBatchDel" funname="deleteALLSelect"></t:dgToolBar>
|
||||
<t:dgToolBar title="查看" icon="icon-search" url="zzSalescountController.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/sales/zzSalescountList.js"></script>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
});
|
||||
|
||||
|
||||
|
||||
//导入
|
||||
function ImportXls() {
|
||||
openuploadwin('Excel导入', 'zzSalescountController.do?upload', "zzSalescountList");
|
||||
}
|
||||
|
||||
//导出
|
||||
function ExportXls() {
|
||||
JeecgExcelExport("zzSalescountController.do?exportXls","zzSalescountList");
|
||||
}
|
||||
|
||||
//模板下载
|
||||
function ExportXlsByT() {
|
||||
JeecgExcelExport("zzSalescountController.do?exportXlsByT","zzSalescountList");
|
||||
}
|
||||
|
||||
|
||||
</script>
|
|
@ -3,7 +3,7 @@
|
|||
<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="wmSttInGoodsList" pageSize="10000" checkbox="true" pagination="true" fitColumns="false" title="差异过账" actionUrl="wmSttInGoodsController.do?datagridcygz" idField="id" fit="true" queryMode="group">
|
||||
<t:datagrid name="wmSttInGoodsList" pageSize="30" checkbox="true" pagination="true" fitColumns="false" title="差异过账" actionUrl="wmSttInGoodsController.do?datagridcygz" idField="id" fit="true" queryMode="group">
|
||||
<t:dgCol title="操作" field="opt" width="100"></t:dgCol>
|
||||
<t:dgCol title="主键" field="id" hidden="true" queryMode="group" width="120"></t:dgCol>
|
||||
<t:dgCol title="所属部门" field="sysOrgCode" hidden="true" queryMode="group" width="120"></t:dgCol>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<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="wmSttInGoodsList" pageSize="10000" checkbox="true" pagination="true" fitColumns="false" title="库存盘点" actionUrl="wmSttInGoodsController.do?datagridfp" idField="id" fit="true" queryMode="group">
|
||||
<t:datagrid name="wmSttInGoodsList" pageSize="30" checkbox="true" pagination="true" fitColumns="false" title="库存盘点" actionUrl="wmSttInGoodsController.do?datagridfp" idField="id" fit="true" queryMode="group">
|
||||
<t:dgCol title="主键" field="id" hidden="true" queryMode="group" width="120"></t:dgCol>
|
||||
<t:dgCol title="创建人名称" field="createName" queryMode="group" width="80"></t:dgCol>
|
||||
<t:dgCol title="创建人登录名称" field="createBy" hidden="true" queryMode="group" width="120"></t:dgCol>
|
||||
|
|
|
@ -1,28 +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 decode(value, id) {//value传入值,id接受值
|
||||
var last = value.lastIndexOf("/");
|
||||
var filename = value.substring(last + 1, value.length);
|
||||
$("#" + id).text(decodeURIComponent(filename));
|
||||
}
|
|
@ -1,318 +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 lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>客户库存</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/vendor.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap-theme.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/app.css">
|
||||
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/style.css" type="text/css"/>
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/tablefrom.css" type="text/css"/>
|
||||
|
||||
<script type="text/javascript" src="plug-in/jquery/jquery-1.8.3.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/dataformat.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/jquery.easyui.min.1.3.2.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/locale/zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/syUtil.js"></script>
|
||||
<script type="text/javascript" src="plug-in/My97DatePicker/WdatePicker.js"></script>
|
||||
<script type="text/javascript" src="plug-in/lhgDialog/lhgdialog.min.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/curdtools_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/easyuiextend.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_v5.3.1_min_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_Datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/plugin/passwordStrength/passwordStrength-min.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.config.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.all.min.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
//编写自定义JS代码
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="mvStockCusController.do?doAdd" tiptype="1" >
|
||||
<input type="hidden" id="btn_sub" class="btn_sub"/>
|
||||
<input type="hidden" id="id" name="id"/>
|
||||
<div class="tab-wrapper">
|
||||
<!-- tab -->
|
||||
<ul class="nav nav-tabs">
|
||||
<li role="presentation" class="active"><a href="javascript:void(0);">客户库存</a></li>
|
||||
</ul>
|
||||
<!-- tab内容 -->
|
||||
<div class="con-wrapper" id="con-wrapper1" style="display: block;">
|
||||
<div class="row form-wrapper">
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存类型:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="kuctype" name="kuctype" type="text" class="form-control"
|
||||
ignore="checked"
|
||||
datatype="*" />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存类型</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>数量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsQua" name="goodsQua" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">数量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsUnit" name="goodsUnit" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存数量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="baseGoodscount" name="baseGoodscount" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存数量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="baseUnit" name="baseUnit" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>储位编码:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="kuWeiBianMa" name="kuWeiBianMa" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">储位编码</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>托盘:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="binId" name="binId" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">托盘</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>客户:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="cusCode" name="cusCode" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">客户</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>客户名称:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="zhongWenQch" name="zhongWenQch" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">客户名称</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>商品编码:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsId" name="goodsId" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">商品编码</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>商品名称:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shpMingCheng" name="shpMingCheng" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">商品名称</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shlDanWei" name="shlDanWei" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>生产日期:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsProData" name="goodsProData" type="text"
|
||||
ignore="ignore"
|
||||
style="background: url('plug-in/ace/images/datetime.png') no-repeat scroll right center transparent;" class="form-control" onClick="WdatePicker()" type="date" pattern="yyyy-MM-dd"/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">生产日期</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>保质期:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="bzhiQi" name="bzhiQi" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">保质期</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>取货次序:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="quHuoCiXu" name="quHuoCiXu" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">取货次序</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>上架次序:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shangJiaCiXu" name="shangJiaCiXu" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
/>
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">上架次序</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" id = "sub_tr" style="display: none;">
|
||||
<div class="col-xs-12 layout-header">
|
||||
<div class="col-xs-6"></div>
|
||||
<div class="col-xs-6"><button type="button" onclick="neibuClick();" class="btn btn-default">提交</button></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="con-wrapper" id="con-wrapper2" style="display: block;"></div>
|
||||
</div>
|
||||
</t:formvalid>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
//查看模式情况下,删除和上传附件功能禁止使用
|
||||
if(location.href.indexOf("load=detail")!=-1){
|
||||
$(".jeecgDetail").hide();
|
||||
}
|
||||
|
||||
if(location.href.indexOf("mode=read")!=-1){
|
||||
//查看模式控件禁用
|
||||
$("#formobj").find(":input").attr("disabled","disabled");
|
||||
}
|
||||
if(location.href.indexOf("mode=onbutton")!=-1){
|
||||
//其他模式显示提交按钮
|
||||
$("#sub_tr").show();
|
||||
}
|
||||
});
|
||||
|
||||
var neibuClickFlag = false;
|
||||
function neibuClick() {
|
||||
neibuClickFlag = true;
|
||||
$('#btn_sub').trigger('click');
|
||||
}
|
||||
|
||||
</script>
|
||||
</body>
|
||||
<script src = "webpage/com/zzjee/wv/mvStockCus.js"></script>
|
||||
</html>
|
|
@ -1,318 +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 lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>客户库存</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/vendor.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap-theme.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/bootstrap.css">
|
||||
<link rel="stylesheet" href="online/template/ledefault/css/app.css">
|
||||
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/style.css" type="text/css"/>
|
||||
<link rel="stylesheet" href="plug-in/Validform/css/metrole/tablefrom.css" type="text/css"/>
|
||||
|
||||
<script type="text/javascript" src="plug-in/jquery/jquery-1.8.3.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/dataformat.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/jquery.easyui.min.1.3.2.js"></script>
|
||||
<script type="text/javascript" src="plug-in/easyui/locale/zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/syUtil.js"></script>
|
||||
<script type="text/javascript" src="plug-in/My97DatePicker/WdatePicker.js"></script>
|
||||
<script type="text/javascript" src="plug-in/lhgDialog/lhgdialog.min.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/curdtools_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/tools/easyuiextend.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_v5.3.1_min_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/Validform_Datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/js/datatype_zh-cn.js"></script>
|
||||
<script type="text/javascript" src="plug-in/Validform/plugin/passwordStrength/passwordStrength-min.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.config.js"></script>
|
||||
<script type="text/javascript" charset="utf-8" src="plug-in/ueditor/ueditor.all.min.js"></script>
|
||||
<script type="text/javascript">
|
||||
//编写自定义JS代码
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="mvStockCusController.do?doUpdate" tiptype="1" >
|
||||
<input type="hidden" id="btn_sub" class="btn_sub"/>
|
||||
<input type="hidden" name="id" value='${mvStockCusPage.id}' >
|
||||
|
||||
|
||||
<div class="tab-wrapper">
|
||||
<!-- tab -->
|
||||
<ul class="nav nav-tabs">
|
||||
<li role="presentation" class="active"><a href="javascript:void(0);">客户库存</a></li>
|
||||
</ul>
|
||||
<!-- tab内容 -->
|
||||
<div class="con-wrapper" id="con-wrapper1" style="display: block;">
|
||||
<div class="row form-wrapper">
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存类型:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="kuctype" name="kuctype" type="text" class="form-control"
|
||||
ignore="checked"
|
||||
datatype="*" value='${mvStockCusPage.kuctype}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存类型</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>数量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsQua" name="goodsQua" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.goodsQua}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">数量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsUnit" name="goodsUnit" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.goodsUnit}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存数量:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="baseGoodscount" name="baseGoodscount" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.baseGoodscount}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存数量</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>库存单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="baseUnit" name="baseUnit" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.baseUnit}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">库存单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>储位编码:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="kuWeiBianMa" name="kuWeiBianMa" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.kuWeiBianMa}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">储位编码</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>托盘:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="binId" name="binId" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.binId}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">托盘</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>客户:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="cusCode" name="cusCode" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.cusCode}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">客户</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>客户名称:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="zhongWenQch" name="zhongWenQch" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.zhongWenQch}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">客户名称</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>商品编码:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsId" name="goodsId" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.goodsId}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">商品编码</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>商品名称:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shpMingCheng" name="shpMingCheng" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.shpMingCheng}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">商品名称</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>单位:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shlDanWei" name="shlDanWei" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.shlDanWei}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">单位</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>生产日期:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="goodsProData" name="goodsProData" type="text"
|
||||
ignore="ignore"
|
||||
style="background: url('plug-in/ace/images/datetime.png') no-repeat scroll right center transparent;" class="form-control" onClick="WdatePicker()" value='<fmt:formatDate value='${mvStockCusPage.goodsProData}' type="date" pattern="yyyy-MM-dd"/>' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">生产日期</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>保质期:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="bzhiQi" name="bzhiQi" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.bzhiQi}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">保质期</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>取货次序:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="quHuoCiXu" name="quHuoCiXu" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.quHuoCiXu}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">取货次序</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row show-grid">
|
||||
<div class="col-xs-3 text-center">
|
||||
<b>上架次序:</b>
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
<input id="shangJiaCiXu" name="shangJiaCiXu" type="text" class="form-control"
|
||||
ignore="ignore"
|
||||
value='${mvStockCusPage.shangJiaCiXu}' />
|
||||
<span class="Validform_checktip" style="float:left;height:0px;"></span>
|
||||
<label class="Validform_label" style="display: none">上架次序</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" id = "sub_tr" style="display: none;">
|
||||
<div class="col-xs-12 layout-header">
|
||||
<div class="col-xs-6"></div>
|
||||
<div class="col-xs-6"><button type="button" onclick="neibuClick();" class="btn btn-default">提交</button></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="con-wrapper" id="con-wrapper2" style="display: block;"></div>
|
||||
</div>
|
||||
</t:formvalid>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
//查看模式情况下,删除和上传附件功能禁止使用
|
||||
if(location.href.indexOf("load=detail")!=-1){
|
||||
$(".jeecgDetail").hide();
|
||||
}
|
||||
|
||||
if(location.href.indexOf("mode=read")!=-1){
|
||||
//查看模式控件禁用
|
||||
$("#formobj").find(":input").attr("disabled","disabled");
|
||||
}
|
||||
if(location.href.indexOf("mode=onbutton")!=-1){
|
||||
//其他模式显示提交按钮
|
||||
$("#sub_tr").show();
|
||||
}
|
||||
});
|
||||
|
||||
var neibuClickFlag = false;
|
||||
function neibuClick() {
|
||||
neibuClickFlag = true;
|
||||
$('#btn_sub').trigger('click');
|
||||
}
|
||||
|
||||
</script>
|
||||
</body>
|
||||
<script src = "webpage/com/zzjee/wv/mvStockCus.js"></script>
|
||||
</html>
|
|
@ -1,28 +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 decode(value, id) {//value传入值,id接受值
|
||||
var last = value.lastIndexOf("/");
|
||||
var filename = value.substring(last + 1, value.length);
|
||||
$("#" + id).text(decodeURIComponent(filename));
|
||||
}
|
Loading…
Reference in New Issue