1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474 |
- <template>
- <view>
- <form @submit="submit">
- <form @submit="addMachine">
- <view class="title"> 机器</view>
- <view class="body">
- <input class="input" style="display:none;" name="coding" :value=coding />
- 机器编码:<input class="input" v-model="coding" />
- <button type="primary" @click="saoma('coding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMachine(coding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="bodyname">
- 名称:<input class="input" name="name" :value="name" />
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- </view>
- <view class="body">
- 机身铭牌:<input class="input" name="nameplate" :value="nameplate" />
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- </view>
- <view class="body">
- 设备编号:<input class="input" name="clientId" :value="clientId" />
- <button type="primary" form-type="submit" class="button1">
- <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>
- <view class="body">
- <input class="input" style="display:none;" name="jikeCoding" :value=jikeCoding />
- 编码:<input class="input" v-model="jikeCoding" />
- <button type="primary" @click="saoma('jikeCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(jikeCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="jikeName" :value="jikeName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="jikeVersion" :value="jikeVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(jikeCoding,'jike')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="lutou" @reset="lutouReset">
- <view class="modules">
- <view class="title">炉头</view>
- <view class="body">
- <input class="input" style="display:none;" name="lutouCoding" :value=lutouCoding />
- 编码:<input class="input" v-model="lutouCoding" />
- <button type="primary" @click="saoma('lutouCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(lutouCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="lutouName" :value="lutouName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="lutouVersion" :value="lutouVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(lutouCoding,'lutou')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="jiashiqi" @reset="jiashiqiReset">
- <view class="modules">
- <view class="title">加湿器</view>
- <view class="body">
- <input class="input" style="display:none;" name="jiashiqiCoding" :value=jiashiqiCoding />
- 编码:<input class="input" v-model="jiashiqiCoding" />
- <button type="primary" @click="saoma('jiashiqiCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(jiashiqiCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="jiashiqiName" :value="jiashiqiName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="jiashiqiVersion" :value="jiashiqiVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(jiashiqiCoding,'jiashiqi')" class="button1">
- <p class="p">更换</p>
- </button>
- </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="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>
- <view class="body">
- <input class="input" style="display:none;" name="jiarebanCoding" :value=jiarebanCoding />
- 编码:<input class="input" v-model="jiarebanCoding" />
- <button type="primary" @click="saoma('jiarebanCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(jiarebanCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="jiarebanName" :value="jiarebanName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="jiarebanVersion" :value="jiarebanVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(jiarebanCoding,'jiareban')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="chugun" @reset="chugunReset">
- <view class="modules">
- <view class="title">出棍模块</view>
- <view class="body">
- <input class="input" style="display:none;" name="chugunCoding" :value=chugunCoding />
- 编码:<input class="input" v-model="chugunCoding" />
- <button type="primary" @click="saoma('chugunCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(chugunCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="chugunName" :value="chugunName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="chugunVersion" :value="chugunVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(chugunCoding,'chugun')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="diangui" @reset="dianguiReset">
- <view class="modules">
- <view class="title">电柜模块</view>
- <view class="body">
- <input class="input" style="display:none;" name="dianguiCoding" :value=dianguiCoding />
- 编码:<input class="input" v-model="dianguiCoding" />
- <button type="primary" @click="saoma('dianguiCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(dianguiCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="dianguiName" :value="dianguiName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="dianguiVersion" :value="dianguiVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(dianguiCoding,'diangui')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="xiazai" @reset="xiazaiReset">
- <view class="modules">
- <view class="title">远程下载模块</view>
- <view class="body">
- <input class="input" style="display:none;" name="xiazaiCoding" :value=xiazaiCoding />
- 编码:<input class="input" v-model="xiazaiCoding" />
- <button type="primary" @click="saoma('xiazaiCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(xiazaiCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="xiazaiName" :value="xiazaiName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="xiazaiVersion" :value="xiazaiVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(xiazaiCoding,'xiazai')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="jixieshou" @reset="jixieshouReset">
- <view class="modules">
- <view class="title">机械手</view>
- <view class="body">
- <input class="input" style="display:none;" name="jixieshouCoding" :value=jixieshouCoding />
- 编码:<input class="input" v-model="jixieshouCoding" />
- <button type="primary" @click="saoma('jixieshouCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(jixieshouCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="jixieshouName" :value="jixieshouName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="jixieshouVersion" :value="jixieshouVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(jixieshouCoding,'jixieshou')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="yaxingdao" @reset="yaxingdaoReset">
- <view class="modules">
- <view class="title">压型刀</view>
- <view class="body">
- <input class="input" style="display:none;" name="yaxingdaoCoding" :value=yaxingdaoCoding />
- 编码:<input class="input" v-model="yaxingdaoCoding" />
- <button type="primary" @click="saoma('yaxingdaoCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(yaxingdaoCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="yaxingdaoName" :value="yaxingdaoName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="yaxingdaoVersion" :value="yaxingdaoVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(yaxingdaoCoding,'yaxingdao')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="songtang" @reset="yaxingdaoReset">
- <view class="modules">
- <view class="title">送糖模块</view>
- <view class="body">
- <input class="input" style="display:none;" name="songtangCoding" :value=songtangCoding />
- 编码:<input class="input" v-model="songtangCoding" />
- <button type="primary" @click="saoma('songtangCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(songtangCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="songtangName" :value="songtangName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="songtangVersion" :value="songtangVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(songtangCoding,'songtang')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="qibeng" @reset="yaxingdaoReset">
- <view class="modules">
- <view class="title">气泵</view>
- <view class="body">
- <input class="input" style="display:none;" name="qibengCoding" :value=qibengCoding />
- 编码:<input class="input" v-model="qibengCoding" />
- <button type="primary" @click="saoma('qibengCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(qibengCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="qibengName" :value="qibengName" />
- </view>
- <!-- <view class="body">
- 版本:<input class="input" name="qibengVersion" :value="qibengVersion" />
- </view> -->
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(qibengCoding,'qibeng')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="zidongdoor" @reset="zidongdoorReset">
- <view class="modules">
- <view class="title">自动门</view>
- <view class="body">
- <input class="input" style="display:none;" name="zidongdoorCoding" :value=zidongdoorCoding />
- 编码:<input class="input" v-model="zidongdoorCoding" />
- <button type="primary" @click="saoma('zidongdoorCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(zidongdoorCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="zidongdoorName" :value="zidongdoorName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="zidongdoorVersion" :value="zidongdoorVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(zidongdoorCoding,'zidongdoor')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="shuibeng" @reset="shuibengReset">
- <view class="modules">
- <view class="title">蒸汽发生器</view>
- <view class="body">
- <input class="input" style="display:none;" name="shuibengCoding" :value=shuibengCoding />
- 编码:<input class="input" v-model="shuibengCoding" />
- <button type="primary" @click="saoma('shuibengCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(shuibengCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="shuibengName" :value="shuibengName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="shuibengVersion" :value="shuibengVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(shuibengCoding,'shuibeng')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
- <view class="line"></view>
- <form @submit="shoudongdoor" @reset="shoudongdoorReset">
- <view class="modules">
- <view class="title">手动门</view>
- <view class="body">
- <input class="input" style="display:none;" name="shoudongdoorCoding" :value=shoudongdoorCoding />
- 编码:<input class="input" v-model="shoudongdoorCoding" />
- <button type="primary" @click="saoma('shoudongdoorCoding')" class="button1">
- <p class="p">扫码</p>
- </button>
- <button type="primary" @click="getMessage(shoudongdoorCoding)" class="button1">
- <p class="p">获取</p>
- </button>
- </view>
- <view class="body">
- 名称:<input class="input" name="shoudongdoorName" :value="shoudongdoorName" />
- </view>
- <view class="body">
- 版本:<input class="input" name="shoudongdoorVersion" :value="shoudongdoorVersion" />
- </view>
- <view class="modulesButton">
- <button type="primary" form-type="submit" class="button1">
- <p class="p">确认</p>
- </button>
- <button type="primary" @click="updateModules(shoudongdoorCoding,'shoudongdoor')" class="button1">
- <p class="p">更换</p>
- </button>
- </view>
- </view>
- </form>
-
-
- <view class="">
- <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>
- </template>
- <script>
- import {
- mapState,
- mapActions,
- mapMutations
- } from 'vuex';
- import timeSelector from '@/components/wing-time-selector/wing-time-selector.vue';
- export default {
- components: {
- timeSelector
- },
- data() {
- return {
- produceDate: '',
- coding: '',
- lutouCoding: null,
- jiashiqiCoding: null,
- name: null,
- jiashiqiName: null,
- lutouName: null,
- nameplate: null,
- clientId:null,
- orderNo:null,
- customerNo:null,
- producePersonnel: null,
- jiashiqiVersion: null,
- lutouVersion: null,
- jikeCoding:null,
- jikeName: null,
- jikeVersion: null,
- shuibengCoding:null,
- shuibengName: null,
- shuibengVersion: null,
- chugunCoding:null,
- chugunName: null,
- chugunVersion: null,
- dianguiCoding:null,
- dianguiName: null,
- dianguiVersion: null,
- zidongdoorCoding:null,
- zidongdoorName: null,
- zidongdoorVersion: null,
- jixieshouCoding:null,
- jixieshouName: null,
- jixieshouVersion: null,
- yaxingdaoCoding:null,
- yaxingdaoName: null,
- yaxingdaoVersion: null,
- qibengCoding:null,
- qibengName: null,
- qibengVersion: null,
- songtangCoding:null,
- songtangName: null,
- songtangVersion: null,
- shoudongdoorCoding:null,
- shoudongdoorName: null,
- shoudongdoorVersion: null,
-
- 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: {
- btnConfirm0(e) {
- // console.log('确定时间为:', e);
- this.produceDate = e.key;
- },
- 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;
- // 允许从相机和相册扫码
- uni.scanCode({
- success(res) {
- // console.log('条码类型:' + res.scanType);
- // console.log('条码内容:' + res.result);
- if (cod == 'coding') {
- that.coding = res.result;
- }
- if (cod == 'lutouCoding') {
- that.lutouCoding = res.result;
- }
- if (cod == 'jiashiqiCoding') {
- that.jiashiqiCoding = res.result;
- }
- if (cod == 'shuibengCoding') {
- that.shuibengCoding = res.result;
- }
- if (cod == 'chugunCoding') {
- that.chugunCoding = res.result;
- }
- if (cod == 'dianguiCoding') {
- that.dianguiCoding = res.result;
- }
- if (cod == 'zidongdoorCoding') {
- that.zidongdoorCoding = res.result;
- }
- if (cod == 'jixieshouCoding') {
- that.jixieshouCoding = res.result;
- }
- if (cod == 'yaxingdaoCoding') {
- that.yaxingdaoCoding = res.result;
- }
- if (cod == 'qibengCoding') {
- that.qibengCoding = res.result;
- }
- if (cod == 'songtangCoding') {
- that.songtangCoding = res.result;
- }
- if (cod == 'shoudongdoorCoding') {
- that.shoudongdoorCoding = res.result;
- }
- if (cod == 'anzhuopingCoding') {
- that.anzhuopingCoding = res.result;
- }
- if (cod == 'plcCoding') {
- that.plcCoding = res.result;
- }
- if (cod == 'jiarebanCoding') {
- that.jiarebanCoding = res.result;
- }
- if (cod == 'jikeCoding') {
- that.jikeCoding = res.result;
- }
- if (cod == 'xiazaiCoding') {
- that.xiazaiCoding = res.result;
- }
- }
- });
- },
- //获取机器详细信息
- getMachine(coding) {
- var that = this;
- that.jiashiqiName = null;
- that.jiashiqiCoding = null;
- that.jiashiqiVersion = null;
- that.lutouName =null;
- that.lutouCoding = null;
- that.lutouVersion =null;
- that.shuibengName = null;
- that.shuibengCoding = null;
- that.shuibengVersion = null;
- that.chugunName = null;
- that.chugunCoding = null;
- that.chugunVersion = null;
- that.dianguiName = null;
- that.dianguiCoding = null;
- that.dianguiVersion = null;
- that.jikeName = null;
- that.jikeCoding = null;
- that.jikeVersion = null;
- that.zidongdoorName = null;
- that.zidongdoorCoding = null;
- that.zidongdoorVersion = null;
- that.shoudongdoorName = null;
- that.shoudongdoorCoding = null;
- that.shoudongdoorVersion = null;
- that.jixieshouName = null;
- that.jixieshouCoding = null;
- that.jixieshouVersion = null;
- that.yaxingdaoName = null;
- that.yaxingdaoCoding = null;
- that.yaxingdaoVersion = null;
- that.songtangName = null;
- that.songtangCoding = null;
- that.songtangVersion = null;
- that.songtangVersion = null;
- that.qibengName = null;
- that.qibengCoding = null;
- that.qibengVersion = null;
- 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;
- that.xiazaiName = null;
- that.xiazaiCoding = null;
- that.xiazaiVersion = null;
- var serverUrl = that.serverurl;
- var token = uni.getStorageSync("token");
- uni.request({
- url: serverUrl + "/TMachine/getMachine?coding=" + coding,
- method: "GET",
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- if (res.data.code == true) {
- //当机器已录入时,会先把所有录入模块给列出来
- if (res.data.message == 'all') {
- var tmachine = res.data.data.tmachine;
- 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;
- for (var i = 0; i < modulesList.length; i++) {
- // console.log(modulesList[i]);
- var coding = modulesList[i].coding;
- //排除标准件
- if (coding.substring(0, 4) != '1000') {
- //半成品
- if (coding.substring(0, 2) == '15') {
- //"加湿器"
- if (coding.substring(5, 7) == '07') {
- that.jiashiqiName = modulesList[i].name;
- that.jiashiqiCoding = modulesList[i].coding;
- that.jiashiqiVersion = modulesList[i].coding.substring(8, 10);
- }
- //炉头
- if (coding.substring(5, 7) == '04') {
- that.lutouName = modulesList[i].name;
- that.lutouCoding = modulesList[i].coding;
- that.lutouVersion = modulesList[i].coding.substring(8, 10);
- }
- //水泵 -> 蒸汽发生器
- if (coding.substring(5, 7) == '08') {
- that.shuibengName = modulesList[i].name;
- that.shuibengCoding = modulesList[i].coding;
- that.shuibengVersion = modulesList[i].coding.substring(8, 10);
- }
- //出棍模块
- if (coding.substring(5, 7) == '06') {
- that.chugunName = modulesList[i].name;
- that.chugunCoding = modulesList[i].coding;
- that.chugunVersion = modulesList[i].coding.substring(8, 10);
- }
- //电柜模块
- if (coding.substring(5, 7) == '01') {
- that.dianguiName = modulesList[i].name;
- that.dianguiCoding = modulesList[i].coding;
- that.dianguiVersion = modulesList[i].coding.substring(8, 10);
- }
- //机壳
- if (coding.substring(5, 7) == '09') {
- that.jikeName = modulesList[i].name;
- that.jikeCoding = modulesList[i].coding;
- that.jikeVersion = modulesList[i].coding.substring(8, 10);
- }
- //自动门
- if (coding.substring(5, 7) == '12') {
- that.zidongdoorName = modulesList[i].name;
- that.zidongdoorCoding = modulesList[i].coding;
- that.zidongdoorVersion = modulesList[i].coding.substring(8, 10);
- }
- //手动门
- if (coding.substring(5, 7) == '11') {
- that.shoudongdoorName = modulesList[i].name;
- that.shoudongdoorCoding = modulesList[i].coding;
- that.shoudongdoorVersion = modulesList[i].coding.substring(8, 10);
- }
- //机械手
- if (coding.substring(5, 7) == '02') {
- that.jixieshouName = modulesList[i].name;
- that.jixieshouCoding = modulesList[i].coding;
- that.jixieshouVersion = modulesList[i].coding.substring(8, 10);
- }
- //压型刀
- if (coding.substring(5, 7) == '03') {
- that.yaxingdaoName = modulesList[i].name;
- that.yaxingdaoCoding = modulesList[i].coding;
- that.yaxingdaoVersion = modulesList[i].coding.substring(8, 10);
- }
- //送糖
- if (coding.substring(5, 7) == '05') {
- that.songtangName = modulesList[i].name;
- that.songtangCoding = modulesList[i].coding;
- that.songtangVersion = modulesList[i].coding.substring(8, 10);
- }
- //远程下载模块
- if (coding.substring(5, 7) == '13') {
- that.xiazaiName = modulesList[i].name;
- that.xiazaiCoding = modulesList[i].coding;
- that.xiazaiVersion = modulesList[i].coding.substring(8, 10);
- }
- //加热板
- if (coding.substring(5, 7) == '14') {
- that.jiarebanName = modulesList[i].name;
- // that.qibengCoding = modulesList[i].coding.substring(0, 10);
- 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{
- //气泵
- if (coding.substring(8, 10) == '39') {
- that.qibengName = modulesList[i].name;
- // that.qibengCoding = modulesList[i].coding.substring(0, 10);
- that.qibengCoding = modulesList[i].coding;
- that.qibengVersion = modulesList[i].coding.substring(8, 10);
- }
-
-
- }
- }
- } else {
- var codes = res.data.data;
- 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");
- }
- } else {
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- }
- });
- },
- getMessage(coding) {
- var that = this;
- var serverUrl = that.serverurl;
- var token = uni.getStorageSync("token");
- uni.request({
- url: serverUrl + "/TModules/getMessage?coding=" + coding,
- method: "GET",
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- if (res.data.code == true) {
- var codes = res.data.data;
- var coding = codes.code;
- //排除标准件
- if (coding.substring(0, 4) != '1000') {
- //半成品
- if (coding.substring(0, 2) == '15') {
- //"加湿器"
- if (coding.substring(5, 7) == '07') {
- that.jiashiqiName = codes.name;
- that.jiashiqiCoding = codes.coding;
- that.jiashiqiVersion = codes.code.substring(8, 10);
- }
- //炉头
- if (coding.substring(5, 7) == '04') {
- that.lutouName = codes.name;
- that.lutouCoding = codes.coding;
- that.lutouVersion = codes.code.substring(8, 10);
- }
- //水泵 -> 蒸汽发生器
- if (coding.substring(5, 7) == '08') {
- that.shuibengName = codes.name;
- that.shuibengCoding = codes.coding;
- that.shuibengVersion = codes.code.substring(8, 10);
- }
- //出棍模块
- if (coding.substring(5, 7) == '06') {
- that.chugunName = codes.name;
- that.chugunCoding = codes.coding;
- that.chugunVersion = codes.code.substring(8, 10);
- }
- //电柜模块
- if (coding.substring(5, 7) == '01') {
- that.dianguiName = codes.name;
- that.dianguiCoding = codes.coding;
- that.dianguiVersion = codes.code.substring(8, 10);
- }
- //机壳
- if (coding.substring(5, 7) == '09') {
- that.jikeName = codes.name;
- that.jikeCoding = codes.coding;
- that.jikeVersion = codes.code.substring(8, 10);
- }
- //自动门
- if (coding.substring(5, 7) == '12') {
- that.zidongdoorName = codes.name;
- that.zidongdoorCoding = codes.coding;
- that.zidongdoorVersion = codes.code.substring(8, 10);
- }
- //手动门
- if (coding.substring(5, 7) == '11') {
- that.shoudongdoorName = codes.name;
- that.shoudongdoorCoding = codes.coding;
- that.shoudongdoorVersion = codes.code.substring(8, 10);
- }
- //机械手
- if (coding.substring(5, 7) == '02') {
- that.jixieshouName = codes.name;
- that.jixieshouCoding = codes.coding;
- that.jixieshouVersion = codes.code.substring(8, 10);
- }
- //压型刀
- if (coding.substring(5, 7) == '03') {
- that.yaxingdaoName = codes.name;
- that.yaxingdaoCoding = codes.coding;
- that.yaxingdaoVersion = codes.code.substring(8, 10);
- }
- //送糖
- if (coding.substring(5, 7) == '05') {
- that.songtangName = codes.name;
- that.songtangCoding = codes.coding;
- that.songtangVersion = codes.code.substring(8, 10);
- }
- //远程下载模块
- if (coding.substring(5, 7) == '13') {
- that.xiazaiName = codes.name;
- that.xiazaiCoding = codes.coding;
- that.xiazaiVersion = codes.code.substring(8, 10);
- }
- //加热板
- if (coding.substring(5, 7) == '14') {
- that.jiarebanName = codes.name;
- 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) == '39') {
- that.qibengName = codes.name;
- that.qibengCoding = codes.coding;
- that.qibengVersion = codes.versions;
- }
-
- }
- } else {
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- }
- });
- },
- //机器修改
- addMachine(event) {
- var serverUrl = this.serverurl;
- const {
- value: modules
- } = event.detail;
- // console.log("3");
- var token = uni.getStorageSync("token");
- var createPersonnel = uni.getStorageSync("name");
- uni.request({
- url: serverUrl + "/TMachine/add",
- method: "POST",
- data: {
- "coding": modules.coding,
- "name": modules.name,
- "nameplate": modules.nameplate,
- "clientId":modules.clientId,
- "customerNo":modules.customerNo,
- "orderNo":modules.orderNo,
- "createPersonnel": createPersonnel
- },
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- });
- },
- lutou(event) {
- var serverUrl = this.serverurl;
- var machineCoding = this.coding;
- const {
- value: modules
- } = event.detail;
- // console.log(event.detail.value);
-
- var token = uni.getStorageSync("token");
- var createPersonnel = uni.getStorageSync("name");
- uni.request({
- url: serverUrl + "/TModules/update",
- method: "POST",
- data: {
- "machineCoding": machineCoding,
- "coding": modules.lutouCoding,
- "name": modules.lutouName,
- "installPersonnel": createPersonnel
- },
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- if (res.data.code == true) {
- }
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- });
- },
- objToStrMap(obj) {
- let strMap = new Map();
- for (let k of Object.keys(obj)) {
- strMap.set(k, obj[k]);
- }
- return strMap;
- },
- jiashiqi(event) {
- this.tijiao(event,"jiashiqi");
- },
- shuibeng(event) {
- this.tijiao(event,"shuibeng");
- },
- chugun(event){
- this.tijiao(event,"chugun");
- },
- diangui(event){
- this.tijiao(event,"diangui");
- },
- zidongdoor(event){
- this.tijiao(event,"zidongdoor");
- },
- shoudongdoor(event){
- this.tijiao(event,"shoudongdoor");
- },
- jixieshou(event){
- this.tijiao(event,"jixieshou");
- },
- yaxingdao(event){
- this.tijiao(event,"yaxingdao");
- },
- qibeng(event){
- this.tijiao(event,"qibeng");
- },
- songtang(event){
- this.tijiao(event,"songtang");
- },
- anzhuoping(event){
- this.tijiao(event,"anzhuoping");
- },
- plc(event){
- this.tijiao(event,"plc");
- },
- jiareban(event){
- this.tijiao(event,"jiareban");
- },
- jike(event){
- this.tijiao(event,"jike");
- },
- xiazai(event){
- this.tijiao(event,"xiazai");
- },
- tijiao(event,sname){
- var serverUrl = this.serverurl;
- var machineCoding = this.coding;
- const {
- value: modules
- } = event.detail;
- var eValue = event.detail.value;
- //将value对象转为map
- var mapValue = this.objToStrMap(eValue);
- var coding = mapValue.get(sname+"Coding");
- var name = mapValue.get(sname+"Name");
- // console.log(coding+"---"+name);
- var token = uni.getStorageSync("token");
- var createPersonnel = uni.getStorageSync("name");
- uni.request({
- url: serverUrl + "/TModules/update",
- method: "POST",
- data: {
- "machineCoding": machineCoding,
- "coding": coding,
- "name": name,
- "installPersonnel": createPersonnel
- },
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- if (res.data.code == true) {
-
- }
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- });
- },
- updateModules(code, name) {
- var that = this;
- uni.setStorageSync("updateModules", code);
- uni.setStorageSync("updateMachineCode", that.coding);
- uni.showModal({
- title: '提示',
- content: '是否要更换?',
- success: function(res) {
- if (res.confirm) {
- uni.navigateTo({
- url: 'updateModules',
- });
- if (name == "lutou") {
- that.lutouName = null;
- that.lutouCoding = null;
- that.lutouVersion = null;
- }
- if (name == "jiashiqi") {
- that.jiashiqiName = null;
- that.jiashiqiCoding = null;
- that.jiashiqiVersion = null;
- }
- if (name == "shuibeng") {
- that.shuibengName = null;
- that.shuibengCoding = null;
- that.shuibengVersion = null;
- }
- if (name == "chugun") {
- that.chugunName = null;
- that.chugunCoding = null;
- that.chugunVersion = null;
- }
- if (name == "diangui") {
- that.dianguiName = null;
- that.dianguiCoding = null;
- that.dianguiVersion = null;
- }
- if (name == "zidongdoor") {
- that.zidongdoorName = null;
- that.zidongdoorCoding = null;
- that.zidongdoorVersion = null;
- }
- if (name == "shoudongdoor") {
- that.shoudongdoorName = null;
- that.shoudongdoorCoding = null;
- that.shoudongdoorVersion = null;
- }
- if (name == "jixieshou") {
- that.jixieshouName = null;
- that.jixieshouCoding = null;
- that.jixieshouVersion = null;
- }
- if (name == "yaxingdao") {
- that.yaxingdaoName = null;
- that.yaxingdaoCoding = null;
- that.yaxingdaoVersion = null;
- }
- if (name == "qibeng") {
- that.qibengName = null;
- that.qibengCoding = null;
- that.qibengVersion = null;
- }
- if (name == "songtang") {
- that.songtangName = null;
- that.songtangCoding = null;
- that.songtangVersion = null;
- }
- if (name == "anzhuoping") {
- that.anzhuopingName = null;
- 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;
- that.jiarebanVersion = null;
- }
- if (name == "jike") {
- that.jikeName = null;
- that.jikeCoding = null;
- that.jikeVersion = null;
- }
- if (name == "xiazai") {
- that.xiazaiName = null;
- that.xiazaiCoding = null;
- that.xiazaiVersion = null;
- }
- } else if (res.cancel) {}
- }
- });
- },
- submit(event){
- var serverUrl = this.serverurl;
- var machineCoding = this.coding;
- const {
- value: modules
- } = event.detail;
- var token = uni.getStorageSync("token");
- var createPersonnel = uni.getStorageSync("name");
- uni.request({
- url: serverUrl + "/TMachine/submit",
- method: "POST",
- data: {
- "coding": machineCoding,
- checkPersonnel:createPersonnel
- },
- header: {
- 'token': token
- },
- success: (Result) => {
- var res = Result;
- if (res.data.code == true) {
-
- }
- uni.showModal({
- title: '提示',
- content: res.data.message,
- });
- }
- });
- },
- 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 = '模块已全部安装';
- }
- }
- });
- }
- }
- }
- </script>
- <style>
- .body {
- background-color: #FFFFFF;
- padding: 20upx 20upx 20upx 20upx;
- display: flex;
- flex-direction: row;
- justify-content: flex-start;
- }
- .bodyname {
- background-color: #FFFFFF;
- padding: 20upx 20upx 20upx 70upx;
- display: flex;
- flex-direction: row;
- justify-content: flex-start;
- }
- .input {
- /* padding: 10upx 20upx 10upx 0upx; */
- padding-left: 20upx;
- padding-top: 10upx;
- background-color: #FFFFFF;
- width: 400upx;
- height: 50upx;
- box-shadow: 0upx 0upx 20upx #D3D3D3;
- border-radius: 5upx;
- }
- .button {
- margin: auto;
- width: 60%;
- height: 100upx;
- }
- .button1 {
- margin: auto;
- width: 75upx;
- height: 50upx;
- }
- .p {
- /* #ifdef H5 */
- top: -13%;
- /* #endif */
- width: 50upx;
- height: 30upx;
- font-size: 25upx;
- padding-right: 9upx;
- padding-top: 6upx;
- /* #ifndef H5 */
- /* padding-top: 10upx; */
- /* #endif */
- position: absolute;
- /* 水平居中 */
- left: 50%;
- -webkit-transform: translateX(-50%);
- transform: translateX(-50%);
- }
- .p1 {
- /* #ifdef H5 */
- top: -13%;
- /* #endif */
- width: 80upx;
- height: 60upx;
- font-size: 40upx;
- padding-top: 6upx;
- /* #ifndef H5 */
- padding-top: 10upx;
- /* #endif */
- position: absolute;
- /* 水平居中 */
- left: 50%;
- -webkit-transform: translateX(-50%);
- transform: translateX(-50%);
- }
- .radio {
- padding-top: 20upx;
- padding-left: 30upx;
- }
- .line {
- background: #ECECEC;
- height: 10upx;
- }
- .title {
- font-size: 35upx;
- }
- .modulesButton {
- background-color: #FFFFFF;
- padding: 20upx 20upx 20upx 20upx;
- display: flex;
- width: 250upx;
- margin: auto;
- flex-direction: row;
- justify-content: flex-start;
- }
- .modules {
- width: 95%;
- margin: auto;
- }
- </style>
|