master
Limy 4 years ago
parent 5a70e720b8
commit e48b6fcb0b

@ -44,28 +44,32 @@ public class SelectParaAllController extends BaseController {
public TableDataInfo list(HttpServletRequest request)
{
String semiBarcode = request.getParameter("semiBarcode");
Map map = new HashMap<String,Object>();
Map<String, Object> map = new HashMap<String,Object>();
map.put("beginTime",null);
map.put("endTime",null);
map.put("semiBarcode",semiBarcode);
List<ParaAllShow> list = tracestateService.selectAllPara(map);
// List<List<?>> multiResult = tracestateService.selectAllPara(map);
// List<ParaAllShow> list = tracestateService.selectAllPara(map);
List<List<HashMap<String,String>>> list = tracestateService.selectAllPara(map);
return getDataTable(list);
}
@RequiresPermissions("nanjing:ParaAllShow:export")
@Log(title = "产品码查询", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(HttpServletRequest request)
{
String semiBarcode = request.getParameter("semiBarcode");
Map map = new HashMap<String,Object>();
map.put("beginTime",null);
map.put("endTime",null);
map.put("semiBarcode",semiBarcode);
List<ParaAllShow> list = tracestateService.selectAllPara(map);
ExcelUtil<ParaAllShow> util = new ExcelUtil<ParaAllShow>(ParaAllShow.class);
return util.exportExcel(list, "ParaAllShow");
// return null;
}
// @RequiresPermissions("nanjing:ParaAllShow:export")
// @Log(title = "产品码查询", businessType = BusinessType.EXPORT)
// @PostMapping("/export")
// @ResponseBody
// public AjaxResult export(HttpServletRequest request)
// {
// String semiBarcode = request.getParameter("semiBarcode");
// Map map = new HashMap<String,Object>();
// map.put("beginTime",null);
// map.put("endTime",null);
// map.put("semiBarcode",semiBarcode);
// List<ParaAllShow> list = tracestateService.selectAllPara(map);
// ExcelUtil<ParaAllShow> util = new ExcelUtil<ParaAllShow>(ParaAllShow.class);
// return util.exportExcel(list, "ParaAllShow");
//// return null;
// }
}

@ -16,16 +16,17 @@
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="searc()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<!-- <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;查询全部</a>-->
<!-- <a class="btn btn-info btn-rounded btn-sm" onclick="celexport()" shiro:hasPermission="nanjing:ParaAllShow:export"><i class="fa fa-download"></i> 导出</a>-->
<!-- <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;查询全部</a>-->
<!-- <a class="btn btn-info btn-rounded btn-sm" onclick="celexport()" shiro:hasPermission="nanjing:ParaAllShow:export"><i class="fa fa-download"></i> 导出</a>-->
</li>
</ul>
</div>
</form>
</div>
<!-- <div class="col-sm-12 select-table table-striped">-->
<!-- <table id="bootstrap-table1"></table>-->
<!-- </div>-->
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table1"></table>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table2"></table>
</div>
@ -48,53 +49,55 @@
contentType: false,
modalName: "产品码查询",
success: function (json) {
console.log(json);
var columnsArray2 = [];
columnsArray2.push({field : "semiBarcode",title : "产品码",colspan: 1,rowspan: 1});
columnsArray2.push({field : "proBarcode",title : "部件码",colspan: 1,rowspan: 1});
columnsArray2.push({field : "stationCode",title : "工位代码",colspan: 1,rowspan: 1});
columnsArray2.push({field : "insertTime",title : "记录时间",colspan: 1,rowspan: 1});
columnsArray2.push({field : "paraName",title : "参数名称",colspan: 1,rowspan: 1});
columnsArray2.push({field : "realVal",title : "实测值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "minVal",title : "最小值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "maxVal",title : "最大值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "paraState",title : "参数状态",colspan: 1,rowspan: 1});
columnsArray2.push({field : "部件码",title : "部件码",colspan: 1,rowspan: 1});
columnsArray2.push({field : "工位代码",title : "工位代码",colspan: 1,rowspan: 1});
columnsArray2.push({field : "记录时间",title : "记录时间",colspan: 1,rowspan: 1});
columnsArray2.push({field : "参数名称",title : "参数名称",colspan: 1,rowspan: 1});
columnsArray2.push({field : "实测值",title : "实测值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "最小值",title : "最小值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "最大值",title : "最大值",colspan: 1,rowspan: 1});
columnsArray2.push({field : "参数状态",title : "参数状态",colspan: 1,rowspan: 1});
var columnsArray1 = [];
columnsArray1.push({field : "系统条码",title : "系统条码",colspan: 1,rowspan: 1});
columnsArray1.push({field : "semiBarcode" ,title : "产品码",colspan: 1,rowspan: 1});
columnsArray1.push({field : "机种类型",title : "机种类型",colspan: 1,rowspan: 1});
columnsArray1.push({field : "返修Y/N",title : "返修Y/N",colspan: 1,rowspan: 1});
columnsArray1.push({field : "合格状态",title : "合格状态",colspan: 1,rowspan: 1});
columnsArray1.push({field : "完成状态",title : "完成状态",colspan: 1,rowspan: 1});
columnsArray1.push({field : "当前工位",title : "当前工位",colspan: 1,rowspan: 1});
columnsArray1.push({field : "NG工位",title : "NG工位",colspan: 1,rowspan: 1});
columnsArray1.push({field : "标签Y/N",title : "标签Y/N",colspan: 1,rowspan: 1});
columnsArray1.push({field : "开始时间",title : "开始时间",colspan: 1,rowspan: 1});
columnsArray1.push({field : "结束时间",title : "结束时间",colspan: 1,rowspan: 1});
// var columnsArray1 = [];
// columnsArray1.push({field : "barcode",title : "系统条码",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "semiBarcode",title : "产品码",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "productName",title : "机种类型",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "isDis",title : "返修Y/N",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "state",title : "合格状态",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "finishFlag",title : "完成状态",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "currentStation",title : "当前工位",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "NGStation",title : "NG工位",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "namePlateInfo",title : "标签Y/N",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "beginTime",title : "开始时间",colspan: 1,rowspan: 1});
// columnsArray1.push({field : "endTime",title : "结束时间",colspan: 1,rowspan: 1});
//
// $('#bootstrap-table1').bootstrapTable('destroy').bootstrapTable({
// id: "bootstrap-table1",
// data:json,
// toolbar: "#toolbar",
// singleSelect: false,
// clickToSelect: true,
// sortName: "recordTime",
// sortOrder: "desc",
// pageSize: 50,
// pageNumber: 1,
// pageList: "[10, 15,25, 50, All]",
// showToggle: true,
// showRefresh: true,
// showColumns: true,
// search: false,
// pagination: true,
// showExport: false,//工具栏上显示导出按钮
// columns: columnsArray1
// });
$('#bootstrap-table1').bootstrapTable('destroy').bootstrapTable({
id: "bootstrap-table1",
data:json.rows[1],
toolbar: "#toolbar",
singleSelect: false,
clickToSelect: true,
sortName: "recordTime",
sortOrder: "desc",
pageSize: 50,
pageNumber: 1,
pageList: "[10, 15,25, 50, All]",
showToggle: true,
showRefresh: true,
showColumns: true,
search: false,
pagination: true,
showExport: false,//工具栏上显示导出按钮
columns: columnsArray1
});
$('#bootstrap-table2').bootstrapTable('destroy').bootstrapTable({
id: "bootstrap-table2",
data:json,
data:json.rows[0],
toolbar: "#toolbar",
singleSelect: false,
clickToSelect: true,

@ -68,9 +68,9 @@
title:'参数值'
},
],
onLoadSuccess:function(data){
mergeTable(data,"table");
},
// onLoadSuccess:function(data){
// mergeTable(data,"table");
// },
})
}

@ -1,5 +1,6 @@
package com.ruoyi.nanjing.mapper;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@ -7,18 +8,21 @@ import com.ruoyi.nanjing.domain.ParaAllShow;
import com.ruoyi.nanjing.domain.ProParaInfo;
import com.ruoyi.nanjing.domain.ProRpList;
import com.ruoyi.nanjing.domain.TSyTracestate;
import org.apache.ibatis.annotations.Options;
import org.apache.ibatis.annotations.ResultMap;
import org.apache.ibatis.mapping.StatementType;
/**
* traceStateMapper
*
*
* @author limy
* @date 2021-01-29
*/
public interface TSyTracestateMapper
public interface TSyTracestateMapper
{
/**
* traceState
*
*
* @param barcode traceStateID
* @return traceState
*/
@ -26,7 +30,7 @@ public interface TSyTracestateMapper
/**
* traceState
*
*
* @param tSyTracestate traceState
* @return traceState
*/
@ -34,7 +38,7 @@ public interface TSyTracestateMapper
/**
* traceState
*
*
* @param tSyTracestate traceState
* @return
*/
@ -42,7 +46,7 @@ public interface TSyTracestateMapper
/**
* traceState
*
*
* @param tSyTracestate traceState
* @return
*/
@ -50,7 +54,7 @@ public interface TSyTracestateMapper
/**
* traceState
*
*
* @param barcode traceStateID
* @return
*/
@ -58,14 +62,15 @@ public interface TSyTracestateMapper
/**
* traceState
*
*
* @param barcodes ID
* @return
*/
public int deleteTSyTracestateByIds(String[] barcodes);
List<ParaAllShow> selectAllPara(Map map);
// List<ProParaInfo> selectAllPara(Map map);
@ResultMap({"col1","col2"})
@Options(statementType = StatementType.CALLABLE)
List<List<HashMap<String,String>>> selectAllPara(Map map);
List<ProRpList> getInfo(Object semiBarcode);
}

@ -1,5 +1,6 @@
package com.ruoyi.nanjing.service;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@ -63,5 +64,6 @@ public interface ITSyTracestateService
*/
public int deleteTSyTracestateById(String barcode);
List<ParaAllShow> selectAllPara(Map map);
List<List<HashMap<String,String>>> selectAllPara(Map map);
}

