工位合格率统计完成

master
Limy 4 years ago
parent 9fe078166b
commit 6c5eb31f94

@ -7,9 +7,9 @@
<artifactId>ruoyi</artifactId>
<version>4.3.1</version>
<name>ruoyi</name>
<url>http://www.ruoyi.vip</url>
<description>若依管理系统</description>
<!-- <name>scxsjcj</name>-->
<!-- <url>http://www.ruoyi.vip</url>-->
<!-- <description>生产线数据采集管理系统</description>-->
<properties>
<ruoyi.version>4.3.1</ruoyi.version>

@ -16,15 +16,5 @@ public class RuoYiApplication
{
// System.setProperty("spring.devtools.restart.enabled", "false");
SpringApplication.run(RuoYiApplication.class, args);
System.out.println("(♥◠‿◠)ノ゙ 若依启动成功 ლ(´ڡ`ლ)゙ \n" +
" .-------. ____ __ \n" +
" | _ _ \\ \\ \\ / / \n" +
" | ( ' ) | \\ _. / ' \n" +
" |(_ o _) / _( )_ .' \n" +
" | (_,_).' __ ___(_ o _)' \n" +
" | |\\ \\ | || |(_,_)' \n" +
" | | \\ `' /| `-' / \n" +
" | | \\ / \\ / \n" +
" ''-' `'-' `-..-' ");
}
}

@ -1,18 +1,24 @@
package com.ruoyi.web.controller.nanjing;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.nanjing.domain.QsProduct;
import com.ruoyi.nanjing.domain.QsStation;
import com.ruoyi.nanjing.domain.TBdProductinfo;
import com.ruoyi.nanjing.service.ITBdProductinfoService;
import com.ruoyi.nanjing.service.ITBdProducttypeService;
import com.ruoyi.system.domain.SysDept;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import javax.servlet.http.HttpServletRequest;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/nanjing/StatisticStation")
@ -22,21 +28,50 @@ public class StatisticStProductController extends BaseController {
@Autowired
private ITBdProducttypeService producttypeService;
@Autowired
private ITBdProductinfoService productinfoService;
@RequiresPermissions("nanjing:stationStatistic:view")
@GetMapping()
public String stationProduct()
public String stationProduct(ModelMap map)
{
List<TBdProductinfo> tBdProductinfoList = productinfoService.selectTBdProductinfoList(new TBdProductinfo());
map.addAttribute("list",tBdProductinfoList);
return prefix + "/QsStation";
}
@RequiresPermissions("nanjing:stationStatistic:list")
@PostMapping("/list")
@ResponseBody
public List<QsProduct> list(QsProduct qsProduct)
public List<QsStation> list(QsStation qsStation)
{
List<QsStation> qsProducts = producttypeService.selectStationQs(qsStation);
return qsProducts;
}
@PostMapping("/listAll")
@ResponseBody
public List<QsStation> listAll(String begin,String end)
{
// List<QsProduct> qsProducts = producttypeService.selectDeptList(qsProduct);
// return qsProducts;
return null;
Map map = new HashMap<String,Object>();
map.put("begin",begin);
map.put("end",end);
map.put("productId","");
map.put("productType","");
List<QsStation> qsStations = producttypeService.selectAllQs(map);
return qsStations;
}
@PostMapping("/nodeClick")
@ResponseBody
public List<QsStation> nodeClick(String begin,String end,String node)
{
Map map = new HashMap<String,Object>();
map.put("begin",begin);
map.put("end",end);
map.put("stationId",node);
map.put("stationType",1);
map.put("productId","ALL");
List<QsStation> qsStations = producttypeService.selectNodeQs(map);
return qsStations;
}
}

