|
@@ -10,7 +10,7 @@
|
|
|
<p class="p">扫码</p>
|
|
|
</button>
|
|
|
<button type="primary" @click="getMachine(coding)" class="button1">
|
|
|
- <p class="p">确认</p>
|
|
|
+ <p class="p">获取</p>
|
|
|
</button>
|
|
|
</view>
|
|
|
<view class="bodyname">
|
|
@@ -31,8 +31,24 @@
|
|
|
<p class="p">确认</p>
|
|
|
</button>
|
|
|
</view>
|
|
|
+ <view class="body">
|
|
|
+ 订单编号:<input class="input" name="orderNo" :value="orderNo" />
|
|
|
+ <button type="primary" form-type="submit" class="button1">
|
|
|
+ <p class="p">确认</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
+ <view class="body">
|
|
|
+ 客户编号:<input class="input" name="customerNo" :value="customerNo" />
|
|
|
+ <button type="primary" form-type="submit" class="button1">
|
|
|
+ <p class="p">确认</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
</form>
|
|
|
<view class="line"></view>
|
|
|
+ <view class="">
|
|
|
+ <uni-list-item title="添加工序" @click="gongxu()" />
|
|
|
+ </view>
|
|
|
+ <view class="line"></view>
|
|
|
<form @submit="jike" @reset="jikeReset">
|
|
|
<view class="modules">
|
|
|
<view class="title">机壳</view>
|
|
@@ -123,6 +139,66 @@
|
|
|
</view>
|
|
|
</form>
|
|
|
<view class="line"></view>
|
|
|
+ <form @submit="anzhuoping" @reset="anzhuopingReset">
|
|
|
+ <view class="modules">
|
|
|
+ <view class="title">安卓屏</view>
|
|
|
+ <view class="body">
|
|
|
+ <input class="input" style="display:none;" name="anzhuopingCoding" :value=anzhuopingCoding />
|
|
|
+ 编码:<input class="input" v-model="anzhuopingCoding" />
|
|
|
+ <button type="primary" @click="saoma('anzhuopingCoding')" class="button1">
|
|
|
+ <p class="p">扫码</p>
|
|
|
+ </button>
|
|
|
+ <button type="primary" @click="getMessage(anzhuopingCoding)" class="button1">
|
|
|
+ <p class="p">获取</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
+ <view class="body">
|
|
|
+ 名称:<input class="input" name="anzhuopingName" :value="anzhuopingName" />
|
|
|
+ </view>
|
|
|
+ <view class="body">
|
|
|
+ 版本:<input class="input" name="anzhuopingVersion" :value="anzhuopingVersion" />
|
|
|
+ </view>
|
|
|
+ <view class="modulesButton">
|
|
|
+ <button type="primary" form-type="submit" class="button1">
|
|
|
+ <p class="p">确认</p>
|
|
|
+ </button>
|
|
|
+ <button type="primary" @click="updateModules(anzhuopingCoding,'anzhuoping')" class="button1">
|
|
|
+ <p class="p">更换</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </form>
|
|
|
+ <view class="line"></view>
|
|
|
+ <form @submit="plc" @reset="plcReset">
|
|
|
+ <view class="modules">
|
|
|
+ <view class="title">plc</view>
|
|
|
+ <view class="body">
|
|
|
+ <input class="input" style="display:none;" name="plcCoding" :value=plcCoding />
|
|
|
+ 编码:<input class="input" v-model="plcCoding" />
|
|
|
+ <button type="primary" @click="saoma('plcCoding')" class="button1">
|
|
|
+ <p class="p">扫码</p>
|
|
|
+ </button>
|
|
|
+ <button type="primary" @click="getMessage(plcCoding)" class="button1">
|
|
|
+ <p class="p">获取</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
+ <view class="body">
|
|
|
+ 名称:<input class="input" name="plcName" :value="plcName" />
|
|
|
+ </view>
|
|
|
+ <view class="body">
|
|
|
+ 版本:<input class="input" name="plcVersion" :value="plcVersion" />
|
|
|
+ </view>
|
|
|
+ <view class="modulesButton">
|
|
|
+ <button type="primary" form-type="submit" class="button1">
|
|
|
+ <p class="p">确认</p>
|
|
|
+ </button>
|
|
|
+ <button type="primary" @click="updateModules(plcCoding,'plc')" class="button1">
|
|
|
+ <p class="p">更换</p>
|
|
|
+ </button>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </form>
|
|
|
+ <view class="line"></view>
|
|
|
<form @submit="jiareban" @reset="jiarebanReset">
|
|
|
<view class="modules">
|
|
|
<view class="title">加热板</view>
|
|
@@ -332,36 +408,6 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</form>
|
|
|
- <view class="line"></view>
|
|
|
- <form @submit="anzhuoping" @reset="anzhuopingReset">
|
|
|
- <view class="modules">
|
|
|
- <view class="title">安卓屏</view>
|
|
|
- <view class="body">
|
|
|
- <input class="input" style="display:none;" name="anzhuopingCoding" :value=anzhuopingCoding />
|
|
|
- 编码:<input class="input" v-model="anzhuopingCoding" />
|
|
|
- <button type="primary" @click="saoma('anzhuopingCoding')" class="button1">
|
|
|
- <p class="p">扫码</p>
|
|
|
- </button>
|
|
|
- <button type="primary" @click="getMessage(anzhuopingCoding)" class="button1">
|
|
|
- <p class="p">获取</p>
|
|
|
- </button>
|
|
|
- </view>
|
|
|
- <view class="body">
|
|
|
- 名称:<input class="input" name="anzhuopingName" :value="anzhuopingName" />
|
|
|
- </view>
|
|
|
- <!-- <view class="body">
|
|
|
- 版本:<input class="input" name="anzhuopingVersion" :value="anzhuopingVersion" />
|
|
|
- </view> -->
|
|
|
- <view class="modulesButton">
|
|
|
- <button type="primary" form-type="submit" class="button1">
|
|
|
- <p class="p">确认</p>
|
|
|
- </button>
|
|
|
- <button type="primary" @click="updateModules(anzhuopingCoding,'anzhuoping')" class="button1">
|
|
|
- <p class="p">更换</p>
|
|
|
- </button>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </form>
|
|
|
|
|
|
<view class="line"></view>
|
|
|
<form @submit="qibeng" @reset="yaxingdaoReset">
|
|
@@ -485,10 +531,14 @@
|
|
|
</form>
|
|
|
|
|
|
<view class="">
|
|
|
- <button type="primary" formType="submit" class="button">
|
|
|
- <p class="p1">提交</p>
|
|
|
+ <button type="primary" @click="jiancha()" class="button">
|
|
|
+ <p class="p1">检查</p>
|
|
|
</button>
|
|
|
</view>
|
|
|
+ <view class="">
|
|
|
+ {{weiname}} </br>
|
|
|
+ {{Modulesname}}
|
|
|
+ </view>
|
|
|
</form>
|
|
|
<view class="line"></view>
|
|
|
</view>
|
|
@@ -508,7 +558,7 @@
|
|
|
data() {
|
|
|
return {
|
|
|
produceDate: '',
|
|
|
- coding: null,
|
|
|
+ coding: '',
|
|
|
lutouCoding: null,
|
|
|
jiashiqiCoding: null,
|
|
|
name: null,
|
|
@@ -516,6 +566,8 @@
|
|
|
lutouName: null,
|
|
|
nameplate: null,
|
|
|
clientId:null,
|
|
|
+ orderNo:null,
|
|
|
+ customerNo:null,
|
|
|
producePersonnel: null,
|
|
|
jiashiqiVersion: null,
|
|
|
lutouVersion: null,
|
|
@@ -552,13 +604,17 @@
|
|
|
anzhuopingCoding:null,
|
|
|
anzhuopingName: null,
|
|
|
anzhuopingVersion: null,
|
|
|
+ plcCoding:null,
|
|
|
+ plcName: null,
|
|
|
+ plcVersion: null,
|
|
|
jiarebanCoding:null,
|
|
|
jiarebanName: null,
|
|
|
jiarebanVersion: null,
|
|
|
xiazaiCoding:null,
|
|
|
xiazaiName: null,
|
|
|
xiazaiVersion: null,
|
|
|
-
|
|
|
+ weiname:'',
|
|
|
+ Modulesname:''
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
@@ -569,6 +625,17 @@
|
|
|
btnCancel0() {
|
|
|
this.produceDate = '';
|
|
|
},
|
|
|
+ gongxu(){
|
|
|
+ var item = {
|
|
|
+ coding:null,
|
|
|
+ type:'add'
|
|
|
+ };
|
|
|
+ var coding = this.coding;
|
|
|
+ item.coding = coding;
|
|
|
+ uni.navigateTo({
|
|
|
+ url:'workingProcedure?item='+encodeURIComponent(JSON.stringify(item))
|
|
|
+ });
|
|
|
+ },
|
|
|
saoma(cod) {
|
|
|
var that = this;
|
|
|
// 允许从相机和相册扫码
|
|
@@ -615,6 +682,9 @@
|
|
|
if (cod == 'anzhuopingCoding') {
|
|
|
that.anzhuopingCoding = res.result;
|
|
|
}
|
|
|
+ if (cod == 'plcCoding') {
|
|
|
+ that.plcCoding = res.result;
|
|
|
+ }
|
|
|
if (cod == 'jiarebanCoding') {
|
|
|
that.jiarebanCoding = res.result;
|
|
|
}
|
|
@@ -670,6 +740,9 @@
|
|
|
that.anzhuopingName = null;
|
|
|
that.anzhuopingCoding = null;
|
|
|
that.anzhuopingVersion = null;
|
|
|
+ that.plcName = null;
|
|
|
+ that.plcCoding = null;
|
|
|
+ that.plcVersion = null;
|
|
|
that.jiarebanName = null;
|
|
|
that.jiarebanCoding = null;
|
|
|
that.jiarebanVersion = null;
|
|
@@ -693,6 +766,8 @@
|
|
|
that.name = tmachine.name;
|
|
|
that.nameplate = tmachine.nameplate;
|
|
|
that.clientId = tmachine.clientId;
|
|
|
+ that.customerNo = tmachine.customerNo;
|
|
|
+ that.orderNo = tmachine.orderNo;
|
|
|
// that.producePersonnel = uni.getStorageSync("name");
|
|
|
var modulesList = res.data.data.modulesList;
|
|
|
var modules;
|
|
@@ -782,6 +857,18 @@
|
|
|
that.jiarebanCoding = modulesList[i].coding;
|
|
|
that.jiarebanVersion = modulesList[i].coding.substring(8, 10);
|
|
|
}
|
|
|
+ //安卓屏
|
|
|
+ if (coding.substring(5, 7) == '15') {
|
|
|
+ that.anzhuopingName = modulesList[i].name;
|
|
|
+ that.anzhuopingCoding = modulesList[i].coding;
|
|
|
+ that.anzhuopingVersion = modulesList[i].coding.substring(8, 10);
|
|
|
+ }
|
|
|
+ //plc
|
|
|
+ if (coding.substring(5, 7) == '16') {
|
|
|
+ that.plcName = modulesList[i].name;
|
|
|
+ that.plcCoding = modulesList[i].coding;
|
|
|
+ that.plcVersion = modulesList[i].coding.substring(8, 10);
|
|
|
+ }
|
|
|
|
|
|
}
|
|
|
}else{
|
|
@@ -792,12 +879,7 @@
|
|
|
that.qibengCoding = modulesList[i].coding;
|
|
|
that.qibengVersion = modulesList[i].coding.substring(8, 10);
|
|
|
}
|
|
|
- //安卓屏
|
|
|
- if (coding.substring(8, 10) == '71'||coding.substring(8, 10) == '72'||coding.substring(7, 10) == '138'||coding.substring(7, 10) == '139') {
|
|
|
- that.anzhuopingName = modulesList[i].name;
|
|
|
- that.anzhuopingCoding = modulesList[i].coding;
|
|
|
- that.anzhuopingVersion = modulesList[i].coding.substring(8, 10);
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
}
|
|
|
}
|
|
@@ -806,6 +888,8 @@
|
|
|
that.name = codes.name;
|
|
|
that.nameplate = codes.nameplate;
|
|
|
that.clientId = codes.clientId;
|
|
|
+ that.customerNo = codes.customerNo;
|
|
|
+ that.orderNo = codes.orderNo;
|
|
|
that.producePersonnel = uni.getStorageSync("name");
|
|
|
}
|
|
|
|
|
@@ -915,16 +999,21 @@
|
|
|
that.jiarebanCoding = codes.coding;
|
|
|
that.jiarebanVersion =codes.code.substring(8, 10);
|
|
|
}
|
|
|
-
|
|
|
+ //安卓屏
|
|
|
+ if (coding.substring(5, 7) == '15') {
|
|
|
+ that.anzhuopingName = codes.name;
|
|
|
+ that.anzhuopingCoding = codes.coding;
|
|
|
+ that.anzhuopingVersion = codes.code.substring(8, 10);
|
|
|
+ }
|
|
|
+ //plc
|
|
|
+ if (coding.substring(5, 7) == '16') {
|
|
|
+ that.plcName = codes.name;
|
|
|
+ that.plcCoding = codes.coding;
|
|
|
+ that.plcVersion = codes.code.substring(8, 10);
|
|
|
+ }
|
|
|
}
|
|
|
}else{
|
|
|
- //安卓屏
|
|
|
- if (coding.substring(8, 10) == '71'||coding.substring(8, 10) == '72'||coding.substring(7, 10) == '138'||coding.substring(7, 10) == '139') {
|
|
|
- // debugger;
|
|
|
- that.anzhuopingName = codes.name;
|
|
|
- that.anzhuopingCoding = codes.coding;
|
|
|
- that.anzhuopingVersion = codes.versions;
|
|
|
- }
|
|
|
+
|
|
|
//气泵
|
|
|
if (coding.substring(8, 10) == '39') {
|
|
|
that.qibengName = codes.name;
|
|
@@ -959,6 +1048,8 @@
|
|
|
"name": modules.name,
|
|
|
"nameplate": modules.nameplate,
|
|
|
"clientId":modules.clientId,
|
|
|
+ "customerNo":modules.customerNo,
|
|
|
+ "orderNo":modules.orderNo,
|
|
|
"createPersonnel": createPersonnel
|
|
|
},
|
|
|
header: {
|
|
@@ -1047,6 +1138,9 @@
|
|
|
anzhuoping(event){
|
|
|
this.tijiao(event,"anzhuoping");
|
|
|
},
|
|
|
+ plc(event){
|
|
|
+ this.tijiao(event,"plc");
|
|
|
+ },
|
|
|
jiareban(event){
|
|
|
this.tijiao(event,"jiareban");
|
|
|
},
|
|
@@ -1166,6 +1260,11 @@
|
|
|
that.anzhuopingCoding = null;
|
|
|
that.anzhuopingVersion = null;
|
|
|
}
|
|
|
+ if (name == "plc") {
|
|
|
+ that.plcName = null;
|
|
|
+ that.plcCoding = null;
|
|
|
+ that.plcVersion = null;
|
|
|
+ }
|
|
|
if (name == "jiareban") {
|
|
|
that.jiarebanName = null;
|
|
|
that.jiarebanCoding = null;
|
|
@@ -1216,6 +1315,48 @@
|
|
|
});
|
|
|
}
|
|
|
});
|
|
|
+ },
|
|
|
+ jiancha(){
|
|
|
+ var token = uni.getStorageSync("token");
|
|
|
+ uni.request({
|
|
|
+ url: this.serverurl + "/TWorkingProcedure/jiancha",
|
|
|
+ method: "POST",
|
|
|
+ data: {
|
|
|
+ "machineCoding": this.coding
|
|
|
+ },
|
|
|
+ header: {
|
|
|
+ 'token': token
|
|
|
+ },
|
|
|
+ success: (Result) => {
|
|
|
+ var res = Result;
|
|
|
+ if (res.data.code == false) {
|
|
|
+ var re = res.data.data.toString();
|
|
|
+ this.weiname = '工序:'+re+'未安装';
|
|
|
+ }else{
|
|
|
+ this.weiname = '工序已全部安装';
|
|
|
+ }
|
|
|
+ this.jianchaModules();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ jianchaModules(){
|
|
|
+ var token = uni.getStorageSync("token");
|
|
|
+ uni.request({
|
|
|
+ url: this.serverurl + "/TModules/jianchaModules?machineCoding="+this.coding,
|
|
|
+ method: "GET",
|
|
|
+ header: {
|
|
|
+ 'token': token
|
|
|
+ },
|
|
|
+ success: (Result) => {
|
|
|
+ var res = Result;
|
|
|
+ if (res.data.code == false) {
|
|
|
+ var re = res.data.data.toString();
|
|
|
+ this.Modulesname = '模块:'+re+'未安装';
|
|
|
+ }else{
|
|
|
+ this.Modulesname = '模块已全部安装';
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
}
|
|
|
}
|
|
|
}
|