1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-b7fa7158"],{"0815":function(e,t,o){"use strict";o.r(t);var r=function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"m-container"},[e._m(0),e._v(" "),o("div",{staticClass:"m-core"},[o("div",{directives:[{name:"permission",rawName:"v-permission",value:"appVersionInfo/add",expression:"'appVersionInfo/add'"}],staticClass:"newBand",on:{click:e.createEdi}},[e._v("新建")]),e._v(" "),o("el-form",{attrs:{inline:!0,model:e.searchForm}},[o("el-form-item",{attrs:{label:"客户端"}},[o("el-select",{attrs:{clearable:""},model:{value:e.searchForm.search,callback:function(t){e.$set(e.searchForm,"search",t)},expression:"searchForm.search"}},e._l(e.sectionList,(function(e,t){return o("el-option",{key:t,attrs:{value:e.value,label:e.label}})})),1)],1),e._v(" "),o("el-form-item",[o("el-button",{attrs:{type:"danger"},on:{click:e.search}},[e._v("搜索")])],1)],1),e._v(" "),o("div",{staticClass:"tableWrap"},[o("el-table",{attrs:{data:e.tableList,"header-cell-style":{background:"#EDEEF0",color:"#444"}}},[o("el-table-column",{attrs:{align:"center",prop:"id",label:"编号"}}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"platform",label:"客户端"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("div",[e._v(e._s(e._f("editionFilter")(t.row.platform)))])]}}])}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"version",label:"版本号"}}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"isForceUpdate",label:"强制更新"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("div",[e._v(e._s(t.row.isForceUpdate?"是":"否"))])]}}])}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"status",label:"状态"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("div",[e._v(e._s(e._f("statusFilter")(t.row.status)))])]}}])}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"description",label:"描述"}}),e._v(" "),o("el-table-column",{attrs:{align:"center",prop:"downloadUrl",width:"120",label:"下载链接"},scopedSlots:e._u([{key:"default",fn:function(e){return[o("overflow-text",{attrs:{width:"120px",text:e.row.downloadUrl}})]}}])}),e._v(" "),o("el-table-column",{attrs:{align:"center",label:"操作"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("div",[o("el-button",{directives:[{name:"permission",rawName:"v-permission",value:"appVersionInfo/update",expression:"'appVersionInfo/update'"}],attrs:{type:"text"},on:{click:function(o){return e.resetEdit(t.row)}}},[e._v("修改")])],1)]}}])})],1),e._v(" "),o("pagination",{attrs:{total:e.rules.total,page:e.rules.page,limit:e.rules.limit,"page-sizes":e.rules.page_size},on:{"update:page":function(t){return e.$set(e.rules,"page",t)},"update:limit":function(t){return e.$set(e.rules,"limit",t)},pagination:e.getList}})],1)],1),e._v(" "),o("el-dialog",{attrs:{title:"版本修改",width:"400px",visible:e.sectionVisible,"before-close":e.resetForm},on:{"update:visible":function(t){e.sectionVisible=t}}},[e.sectionVisible?o("el-form",{ref:"sectionForm",attrs:{model:e.sectionForm,rules:e.sectionRules,"label-position":"right","label-width":"80px",inline:!0}},[e.isNew?o("el-form-item",{attrs:{label:"客户端",prop:"platform"}},[o("el-select",{attrs:{clearable:""},model:{value:e.sectionForm.platform,callback:function(t){e.$set(e.sectionForm,"platform",t)},expression:"sectionForm.platform"}},e._l(e.sectionList,(function(e,t){return o("el-option",{key:t,attrs:{label:e.label,value:e.value}})})),1)],1):e._e(),e._v(" "),e.isNew?o("el-form-item",{attrs:{label:"版本号",prop:"version"}},[o("el-input",{nativeOn:{mousewheel:function(e){e.preventDefault()}},model:{value:e.sectionForm.version,callback:function(t){e.$set(e.sectionForm,"version","string"===typeof t?t.trim():t)},expression:"sectionForm.version"}})],1):e._e(),e._v(" "),o("el-form-item",{attrs:{label:"强制更新",prop:"isForceUpdate"}},[o("el-select",{attrs:{clearable:""},model:{value:e.sectionForm.isForceUpdate,callback:function(t){e.$set(e.sectionForm,"isForceUpdate",t)},expression:"sectionForm.isForceUpdate"}},[o("el-option",{attrs:{label:"是",value:!0}}),e._v(" "),o("el-option",{attrs:{label:"否",value:!1}})],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"状态",prop:"status"}},[o("el-select",{attrs:{clearable:""},model:{value:e.sectionForm.status,callback:function(t){e.$set(e.sectionForm,"status",t)},expression:"sectionForm.status"}},[o("el-option",{attrs:{label:"最新",value:"newest"}}),e._v(" "),o("el-option",{attrs:{label:"历史",value:"history"}})],1)],1),e._v(" "),o("el-form-item",{attrs:{label:"下载链接",prop:"downloadUrl"}},[o("el-input",{attrs:{type:"textarea"},model:{value:e.sectionForm.downloadUrl,callback:function(t){e.$set(e.sectionForm,"downloadUrl","string"===typeof t?t.trim():t)},expression:"sectionForm.downloadUrl"}})],1),e._v(" "),o("el-form-item",{attrs:{label:"描述",prop:"description"}},[o("el-input",{attrs:{type:"textarea"},model:{value:e.sectionForm.description,callback:function(t){e.$set(e.sectionForm,"description",t)},expression:"sectionForm.description"}})],1)],1):e._e(),e._v(" "),o("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.sectionVisible=!1}}},[e._v("取 消")]),e._v(" "),e.isNew?o("el-button",{attrs:{type:"primary"},on:{click:e.createEdition}},[e._v("确 定")]):e._e(),e._v(" "),e.isNew?e._e():o("el-button",{attrs:{type:"primary"},on:{click:e.resetEdition}},[e._v("确 定")])],1)],1)],1)},i=[function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("h2",[o("div",{staticClass:"squrt"}),e._v("版本控制\n ")])}],s=o("db72"),a=(o("386d"),o("99b4")),n=o("333d");const l="function"===typeof atob,c="function"===typeof Buffer,u="function"===typeof TextDecoder?new TextDecoder:void 0,d=("function"===typeof TextEncoder&&new TextEncoder,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),p=[...d],m=(e=>{let t={};return e.forEach((e,o)=>t[e]=o),t})(p),f=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,b=String.fromCharCode.bind(String),v="function"===typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):(e,t=(e=>e))=>new Uint8Array(Array.prototype.slice.call(e,0).map(t)),h=e=>e.replace(/[^A-Za-z0-9\+\/]/g,""),F=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,g=e=>{switch(e.length){case 4:var t=(7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3),o=t-65536;return b(55296+(o>>>10))+b(56320+(1023&o));case 3:return b((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return b((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},_=e=>e.replace(F,g),w=e=>{if(e=e.replace(/\s+/g,""),!f.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(3&e.length));let t,o,r,i="";for(let s=0;s<e.length;)t=m[e.charAt(s++)]<<18|m[e.charAt(s++)]<<12|(o=m[e.charAt(s++)])<<6|(r=m[e.charAt(s++)]),i+=64===o?b(t>>16&255):64===r?b(t>>16&255,t>>8&255):b(t>>16&255,t>>8&255,255&t);return i},y=l?e=>atob(h(e)):c?e=>Buffer.from(e,"base64").toString("binary"):w,x=c?e=>v(Buffer.from(e,"base64")):e=>v(y(e),e=>e.charCodeAt(0)),A=c?e=>Buffer.from(e,"base64").toString("utf8"):u?e=>u.decode(x(e)):e=>_(y(e)),k=e=>h(e.replace(/[-_]/g,e=>"-"==e?"+":"/")),U=e=>A(k(e));var E={components:{pagination:n["a"]},data:function(){return{sectionVisible:!1,tableList:[],rules:{limit:10,page:1,total:0,page_size:[10,20,40,50]},searchForm:{search:null},sectionList:[{value:"ios-teacher",label:"苹果-老师端"},{value:"ios-student",label:"苹果-学生端"},{value:"ios-education",label:"苹果-教务端"},{value:"android-teacher",label:"安卓-老师端"},{value:"android-student",label:"安卓-学生端"},{value:"android-education",label:"安卓-教务端"}],sectionForm:{platform:"",version:"",isForceUpdate:"",downloadUrl:"",status:"",id:""},sectionRules:{platform:[{required:!0,message:"请选择客户端",trigger:"blur"}],version:[{required:!0,message:"请输入版本号",trigger:"blur"}],isForceUpdate:[{required:!0,message:"请选择是否强更",trigger:"blur"}],status:[{required:!0,message:"请选择版本状态",trigger:"blur"}]},isNew:!1}},activated:function(){this.init()},created:function(){this.init()},methods:{search:function(){this.rules.page=1,this.getList()},init:function(){this.getList()},getList:function(){var e=this;this.searchForm.search?this.searchForm.search:this.searchForm.search=null,Object(a["b"])({search:this.searchForm.search,page:this.rules.page,rows:this.rules.limit}).then((function(t){200==t.code&&(e.tableList=t.data.rows.map((function(e){return Object(s["a"])(Object(s["a"])({},e),{},{downloadUrl:U(e.downloadUrl||"")})})),e.rules.total=t.data.total)}))},createEdi:function(){this.isNew=!0,this.sectionVisible=!0},createEdition:function(){var e=this;this.$refs.sectionForm.validate((function(t){t&&Object(a["a"])(e.sectionForm).then((function(t){200==t.code&&(e.$message.success("新增成功"),e.sectionVisible=!1,e.getList())}))}))},resetEdit:function(e){this.isNew=!1,this.sectionForm=e,this.sectionVisible=!0},resetEdition:function(){var e=this;Object(a["C"])(this.sectionForm).then((function(t){200==t.code&&(e.$message.success("修改成功"),e.sectionVisible=!1,e.getList())}))},resetForm:function(){this.sectionForm={platform:"",version:"",isForceUpdate:"",downloadUrl:"",status:"",id:""},this.$refs.sectionForm.resetFields(),this.sectionVisible=!1}},filters:{statusFilter:function(e){return"newest"==e?"最新":"history"==e?"历史":""}}},C=E,$=o("2877"),V=Object($["a"])(C,r,i,!1,null,null,null);t["default"]=V.exports},"09f4":function(e,t,o){"use strict";o.d(t,"a",(function(){return a})),Math.easeInOutQuad=function(e,t,o,r){return e/=r/2,e<1?o/2*e*e+t:(e--,-o/2*(e*(e-2)-1)+t)};var r=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function i(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function s(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function a(e,t,o){var a=s(),n=e-a,l=20,c=0;t="undefined"===typeof t?500:t;var u=function e(){c+=l;var s=Math.easeInOutQuad(c,a,n,t);i(s),c<t?r(e):o&&"function"===typeof o&&o()};u()}}}]);
|