@ -1,13 +1,13 @@
# 项目相关配置
ruoyi:
# 名称
name: RuoYi
name: Nanjing
# 版本
version: 4.3.1
# 版权年份
copyrightYear: 2019
copyrightYear: 2021
# 实例演示开关
demoEnabled: true
demoEnabled: false
# 文件路径 示例( Windows配置D:/ruoyi/uploadPathLinux配置 /home/ruoyi/uploadPath
profile: D:/ruoyi/uploadPath
# profile: /Users/sxile/MyWorkSpase/WorkSpase/uploadPath/RuoYi-SqlServer

@ -1,24 +1,10 @@
Application Version: ${ruoyi.version}
Spring Boot Version: ${spring-boot.version}
////////////////////////////////////////////////////////////////////
// _ooOoo_ //
// o8888888o //
// 88" . "88 //
// (| ^_^ |) //
// O\ = /O //
// ____/`---'\____ //
// .' \\| |// `. //
// / \\||| : |||// \ //
// / _||||| -:- |||||- \ //
// | | \\\ - /// | | //
// | \_| ''\---/'' | | //
// \ .-\__ `-` ___/-. / //
// ___`. .' /--.--\ `. . ___ //
// ."" '< `.___\_<|>_/___.' >'"". //
// | | : `- \`.;`\ _ /`;.`/ - ` : | | //
// \ \ `-. \_ __\ /__ _/ .-` / / //
// ========`-.____`-.___\_____/___.-`____.-'======== //
// `=---=' //
// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ //
// 佛祖保佑 永不宕机 永无BUG //
////////////////////////////////////////////////////////////////////
$$\ $$\ $$$$$$$$\ $$$$$$\ $$\ $$\ $$$$$$\ $$$$$$\
$$$\ $$$ |$$ _____|$$ __$$\ $$$\ $$ |$$ __$$\ $$ __$$\
$$$$\ $$$$ |$$ | $$ / \__|$$$$\ $$ |$$ / $$ |$$ / \__|
$$\$$\$$ $$ |$$$$$\ \$$$$$$\ $$ $$\$$ |$$$$$$$$ |$$ |
$$ \$$$ $$ |$$ __| \____$$\ $$ \$$$$ |$$ __$$ |$$ |
$$ |\$ /$$ |$$ | $$\ $$ |$$ |\$$$ |$$ | $$ |$$ | $$\
$$ | \_/ $$ |$$$$$$$$\ \$$$$$$ |$$ | \$$ |$$ | $$ |\$$$$$$ |
\__| \__|\________| \______/ \__| \__|\__| \__| \______/

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 139 KiB

After

Width:  |  Height:  |  Size: 307 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 142 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.4 KiB

