Commit dac1e258 authored by 李苏's avatar 李苏 💬

加工反馈

parent 3e6c80e9
......@@ -12,6 +12,12 @@
#kwrkb01 li{
font-size: 14px;
}
#jgfkkb div{
font-size: 14px;
}
#jgfkkb li{
font-size: 14px;
}
#kwrkb02 div{
font-size: 14px;
}
......@@ -383,3 +389,124 @@
width: 25%;
height: 100%;
}
#jgfkkb {
height: 100%;
width: 100%;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-items: stretch
}
#jgfkkb div {
box-sizing: border-box;
}
#jgfkkb .toptitle {
height: 50px;
width: 100%;
background-color: #00aaff;
color: #FFFFFF;
text-align: center;
line-height: 50px;
}
#jgfkkb .left {
height: calc(100% - 60px);
width: 40%;
}
#jgfkkb .right {
height: calc(100% - 60px);
width: calc(60% - 10px);
border: #EEEEEE 1px solid;
}
#jgfkkb .rightPdf {
height: 100%;
width: 100%;
}
#jgfkkb .cbinfor {
width: 100%;
height: 40%;
}
#jgfkkb .tab {
width: 100%;
height: 60%;
padding-top: 10px;
}
#jgfkkb .cpif {
width: 100%;
height: 50%;
border: 1px solid #EEEEEE;
}
#jgfkkb .cprz {
width: 100%;
height: 50%;
border: 1px solid #EEEEEE;
}
#jgfkkb .cpiftop {
width: 100%;
height: 40px;
border-bottom: 1px solid #EEEEEE;
line-height: 40px;
display: flex;
justify-content: center;
}
#jgfkkb .cpifbot {
height: calc(100% - 40px);
}
#jgfkkb .ery {
width: 50%;
height: 50%;
display: flex;
align-items: center;
}
#jgfkkb .ery span {
padding-left: 20px;
display: inline-block;
width: 70px;
}
#jgfkkb .tipul>li {
width: 150px;
padding-left: 20px;
float: left;
line-height: 50px;
}
#jgfkkb .tipuli2 {
float: right !important;
}
#jgfkkb .maintab {
height: 100%;
width: 100%;
overflow: hidden;
border: 0.5px solid #EEEEEE;
}
#jgfkkb .showtab {
height: 100%;
width: 100%;
}
.easyuitext{
padding-left: 10px;
height: 30px;
border: 0.5px solid #D3D3D3;
}
#jgfkkb .wid70{
width: 70%;
}
#jgfkkb .n-item {background:rgb(57, 52, 86);}
#jgfkkb .ok-item {background:-webkit-gradient(linear, left top, right top, from(#42d79b), to(#a6e25f));background:linear-gradient(90deg, #42d79b, #a6e25f);}
#jgfkkb .nok-item {background:-webkit-gradient(linear, left top, right top, from(#ff0000), to(#ff007f));background:linear-gradient(90deg, #ff0000, #ff007f);}
\ No newline at end of file
......@@ -182,16 +182,7 @@
function jyfk_pdfshow(e,woid){
let that=e
let newpdfurl=pdfUr+"/"+woid+"/"+window.bzlx
// that.pdf=""
// if (newpdfurl!=that.pdfurl){
// that.pdfurl=newpdfurl
// if(that.sivpdf){
// clearInterval(that.sivpdf)
// }
// pdfshow(that.pdfurl, that.pdfdom, 10000).then(e => {
// that.sivpdf = e
// })
// }
/* 作废 */
}
</script>
......
......@@ -27,24 +27,6 @@
</div>
</div>
<script type="text/javascript">
$("#btnqh").click(function(){
if($("#kwrkb01").css("display")=="flex"){
$("#kwrkb01").css("display","none")
$("#kwrkb02").css("display","flex")
$("#kwrkb03").css("display","none")
}else if($("#kwrkb02").css("display")=="flex"){
$("#kwrkb01").css("display","none")
$("#kwrkb02").css("display","none")
$("#kwrkb03").css("display","flex")
}else{
$("#kwrkb01").css("display","flex")
$("#kwrkb02").css("display","none")
$("#kwrkb03").css("display","none")
}
})
/* 取登录值 */
/* 通用代码 */
......@@ -65,7 +47,7 @@
}
/* 通用表格参数 */
var zpfk_columns=[
var jgfk_columns=[
[{
field: 'wlxxCode',
title: '品号',
......@@ -99,68 +81,72 @@
]
]
/* 初始化工序 */
function zpfk_getgx(e){
function jgfk_getgx(e){
let that=e
that.gx=window.gxname||"获取失败"
}
/* 获取计数 */
function zpfk_apigetjs(s){
function jgfk_apigetjs(s){
let that=s
gas.post('kmes/gpfk/getDailyInfo',{}, function(res){
if(res.data&&res.data.records){
that.fksl=res.data.records.fksl||0
}else{
let msg=res.message||"当前计数获取失败"
zpfk_wrz(that,msg,'error')
jgfk_wrz(that,msg,'error')
}
});
}
/* 重查 */
function zpfk_showzpfk(e){
let that=e
that.okOrng=""//ok标记
gas.post('kmes/gpfk/zpfk',{"sncode":that.wosncode||"","bzgxid":window.bzlx||"","wosncode":that.wosncode||""}, function(res){
if(res.data&&res.data.records){
/* 赋值操作 */
that.okOrng=res.data.records.zpbz||""
that.xlh=""
}else{
}
});
}
/* !new zpfk接口获取信息*/
function zpfk_apizpfk(e){
// function jgfk_showjgfk(e){
// let that=e
// that.okOrng=""
// gas.post('kmes/gpfk/jgfk',{"sncode":that.wosncode||"","bzgxid":window.bzlx||"","wosncode":that.wosncode||""}, function(res){
// if(res.data&&res.data.records){
// that.okOrng=res.data.records.zpbz||""
// that.xlh=""
// }else{
// }
// });
// }
/* !new jgfk接口获取信息*/
function jgfk_apijgfk(e){
let that=e
that.okOrng=""//ok标记
that.isok=""//ok标记
return new Promise(function(y,n){
gas.post('kmes/gpfk/zpfk',{"sncode":that.xlh,"bzgxid":window.bzlx||"","wosncode":that.wosncode||""}, function(res){
gas.post('kmes/gpfk/jgfk',{"sncode":that.xlh,"bzgxid":window.bzlx||"","wosncode":that.wosncode||""}, function(res){
if(res.data&&res.data.records){
/* 赋值操作 */
that.hg= res.data.records.hgsl||0;
that.ng= res.data.records.bhgsl||0;
that.gd = res.data.records.woDjid;
that.cpsn = res.data.records.wosnCode;
that.ph = res.data.records.wlxxCode;
let woid = res.data.records.woid;
that.fkid=res.data.records.id||""
that.okOrng=res.data.records.zpbz||""
let woid = res.data.records.woDjid;
that.fkid = res.data.records.id;
y(woid)
/** wobom查询 **/
if(res.data.records.sntype=="WOSNID")
{
that.wosncode=that.xlh
let msg=res.message||"查询WOSNID:"+that.wosncode+"成功"
zpfk_wrz(that,msg)
}else if(res.data.records.sntype=="WLID"){
let msg=res.message||"当前装配SN:"+that.wosncode+";品号"+res.data.records.curwlsncode+";品名"+res.data.records.curwlsnname+"成功!"
zpfk_wrz(that,msg)
zpfk_showzpfk(that)
jgfk_wrz(that,msg)
}else if(res.data.records.sntype=="OKBZ"){
that.isok="OK"
that.hg=res.data.records.hgsl||0;
that.ng=res.data.records.bhgsl||0;
}else if(res.data.records.sntype=="NGBZ"){
that.isok="NG"
that.hg=res.data.records.hgsl||0;
that.ng=res.data.records.bhgsl||0;
}
that.xlh=""
y(woid)
/** wobom查询 **/
/* 日志操作 */
/* pdf地址 */
}else{
let msg=res.message||"查询:"+that.xlh+"失败"
let msg=res.message||"查询该序列号:"+that.xlh+"失败"
that.xlh=""
zpfk_wrz(that,msg,'error')
jgfk_wrz(that,msg,'error')
screenAlert(that.el,msg,2000)
}
});
......@@ -168,41 +154,40 @@
}
/* new整体封装 */
function zpfk_zpfk(t){
function jgfk_jgfk(t){
let that=t
if(that.xlh=="logout")
{
zpfk_wrz(that,"即将退出系统")
jgfk_wrz(that,"即将退出系统")
localStorage.clear();
window.location.href ="loginscan_view";
return
}
zpfk_apigetjs(that)
zpfk_apizpfk(that).then(function(s){
zpfk_queryWoBomByWoid(that,s)
zpfk_pdfshow(that,s)
jgfk_apigetjs(that)
jgfk_apijgfk(that).then(function(s){
jgfk_queryWoBomByWoid(that,s)
})
//
}
/* wobom查询 .then(e=>执行) */
function zpfk_queryWoBomByWoid(e,woid){
function jgfk_queryWoBomByWoid(e,woid){
let that=e
that.xlh=""
gas.post('kmes/gpfk/queryWoBomByWoid',{"woid":woid,"wosn":that.cpsn,"bzlx":window.bzlx}, function(res){
if(res.data&&res.data.records){
// let msg="查询装配表格:"+woid+"成功"
// zpfk_wrz(that,msg)
// jgfk_wrz(that,msg)
that.tabdata = res.data.records;
that.initpage()
}else{
let msg=res.message||"查询装配表格:"+woid+"失败"
// zpfk_wrz(that,msg,'error')
// jgfk_wrz(that,msg,'error')
screenAlert(that.el,msg,2000)
}
});
}
/* pdfshow gxid登录页传进来 */
function zpfk_pdfshow(e,woid){
function jgfk_pdfshow(e,woid){
console.log("pdf")
let that=e
let newpdfurl=pdfUr+"/"+woid+"/"+window.bzlx
......@@ -219,7 +204,7 @@
}
}
/* 初始化表格 */
function zpfk_pageinit(q){
function jgfk_pageinit(q){
let that=q
let $tab = $(that.el).find('.showtab')
that.$tab=$tab
......@@ -232,13 +217,13 @@
// return 'background-color:#6293BB;color:#fff;';
// }
// },
columns:zpfk_columns,
columns:jgfk_columns,
data: that.tabdata
}
$tab.datagrid(that.taboptions);
}
/* 时间 */
function zpfk_pagetime(w){
function jgfk_pagetime(w){
let that=w
let nowtime
nowtime=new Date().getTime()
......@@ -249,7 +234,7 @@
},20000)
}
/* 日志事件汇总,写在请求内部或者单独拿出 */
function zpfk_wrz(o,msg,type){
function jgfk_wrz(o,msg,type){
let that=o
if(type!='error'){
$(that.el).find(".rz").append("<br>>" + "<span>" +msg+"</sapn>")
......@@ -259,14 +244,14 @@
$(that.el).find(".rz").append("<br>>" + "<span style='color: red;'>" +msg+"</sapn>")
that.addtop = that.addtop + 600
$(that.el).find(".rz").scrollTop(that.addtop)
that.okOrng='NG'
// that.okOrng='NG'
}
/* this.xlh="" */
}
/* 弹框封装 */
</script>
<div id="kwrkb01">
<div id="jgfkkb">
<!-- 顶部信息条 -->
<div class="toptitle">
<ul class="tipul" style="height: 100%;">
......@@ -281,8 +266,8 @@
<!-- 左侧信息条 -->
<div class="left" style="width: 30%;">
<!-- 左上信息表 -->
<div class="cbinfor">
<div class="cpif">
<div class="cbinfor" style="height: 50%;">
<div class="cpif" style="height: 40%;">
<!-- top -->
<div class="cpiftop" style="display: flex;align-items: center;">
<span>序列号&nbsp;&nbsp;</span><input style="width: 84%;" class="easyuitext" name="xlh" @keydown="scanxlh()" v-model="xlh" placeholder="请扫码条码" />
......@@ -304,22 +289,30 @@
</div>
</div>
<!-- 日志 -->
<div class="cprz">
<div class="cprz" style="height: 60%;">
<div class="cardList-wrapper" style="width: 100%;height: 20%;background-color: #FFFFFF;color: #FFFFFF;display: flex;flex-wrap: wrap;justify-content:space-around;align-items: center;">
<div class="" style="height: 100%;width: 50%;display: flex;align-items: center;justify-content: center;color: #FFFFFF;background-color: #00AAFF!important;">
<span style="font-size: 20px;font-weight: 800;">合格数量:{{hg}}</span>
</div>
<div class="" style="height: 100%;width: 50%;display: flex;align-items: center;justify-content: center;color: #FFFFFF;background-color: #FEC041!important;">
<span style="font-size: 20px;font-weight: 800;">NG数量:{{ng}}</span>
</div>
</div>
<div style="height: 20px;line-height: 20px;background-color: grey;color: white;text-align: center;">
日志
</div>
<div style="height: calc(100% - 20px);display: flex;">
<div style="height: calc(80% - 20px);display: flex;">
<div class="rz" style="width: 80%;height: 100%;background-color: #393456;color: #FFFFFF;overflow: auto;">
</div>
<div :class="{'ok-item' : okOrng=='OK','nok-item' : okOrng=='NG','n-item': okOrng!='OK'&&okOrng!='NG'}"
<div :class="{'ok-item' : isok=='OK','nok-item' : isok=='NG','n-item': isok!='OK'&&isok!='NG'}"
style="width: 20%;height: 100%;color: white;display: flex;align-items: center;justify-content: center;font-size: 30px;">
<b>{{okOrng}}</b>
<b>{{isok}}</b>
</div>
</div>
</div>
</div>
<!-- 左下表格 -->
<div class="tab">
<div class="tab" style="height:50%;">
<div class="maintab">
<table class="showtab">
......@@ -329,7 +322,7 @@
</div>
<!-- 右侧信息pdf -->
<div class="right" style="width: 45%;">
<canvas id="kwrkb01pdf" class="rightPdf"></canvas>
<canvas id="jgfkkbpdf" class="rightPdf"></canvas>
</div>
<!-- new右侧 -->
<div class="right" style="width: 25%;">
......@@ -338,157 +331,18 @@
</video>
</div>
<div ref="scrollmain" style="height: 50%;overflow: auto;border-bottom: 1px solid #EEEEEE;">
<canvas id="kwrkb01rpdf" ref="scroll" style="width: 100%;height: 160%;" ></canvas>
</div>
</div>
<canvas id="jgfkkbrpdf" ref="scroll" style="width: 100%;height: 160%;" ></canvas>
</div>
<!-- div2 -->
<div id="kwrkb02" style="display: none;">
<!-- 顶部信息条 -->
<div class="toptitle" style="position: relative;">
<ul style="position: absolute;right: 50%;transform: translateX(50%);">
<li class="tipulmid"></li>
<li class="tipulmid" style="width: 130px;">{{username}}</li>
<li class="tipulmid">甲班</li>
<li class="tipulmid" style="width: 200px;">当前工序:{{gx}}</li>
</ul>
<ul class="tipul" style="height: 100%;width: 100%;">
<li style="width: 400px;">
<input class="easyuitext" style="width: 250px;" @keydown="scanxlh()" placeholder="请扫码条码" name="xlh" v-model="xlh" />
<button type="button" ><b style="color: #666666;font-style:oblique;">SUBMIT</b></button>
</li>
<li class="tipuli2" style="width: 250px;">{{systime}}</li>
<li class="tipuli2" style="margin-right: 10px;">计数: <span style="font-size: 16px;">{{fksl}}</span></li>
</ul>
</div>
<!-- 左侧信息条 -->
<div class="left">
<!-- 左上信息表 -->
<div class="cbinfor">
<div class="cpif">
<!-- top -->
<div class="cpileft" style="width: 70%;height: 100%;">
<div class="ery">
<span>工单</span><input class="easyuitext" v-model="gd" style="width: 70%;" name="gd" />
</div>
<div class="ery">
<span>SN</span><input class="easyuitext" v-model="cpsn" style="width: 70%" name="cpsn" />
</div>
<div class="ery">
<span>品号</span><input class="easyuitext" v-model="ph" style="width: 70%" name="ph" />
</div>
</div>
<div class="cpiright" style="width: 30%;height: 100%;padding: 10px;">
<div
:class="{'ok-item' : okOrng=='OK','nok-item' : okOrng=='NG','n-item': okOrng!='OK'&&okOrng!='NG'}"
style="width: 100%;height: 100%;background-color: #1890FF;color: white;display: flex;align-items: center;justify-content: center;font-size: 30px;">
<b>{{okOrng}}</b>
</div>
</div>
<!-- bot -->
</div>
<!-- 日志 -->
<div class="cprz" >
<div style="height: 20px;line-height: 20px;background-color: grey;color: white;text-align: center;">
日志
</div>
<div style="height: calc(100% - 20px);display: flex;">
<div class="rz" style="width: 100%;height: 100%;background-color: #393456;color: #FFFFFF;overflow: auto;">
</div>
</div>
</div>
</div>
<!-- 左下表格 -->
<div class="tab">
<div class="maintab">
<table class="showtab">
</table>
</div>
</div>
</div>
<!-- 右侧信息pdf -->
<div class="right">
<canvas id="kwrkb02pdf" class="rightPdf"></canvas>
</div>
</div>
<!-- 界面3 -->
<div id="kwrkb03" style="display: none;">
<!-- 顶部信息条 -->
<div class="toptitle" style="position: relative;">
<ul class="tipul" style="height: 100%;width: 100%;">
<li class="tipulmid">ADMIN</li>
<li class="tipulmid">{{username}}</li>
<li class="tipulmid">甲班</li>
<li class="tipuli2" style="width: 250px;">{{systime}}</li>
<li class="tipuli2" style="margin-right: 10px;">计数: <span style="font-size: 16px;">{{fksl}}</span></li>
<li class="tipuli2" style="margin-right: 10px;">当前工序:{{gx}}</li>
</ul>
</div>
<!-- 标题下信息 -->
<div class="titdow" style="width: 100%;height: 35px;display: flex;">
<div class="titdowinfor" style="padding-left: 10px;">
<input class="easyuitext" style="width:70%" placeholder="扫描条码" name="xlh" @keydown="scanxlh()" v-model="xlh" />
<button type="button" ><b style="color: #666666;font-style:oblique;">SUBMIT</b></button>
</div>
<div class="titdowinfor">
<span>工单</span><input class="easyuitext" style="width:70%" name="gd" v-model="gd" />
</div>
<div class="titdowinfor">
<span>SN</span><input class="easyuitext" style="width:70%" name="cpsn" v-model="cpsn" />
</div>
<div class="titdowinfor">
<span>品号</span><input class="easyuitext" style="width:70%" name="ph" v-model="ph" />
</div>
</div>
<!-- 左侧信息条 -->
<div class="left">
<!-- 左上信息表 -->
<div class="cbinfor">
<!-- 日志 -->
<div class="cprz" style="position: relative;">
<div class="cpiright" style="width:30%;height: 50%;padding: 10px;position: absolute;right: 0px;top: 20px;">
<div
:class="{'ok-item' : okOrng=='OK','nok-item' : okOrng=='NG','n-item': okOrng!='OK'&&okOrng!='NG'}"
style="width: 100%;height: 100%;background-color: #1890FF;color: white;display: flex;align-items: center;justify-content: center;font-size: 30px;">
<b>{{okOrng}}</b>
</div>
</div>
<div style="height: 20px;line-height: 20px;background-color: grey;color: white;text-align: center;">
日志
</div>
<div style="height: calc(100% - 20px);display: flex;">
<div class="rz" style="width: 100%;height: 100%;background-color: #393456;color: #FFFFFF;overflow: auto;">
</div>
</div>
</div>
</div>
<!-- 左下表格 -->
<div class="tab">
<div class="maintab">
<table class="showtab">
</table>
</div>
</div>
</div>
<!-- 右侧信息pdf -->
<div class="right">
<canvas id="kwrkb03pdf" class="rightPdf"></canvas>
</div>
</div>
<script type="text/javascript">
let Vkwrkb01 = new Vue({
el: "#kwrkb01",
let Vjgfkkb = new Vue({
el: "#jgfkkb",
mounted() {
zpfk_getgx(this)
jgfk_getgx(this)
this.initpage()
dbenlarge('kwrkb01', 1, this.initpage)
dbenlarge('jgfkkb', 1, this.initpage)
$(this.el).dblclick()
this.scroll()
this.gettime()
......@@ -504,12 +358,14 @@
},
data: function() {
return {
ng:0,
hg:0,
urlm:urlm,
fksl:0,
username:localStorage.getItem("username"),
okOrng:"",
pdfdom:"kwrkb01pdf",
el:"#kwrkb01",
isok:"",
pdfdom:"jgfkkbpdf",
el:"#jgfkkb",
pdfurl:"kmes/gpfk/queryPdfByWoidAndZpgx",
addtop:0,
xlh:"",
......@@ -529,13 +385,12 @@
},
methods: {
scroll(){
console.log(urlo)
/* test */
pdfshow(urlo,'kwrkb01pdf', 10000).then(e => {
pdfshow(urlo,'jgfkkbpdf', 10000).then(e => {
that.sivpdf = e
})
/* test */
pdfshow(urlt,'kwrkb01rpdf', 10000).then(e => {
pdfshow(urlt,'jgfkkbrpdf', 10000).then(e => {
that.sivrpdf = e
})
const mainData=this.$refs.scrollmain
......@@ -550,7 +405,7 @@
// 扫码接口
apiscanxlh(){
let that=this
zpfk_zpfk(that)
jgfk_jgfk(that)
},
isFocus(){
let $xlh=$(this.el).find('input[name="xlh"]')
......@@ -566,179 +421,21 @@
// 初始化页面
initpage() {
let that=this
zpfk_pageinit(that)
jgfk_pageinit(that)
},
/* 展示时间 */
gettime() {
let that = this
zpfk_pagetime(that)
jgfk_pagetime(that)
},
appdestory() {
let that = this
this.sivdestory = setInterval(function() {
if (!$("#kwrkb01").height()) {
Vkwrkb01.$destroy()
if (!$("#jgfkkb").height()) {
Vjgfkkb.$destroy()
}
}, 3000)
}
}
})
/* 示例2 */
let Vkwrkb02= new Vue({
el:"#kwrkb02",
mounted() {
zpfk_getgx(this)
// $(this.el).hide()
dbenlarge('kwrkb02',1,this.initpage)
// this.sivpdf=
this.initpage()
this.gettime()
this.appdestory()
},
destroyed() {
clearInterval(this.sivdestory)
clearInterval(this.sivpdf)
clearInterval(this.sivtimer)
},
data:function(){
return{
fksl:0,
username:localStorage.getItem("username"),
okOrng:"N",
pdfdom:"kwrkb02pdf",
el:"#kwrkb02",
pdfurl:"kmes/gpfk/queryPdfByWoidAndZpgx",
addtop:0,
xlh:"",
gx:"",
gd:"",
cpsn:"",
ph:"",
systime: "",
tabdata: [
],
sivtimer: null, //时间计数器
sivpdf: null,
sivdestory: null,
}
},
methods:{
isFocus(){
let $xlh=$(this.el).find('input[name="xlh"]')
$xlh.focus()
},
// 扫码接口
apiscanxlh(){
let that=this
zpfk_zpfk(that)
},
// 扫码事件
scanxlh(e){
var evt = window.event || e;
if (evt.keyCode == 13) {
this.apiscanxlh()
$("#kwrkb02").find(".rz").append("<br>>" + "<span>" +"正在查询:"+this.xlh+"</sapn>")
this.addtop = this.addtop + 600
$("#kwrkb02").find(".rz").scrollTop(this.addtop)
/* this.xlh="" */
}
},
// 初始化页面
initpage() {
let that=this
zpfk_pageinit(that)
},
/* 展示时间 */
gettime(){
let that = this
zpfk_pagetime(that)
},
appdestory(){
let that=this
this.sivdestory=setInterval(function(){
if(!$("#kwrkb02").height()){
Vkwrkb02.$destroy()
}
},3000)
}
}
})
let Vkwrkb03= new Vue({
el:"#kwrkb03",
mounted() {
zpfk_getgx(this)
dbenlarge('kwrkb03',1,this.initpage)
// this.sivpdf=
this.initpage()
this.gettime()
this.appdestory()
},
destroyed() {
clearInterval(this.sivdestory)
clearInterval(this.sivpdf)
clearInterval(this.sivtimer)
},
data:function(){
return{
fksl:0,
username:localStorage.getItem("username"),
okOrng:"N",
pdfdom:"kwrkb03pdf",
el:"#kwrkb03",
pdfurl:"kmes/gpfk/queryPdfByWoidAndZpgx",
addtop:0,
xlh:"",
gx:"",
gd:"",
cpsn:"",
ph:"",
systime: "",
tabdata: [
],
sivtimer: null, //时间计数器
sivpdf: null,
sivdestory: null,
}
},
methods:{
isFocus(){
let $xlh=$(this.el).find('input[name="xlh"]')
$xlh.focus()
},
// 扫码接口
apiscanxlh(){
let that=this
zpfk_zpfk(that)
},
// 扫码事件
scanxlh(e){
var evt = window.event || e;
if (evt.keyCode == 13) {
this.apiscanxlh()
$("#kwrkb03").find(".rz").append("<br>>" + "<span>" +"正在查询:"+this.xlh+"</sapn>")
this.addtop = this.addtop + 600
$("#kwrkb03").find(".rz").scrollTop(this.addtop)
/* this.xlh="" */
}
},
// 初始化页面
initpage(){
let that=this
zpfk_pageinit(that)
},
/* 展示时间 */
gettime(){
let that = this
zpfk_pagetime(that)
},
appdestory(){
let that=this
this.sivdestory=setInterval(function(){
if(!$("#kwrkb03").height()){
Vkwrkb03.$destroy()
}
},3000)
}
}
})
</script>
<div id="kmesGpfkindex" class="gui-div">
<table class="toolbar-table" data-options="id: 'kmesGpfkindexTable',herf:'kzzx/gridset/query'"></table>
<div id="kmesJgfkindex" class="gui-div">
<table class="toolbar-table" data-options="id: 'kmesJgfkindexTable',herf:'kzzx/gridset/query'"></table>
<!-- 表格工具栏开始 -->
<div id="kmesGpfkindexTable-toolbar" class="gui-toolbar" data-options="grid:{type:'datagrid',id:'kmesGpfkindexTable'}">
<div id="kmesJgfkindexTable-toolbar" class="gui-toolbar" data-options="grid:{type:'datagrid',id:'kmesJgfkindexTable'}">
<div class="navbar-toolbar">
<a class="toolbar-print toolbar" href="javascript:void(0)"></a>
<a class="toolbar-export toolbar" href="javascript:void(0)"></a>
......@@ -57,7 +57,7 @@
<script>
$(function () {
/*js初始化*/
var $div=$('#kmesGpfkindex');
var $div=$('#kmesJgfkindex');
var $datagrid=$div.find(".toolbar-table");
var $datStart=$div.find("input[name='start']");
var $datEnd=$div.find("input[name='end']");
......@@ -77,7 +77,7 @@
$txtScgd.iTextbox();
$txtWosnid.iTextbox();
var options = {
url: 'kmes/gpfk',
url: 'kmes/jgfk',
noRequest: true,
columns: [[
{title: "产品条码", field: "wosnid", fieldType: "ftString",width:160},
......@@ -109,7 +109,7 @@
]],
dialog: {
footerIn: true,
href: 'kmes/gpfk/edit',
href: 'kmes/jgfk/edit',
maximized:true,
width:1080,
height:640,
......@@ -146,7 +146,7 @@
};
$div.Holder(options);
$("#kmesGpfkindexTable-toolbar").find(".toolbar-cancelzp").iMenubutton({
$("#kmesJgfkindexTable-toolbar").find(".toolbar-cancelzp").iMenubutton({
event:'doAjax',
text:'取消装配',
onClick:function () {
......@@ -157,7 +157,7 @@
}
gas.confirm("是否执行该操作",function () {
var index=$div.find('.toolbar-table').datagrid("getRowIndex",selectedRow);
HTTP.post('kmes/gphy/delGpzp',{gpfkid:selectedRow.id},function (result) {
HTTP.post('kmes/gphy/delGpzp',{jgfkid:selectedRow.id},function (result) {
if(result['success']){
$div.find('.toolbar-table').datagrid("deleteRow",index);
$.messager.alert('提示','取消装配成功!');
......@@ -170,7 +170,7 @@
}
});
$("#kmesGpfkindexTable-toolbar").find(".toolbar-search1").iMenubutton({
$("#kmesJgfkindexTable-toolbar").find(".toolbar-search1").iMenubutton({
text:'搜索',
iconCls:"fa fa-search",
btnCls:"",
......@@ -192,10 +192,7 @@
}
/*用户操作*/
function run(res){
$bzgxid.iCombobox({valueField: "id", textField: "name", allowNull:false,required:true,allowEdit:false, url: 'gygl/bzgx/queryZpBzgx',onSelect:function (a) {
// $dialog.find("input[name='gxName']").val(a.name);
// $dialog.find("input[name='gzzxid']").val(a.gzzxid||'');
// $dialog.find("input[name='gzzxname']").val(a.gzzxname||'')
$bzgxid.iCombobox({valueField: "id", textField: "name", allowNull:false,required:true,allowEdit:false, url: 'gygl/bzgx/queryJgBzgx',onSelect:function (a) {
gxName=a.name||""
gzzxid=a.gzzxid||""
gzzxname=a.gzzxname||""
......@@ -208,31 +205,6 @@
return datas
}
})
// gas.Dialog({
// title:"选择工序",
// width:480,
// height:280,
// minimizable:false,
// maximizable:false,
// href:"kmes/gphy/gx",
// onInit:function (element) {
// },
// regResultHandler:function (element) {
// if(!element.form("validate")){
// return false
// }
// var data=DataBind.collectData(element);
// $div.find("input[name='bxid']").val(data.bxid||"");
// $div.find("input[name='bzgxid']").val(data.gxid||"");
// $div.find("input[name='fkrid']").val(window.sessionStorage.getItem('userId'));
// fkrName=window.sessionStorage.getItem('userName');
// gxName=data.gxName||"";
// gzzxid=data.gzzxid||'';
// gzzxname=data.gzzxname||"";
// $datagrid.datagrid("options").url="kmes/gpfk/query";
// $datagrid.datagrid("load",DataBind.collectData($div))
// }
// })
}
gas.load(paramsInit,pageInit,dataInit,run);
......
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