(self["webpackChunkbaozhida_chain_verify_online"]=self["webpackChunkbaozhida_chain_verify_online"]||[]).push([[516],{7731:function(t,e,a){"use strict";a.r(e),a.d(e,{default:function(){return v}});var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"CompanyAccount"},[e("div",{staticClass:"CompanyAccount-mai"},[e("div",{staticClass:"CompanyAccount1"},[e("div",{staticClass:"CompanyAccount1-R"},[e("el-input",{attrs:{placeholder:"请输入任务",clearable:""},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.search(0)}},model:{value:t.pages.T_name,callback:function(e){t.$set(t.pages,"T_name",e)},expression:"pages.T_name"}}),e("el-button",{staticClass:"s1 sBtn",attrs:{type:"primary",icon:"el-icon-search"},on:{click:function(e){return t.search(0)}}},[t._v("搜索")])],1)]),e("div",{staticClass:"CompanyAccount2"},[e("el-table",{attrs:{data:t.tableData,border:"",size:"small"}},[e("el-table-column",{attrs:{label:"任务"},scopedSlots:t._u([{key:"default",fn:function(a){return[e("span",[t._v(t._s(a.row.T_name))])]}}])}),e("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(a){return[e("el-button",{attrs:{size:"small",disabled:""===a.row.T_pdf1},on:{click:function(e){return t.handleEdit1(a.row)}}},[t._v("验证方案")]),e("el-button",{attrs:{size:"small",disabled:""===a.row.T_pdf2},on:{click:function(e){return t.handleEdit2(a.row)}}},[t._v("验证报告")]),e("el-button",{attrs:{size:"small",disabled:0==a.row.T_reporting_state},on:{click:function(e){return t.handleEdit3(a.row)}}},[t._v("校准证书")]),e("el-button",{attrs:{size:"small",disabled:1!=a.row.T_delivery_state},on:{click:function(e){return t.handleEdit4(a.row)}}},[t._v("验证数据")])]}}])})],1)],1),e("div",{staticClass:"CompanyAccount3"},[e("el-pagination",{attrs:{"current-page":t.pages.page,"page-size":t.pages.page_z,layout:"total, prev, pager, next, jumper",total:t.total},on:{"current-change":t.handleCurrentChange}})],1)]),e("el-drawer",{ref:"drawer",attrs:{title:"验证设备数据",visible:t.Drawer,direction:"rtl",size:"90%"},on:{"update:visible":function(e){t.Drawer=e}}},[e("div",{staticClass:"demo-drawers"},[e("div",{staticClass:"demoDra1"},[e("div",{staticClass:"demoDra1-R"},[e("el-input",{staticClass:"s1",attrs:{placeholder:"请输入编号",clearable:""},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.search(1)}},model:{value:t.pages1.T_id,callback:function(e){t.$set(t.pages1,"T_id",e)},expression:"pages1.T_id"}}),e("el-date-picker",{staticClass:"s1",attrs:{"picker-options":t.pickerOptions,"popper-class":"noClear","value-format":"yyyy-MM-dd HH:mm:ss",type:"datetimerange","range-separator":"至",clearable:!1,"start-placeholder":"开始日期","end-placeholder":"结束日期"},on:{change:t.searchTimeData},model:{value:t.pickerTime,callback:function(e){t.pickerTime=e},expression:"pickerTime"}}),e("el-button",{staticClass:"s1 sBtn",attrs:{type:"primary",icon:"el-icon-search"},on:{click:function(e){return t.search(1)}}})],1),e("div",{staticClass:"demoDra1-L s1"},[e("el-button",{attrs:{type:"primary",icon:"el-icon-download"},on:{click:function(e){return t.downloadFun("t")}}},[t._v("下载温度")]),e("el-button",{attrs:{type:"primary",icon:"el-icon-download"},on:{click:function(e){return t.downloadFun("h")}}},[t._v("下载湿度")])],1)]),e("div",{staticClass:"demoDra2"},[e("el-table",{attrs:{data:t.tableData1,border:"",size:"small"}},[e("el-table-column",{attrs:{label:"设备编号"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.T_id)+" ")]}}])}),e("el-table-column",{attrs:{label:"证书编号"},scopedSlots:t._u([{key:"default",fn:function(a){return[e("span",[t._v(t._s(a.row.T_Certificate_sn))])]}}])}),e("el-table-column",{attrs:{label:"温度℃"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.T_t)+" ")]}}])}),e("el-table-column",{attrs:{label:"湿度%"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.T_rh)+" ")]}}])}),e("el-table-column",{attrs:{label:"时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(e.row.T_time)+" ")]}}])})],1)],1),e("div",{staticClass:"demoDra3"},[e("el-pagination",{attrs:{"current-page":t.pages1.page,"page-size":t.pages1.page_z,layout:"total, prev, pager, next, jumper",total:t.total1},on:{"current-change":t.handleCurrentChange1}})],1)])]),e("el-drawer",{ref:"drawer",attrs:{title:"校准证书",visible:t.Drawer1,direction:"rtl",size:"50%"},on:{"update:visible":function(e){t.Drawer1=e}}},[e("div",{staticClass:"demo-drawers"},[e("div",{staticStyle:{"margin-bottom":"20px","font-size":"14px",color:"#C0C4CC"}},[t._v("请选择对应的校准证书查看:")]),e("div",{staticClass:"demo-drawers-mins"},t._l(t.radioXuan,(function(a,n){return e("div",{key:n,staticClass:"demo-drawers-mins-item",on:{click:function(e){return t.radioInput(a)}}},[t._v(" 【"+t._s(a.T_id)+"】"+t._s(a.T_Certificate_sn)+" ")])})),0)])]),e("pdf",{ref:"pdf"})],1)},i=[],s=function(){var t=this,e=t._self._c;return e("div",[e("el-dialog",{attrs:{visible:t.dialogVisible4,width:"80%",height:"100%"},on:{"update:visible":function(e){t.dialogVisible4=e}}},[e("iframe",{staticStyle:{width:"100%",height:"80vh"},attrs:{src:t.serPdf,frameborder:"0"}})])],1)},r=[],o=a(9834),l={name:"CompanyAccount",components:{pdf:o.Z},data(){return{dialogVisible4:!1,serPdf:""}},methods:{SetPdf(t){this.dialogVisible4=!0,this.serPdf=t}}},d=l,c=a(1001),u=(0,c.Z)(d,s,r,!1,null,"09d2b27e",null),p=u.exports,f=a(5448),m=a.n(f),h=a(8638),_=a(9171),g={name:"CompanyAccount",components:{pdf:p},data(){return{Drawer:!1,Drawer1:!1,src:"",dia:null,total:0,total1:0,pages:{page:1,page_z:10,T_name:""},pickerTime:[],defaultpickerTime:[],pages1:{T_task_id:"",T_sn:"",T_id:"",Time_start:"",Time_end:"",page:1,page_z:10},radioXuan:[],radio1:"",tableData:[],tableData1:[]}},computed:{pickerOptions(){let t=this;return{disabledDate(e){const a=new Date(t.defaultpickerTime[0]),n=new Date(t.defaultpickerTime[1]);return e.getTime()n.getTime()}}}},mounted(){this.GetTkListApi()},methods:{radioInput(t){t.T_pdf?this.$refs.pdf.SetPdf(t.T_pdf):this.$message.error("没有可展示证书哦")},GetTkListApi(){(0,h.ax)(this.pages).then((t=>{200===t.data.Code&&(this.tableData=t.data.Data.List,this.total=t.data.Data.Num)}))},handleEdit1(t){this.$refs.pdf.SetPdf(t.T_pdf1)},handleEdit2(t){this.$refs.pdf.SetPdf(t.T_pdf2)},handleEdit3(t){const{T_class:e}={...t};(0,h.Aj)({T_class:e}).then((t=>{200==t.data.Code&&(this.Drawer1=!0,this.radioXuan=t.data.Data.List||[])}))},handleEdit4(t){this.pages1.T_task_id=t.T_task_id,this.defaultpickerTime=t.T_VerifyDeviceDataTime,this.pickerTime=this.defaultpickerTime,this.pages1.Time_start=this.pickerTime[0],this.pages1.Time_end=this.pickerTime[1],this.GetExtDataApi()},GetExtDataApi(){(0,h.Gj)(this.pages1).then((t=>{this.Drawer=!0,200===t.data.Code&&(this.tableData1=t.data.Data.List,this.total1=t.data.Data.Num)}))},Dowload(){var t={T_task_id:this.pages1.T_task_id,T_sn_list:"",Time_start:this.pages1.Time_start,Time_end:this.pages1.Time_end};const e=this.$loading({lock:!0,text:"正在整理数据,请稍后...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"});(0,h.Z)(t).then((t=>{200===t.data.Code&&(e.close(),m()(t.data.Data))}))},async downloadFun(t){let{T_sn:e,page:a,page_z:n,...i}=this.pages1;const s=this.$loading({lock:!0,text:"正在整理数据,请稍后...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),r="t"==t?await(0,h.u8)(i):await(0,h.Fd)(i);s.close(),r.status&&(0,_.W)(r,"t"==t?"温度":"湿度")},searchTimeData(t){null!=t?(this.pages1.Time_start=t[0],this.pages1.Time_end=t[1]):(this.pages1.Time_start="",this.pages1.Time_end=""),this.pages1.page=1,this.GetExtDataApi()},search(t){0==t?(this.pages.page=1,this.GetTkListApi()):(this.pages1.page=1,this.GetExtDataApi())},handleCurrentChange(t){this.pages.page=t,this.GetTkListApi()},handleCurrentChange1(t){this.pages1.page=t,this.GetExtDataApi()}}},b=g,T=(0,c.Z)(b,n,i,!1,null,"60040b59",null),v=T.exports},5448:function(t,e,a){var n,i,s;a(2801),function(a,r){i=[],n=r,s="function"===typeof n?n.apply(e,i):n,void 0===s||(t.exports=s)}(0,(function(){return function t(e,a,n){var i,s,r=window,o="application/octet-stream",l=n||o,d=e,c=!a&&!n&&d,u=document.createElement("a"),p=function(t){return String(t)},f=r.Blob||r.MozBlob||r.WebKitBlob||p,m=a||"download";if(f=f.call?f.bind(r):Blob,"true"===String(this)&&(d=[d,l],l=d[0],d=d[1]),c&&c.length<2048&&(m=c.split("/").pop().split("?")[0],u.href=c,-1!==u.href.indexOf(c))){var h=new XMLHttpRequest;return h.open("GET",c,!0),h.responseType="blob",h.onload=function(e){t(e.target.response,m,o)},setTimeout((function(){h.send()}),0),h}if(/^data:([\w+-]+\/[\w+.-]+)?[,;]/.test(d)){if(!(d.length>2096103.424&&f!==p))return navigator.msSaveBlob?navigator.msSaveBlob(T(d),m):v(d);d=T(d),l=d.type||o}else if(/([\x80-\xff])/.test(d)){var _=0,g=new Uint8Array(d.length),b=g.length;for(_;_