mirror of
https://github.com/hpd840321/starRiverProperty.git
synced 2026-06-10 17:00:30 +08:00
4f79e10bd6
Former-commit-id: 376f94edd602d3dfed1cbada6e08361ee7b08e73
1 line
6.9 KiB
JavaScript
1 line
6.9 KiB
JavaScript
webpackJsonp([73],{JM2R:function(e,t,a){(e.exports=a("FZ+f")(!1)).push([e.i,"\n.upadd-card[data-v-ac6332aa] {\n margin-bottom: 100px;\n padding-bottom: 18px;\n}\n",""])},htKO:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=a("Dd8w"),r=a.n(n),s=a("Gu7T"),i=a.n(s),o=a("hpEt"),l=a("xT6B"),c={components:{searchPage:a("vMX1").a},data:function(){return{formateDate:l.a,searchForm:{rowsOfPage:10,currentPage:1,deviceTypeId:"",serviceCode:""},engineTypes:[],serviceTypes:[],logoutDialog:!1,logoutTitle:"",packageList:[{label:"增量",value:"1"},{label:"全量",value:"2"}],tableData:[],loading:!1,showEdit:!1,total:0,tableLoading:!1}},created:function(){this.fetchData(),this.fetchTypeList(),this.fetchApplicationList()},methods:{fetchApplicationList:function(){var e=this;o.a.applicationList().then(function(t){e.serviceTypes=[{label:"全部",value:""}].concat(i()(t))}).catch(function(t){e.$message.error(t.message)})},fetchTypeList:function(){var e=this;o.a.typeList().then(function(t){e.engineTypes=t,e.engineTypes.unshift({label:"全部",value:""})}).catch(function(t){e.$message.error(t.message)})},searchData:function(){this.searchForm.currentPage=1,this.fetchData()},fetchData:function(e){var t=this;this.tableLoading=!0;var a=this.serviceTypes.find(function(e){return e.value===t.searchForm.serviceCode})||{};o.a.fileSearch(r()({},this.searchForm,{serviceCodeName:"全部"===a.label?"":a.label})).then(function(e){setTimeout(function(){t.tableData=e.data,t.total=e.total,t.tableLoading=!1},500)}).catch(function(e){t.tableLoading=!1,t.$message.error(e.message)})},disable:function(e){var t=this;this.$confirm("是否确定注销?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){t.$set(e,"loading",!0),o.a.disable(e.id).then(function(a){t.$set(e,"loading",!1),t.$message.success(a.message),t.fetchData()}).catch(function(a){t.$set(e,"loading",!1),t.$message.error(a.message),t.fetchData()})}).catch(function(){})},enable:function(e){var t=this;this.$set(e,"loading",!0),o.a.enable(e.id).then(function(a){t.$set(e,"loading",!1),t.$message.success(a.message),t.fetchData()}).catch(function(a){t.$message.error(a.message),t.$set(e,"loading",!1),t.fetchData()})},del:function(e){var t=this;this.$confirm("提示:版本删除后,无法恢复,请谨慎操作!","确认删除所选择的版本吗?",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){t.$set(e,"loading",!0),o.a.fileDel(e.id).then(function(a){t.$set(e,"loading",!1),t.fetchData(),t.$message.success(a.message)}).catch(function(a){t.$set(e,"loading",!1),t.$message.error(a.message),t.fetchData()})}).catch(function(){})},resetSearch:function(){this.searchForm={rowsOfPage:10,currentPage:1},this.fetchData()},handleSizeChange:function(e){this.searchForm.rowsOfPage=e,this.fetchData()},handleCurrentChange:function(e){this.searchForm.currentPage=e,this.fetchData()}}},u={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"app-container"},[a("el-card",{staticClass:"upadd-card",attrs:{shadow:"hover"}},[a("search-page",{attrs:{pageSize:e.searchForm.rowsOfPage,pageNum:e.searchForm.currentPage,total:e.total},on:{"update:pageSize":function(t){return e.$set(e.searchForm,"rowsOfPage",t)},"update:page-size":function(t){return e.$set(e.searchForm,"rowsOfPage",t)},"update:pageNum":function(t){return e.$set(e.searchForm,"currentPage",t)},"update:page-num":function(t){return e.$set(e.searchForm,"currentPage",t)},change:e.fetchData}},[a("el-form",{attrs:{inline:"","label-width":"70px"}},[a("el-form-item",{attrs:{label:"升级文件名称","label-width":"100px"}},[a("el-input",{attrs:{placeholder:"请输入文件名称",maxlength:"32"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.searchData(t)}},model:{value:e.searchForm.name,callback:function(t){e.$set(e.searchForm,"name","string"==typeof t?t.trim():t)},expression:"searchForm.name"}})],1),e._v(" "),a("el-form-item",{attrs:{label:"设备类型","label-width":"100px"}},[a("el-select",{model:{value:e.searchForm.deviceTypeId,callback:function(t){e.$set(e.searchForm,"deviceTypeId",t)},expression:"searchForm.deviceTypeId"}},e._l(e.engineTypes,function(e,t){return a("el-option",{key:t,attrs:{label:e.label,value:e.value}})}),1)],1),e._v(" "),a("el-form-item",{attrs:{label:"应用类型"}},[a("el-select",{model:{value:e.searchForm.serviceCode,callback:function(t){e.$set(e.searchForm,"serviceCode",t)},expression:"searchForm.serviceCode"}},e._l(e.serviceTypes,function(e,t){return a("el-option",{key:t,attrs:{label:e.label,value:e.value}})}),1)],1),e._v(" "),a("el-form-item",[a("el-button",{directives:[{name:"permission",rawName:"v-permission",value:[e.$auth.mulDeviceFileSearch],expression:"[$auth.mulDeviceFileSearch]"}],attrs:{type:"warning"},on:{click:e.searchData}},[e._v("查询")]),e._v(" "),a("el-button",{directives:[{name:"permission",rawName:"v-permission",value:[e.$auth.mulDeviceFileSearch],expression:"[$auth.mulDeviceFileSearch]"}],attrs:{type:"default"},on:{click:e.resetSearch}},[e._v("重置")]),e._v(" "),a("router-link",{attrs:{to:{name:"fileMulAdd"}}},[a("el-button",{directives:[{name:"permission",rawName:"v-permission",value:[e.$auth.mulDeviceFileAdd],expression:"[$auth.mulDeviceFileAdd]"}],staticStyle:{"margin-left":"10px"},attrs:{type:"primary"}},[e._v("新建")])],1)],1)],1),e._v(" "),a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.tableLoading,expression:"tableLoading"}],staticStyle:{width:"100%"},attrs:{data:e.tableData}},[a("el-table-column",{attrs:{type:"index",width:"50",label:"序号"}}),e._v(" "),a("el-table-column",{attrs:{prop:"name",label:"升级文件名称"}}),e._v(" "),a("el-table-column",{attrs:{prop:"deviceTypeName",label:"设备类型"}}),e._v(" "),a("el-table-column",{attrs:{prop:"serviceCodeName",label:"应用类型"}}),e._v(" "),a("el-table-column",{attrs:{prop:"previousVersion",label:"上一版本号"}}),e._v(" "),a("el-table-column",{attrs:{prop:"remark",label:"升级备注","show-overflow-tooltip":""}}),e._v(" "),a("el-table-column",{attrs:{prop:"createTime",label:"创建时间"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(e._s(t.row.createTime?e.formateDate(new Date(t.row.createTime),"yyyy-MM-dd hh:mm:ss"):""))]}}])}),e._v(" "),a("el-table-column",{attrs:{label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("router-link",{attrs:{to:{name:"fileMulDetail",query:{id:t.row.id}}}},[a("el-button",{directives:[{name:"permission",rawName:"v-permission",value:[e.$auth.mulDeviceFileDetail],expression:"[$auth.mulDeviceFileDetail]"}],attrs:{type:"text"}},[e._v("详情")])],1)]}}])})],1)],1)],1)],1)},staticRenderFns:[]};var h=a("VU/8")(c,u,!1,function(e){a("qjZ9")},"data-v-ac6332aa",null);t.default=h.exports},qjZ9:function(e,t,a){var n=a("JM2R");"string"==typeof n&&(n=[[e.i,n,""]]),n.locals&&(e.exports=n.locals);a("rjj0")("4a8df7ea",n,!0)}}); |