@ -1,6 +1,7 @@
package com.ruoyi.nanjing.service.impl;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@ -99,22 +100,11 @@ public class TSyTracestateServiceImpl implements ITSyTracestateService
}
@Override
public List<ParaAllShow> selectAllPara(Map map) {
// List<ParaAllShow> paraAllShows = new ArrayList<ParaAllShow>();
// List<ProParaInfo> list = tSyTracestateMapper.selectAllPara(map);
// List<ProRpList> list1 = tSyTracestateMapper.getInfo(map.get("semiBarcode"));
// ParaAllShow paraAllShow = new ParaAllShow();
// for (ProParaInfo ppi:list) {
// paraAllShow.setProParaInfo(ppi);
// paraAllShows.add(paraAllShow);
// }
// for (ProRpList prl:list1) {
// paraAllShow.setProRpList(prl);
// paraAllShows.add(paraAllShow);
// }
List<ParaAllShow> paraAllShows = tSyTracestateMapper.selectAllPara(map);
public List<List<HashMap<String,String>>> selectAllPara(Map map) {
List<List<HashMap<String,String>>> paraAllShows= tSyTracestateMapper.selectAllPara(map);
return paraAllShows;
}
}

@ -151,7 +151,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectReport" parameterType="map" statementType="CALLABLE" resultMap="repo">
{
call begin_date3
call begin_date4
(
#{begin,mode=IN,jdbcType=DATE},
#{end,mode=IN,jdbcType=DATE},

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.nanjing.mapper.TSyTracestateMapper">
<resultMap type="TSyTracestate" id="TSyTracestateResult">
@ -32,48 +32,48 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="d9Remark" column="D9Remark" />
</resultMap>
<!-- <resultMap id="paraAll" type="com.ruoyi.nanjing.domain.ParaAllShow">-->
<!-- <result property="barcode" column="系统条码" />-->
<!-- <result property="productName" column="机种类型" />-->
<!-- <result property="semiBarcode" column="产品码" />-->
<!-- <result property="state" column="合格状态" />-->
<!-- <result property="currentStation" column="当前工位" />-->
<!-- <result property="NGStation" column="NG工位" />-->
<!-- <result property="finishFlag" column="完成状态" />-->
<!-- <result property="namePlateInfo" column="标签Y/N" />-->
<!-- <result property="isDis" column="返修Y/N" />-->
<!-- <result property="beginTime" column="开始时间" />-->
<!-- <result property="endTime" column="结束时间" />-->
<!-- <result property="proBarcode" column="部件码" />-->
<!-- <result property="stationCode" column="工位代码" />-->
<!-- <result property="insertTime" column="记录时间" />-->
<!-- <result property="paraName" column="参数名称" />-->
<!-- <result property="realVal" column="实测值" />-->
<!-- <result property="minVal" column="最小值" />-->
<!-- <result property="maxVal" column="最大值" />-->
<!-- <result property="paraState" column="参数状态" />-->
<!-- </resultMap>-->
<!-- <resultMap id="paraAll" type="com.ruoyi.nanjing.domain.ParaAllShow">-->
<!-- <result property="barcode" column="系统条码" />-->
<!-- <result property="productName" column="机种类型" />-->
<!-- <result property="semiBarcode" column="产品码" />-->
<!-- <result property="state" column="合格状态" />-->
<!-- <result property="currentStation" column="当前工位" />-->
<!-- <result property="NGStation" column="NG工位" />-->
<!-- <result property="finishFlag" column="完成状态" />-->
<!-- <result property="namePlateInfo" column="标签Y/N" />-->
<!-- <result property="isDis" column="返修Y/N" />-->
<!-- <result property="beginTime" column="开始时间" />-->
<!-- <result property="endTime" column="结束时间" />-->
<!-- <result property="proBarcode" column="部件码" />-->
<!-- <result property="stationCode" column="工位代码" />-->
<!-- <result property="insertTime" column="记录时间" />-->
<!-- <result property="paraName" column="参数名称" />-->
<!-- <result property="realVal" column="实测值" />-->
<!-- <result property="minVal" column="最小值" />-->
<!-- <result property="maxVal" column="最大值" />-->
<!-- <result property="paraState" column="参数状态" />-->
<!-- </resultMap>-->
<resultMap id="col2" type="com.ruoyi.nanjing.domain.ProParaInfo">
<resultMap type="java.util.HashMap" id="col2">
<result property="semiBarcode" column="产品码" />
<result property="proBarcode" column="部件码" />
<result property="stationCode" column="工位代码" />
<result property="insertTime" column="记录时间" />
<result property="proBarcode" column="部件码" />
<result property="stationCode" column="工位代码" />
<result property="insertTime" column="记录时间" />
<result property="paraName" column="参数名称" />
<result property="realVal" column="实测值" />
<result property="minVal" column="最小值" />
<result property="minVal" column="最小值" />
<result property="maxVal" column="最大值" />
<result property="paraState" column="参数状态" />
<!-- <collection column="{semiCode=semiBarcode}" property="proRpList" ofType="com.ruoyi.nanjing.domain.ProRpList" select="getAttribute" >-->
<!-- </collection>-->
<result property="paraState" column="参数状态" />
<!-- <collection column="{semiCode=semiBarcode}" property="proRpList" ofType="com.ruoyi.nanjing.domain.ProRpList" select="getAttribute" >-->
<!-- </collection>-->
</resultMap>
<resultMap id="col1" type="com.ruoyi.nanjing.domain.ProRpList">
<resultMap type="java.util.HashMap" id="col1" >
<result property="barcode" column="系统条码" />
<result property="semiBarcode" column="产品码" />
<result property="productName" column="机种类型" />
<result property="isDis" column="返修Y/N" />
<result property="state" column="合格状态" />
<result property="productName" column="机种类型" />
<result property="isDis" column="返修Y/N" />
<result property="state" column="合格状态" />
<result property="finishFlag" column="完成状态" />
<result property="currentStation" column="当前工位" />
<result property="NGStation" column="NG工位" />
@ -111,7 +111,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<select id="selectAllPara" parameterType="map" resultMap="col2" statementType="CALLABLE">
<select id="selectAllPara" statementType="CALLABLE" parameterType="map" resultMap="col1,col2" >
{
call pro_AllParaShowInfo_Net
(
@ -150,7 +150,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nGStationID != null">NGStationID,</if>
<if test="finishFlag != null">FinishFlag,</if>
<if test="d9Remark != null">D9Remark,</if>
</trim>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="barcode != null">#{barcode},</if>
<if test="productID != null">#{productID},</if>
@ -177,7 +177,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nGStationID != null">#{nGStationID},</if>
<if test="finishFlag != null">#{finishFlag},</if>
<if test="d9Remark != null">#{d9Remark},</if>
</trim>
</trim>
</insert>
<update id="updateTSyTracestate" parameterType="TSyTracestate">

Loading…
Cancel
Save