1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-index-equipmentStop-equipmentStopDetail-equipmentStopDetail"],{"02f3":function(t,a,e){"use strict";var i=e("3fd7"),s=e.n(i);s.a},2405:function(t,a,e){var i=e("24fb");a=i(!1),a.push([t.i,".show-bx[data-v-253f91da]{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;flex-direction:row;padding:%?30?%;-webkit-flex-wrap:wrap;flex-wrap:wrap;width:100%;height:auto;box-sizing:border-box}.item-title[data-v-253f91da]{width:100%;height:%?70?%;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;flex-direction:row;border-bottom:%?1?% solid #d3d3d3;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between}.item-title uni-text[data-v-253f91da]{font-size:%?32?%;color:#333}.show-item[data-v-253f91da]{width:100%;height:%?70?%;line-height:3}.sh-hd[data-v-253f91da]{font-size:%?28?%;color:#333;margin-right:%?10?%;width:%?200?%;display:inline-block}.sh-bd[data-v-253f91da]{font-size:%?28?%;color:#333}.btn-bx[data-v-253f91da]{width:100%;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;flex-direction:row;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;margin-top:%?40?%}.btn-sub[data-v-253f91da]{width:%?290?%;height:%?86?%;border-radius:%?10?%;background:#169bd5;font-size:%?32?%;color:#fff;margin-right:%?40?%}.btn-res[data-v-253f91da]{width:%?290?%;height:%?86?%;border-radius:%?10?%;background:#f60;font-size:%?32?%;color:#fff}",""]),t.exports=a},"3fd7":function(t,a,e){var i=e("2405");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var s=e("4f06").default;s("0ed0e2dd",i,!0,{sourceMap:!1,shadowMode:!1})},ac30:function(t,a,e){"use strict";e.r(a);var i=e("e417"),s=e.n(i);for(var n in i)"default"!==n&&function(t){e.d(a,t,(function(){return i[t]}))}(n);a["default"]=s.a},b0da:function(t,a,e){"use strict";var i;e.d(a,"b",(function(){return s})),e.d(a,"c",(function(){return n})),e.d(a,"a",(function(){return i}));var s=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("v-uni-view",{staticClass:"page"},[e("v-uni-view",{staticClass:"grace-list-items",staticStyle:{background:"#fff","margin-bottom":"16upx"}},[e("v-uni-view",{staticClass:"grace-title grace-border-b",staticStyle:{margin:"0 20upx"}},[e("v-uni-text",{staticClass:"grace-icons icon-comments icon grace-blue"}),e("v-uni-text",{staticClass:"title grace-black"},[t._v("设备信息")])],1),e("v-uni-view",{staticClass:"grace-nowrap g-title-bx-row",staticStyle:{padding:"0 20upx"}},[e("v-uni-text",{staticClass:" grace-black9 g-card-w"},[t._v("设备编号:")]),e("v-uni-text",{staticClass:" grace-black5 grace-bold"},[t._v(t._s(t.dataValue.eqCode))])],1),e("v-uni-view",{staticClass:"grace-nowrap g-title-bx-row",staticStyle:{padding:"0 20upx"}},[e("v-uni-text",{staticClass:" grace-black9 g-card-w"},[t._v("设备名称:")]),e("v-uni-text",{staticClass:" grace-black5 grace-bold"},[t._v(t._s(t.dataValue.eqName))])],1),e("v-uni-view",{staticClass:"grace-nowrap g-title-bx-row",staticStyle:{padding:"0 20upx"}},[e("v-uni-text",{staticClass:" grace-black9 g-card-w"},[t._v("资产编号:")]),e("v-uni-text",{staticClass:" grace-black5 grace-bold"},[t._v(t._s(t.dataValue.assetNumber))])],1)],1),e("v-uni-view",{staticClass:"g-line"}),e("v-uni-view",{staticClass:"grace-title grace-border-b",staticStyle:{margin:"0 20upx"}},[e("v-uni-text",{staticClass:"grace-icons icon-article icon grace-blue"}),e("v-uni-text",{staticClass:"title grace-black"},[t._v("任务详情")])],1),e("v-uni-view",{staticClass:"show-bx"},[e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("牧场:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.pastureName))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("部门:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.deptName))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("规格:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.specification))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("品牌:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.brandName))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("启停状态:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.changeStatue))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("启用人:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.enabledPerson))])],1),e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("启用时间:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.enabledTime))])],1),"停用"==t.dataValue.changeStatue?e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("停用人:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.blockPerson))])],1):t._e(),"停用"==t.dataValue.changeStatue?e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("停用时间:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(t.dataValue.blockTime))])],1):t._e(),"停用"==t.dataValue.changeStatue?e("v-uni-view",{staticClass:"show-item grace-border-b"},[e("v-uni-text",{staticClass:"sh-hd"},[t._v("上次使用时长:")]),e("v-uni-text",{staticClass:"sh-bd"},[t._v(t._s(void 0==t.last_time?" ":t.last_time+"小时"))])],1):t._e()],1)],1)},n=[]},e12b:function(t,a,e){"use strict";e.r(a);var i=e("b0da"),s=e("ac30");for(var n in s)"default"!==n&&function(t){e.d(a,t,(function(){return s[t]}))}(n);e("02f3");var o,d=e("f0c5"),l=Object(d["a"])(s["default"],i["b"],i["c"],!1,null,"253f91da",null,!1,i["a"],o);a["default"]=l.exports},e417:function(t,a,e){"use strict";e("b680"),e("ac1f"),e("5319"),Object.defineProperty(a,"__esModule",{value:!0}),a.default=void 0;var i={data:function(){return{last_time:" ",today_now:"2019-10-17",dataValue:{}}},onLoad:function(t){var a=this,e=a.get_today_now(),i=uni.getStorageSync("g_username"),s=uni.getStorageSync("g_employeId");a.dataValue.g_username=i,a.g_username=i,a.g_employeId=s,a.today_now=e,console.log(t);var n=t.name,o=uni.getStorageSync("g_pastureId"),d="/authdata/GetDataByName",l={name:"findAssetMain",parammaps:{eqCode:n,pastureId:o}};a.ajax(d,l,"POST",a.get_list_data)},methods:{get_list_data:function(t){var a=this;if(console.log("列表数据:",JSON.stringify(t)),null==t.data.list)uni.showToast({title:"暂无数据",icon:"none"});else{var e=t.data.list.length-1;this.dataValue=t.data.list[e];var i=t.data.list[e].enabledTime,s=t.data.list[e].blockTime;if(console.log("启用时间",i),console.log("停用时间",s),void 0==i||void 0==s)a.last_time=void 0;else{var n=new Date(i.replace(/-/g,"/")).getTime(),o=new Date(s.replace(/-/g,"/")).getTime();console.log(n);var d=(o-n)/1e3/60/60;console.log("上次使用时长1",d);var l=d.toFixed(2);console.log("上次使用时长2",l),a.last_time=l}}},formSubmit:function(t){var a=this,e=uni.getStorageSync("g_employeId");a.dataValue.employeId=e;var i=a.get_today_now();a.dataValue.inputDatetime=i;var s=a.dataValue.changeStatue;console.log("页面原来的状态:"+s);var n="/authdata/ExecDataByConfig",o={common:{returnmap:"0"},data:[{name:"updateByIdEnabled",type:"e",parammaps:a.dataValue},{name:"insertSTT",type:"e",parammaps:{inputDatetime:i,employeId:e,id:a.dataValue.assetId,pastureId:a.dataValue.pastureId}},{name:"updateByIdAsset",type:"e",parammaps:{sttId:"@insertSTT.LastInsertId",id:a.dataValue.id,pastureId:a.dataValue.pastureId}}]},d={common:{returnmap:"0"},data:[{name:"updateByIdBlock",type:"e",parammaps:a.dataValue},{name:"updateSTT",type:"e",parammaps:{inputDatetime:i,employeId:e,id:a.dataValue.id,pastureId:a.dataValue.pastureId}}]};"启用"==s?a.ajax(n,d,"POST",a.get_add_status):a.ajax(n,o,"POST",a.get_add_status),console.log("需要发送的数据:"+JSON.stringify(a.dataValue))},formCancel:function(t){uni.redirectTo({url:"/pages/index/equipmentStop/equipmentStop"})},get_add_status:function(t){console.log("保存状态:",t),"ok"==t.msg?uni.showToast({title:"保存成功",duration:500,icon:"none",success:function(t){setTimeout((function(){uni.redirectTo({url:"/pages/index/equipmentStop/equipmentStop"})}),1e3)}}):uni.showToast({title:"保存失败",duration:2e3,icon:"none"})}}};a.default=i}}]);
|