@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="renderer" content="webkit">
<title>若依系统首页</title>
<title>生产线数据采集系统</title>
<!-- 避免IE使用兼容模式 -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link th:href="@{favicon.ico}" rel="shortcut icon"/>
@ -26,7 +26,7 @@
</div>
<a th:href="@{/index}">
<li class="logo hidden-xs">
<span class="logo-lg">RuoYi</span>
<span class="logo-lg">Refresh</span>
</li>
</a>
<div class="sidebar-collapse">
@ -36,19 +36,19 @@
<a class="menuItem noactive" title="个人中心" th:href="@{/system/user/profile}">
<div class="hide" th:text="个人中心"></div>
<div class="pull-left image">
<img th:src="(${user.avatar} == '') ? @{/img/profile.jpg} : @{${user.avatar}}" th:onerror="this.src='img/profile.jpg'" class="img-circle" alt="User Image">
<img th:src="(${user.avatar} == '') ? @{/img/icn.png} : @{${user.avatar}}" th:onerror="this.src='img/icn.png'" class="img-circle" alt="User Image">
</div>
</a>
<div class="pull-left info">
<p>[[${user.loginName}]]</p>
<a href="#"><i class="fa fa-circle text-success"></i> 在线</a>
<!-- <a href="#"><i class="fa fa-circle text-success"></i> 在线</a>-->
<a th:href="@{logout}" style="padding-left:5px;"><i class="fa fa-sign-out text-danger"></i> 注销</a>
</div>
</div>
</li>
<li>
<a class="menuItem" th:href="@{/system/main}"><i class="fa fa-home"></i> <span class="nav-label">首页</span> </a>
</li>
<!-- <li>-->
<!-- <a class="menuItem" th:href="@{/system/main}"><i class="fa fa-home"></i> <span class="nav-label">首页</span> </a>-->
<!-- </li>-->
<li th:each="menu : ${menus}">
<a th:class="@{${menu.url != '' && menu.url != '#'} ? ${menu.target}}" th:href="@{${menu.url == ''} ? |#| : ${menu.url}}">
<i class="fa fa-bar-chart-o" th:class="${menu.icon}"></i>
@ -182,12 +182,12 @@
</a>
</div>
<ul class="nav navbar-top-links navbar-right welcome-message">
<li><a title="视频教程" href="http://doc.ruoyi.vip/ruoyi/document/spjc.html" target="_blank"><i class="fa fa-video-camera"></i> 视频教程</a></li>
<li><a title="开发文档" href="http://doc.ruoyi.vip" target="_blank"><i class="fa fa-question-circle"></i> 开发文档</a></li>
<!-- <li><a title="视频教程" href="http://doc.ruoyi.vip/ruoyi/document/spjc.html" target="_blank"><i class="fa fa-video-camera"></i> 视频教程</a></li>-->
<!-- <li><a title="开发文档" href="http://doc.ruoyi.vip" target="_blank"><i class="fa fa-question-circle"></i> 开发文档</a></li>-->
<li><a title="全屏显示" href="javascript:void(0)" id="fullScreen"><i class="fa fa-arrows-alt"></i> 全屏显示</a></li>
<li class="dropdown user-menu">
<a href="javascript:void(0)" class="dropdown-toggle" data-hover="dropdown">
<img th:src="(${user.avatar} == '') ? @{/img/profile.jpg} : @{${user.avatar}}" th:onerror="this.src='img/profile.jpg'" class="user-image">
<img th:src="(${user.avatar} == '') ? @{/img/icn.png} : @{${user.avatar}}" th:onerror="this.src='img/icn.png'" class="user-image">
<span class="hidden-xs">[[${#strings.defaultString(user.userName, '-')}]]</span>
</a>
<ul class="dropdown-menu">
@ -219,7 +219,7 @@
</button>
<nav class="page-tabs menuTabs">
<div class="page-tabs-content">
<a href="javascript:;" class="active menuTab" th:data-id="@{/system/main}">首页</a>
<a href="javascript:;" class="active menuTab" th:data-id="@{/nanjing/SubStation}">工位管理</a>
</div>
</nav>
<button class="roll-nav roll-right tabRight">
@ -231,11 +231,11 @@
<a id="ax_close_max" class="ax_close_max" href="#" title="关闭全屏"> <i class="fa fa-times-circle-o"></i> </a>
<div class="row mainContent" id="content-main">
<iframe class="RuoYi_iframe" name="iframe0" width="100%" height="100%" th:data-id="@{/system/main}"
th:src="@{/system/main}" frameborder="0" seamless></iframe>
<iframe class="RuoYi_iframe" name="iframe0" width="100%" height="100%" th:data-id="@{/nanjing/SubStation}"
th:src="@{/nanjing/SubStation}" frameborder="0" seamless></iframe>
</div>
<div class="footer">
<div class="pull-right">© [[${copyrightYear}]] RuoYi Copyright </div>
<div class="pull-right">© [[${copyrightYear}]] Copyright </div>
</div>
</div>
<!--右侧部分结束-->

@ -3,8 +3,8 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<title>登录若依系统</title>
<meta name="description" content="若依后台管理框架">
<title>用户登录</title>
<meta name="description" content="生产线数据采集系统">
<link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
<link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
<link href="../static/css/style.css" th:href="@{/css/style.css}" rel="stylesheet"/>
@ -23,27 +23,27 @@
<body class="signin">
<div class="signinpanel">
<div class="row">
<div class="col-sm-7">
<div class="signin-info">
<div class="logopanel m-b">
<h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>
</div>
<div class="m-b"></div>
<h4>欢迎使用 <strong>若依 后台管理系统</strong></h4>
<ul class="m-b">
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> SpringBoot</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Mybatis</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Shiro</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Thymeleaf</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Bootstrap</li>
</ul>
<strong th:if="${@config.getKey('sys.account.registerUser')}">还没有账号? <a th:href="@{/register}">立即注册&raquo;</a></strong>
</div>
</div>
<div class="col-sm-5">
<!-- <div class="col-sm-7">-->
<!-- <div class="signin-info">-->
<!-- <div class="logopanel m-b">-->
<!-- <h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>-->
<!-- </div>-->
<!-- <div class="m-b"></div>-->
<!-- <h4>欢迎使用 <strong>若依 后台管理系统</strong></h4>-->
<!-- <ul class="m-b">-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> SpringBoot</li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Mybatis</li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Shiro</li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Thymeleaf</li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Bootstrap</li>-->
<!-- </ul>-->
<!-- <strong th:if="${@config.getKey('sys.account.registerUser')}">还没有账号? <a th:href="@{/register}">立即注册&raquo;</a></strong>-->
<!-- </div>-->
<!-- </div>-->
<div class="col-sm-7 col-md-offset-2">
<form id="signupForm" autocomplete="off">
<h4 class="no-margins">登录:</h4>
<p class="m-t-md">你若不离不弃,我必生死相依</p>
<h4 class="no-margins">用户登录:</h4>
<!-- <p class="m-t-md">你若不离不弃,我必生死相依</p>-->
<input type="text" name="username" class="form-control uname" placeholder="用户名" value="admin" />
<input type="password" name="password" class="form-control pword" placeholder="密码" value="admin123" />
<div class="row m-t" th:if="${captchaEnabled==true}">
@ -65,7 +65,7 @@
</div>
<div class="signup-footer">
<div class="pull-left">
&copy; 2019 All Rights Reserved. RuoYi <br>
&copy; 2021 All Rights Reserved.<br>
</div>
</div>
</div>

@ -11,13 +11,13 @@
<div class="box box-main">
<div class="box-header">
<div class="box-title">
<i class="fa icon-grid"></i> 组织机构
<i class="fa icon-grid"></i> 工位名称
</div>
<div class="box-tools pull-right">
<a type="button" class="btn btn-box-tool" href="#" onclick="dept()" title="管理部门"><i class="fa fa-edit"></i></a>
<button type="button" class="btn btn-box-tool" id="btnExpand" title="展开" style="display:none;"><i class="fa fa-chevron-up"></i></button>
<button type="button" class="btn btn-box-tool" id="btnCollapse" title="折叠"><i class="fa fa-chevron-down"></i></button>
<button type="button" class="btn btn-box-tool" id="btnRefresh" title="刷新部门"><i class="fa fa-refresh"></i></button>
<!-- <a type="button" class="btn btn-box-tool" href="#" onclick="dept()" title="工位信息"><i class="fa fa-edit"></i></a>-->
<!-- <button type="button" class="btn btn-box-tool" id="btnExpand" title="展开" style="display:none;"><i class="fa fa-chevron-up"></i></button>-->
<!-- <button type="button" class="btn btn-box-tool" id="btnCollapse" title="折叠"><i class="fa fa-chevron-down"></i></button>-->
<button type="button" class="btn btn-box-tool" id="btnRefresh" title="刷新工位"><i class="fa fa-refresh"></i></button>
</div>
</div>
<div class="ui-layout-content">
@ -31,25 +31,26 @@
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<input type="hidden" id="stationId" name="stationId">
<input type="hidden" id="parentId" name="parentId">
<div class="select-list">
<ul>
<li class="select-time">
<label>时间区间: </label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="beginTime"/>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="beginTime" required/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="endTime"/>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="endTime" required/>
</li>
<li>
<label>机种类型:</label>
<select name="productType" th:with="type=${@dict.getType('productType')}">
<option value="">全部</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
<select name="productId" id="product">
<option value="ALL">所有</option>
<option th:each="ls:${list}" th:value="${ls.productID}" th:text="${ls.productName}"></option>
</select>
</li>
<input type="hidden" id="stationId" name="stationId">
<!-- <input type="hidden" id="parentId" name="parentId">-->
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-primary btn-rounded btn-sm" onclick="searchAll()"><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="$.table.exportExcel()" shiro:hasPermission="nanjing:QsProduct:export"><i class="fa fa-download"></i> 导出</a>-->
</li>
@ -74,48 +75,95 @@
panehHidden = true;
}
$('body').layout({ initClosed: panehHidden, west__size: 185 });
queryList();
// queryList();
queryDeptTree();
});
function queryList() {
var options = {
url: prefix + "/list",
exportUrl: prefix + "/export",
modalName: "整机合格率统计",
// function queryList(url) {
// console.log(url);
// var options = {
// // url: url,
// // exportUrl: prefix + "/export",
// modalName: "工位合格率统计",
// columns: [
// {
// field: 'productTp',
// title: '机种类型'
// },
// {
// field: 'inputNum',
// title: '投入量'
// },
// {
// field: 'okNum',
// title: '合格品'
// },
// {
// field:'noNum',
// title:'不合格品'
// },
// {
// field:'ero',
// title:'异常'
// },
// {
// field: 'allRate',
// title: '综合合格率',
// }
// ]
// };
// $.table.init(options);
// }
function searchAll(){
// console.log("点击查询按钮事件执行...");
var url = ctx + "nanjing/StatisticStation/listAll";
// queryList(url);
$('#bootstrap-table').bootstrapTable('destroy');
$('#bootstrap-table').bootstrapTable({
method:"post",
url: url,
pagination: true,
search: true,
contentType : "application/x-www-form-urlencoded",
queryParams: {
begin:$('#startTime').val(),
end:$('#endTime').val()
},
modalName: "工位合格率统计",
columns: [
{
field: 'productTp',
title: '机种类型'
},
{
field: 'inputNum',
title: '投入量'
},
{
field: 'okNum',
title: '合格品'
},
{
field:'noNum',
title:'不合格品'
},
{
field:'ero',
title:'异常'
},
{
field: 'allRate',
title: '综合合格率',
}
{
field: 'productTp',
title: '机种类型'
},
{
field: 'inputNum',
title: '投入量'
},
{
field: 'okNum',
title: '合格品'
},
{
field:'noNum',
title:'不合格品'
},
{
field:'ero',
title:'异常'
},
{
field: 'allRate',
title: '综合合格率',
}
]
};
$.table.init(options);
})
}
function queryDeptTree()
{
var url = ctx + "nanjing/treeData";
// console.log("加载树执行。。。。。。");
var url = ctx + "nanjing/SubStation/treeData";
var options = {
url: url,
expandLevel: 2,
@ -124,11 +172,62 @@
$.tree.init(options);
function zOnClick(event, treeId, treeNode) {
// queryList(prefix + "/list");
console.log("点击节点工位ID"+treeNode.id);
$("#stationId").val(treeNode.id);
// $("#parentId").val(treeNode.pId);
$.table.search();
$("#parentId").val(treeNode.pId);
// $.table.search();
$('#bootstrap-table').bootstrapTable('destroy');
$('#bootstrap-table').bootstrapTable({
method:"post",
url: prefix+"/nodeClick",
pagination: true,
search: true,
contentType : "application/x-www-form-urlencoded",
queryParams:
{
begin:$('#startTime').val(),
end:$('#endTime').val(),
node:$('#stationId').val()
},
modalName: "工位合格率统计",
columns: [
{
field: 'stationCode',
title: '工位代码'
},
{
field: 'stationName',
title: '工位名称'
},
{
field: 'inputNum',
title: '总数量'
},
{
field: 'okNum',
title: '合格数量'
},
{
field:'ero',
title:'异常数量'
},
{
field: 'allRate',
title: '合格率',
}
]
})
}
}
/* 工位信息 */
function dept() {
var url = ctx + "nanjing/SubStation/list";
$.modal.openTab("工位信息", url);
}
$('#btnExpand').click(function() {
$._tree.expandAll(true);
$(this).hide();

@ -2,9 +2,9 @@
# 代码生成
gen:
# 作者
author: ruoyi
author: limy
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
packageName: com.ruoyi.system
packageName: com.ruoyi.nanjing
# 自动去除表前缀默认是false
autoRemovePre: false
# 表前缀(生成类名不会包含表前缀,多个用逗号分隔)

@ -20,10 +20,16 @@ public class QsProduct extends BaseEntity {
private String ero;
@Excel(name = "综合合格率")
private String allRate;
private Date beginTime;
private Date endTime;
private String productType;
//工位合格率统计
private String productId;
private String stationId;
public String getProductTp() {
return productTp;
}

@ -0,0 +1,107 @@
package com.ruoyi.nanjing.domain;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import java.util.Date;
public class QsStation extends BaseEntity {
private static final long serialVersionUID = 1L;
private String stationCode;
private String stationName;
@Excel(name = "总数量")
private String inputNum;
@Excel(name = "合格数量")
private String okNum;
@Excel(name = "异常数量")
private String ero;
@Excel(name = "合格率")
private String allRate;
private Date beginTime;
private Date endTime;
private String productId;
private String stationId;
public String getStationCode() {
return stationCode;
}
public void setStationCode(String stationCode) {
this.stationCode = stationCode;
}
public String getStationName() {
return stationName;
}
public void setStationName(String stationName) {
this.stationName = stationName;
}
public String getInputNum() {
return inputNum;
}
public void setInputNum(String inputNum) {
this.inputNum = inputNum;
}
public String getOkNum() {
return okNum;
}
public void setOkNum(String okNum) {
this.okNum = okNum;
}
public String getEro() {
return ero;
}
public void setEro(String ero) {
this.ero = ero;
}
public String getAllRate() {
return allRate;
}
public void setAllRate(String allRate) {
this.allRate = allRate;
}
public Date getBeginTime() {
return beginTime;
}
public void setBeginTime(Date beginTime) {
this.beginTime = beginTime;
}
public Date getEndTime() {
return endTime;
}
public void setEndTime(Date endTime) {
this.endTime = endTime;
}
public String getProductId() {
return productId;
}
public void setProductId(String productId) {
this.productId = productId;
}
public String getStationId() {
return stationId;
}
public void setStationId(String stationId) {
this.stationId = stationId;
}
}

@ -112,6 +112,16 @@ public class TBdSubstation extends BaseEntity
// @Excel(name = "限制id")
private String LimitID;
public Long getParentId() {
return parentId;
}
public void setParentId(Long parentId) {
this.parentId = parentId;
}
private Long parentId;
/** 图片路径 */
// @Excel(name = "图片路径")
private String ImageUrl;

@ -3,10 +3,7 @@ package com.ruoyi.nanjing.mapper;
import java.util.List;
import java.util.Map;
import com.ruoyi.nanjing.domain.ProRpList;
import com.ruoyi.nanjing.domain.QsProduct;
import com.ruoyi.nanjing.domain.QtProduct;
import com.ruoyi.nanjing.domain.TBdProducttype;
import com.ruoyi.nanjing.domain.*;
/**
* Mapper
@ -34,4 +31,8 @@ public interface TBdProducttypeMapper
List<QsProduct> selectQsProductList(Map map);
List<QsProduct> selectQ1ProductList(Map map);
List<QsStation> selectStationQs(Map map);
List<QsStation> selectAllQs(Map map);
}

@ -33,4 +33,10 @@ public interface ITBdProducttypeService
List<QsProduct> selectQsProductList(Map map);
List<QsProduct> selectQ1ProductList(Map map);
List<QsStation> selectStationQs(QsStation qsStation);
List<QsStation> selectAllQs(Map map);
List<QsStation> selectNodeQs(Map map);
}

@ -1,15 +1,13 @@
package com.ruoyi.nanjing.service.impl;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.ruoyi.nanjing.domain.ProRpList;
import com.ruoyi.nanjing.domain.QsProduct;
import com.ruoyi.nanjing.domain.QtProduct;
import com.ruoyi.nanjing.domain.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.nanjing.mapper.TBdProducttypeMapper;
import com.ruoyi.nanjing.domain.TBdProducttype;
import com.ruoyi.nanjing.service.ITBdProducttypeService;
import com.ruoyi.common.core.text.Convert;
@ -61,4 +59,26 @@ public class TBdProducttypeServiceImpl implements ITBdProducttypeService
public List<QsProduct> selectQ1ProductList(Map map) {
return tBdProducttypeMapper.selectQ1ProductList(map);
}
@Override
public List<QsStation> selectStationQs(QsStation qsStation) {
Map map = new HashMap<String,Object>();
map.put("begin",qsStation.getBeginTime());
map.put("end",qsStation.getEndTime());
map.put("stationType",1);
map.put("stationId",qsStation.getStationId());
map.put("productId",qsStation.getProductId());
List<QsStation> list = tBdProducttypeMapper.selectStationQs(map);
return list;
}
@Override
public List<QsStation> selectAllQs(Map map) {
return tBdProducttypeMapper.selectAllQs(map);
}
@Override
public List<QsStation> selectNodeQs(Map map) {
return tBdProducttypeMapper.selectStationQs(map);
}
}

@ -145,7 +145,7 @@ public class TBdSubstationServiceImpl implements ITBdSubstationService
Ztree ztree = new Ztree();
ztree.setId(substation1.getStationID());
// ztree.setpId(substation1.getParentId());
ztree.setpId(substation1.getParentId());
ztree.setName(substation1.getStationName());
ztree.setTitle(substation1.getStationName());
if (isCheck)

@ -42,6 +42,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="ero" column="异常"/>
<result property="allRate" column="综合合格率"/>
</resultMap>
<resultMap id="qsStation" type="com.ruoyi.nanjing.domain.QsStation">
<result property="stationCode" column="工位代码"/>
<result property="stationName" column="工位名称"/>
<result property="inputNum" column="总数量"/>
<result property="okNum" column="合格数量"/>
<result property="ero" column="异常数量"/>
<result property="allRate" column="合格率"/>
</resultMap>
<sql id="selectTBdProducttypeVo">
select ID, ProductTypeID, ProductTypeName from T_BD_ProductType
</sql>
@ -108,6 +117,31 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
}
</select>
<select id="selectStationQs" parameterType="map" statementType="CALLABLE" resultMap="qsStation">
{
call pro_StationQStatistic
(
#{beginTime,mode=IN,jdbcType=DATE},
#{endTime,mode=IN,jdbcType=DATE},
#{stationType,mode=IN,jdbcType=VARCHAR},
#{stationId,mode=IN,jdbcType=VARCHAR},
#{productId,mode=IN,jdbcType=VARCHAR}
)
}
</select>
<select id="selectAllQs" parameterType="map" statementType="CALLABLE" resultMap="qsProduct">
{
call pro_StatisticOfProductQRate
(
#{begin,mode=IN,jdbcType=DATE},
#{end,mode=IN,jdbcType=DATE},
#{productId,mode=IN,jdbcType=VARCHAR},
#{productType,mode=IN,jdbcType=VARCHAR}
)
}
</select>
<!-- <insert id="insertTBdProducttype" parameterType="TBdProducttype">-->
<!-- insert into T_BD_ProductType-->

Loading…
Cancel
Save