1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([[47],{2763:function(e,t,a){"use strict";a.r(t);var n=function(){var e=this,t=e._self._c;return t("div",[t("transition",{attrs:{appear:"","enter-active-class":"animated fadeIn"}},[t("q-table",{staticClass:"my-sticky-header-table shadow-24",attrs:{data:e.table_list,"row-key":"id",separator:e.separator,loading:e.loading,filter:e.filter,columns:e.columns,"hide-bottom":"",pagination:e.pagination,"no-data-label":"No data","no-results-label":"No data you want","table-style":{height:e.height},flat:"",bordered:""},on:{"update:pagination":function(t){e.pagination=t}},scopedSlots:e._u([{key:"top",fn:function(){return[t("q-btn-group",{attrs:{push:""}},[t("q-btn",{attrs:{label:e.$t("refresh"),icon:"refresh"},on:{click:function(t){return e.reFresh()}}},[t("q-tooltip",{attrs:{"content-class":"bg-amber text-black shadow-4",offset:[10,10],"content-style":"font-size: 12px"}},[e._v("\n "+e._s(e.$t("refreshtip"))+"\n ")])],1)],1),t("q-space"),t("q-input",{directives:[{name:"show",rawName:"v-show",value:e.$q.platform.is.desktop,expression:"$q.platform.is.desktop"}],attrs:{outlined:"",rounded:"",dense:"",debounce:"300",color:"primary",placeholder:e.$t("search")},scopedSlots:e._u([{key:"append",fn:function(){return[t("q-icon",{attrs:{name:"search"}})]},proxy:!0}]),model:{value:e.filter,callback:function(t){e.filter=t},expression:"filter"}})]},proxy:!0},{key:"body",fn:function(a){return[t("q-tr",{attrs:{props:a}},[t("q-td",{key:"bin_property",attrs:{props:a}},[e._v("\n "+e._s(a.row.bin_property)+"\n ")]),t("q-td",{key:"creater",attrs:{props:a}},[e._v("\n "+e._s(a.row.creater)+"\n ")]),t("q-td",{key:"create_time",attrs:{props:a}},[e._v("\n "+e._s(a.row.create_time)+"\n ")]),t("q-td",{key:"update_time",attrs:{props:a}},[e._v("\n "+e._s(a.row.update_time)+"\n ")])],1)]}}])})],1),[t("div",{directives:[{name:"show",rawName:"v-show",value:0!==e.max,expression:"max !== 0"}],staticClass:"q-pa-lg flex flex-center"},[t("div",[e._v(e._s(e.total)+" ")]),t("q-pagination",{attrs:{color:"black",max:e.max,"max-pages":6,"boundary-links":""},on:{click:function(t){return e.getList()}},model:{value:e.current,callback:function(t){e.current=t},expression:"current"}}),t("div",[t("input",{directives:[{name:"model",rawName:"v-model",value:e.paginationIpt,expression:"paginationIpt"}],staticStyle:{width:"60px","text-align":"center"},domProps:{value:e.paginationIpt},on:{blur:e.changePageEnter,keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.changePageEnter.apply(null,arguments)},input:function(t){t.target.composing||(e.paginationIpt=t.target.value)}}})])],1),t("div",{directives:[{name:"show",rawName:"v-show",value:0===e.max,expression:"max === 0"}],staticClass:"q-pa-lg flex flex-center"},[t("q-btn",{attrs:{flat:"",push:"",color:"dark",label:e.$t("no_data")}})],1)]],2)},r=[],i=a("3004"),o=a("18d6"),p={name:"Pagebinproperty",data(){return{openid:"",login_name:"",authin:"0",pathname:"binproperty/",pathname_previous:"",pathname_next:"",separator:"cell",loading:!1,height:"",table_list:[],columns:[{name:"bin_property",required:!0,label:this.$t("warehouse.view_property.bin_property"),align:"left",field:"bin_property"},{name:"creater",label:this.$t("creater"),field:"Creater",align:"center"},{name:"create_time",label:this.$t("createtime"),field:"create_time",align:"center"},{name:"update_time",label:this.$t("updatetime"),field:"update_time",align:"center"}],filter:"",pagination:{page:1,rowsPerPage:"30"},current:1,max:0,total:0,paginationIpt:1}},methods:{getList(){var e=this;o["a"].has("auth")&&Object(i["f"])(e.pathname+"?page="+e.current,{}).then((t=>{e.table_list=t.results,e.total=t.count,0===t.count||1===Math.ceil(t.count/30)?e.max=0:e.max=Math.ceil(t.count/30),"zh-hans"===o["a"].getItem("lang")&&e.table_list.forEach(((e,t)=>{"Damage"===e.bin_property?e.bin_property="破损":"Inspection"===e.bin_property?e.bin_property="质检":"Holding"===e.bin_property?e.bin_property="锁货":"Normal"===e.bin_property&&(e.bin_property="正常库位")})),e.pathname_previous=t.previous,e.pathname_next=t.next})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},changePageEnter(e){Number(this.paginationIpt)<1?(this.current=1,this.paginationIpt=1):Number(this.paginationIpt)>this.max?(this.current=this.max,this.paginationIpt=this.max):this.current=Number(this.paginationIpt),this.getList()},getListPrevious(){var e=this;o["a"].has("auth")&&Object(i["f"])(e.pathname_previous,{}).then((t=>{e.table_list=t.results,"zh-hans"===o["a"].getItem("lang")&&e.table_list.forEach(((e,t)=>{"Damage"===e.bin_property?e.bin_property="破损":"Inspection"===e.bin_property?e.bin_property="质检":"Holding"===e.bin_property?e.bin_property="锁货":"Normal"===e.bin_property&&(e.bin_property="正常库位")})),e.pathname_previous=t.previous,e.pathname_next=t.next})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},getListNext(){var e=this;o["a"].has("auth")&&Object(i["f"])(e.pathname_next,{}).then((t=>{e.table_list=t.results,"zh-hans"===o["a"].getItem("lang")&&e.table_list.forEach(((e,t)=>{"Damage"===e.bin_property?e.bin_property="破损":"Inspection"===e.bin_property?e.bin_property="质检":"Holding"===e.bin_property?e.bin_property="锁货":"Normal"===e.bin_property&&(e.bin_property="正常库位")})),e.pathname_previous=t.previous,e.pathname_next=t.next})).catch((t=>{e.$q.notify({message:t.detail,icon:"close",color:"negative"})}))},reFresh(){var e=this;e.getList()}},created(){var e=this;o["a"].has("openid")?e.openid=o["a"].getItem("openid"):(e.openid="",o["a"].set("openid","")),o["a"].has("login_name")?e.login_name=o["a"].getItem("login_name"):(e.login_name="",o["a"].set("login_name","")),o["a"].has("auth")?(e.authin="1",e.getList()):e.authin="0"},mounted(){var e=this;e.$q.platform.is.electron?e.height=String(e.$q.screen.height-290)+"px":e.height=e.$q.screen.height-290+"px"},updated(){},destroyed(){}},s=p,l=a("42e1"),c=a("d30f"),u=a("eaac"),h=a("e7a9"),d=a("9c40"),m=a("05c0"),g=a("2c91"),b=a("27f9"),_=a("0016"),f=a("bd08"),y=a("db86"),v=a("3b16"),x=a("eebe"),w=a.n(x),k=Object(l["a"])(s,n,r,!1,null,null,null);"function"===typeof c["default"]&&Object(c["default"])(k);t["default"]=k.exports;w()(k,"components",{QTable:u["a"],QBtnGroup:h["a"],QBtn:d["a"],QTooltip:m["a"],QSpace:g["a"],QInput:b["a"],QIcon:_["a"],QTr:f["a"],QTd:y["a"],QPagination:v["a"]})},"7c04":function(e,t){},d30f:function(e,t,a){"use strict";var n=a("7c04"),r=a.n(n);t["default"]=r.a}}]);
|