Commit 788ed4c1 authored by suichenguang's avatar suichenguang
parents b2396a9f 6afbba91
...@@ -28,6 +28,12 @@ ...@@ -28,6 +28,12 @@
<dependency> <dependency>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId> <artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-logging</artifactId>
</exclusion>
</exclusions>
</dependency> </dependency>
<dependency> <dependency>
...@@ -50,9 +56,35 @@ ...@@ -50,9 +56,35 @@
<!--引入log4j2作为日志组件--> <!--引入log4j2作为日志组件-->
<!--<dependency>--> <!--<dependency>-->
<!--<groupId>org.springframework.boot</groupId>--> <!--<groupId>org.springframework.boot</groupId>-->
<!--<artifactId>spring-boot-starter-log4j2</artifactId>--> <!--<artifactId>spring-boot-starter-log4j</artifactId>-->
<!--<version>1.3.2.RELEASE</version>-->
<!--</dependency>-->
<!--<dependency>-->
<!--<groupId>log4j</groupId>-->
<!--<artifactId>log4j</artifactId>-->
<!--<version>1.2.17</version>-->
<!--</dependency>--> <!--</dependency>-->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.5</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.7.12</version>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<!-- shiro相关 --> <!-- shiro相关 -->
<dependency> <dependency>
<groupId>org.apache.shiro</groupId> <groupId>org.apache.shiro</groupId>
...@@ -77,6 +109,22 @@ ...@@ -77,6 +109,22 @@
<version>1.6.1</version> <version>1.6.1</version>
</dependency> </dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-log4j</artifactId>
<version>1.3.8.RELEASE</version>
</dependency>
<dependency> <dependency>
<groupId>net.sf.json-lib</groupId> <groupId>net.sf.json-lib</groupId>
<artifactId>json-lib</artifactId> <artifactId>json-lib</artifactId>
......
#控制日志级别,在哪里输出Output pattern : date [thread] priority category - message FATAL 0 ERROR 3 WARN 4 INFO 6 DEBUG 7
log4j.rootLogger=INFO, stdout
#控制台 显示的的方式为控制台普通方式
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
#日志输出的格式
log4j.appender.stdout.layout.ConversionPattern=%d %-5p [%c{5}] - %m%n
#打印sql部分
log4j.logger.java.sql=DEBUG
log4j.logger.java.sql.Connection = DEBUG
log4j.logger.java.sql.Statement = DEBUG
log4j.logger.java.sql.PreparedStatement = DEBUG
log4j.logger.java.sql.ResultSet = DEBUG
log4j.logger.com.yxproject.start.entity=DEBUG
\ No newline at end of file
...@@ -239,7 +239,7 @@ public class AdminApi { ...@@ -239,7 +239,7 @@ public class AdminApi {
SysPermission sysPermission = new SysPermission(); SysPermission sysPermission = new SysPermission();
sysPermission.setName(jsonObject.getString("name")); sysPermission.setName(jsonObject.getString("name"));
sysPermission.setResource_type(jsonObject.getString("resourceType")); sysPermission.setResource_type(jsonObject.getString("resourceType"));
// sysPermission.setUrl(jsonObject.getString("url")); sysPermission.setUrl(jsonObject.getString("url"));
sysPermission.setPermission(jsonObject.getString("permission")); sysPermission.setPermission(jsonObject.getString("permission"));
// sysPermission.setParent_id(Long.parseLong(jsonObject.getString("parentId"))); // sysPermission.setParent_id(Long.parseLong(jsonObject.getString("parentId")));
// if(jsonObject.getString("parentId").equals(str)){ // if(jsonObject.getString("parentId").equals(str)){
...@@ -401,7 +401,7 @@ public class AdminApi { ...@@ -401,7 +401,7 @@ public class AdminApi {
sysPermission.setId(Integer.parseInt(jsonObject.getString("id"))); sysPermission.setId(Integer.parseInt(jsonObject.getString("id")));
sysPermission.setName(jsonObject.getString("name")); sysPermission.setName(jsonObject.getString("name"));
sysPermission.setResource_type(jsonObject.getString("resourceType")); sysPermission.setResource_type(jsonObject.getString("resourceType"));
// sysPermission.setUrl(jsonObject.getString("url")); sysPermission.setUrl(jsonObject.getString("url"));
sysPermission.setPermission(jsonObject.getString("permission")); sysPermission.setPermission(jsonObject.getString("permission"));
// sysPermission.setParent_id(Long.parseLong(parentId)); // sysPermission.setParent_id(Long.parseLong(parentId));
// if(parentId.equals(str)){ // if(parentId.equals(str)){
......
...@@ -19,6 +19,7 @@ import org.dom4j.Attribute; ...@@ -19,6 +19,7 @@ import org.dom4j.Attribute;
import org.dom4j.Document; import org.dom4j.Document;
import org.dom4j.Element; import org.dom4j.Element;
import org.dom4j.io.*; import org.dom4j.io.*;
import org.hibernate.loader.plan.spi.Return;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -127,16 +128,19 @@ public class UserApi { ...@@ -127,16 +128,19 @@ public class UserApi {
* *
* @return * @return
*/ */
@RequestMapping(value = "/updateProductionTask", method = RequestMethod.GET) @RequestMapping(value = "/updateTaskState", method = RequestMethod.GET)
@RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
@ResponseBody @ResponseBody
public String updateProductionTask(@RequestParam("id") String id, HttpServletResponse resp) { public String updateProductionTask(@RequestParam("taskId") Long id,@RequestParam("state") int state, HttpServletResponse resp) {
String map = "{\"production_Task_List_Id\":\"20181016001\",\"make_Type\":8,\"old_Make_Type\":8,} "; // String map = "{\"production_Task_List_Id\":\"20181016001\",\"make_Type\":8,\"old_Make_Type\":8,} ";
JSONObject jsonObject = JSONObject.fromObject(map); // JSONObject jsonObject = JSONObject.fromObject(map);
TaskEntity productionTaskListEntity = (TaskEntity) JSONObject.toBean(jsonObject, TaskEntity.class); // TaskEntity productionTaskListEntity = (TaskEntity) JSONObject.toBean(jsonObject, TaskEntity.class);
TaskEntity taskEntity = new TaskEntity();
taskEntity.setTask_Id(id);
taskEntity.setTask_State_Id(state);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
int i = taskService.updateProductionTask(productionTaskListEntity); int i = taskService.updateProductionTask(taskEntity);
yxjsonResponse.outPutSuccess(i + "更新成功"); yxjsonResponse.outPutSuccess(i + "更新成功");
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
...@@ -349,8 +353,8 @@ public class UserApi { ...@@ -349,8 +353,8 @@ public class UserApi {
*/ */
@RequestMapping("getCountyList") @RequestMapping("getCountyList")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getCountyListInfoByTaskListID(@RequestParam("taskListId") String taskListId,@RequestParam("taskStateId") String taskStateId,@RequestParam("cardType") String cardType, HttpServletResponse resp) { public String getCountyListInfoByTaskId(@RequestParam("taskId") String taskId, HttpServletResponse resp) {
List<CountyEntity> countyListEntity = countyService.findCountyList(taskListId,taskStateId,cardType); List<CountyEntity> countyListEntity = countyService.findCountyList(taskId);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(countyListEntity); yxjsonResponse.outPutSuccess(countyListEntity);
...@@ -364,10 +368,10 @@ public class UserApi { ...@@ -364,10 +368,10 @@ public class UserApi {
* *
* @return * @return
*/ */
@RequestMapping("getGroupListByTaskListId") @RequestMapping("getGroupListByTaskId")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getGroupListByTaskListId(@RequestParam("taskListId") String taskListId, HttpServletResponse resp) { public String getGroupListByTaskId(@RequestParam("taskId") String taskId, HttpServletResponse resp) {
List<GroupListEntity> groupNoEntity = groupListService.findGroupListByTaskListId(taskListId); List<GroupListEntity> groupNoEntity = groupListService.findGroupListByTaskId(taskId);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(groupNoEntity); yxjsonResponse.outPutSuccess(groupNoEntity);
...@@ -468,10 +472,10 @@ public class UserApi { ...@@ -468,10 +472,10 @@ public class UserApi {
* *
* @return * @return
*/ */
@RequestMapping("getStorageCountByTaskListId") @RequestMapping("getStorageCountByTaskId")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String getStorageCountByTaskListId(@RequestParam("taskListID") String taskListId, HttpServletResponse resp) { public String getStorageCountByTaskId(@RequestParam("taskId") String taskId, HttpServletResponse resp) {
List <CountyListEntity> countyListEntity=countyListService.findStorageCountByTaskListId(taskListId); List <CountyListEntity> countyListEntity=countyListService.findStorageCountByTaskId(taskId);
YXJSONResponse yxjsonResponse=new YXJSONResponse(); YXJSONResponse yxjsonResponse=new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(countyListEntity); yxjsonResponse.outPutSuccess(countyListEntity);
...@@ -503,66 +507,29 @@ public class UserApi { ...@@ -503,66 +507,29 @@ public class UserApi {
*/ */
@RequestMapping("addExceptionState") @RequestMapping("addExceptionState")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String addExceptionState(@RequestParam("exception_Information") String exception_Information, HttpServletResponse resp) { public String addExceptionState(@RequestParam("taskId") String taskId,@RequestParam("exceptionInformation") String exceptionInformation, HttpServletResponse resp) {
String map = "{\"task_Id\":\"20181016001\",\"exception_Information\":0} "; int i = taskService.addExceptionState(taskId,exceptionInformation);
JSONObject jsonObject = JSONObject.fromObject(map);
TaskEntity taskEntity = (TaskEntity) JSONObject.toBean(jsonObject, TaskEntity.class);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
int i = taskService.addExceptionState(taskEntity);
yxjsonResponse.outPutSuccess(i + "更新成功"); yxjsonResponse.outPutSuccess(i + "更新成功");
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
/** /**
* 对出入库数进行更改 * 对出入库数进行更改,并更新出入库时间
* *
* @return * @return
*/ */
@RequestMapping("reviseStorageCount") @RequestMapping("reviseStorageCount")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public String reviseStorageCount(@RequestParam("taskListId") String taskListId,@RequestParam("countyCode") String countyCode,@RequestParam("inStorageCount") String in_Storage_Count, @RequestParam("outStorageCount") String out_Storage_Count, HttpServletResponse resp) { public String reviseStorageCount(@RequestParam("taskId") String taskId,@RequestParam("countyCode") String countyCode,@RequestParam("inStorageCount") String inStorageCount, @RequestParam("outStorageCount") String outStorageCount, HttpServletResponse resp) {
int i=countyListService.reviseStorageCount(taskListId,countyCode, in_Storage_Count, out_Storage_Count); int i=countyListService.reviseStorageCount(taskId,countyCode, inStorageCount, outStorageCount);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(i+"--更新成功--"); yxjsonResponse.outPutSuccess(i+"--更新成功--");
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
// /**
// * 更新入库时间
// * 前端空值
// * @return
// */
// @RequestMapping("updateInStorageDate")
//// @RequiresPermissions("userInfo.add")//权限管理;
// public String updateInStorageDate(@RequestParam("taskListId") String taskListId,@RequestParam("inStorageCount") String inStorageCount,@RequestParam("outStorageCount") String outStorageCount, HttpServletResponse resp) {
// int i = taskService.updateStorageDate(taskListId,inStorageCount,outStorageCount);
// YXJSONResponse yxjsonResponse = new YXJSONResponse();
// resp.setCharacterEncoding("UTF-8");
// yxjsonResponse.outPutSuccess(i + "更新成功");
// return yxjsonResponse.toJSONString();
// }
// /**
// * 更新出库时间
// * @return
// */
// @RequestMapping("updateOutBoundDate")
//// @RequiresPermissions("userInfo.add")//权限管理;
// public String updateOutBoundDate(@RequestParam("id") String id, HttpServletResponse resp) {
// String map = "{\"id\":\"20181016001\",} ";
// JSONObject jsonObject = JSONObject.fromObject(map);
// Object outStorageCount = jsonObject.get("outStorageCount");
// Object putOutStorageDate = jsonObject.get("putOutStorageDate");
// TaskEntity taskEntity = (TaskEntity) putOutStorageDate;
// CountyListEntity countyListEntity = (CountyListEntity) outStorageCount;
// YXJSONResponse yxjsonResponse = new YXJSONResponse();
// resp.setCharacterEncoding("UTF-8");
// int i = taskService.updateOutBoundDate(taskEntity,countyListEntity);
// yxjsonResponse.outPutSuccess(i + "更新成功");
// return yxjsonResponse.toJSONString();
// }
/** /**
* 查询交接单; * 查询交接单;
...@@ -581,13 +548,133 @@ public class UserApi { ...@@ -581,13 +548,133 @@ public class UserApi {
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
/**
* 下载回执单
*/
@RequestMapping("printOfficialReceipt")
// @RequiresPermissions("userInfo.add")//权限管理;
public byte[] printOfficialReceipt(@RequestParam("startDate") String startDate, @RequestParam("endDate") String endDate, HttpServletResponse response) {
// cyclesheetID ="20180802032";
response.setContentType("application/x-download");
response.setCharacterEncoding("UTF-8");
String dateTime = DateFormatUtils.format(new Date(), "yyyyMMddHH");
// //使用Servlet实现文件下载的时候,避免浏览器自动打开文件
String fout = null;
List<ReceiptListEntity> receiptListEntity = receiptListService.getReceiptList(startDate,endDate);
fout = officialReceiptExcel(receiptListEntity, receiptListEntity.get(0).getXiaoJi() + "", 6000, receiptListEntity.get(0).getBoxCount(),receiptListEntity.get(0).getCountyName(), dateTime, startDate, endDate);
String outFile = dateTime + "身份证专递回执单";
try {
FileInputStream fis = new FileInputStream(new File(fout));
byte[] b = new byte[fis.available()];
fis.read(b);
fis.close();
response.addHeader("Content-Disposition", "attachment;filename=" + outFile + ".xls");
return b;
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
return null;
}
private String officialReceiptExcel( List<ReceiptListEntity> receiptListEntity, String typeName, int sum , long boxCount, String countyName, String dateTime, String startDate , String endDate) {
if(typeName.contains("null")){
typeName=typeName.replace("null", "");
}
//第一步创建workbook
HSSFWorkbook wb=new HSSFWorkbook();
SimpleDateFormat simpleDateFormat=new SimpleDateFormat("yyyy-MM-dd");
// HSSFSheet sheet=wb.createSheet("身份证专递回执单");
// sheet.setColumnWidth(0, 100 * 255);
for (ReceiptListEntity receiptList :receiptListEntity){
HSSFSheet sheet = wb.createSheet("回执单" + receiptList.getCountyName());
HSSFPrintSetup ps=sheet.getPrintSetup();
ps.setLandscape(true); // 打印方向,true:横向,false:纵向
ps.setPaperSize(HSSFPrintSetup.B5_PAPERSIZE); //纸张
sheet.setColumnWidth(0, (int) 100 * 255);
//第三步创建行row:添加表头0行
HSSFRow row=sheet.createRow(0);
// HSSFCellStyle style=wb.createCellStyle();//样式
// style.setVerticalAlignment(HSSFCellStyle.ALIGN_LEFT); //设置垂直居中
// style.setAlignment(HSSFCellStyle.ALIGN_LEFT);
// style.setWrapText(true);//设置自动换行
//
// style.setBorderBottom(HSSFCellStyle.BORDER_THIN); //下边框
// style.setBorderLeft(HSSFCellStyle.BORDER_THIN);//左边框
// style.setBorderTop(HSSFCellStyle.BORDER_THIN);//上边框
// style.setBorderRight(HSSFCellStyle.BORDER_THIN);//右边框
// HSSFFont font=wb.createFont();
// font.setFontHeightInPoints((short) 32);
// style.setFont(font);
HSSFCellStyle style2=wb.createCellStyle(); //表头样式
style2.setVerticalAlignment(HSSFCellStyle.VERTICAL_CENTER); //设置垂直居中
style2.setAlignment(HSSFCellStyle.ALIGN_CENTER);
HSSFFont font2=wb.createFont();
font2.setBoldweight(HSSFFont.BOLDWEIGHT_BOLD);//粗体显示
font2.setFontHeightInPoints((short) 36);
style2.setFont(font2);
HSSFCellStyle style3=wb.createCellStyle(); //表头样式
style3.setVerticalAlignment(HSSFCellStyle.ALIGN_RIGHT); //设置垂直靠右
style3.setAlignment(HSSFCellStyle.ALIGN_RIGHT);
HSSFFont font3=wb.createFont();
font3.setBoldweight(HSSFFont.BOLDWEIGHT_NORMAL);
font3.setFontHeightInPoints((short) 24);
style3.setFont(font3);
HSSFCellStyle style4=wb.createCellStyle(); //表头样式
style4.setVerticalAlignment(HSSFCellStyle.VERTICAL_CENTER); //设置垂直居中
style4.setAlignment(HSSFCellStyle.ALIGN_CENTER);
HSSFFont font4=wb.createFont();
font4.setBoldweight(HSSFFont.BOLDWEIGHT_NORMAL);//粗体显示
font4.setFontHeightInPoints((short) 18);
style4.setFont(font4);
// ReceiptListEntity receiptListEntity1=receiptListEntity.get(i);
row=sheet.createRow(0); //创建下标为0的单元格
row.setHeightInPoints(Short.parseShort("67"));//设置行高
HSSFCell cell=row.createCell(0); //设定值
cell.setCellValue("身份证专递回执单");
cell.setCellStyle(style2);
row=sheet.createRow(1);
row.setHeightInPoints(Short.parseShort("192"));//设置行高
cell=row.createCell(0);
cell.setCellValue(" " + receiptList.getCountyName() + "\\县于" + simpleDateFormat.format(new Date()) + "出库身份证\r\n普通证" + receiptList.getPTZ()+ "人,快证" + receiptList.getKZ() + "人,省内异地快速通\r\n道邮" + receiptList.getYDKSY() + "人,省内异地快速通道普" + receiptList.getYDKSP() + "人,省内\r\n异地邮" + receiptList.getYDY() + "人,省内异地普" + receiptList.getYDP() + "人,军人证" + receiptList.getJRZ() + "人,\r\n快速通道普" + receiptList.getKSP() + "人,快速通道邮" + receiptList.getKSY() + "人,邮寄证\r\n" + receiptList.getYJZ() + "人,国内异地证____人,共" + receiptList.getBoxCount() + "盒。(请核\r\n对签字后,使用传真发至0371-69179397;或交\r\n至本地速递局身份证项目经理寄回。)"); //设定值
cell.setCellStyle(style4); //内容居中
row=sheet.createRow(2);//i+2行之后开始创建
row.setHeightInPoints(Short.parseShort("50"));//设置行高
//创建单元格并且添加数据
cell=row.createCell(0);
cell.setCellValue("收件人签字:__________");
cell.setCellStyle(style3);
}
FileOutputStream fout = null;
try {
fout = new FileOutputStream("E:\\Excel\\" + simpleDateFormat.format(new Date())+ "身份证专递回执单" + ".xls");
// fout = new FileOutputStream("D:\\" + simpleDateFormat.format(new Date()) + list.get(0).getString("COUNTYNAME") + ".xls");
wb.write(fout);
fout.close();
} catch (IOException e) {
e.printStackTrace();
}
System.out.println("Excel文件生成成功..." + new Date());
return "E:\\Excel\\" + simpleDateFormat.format(new Date()) + "身份证专递回执单" + ".xls";
// return "D:\\" + simpleDateFormat.format(new Date()) + list.get(0).getString("COUNTYNAME") + ".xls";
}
/** /**
* 下载交接单 * 下载交接单
*/ */
@RequestMapping("printReceiptList") @RequestMapping("printReceiptList")
// @RequiresPermissions("userInfo.add")//权限管理; // @RequiresPermissions("userInfo.add")//权限管理;
public byte[] printConnectList(@RequestParam("startDate") String startDate, @RequestParam("endDate") String endDate, HttpServletResponse response) { public byte[] printReceiptList(@RequestParam("startDate") String startDate, @RequestParam("endDate") String endDate, HttpServletResponse response) {
// cyclesheetID ="20180802032"; // cyclesheetID ="20180802032";
response.setContentType("application/x-download"); response.setContentType("application/x-download");
response.setCharacterEncoding("UTF-8"); response.setCharacterEncoding("UTF-8");
......
package com.yxproject.start.api; package com.yxproject.start.api;
//import com.yxproject.start.service.FindCbCountByDealdateViewService; //import com.yxproject.start.service.FindCbCountByDealdateViewService;
import com.yxproject.start.service.CardBodyService; import com.yxproject.start.entity.FindStationCountByViewEntity;
import com.yxproject.start.service.FindFinancialReportByViewService; import com.yxproject.start.entity.SpecialCardEntity;
import com.yxproject.start.service.FindStationCountService; import com.yxproject.start.service.*;
import com.yxproject.start.service.FindTaskByDealdateViewService;
import com.yxproject.start.utils.YXJSONResponse; import com.yxproject.start.utils.YXJSONResponse;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
...@@ -31,6 +30,10 @@ public class YingxinApi { ...@@ -31,6 +30,10 @@ public class YingxinApi {
private FindStationCountService findStationCountService; private FindStationCountService findStationCountService;
@Autowired @Autowired
private FindFinancialReportByViewService findFinancialReportByViewService; private FindFinancialReportByViewService findFinancialReportByViewService;
@Autowired
private AddTuiZhengService addTuiZhengService;
@Autowired
private AddRemainingCardService addRemainingCardService;
/** /**
* 查询在受理库查询任务单详情 根据处理时间查询; * 查询在受理库查询任务单详情 根据处理时间查询;
* *
...@@ -71,7 +74,7 @@ public class YingxinApi { ...@@ -71,7 +74,7 @@ public class YingxinApi {
*/ */
@RequestMapping("getStateCountInfo") @RequestMapping("getStateCountInfo")
public String getStateCountInfo(@RequestParam("submitDate") String submitDate,@RequestParam("state") String state,HttpServletResponse resp){ public String getStateCountInfo(@RequestParam("submitDate") String submitDate,@RequestParam("state") String state,HttpServletResponse resp){
List<Map<String,Object>> list=findStationCountService.getStationCountData(submitDate,state); List<FindStationCountByViewEntity> list=findStationCountService.getStationCountData(submitDate,state);
YXJSONResponse yxjsonResponse = new YXJSONResponse(); YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(list); yxjsonResponse.outPutSuccess(list);
...@@ -93,5 +96,31 @@ public class YingxinApi { ...@@ -93,5 +96,31 @@ public class YingxinApi {
return yxjsonResponse.toJSONString(); return yxjsonResponse.toJSONString();
} }
/*
*添加退证
*
* */
@RequestMapping("addInValidCardInfo")
public String addTuiZhengInfo(@RequestParam("acceptNo")String acceptNumber,HttpServletResponse resp){
List<SpecialCardEntity> list=addTuiZhengService.getTuiZhengData(acceptNumber);
YXJSONResponse yxjsonResponse = new YXJSONResponse();
resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(list);
Map map = new HashMap();
return yxjsonResponse.toJSONString();
}
/*
*添加余证
*
* */
@RequestMapping("addRemainingCardInfo")
public String addRemainingCardInfo(@RequestParam("acceptNo")String accept_Number,HttpServletResponse resp){
List<SpecialCardEntity> list=addRemainingCardService.getRemainingCardData(accept_Number);
YXJSONResponse yxjsonResponse =new YXJSONResponse();
resp.setCharacterEncoding("UTF-8");
yxjsonResponse.outPutSuccess(list);
Map map=new HashMap();
return yxjsonResponse.toJSONString();
}
} }
...@@ -5,4 +5,6 @@ package com.yxproject.start.entity.accu; ...@@ -5,4 +5,6 @@ package com.yxproject.start.entity.accu;
*/ */
public class AccCardInfoEntity { public class AccCardInfoEntity {
} }
...@@ -16,10 +16,10 @@ import java.util.Map; ...@@ -16,10 +16,10 @@ import java.util.Map;
@Mapper @Mapper
public interface CountyListMapper { public interface CountyListMapper {
public List<CountyEntity> findCountyList(@Param("taskListId") String taskListId,@Param("taskStateId") String taskStateId,@Param("cardType") String cardType); public List<CountyEntity> findCountyList(String taskId);
public int reviseStorageCount( @Param("taskListId") String taskListId, @Param("countyCode") String countyCode,@Param("in_Storage_Count") String in_Storage_Count,@Param("out_Storage_Count") String out_Storage_Count); public int reviseStorageCount( @Param("taskId") String taskId, @Param("countyCode") String countyCode,@Param("inStorageCount") String inStorageCount,@Param("outStorageCount") String out_Storage_Count);
public List<ReceiptListEntity> getReceiptList( @Param("startDate")String startDate , @Param("endDate") String endDate); public List<ReceiptListEntity> getReceiptList( @Param("startDate")String startDate , @Param("endDate") String endDate);
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId); public List<CountyListEntity> findStorageCountByTaskId(String taskId);
public int totalFinshCount (); public int totalFinshCount ();
public int totalInStorageCount (); public int totalInStorageCount ();
public int totalOutStorageCount (); public int totalOutStorageCount ();
......
package com.yxproject.start.mapper; package com.yxproject.start.mapper;
import com.yxproject.start.entity.FindStationCountByViewEntity;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
...@@ -11,5 +12,5 @@ import java.util.Map; ...@@ -11,5 +12,5 @@ import java.util.Map;
*/ */
@Mapper @Mapper
public interface FindStationCountMapper { public interface FindStationCountMapper {
public List<Map<String,Object>>findStationCountByDealDate(@Param("submitDate") String submitDate,@Param("state") String state); public List<FindStationCountByViewEntity> findStationCountByDealDate(@Param("submitDate") String submitDate, @Param("state") String state);
} }
...@@ -20,7 +20,7 @@ public interface GroupNoMapper { ...@@ -20,7 +20,7 @@ public interface GroupNoMapper {
public int findGroupNoCountByTaskId(String task_Id); public int findGroupNoCountByTaskId(String task_Id);
public List<Map<String,Object>> findSpecialCountyList(String task_Id); public List<Map<String,Object>> findSpecialCountyList(String task_Id);
public List<Map<String,Object>> findNormalCountyList(String task_Id); public List<Map<String,Object>> findNormalCountyList(String task_Id);
public List<GroupListEntity> findGroupListByTaskListId( String taskListId); public List<GroupListEntity> findGroupListByTaskId( String taskId);
} }
...@@ -15,5 +15,6 @@ public interface SpecialCardMapper { ...@@ -15,5 +15,6 @@ public interface SpecialCardMapper {
public void updateSpecialCardEntity(SpecialCardEntity specialCardEntity); public void updateSpecialCardEntity(SpecialCardEntity specialCardEntity);
public List<SpecialCardEntity> findSpecialCardEntityByGroupNo(String groupNo); public List<SpecialCardEntity> findSpecialCardEntityByGroupNo(String groupNo);
public List <SpecialCardEntity> findSpecialCardList( String groupNo); public List <SpecialCardEntity> findSpecialCardList( String groupNo);
public List <SpecialCardEntity> addTuiZheng(String acceptNumber);
public List<SpecialCardEntity> addRemainingCard(String accept_Number);
} }
...@@ -17,7 +17,7 @@ public interface SysPermissionMapper{ ...@@ -17,7 +17,7 @@ public interface SysPermissionMapper{
* @param sysPermission * @param sysPermission
*/ */
@Insert("INSERT INTO sys_permission (id,available,name,parent_id,parent_ids,permission,resource_type,url)\n" + @Insert("INSERT INTO sys_permission (id,available,name,parent_id,parent_ids,permission,resource_type,url)\n" +
"VALUES (PERMISSION_seq.nextval,0,#{name},'0','0/',#{permission},#{resource_type},'')") "VALUES (PERMISSION_seq.nextval,0,#{name},'0','0/',#{permission},#{resource_type},#{url})")
public void addPermissionByMap(SysPermission sysPermission); public void addPermissionByMap(SysPermission sysPermission);
/** /**
......
...@@ -17,10 +17,11 @@ public interface TaskMapper { ...@@ -17,10 +17,11 @@ public interface TaskMapper {
public int updateTaskEntity(TaskEntity taskEntity); public int updateTaskEntity(TaskEntity taskEntity);
public List<TaskEntity> findTaskEntityByAcceptNo(String acceptNo); public List<TaskEntity> findTaskEntityByAcceptNo(String acceptNo);
public List<TaskEntity> findTaskEntityByState(int state); public List<TaskEntity> findTaskEntityByState(int state);
public int replaceExceptionInformation(TaskEntity taskEntity); public int updateTaskIsException(@Param("taskId") String taskId,@Param("exceptionInformation") String exceptionInformation,@Param("isException")String isException);
public int replaceExceptionInformation(@Param("taskId")String taskId,@Param("isException")String isException);
public List<TypeListEntity> findTypeListByTaskStateId(String taskStateId); public List<TypeListEntity> findTypeListByTaskStateId(String taskStateId);
public List <CityListEntity> findCityList(@Param("taskStateId") String taskStateId,@Param("cardType") String cardType); public List <CityListEntity> findCityList(@Param("taskStateId") String taskStateId,@Param("cardType") String cardType);
public int updateOutStorageDate(String taskListId); public int updateOutStorageDate(String taskId);
public int updateInStorageDate(String taskListId); public int updateInStorageDate(String taskId);
public int updateStorageDate(String taskListId); public int updateStorageDate(String taskId);
} }
package com.yxproject.start.service;
import com.yxproject.start.entity.SpecialCardEntity;
import java.util.List;
/**
* Created by Administrator on 2018/12/21.
*/
public interface AddRemainingCardService {
public List<SpecialCardEntity>getRemainingCardData(String accept_Number);
}
package com.yxproject.start.service;
import com.yxproject.start.entity.SpecialCardEntity;
import java.util.List;
/**
* Created by Administrator on 2018/12/20.
*/
public interface AddTuiZhengService {
public List<SpecialCardEntity>getTuiZhengData(String acceptNumber);
}
...@@ -8,6 +8,6 @@ import java.util.Map; ...@@ -8,6 +8,6 @@ import java.util.Map;
public interface CountyListService { public interface CountyListService {
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId); public List<CountyListEntity> findStorageCountByTaskId(String taskId);
public int reviseStorageCount(String taskListId,String countyCode, String in_Storage_Count, String out_Storage_Count); public int reviseStorageCount(String taskId,String countyCode, String inStorageCount, String outStorageCount);
} }
...@@ -8,7 +8,7 @@ import java.util.List; ...@@ -8,7 +8,7 @@ import java.util.List;
* Created by Administrator on 2018/12/19. * Created by Administrator on 2018/12/19.
*/ */
public interface CountyService { public interface CountyService {
public List<CountyEntity> findCountyList( String taskListId,String taskStateId,String cardType); public List<CountyEntity> findCountyList( String taskId);
} }
package com.yxproject.start.service; package com.yxproject.start.service;
import com.yxproject.start.entity.FindStationCountByViewEntity;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -7,5 +9,5 @@ import java.util.Map; ...@@ -7,5 +9,5 @@ import java.util.Map;
* Created by Administrator on 2018/11/29. * Created by Administrator on 2018/11/29.
*/ */
public interface FindStationCountService { public interface FindStationCountService {
public List<Map<String,Object>>getStationCountData(String submitDate,String state); public List<FindStationCountByViewEntity>getStationCountData(String submitDate, String state);
} }
...@@ -9,6 +9,6 @@ import java.util.List; ...@@ -9,6 +9,6 @@ import java.util.List;
*/ */
public interface GroupListService { public interface GroupListService {
public List<GroupListEntity> findGroupListByTaskListId( String taskListId); public List<GroupListEntity> findGroupListByTaskId( String taskId);
} }
...@@ -26,7 +26,7 @@ public interface TaskService { ...@@ -26,7 +26,7 @@ public interface TaskService {
public List<Map<String,Object>> findProductionTaskListEntityByState(int state); public List<Map<String,Object>> findProductionTaskListEntityByState(int state);
public int addExceptionState(TaskEntity state); public int addExceptionState(String taskId, String exceptionInformation);
// public int updateStorageDate(String taskListId,String inStorageCount,String outStorageCount); // public int updateStorageDate(String taskListId,String inStorageCount,String outStorageCount);
......
package com.yxproject.start.service.impl;
import com.yxproject.start.entity.SpecialCardEntity;
import com.yxproject.start.mapper.SpecialCardMapper;
import com.yxproject.start.service.AddRemainingCardService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* Created by Administrator on 2018/12/21.
*/
@Service
public class AddRemainingCardServiceImpl implements AddRemainingCardService{
@Autowired
private SpecialCardMapper specialCardMapper;
@Override
public List<SpecialCardEntity>getRemainingCardData(String accept_number){
List<SpecialCardEntity>List=specialCardMapper.addRemainingCard(accept_number);
return List;
}
}
package com.yxproject.start.service.impl;
import com.yxproject.start.entity.SpecialCardEntity;
import com.yxproject.start.mapper.SpecialCardMapper;
import com.yxproject.start.service.AddTuiZhengService;
import org.omg.CORBA.Object;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;
/**
* Created by Administrator on 2018/12/20.
*/
@Service
public class AddTuiZhengServiceImpl implements AddTuiZhengService {
@Autowired
private SpecialCardMapper specialCardMapper;
@Override
public List<SpecialCardEntity>getTuiZhengData(String acceptNumber){
List<SpecialCardEntity>List=specialCardMapper.addTuiZheng(acceptNumber);
return List;
}
}
...@@ -24,7 +24,7 @@ public class CountyListServiceImpl implements CountyListService { ...@@ -24,7 +24,7 @@ public class CountyListServiceImpl implements CountyListService {
public TaskMapper taskMapper; public TaskMapper taskMapper;
@Override @Override
public int reviseStorageCount(String taskListId,String countyCode, String in_Storage_Count, String out_Storage_Count) { public int reviseStorageCount(String taskId,String countyCode, String inStorageCount, String outStorageCount) {
int i = 0; int i = 0;
int totalFinshCount = 0; int totalFinshCount = 0;
int totalInStorageCount = 0; int totalInStorageCount = 0;
...@@ -32,22 +32,22 @@ public class CountyListServiceImpl implements CountyListService { ...@@ -32,22 +32,22 @@ public class CountyListServiceImpl implements CountyListService {
totalFinshCount = countyListMapper.totalFinshCount(); totalFinshCount = countyListMapper.totalFinshCount();
totalInStorageCount = countyListMapper.totalInStorageCount(); totalInStorageCount = countyListMapper.totalInStorageCount();
totalOutStorageCount = countyListMapper.totalOutStorageCount(); totalOutStorageCount = countyListMapper.totalOutStorageCount();
i = countyListMapper.reviseStorageCount(taskListId, countyCode, in_Storage_Count, out_Storage_Count); i = countyListMapper.reviseStorageCount(taskId, countyCode, inStorageCount, outStorageCount);
if(totalInStorageCount == totalFinshCount){ if(totalInStorageCount == totalFinshCount){
taskMapper.updateInStorageDate(taskListId); taskMapper.updateInStorageDate(taskId);
} }
if(totalOutStorageCount == totalFinshCount){ if(totalOutStorageCount == totalFinshCount){
taskMapper.updateOutStorageDate(taskListId); taskMapper.updateOutStorageDate(taskId);
} }
if(totalInStorageCount == totalFinshCount && totalOutStorageCount == totalFinshCount){ if(totalInStorageCount == totalFinshCount && totalOutStorageCount == totalFinshCount){
taskMapper.updateStorageDate(taskListId); taskMapper.updateStorageDate(taskId);
} }
return i; return i;
} }
@Override @Override
public List<CountyListEntity> findStorageCountByTaskListId(String taskListId){ public List<CountyListEntity> findStorageCountByTaskId(String taskId){
return countyListMapper.findStorageCountByTaskListId(taskListId); return countyListMapper.findStorageCountByTaskId(taskId);
} }
......
...@@ -20,8 +20,8 @@ public class CountyServiceImpl implements CountyService { ...@@ -20,8 +20,8 @@ public class CountyServiceImpl implements CountyService {
public CountyListMapper countyListMapper; public CountyListMapper countyListMapper;
@Override @Override
public List <CountyEntity> findCountyList( String taskListId, String taskStateId, String cardType ) { public List <CountyEntity> findCountyList( String taskId ) {
List<CountyEntity> county = countyListMapper.findCountyList(taskListId,taskStateId,cardType); List<CountyEntity> county = countyListMapper.findCountyList(taskId);
return county; return county;
} }
......
package com.yxproject.start.service.impl; package com.yxproject.start.service.impl;
import com.yxproject.start.entity.FindStationCountByViewEntity;
import com.yxproject.start.mapper.FindStationCountMapper; import com.yxproject.start.mapper.FindStationCountMapper;
import com.yxproject.start.mapper.TaskMapper;
import com.yxproject.start.service.FindStationCountService; import com.yxproject.start.service.FindStationCountService;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -15,10 +17,13 @@ import java.util.Map; ...@@ -15,10 +17,13 @@ import java.util.Map;
public class FindStationCountServiceImpl implements FindStationCountService { public class FindStationCountServiceImpl implements FindStationCountService {
@Autowired @Autowired
private FindStationCountMapper findStationCountMapper; private FindStationCountMapper findStationCountMapper;
@Autowired
private TaskMapper taskMapper;
@Override @Override
public List<Map<String,Object>>getStationCountData(String submitDate,String state) { public List<FindStationCountByViewEntity>getStationCountData(String submitDate,String state) {
List<Map<String,Object>> list=findStationCountMapper.findStationCountByDealDate(submitDate,state); List<FindStationCountByViewEntity> list = findStationCountMapper.findStationCountByDealDate(submitDate, state);
// List<Map<String, Object>> list = taskMapper.findStationCountByDealDate(submitDate, state);
return list; return list;
} }
......
...@@ -22,8 +22,8 @@ public class GroupListServiceImpl implements GroupListService { ...@@ -22,8 +22,8 @@ public class GroupListServiceImpl implements GroupListService {
public SpecialCardMapper specialCardMapper; public SpecialCardMapper specialCardMapper;
@Override @Override
public List<GroupListEntity> findGroupListByTaskListId( String taskListId) { public List<GroupListEntity> findGroupListByTaskId( String taskId) {
List <GroupListEntity> groupList=groupNoMapper.findGroupListByTaskListId(taskListId); List <GroupListEntity> groupList=groupNoMapper.findGroupListByTaskId(taskId);
for ( GroupListEntity groupListEntity:groupList) { for ( GroupListEntity groupListEntity:groupList) {
List <SpecialCardEntity> specialCardEntities=specialCardMapper.findSpecialCardList(groupListEntity.getGroupNo()+""); List <SpecialCardEntity> specialCardEntities=specialCardMapper.findSpecialCardList(groupListEntity.getGroupNo()+"");
groupListEntity.setSpecialCardList(specialCardEntities); groupListEntity.setSpecialCardList(specialCardEntities);
......
...@@ -420,15 +420,16 @@ public class TaskServiceImpl implements TaskService { ...@@ -420,15 +420,16 @@ public class TaskServiceImpl implements TaskService {
* @return * @return
*/ */
@Override @Override
public int addExceptionState(TaskEntity taskEntity) { public int addExceptionState(String taskId, String exceptionInformation) {
int i =0; int i =0;
if(taskEntity.getException_Information()!=null) { String isException;
taskEntity.setIs_Exception((long)1); if(Integer.parseInt(exceptionInformation) != 0) {
i=taskMapper.updateTaskEntity(taskEntity); isException =String.valueOf(1);
i=taskMapper.updateTaskIsException(taskId,exceptionInformation,isException);
} else { } else {
taskEntity.setIs_Exception((long)0); isException =String.valueOf(0);
i=taskMapper.replaceExceptionInformation(taskEntity); i=taskMapper.replaceExceptionInformation(taskId,isException);
} }
return i; return i;
} }
......
...@@ -7,6 +7,11 @@ mybatis: ...@@ -7,6 +7,11 @@ mybatis:
#加载Mybatis配置文件 #加载Mybatis配置文件
mapper-locations: classpath:mapper/*Mapper.xml mapper-locations: classpath:mapper/*Mapper.xml
config-location: classpath:mapper/config/mybatis-config.xml config-location: classpath:mapper/config/mybatis-config.xml
#logging.level.*=DEBUG
#logging:
# level:
# com.yx_project.start.mapper.*: debug
# logging.level.com.hz.controller=WARN #控制器层
#配置调度生产Oracle数据库 #配置调度生产Oracle数据库
spring: spring:
...@@ -16,6 +21,7 @@ spring: ...@@ -16,6 +21,7 @@ spring:
username: dahai username: dahai
password: dahai password: dahai
#配置shiro #配置shiro
shiro: shiro:
loginUrl: http://localhost:8081 loginUrl: http://localhost:8081
......
log4j.rootCategory=DEBUG,stdout,DebugAppender,InfoAppender,ErrorAppender
log4j.debug=true log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=[QC] %p [%t] %C.%M(%L) | %m%n
#logger input file log4j.logger.DebugAppender.access=DEBUG
log4j.appender.DebugAppender=org.apache.log4j.DailyRollingFileAppender
log4j.appender.DebugAppender.File=../logs/a.log
log4j.appender.DebugAppender.layout=org.apache.log4j.PatternLayout
log4j.appender.DebugAppender.layout.ConversionPattern=%d-[TS] %p %t %c - %m%n
#logger input file log4j.logger.InfoAppender.access=INFO
log4j.appender.InfoAppender=org.apache.log4j.DailyRollingFileAppender
log4j.appender.InfoAppender.File=../logs/b.log
log4j.appender.InfoAppender.layout=org.apache.log4j.PatternLayout
log4j.appender.InfoAppender.layout.ConversionPattern=%d-[TS] %p %t %c - %m%n
#error log input file log4j.logger.ErrorAppender.access=ERROR
log4j.appender.ErrorAppender=org.apache.log4j.DailyRollingFileAppender
log4j.appender.ErrorAppender.File=../logs/c.log
log4j.appender.ErrorAppender.Append = true
log4j.appender.ErrorAppender.threshold = ERROR
log4j.appender.ErrorAppender.layout=org.apache.log4j.PatternLayout
log4j.appender.ErrorAppender.layout.ConversionPattern=%d{MM-dd HH:mm:ss.SSS} %c %-5p - %m%n
\ No newline at end of file
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
SELECT COUNTY_LIST.COUNTY_CODE,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,COUNTY_DIC.COUNTYNAME FROM COUNTY_LIST SELECT COUNTY_LIST.COUNTY_CODE,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,COUNTY_DIC.COUNTYNAME FROM COUNTY_LIST
LEFT JOIN TASK ON COUNTY_LIST.TASK_ID = TASK.TASK_ID LEFT JOIN TASK ON COUNTY_LIST.TASK_ID = TASK.TASK_ID
LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE
WHERE TASK.TASK_ID=#{taskListId} AND TASK.CARD_TYPE=#{cardType} AND TASK.TASK_STATE_ID=#{taskStateId} WHERE TASK.TASK_ID=#{taskId}
</select> </select>
<select id="getReceiptList" resultType="com.yxproject.start.entity.ReceiptListEntity" parameterType="String"> <select id="getReceiptList" resultType="com.yxproject.start.entity.ReceiptListEntity" parameterType="String">
...@@ -42,32 +42,32 @@ ...@@ -42,32 +42,32 @@
SELECT COUNTYNAME,SUM(TYPE_COUNT) AS XIAOJI FROM t_county GROUP BY COUNTYNAME SELECT COUNTYNAME,SUM(TYPE_COUNT) AS XIAOJI FROM t_county GROUP BY COUNTYNAME
) )
SELECT DECODE(GROUPING(t_total_count.COUNTYNAME),1,'总计',t_total_count.COUNTYNAME)COUNTYNAME, SELECT DECODE(GROUPING(t_total_count.COUNTYNAME),1,'总计',t_total_count.COUNTYNAME)COUNTYNAME,
SUM(PTZ)PTZ, nvl(SUM(PTZ),0)AS PTZ ,
SUM(KZ)KZ, nvl(SUM(KZ),0)AS KZ,
SUM(YDKSY)YDKSY, nvl(SUM(YDKSY),0) AS YDKSY,
SUM(YDKSP)YDKSP, nvl(SUM(YDKSP),0)AS YDKSP,
SUM(YDY)YDY, nvl(SUM(YDY),0)AS YDY,
SUM(YDP)YDP, nvl(SUM(YDP),0)AS YDP,
SUM(JRZ)JRZ, nvl(SUM(JRZ),0)AS JRZ,
SUM(KSP)KSP, nvl(SUM(KSP),0)AS KSP,
SUM(KSY)KSY, nvl(SUM(KSY),0)AS KSY,
SUM(YJZ)YJZ, nvl(SUM(YJZ),0)AS YJZ,
SUM(XIAOJI)XIAOJI, SUM(XIAOJI)XIAOJI,
SUM(boxCount)boxCount SUM(boxCount)boxCount
FROM t_total_count,county_xiaoji WHERE t_total_count.COUNTYNAME=county_xiaoji.COUNTYNAME AND substr(TO_CHAR(SAVE_DATE,'yyyyMMdd'),0,8) >= #{startDate} AND #{endDate} >= substr(TO_CHAR(SAVE_DATE,'yyyyMMdd'),0,8) FROM t_total_count,county_xiaoji WHERE t_total_count.COUNTYNAME=county_xiaoji.COUNTYNAME AND substr(TO_CHAR(SAVE_DATE,'yyyyMMdd'),0,8) >= #{startDate} AND #{endDate} >= substr(TO_CHAR(SAVE_DATE,'yyyyMMdd'),0,8)
GROUP BY ROLLUP(t_total_count.COUNTYNAME) GROUP BY ROLLUP(t_total_count.COUNTYNAME)
</select> </select>
<select id="findStorageCountByTaskListId" resultType="java.util.HashMap" parameterType="String"> <select id="findStorageCountByTaskId" resultType="java.util.HashMap" parameterType="String">
SELECT TASK_ID,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,CITY_DIC.CITYNAME||' '||COUNTY_DIC.COUNTYNAME,COUNTY_DIC.COUNTY_CODE FROM COUNTY_LIST SELECT TASK_ID,FINISH_COUNT,IN_STORAGE_COUNT,OUT_STORAGE_COUNT,CITY_DIC.CITYNAME||' '||COUNTY_DIC.COUNTYNAME,COUNTY_DIC.COUNTY_CODE FROM COUNTY_LIST
LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE LEFT JOIN COUNTY_DIC ON COUNTY_LIST.COUNTY_CODE = COUNTY_DIC.COUNTY_CODE
LEFT JOIN CITY_DIC ON substr(CITY_DIC.CITYCODE,1,4) = substr(COUNTY_LIST.COUNTY_CODE,1,4) LEFT JOIN CITY_DIC ON substr(CITY_DIC.CITYCODE,1,4) = substr(COUNTY_LIST.COUNTY_CODE,1,4)
WHERE TASK_ID=#{task_Id} WHERE TASK_ID=#{taskId}
</select> </select>
<insert id="reviseStorageCount" parameterType="String" > <insert id="reviseStorageCount" parameterType="String" >
INSERT INTO COUNTY_LIST (TASK_ID,COUNTY_CODE,IN_STORAGE_COUNT,OUT_STORAGE_COUNT) VALUES ( #{taskListId},#{countyCode},#{in_Storage_Count},#{out_Storage_Count} ) INSERT INTO COUNTY_LIST (TASK_ID,COUNTY_CODE,IN_STORAGE_COUNT,OUT_STORAGE_COUNT) VALUES ( #{taskId},#{countyCode},#{inStorageCount},#{outStorageCount} )
</insert> </insert>
<select id="totalFinshCount" resultType="Integer"> <select id="totalFinshCount" resultType="Integer">
......
...@@ -15,7 +15,8 @@ ...@@ -15,7 +15,8 @@
<result column="APPLY_COUNT" property="applyCount" jdbcType="NUMERIC"/> <result column="APPLY_COUNT" property="applyCount" jdbcType="NUMERIC"/>
</resultMap> </resultMap>
<select id="findStationCountByDealDate" resultType="java.util.HashMap" parameterType="String"> <select id="findStationCountByDealDate" resultType="com.yxproject.start.entity.FindStationCountByViewEntity"
parameterType="String">
SELECT * FROM FIND_STATE_COUNT_VIEW WHERE FIND_STATE_COUNT_LIST.SET_SUBMITDATE_PARAM(#{submitDate})=#{submitDate} AND FIND_STATE_COUNT_LIST.SET_STATE_PARAM(#{state})=#{state} SELECT * FROM FIND_STATE_COUNT_VIEW WHERE FIND_STATE_COUNT_LIST.SET_SUBMITDATE_PARAM(#{submitDate})=#{submitDate} AND FIND_STATE_COUNT_LIST.SET_STATE_PARAM(#{state})=#{state}
</select> </select>
......
...@@ -43,10 +43,10 @@ ...@@ -43,10 +43,10 @@
SELECT * FROM TABLE(find_normal_county_list.GET_county_infos(#{task_Id})) SELECT * FROM TABLE(find_normal_county_list.GET_county_infos(#{task_Id}))
</select> </select>
<select id="findGroupListByTaskListId" resultType="com.yxproject.start.entity.GroupListEntity" parameterType="String"> <select id="findGroupListByTaskId" resultType="com.yxproject.start.entity.GroupListEntity" parameterType="String">
select GROUP_NO as groupNo,sum(VALID_COUNT) as validCount,sum(INVALID_COUNT) as invalidCount,sum(SPECIAL_CARD_COUNT) as specialCardCount from (select sum(VALID_COUNT),sum(INVALID_COUNT),sum(SPECIAL_CARD_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO select GROUP_NO as groupNo,sum(VALID_COUNT) as validCount,sum(INVALID_COUNT) as invalidCount,sum(SPECIAL_CARD_COUNT) as specialCardCount from (select sum(VALID_COUNT),sum(INVALID_COUNT),sum(SPECIAL_CARD_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO
left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID
where TASK.TASK_ID=#{task_Id} where TASK.TASK_ID=#{taskId}
group by GROUP_NO group by GROUP_NO
</select> </select>
......
...@@ -34,4 +34,11 @@ ...@@ -34,4 +34,11 @@
SELECT * FROM SPECIAL_CARD LEFT JOIN GROUP_NO ON GROUP_NO.GROUP_NO = SPECIAL_CARD.GROUP_NO WHERE GROUP_NO.GROUP_NO=#{group_No} SELECT * FROM SPECIAL_CARD LEFT JOIN GROUP_NO ON GROUP_NO.GROUP_NO = SPECIAL_CARD.GROUP_NO WHERE GROUP_NO.GROUP_NO=#{group_No}
</select> </select>
<select id="addTuiZheng" resultType="com.yxproject.start.entity.SpecialCardEntity" parameterType="String">
INSERT INTO SPECIAL_CARD (ACCEPT_NO, TASK_ID, SPECIAL_TYPE,GROUP_NO) VALUES (#{acceptNumber},(SELECT TASK_ID FROM GROUP_NO WHERE GROUP_NO.GROUP_NO=SUBSTR(#{acceptNumber},1,8)),2,SUBSTR(#{acceptNumber},1,8))
</select>
<select id="addRemainingCard" resultType="com.yxproject.start.entity.SpecialCardEntity" parameterType="String">
INSERT INTO SPECIAL_CARD (ACCEPT_NO, TASK_ID, SPECIAL_TYPE,GROUP_NO) VALUES (#{accept_Number},(SELECT TASK_ID FROM GROUP_NO WHERE GROUP_NO.GROUP_NO=SUBSTR(#{accept_Number},1,8)),0,SUBSTR(#{accept_Number},1,8))
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -68,20 +68,24 @@ ...@@ -68,20 +68,24 @@
select * from TASK where TASK_STATE_ID =#{task_State_Id} select * from TASK where TASK_STATE_ID =#{task_State_Id}
</select> </select>
<update id="replaceExceptionInformation" parameterType="com.yxproject.start.entity.TaskEntity" > <update id="updateTaskIsException" parameterType="String" >
update TASK set exception_Information = NULL and IS_EXCEPTION =#{is_Exception} where TASK_ID =#{task_Id} update TASK set EXCEPTION_INFORMATION = #{exceptionInformation},IS_EXCEPTION = #{isException} where TASK_ID =#{taskId}
</update>
<update id="replaceExceptionInformation" parameterType="String" >
update TASK set EXCEPTION_INFORMATION = NULL,IS_EXCEPTION = #{isException} where TASK_ID =#{taskId}
</update> </update>
<update id="updateOutStorageDate"> <update id="updateOutStorageDate">
UPDATE TASK SET OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<update id="updateInStorageDate" > <update id="updateInStorageDate" >
UPDATE TASK SET IN_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET IN_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<update id="updateStorageDate" > <update id="updateStorageDate" >
UPDATE TASK SET IN_STORAGE_DATE = SYSDATE , OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskListId} UPDATE TASK SET IN_STORAGE_DATE = SYSDATE , OUT_STORAGE_DATE = SYSDATE WHERE TASK_ID = #{taskId}
</update> </update>
<select id="findTypeListByTaskStateId" resultType="com.yxproject.start.entity.TypeListEntity" parameterType="String"> <select id="findTypeListByTaskStateId" resultType="com.yxproject.start.entity.TypeListEntity" parameterType="String">
...@@ -92,11 +96,17 @@ ...@@ -92,11 +96,17 @@
</select> </select>
<select id="findCityList" resultType="com.yxproject.start.entity.CityListEntity"> <select id="findCityList" resultType="com.yxproject.start.entity.CityListEntity">
SELECT CARD_TYPE,TASK.CITYCODE,CITYNAME AS cityName,sum(VALID_COUNT) AS validCount,sum(INVALID_COUNT) AS invalidCount,COUNT(GROUP_NO) AS groupCount,GROUP_NO AS groupNo,TASK.TASK_ID,OLD_CARD_TYPE,SUBMIT_DATE,ISSUED_DATE,PRINT_STATE,DOWNLOAD_DATE,PRINT_OUT_DATE,POSITION_DATE,OUT_WORKSHOP_DATE,QUALITY_PEOPLE_NAME,QUALITY_TEST_DATE,EXCEPTION_INFORMATION,OUT_STORAGE_DATE,IN_STORAGE_DATE,TASK_STATE_ID,IS_EXCEPTION,PRINTER_ID from (select sum(VALID_COUNT),sum(INVALID_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO SELECT CARD_TYPE AS cardType,TASK.CITYCODE AS citycode,CITYNAME AS cityName,sum(VALID_COUNT) AS validCount,sum(INVALID_COUNT) AS invalidCount,COUNT(GROUP_NO) AS groupCount,GROUP_NO AS groupNo,TASK.TASK_ID AS taskId,OLD_CARD_TYPE AS oldCardType,SUBMIT_DATE AS submitDate,ISSUED_DATE AS issuedDate,PRINT_STATE AS printState,DOWNLOAD_DATE AS downloadDate,PRINT_OUT_DATE AS printOutDate,POSITION_DATE AS positionDate,OUT_WORKSHOP_DATE AS outWorkshopDate,QUALITY_PEOPLE_NAME AS qualityPeopleName,QUALITY_TEST_DATE AS qualityTestDate,EXCEPTION_INFORMATION AS exceptionInformation,OUT_STORAGE_DATE AS outStorageDate,IN_STORAGE_DATE AS inStorageDate,TASK_STATE_ID AS taskStateId,IS_EXCEPTION AS isException,PRINTER_ID AS printerId
from (select sum(VALID_COUNT),sum(INVALID_COUNT),COUNT(GROUP_NO),TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT from GROUP_NO group by TASK_ID,GROUP_NO,SPECIAL_CARD_COUNT,VALID_COUNT,INVALID_COUNT ) GROUP_NO
left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID left join TASK on GROUP_NO.TASK_ID = TASK.TASK_ID
left join (SELECT CITYCODE,CITYNAME FROM CITY_DIC) CITY_DIC on CITY_DIC.CITYCODE = TASK.CITYCODE left join (SELECT CITYCODE,CITYNAME FROM CITY_DIC) CITY_DIC on CITY_DIC.CITYCODE = TASK.CITYCODE
where CARD_TYPE=#{cardType} and TASK_STATE_ID = #{taskStateId} where CARD_TYPE=#{cardType} and TASK_STATE_ID = #{taskStateId}
GROUP BY CARD_TYPE,TASK.CITYCODE,CITYNAME,GROUP_NO,TASK.TASK_ID,OLD_CARD_TYPE,SUBMIT_DATE,ISSUED_DATE,PRINT_STATE,DOWNLOAD_DATE,PRINT_OUT_DATE,POSITION_DATE,OUT_WORKSHOP_DATE,QUALITY_PEOPLE_NAME,QUALITY_TEST_DATE,EXCEPTION_INFORMATION,OUT_STORAGE_DATE,IN_STORAGE_DATE,TASK_STATE_ID,IS_EXCEPTION,PRINTER_ID GROUP BY CARD_TYPE,TASK.CITYCODE,CITYNAME,GROUP_NO,TASK.TASK_ID,OLD_CARD_TYPE,SUBMIT_DATE,ISSUED_DATE,PRINT_STATE,DOWNLOAD_DATE,PRINT_OUT_DATE,POSITION_DATE,OUT_WORKSHOP_DATE,QUALITY_PEOPLE_NAME,QUALITY_TEST_DATE,EXCEPTION_INFORMATION,OUT_STORAGE_DATE,IN_STORAGE_DATE,TASK_STATE_ID,IS_EXCEPTION,PRINTER_ID
</select> </select>
<select id="findStationCountByDealDate" resultType="java.util.HashMap" parameterType="String">
SELECT * FROM FIND_STATE_COUNT_VIEW WHERE FIND_STATE_COUNT_LIST.SET_SUBMITDATE_PARAM(#{submitDate})=#{submitDate} AND FIND_STATE_COUNT_LIST.SET_STATE_PARAM(#{state})=#{state}
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -19,4 +19,10 @@ PUBLIC "-//mybatis.org//DTD Config 3.0//EN" ...@@ -19,4 +19,10 @@ PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
<!--</plugin>--> <!--</plugin>-->
<!--</plugins>--> <!--</plugins>-->
<!--<settings>-->
<!--<setting name="log4jImpl" value="LOG4J"/>-->
<!--</settings>-->
</configuration> </configuration>
\ No newline at end of file
...@@ -12,10 +12,10 @@ ...@@ -12,10 +12,10 @@
</thead> </thead>
<tbody> <tbody>
<tr ng-repeat="specialCard in specialCardList"> <tr ng-repeat="specialCard in specialCardList">
<td>{{specialCard.acceptNo}}</td> <td>{{specialCard.accept_No}}</td>
<td ng-if="specialCard.specialType==0">余证</td> <td ng-if="specialCard.special_Type==0">余证</td>
<td ng-if="specialCard.specialType==1">快证</td> <td ng-if="specialCard.special_Type==1">快证</td>
<td ng-if="specialCard.specialType==2">退证</td> <td ng-if="specialCard.special_Type==2">退证</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
......
...@@ -7,6 +7,10 @@ ...@@ -7,6 +7,10 @@
<label>名称</label> <label>名称</label>
<input type="text" class="form-control" ng-model="thisPerm.name" ng-value="thisPerm.name" required> <input type="text" class="form-control" ng-model="thisPerm.name" ng-value="thisPerm.name" required>
</div> </div>
<div class="form-group">
<label>路径</label>
<input type="text" class="form-control" ng-model="thisPerm.url" ng-value="thisPerm.url" required >
</div>
<div class="form-group"> <div class="form-group">
<label>权限字符串</label> <label>权限字符串</label>
<input type="text" class="form-control" ng-model="thisPerm.permission" ng-value="thisPerm.permission" <input type="text" class="form-control" ng-model="thisPerm.permission" ng-value="thisPerm.permission"
......
...@@ -14,11 +14,11 @@ ...@@ -14,11 +14,11 @@
<div class="form-group pull-in clearfix" ng-if="thisUser.username!='admin'"> <div class="form-group pull-in clearfix" ng-if="thisUser.username!='admin'">
<div class="col-sm-6"> <div class="col-sm-6">
<label>角色</label> <label>角色</label>
<select class="form-control w-md" ng-model="roleId" ng-options="role.id as role.role for role in activeRoleList"></select> <select class="form-control w-md" ng-model="thisUser.roleId" ng-options="role.id as role.role for role in activeRoleList"></select>
</div> </div>
</div> </div>
</form> </form>
</div> </div>
<div class="ui-dialog-confirm"> <div class="ui-dialog-confirm">
<button type="submit" class="btn btn-info" ng-click="userUpdate(roleId)&&closeThisDialog()">确认修改</button> <button type="submit" class="btn btn-info" ng-click="userUpdate()&&closeThisDialog()">确认修改</button>
</div> </div>
\ No newline at end of file
...@@ -381,12 +381,13 @@ app.service('MessageService', function (ngDialog) { ...@@ -381,12 +381,13 @@ app.service('MessageService', function (ngDialog) {
MessageService.httpRequestFailed(JSON.stringify(errA)) MessageService.httpRequestFailed(JSON.stringify(errA))
}) })
}, },
getTypeListByTaskStateId:function(state,success){ getTypeListByTaskStateId:function(userState,success){
console.log('----测试查询代码----',userState)
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getTypeListByTaskStateId" + urlTimeStamp(), url: "../user/getTypeListByTaskStateId" + urlTimeStamp(),
params:{ params:{
taskStateId:state taskStateId:userState
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
success(response.data) success(response.data)
...@@ -398,9 +399,9 @@ app.service('MessageService', function (ngDialog) { ...@@ -398,9 +399,9 @@ app.service('MessageService', function (ngDialog) {
getCityListByCardType:function(cardType,state,success){ getCityListByCardType:function(cardType,state,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getCityListByCardType" + urlTimeStamp(), url: "../user/getCityList" + urlTimeStamp(),
params:{ params:{
state:state, taskStateId:state,
cardType:cardType cardType:cardType
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
...@@ -413,9 +414,9 @@ app.service('MessageService', function (ngDialog) { ...@@ -413,9 +414,9 @@ app.service('MessageService', function (ngDialog) {
getGroupNoByTaskListId:function(taskStateId,success){ getGroupNoByTaskListId:function(taskStateId,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getGroupNoByTaskListId" + urlTimeStamp(), url: "../user/getGroupListByTaskId" + urlTimeStamp(),
params:{ params:{
taskStateId:taskStateId taskId:taskStateId
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
success(response.data) success(response.data)
...@@ -427,9 +428,9 @@ app.service('MessageService', function (ngDialog) { ...@@ -427,9 +428,9 @@ app.service('MessageService', function (ngDialog) {
getCountyListByTaskListId:function(taskStateId,success){ getCountyListByTaskListId:function(taskStateId,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getCountyListByTaskListId" + urlTimeStamp(), url: "../user/getCountyList" + urlTimeStamp(),
params:{ params:{
taskStateId:taskStateId taskId:taskStateId
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
success(response.data) success(response.data)
...@@ -441,7 +442,7 @@ app.service('MessageService', function (ngDialog) { ...@@ -441,7 +442,7 @@ app.service('MessageService', function (ngDialog) {
updateProductionTask:function(taskId,state,success){ updateProductionTask:function(taskId,state,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/updateProductionTask" + urlTimeStamp(), url: "../user/updateTaskState" + urlTimeStamp(),
params:{ params:{
taskId:taskId, taskId:taskId,
state:state state:state
...@@ -471,12 +472,13 @@ app.service('MessageService', function (ngDialog) { ...@@ -471,12 +472,13 @@ app.service('MessageService', function (ngDialog) {
getReceiptData:function(startTime, endTime,success){ getReceiptData:function(startTime, endTime,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getConnectList" + urlTimeStamp(), url: "../user/getReceiptList" + urlTimeStamp(),
params:{ params:{
startTime:startTime, startDate:startTime,
endTime:endTime endDate:endTime
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
console.log(response.data,"-------------response.data------")
success(response.data) success(response.data)
},function(err){ },function(err){
var errA = {Error:true, ReturnCode:err.status, ReturnMsg:"API访问返回错误"} var errA = {Error:true, ReturnCode:err.status, ReturnMsg:"API访问返回错误"}
...@@ -486,10 +488,10 @@ app.service('MessageService', function (ngDialog) { ...@@ -486,10 +488,10 @@ app.service('MessageService', function (ngDialog) {
getprintReceipt:function(startTime, endTime,success){ getprintReceipt:function(startTime, endTime,success){
$http({ $http({
method: 'GET', method: 'GET',
url: "../user/getConnectList" + urlTimeStamp(), url: "../user/printReceiptList" + urlTimeStamp(),
params:{ params:{
startTime:startTime, startDate:startTime,
endTime:endTime endDate:endTime
} }
}).then(function successCallback(response) { }).then(function successCallback(response) {
success(response.data) success(response.data)
......
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
</thead> </thead>
<tbody ng-repeat="city in cityList| orderBy:citycode:desc"> <tbody ng-repeat="city in cityList| orderBy:citycode:desc">
<tr> <tr>
<td>{{city.task_Id}}</td> <td>{{city.taskId}}</td>
<td><span class="city" <td><span class="city"
style="color: #337ab7;display:inline-block">{{city.cityName}}</span></td> style="color: #337ab7;display:inline-block">{{city.cityName}}</span></td>
<td>{{city.groupCount}}</td> <td>{{city.groupCount}}</td>
...@@ -70,14 +70,14 @@ ...@@ -70,14 +70,14 @@
<span style="padding-left:10px;" <span style="padding-left:10px;"
ng-show="city.printer_Id==null">未分配</span> ng-show="city.printer_Id==null">未分配</span>
<span style="padding-left:10px;" <span style="padding-left:10px;"
ng-show="city.printer_Id!=null">机器<span>{{city.printer_Id}}</span></span> ng-show="city.printer_Id!=null">机器<span>{{city.printerId}}</span></span>
</td> </td>
<td>{{city.state}}</td> <td>{{city.state}}</td>
<td ng-if="userState<=4"><a ng-click="showTable(city.task_Id)">组号列表</a></td> <td ng-if="userState<=4"><a ng-click="showTable(city.taskId)">组号列表</a></td>
<td ng-if="userState>4"><a ng-click="showTable(city.task_Id)">区县列表</a></td> <td ng-if="userState>4"><a ng-click="showTableCounty(city.taskId)">区县列表</a></td>
<td><a ng-click="finishClick(city.task_Id,userState)">完成</a></td> <td><a ng-click="finishClick(city.taskId,userState)">完成</a></td>
</tr> </tr>
<tr ng-show="showtable==city.task_Id && userState<=4"> <tr ng-show="showtable==city.taskId && userState<=4">
<td></td> <td></td>
<td colspan="4"> <td colspan="4">
<table style="font-size:0.9em;color: #000;" class="table"> <table style="font-size:0.9em;color: #000;" class="table">
...@@ -90,9 +90,9 @@ ...@@ -90,9 +90,9 @@
</thead> </thead>
<tbody> <tbody>
<tr ng-repeat="group in groupList"> <tr ng-repeat="group in groupList">
<td>{{group.groupNO}}</td> <td>{{group.groupNo}}</td>
<td>{{group.vaildCount}}</td> <td>{{group.validCount}}</td>
<td>{{group.invaildCount}}</td> <td>{{group.invalidCount}}</td>
<td>{{group.specialCardCount}}</td> <td>{{group.specialCardCount}}</td>
<td><a ng-click="showTableGroup(group.specialCardList)">特殊证件列表</a></td> <td><a ng-click="showTableGroup(group.specialCardList)">特殊证件列表</a></td>
</tr> </tr>
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
</td> </td>
</tr> </tr>
<tr ng-show="showtable==city.task_Id && userState>4"> <tr ng-show="showtableCounty==city.taskId && userState>4">
<td></td> <td></td>
<td colspan="4"> <td colspan="4">
<table style="font-size:0.9em;color: #000;" class="table"> <table style="font-size:0.9em;color: #000;" class="table">
......
...@@ -5,8 +5,9 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -5,8 +5,9 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
} else { } else {
$state.go("layout.cycleSheet") $state.go("layout.cycleSheet")
} }
$scope.userState = $rootScope.loginData.state; // $scope.userState = $rootScope.loginData.workshop;
// $scope.userState=5; console.log($scope.userState,'---------$scope.userState-------')
$scope.userState=5;
var getNowFormatDate = function () { var getNowFormatDate = function () {
var date = new Date(); var date = new Date();
...@@ -43,7 +44,6 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -43,7 +44,6 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
$scope.open = function ($event) { $scope.open = function ($event) {
$event.preventDefault(); $event.preventDefault();
$event.stopPropagation(); $event.stopPropagation();
$scope.opened = true; $scope.opened = true;
}; };
...@@ -57,24 +57,32 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -57,24 +57,32 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
$scope.formats = ['dd-MMMM-yyyy', 'yyyy/MM/dd', 'dd.MM.yyyy', 'shortDate']; $scope.formats = ['dd-MMMM-yyyy', 'yyyy/MM/dd', 'dd.MM.yyyy', 'shortDate'];
$scope.format = $scope.formats[1]; $scope.format = $scope.formats[1];
$scope.task_click = function () { $scope.task_click = function () {
console.log($rootScope.loginData.state, "----测试-----", $scope.dt, "====");
} }
$scope.cardType = 0; $scope.cardType = 0;
$scope.check_type = function (typeCode) { $scope.check_type = function (typeCode) {
cardType = typeCode; cardType = typeCode;
console.log($rootScope.loginData.state, "----测试-----", $scope.dt, "====", typeCode, "+++++++++++++"); getCityListData(cardType,$scope.userState);
} }
// 查询制证类型列表 // 查询制证类型列表
var getTypeListData = function (state) { var getTypeListData = function (userState) {
HttpService.getTypeListByTaskStateId(1,function (data) { HttpService.getTypeListByTaskStateId(userState,function (data) {
$scope.typeList = data.respData; $scope.typeList = data.respData;
console.log("---制证类型--数据源:")
console.log(data.respData)
}) })
} }
getTypeListData($rootScope.loginData.state); getTypeListData($scope.userState);
$scope.currentTab = 1;
$scope.func = function (id) {
for (var i = 0; i < $scope.folds.length; i++) {
if (id == $scope.folds[i].id) {
$scope.folds[i].isActive = true;
} else {
$scope.folds[i].isActive = false;
}
}
$scope.currentTab = id;
}
// $scope.nowType == $scope.getCityListData[$scope.currentTab].typeCode? $scope.currentTab=$scope.currentTab:$scope.currentTab= -1; // $scope.nowType == $scope.getCityListData[$scope.currentTab].typeCode? $scope.currentTab=$scope.currentTab:$scope.currentTab= -1;
// for (var i = 0; i < $scope.getCityListData.length; i++) { // for (var i = 0; i < $scope.getCityListData.length; i++) {
...@@ -86,37 +94,40 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -86,37 +94,40 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
// } // }
// } // }
// // 查询城市列表 // 查询城市列表
// var getCityListData = function (cardType,state) { var getCityListData = function (cardType,state) {
// HttpService.getCityListByCardType(cardType,1,function (data) { console.log("----调用查询城市列表接口-",cardType,state)
// $scope.cityList = data.respData; HttpService.getCityListByCardType(cardType,state,function (data) {
// console.log("---城市列表--数据源:") $scope.cityList = data.respData;
// console.log(data.respData) console.log("---城市列表--数据源:")
// console.log(data.respData)
// })
// }
// getCityListData(cardType,$rootScope.loginData.state);
// // 查询组号列表
// var getGroupListData = function (taskId) {
// HttpService.getGroupNoByTaskListId(taskId,function (data) {
// $scope.groupList = data.respData;
// console.log("---查询组号列表--数据源:")
// console.log(data.respData)
//
// })
// }
})
}
console.log("--查看card type- -",$scope.cardType)
getCityListData($scope.cardType,$scope.userState);
// 查询组号列表
var getGroupListData = function (taskId) {
console.log("---查询组号列表--数据源:",taskId);
HttpService.getGroupNoByTaskListId(taskId,function (data) {
$scope.groupList = data.respData;
console.log("---查询组号列表--数据源:")
console.log(data.respData)
})
}
// // 查询区县列表
// var getCountyListData = function (taskId) { // 查询区县列表
// HttpService.getCountyListByTaskListId(taskId,function (data) { var getCountyListData = function (taskId) {
// $scope.countyList = data.respData; HttpService.getCountyListByTaskListId(taskId,function (data) {
// console.log("---查询区县列表--数据源:") $scope.countyList = data.respData;
// console.log(data.respData) console.log("---查询区县列表--数据源:")
// console.log(data.respData)
// })
// } })
}
// $scope.typeList = [ // $scope.typeList = [
// {typeCode: 0, typeCount: 5000, typeName: '普通证'}, // {typeCode: 0, typeCount: 5000, typeName: '普通证'},
...@@ -124,218 +135,233 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -124,218 +135,233 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
// {typeCode: 2, typeCount: 5000, typeName: '特殊证'}, // {typeCode: 2, typeCount: 5000, typeName: '特殊证'},
// {typeCode: 9, typeCount: 5000, typeName: '异地证'} // {typeCode: 9, typeCount: 5000, typeName: '异地证'}
// ] // ]
$scope.cityList = [ // $scope.cityList = [
{ // {
"card_Type": 1, // "card_Type": 1,
"citycode": "410300", // "citycode": "410300",
cityName: "郑州", // cityName: "郑州",
groupCount: 10, // groupCount: 10,
groupSum: 1500, // groupSum: 1500,
groupInvailedSum: 15, // groupInvailedSum: 15,
groupNO: "1-25", // groupNO: "1-25",
"download_Date": null, // "download_Date": null,
"exception_Information": "", // "exception_Information": "",
"in_Storage_Date": null, // "in_Storage_Date": null,
"is_Exception": 0, // "is_Exception": 0,
"issued_Date": null, // "issued_Date": null,
"old_Card_Type": 1, // "old_Card_Type": 1,
"out_Storage_Date": null, // "out_Storage_Date": null,
"out_Workshop_Date": null, // "out_Workshop_Date": null,
"position_Date": null, // "position_Date": null,
"print_Out_Date": null, // "print_Out_Date": null,
"print_State": 0, // "print_State": 0,
"printer_Id": 0, // "printer_Id": 0,
"quality_People_Name": "", // "quality_People_Name": "",
"quality_Test_Date": null, // "quality_Test_Date": null,
"submit_Date": { // "submit_Date": {
"date": 20, // "date": 20,
"day": 2, // "day": 2,
"hours": 11, // "hours": 11,
"minutes": 20, // "minutes": 20,
"month": 10, // "month": 10,
"seconds": 53, // "seconds": 53,
"time": 1542684053000, // "time": 1542684053000,
"timezoneOffset": -480, // "timezoneOffset": -480,
"year": 118 // "year": 118
}, // },
"task_Id": 201811203, // "task_Id": 201811203,
"task_State_Id": 1 // "task_State_Id": 1
}, // },
{ // {
"card_Type": 1, // "card_Type": 1,
"citycode": "410400", // "citycode": "410400",
cityName: "驻马店", // cityName: "驻马店",
groupCount: 10, // groupCount: 10,
groupSum: 2500, // groupSum: 2500,
groupInvailedSum: 16, // groupInvailedSum: 16,
groupNO: "26-45", // groupNO: "26-45",
"download_Date": null, // "download_Date": null,
"exception_Information": "", // "exception_Information": "",
"in_Storage_Date": null, // "in_Storage_Date": null,
"is_Exception": 0, // "is_Exception": 0,
"issued_Date": null, // "issued_Date": null,
"old_Card_Type": 1, // "old_Card_Type": 1,
"out_Storage_Date": null, // "out_Storage_Date": null,
"out_Workshop_Date": null, // "out_Workshop_Date": null,
"position_Date": null, // "position_Date": null,
"print_Out_Date": null, // "print_Out_Date": null,
"print_State": 0, // "print_State": 0,
"printer_Id": 0, // "printer_Id": 0,
"quality_People_Name": "", // "quality_People_Name": "",
"quality_Test_Date": null, // "quality_Test_Date": null,
"submit_Date": { // "submit_Date": {
"date": 20, // "date": 20,
"day": 2, // "day": 2,
"hours": 11, // "hours": 11,
"minutes": 20, // "minutes": 20,
"month": 10, // "month": 10,
"seconds": 53, // "seconds": 53,
"time": 1542684053000, // "time": 1542684053000,
"timezoneOffset": -480, // "timezoneOffset": -480,
"year": 118 // "year": 118
}, // },
"task_Id": 201811204, // "task_Id": 201811204,
"task_State_Id": 1 // "task_State_Id": 1
}, // },
{ // {
"card_Type": 1, // "card_Type": 1,
"citycode": "410500", // "citycode": "410500",
cityName: "新乡", // cityName: "新乡",
groupCount: 10, // groupCount: 10,
groupSum: 3500, // groupSum: 3500,
groupInvailedSum: 17, // groupInvailedSum: 17,
groupNO: "46", // groupNO: "46",
"download_Date": null, // "download_Date": null,
"exception_Information": "", // "exception_Information": "",
"in_Storage_Date": null, // "in_Storage_Date": null,
"is_Exception": 0, // "is_Exception": 0,
"issued_Date": null, // "issued_Date": null,
"old_Card_Type": 1, // "old_Card_Type": 1,
"out_Storage_Date": null, // "out_Storage_Date": null,
"out_Workshop_Date": null, // "out_Workshop_Date": null,
"position_Date": null, // "position_Date": null,
"print_Out_Date": null, // "print_Out_Date": null,
"print_State": 0, // "print_State": 0,
"printer_Id": 0, // "printer_Id": 0,
"quality_People_Name": "", // "quality_People_Name": "",
"quality_Test_Date": null, // "quality_Test_Date": null,
"submit_Date": { // "submit_Date": {
"date": 20, // "date": 20,
"day": 2, // "day": 2,
"hours": 11, // "hours": 11,
"minutes": 20, // "minutes": 20,
"month": 10, // "month": 10,
"seconds": 53, // "seconds": 53,
"time": 1542684053000, // "time": 1542684053000,
"timezoneOffset": -480, // "timezoneOffset": -480,
"year": 118 // "year": 118
}, // },
"task_Id": 201811205, // "task_Id": 201811205,
"task_State_Id": 1 // "task_State_Id": 1
}, // },
{ // {
"card_Type": 1, // "card_Type": 1,
"citycode": "410600", // "citycode": "410600",
cityName: "周口", // cityName: "周口",
groupCount: 10, // groupCount: 10,
groupSum: 3500, // groupSum: 3500,
groupInvailedSum: 18, // groupInvailedSum: 18,
groupNO: "48-52,53-55", // groupNO: "48-52,53-55",
"download_Date": null, // "download_Date": null,
"exception_Information": "", // "exception_Information": "",
"in_Storage_Date": null, // "in_Storage_Date": null,
"is_Exception": 0, // "is_Exception": 0,
"issued_Date": null, // "issued_Date": null,
"old_Card_Type": 1, // "old_Card_Type": 1,
"out_Storage_Date": null, // "out_Storage_Date": null,
"out_Workshop_Date": null, // "out_Workshop_Date": null,
"position_Date": null, // "position_Date": null,
"print_Out_Date": null, // "print_Out_Date": null,
"print_State": 0, // "print_State": 0,
"printer_Id": 0, // "printer_Id": 0,
"quality_People_Name": "", // "quality_People_Name": "",
"quality_Test_Date": null, // "quality_Test_Date": null,
"submit_Date": { // "submit_Date": {
"date": 20, // "date": 20,
"day": 2, // "day": 2,
"hours": 11, // "hours": 11,
"minutes": 20, // "minutes": 20,
"month": 10, // "month": 10,
"seconds": 53, // "seconds": 53,
"time": 1542684053000, // "time": 1542684053000,
"timezoneOffset": -480, // "timezoneOffset": -480,
"year": 118 // "year": 118
}, // },
"task_Id": 201811206, // "task_Id": 201811206,
"task_State_Id": 1 // "task_State_Id": 1
}, // },
] // ]
$scope.groupList = [ // $scope.groupList = [
{ // {
"groupNO": 45, // "groupNO": 45,
"vaildCount": 45, // "vaildCount": 45,
invaildCount: 25, // invaildCount: 25,
specialCardCount: 5, // specialCardCount: 5,
specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}] // specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}]
}, // },
{ // {
"groupNO": 45, // "groupNO": 45,
"vaildCount": 45, // "vaildCount": 45,
invaildCount: 25, // invaildCount: 25,
specialCardCount: 5, // specialCardCount: 5,
specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}] // specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}]
}, // },
{ // {
"groupNO": 45, // "groupNO": 45,
"vaildCount": 45, // "vaildCount": 45,
invaildCount: 25, // invaildCount: 25,
specialCardCount: 5, // specialCardCount: 5,
specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}] // specialCardList: [{acceptNo: 20180401, specialType: 1}, {acceptNo: 20180401, specialType: 1}]
} // }
] // ]
$scope.countyList = [ // $scope.countyList = [
{ // {
"countyName": "许昌县", // "countyName": "许昌县",
county_Code: "411023", // county_Code: "411023",
downloadCount: 240, // downloadCount: 240,
electric_writerCount: 240, // electric_writerCount: 240,
in_Storage_Count: 240, // in_Storage_Count: 240,
out_Storage_Count: 240, // out_Storage_Count: 240,
finish_Count: 240 // finish_Count: 240
}, // },
{ // {
"countyName": "禹州", // "countyName": "禹州",
county_Code: "411081", // county_Code: "411081",
downloadCount: 210, // downloadCount: 210,
electric_writerCount: 210, // electric_writerCount: 210,
in_Storage_Count: 210, // in_Storage_Count: 210,
out_Storage_Count: 210, // out_Storage_Count: 210,
finish_Count: 210 // finish_Count: 210
}, // },
{ // {
"countyName": "长葛", // "countyName": "长葛",
county_Code: "411082", // county_Code: "411082",
downloadCount: 243, // downloadCount: 243,
electric_writerCount: 243, // electric_writerCount: 243,
in_Storage_Count: 243, // in_Storage_Count: 243,
out_Storage_Count: 243, // out_Storage_Count: 243,
finish_Count: 243 // finish_Count: 243
} // }
] // ]
$scope.receiptList = [[358, 0, 0, 0, 82, 0, 0, 1, 0, 205, 646, 3, "郑州 辖区", "410101"], [721, 0, 0, 0, 20, 0, 0, 7, 1, 91, 840, 4, "郑州 中原", "410102"],] // $scope.receiptList = [[358, 0, 0, 0, 82, 0, 0, 1, 0, 205, 646, 3, "郑州 辖区", "410101"], [721, 0, 0, 0, 20, 0, 0, 7, 1, 91, 840, 4, "郑州 中原", "410102"],]
$scope.showtable = -1; $scope.showtable = -1;
$scope.showTable = function (taskID) { $scope.showTable = function (taskID) {
console.log("$scope.-------$scope.showtable----",taskID);
if ($scope.showtable != taskID) { if ($scope.showtable != taskID) {
$scope.showtable = taskID; $scope.showtable = taskID;
} else { } else {
$scope.showtable = -1; $scope.showtable = -1;
} }
getGroupListData($scope.showtable);
}
$scope.showtableCounty = -1;
$scope.showTableCounty = function (taskID) {
if ($scope.showtableCounty != taskID) {
$scope.showtableCounty = taskID;
} else {
$scope.showtableCounty = -1;
}
console.log($scope.showtableCounty,"---$scope.showtableCounty--");
getCountyListData($scope.showtableCounty);
} }
$scope.showTableGroup = function (specialCardList) { $scope.showTableGroup = function (specialCardList) {
console.log("--specialCardList--",specialCardList);
ngDialog.open({ ngDialog.open({
template: 'dialogs/specialCardList.html' + urlTimeStamp(), template: 'dialogs/specialCardList.html' + urlTimeStamp(),
width: 800, width: 800,
...@@ -348,122 +374,115 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f ...@@ -348,122 +374,115 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
} }
$scope.finishClick = function (taskId, userState) { $scope.finishClick = function (taskId, userState) {
HttpService.updateProductionTask(taskId, userState, function (data) { var state =parseInt(userState);
console.log("--userState+1--",state+1);
HttpService.updateProductionTask(taskId, state+1, function (success) {
//点击确认成功后 再次查询城市列表 //点击确认成功后 再次查询城市列表
getCityListData(cardType, $rootScope.loginData.state); getCityListData(cardType,state+1 );
}) })
} }
$scope.folds = [ // $scope.folds = [
{ // {
id: 1, name: '普通证', count: 10000, filter: '', isActive: true, dataTable: { // id: 1, name: '普通证', count: 10000, filter: '', isActive: true, dataTable: {
"aaData": [ // "aaData": [
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 4.0", // "browser": "Internet Explorer 4.0",
"platform": "Win 95+", // "platform": "Win 95+",
"version": "4", // "version": "4",
"grade": "X" // "grade": "X"
}, // },
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 5.0", // "browser": "Internet Explorer 5.0",
"platform": "Win 95+", // "platform": "Win 95+",
"version": "5", // "version": "5",
"grade": "C" // "grade": "C"
}] // }]
} // }
}, // },
{ // {
id: 2, name: '邮寄证', count: 20000, filter: 'starred', dataTable: { // id: 2, name: '邮寄证', count: 20000, filter: 'starred', dataTable: {
"aaData": [ // "aaData": [
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 5.5", // "browser": "Internet Explorer 5.5",
"platform": "Win 95+", // "platform": "Win 95+",
"version": "5.5", // "version": "5.5",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 6", // "browser": "Internet Explorer 6",
"platform": "Win 98+", // "platform": "Win 98+",
"version": "6", // "version": "6",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 7", // "browser": "Internet Explorer 7",
"platform": "Win XP SP2+", // "platform": "Win XP SP2+",
"version": "7", // "version": "7",
"grade": "A" // "grade": "A"
}] // }]
} // }
}, // },
{ // {
id: 3, name: '军人证', count: 32000, filter: 'sent', dataTable: { // id: 3, name: '军人证', count: 32000, filter: 'sent', dataTable: {
"aaData": [ // "aaData": [
{ // {
"engine": "Trident", // "engine": "Trident",
"browser": "Internet Explorer 5.5", // "browser": "Internet Explorer 5.5",
"platform": "Win 95+", // "platform": "Win 95+",
"version": "5.5", // "version": "5.5",
"grade": "A" // "grade": "A"
}] // }]
} // }
}, // },
{ // {
id: 4, name: '快证', count: 40, filter: 'important', dataTable: { // id: 4, name: '快证', count: 40, filter: 'important', dataTable: {
"aaData": [ // "aaData": [
{ // {
"engine": "Webkit", // "engine": "Webkit",
"browser": "Safari 1.3", // "browser": "Safari 1.3",
"platform": "OSX.3", // "platform": "OSX.3",
"version": "312.8", // "version": "312.8",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Webkit", // "engine": "Webkit",
"browser": "Safari 2.0", // "browser": "Safari 2.0",
"platform": "OSX.4+", // "platform": "OSX.4+",
"version": "419.3", // "version": "419.3",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Webkit", // "engine": "Webkit",
"browser": "Safari 3.0", // "browser": "Safari 3.0",
"platform": "OSX.4+", // "platform": "OSX.4+",
"version": "522.1", // "version": "522.1",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Webkit", // "engine": "Webkit",
"browser": "OmniWeb 5.5", // "browser": "OmniWeb 5.5",
"platform": "OSX.4+", // "platform": "OSX.4+",
"version": "420", // "version": "420",
"grade": "A" // "grade": "A"
}, // },
{ // {
"engine": "Webkit", // "engine": "Webkit",
"browser": "iPod Touch / iPhone", // "browser": "iPod Touch / iPhone",
"platform": "iPod", // "platform": "iPod",
"version": "420.1", // "version": "420.1",
"grade": "A" // "grade": "A"
}] // }]
} // }
} // }
]; // ];
$scope.currentTab = 1;
$scope.func = function (id) {
for (var i = 0; i < $scope.folds.length; i++) {
if (id == $scope.folds[i].id) {
$scope.folds[i].isActive = true;
} else {
$scope.folds[i].isActive = false;
}
}
$scope.currentTab = id;
}
}]); }]);
\ No newline at end of file
...@@ -10,17 +10,7 @@ ...@@ -10,17 +10,7 @@
<input type="text" ng-model="nowDate" value="currentDetailDate" id="wdate2" class="Wdate" onClick="WdatePicker({el:this,dateFmt:'yyyy-MM-dd HH:mm',autoPickDate:'true'})"> <input type="text" ng-model="nowDate" value="currentDetailDate" id="wdate2" class="Wdate" onClick="WdatePicker({el:this,dateFmt:'yyyy-MM-dd HH:mm',autoPickDate:'true'})">
<input type="submit" class="btn btn-primary" value="查询" ng-click="myClick()"> <input type="submit" class="btn btn-primary" value="查询" ng-click="myClick()">
</div> </div>
</div> <div style="padding: 10px;background-color: #fff;border: 1px solid #CCC;border-radius: 10px;">
</div>
<div class="loading">
<span></span>
<span></span>
<span></span>
<span></span>
<span></span>
</div>
</div>
<div style="padding: 10px;background-color: #fff;border: 1px solid #CCC;border-radius: 10px;">
<div> <div>
<div ng-if="receiptData.length>0"> <div ng-if="receiptData.length>0">
<table class="table table-hover" style="margin-top:10px;"> <table class="table table-hover" style="margin-top:10px;">
...@@ -42,11 +32,24 @@ ...@@ -42,11 +32,24 @@
</thead> </thead>
<tbody> <tbody>
<tr ng-repeat="county in receiptData"> <tr ng-repeat="county in receiptData">
<td width="100px">{{county[12]}}</td> <td width="100px">{{county.countyName}}</td>
<td width="100px" ng-repeat="item in county track by $index" ng-if="$index!=12 && $index!=13"> <td width="100px">{{county.PTZ}}</td>
<span ng-if="item!=0">{{item}}</span> <td width="100px">{{county.KZ}}</td>
<span ng-if="item==0"></span> <td width="100px">{{county.YDKSY}}</td>
</td> <td width="100px">{{county.YDKSP}}</td>
<td width="100px">{{county.YDY}}</td>
<td width="100px">{{county.YDP}}</td>
<td width="100px">{{county.JRZ}}</td>
<td width="100px">{{county.KSP}}</td>
<td width="100px">{{county.KSY}}</td>
<td width="100px">{{county.YJZ}}</td>
<td width="100px">{{county.sum}}</td>
<td width="100px">{{county.boxCount}}</td>
<!--<td width="100px" ng-repeat="item in county track by $index" ng-if="$index!=12 && $index!=13">-->
<!--<span ng-if="item!=0">{{item}}</span>-->
<!--<span ng-if="item==0"></span>-->
<!--</td>-->
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -54,9 +57,20 @@ ...@@ -54,9 +57,20 @@
<div ng-if="receiptData.length==0" style="font-size:1.5em;"> <div ng-if="receiptData.length==0" style="font-size:1.5em;">
当天暂无报表数据。 当天暂无报表数据。
</div> </div>
<div ng-if="receiptData.length!=0 && receiptData[0][11] != 0" style="font-size:1.5em;"> <div ng-if="receiptData.length!=0" style="font-size:1.5em;">
<input type="button" class="btn btn-primary" value="下载交接单" ng-click="printReceipt()"> <input type="button" class="btn btn-primary" value="下载交接单" ng-click="printReceipt()">
<input type="button" class="btn btn-primary" value="下载回执单" ng-click="printOfficialReceipt()"> <input type="button" class="btn btn-primary" value="下载回执单" ng-click="printOfficialReceipt()">
</div> </div>
</div> </div>
</div>
</div>
</div>
<!--<div class="loading">-->
<!--<span></span>-->
<!--<span></span>-->
<!--<span></span>-->
<!--<span></span>-->
<!--<span></span>-->
<!--</div>-->
</div> </div>
...@@ -30,8 +30,10 @@ app.controller('receiptCtrl', ['$scope', '$rootScope', '$http', '$state', '$filt ...@@ -30,8 +30,10 @@ app.controller('receiptCtrl', ['$scope', '$rootScope', '$http', '$state', '$filt
return currentdate; return currentdate;
} }
$scope.currentDetailDate = getNowFormatDetailDate(); $scope.currentDetailDate = getNowFormatDetailDate();
$scope.nowDataEight = new Date().format("yyyy-MM-dd 08:00") // $scope.nowDataEight = new Date().format("yyyy-MM-dd 08:00");
$scope.nowDate = new Date().format("yyyy-MM-dd hh:mm"); var date = new Date();
$scope.nowDataEight = $filter('date')(date,"yyyy-MM-dd 08:00");
$scope.nowDate = $filter('date')(date,"yyyy-MM-dd hh:mm");
var changeDataFormat = function (date) { var changeDataFormat = function (date) {
var yyyyMMdd = date.split(" ")[0]; var yyyyMMdd = date.split(" ")[0];
...@@ -43,12 +45,11 @@ app.controller('receiptCtrl', ['$scope', '$rootScope', '$http', '$state', '$filt ...@@ -43,12 +45,11 @@ app.controller('receiptCtrl', ['$scope', '$rootScope', '$http', '$state', '$filt
var mm = hhmm.split(":")[1]; var mm = hhmm.split(":")[1];
return yyyy + MM + dd + hh + mm; return yyyy + MM + dd + hh + mm;
} }
$scope.receiptData =[];
var getReceiptData = function (startTime, endTime) { var getReceiptData = function (startTime, endTime) {
HttpService.getReceiptData(startTime, endTime, function (data) { HttpService.getReceiptData(startTime, endTime, function (data) {
$scope.receiptData = data.respData; $scope.receiptData = data.respData;
console.log($scope.receiptData)
}) })
} }
getReceiptData(changeDataFormat($scope.nowDataEight), changeDataFormat($scope.nowDate)) getReceiptData(changeDataFormat($scope.nowDataEight), changeDataFormat($scope.nowDate))
......
...@@ -5,7 +5,7 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$ ...@@ -5,7 +5,7 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$
} else { } else {
$state.go("layout.yieldReport") $state.go("layout.yieldReport")
} }
$scope.userState = $rootScope.loginData.state; $scope.userState = $rootScope.workshop;
// $scope.userState=5; // $scope.userState=5;
...@@ -48,10 +48,10 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$ ...@@ -48,10 +48,10 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$
$scope.month_last = getMonthLastDay(); $scope.month_last = getMonthLastDay();
var getQualityReport = function (startDate, endDate) { var getQualityReport = function (startDate, endDate) {
HttpService.getQualityReport(startDate, endDate, function (data) { // HttpService.getQualityReport(startDate, endDate, function (data) {
$scope.dataCheckData = data.respData; // $scope.dataCheckData = data.respData;
console.log("初始化数据核验质量报表:", $scope.dataCheckData) // console.log("初始化数据核验质量报表:", $scope.dataCheckData)
}) // })
} }
//初始化数据核验报表 //初始化数据核验报表
if ($rootScope.loginData.state == 1 || $rootScope.loginData.state == 0) { if ($rootScope.loginData.state == 1 || $rootScope.loginData.state == 0) {
...@@ -89,7 +89,7 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$ ...@@ -89,7 +89,7 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$
}) })
} }
if ($rootScope.loginData.state == 0) { if ($rootScope.loginData.state == 0) {
HttpService.getAdminPrintData(startDate, endDate, $scope.state.substring(1, 2), function (data) { HttpService.getAdminPrintData(startDate, endDate, $scope.userState, function (data) {
$scope.printDataReport = data.respData; $scope.printDataReport = data.respData;
console.log("初始化打印卸载报表:", $scope.printDataReport) console.log("初始化打印卸载报表:", $scope.printDataReport)
}) })
...@@ -128,23 +128,23 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$ ...@@ -128,23 +128,23 @@ app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$
} }
var getQualityCheckReport = function (month) { var getQualityCheckReport = function (month) {
if ($rootScope.loginData.state == 6) { // if ($rootScope.loginData.state == 6) {
HttpService.getQualityCheckReportData(month, function (data) { // HttpService.getQualityCheckReportData(month, function (data) {
$scope.qulityCheckData = data.respData; // $scope.qulityCheckData = data.respData;
console.log("质检报表:", $scope.qulityCheckData) // console.log("质检报表:", $scope.qulityCheckData)
}) // })
} // }
if ($rootScope.loginData.state == 0) { // if ($rootScope.loginData.state == 0) {
HttpService.getAdminQualityCheckReportData(month, $scope.state.substring(1, 2), function (data) { // HttpService.getAdminQualityCheckReportData(month, $scope.state.substring(1, 2), function (data) {
$scope.qulityCheckData = data.respData; // $scope.qulityCheckData = data.respData;
console.log("质检报表:", $scope.qulityCheckData) // console.log("质检报表:", $scope.qulityCheckData)
}) // })
} // }
} }
if ($rootScope.loginData.state == 6 || $rootScope.loginData.state == 0) { // if ($rootScope.loginData.state == 6 || $rootScope.loginData.state == 0) {
getQualityCheckReport($scope.nowMonth) // getQualityCheckReport($scope.nowMonth)
} // }
$scope.printQualityCheckReport = function () { $scope.printQualityCheckReport = function () {
var month = $("#wdateZj").val() var month = $("#wdateZj").val()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment