bi-element-ui 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/css/about.ba384392.css +1 -0
- package/dist/index.html +1 -1
- package/dist/js/about.f95f1b1d.js +2 -0
- package/dist/js/{index.b59d3038.js → index.ccf79dfe.js} +2 -2
- package/lib/bi-element-ui.common.js +10 -9
- package/lib/bi-element-ui.umd.js +10 -9
- package/lib/bi-element-ui.umd.min.js +1 -1
- package/package.json +1 -1
- package/src/views/Date.vue +38 -16
- package/dist/css/about.5b6fef7c.css +0 -1
- package/dist/js/about.93275045.js +0 -2
@@ -0,0 +1 @@
|
|
1
|
+
.example-table-box[data-v-a478ee98]{margin:25px 50px}.example-table-box p[data-v-a478ee98]{text-align:left;font-weight:700}
|
package/dist/index.html
CHANGED
@@ -1 +1 @@
|
|
1
|
-
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=favicon.ico><title>bi-element-ui</title><link href=css/about.
|
1
|
+
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=favicon.ico><title>bi-element-ui</title><link href=css/about.ba384392.css rel=prefetch><link href=js/about.f95f1b1d.js rel=prefetch><link href=css/chunk-vendors.8140bef9.css rel=preload as=style><link href=css/index.1a2b0a2e.css rel=preload as=style><link href=js/chunk-vendors.a9a38d93.js rel=preload as=script><link href=js/index.ccf79dfe.js rel=preload as=script><link href=css/chunk-vendors.8140bef9.css rel=stylesheet><link href=css/index.1a2b0a2e.css rel=stylesheet></head><body><noscript><strong>We're sorry but bi-element-ui doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=js/chunk-vendors.a9a38d93.js></script><script src=js/index.ccf79dfe.js></script></body></html>
|
@@ -0,0 +1,2 @@
|
|
1
|
+
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["about"],{"3a43":function(e,a,t){"use strict";t.r(a);var l=function(){var e=this,a=e.$createElement,t=e._self._c||a;return t("div",{staticClass:"free-table"},[t("div",{staticClass:"example-table-box"},[t("p",[e._v("基础日期-"+e._s(e.date))]),t("BiDatePicker",{attrs:{type:"date",placeholder:"选择日期"},model:{value:e.date,callback:function(a){e.date=a},expression:"date"}})],1),t("div",{staticClass:"example-table-box"},[t("p",[e._v("基础周-"+e._s(e.date1))]),t("BiDatePicker",{attrs:{type:"week",placeholder:"选择周"},model:{value:e.date1,callback:function(a){e.date1=a},expression:"date1"}})],1),t("div",{staticClass:"example-table-box"},[t("p",[e._v("基础月-"+e._s(e.date2))]),t("BiDatePicker",{attrs:{type:"month",placeholder:"选择周"},model:{value:e.date2,callback:function(a){e.date2=a},expression:"date2"}})],1),t("div",{staticClass:"example-table-box"},[t("p",[e._v("范围日期-"+e._s(e.date3))]),t("BiDatePicker",{attrs:{type:"daterange",placeholder:"选择日期1","picker-option":e.pickerOptions1},model:{value:e.date3,callback:function(a){e.date3=a},expression:"date3"}}),t("p",[e._v("范围日期-"+e._s(e.date7))]),t("BiDatePicker",{attrs:{type:"daterange",placeholder:"选择日期2","picker-option":e.pickerOptions2},model:{value:e.date7,callback:function(a){e.date7=a},expression:"date7"}})],1),t("div",{staticClass:"example-table-box"},[t("p",[e._v("范围月-"+e._s(e.date5))]),t("BiDatePicker",{attrs:{type:"monthrange",placeholder:"选择日期",format:"yyyy-MM"},model:{value:e.date5,callback:function(a){e.date5=a},expression:"date5"}})],1),t("div",{staticClass:"example-table-box"},[t("p",[e._v("范围日期时间-"+e._s(e.date6))]),t("BiDatePicker",{attrs:{type:"datetimerange",format:"yyyy-MM-dd HH:mm:ss","value-format":"yyyy-MM-dd HH:mm:ss","default-time":["00:00:00","23:59:59"],"range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},model:{value:e.date6,callback:function(a){e.date6=a},expression:"date6"}})],1)])},i=[],s=t("caaf"),o=t.n(s),d={components:{},data(){return{date:"",date1:"",date2:"",date3:[],date4:[],date5:[],date6:[],date7:[],columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1,pickerOptions1:{firstDayOfWeek:1,onPick:({minDate:e,maxDate:a})=>{console.log(1,o()(e).format("YYYY-MM-DD"))}},pickerOptions2:{firstDayOfWeek:1,onPick:({minDate:e,maxDate:a})=>{console.log(2,o()(e).format("YYYY-MM-DD"))}}}},methods:{selectionChange(e){console.log("selected",e)},getList(){},openDialog({row:e}){this.editForm=Object.assign({},e),this.dialogVisible=!0}}},c=d,n=(t("8d0b"),t("cba8")),r=Object(n["a"])(c,l,i,!1,null,"a478ee98",null);a["default"]=r.exports},"8d0b":function(e,a,t){"use strict";t("e1f4")},e1f4:function(e,a,t){}}]);
|
2
|
+
//# sourceMappingURL=about.f95f1b1d.js.map
|
@@ -1,2 +1,2 @@
|
|
1
|
-
(function(e){function t(t){for(var n,s,o=t[0],r=t[1],c=t[2],d=0,u=[];d<o.length;d++)s=o[d],Object.prototype.hasOwnProperty.call(l,s)&&l[s]&&u.push(l[s][0]),l[s]=0;for(n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);p&&p(t);while(u.length)u.shift()();return i.push.apply(i,c||[]),a()}function a(){for(var e,t=0;t<i.length;t++){for(var a=i[t],n=!0,s=1;s<a.length;s++){var o=a[s];0!==l[o]&&(n=!1)}n&&(i.splice(t--,1),e=r(r.s=a[0]))}return e}var n={},s={index:0},l={index:0},i=[];function o(e){return r.p+"js/"+({about:"about"}[e]||e)+"."+{about:"93275045"}[e]+".js"}function r(t){if(n[t])return n[t].exports;var a=n[t]={i:t,l:!1,exports:{}};return e[t].call(a.exports,a,a.exports,r),a.l=!0,a.exports}r.e=function(e){var t=[],a={about:1};s[e]?t.push(s[e]):0!==s[e]&&a[e]&&t.push(s[e]=new Promise((function(t,a){for(var n="css/"+({about:"about"}[e]||e)+"."+{about:"5b6fef7c"}[e]+".css",l=r.p+n,i=document.getElementsByTagName("link"),o=0;o<i.length;o++){var c=i[o],d=c.getAttribute("data-href")||c.getAttribute("href");if("stylesheet"===c.rel&&(d===n||d===l))return t()}var u=document.getElementsByTagName("style");for(o=0;o<u.length;o++){c=u[o],d=c.getAttribute("data-href");if(d===n||d===l)return t()}var p=document.createElement("link");p.rel="stylesheet",p.type="text/css",p.onload=t,p.onerror=function(t){var n=t&&t.target&&t.target.src||l,i=new Error("Loading CSS chunk "+e+" failed.\n("+n+")");i.code="CSS_CHUNK_LOAD_FAILED",i.request=n,delete s[e],p.parentNode.removeChild(p),a(i)},p.href=l;var m=document.getElementsByTagName("head")[0];m.appendChild(p)})).then((function(){s[e]=0})));var n=l[e];if(0!==n)if(n)t.push(n[2]);else{var i=new Promise((function(t,a){n=l[e]=[t,a]}));t.push(n[2]=i);var c,d=document.createElement("script");d.charset="utf-8",d.timeout=120,r.nc&&d.setAttribute("nonce",r.nc),d.src=o(e);var u=new Error;c=function(t){d.onerror=d.onload=null,clearTimeout(p);var a=l[e];if(0!==a){if(a){var n=t&&("load"===t.type?"missing":t.type),s=t&&t.target&&t.target.src;u.message="Loading chunk "+e+" failed.\n("+n+": "+s+")",u.name="ChunkLoadError",u.type=n,u.request=s,a[1](u)}l[e]=void 0}};var p=setTimeout((function(){c({type:"timeout",target:d})}),12e4);d.onerror=d.onload=c,document.head.appendChild(d)}return Promise.all(t)},r.m=e,r.c=n,r.d=function(e,t,a){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},r.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(r.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(a,n,function(t){return e[t]}.bind(null,n));return a},r.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r.oe=function(e){throw console.error(e),e};var c=window["webpackJsonp"]=window["webpackJsonp"]||[],d=c.push.bind(c);c.push=t,c=c.slice();for(var u=0;u<c.length;u++)t(c[u]);var p=d;i.push([0,"chunk-vendors"]),a()})({0:function(e,t,a){e.exports=a("56d7")},"047b":function(e,t,a){},"0c8e":function(e,t,a){"use strict";a("6211")},1593:function(e,t,a){},2666:function(e,t,a){},"48f9":function(e,t,a){"use strict";a("7d74")},"56d7":function(e,t,a){"use strict";a.r(t);var n=a("430a"),s=a("edcc"),l=a.n(s),i=(a("0db3"),function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{attrs:{id:"app"}},[a("el-container",[a("el-aside",{attrs:{width:"150px"}},[a("div",{attrs:{id:"nav"}},[a("router-link",{attrs:{to:"/"}},[e._v("例子展示")]),a("router-link",{attrs:{to:"/date"}},[e._v("date")]),a("router-link",{attrs:{to:"/scene"}},[e._v("场景使用")])],1)]),a("el-main",[a("router-view")],1)],1)],1)}),o=[],r=(a("5c0b"),a("cba8")),c={},d=Object(r["a"])(c,i,o,!1,null,null,null),u=d.exports,p=a("a5e4"),m=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"bi-table"},[a("div",{staticClass:"example-table-box"},[a("p",[e._v("基础表格")]),a("BiCustomColumn",{attrs:{"column-name":"test","table-column":e.basicColumn,"default-list":e.defaultColumnList,"default-column":{left:["date"],center:["name"],right:["other"]}},on:{handleTableColumn:e.setTableColumn}}),a("bi-table",{directives:[{name:"loading",rawName:"v-loading",value:e.tableLoading,expression:"tableLoading"}],attrs:{border:"",stripe:"",data:e.data,column:e.basicColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持render渲染")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.renderColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持slot插槽")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.slotColumn},scopedSlots:e._u([{key:"zip",fn:function(t){var n=t.row;return[a("el-tag",{staticClass:"el-icon-message-solid",attrs:{type:"success"}},[e._v(" "+e._s(n.zip)+" ")])]}}])})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持组件引入")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.componentColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持树形数据")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.componentColumn,"default-expand-all":"","row-key":"id","tree-props":{children:"children",hasChildren:"hasChildren"}}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持selection/index/expand")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.typesColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("带分页功能")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.complexColumn,"columns-props":e.columnsProps,pagination:"","auto-scroll":!1,total:100,page:e.listQuery.page,limit:e.listQuery.limit},on:{"update:page":function(t){return e.$set(e.listQuery,"page",t)},"update:limit":function(t){return e.$set(e.listQuery,"limit",t)},"selection-change":e.selectionChange,pagination:e.getList}}),a("el-dialog",{attrs:{title:"收货地址",visible:e.dialogVisible},on:{"update:visible":function(t){e.dialogVisible=t}}},[a("el-form",{attrs:{model:e.editForm,"label-width":"100px"}},[a("el-form-item",{attrs:{label:"名称"}},[a("el-input",{attrs:{autocomplete:"off"},model:{value:e.editForm.name,callback:function(t){e.$set(e.editForm,"name",t)},expression:"editForm.name"}})],1),a("el-form-item",{attrs:{label:"区域"}},[a("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择区域"},model:{value:e.editForm.province,callback:function(t){e.$set(e.editForm,"province",t)},expression:"editForm.province"}},[a("el-option",{attrs:{label:"上海",value:"shanghai"}}),a("el-option",{attrs:{label:"北京",value:"beijing"}})],1)],1),a("el-form-item",{attrs:{label:"市区"}},[a("el-input",{model:{value:e.editForm.city,callback:function(t){e.$set(e.editForm,"city",t)},expression:"editForm.city"}})],1),a("el-form-item",{attrs:{label:"地址"}},[a("el-input",{model:{value:e.editForm.address,callback:function(t){e.$set(e.editForm,"address",t)},expression:"editForm.address"}})],1)],1),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.dialogVisible=!1}}},[e._v("取 消")]),a("el-button",{attrs:{type:"primary"},on:{click:function(t){e.dialogVisible=!1}}},[e._v("确 定")])],1)],1)],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("sticky表格")]),a("bi-table",{attrs:{border:"",stripe:"",fixed:"sticky",data:e.data,column:e.fullscreenColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("普通固定表头")]),a("bi-table",{attrs:{border:"",stripe:"",fixed:"fullscreen",data:e.data,column:e.fullscreenColumn,"max-height":"200px","fixed-offset":"60",pagination:"","auto-scroll":!1,total:100,page:e.listQuery.page,limit:e.listQuery.limit},on:{"update:page":function(t){return e.$set(e.listQuery,"page",t)},"update:limit":function(t){return e.$set(e.listQuery,"limit",t)},"selection-change":e.selectionChange,pagination:e.getList}})],1)])},h=[],f=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-button",{attrs:{size:"mini"},on:{click:e.todo}},[e._v("编辑")])},b=[],g={props:["row","column"],methods:{todo(){this.$emit("row-edit",this.row)}}},y=g,v=Object(r["a"])(y,f,b,!1,null,null,null),x=v.exports,C={data(){this.$createElement;return{defaultColumnList:[{content:"分组1",status:!1,children:[{name:"date",content:"日期",status:!1}]},{content:"分组2",status:!1,children:[{content:"姓名",name:"name",status:!1},{content:"省份",name:"province",status:!1},{content:"市区",name:"city",status:!1}]},{content:"分组3",status:!1,children:[{content:"地址",name:"address",status:!1},{content:"地址2",name:"address2",status:!1},{content:"邮编",name:"zip",status:!1},{content:"v-model",name:"other",status:!1}]}],renderColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name",render:(e,t)=>e("el-popover",{attrs:{trigger:"hover",content:"这是一段内容,这是一段内容"}},[e("el-tag",{slot:"reference"},[t.row.name])])},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"}],slotColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip",slotScope:!0}],componentColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"},{label:"组件",prop:"cmp",component:x,listeners:{"row-edit"(e){console.log("row-edit",e)}}}],typesColumn:[{label:"序号",prop:"index",type:"index"},{label:"选择",prop:"selection",type:"selection"},{label:"日期",prop:"date"},{label:"省份",prop:"province"},{label:"姓名",prop:"name"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"更多",prop:"expand",type:"expand",render:(e,t)=>{const{row:a}=t;return e("div",[e("p",["姓名:",a.name]),e("p",["日期:",a.date]),e("p",["地址:",a.province," ",a.address," ",a.address]),e("p",["邮编:",a.zip])])}},{label:"邮编",prop:"zip"}],complexColumn:[{label:"更多",prop:"expand",type:"expand",render:(e,t)=>e("span",["--",t.row.name,"--"])},{label:"选择",prop:"selection",type:"selection"},{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province",formatter(e,t){return"中国 -"+e[t.property]}},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"},{label:"操作",prop:"cation",align:"center",width:200,render:(e,t)=>e("div",[e("el-button",{attrs:{icon:"el-icon-edit-outline",type:"primary",size:"small"},on:{click:()=>{this.openDialog(t)}}},["编辑"]),e("el-button",{attrs:{icon:"el-icon-delete",type:"danger",size:"small"},on:{click:()=>{alert("del")}}},["删除"])])}],fullscreenColumn:[{label:"日期",prop:"date",sortable:!0,fixed:!0},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address",width:300},{label:"地址2",prop:"address",width:300},{label:"地址3",prop:"address",width:300},{label:"邮编",prop:"zip"},{label:"操作",prop:"cmp",component:x,fixed:"right"}],data:[{id:1,date:"2016-05-03",name:"王小虎",province:"上海",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:2,date:"2016-05-02",name:"赵四",province:"东北",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333,children:[{id:11,date:"2000-05-02",name:"我是嵌套",province:"南极",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:12,date:"1999-05-02",name:"我是嵌套000",province:"美国",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333}]},{id:3,date:"2016-05-04",name:"张三疯",province:"武当山",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:4,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333}]}}},k={components:{},mixins:[C],data(){return{basicColumn:[{label:"日期",prop:"date",sortable:!0,fixed:!0},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address",width:300},{label:"地址2",prop:"address2",width:300},{label:"邮编",prop:"zip"},{label:"v-model",prop:"other",fixed:"right",render:(e,t)=>e("input",{on:{input(e){t.row.name=e.target.value}},domProps:{value:t.row.name},style:{width:"100%",minHeight:"30px",color:"red",border:"1px solid #ddd"}})}],tableLoading:!1,columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1}},methods:{selectionChange(e){console.log("selected",e)},getList(){},openDialog({row:e}){this.editForm=Object.assign({},e),this.dialogVisible=!0},setTableColumn(e){this.$set(this,"basicColumn",[]),setTimeout(()=>{this.$set(this,"basicColumn",e)},10)}}},j=k,_=(a("48f9"),Object(r["a"])(j,m,h,!1,null,"3b539933",null)),Y=_.exports;n["default"].use(p["a"]);const w=[{path:"/",name:"Home",component:Y},{path:"/date",name:"Date",component:()=>a.e("about").then(a.bind(null,"3a43"))}],L=new p["a"]({routes:w});var z=L,D=a("7736");n["default"].use(D["a"]);var $,M,O=new D["a"].Store({state:{},mutations:{},actions:{},modules:{}}),S=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"bi-table"},[a("div",{staticClass:"bi-table-wrapper"},[a("el-table",e._g(e._b({directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"elTable",attrs:{data:e.data,"max-height":e.maxHeight}},"el-table",e.$attrs,!1),e.$listeners),[e._l(e.tbColumns,(function(t){return[t.slotScope?a("el-table-column",e._g(e._b({key:t.prop+t.label,scopedSlots:e._u([{key:"default",fn:function(a){return[e._t(t.prop,null,null,a)]}}],null,!0)},"el-table-column",t,!1),e.$listeners)):a("bi-column",e._b({key:t.prop+t.label,attrs:{column:t}},"bi-column",e.$attrs,!1))]}))],2)],1),e.pagination?[e.data.length>0?a("pagination",e._g(e._b({},"pagination",e.$attrs,!1),e.$listeners)):e._e()]:e._e()],2)},T=[],E=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-table-column",e._g(e._b({scopedSlots:e._u([{key:"header",fn:function(t){return[e.column.renderHeader?a("bi-render",{attrs:{scope:t,render:e.column.renderHeader}}):a("span",[e._v(e._s(t.column.label))])]}},{key:"default",fn:function(t){return[e.column.component?a(e.column.component,e._g(e._b({tag:"component"},"component",e.getCptBind(t,e.column),!1),e.column.listeners)):e.column.children?e._l(e.column.children,(function(e){return a("free-column",{key:e.prop,attrs:{column:e}})})):a("bi-render",{attrs:{scope:t,render:e.column.render}})]}}])},"el-table-column",e.column,!1),e.$listeners))},A=[],B={name:"BiRender",functional:!0,props:{scope:{type:Object,default:()=>({})},render:{type:Function,default:()=>()=>{}}},render:(e,t)=>t.props.render?t.props.render(e,t.props.scope):""},N=B,F=Object(r["a"])(N,$,M,!1,null,null,null),P=F.exports,H={selection:{renderHeader:function(e,{store:t}){return e("el-checkbox",{attrs:{disabled:t.states.data&&0===t.states.data.length,indeterminate:t.states.selection.length>0&&!this.isAllSelected,value:this.isAllSelected},nativeOn:{click:this.toggleAllSelection}})},renderCell:function(e,{row:t,column:a,store:n,$index:s}){return e("el-checkbox",{nativeOn:{click:e=>e.stopPropagation()},attrs:{value:n.isSelected(t),disabled:!!a.selectable&&!a.selectable.call(null,t,s)},on:{input:()=>{n.commit("rowSelectedChanged",t)}}})},sortable:!1,resizable:!1},index:{renderHeader:function(e,{column:t}){return t.label||"#"},renderCell:function(e,{$index:t,column:a}){let n=t+1;const s=a.index;return"number"===typeof s?n=t+s:"function"===typeof s&&(n=s(t)),e("div",[n])},sortable:!1},expand:{renderHeader:function(e,{column:t}){return t.label||""},renderCell:function(e,{row:t,store:a}){const n=["el-table__expand-icon"];a.states.expandRows.indexOf(t)>-1&&n.push("el-table__expand-icon--expanded");const s=function(e){e.stopPropagation(),a.toggleRowExpansion(t)};return e("div",{class:n,on:{click:s}},[e("i",{class:"el-icon el-icon-arrow-right"})])},sortable:!1,resizable:!1,className:"el-table__expand-column"}},I={name:"BiColumn",components:{BiRender:P},props:{column:{type:Object,default:()=>{}}},watch:{column:{handler:"renderColumn",immediate:!0}},methods:{renderColumn(){this.$createElement;const{column:e}=this;return e.type&&(e.renderHeader=H[e.type].renderHeader,e.render=e.render||H[e.type].renderCell),e.formatter&&(e.render=(e,t)=>e("span",[t.column.formatter(t.row,t.column,t.row[t.column.property],t.$index)])),e.render||(e.render=(e,t)=>e("span",[t.row[t.column.property]])),e},getColBind(e){const t=Object.assign({},this.$attrs,e);return delete t.component,delete t.listeners,delete t.propsHandler,t},getCptBind({row:e,column:t},a){const n={row:e,col:a,column:t},s=a.propsHandler;return s&&s(n)||n}}},q=I,Q=Object(r["a"])(q,E,A,!1,null,null,null),V=Q.exports,R=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"pagination-container",class:{hidden:e.hidden}},[a("el-pagination",e._b({attrs:{background:e.background,"current-page":e.currentPage,"page-size":e.pageSize,layout:e.layout,"page-sizes":e.pageSizes,total:e.total},on:{"update:currentPage":function(t){e.currentPage=t},"update:current-page":function(t){e.currentPage=t},"update:pageSize":function(t){e.pageSize=t},"update:page-size":function(t){e.pageSize=t},"size-change":e.handleSizeChange,"current-change":e.handleCurrentChange}},"el-pagination",e.$attrs,!1))],1)},G=[];Math.easeInOutQuad=function(e,t,a,n){return e/=n/2,e<1?a/2*e*e+t:(e--,-a/2*(e*(e-2)-1)+t)};var J=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function U(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function K(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function W(e,t,a){const n=K(),s=e-n,l=20;let i=0;t="undefined"===typeof t?500:t;var o=function(){i+=l;var e=Math.easeInOutQuad(i,n,s,t);U(e),i<t?J(o):a&&"function"===typeof a&&a()};o()}var X={name:"BiPagination",props:{total:{required:!0,type:Number},page:{type:Number,default:1},limit:{type:Number,default:20},pageSizes:{type:Array,default(){return[10,20,30,50]}},layout:{type:String,default:"total, sizes, prev, pager, next, jumper"},background:{type:Boolean,default:!0},autoScroll:{type:Boolean,default:!0},hidden:{type:Boolean,default:!1}},computed:{currentPage:{get(){return this.page},set(e){this.$emit("update:page",e)}},pageSize:{get(){return this.limit},set(e){this.$emit("update:limit",e)}}},methods:{handleSizeChange(e){this.$emit("pagination",{page:this.currentPage,limit:e}),this.autoScroll&&W(0,800)},handleCurrentChange(e){this.$emit("pagination",{page:e,limit:this.pageSize}),this.autoScroll&&W(0,800)}}},Z=X,ee=(a("f621"),Object(r["a"])(Z,R,G,!1,null,"c276c1ba",null)),te=ee.exports,ae={name:"BiTable",components:{Pagination:te,BiColumn:V},props:{data:{type:Array,default:()=>[]},column:{type:Array,default:()=>[]},columnsProps:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},pagination:{type:Boolean,default:!1},fixed:{type:String,default:""},fixedOffset:{type:String,default:""}},data(){return{maxHeight:null}},computed:{tbColumns(){const{column:e,columnsProps:t}=this;return e.map(e=>{const a=Object.assign({},t,e);return a})},fixedHeader(){return this.fixed}},mounted(){"sticky"===this.fixedHeader?window.addEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.addEventListener("scroll",this.handleFixedHeader,!0)},destroyed(){"sticky"===this.fixedHeader?window.removeEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.removeEventListener("scroll",this.handleFixedHeader,!0)},methods:{handleStickyHeader(){const e=document.documentElement.scrollTop,t=this.$el.offsetTop;if(e>t+30){this.headerStatus||(this.headerStatus=!0,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="absolute",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="2");const a=e-(t+1)+Number(this.fixedOffset);this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.querySelector(".el-table__fixed").style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.querySelector(".el-table__fixed-right").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="4"}else this.headerStatus=!1,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.getElementsByClassName("el-table__body-wrapper")[0].style.paddingTop="0"},handleFixedHeader(){const e=this.$el.getBoundingClientRect().top,t=window.innerHeight-Number(this.fixedOffset)-(this.pagination?72:0);Math.abs(t-this.maxHeight)>3&&(this.maxHeight=t),e<=Number(this.fixedOffset)+20&&e>=0?this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="auto":this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="hidden"}}},ne=ae,se=Object(r["a"])(ne,S,T,!1,null,null,null),le=se.exports;le.install=function(e){e.component(le.name,le)};var ie=le,oe=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-button",{attrs:{type:"primary"},on:{click:function(t){e.visible=!0}}},[e._v(" 自定义列 "),a("el-dialog",{attrs:{"custom-class":"bi-column-dialog",title:"自定义列",visible:e.visible,width:"800px",top:"8vh","append-to-body":""},on:{"update:visible":function(t){e.visible=t},open:e.handleOpen,close:e.close}},[a("div",{staticClass:"dialog-body",staticStyle:{"min-height":"160px"}},[a("div",{staticClass:"bi-column-container"},[a("div",{staticClass:"checkbox-container"},[a("el-card",{staticClass:"box-card"},[a("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[a("span",[e._v("可操作性的列")])]),e._l(e.colList,(function(t,n){return a("div",{key:n,staticClass:"checkbox-group"},[a("p",{staticClass:"checkbox-title"},[a("el-checkbox",{on:{change:function(a){return e.handleCheckGroupAllChange(a,t)}},model:{value:t.status,callback:function(a){e.$set(t,"status",a)},expression:"item.status"}},[e._v(e._s(t.content))])],1),a("p",[a("el-checkbox-group",{attrs:{"true-label":1,"false-label":0},on:{change:function(a){return e.handleCheckGroupAll(t)}},model:{value:e.checkList,callback:function(t){e.checkList=t},expression:"checkList"}},e._l(t.children,(function(t,n){return a("el-checkbox",{key:n,staticStyle:{width:"120px",margin:"0 15px 15px 0"},attrs:{label:t.name}},[e._v(" "+e._s(t.content)+" ")])})),1)],1)])}))],2)],1),a("div",{staticClass:"column-container"},[a("el-card",{staticClass:"box-card"},[a("div",{staticClass:"column-title",attrs:{slot:"header"},slot:"header"},[a("span",[e._v("已选"+e._s(e.columnLength)+"列")]),a("el-button",{attrs:{type:"text"},on:{click:e.clearAll}},[e._v("清空全部")])],1),a("p",{staticClass:"column-group-title"},[e._v("左侧固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.leftColumnList,callback:function(t){e.leftColumnList=t},expression:"leftColumnList"}},e._l(e.leftColumnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1),a("p",{staticClass:"column-group-title"},[e._v("中间不固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.columnList,callback:function(t){e.columnList=t},expression:"columnList"}},e._l(e.columnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1),a("p",{staticClass:"column-group-title"},[e._v("右侧固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.rightColumnList,callback:function(t){e.rightColumnList=t},expression:"rightColumnList"}},e._l(e.rightColumnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1)])],1)])]),a("span",{staticClass:"dialog-footer",staticStyle:{display:"flex","justify-content":"space-between"},attrs:{slot:"footer"},slot:"footer"},[a("span",{staticStyle:{display:"inline-block","line-height":"32px"}},[a("el-checkbox",{attrs:{label:"全选"},on:{change:e.checkAll},model:{value:e.checkAllData,callback:function(t){e.checkAllData=t},expression:"checkAllData"}},[e._v(" 全选 ")])],1),a("div",[a("el-button",{on:{click:e.close}},[e._v("关闭")]),a("el-button",{attrs:{type:"primary"},on:{click:e.ok}},[e._v("生效")])],1)])])],1)},re=[],ce=a("3335"),de=a.n(ce),ue={name:"BiCustomColumn",components:{draggable:de.a},props:{columnName:{type:String,require:!0,default:""},listType:{type:String,require:!0,default:""},checkData:{type:Array,require:!0,default:()=>[]},tableColumn:{type:Array,default:()=>[]},defaultList:{type:Array,default:()=>[]},defaultColumn:{type:Object,default:()=>({left:[],center:[],right:[]})}},data(){return{tableColumnList:this.tableColumn,visible:!1,colList:[],checkList:[],checkAllData:!1,draggableList:[],leftColumnList:[],columnList:[],rightColumnList:[]}},computed:{columnLength(){return this.leftColumnList.length+this.columnList.length+this.rightColumnList.length}},watch:{colList:{handler(e){let t=!0;e.forEach(e=>{e.status=Boolean(e.status),e.status?this.checkAllData=e.status:t=!1,this.checkAllData=t})},deep:!0}},mounted(){const e={type:this.listType};this.defaultColumnInit(),this.getList(e),this.returnColumn()},beforeDestroy(){this.visible=!1},methods:{defaultColumnInit(){const e=this.getLocalStorage(),{left:t,center:a,right:n}=e||this.defaultColumn;t.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.leftColumnList.push(t)}),a.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.columnList.push(t)}),n.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.rightColumnList.push(t)})},async getList(e){this.colList=this.defaultList,this.defaultCheck()},checkAll(e){this.colList.forEach(t=>{this.handleCheckGroupAllChange(e,t),t.status=e}),e||(this.checkList=[])},defaultCheck(){this.colList.forEach(e=>{this.handleCheckGroupAll(e)})},deleteArrayItemForIndex(e,t){if(-1!==t)return e.splice(t,1)},handleCheckGroupAllChange(e,t){e?t.children.map(e=>{-1===this.checkList.indexOf(e.name)&&(this.checkList.push(e.name),this.insertColumn(e.name))}):t.children.map(e=>{this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e.name)),this.removeColumn(e.name)})},handleCheckGroupAll(e){let t=1;e.children.map(e=>{-1===this.checkList.indexOf(e.name)?(this.removeColumn(e.name),t=0):this.insertColumn(e.name)}),e.status=t},async setTheadList(){const e=JSON.parse(JSON.stringify(this.colList));var t=[];e.forEach(e=>{e.status=e.status?1:0,t.push(...e.children)})},clearAll(){this.checkList=[],this.checkAll(!1)},closeColumn(e){this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e)),this.removeColumn(e),this.defaultCheck()},insertColumn(e){const t=this.tableColumnList.find(t=>t.prop===e);this.leftColumnList.find(t=>t.prop===e)||this.rightColumnList.find(t=>t.prop===e)||this.columnList.find(t=>t.prop===e)||this.columnList.push(t)},removeColumn(e){if(this.leftColumnList.length&&this.leftColumnList.find(t=>t.prop===e)){const t=this.leftColumnList.findIndex(t=>t.prop===e);t>-1&&this.leftColumnList.splice(t,1)}if(this.columnList.length&&this.columnList.find(t=>t.prop===e)){const t=this.columnList.findIndex(t=>t.prop===e);t>-1&&this.columnList.splice(t,1)}if(this.rightColumnList.length&&this.rightColumnList.find(t=>t.prop===e)){const t=this.rightColumnList.findIndex(t=>t.prop===e);t>-1&&this.rightColumnList.splice(t,1)}},returnColumn(){this.leftColumnList.map(e=>{e.fixed=!0}),this.columnList.map(e=>{e.fixed=!1}),this.rightColumnList.map(e=>{e.fixed="right"}),this.$emit("handleTableColumn",[...this.leftColumnList,...this.columnList,...this.rightColumnList])},ok(){this.returnColumn(),this.saveLocalStorage(),this.visible=!1},saveLocalStorage(){const e={left:[],center:[],right:[]};this.leftColumnList.map(({prop:t})=>{t&&e.left.push(t)}),this.columnList.map(({prop:t})=>{t&&e.center.push(t)}),this.rightColumnList.map(({prop:t})=>{t&&e.right.push(t)}),localStorage.setItem(this.columnName,JSON.stringify(e))},getLocalStorage(){const e=localStorage.getItem(this.columnName);return e?JSON.parse(e):void 0},handleOpen(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[];const e=this.getLocalStorage();e&&this.defaultColumnInit()},close(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[],this.visible=!1,this.$emit("closeDialog",{visible:!1})}}},pe=ue,me=(a("bde6"),a("0c8e"),Object(r["a"])(pe,oe,re,!1,null,"28f3ba1d",null)),he=me.exports;he.install=function(e){e.component(he.name,he)};var fe=he,be=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-date-picker",e._g(e._b({attrs:{"picker-options":e.componentPickerOptions,format:e.format,"value-format":e.valueFormat},model:{value:e.date,callback:function(t){e.date=t},expression:"date"}},"el-date-picker",e.$attrs,!1),e.$listeners))},ge=[],ye=a("caaf"),ve=a.n(ye);const xe={daterange:{shortcuts:[{text:"今天",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"昨天",onClick(e){const t=ve()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一周",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一月",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"上个月",onClick(e){const t=ve()().startOf("month").subtract(1,"month").format("YYYY-MM-DD 00:00:00"),a=ve()().endOf("month").subtract(1,"month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,a])}},{text:"本月",onClick(e){const t=ve()().startOf("month").format("YYYY-MM-DD 00:00:00"),a=ve()().endOf("month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,a])}}]},monthrange:{shortcuts:[{text:"本月",onClick(e){const t=ve()().startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近三个月",onClick(e){const t=ve()().subtract(2,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近六个月",onClick(e){const t=ve()().subtract(5,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近一年",onClick(e){const t=ve()().subtract(11,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"今年",onClick(e){const t=ve()().startOf("year").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}}]},datetimerange:{shortcuts:[{text:"今天",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"昨天",onClick(e){const t=ve()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一周",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一月",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"上个月",onClick(e){if(null!==e.value){const t=ve()(e.value[1]).subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()(e.value[0]).subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}else{const t=ve()().subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}}},{text:"本月",onClick(e){const t=ve()().endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()().startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}}]}};var Ce=xe,ke={name:"BiDatePicker",props:{pickerOption:{type:Object,default:()=>({})},format:{type:String,default:"yyyy-MM-dd"},valueFormat:{type:String,default:"yyyy-MM-dd"},value:{type:[String,Array],default:""}},computed:{date:{get(){return this.value},set(e){this.$emit("input",e)}},componentPickerOptions(){const e=this.$attrs.type;return"daterange"===e?Object.assign(Ce.daterange,this.pickerOption):"monthrange"===e?Object.assign(Ce.monthrange,this.pickerOption):"datetimerange"===e?Object.assign(Ce.datetimerange,this.pickerOption):this.pickerOption}},methods:{}},je=ke,_e=(a("9895"),Object(r["a"])(je,be,ge,!1,null,null,null)),Ye=_e.exports;Ye.install=function(e){e.component(Ye.name,Ye)};var we=Ye;const Le=[ie,fe,we],ze=function(e){ze.installed||Le.map(t=>e.component(t.name,t))};"undefined"!==typeof window&&window.Vue&&ze(window.Vue);var De={install:ze,BiTable:ie,BiCustomColumn:fe,BiDatePicker:we};n["default"].use(l.a),n["default"].use(De),n["default"].config.productionTip=!1,new n["default"]({router:z,store:O,render:e=>e(u)}).$mount("#app")},"5c0b":function(e,t,a){"use strict";a("7df9")},6211:function(e,t,a){},"7d74":function(e,t,a){},"7df9":function(e,t,a){},9895:function(e,t,a){"use strict";a("1593")},aaf1:function(e,t,a){var n={"./af":"0674","./af.js":"0674","./ar":"6cc2","./ar-dz":"b1de","./ar-dz.js":"b1de","./ar-kw":"7d0b","./ar-kw.js":"7d0b","./ar-ly":"4064","./ar-ly.js":"4064","./ar-ma":"56ad","./ar-ma.js":"56ad","./ar-sa":"adaa","./ar-sa.js":"adaa","./ar-tn":"5221","./ar-tn.js":"5221","./ar.js":"6cc2","./az":"1a3f","./az.js":"1a3f","./be":"84b2","./be.js":"84b2","./bg":"a213","./bg.js":"a213","./bm":"8b34","./bm.js":"8b34","./bn":"3482","./bn-bd":"98bb","./bn-bd.js":"98bb","./bn.js":"3482","./bo":"a3f6","./bo.js":"a3f6","./br":"72ea","./br.js":"72ea","./bs":"fa2c","./bs.js":"fa2c","./ca":"f217","./ca.js":"f217","./cs":"1b54","./cs.js":"1b54","./cv":"ae9c","./cv.js":"ae9c","./cy":"7554","./cy.js":"7554","./da":"b478","./da.js":"b478","./de":"35a9","./de-at":"5b88","./de-at.js":"5b88","./de-ch":"7475","./de-ch.js":"7475","./de.js":"35a9","./dv":"4c16","./dv.js":"4c16","./el":"3f33","./el.js":"3f33","./en-au":"73ff","./en-au.js":"73ff","./en-ca":"bfc9","./en-ca.js":"bfc9","./en-gb":"428a","./en-gb.js":"428a","./en-ie":"6b5c","./en-ie.js":"6b5c","./en-il":"eb4a","./en-il.js":"eb4a","./en-in":"3fbf","./en-in.js":"3fbf","./en-nz":"89f8","./en-nz.js":"89f8","./en-sg":"13d6","./en-sg.js":"13d6","./eo":"dfd6","./eo.js":"dfd6","./es":"5221e","./es-do":"7a70","./es-do.js":"7a70","./es-mx":"a656","./es-mx.js":"a656","./es-us":"3081","./es-us.js":"3081","./es.js":"5221e","./et":"45f3","./et.js":"45f3","./eu":"d1a1","./eu.js":"d1a1","./fa":"6773","./fa.js":"6773","./fi":"259f","./fi.js":"259f","./fil":"32e2","./fil.js":"32e2","./fo":"0e60","./fo.js":"0e60","./fr":"0600","./fr-ca":"6520","./fr-ca.js":"6520","./fr-ch":"2b9c","./fr-ch.js":"2b9c","./fr.js":"0600","./fy":"23bb","./fy.js":"23bb","./ga":"f9bb","./ga.js":"f9bb","./gd":"088a","./gd.js":"088a","./gl":"da3a","./gl.js":"da3a","./gom-deva":"e728","./gom-deva.js":"e728","./gom-latn":"b781","./gom-latn.js":"b781","./gu":"ab1a","./gu.js":"ab1a","./he":"2e9a","./he.js":"2e9a","./hi":"77d9","./hi.js":"77d9","./hr":"334c","./hr.js":"334c","./hu":"9f96","./hu.js":"9f96","./hy-am":"f2d9","./hy-am.js":"f2d9","./id":"7e6f","./id.js":"7e6f","./is":"770b","./is.js":"770b","./it":"aed5","./it-ch":"72a8","./it-ch.js":"72a8","./it.js":"aed5","./ja":"d546","./ja.js":"d546","./jv":"63b1","./jv.js":"63b1","./ka":"517d","./ka.js":"517d","./kk":"1320","./kk.js":"1320","./km":"b9f3","./km.js":"b9f3","./kn":"d861","./kn.js":"d861","./ko":"ce13","./ko.js":"ce13","./ku":"ecb8","./ku.js":"ecb8","./ky":"885a","./ky.js":"885a","./lb":"aa9d","./lb.js":"aa9d","./lo":"579e","./lo.js":"579e","./lt":"b8d7","./lt.js":"b8d7","./lv":"1bb4","./lv.js":"1bb4","./me":"673d","./me.js":"673d","./mi":"26ae","./mi.js":"26ae","./mk":"e174","./mk.js":"e174","./ml":"4a84","./ml.js":"4a84","./mn":"aadd","./mn.js":"aadd","./mr":"a2a5","./mr.js":"a2a5","./ms":"d18a","./ms-my":"66b0","./ms-my.js":"66b0","./ms.js":"d18a","./mt":"7fb0","./mt.js":"7fb0","./my":"74d1","./my.js":"74d1","./nb":"5fd8","./nb.js":"5fd8","./ne":"4e84","./ne.js":"4e84","./nl":"6f41","./nl-be":"6f69","./nl-be.js":"6f69","./nl.js":"6f41","./nn":"e69e","./nn.js":"e69e","./oc-lnc":"8d28","./oc-lnc.js":"8d28","./pa-in":"b000","./pa-in.js":"b000","./pl":"510c","./pl.js":"510c","./pt":"714b","./pt-br":"e9f3","./pt-br.js":"e9f3","./pt.js":"714b","./ro":"a876","./ro.js":"a876","./ru":"ba7c","./ru.js":"ba7c","./sd":"25dc","./sd.js":"25dc","./se":"d540","./se.js":"d540","./si":"1b0a","./si.js":"1b0a","./sk":"bfa3","./sk.js":"bfa3","./sl":"d112","./sl.js":"d112","./sq":"8f41","./sq.js":"8f41","./sr":"61ee","./sr-cyrl":"17eb","./sr-cyrl.js":"17eb","./sr.js":"61ee","./ss":"0d66","./ss.js":"0d66","./sv":"820c","./sv.js":"820c","./sw":"dbbf","./sw.js":"dbbf","./ta":"70b6","./ta.js":"70b6","./te":"67e8","./te.js":"67e8","./tet":"9609","./tet.js":"9609","./tg":"a19a","./tg.js":"a19a","./th":"459d","./th.js":"459d","./tk":"b2a1","./tk.js":"b2a1","./tl-ph":"341b","./tl-ph.js":"341b","./tlh":"b24c","./tlh.js":"b24c","./tr":"8f6c","./tr.js":"8f6c","./tzl":"fea0","./tzl.js":"fea0","./tzm":"9828","./tzm-latn":"a859","./tzm-latn.js":"a859","./tzm.js":"9828","./ug-cn":"0a67","./ug-cn.js":"0a67","./uk":"82cc","./uk.js":"82cc","./ur":"ad72","./ur.js":"ad72","./uz":"015a","./uz-latn":"35be","./uz-latn.js":"35be","./uz.js":"015a","./vi":"90db","./vi.js":"90db","./x-pseudo":"7eee","./x-pseudo.js":"7eee","./yo":"b9ec","./yo.js":"b9ec","./zh-cn":"10ef","./zh-cn.js":"10ef","./zh-hk":"c3a6","./zh-hk.js":"c3a6","./zh-mo":"9218","./zh-mo.js":"9218","./zh-tw":"0144","./zh-tw.js":"0144"};function s(e){var t=l(e);return a(t)}function l(e){if(!a.o(n,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return n[e]}s.keys=function(){return Object.keys(n)},s.resolve=l,e.exports=s,s.id="aaf1"},bde6:function(e,t,a){"use strict";a("2666")},f621:function(e,t,a){"use strict";a("047b")}});
|
2
|
-
//# sourceMappingURL=index.
|
1
|
+
(function(e){function t(t){for(var n,s,o=t[0],r=t[1],c=t[2],d=0,u=[];d<o.length;d++)s=o[d],Object.prototype.hasOwnProperty.call(l,s)&&l[s]&&u.push(l[s][0]),l[s]=0;for(n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);p&&p(t);while(u.length)u.shift()();return i.push.apply(i,c||[]),a()}function a(){for(var e,t=0;t<i.length;t++){for(var a=i[t],n=!0,s=1;s<a.length;s++){var o=a[s];0!==l[o]&&(n=!1)}n&&(i.splice(t--,1),e=r(r.s=a[0]))}return e}var n={},s={index:0},l={index:0},i=[];function o(e){return r.p+"js/"+({about:"about"}[e]||e)+"."+{about:"f95f1b1d"}[e]+".js"}function r(t){if(n[t])return n[t].exports;var a=n[t]={i:t,l:!1,exports:{}};return e[t].call(a.exports,a,a.exports,r),a.l=!0,a.exports}r.e=function(e){var t=[],a={about:1};s[e]?t.push(s[e]):0!==s[e]&&a[e]&&t.push(s[e]=new Promise((function(t,a){for(var n="css/"+({about:"about"}[e]||e)+"."+{about:"ba384392"}[e]+".css",l=r.p+n,i=document.getElementsByTagName("link"),o=0;o<i.length;o++){var c=i[o],d=c.getAttribute("data-href")||c.getAttribute("href");if("stylesheet"===c.rel&&(d===n||d===l))return t()}var u=document.getElementsByTagName("style");for(o=0;o<u.length;o++){c=u[o],d=c.getAttribute("data-href");if(d===n||d===l)return t()}var p=document.createElement("link");p.rel="stylesheet",p.type="text/css",p.onload=t,p.onerror=function(t){var n=t&&t.target&&t.target.src||l,i=new Error("Loading CSS chunk "+e+" failed.\n("+n+")");i.code="CSS_CHUNK_LOAD_FAILED",i.request=n,delete s[e],p.parentNode.removeChild(p),a(i)},p.href=l;var m=document.getElementsByTagName("head")[0];m.appendChild(p)})).then((function(){s[e]=0})));var n=l[e];if(0!==n)if(n)t.push(n[2]);else{var i=new Promise((function(t,a){n=l[e]=[t,a]}));t.push(n[2]=i);var c,d=document.createElement("script");d.charset="utf-8",d.timeout=120,r.nc&&d.setAttribute("nonce",r.nc),d.src=o(e);var u=new Error;c=function(t){d.onerror=d.onload=null,clearTimeout(p);var a=l[e];if(0!==a){if(a){var n=t&&("load"===t.type?"missing":t.type),s=t&&t.target&&t.target.src;u.message="Loading chunk "+e+" failed.\n("+n+": "+s+")",u.name="ChunkLoadError",u.type=n,u.request=s,a[1](u)}l[e]=void 0}};var p=setTimeout((function(){c({type:"timeout",target:d})}),12e4);d.onerror=d.onload=c,document.head.appendChild(d)}return Promise.all(t)},r.m=e,r.c=n,r.d=function(e,t,a){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},r.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(r.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(a,n,function(t){return e[t]}.bind(null,n));return a},r.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r.oe=function(e){throw console.error(e),e};var c=window["webpackJsonp"]=window["webpackJsonp"]||[],d=c.push.bind(c);c.push=t,c=c.slice();for(var u=0;u<c.length;u++)t(c[u]);var p=d;i.push([0,"chunk-vendors"]),a()})({0:function(e,t,a){e.exports=a("56d7")},"047b":function(e,t,a){},"0c8e":function(e,t,a){"use strict";a("6211")},1593:function(e,t,a){},2666:function(e,t,a){},"48f9":function(e,t,a){"use strict";a("7d74")},"56d7":function(e,t,a){"use strict";a.r(t);var n=a("430a"),s=a("edcc"),l=a.n(s),i=(a("0db3"),function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{attrs:{id:"app"}},[a("el-container",[a("el-aside",{attrs:{width:"150px"}},[a("div",{attrs:{id:"nav"}},[a("router-link",{attrs:{to:"/"}},[e._v("例子展示")]),a("router-link",{attrs:{to:"/date"}},[e._v("date")]),a("router-link",{attrs:{to:"/scene"}},[e._v("场景使用")])],1)]),a("el-main",[a("router-view")],1)],1)],1)}),o=[],r=(a("5c0b"),a("cba8")),c={},d=Object(r["a"])(c,i,o,!1,null,null,null),u=d.exports,p=a("a5e4"),m=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"bi-table"},[a("div",{staticClass:"example-table-box"},[a("p",[e._v("基础表格")]),a("BiCustomColumn",{attrs:{"column-name":"test","table-column":e.basicColumn,"default-list":e.defaultColumnList,"default-column":{left:["date"],center:["name"],right:["other"]}},on:{handleTableColumn:e.setTableColumn}}),a("bi-table",{directives:[{name:"loading",rawName:"v-loading",value:e.tableLoading,expression:"tableLoading"}],attrs:{border:"",stripe:"",data:e.data,column:e.basicColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持render渲染")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.renderColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持slot插槽")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.slotColumn},scopedSlots:e._u([{key:"zip",fn:function(t){var n=t.row;return[a("el-tag",{staticClass:"el-icon-message-solid",attrs:{type:"success"}},[e._v(" "+e._s(n.zip)+" ")])]}}])})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持组件引入")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.componentColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持树形数据")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.componentColumn,"default-expand-all":"","row-key":"id","tree-props":{children:"children",hasChildren:"hasChildren"}}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("支持selection/index/expand")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.typesColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("带分页功能")]),a("bi-table",{attrs:{border:"",data:e.data,column:e.complexColumn,"columns-props":e.columnsProps,pagination:"","auto-scroll":!1,total:100,page:e.listQuery.page,limit:e.listQuery.limit},on:{"update:page":function(t){return e.$set(e.listQuery,"page",t)},"update:limit":function(t){return e.$set(e.listQuery,"limit",t)},"selection-change":e.selectionChange,pagination:e.getList}}),a("el-dialog",{attrs:{title:"收货地址",visible:e.dialogVisible},on:{"update:visible":function(t){e.dialogVisible=t}}},[a("el-form",{attrs:{model:e.editForm,"label-width":"100px"}},[a("el-form-item",{attrs:{label:"名称"}},[a("el-input",{attrs:{autocomplete:"off"},model:{value:e.editForm.name,callback:function(t){e.$set(e.editForm,"name",t)},expression:"editForm.name"}})],1),a("el-form-item",{attrs:{label:"区域"}},[a("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:"请选择区域"},model:{value:e.editForm.province,callback:function(t){e.$set(e.editForm,"province",t)},expression:"editForm.province"}},[a("el-option",{attrs:{label:"上海",value:"shanghai"}}),a("el-option",{attrs:{label:"北京",value:"beijing"}})],1)],1),a("el-form-item",{attrs:{label:"市区"}},[a("el-input",{model:{value:e.editForm.city,callback:function(t){e.$set(e.editForm,"city",t)},expression:"editForm.city"}})],1),a("el-form-item",{attrs:{label:"地址"}},[a("el-input",{model:{value:e.editForm.address,callback:function(t){e.$set(e.editForm,"address",t)},expression:"editForm.address"}})],1)],1),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{on:{click:function(t){e.dialogVisible=!1}}},[e._v("取 消")]),a("el-button",{attrs:{type:"primary"},on:{click:function(t){e.dialogVisible=!1}}},[e._v("确 定")])],1)],1)],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("sticky表格")]),a("bi-table",{attrs:{border:"",stripe:"",fixed:"sticky",data:e.data,column:e.fullscreenColumn}})],1),a("div",{staticClass:"example-table-box"},[a("p",[e._v("普通固定表头")]),a("bi-table",{attrs:{border:"",stripe:"",fixed:"fullscreen",data:e.data,column:e.fullscreenColumn,"max-height":"200px","fixed-offset":"60",pagination:"","auto-scroll":!1,total:100,page:e.listQuery.page,limit:e.listQuery.limit},on:{"update:page":function(t){return e.$set(e.listQuery,"page",t)},"update:limit":function(t){return e.$set(e.listQuery,"limit",t)},"selection-change":e.selectionChange,pagination:e.getList}})],1)])},h=[],f=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-button",{attrs:{size:"mini"},on:{click:e.todo}},[e._v("编辑")])},b=[],g={props:["row","column"],methods:{todo(){this.$emit("row-edit",this.row)}}},y=g,v=Object(r["a"])(y,f,b,!1,null,null,null),x=v.exports,C={data(){this.$createElement;return{defaultColumnList:[{content:"分组1",status:!1,children:[{name:"date",content:"日期",status:!1}]},{content:"分组2",status:!1,children:[{content:"姓名",name:"name",status:!1},{content:"省份",name:"province",status:!1},{content:"市区",name:"city",status:!1}]},{content:"分组3",status:!1,children:[{content:"地址",name:"address",status:!1},{content:"地址2",name:"address2",status:!1},{content:"邮编",name:"zip",status:!1},{content:"v-model",name:"other",status:!1}]}],renderColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name",render:(e,t)=>e("el-popover",{attrs:{trigger:"hover",content:"这是一段内容,这是一段内容"}},[e("el-tag",{slot:"reference"},[t.row.name])])},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"}],slotColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip",slotScope:!0}],componentColumn:[{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"},{label:"组件",prop:"cmp",component:x,listeners:{"row-edit"(e){console.log("row-edit",e)}}}],typesColumn:[{label:"序号",prop:"index",type:"index"},{label:"选择",prop:"selection",type:"selection"},{label:"日期",prop:"date"},{label:"省份",prop:"province"},{label:"姓名",prop:"name"},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"更多",prop:"expand",type:"expand",render:(e,t)=>{const{row:a}=t;return e("div",[e("p",["姓名:",a.name]),e("p",["日期:",a.date]),e("p",["地址:",a.province," ",a.address," ",a.address]),e("p",["邮编:",a.zip])])}},{label:"邮编",prop:"zip"}],complexColumn:[{label:"更多",prop:"expand",type:"expand",render:(e,t)=>e("span",["--",t.row.name,"--"])},{label:"选择",prop:"selection",type:"selection"},{label:"日期",prop:"date"},{label:"姓名",prop:"name"},{label:"省份",prop:"province",formatter(e,t){return"中国 -"+e[t.property]}},{label:"市区",prop:"city"},{label:"地址",prop:"address"},{label:"邮编",prop:"zip"},{label:"操作",prop:"cation",align:"center",width:200,render:(e,t)=>e("div",[e("el-button",{attrs:{icon:"el-icon-edit-outline",type:"primary",size:"small"},on:{click:()=>{this.openDialog(t)}}},["编辑"]),e("el-button",{attrs:{icon:"el-icon-delete",type:"danger",size:"small"},on:{click:()=>{alert("del")}}},["删除"])])}],fullscreenColumn:[{label:"日期",prop:"date",sortable:!0,fixed:!0},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address",width:300},{label:"地址2",prop:"address",width:300},{label:"地址3",prop:"address",width:300},{label:"邮编",prop:"zip"},{label:"操作",prop:"cmp",component:x,fixed:"right"}],data:[{id:1,date:"2016-05-03",name:"王小虎",province:"上海",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:2,date:"2016-05-02",name:"赵四",province:"东北",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333,children:[{id:11,date:"2000-05-02",name:"我是嵌套",province:"南极",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:12,date:"1999-05-02",name:"我是嵌套000",province:"美国",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333}]},{id:3,date:"2016-05-04",name:"张三疯",province:"武当山",city:"普陀区",address:"上海市普陀区金沙江路 1518 弄",address2:"上海市普陀区金沙江路 1518 弄",zip:200333},{id:4,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333},{id:5,date:"2016-05-044",name:"李连杰",province:"新加坡",city:"普陀区",address:"上海市普陀区金沙江路 1516 T",zip:200333}]}}},k={components:{},mixins:[C],data(){return{basicColumn:[{label:"日期",prop:"date",sortable:!0,fixed:!0},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address",width:300},{label:"地址2",prop:"address2",width:300},{label:"邮编",prop:"zip"},{label:"v-model",prop:"other",fixed:"right",render:(e,t)=>e("input",{on:{input(e){t.row.name=e.target.value}},domProps:{value:t.row.name},style:{width:"100%",minHeight:"30px",color:"red",border:"1px solid #ddd"}})}],tableLoading:!1,columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1}},methods:{selectionChange(e){console.log("selected",e)},getList(){},openDialog({row:e}){this.editForm=Object.assign({},e),this.dialogVisible=!0},setTableColumn(e){this.$set(this,"basicColumn",[]),setTimeout(()=>{this.$set(this,"basicColumn",e)},10)}}},j=k,_=(a("48f9"),Object(r["a"])(j,m,h,!1,null,"3b539933",null)),Y=_.exports;n["default"].use(p["a"]);const w=[{path:"/",name:"Home",component:Y},{path:"/date",name:"Date",component:()=>a.e("about").then(a.bind(null,"3a43"))}],L=new p["a"]({routes:w});var z=L,D=a("7736");n["default"].use(D["a"]);var $,M,O=new D["a"].Store({state:{},mutations:{},actions:{},modules:{}}),S=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"bi-table"},[a("div",{staticClass:"bi-table-wrapper"},[a("el-table",e._g(e._b({directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"elTable",attrs:{data:e.data,"max-height":e.maxHeight}},"el-table",e.$attrs,!1),e.$listeners),[e._l(e.tbColumns,(function(t){return[t.slotScope?a("el-table-column",e._g(e._b({key:t.prop+t.label,scopedSlots:e._u([{key:"default",fn:function(a){return[e._t(t.prop,null,null,a)]}}],null,!0)},"el-table-column",t,!1),e.$listeners)):a("bi-column",e._b({key:t.prop+t.label,attrs:{column:t}},"bi-column",e.$attrs,!1))]}))],2)],1),e.pagination?[e.data.length>0?a("pagination",e._g(e._b({},"pagination",e.$attrs,!1),e.$listeners)):e._e()]:e._e()],2)},T=[],E=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-table-column",e._g(e._b({scopedSlots:e._u([{key:"header",fn:function(t){return[e.column.renderHeader?a("bi-render",{attrs:{scope:t,render:e.column.renderHeader}}):a("span",[e._v(e._s(t.column.label))])]}},{key:"default",fn:function(t){return[e.column.component?a(e.column.component,e._g(e._b({tag:"component"},"component",e.getCptBind(t,e.column),!1),e.column.listeners)):e.column.children?e._l(e.column.children,(function(e){return a("free-column",{key:e.prop,attrs:{column:e}})})):a("bi-render",{attrs:{scope:t,render:e.column.render}})]}}])},"el-table-column",e.column,!1),e.$listeners))},A=[],B={name:"BiRender",functional:!0,props:{scope:{type:Object,default:()=>({})},render:{type:Function,default:()=>()=>{}}},render:(e,t)=>t.props.render?t.props.render(e,t.props.scope):""},N=B,F=Object(r["a"])(N,$,M,!1,null,null,null),P=F.exports,H={selection:{renderHeader:function(e,{store:t}){return e("el-checkbox",{attrs:{disabled:t.states.data&&0===t.states.data.length,indeterminate:t.states.selection.length>0&&!this.isAllSelected,value:this.isAllSelected},nativeOn:{click:this.toggleAllSelection}})},renderCell:function(e,{row:t,column:a,store:n,$index:s}){return e("el-checkbox",{nativeOn:{click:e=>e.stopPropagation()},attrs:{value:n.isSelected(t),disabled:!!a.selectable&&!a.selectable.call(null,t,s)},on:{input:()=>{n.commit("rowSelectedChanged",t)}}})},sortable:!1,resizable:!1},index:{renderHeader:function(e,{column:t}){return t.label||"#"},renderCell:function(e,{$index:t,column:a}){let n=t+1;const s=a.index;return"number"===typeof s?n=t+s:"function"===typeof s&&(n=s(t)),e("div",[n])},sortable:!1},expand:{renderHeader:function(e,{column:t}){return t.label||""},renderCell:function(e,{row:t,store:a}){const n=["el-table__expand-icon"];a.states.expandRows.indexOf(t)>-1&&n.push("el-table__expand-icon--expanded");const s=function(e){e.stopPropagation(),a.toggleRowExpansion(t)};return e("div",{class:n,on:{click:s}},[e("i",{class:"el-icon el-icon-arrow-right"})])},sortable:!1,resizable:!1,className:"el-table__expand-column"}},I={name:"BiColumn",components:{BiRender:P},props:{column:{type:Object,default:()=>{}}},watch:{column:{handler:"renderColumn",immediate:!0}},methods:{renderColumn(){this.$createElement;const{column:e}=this;return e.type&&(e.renderHeader=H[e.type].renderHeader,e.render=e.render||H[e.type].renderCell),e.formatter&&(e.render=(e,t)=>e("span",[t.column.formatter(t.row,t.column,t.row[t.column.property],t.$index)])),e.render||(e.render=(e,t)=>e("span",[t.row[t.column.property]])),e},getColBind(e){const t=Object.assign({},this.$attrs,e);return delete t.component,delete t.listeners,delete t.propsHandler,t},getCptBind({row:e,column:t},a){const n={row:e,col:a,column:t},s=a.propsHandler;return s&&s(n)||n}}},q=I,Q=Object(r["a"])(q,E,A,!1,null,null,null),V=Q.exports,R=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"pagination-container",class:{hidden:e.hidden}},[a("el-pagination",e._b({attrs:{background:e.background,"current-page":e.currentPage,"page-size":e.pageSize,layout:e.layout,"page-sizes":e.pageSizes,total:e.total},on:{"update:currentPage":function(t){e.currentPage=t},"update:current-page":function(t){e.currentPage=t},"update:pageSize":function(t){e.pageSize=t},"update:page-size":function(t){e.pageSize=t},"size-change":e.handleSizeChange,"current-change":e.handleCurrentChange}},"el-pagination",e.$attrs,!1))],1)},G=[];Math.easeInOutQuad=function(e,t,a,n){return e/=n/2,e<1?a/2*e*e+t:(e--,-a/2*(e*(e-2)-1)+t)};var J=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function U(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function K(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function W(e,t,a){const n=K(),s=e-n,l=20;let i=0;t="undefined"===typeof t?500:t;var o=function(){i+=l;var e=Math.easeInOutQuad(i,n,s,t);U(e),i<t?J(o):a&&"function"===typeof a&&a()};o()}var X={name:"BiPagination",props:{total:{required:!0,type:Number},page:{type:Number,default:1},limit:{type:Number,default:20},pageSizes:{type:Array,default(){return[10,20,30,50]}},layout:{type:String,default:"total, sizes, prev, pager, next, jumper"},background:{type:Boolean,default:!0},autoScroll:{type:Boolean,default:!0},hidden:{type:Boolean,default:!1}},computed:{currentPage:{get(){return this.page},set(e){this.$emit("update:page",e)}},pageSize:{get(){return this.limit},set(e){this.$emit("update:limit",e)}}},methods:{handleSizeChange(e){this.$emit("pagination",{page:this.currentPage,limit:e}),this.autoScroll&&W(0,800)},handleCurrentChange(e){this.$emit("pagination",{page:e,limit:this.pageSize}),this.autoScroll&&W(0,800)}}},Z=X,ee=(a("f621"),Object(r["a"])(Z,R,G,!1,null,"c276c1ba",null)),te=ee.exports,ae={name:"BiTable",components:{Pagination:te,BiColumn:V},props:{data:{type:Array,default:()=>[]},column:{type:Array,default:()=>[]},columnsProps:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},pagination:{type:Boolean,default:!1},fixed:{type:String,default:""},fixedOffset:{type:String,default:""}},data(){return{maxHeight:null}},computed:{tbColumns(){const{column:e,columnsProps:t}=this;return e.map(e=>{const a=Object.assign({},t,e);return a})},fixedHeader(){return this.fixed}},mounted(){"sticky"===this.fixedHeader?window.addEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.addEventListener("scroll",this.handleFixedHeader,!0)},destroyed(){"sticky"===this.fixedHeader?window.removeEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.removeEventListener("scroll",this.handleFixedHeader,!0)},methods:{handleStickyHeader(){const e=document.documentElement.scrollTop,t=this.$el.offsetTop;if(e>t+30){this.headerStatus||(this.headerStatus=!0,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="absolute",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="2");const a=e-(t+1)+Number(this.fixedOffset);this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.querySelector(".el-table__fixed").style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${a}px, 0px)`,this.$el.querySelector(".el-table__fixed-right").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="4"}else this.headerStatus=!1,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.getElementsByClassName("el-table__body-wrapper")[0].style.paddingTop="0"},handleFixedHeader(){const e=this.$el.getBoundingClientRect().top,t=window.innerHeight-Number(this.fixedOffset)-(this.pagination?72:0);Math.abs(t-this.maxHeight)>3&&(this.maxHeight=t),e<=Number(this.fixedOffset)+20&&e>=0?this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="auto":this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="hidden"}}},ne=ae,se=Object(r["a"])(ne,S,T,!1,null,null,null),le=se.exports;le.install=function(e){e.component(le.name,le)};var ie=le,oe=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-button",{attrs:{type:"primary"},on:{click:function(t){e.visible=!0}}},[e._v(" 自定义列 "),a("el-dialog",{attrs:{"custom-class":"bi-column-dialog",title:"自定义列",visible:e.visible,width:"800px",top:"8vh","append-to-body":""},on:{"update:visible":function(t){e.visible=t},open:e.handleOpen,close:e.close}},[a("div",{staticClass:"dialog-body",staticStyle:{"min-height":"160px"}},[a("div",{staticClass:"bi-column-container"},[a("div",{staticClass:"checkbox-container"},[a("el-card",{staticClass:"box-card"},[a("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[a("span",[e._v("可操作性的列")])]),e._l(e.colList,(function(t,n){return a("div",{key:n,staticClass:"checkbox-group"},[a("p",{staticClass:"checkbox-title"},[a("el-checkbox",{on:{change:function(a){return e.handleCheckGroupAllChange(a,t)}},model:{value:t.status,callback:function(a){e.$set(t,"status",a)},expression:"item.status"}},[e._v(e._s(t.content))])],1),a("p",[a("el-checkbox-group",{attrs:{"true-label":1,"false-label":0},on:{change:function(a){return e.handleCheckGroupAll(t)}},model:{value:e.checkList,callback:function(t){e.checkList=t},expression:"checkList"}},e._l(t.children,(function(t,n){return a("el-checkbox",{key:n,staticStyle:{width:"120px",margin:"0 15px 15px 0"},attrs:{label:t.name}},[e._v(" "+e._s(t.content)+" ")])})),1)],1)])}))],2)],1),a("div",{staticClass:"column-container"},[a("el-card",{staticClass:"box-card"},[a("div",{staticClass:"column-title",attrs:{slot:"header"},slot:"header"},[a("span",[e._v("已选"+e._s(e.columnLength)+"列")]),a("el-button",{attrs:{type:"text"},on:{click:e.clearAll}},[e._v("清空全部")])],1),a("p",{staticClass:"column-group-title"},[e._v("左侧固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.leftColumnList,callback:function(t){e.leftColumnList=t},expression:"leftColumnList"}},e._l(e.leftColumnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1),a("p",{staticClass:"column-group-title"},[e._v("中间不固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.columnList,callback:function(t){e.columnList=t},expression:"columnList"}},e._l(e.columnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1),a("p",{staticClass:"column-group-title"},[e._v("右侧固定列")]),a("div",{staticClass:"column-configurable"},[a("draggable",{attrs:{group:"column"},model:{value:e.rightColumnList,callback:function(t){e.rightColumnList=t},expression:"rightColumnList"}},e._l(e.rightColumnList,(function(t){return a("div",{key:t.prop,staticClass:"selected-column-item"},[a("i",{staticClass:"el-icon-menu"}),a("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),a("i",{staticClass:"el-icon-close column-close",on:{click:function(a){return e.closeColumn(t.prop)}}})])})),0)],1)])],1)])]),a("span",{staticClass:"dialog-footer",staticStyle:{display:"flex","justify-content":"space-between"},attrs:{slot:"footer"},slot:"footer"},[a("span",{staticStyle:{display:"inline-block","line-height":"32px"}},[a("el-checkbox",{attrs:{label:"全选"},on:{change:e.checkAll},model:{value:e.checkAllData,callback:function(t){e.checkAllData=t},expression:"checkAllData"}},[e._v(" 全选 ")])],1),a("div",[a("el-button",{on:{click:e.close}},[e._v("关闭")]),a("el-button",{attrs:{type:"primary"},on:{click:e.ok}},[e._v("生效")])],1)])])],1)},re=[],ce=a("3335"),de=a.n(ce),ue={name:"BiCustomColumn",components:{draggable:de.a},props:{columnName:{type:String,require:!0,default:""},listType:{type:String,require:!0,default:""},checkData:{type:Array,require:!0,default:()=>[]},tableColumn:{type:Array,default:()=>[]},defaultList:{type:Array,default:()=>[]},defaultColumn:{type:Object,default:()=>({left:[],center:[],right:[]})}},data(){return{tableColumnList:this.tableColumn,visible:!1,colList:[],checkList:[],checkAllData:!1,draggableList:[],leftColumnList:[],columnList:[],rightColumnList:[]}},computed:{columnLength(){return this.leftColumnList.length+this.columnList.length+this.rightColumnList.length}},watch:{colList:{handler(e){let t=!0;e.forEach(e=>{e.status=Boolean(e.status),e.status?this.checkAllData=e.status:t=!1,this.checkAllData=t})},deep:!0}},mounted(){const e={type:this.listType};this.defaultColumnInit(),this.getList(e),this.returnColumn()},beforeDestroy(){this.visible=!1},methods:{defaultColumnInit(){const e=this.getLocalStorage(),{left:t,center:a,right:n}=e||this.defaultColumn;t.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.leftColumnList.push(t)}),a.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.columnList.push(t)}),n.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.rightColumnList.push(t)})},async getList(e){this.colList=this.defaultList,this.defaultCheck()},checkAll(e){this.colList.forEach(t=>{this.handleCheckGroupAllChange(e,t),t.status=e}),e||(this.checkList=[])},defaultCheck(){this.colList.forEach(e=>{this.handleCheckGroupAll(e)})},deleteArrayItemForIndex(e,t){if(-1!==t)return e.splice(t,1)},handleCheckGroupAllChange(e,t){e?t.children.map(e=>{-1===this.checkList.indexOf(e.name)&&(this.checkList.push(e.name),this.insertColumn(e.name))}):t.children.map(e=>{this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e.name)),this.removeColumn(e.name)})},handleCheckGroupAll(e){let t=1;e.children.map(e=>{-1===this.checkList.indexOf(e.name)?(this.removeColumn(e.name),t=0):this.insertColumn(e.name)}),e.status=t},async setTheadList(){const e=JSON.parse(JSON.stringify(this.colList));var t=[];e.forEach(e=>{e.status=e.status?1:0,t.push(...e.children)})},clearAll(){this.checkList=[],this.checkAll(!1)},closeColumn(e){this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e)),this.removeColumn(e),this.defaultCheck()},insertColumn(e){const t=this.tableColumnList.find(t=>t.prop===e);this.leftColumnList.find(t=>t.prop===e)||this.rightColumnList.find(t=>t.prop===e)||this.columnList.find(t=>t.prop===e)||this.columnList.push(t)},removeColumn(e){if(this.leftColumnList.length&&this.leftColumnList.find(t=>t.prop===e)){const t=this.leftColumnList.findIndex(t=>t.prop===e);t>-1&&this.leftColumnList.splice(t,1)}if(this.columnList.length&&this.columnList.find(t=>t.prop===e)){const t=this.columnList.findIndex(t=>t.prop===e);t>-1&&this.columnList.splice(t,1)}if(this.rightColumnList.length&&this.rightColumnList.find(t=>t.prop===e)){const t=this.rightColumnList.findIndex(t=>t.prop===e);t>-1&&this.rightColumnList.splice(t,1)}},returnColumn(){this.leftColumnList.map(e=>{e.fixed=!0}),this.columnList.map(e=>{e.fixed=!1}),this.rightColumnList.map(e=>{e.fixed="right"}),this.$emit("handleTableColumn",[...this.leftColumnList,...this.columnList,...this.rightColumnList])},ok(){this.returnColumn(),this.saveLocalStorage(),this.visible=!1},saveLocalStorage(){const e={left:[],center:[],right:[]};this.leftColumnList.map(({prop:t})=>{t&&e.left.push(t)}),this.columnList.map(({prop:t})=>{t&&e.center.push(t)}),this.rightColumnList.map(({prop:t})=>{t&&e.right.push(t)}),localStorage.setItem(this.columnName,JSON.stringify(e))},getLocalStorage(){const e=localStorage.getItem(this.columnName);return e?JSON.parse(e):void 0},handleOpen(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[];const e=this.getLocalStorage();e&&this.defaultColumnInit()},close(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[],this.visible=!1,this.$emit("closeDialog",{visible:!1})}}},pe=ue,me=(a("bde6"),a("0c8e"),Object(r["a"])(pe,oe,re,!1,null,"28f3ba1d",null)),he=me.exports;he.install=function(e){e.component(he.name,he)};var fe=he,be=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("el-date-picker",e._g(e._b({attrs:{"picker-options":e.componentPickerOptions,format:e.format,"value-format":e.valueFormat},model:{value:e.date,callback:function(t){e.date=t},expression:"date"}},"el-date-picker",e.$attrs,!1),e.$listeners))},ge=[],ye=a("caaf"),ve=a.n(ye);const xe={daterange:{shortcuts:[{text:"今天",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"昨天",onClick(e){const t=ve()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一周",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一月",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"上个月",onClick(e){const t=ve()().startOf("month").subtract(1,"month").format("YYYY-MM-DD 00:00:00"),a=ve()().endOf("month").subtract(1,"month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,a])}},{text:"本月",onClick(e){const t=ve()().startOf("month").format("YYYY-MM-DD 00:00:00"),a=ve()().endOf("month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,a])}}]},monthrange:{shortcuts:[{text:"本月",onClick(e){const t=ve()().startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近三个月",onClick(e){const t=ve()().subtract(2,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近六个月",onClick(e){const t=ve()().subtract(5,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"最近一年",onClick(e){const t=ve()().subtract(11,"month").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}},{text:"今年",onClick(e){const t=ve()().startOf("year").startOf("month").format("YYYY-MM-DD"),a=ve()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,a])}}]},datetimerange:{shortcuts:[{text:"今天",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"昨天",onClick(e){const t=ve()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一周",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"近一月",onClick(e){const t=ve()().format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}},{text:"上个月",onClick(e){if(null!==e.value){const t=ve()(e.value[1]).subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()(e.value[0]).subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}else{const t=ve()().subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()().subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}}},{text:"本月",onClick(e){const t=ve()().endOf("month").format("YYYY-MM-DD 23:59:59"),a=ve()().startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[a,t])}}]}};var Ce=xe,ke={name:"BiDatePicker",props:{pickerOption:{type:Object,default:()=>({})},format:{type:String,default:"yyyy-MM-dd"},valueFormat:{type:String,default:"yyyy-MM-dd"},value:{type:[String,Array],default:""}},computed:{date:{get(){return this.value},set(e){this.$emit("input",e)}},componentPickerOptions(){const e=this.$attrs.type,t=Object.assign({},Ce[e]);return"daterange"===e||"monthrange"===e||"datetimerange"===e?Object.assign(t,this.pickerOption):this.pickerOption}},methods:{}},je=ke,_e=(a("9895"),Object(r["a"])(je,be,ge,!1,null,null,null)),Ye=_e.exports;Ye.install=function(e){e.component(Ye.name,Ye)};var we=Ye;const Le=[ie,fe,we],ze=function(e){ze.installed||Le.map(t=>e.component(t.name,t))};"undefined"!==typeof window&&window.Vue&&ze(window.Vue);var De={install:ze,BiTable:ie,BiCustomColumn:fe,BiDatePicker:we};n["default"].use(l.a),n["default"].use(De),n["default"].config.productionTip=!1,new n["default"]({router:z,store:O,render:e=>e(u)}).$mount("#app")},"5c0b":function(e,t,a){"use strict";a("7df9")},6211:function(e,t,a){},"7d74":function(e,t,a){},"7df9":function(e,t,a){},9895:function(e,t,a){"use strict";a("1593")},aaf1:function(e,t,a){var n={"./af":"0674","./af.js":"0674","./ar":"6cc2","./ar-dz":"b1de","./ar-dz.js":"b1de","./ar-kw":"7d0b","./ar-kw.js":"7d0b","./ar-ly":"4064","./ar-ly.js":"4064","./ar-ma":"56ad","./ar-ma.js":"56ad","./ar-sa":"adaa","./ar-sa.js":"adaa","./ar-tn":"5221","./ar-tn.js":"5221","./ar.js":"6cc2","./az":"1a3f","./az.js":"1a3f","./be":"84b2","./be.js":"84b2","./bg":"a213","./bg.js":"a213","./bm":"8b34","./bm.js":"8b34","./bn":"3482","./bn-bd":"98bb","./bn-bd.js":"98bb","./bn.js":"3482","./bo":"a3f6","./bo.js":"a3f6","./br":"72ea","./br.js":"72ea","./bs":"fa2c","./bs.js":"fa2c","./ca":"f217","./ca.js":"f217","./cs":"1b54","./cs.js":"1b54","./cv":"ae9c","./cv.js":"ae9c","./cy":"7554","./cy.js":"7554","./da":"b478","./da.js":"b478","./de":"35a9","./de-at":"5b88","./de-at.js":"5b88","./de-ch":"7475","./de-ch.js":"7475","./de.js":"35a9","./dv":"4c16","./dv.js":"4c16","./el":"3f33","./el.js":"3f33","./en-au":"73ff","./en-au.js":"73ff","./en-ca":"bfc9","./en-ca.js":"bfc9","./en-gb":"428a","./en-gb.js":"428a","./en-ie":"6b5c","./en-ie.js":"6b5c","./en-il":"eb4a","./en-il.js":"eb4a","./en-in":"3fbf","./en-in.js":"3fbf","./en-nz":"89f8","./en-nz.js":"89f8","./en-sg":"13d6","./en-sg.js":"13d6","./eo":"dfd6","./eo.js":"dfd6","./es":"5221e","./es-do":"7a70","./es-do.js":"7a70","./es-mx":"a656","./es-mx.js":"a656","./es-us":"3081","./es-us.js":"3081","./es.js":"5221e","./et":"45f3","./et.js":"45f3","./eu":"d1a1","./eu.js":"d1a1","./fa":"6773","./fa.js":"6773","./fi":"259f","./fi.js":"259f","./fil":"32e2","./fil.js":"32e2","./fo":"0e60","./fo.js":"0e60","./fr":"0600","./fr-ca":"6520","./fr-ca.js":"6520","./fr-ch":"2b9c","./fr-ch.js":"2b9c","./fr.js":"0600","./fy":"23bb","./fy.js":"23bb","./ga":"f9bb","./ga.js":"f9bb","./gd":"088a","./gd.js":"088a","./gl":"da3a","./gl.js":"da3a","./gom-deva":"e728","./gom-deva.js":"e728","./gom-latn":"b781","./gom-latn.js":"b781","./gu":"ab1a","./gu.js":"ab1a","./he":"2e9a","./he.js":"2e9a","./hi":"77d9","./hi.js":"77d9","./hr":"334c","./hr.js":"334c","./hu":"9f96","./hu.js":"9f96","./hy-am":"f2d9","./hy-am.js":"f2d9","./id":"7e6f","./id.js":"7e6f","./is":"770b","./is.js":"770b","./it":"aed5","./it-ch":"72a8","./it-ch.js":"72a8","./it.js":"aed5","./ja":"d546","./ja.js":"d546","./jv":"63b1","./jv.js":"63b1","./ka":"517d","./ka.js":"517d","./kk":"1320","./kk.js":"1320","./km":"b9f3","./km.js":"b9f3","./kn":"d861","./kn.js":"d861","./ko":"ce13","./ko.js":"ce13","./ku":"ecb8","./ku.js":"ecb8","./ky":"885a","./ky.js":"885a","./lb":"aa9d","./lb.js":"aa9d","./lo":"579e","./lo.js":"579e","./lt":"b8d7","./lt.js":"b8d7","./lv":"1bb4","./lv.js":"1bb4","./me":"673d","./me.js":"673d","./mi":"26ae","./mi.js":"26ae","./mk":"e174","./mk.js":"e174","./ml":"4a84","./ml.js":"4a84","./mn":"aadd","./mn.js":"aadd","./mr":"a2a5","./mr.js":"a2a5","./ms":"d18a","./ms-my":"66b0","./ms-my.js":"66b0","./ms.js":"d18a","./mt":"7fb0","./mt.js":"7fb0","./my":"74d1","./my.js":"74d1","./nb":"5fd8","./nb.js":"5fd8","./ne":"4e84","./ne.js":"4e84","./nl":"6f41","./nl-be":"6f69","./nl-be.js":"6f69","./nl.js":"6f41","./nn":"e69e","./nn.js":"e69e","./oc-lnc":"8d28","./oc-lnc.js":"8d28","./pa-in":"b000","./pa-in.js":"b000","./pl":"510c","./pl.js":"510c","./pt":"714b","./pt-br":"e9f3","./pt-br.js":"e9f3","./pt.js":"714b","./ro":"a876","./ro.js":"a876","./ru":"ba7c","./ru.js":"ba7c","./sd":"25dc","./sd.js":"25dc","./se":"d540","./se.js":"d540","./si":"1b0a","./si.js":"1b0a","./sk":"bfa3","./sk.js":"bfa3","./sl":"d112","./sl.js":"d112","./sq":"8f41","./sq.js":"8f41","./sr":"61ee","./sr-cyrl":"17eb","./sr-cyrl.js":"17eb","./sr.js":"61ee","./ss":"0d66","./ss.js":"0d66","./sv":"820c","./sv.js":"820c","./sw":"dbbf","./sw.js":"dbbf","./ta":"70b6","./ta.js":"70b6","./te":"67e8","./te.js":"67e8","./tet":"9609","./tet.js":"9609","./tg":"a19a","./tg.js":"a19a","./th":"459d","./th.js":"459d","./tk":"b2a1","./tk.js":"b2a1","./tl-ph":"341b","./tl-ph.js":"341b","./tlh":"b24c","./tlh.js":"b24c","./tr":"8f6c","./tr.js":"8f6c","./tzl":"fea0","./tzl.js":"fea0","./tzm":"9828","./tzm-latn":"a859","./tzm-latn.js":"a859","./tzm.js":"9828","./ug-cn":"0a67","./ug-cn.js":"0a67","./uk":"82cc","./uk.js":"82cc","./ur":"ad72","./ur.js":"ad72","./uz":"015a","./uz-latn":"35be","./uz-latn.js":"35be","./uz.js":"015a","./vi":"90db","./vi.js":"90db","./x-pseudo":"7eee","./x-pseudo.js":"7eee","./yo":"b9ec","./yo.js":"b9ec","./zh-cn":"10ef","./zh-cn.js":"10ef","./zh-hk":"c3a6","./zh-hk.js":"c3a6","./zh-mo":"9218","./zh-mo.js":"9218","./zh-tw":"0144","./zh-tw.js":"0144"};function s(e){var t=l(e);return a(t)}function l(e){if(!a.o(n,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return n[e]}s.keys=function(){return Object.keys(n)},s.resolve=l,e.exports=s,s.id="aaf1"},bde6:function(e,t,a){"use strict";a("2666")},f621:function(e,t,a){"use strict";a("047b")}});
|
2
|
+
//# sourceMappingURL=index.ccf79dfe.js.map
|
@@ -28500,12 +28500,12 @@ CustomColumn_src.install = function (Vue) {
|
|
28500
28500
|
};
|
28501
28501
|
|
28502
28502
|
/* harmony default export */ var CustomColumn = (CustomColumn_src);
|
28503
|
-
// CONCATENATED MODULE: ./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"98113606-vue-loader-template"}!./node_modules/_vue-loader@15.9.8@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.9.8@vue-loader/lib??vue-loader-options!./packages/DatePicker/src/index.vue?vue&type=template&id=
|
28504
|
-
var
|
28505
|
-
var
|
28503
|
+
// CONCATENATED MODULE: ./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"98113606-vue-loader-template"}!./node_modules/_vue-loader@15.9.8@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.9.8@vue-loader/lib??vue-loader-options!./packages/DatePicker/src/index.vue?vue&type=template&id=74b7930f&
|
28504
|
+
var srcvue_type_template_id_74b7930f_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (true)?_c('el-date-picker',_vm._g(_vm._b({attrs:{"picker-options":_vm.componentPickerOptions,"format":_vm.format,"value-format":_vm.valueFormat},model:{value:(_vm.date),callback:function ($$v) {_vm.date=$$v},expression:"date"}},'el-date-picker',_vm.$attrs,false),_vm.$listeners)):undefined}
|
28505
|
+
var srcvue_type_template_id_74b7930f_staticRenderFns = []
|
28506
28506
|
|
28507
28507
|
|
28508
|
-
// CONCATENATED MODULE: ./packages/DatePicker/src/index.vue?vue&type=template&id=
|
28508
|
+
// CONCATENATED MODULE: ./packages/DatePicker/src/index.vue?vue&type=template&id=74b7930f&
|
28509
28509
|
|
28510
28510
|
// EXTERNAL MODULE: ./node_modules/_moment@2.29.1@moment/moment.js
|
28511
28511
|
var moment = __webpack_require__("caaf");
|
@@ -28746,13 +28746,14 @@ const pickerOptions = {
|
|
28746
28746
|
|
28747
28747
|
componentPickerOptions() {
|
28748
28748
|
const type = this.$attrs.type;
|
28749
|
+
const defaultPickerOption = Object.assign({}, datePickerOption[type]);
|
28749
28750
|
|
28750
28751
|
if (type === 'daterange') {
|
28751
|
-
return Object.assign(
|
28752
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28752
28753
|
} else if (type === 'monthrange') {
|
28753
|
-
return Object.assign(
|
28754
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28754
28755
|
} else if (type === 'datetimerange') {
|
28755
|
-
return Object.assign(
|
28756
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28756
28757
|
} else {
|
28757
28758
|
return this.pickerOption;
|
28758
28759
|
}
|
@@ -28777,8 +28778,8 @@ var srcvue_type_style_index_0_lang_css_ = __webpack_require__("9895");
|
|
28777
28778
|
|
28778
28779
|
var DatePicker_src_component = normalizeComponent(
|
28779
28780
|
packages_DatePicker_srcvue_type_script_lang_js_,
|
28780
|
-
|
28781
|
-
|
28781
|
+
srcvue_type_template_id_74b7930f_render,
|
28782
|
+
srcvue_type_template_id_74b7930f_staticRenderFns,
|
28782
28783
|
false,
|
28783
28784
|
null,
|
28784
28785
|
null,
|
package/lib/bi-element-ui.umd.js
CHANGED
@@ -28509,12 +28509,12 @@ CustomColumn_src.install = function (Vue) {
|
|
28509
28509
|
};
|
28510
28510
|
|
28511
28511
|
/* harmony default export */ var CustomColumn = (CustomColumn_src);
|
28512
|
-
// CONCATENATED MODULE: ./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"98113606-vue-loader-template"}!./node_modules/_vue-loader@15.9.8@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.9.8@vue-loader/lib??vue-loader-options!./packages/DatePicker/src/index.vue?vue&type=template&id=
|
28513
|
-
var
|
28514
|
-
var
|
28512
|
+
// CONCATENATED MODULE: ./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"98113606-vue-loader-template"}!./node_modules/_vue-loader@15.9.8@vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/_cache-loader@4.1.0@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.9.8@vue-loader/lib??vue-loader-options!./packages/DatePicker/src/index.vue?vue&type=template&id=74b7930f&
|
28513
|
+
var srcvue_type_template_id_74b7930f_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (true)?_c('el-date-picker',_vm._g(_vm._b({attrs:{"picker-options":_vm.componentPickerOptions,"format":_vm.format,"value-format":_vm.valueFormat},model:{value:(_vm.date),callback:function ($$v) {_vm.date=$$v},expression:"date"}},'el-date-picker',_vm.$attrs,false),_vm.$listeners)):undefined}
|
28514
|
+
var srcvue_type_template_id_74b7930f_staticRenderFns = []
|
28515
28515
|
|
28516
28516
|
|
28517
|
-
// CONCATENATED MODULE: ./packages/DatePicker/src/index.vue?vue&type=template&id=
|
28517
|
+
// CONCATENATED MODULE: ./packages/DatePicker/src/index.vue?vue&type=template&id=74b7930f&
|
28518
28518
|
|
28519
28519
|
// EXTERNAL MODULE: ./node_modules/_moment@2.29.1@moment/moment.js
|
28520
28520
|
var moment = __webpack_require__("caaf");
|
@@ -28755,13 +28755,14 @@ const pickerOptions = {
|
|
28755
28755
|
|
28756
28756
|
componentPickerOptions() {
|
28757
28757
|
const type = this.$attrs.type;
|
28758
|
+
const defaultPickerOption = Object.assign({}, datePickerOption[type]);
|
28758
28759
|
|
28759
28760
|
if (type === 'daterange') {
|
28760
|
-
return Object.assign(
|
28761
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28761
28762
|
} else if (type === 'monthrange') {
|
28762
|
-
return Object.assign(
|
28763
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28763
28764
|
} else if (type === 'datetimerange') {
|
28764
|
-
return Object.assign(
|
28765
|
+
return Object.assign(defaultPickerOption, this.pickerOption);
|
28765
28766
|
} else {
|
28766
28767
|
return this.pickerOption;
|
28767
28768
|
}
|
@@ -28786,8 +28787,8 @@ var srcvue_type_style_index_0_lang_css_ = __webpack_require__("9895");
|
|
28786
28787
|
|
28787
28788
|
var DatePicker_src_component = normalizeComponent(
|
28788
28789
|
packages_DatePicker_srcvue_type_script_lang_js_,
|
28789
|
-
|
28790
|
-
|
28790
|
+
srcvue_type_template_id_74b7930f_render,
|
28791
|
+
srcvue_type_template_id_74b7930f_staticRenderFns,
|
28791
28792
|
false,
|
28792
28793
|
null,
|
28793
28794
|
null,
|
@@ -276,7 +276,7 @@ var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n=
|
|
276
276
|
//! moment.js locale configuration
|
277
277
|
var t=e.defineLocale("ca",{months:{standalone:"gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre".split("_"),format:"de gener_de febrer_de març_d'abril_de maig_de juny_de juliol_d'agost_de setembre_d'octubre_de novembre_de desembre".split("_"),isFormat:/D[oD]?(\s)+MMMM/},monthsShort:"gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.".split("_"),monthsParseExact:!0,weekdays:"diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dt._dc._dj._dv._ds.".split("_"),weekdaysMin:"dg_dl_dt_dc_dj_dv_ds".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [de] YYYY",ll:"D MMM YYYY",LLL:"D MMMM [de] YYYY [a les] H:mm",lll:"D MMM YYYY, H:mm",LLLL:"dddd D MMMM [de] YYYY [a les] H:mm",llll:"ddd D MMM YYYY, H:mm"},calendar:{sameDay:function(){return"[avui a "+(1!==this.hours()?"les":"la")+"] LT"},nextDay:function(){return"[demà a "+(1!==this.hours()?"les":"la")+"] LT"},nextWeek:function(){return"dddd [a "+(1!==this.hours()?"les":"la")+"] LT"},lastDay:function(){return"[ahir a "+(1!==this.hours()?"les":"la")+"] LT"},lastWeek:function(){return"[el] dddd [passat a "+(1!==this.hours()?"les":"la")+"] LT"},sameElse:"L"},relativeTime:{future:"d'aquí %s",past:"fa %s",s:"uns segons",ss:"%d segons",m:"un minut",mm:"%d minuts",h:"una hora",hh:"%d hores",d:"un dia",dd:"%d dies",M:"un mes",MM:"%d mesos",y:"un any",yy:"%d anys"},dayOfMonthOrdinalParse:/\d{1,2}(r|n|t|è|a)/,ordinal:function(e,t){var n=1===e?"r":2===e?"n":3===e?"r":4===e?"t":"è";return"w"!==t&&"W"!==t||(n="a"),e+n},week:{dow:1,doy:4}});return t}))},f2d9:function(e,t,n){(function(e,t){t(n("caaf"))})(0,(function(e){"use strict";
|
278
278
|
//! moment.js locale configuration
|
279
|
-
var t=e.defineLocale("hy-am",{months:{format:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_"),standalone:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_")},monthsShort:"հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_"),weekdays:"կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_"),weekdaysShort:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),weekdaysMin:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY թ.",LLL:"D MMMM YYYY թ., HH:mm",LLLL:"dddd, D MMMM YYYY թ., HH:mm"},calendar:{sameDay:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",ss:"%d վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiemParse:/գիշերվա|առավոտվա|ցերեկվա|երեկոյան/,isPM:function(e){return/^(ցերեկվա|երեկոյան)$/.test(e)},meridiem:function(e){return e<4?"գիշերվա":e<12?"առավոտվա":e<17?"ցերեկվա":"երեկոյան"},dayOfMonthOrdinalParse:/\d{1,2}|\d{1,2}-(ին|րդ)/,ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}});return t}))},f4a0:function(e,t,n){"use strict";if(n.r(t),"undefined"!==typeof window){var a=window.document.currentScript,r=n("79e4");a=r(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:r});var s=a&&a.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);s&&(n.p=s[1])}var i,o,d=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"bi-table"},[n("div",{staticClass:"bi-table-wrapper"},[n("el-table",e._g(e._b({directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"elTable",attrs:{data:e.data,"max-height":e.maxHeight}},"el-table",e.$attrs,!1),e.$listeners),[e._l(e.tbColumns,(function(t){return[t.slotScope?n("el-table-column",e._g(e._b({key:t.prop+t.label,scopedSlots:e._u([{key:"default",fn:function(n){return[e._t(t.prop,null,null,n)]}}],null,!0)},"el-table-column",t,!1),e.$listeners)):n("bi-column",e._b({key:t.prop+t.label,attrs:{column:t}},"bi-column",e.$attrs,!1))]}))],2)],1),e.pagination?[e.data.length>0?n("pagination",e._g(e._b({},"pagination",e.$attrs,!1),e.$listeners)):e._e()]:e._e()],2)},u=[],l=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-table-column",e._g(e._b({scopedSlots:e._u([{key:"header",fn:function(t){return[e.column.renderHeader?n("bi-render",{attrs:{scope:t,render:e.column.renderHeader}}):n("span",[e._v(e._s(t.column.label))])]}},{key:"default",fn:function(t){return[e.column.component?n(e.column.component,e._g(e._b({tag:"component"},"component",e.getCptBind(t,e.column),!1),e.column.listeners)):e.column.children?e._l(e.column.children,(function(e){return n("free-column",{key:e.prop,attrs:{column:e}})})):n("bi-render",{attrs:{scope:t,render:e.column.render}})]}}])},"el-table-column",e.column,!1),e.$listeners))},_=[],m={name:"BiRender",functional:!0,props:{scope:{type:Object,default:()=>({})},render:{type:Function,default:()=>()=>{}}},render:(e,t)=>t.props.render?t.props.render(e,t.props.scope):""},c=m;function h(e,t,n,a,r,s,i,o){var d,u="function"===typeof e?e.options:e;if(t&&(u.render=t,u.staticRenderFns=n,u._compiled=!0),a&&(u.functional=!0),s&&(u._scopeId="data-v-"+s),i?(d=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"===typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),r&&r.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(i)},u._ssrRegister=d):r&&(d=o?function(){r.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:r),d)if(u.functional){u._injectStyles=d;var l=u.render;u.render=function(e,t){return d.call(t),l(e,t)}}else{var _=u.beforeCreate;u.beforeCreate=_?[].concat(_,d):[d]}return{exports:e,options:u}}var f=h(c,i,o,!1,null,null,null),M=f.exports,p={selection:{renderHeader:function(e,{store:t}){return e("el-checkbox",{attrs:{disabled:t.states.data&&0===t.states.data.length,indeterminate:t.states.selection.length>0&&!this.isAllSelected,value:this.isAllSelected},nativeOn:{click:this.toggleAllSelection}})},renderCell:function(e,{row:t,column:n,store:a,$index:r}){return e("el-checkbox",{nativeOn:{click:e=>e.stopPropagation()},attrs:{value:a.isSelected(t),disabled:!!n.selectable&&!n.selectable.call(null,t,r)},on:{input:()=>{a.commit("rowSelectedChanged",t)}}})},sortable:!1,resizable:!1},index:{renderHeader:function(e,{column:t}){return t.label||"#"},renderCell:function(e,{$index:t,column:n}){let a=t+1;const r=n.index;return"number"===typeof r?a=t+r:"function"===typeof r&&(a=r(t)),e("div",[a])},sortable:!1},expand:{renderHeader:function(e,{column:t}){return t.label||""},renderCell:function(e,{row:t,store:n}){const a=["el-table__expand-icon"];n.states.expandRows.indexOf(t)>-1&&a.push("el-table__expand-icon--expanded");const r=function(e){e.stopPropagation(),n.toggleRowExpansion(t)};return e("div",{class:a,on:{click:r}},[e("i",{class:"el-icon el-icon-arrow-right"})])},sortable:!1,resizable:!1,className:"el-table__expand-column"}},y={name:"BiColumn",components:{BiRender:M},props:{column:{type:Object,default:()=>{}}},watch:{column:{handler:"renderColumn",immediate:!0}},methods:{renderColumn(){this.$createElement;const{column:e}=this;return e.type&&(e.renderHeader=p[e.type].renderHeader,e.render=e.render||p[e.type].renderCell),e.formatter&&(e.render=(e,t)=>e("span",[t.column.formatter(t.row,t.column,t.row[t.column.property],t.$index)])),e.render||(e.render=(e,t)=>e("span",[t.row[t.column.property]])),e},getColBind(e){const t=Object.assign({},this.$attrs,e);return delete t.component,delete t.listeners,delete t.propsHandler,t},getCptBind({row:e,column:t},n){const a={row:e,col:n,column:t},r=n.propsHandler;return r&&r(a)||a}}},L=y,Y=h(L,l,_,!1,null,null,null),g=Y.exports,v=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"pagination-container",class:{hidden:e.hidden}},[n("el-pagination",e._b({attrs:{background:e.background,"current-page":e.currentPage,"page-size":e.pageSize,layout:e.layout,"page-sizes":e.pageSizes,total:e.total},on:{"update:currentPage":function(t){e.currentPage=t},"update:current-page":function(t){e.currentPage=t},"update:pageSize":function(t){e.pageSize=t},"update:page-size":function(t){e.pageSize=t},"size-change":e.handleSizeChange,"current-change":e.handleCurrentChange}},"el-pagination",e.$attrs,!1))],1)},D=[];Math.easeInOutQuad=function(e,t,n,a){return e/=a/2,e<1?n/2*e*e+t:(e--,-n/2*(e*(e-2)-1)+t)};var k=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function b(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function w(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function T(e,t,n){const a=w(),r=e-a,s=20;let i=0;t="undefined"===typeof t?500:t;var o=function(){i+=s;var e=Math.easeInOutQuad(i,a,r,t);b(e),i<t?k(o):n&&"function"===typeof n&&n()};o()}var S={name:"BiPagination",props:{total:{required:!0,type:Number},page:{type:Number,default:1},limit:{type:Number,default:20},pageSizes:{type:Array,default(){return[10,20,30,50]}},layout:{type:String,default:"total, sizes, prev, pager, next, jumper"},background:{type:Boolean,default:!0},autoScroll:{type:Boolean,default:!0},hidden:{type:Boolean,default:!1}},computed:{currentPage:{get(){return this.page},set(e){this.$emit("update:page",e)}},pageSize:{get(){return this.limit},set(e){this.$emit("update:limit",e)}}},methods:{handleSizeChange(e){this.$emit("pagination",{page:this.currentPage,limit:e}),this.autoScroll&&T(0,800)},handleCurrentChange(e){this.$emit("pagination",{page:e,limit:this.pageSize}),this.autoScroll&&T(0,800)}}},H=S,x=(n("f621"),h(H,v,D,!1,null,"c276c1ba",null)),j=x.exports,O={name:"BiTable",components:{Pagination:j,BiColumn:g},props:{data:{type:Array,default:()=>[]},column:{type:Array,default:()=>[]},columnsProps:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},pagination:{type:Boolean,default:!1},fixed:{type:String,default:""},fixedOffset:{type:String,default:""}},data(){return{maxHeight:null}},computed:{tbColumns(){const{column:e,columnsProps:t}=this;return e.map(e=>{const n=Object.assign({},t,e);return n})},fixedHeader(){return this.fixed}},mounted(){"sticky"===this.fixedHeader?window.addEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.addEventListener("scroll",this.handleFixedHeader,!0)},destroyed(){"sticky"===this.fixedHeader?window.removeEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.removeEventListener("scroll",this.handleFixedHeader,!0)},methods:{handleStickyHeader(){const e=document.documentElement.scrollTop,t=this.$el.offsetTop;if(e>t+30){this.headerStatus||(this.headerStatus=!0,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="absolute",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="2");const n=e-(t+1)+Number(this.fixedOffset);this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.querySelector(".el-table__fixed").style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.querySelector(".el-table__fixed-right").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="4"}else this.headerStatus=!1,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.getElementsByClassName("el-table__body-wrapper")[0].style.paddingTop="0"},handleFixedHeader(){const e=this.$el.getBoundingClientRect().top,t=window.innerHeight-Number(this.fixedOffset)-(this.pagination?72:0);Math.abs(t-this.maxHeight)>3&&(this.maxHeight=t),e<=Number(this.fixedOffset)+20&&e>=0?this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="auto":this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="hidden"}}},E=O,P=h(E,d,u,!1,null,null,null),A=P.exports;A.install=function(e){e.component(A.name,A)};var C=A,W=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-button",{attrs:{type:"primary"},on:{click:function(t){e.visible=!0}}},[e._v(" 自定义列 "),n("el-dialog",{attrs:{"custom-class":"bi-column-dialog",title:"自定义列",visible:e.visible,width:"800px",top:"8vh","append-to-body":""},on:{"update:visible":function(t){e.visible=t},open:e.handleOpen,close:e.close}},[n("div",{staticClass:"dialog-body",staticStyle:{"min-height":"160px"}},[n("div",{staticClass:"bi-column-container"},[n("div",{staticClass:"checkbox-container"},[n("el-card",{staticClass:"box-card"},[n("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[n("span",[e._v("可操作性的列")])]),e._l(e.colList,(function(t,a){return n("div",{key:a,staticClass:"checkbox-group"},[n("p",{staticClass:"checkbox-title"},[n("el-checkbox",{on:{change:function(n){return e.handleCheckGroupAllChange(n,t)}},model:{value:t.status,callback:function(n){e.$set(t,"status",n)},expression:"item.status"}},[e._v(e._s(t.content))])],1),n("p",[n("el-checkbox-group",{attrs:{"true-label":1,"false-label":0},on:{change:function(n){return e.handleCheckGroupAll(t)}},model:{value:e.checkList,callback:function(t){e.checkList=t},expression:"checkList"}},e._l(t.children,(function(t,a){return n("el-checkbox",{key:a,staticStyle:{width:"120px",margin:"0 15px 15px 0"},attrs:{label:t.name}},[e._v(" "+e._s(t.content)+" ")])})),1)],1)])}))],2)],1),n("div",{staticClass:"column-container"},[n("el-card",{staticClass:"box-card"},[n("div",{staticClass:"column-title",attrs:{slot:"header"},slot:"header"},[n("span",[e._v("已选"+e._s(e.columnLength)+"列")]),n("el-button",{attrs:{type:"text"},on:{click:e.clearAll}},[e._v("清空全部")])],1),n("p",{staticClass:"column-group-title"},[e._v("左侧固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.leftColumnList,callback:function(t){e.leftColumnList=t},expression:"leftColumnList"}},e._l(e.leftColumnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1),n("p",{staticClass:"column-group-title"},[e._v("中间不固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.columnList,callback:function(t){e.columnList=t},expression:"columnList"}},e._l(e.columnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1),n("p",{staticClass:"column-group-title"},[e._v("右侧固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.rightColumnList,callback:function(t){e.rightColumnList=t},expression:"rightColumnList"}},e._l(e.rightColumnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1)])],1)])]),n("span",{staticClass:"dialog-footer",staticStyle:{display:"flex","justify-content":"space-between"},attrs:{slot:"footer"},slot:"footer"},[n("span",{staticStyle:{display:"inline-block","line-height":"32px"}},[n("el-checkbox",{attrs:{label:"全选"},on:{change:e.checkAll},model:{value:e.checkAllData,callback:function(t){e.checkAllData=t},expression:"checkAllData"}},[e._v(" 全选 ")])],1),n("div",[n("el-button",{on:{click:e.close}},[e._v("关闭")]),n("el-button",{attrs:{type:"primary"},on:{click:e.ok}},[e._v("生效")])],1)])])],1)},F=[],N=n("3335"),z=n.n(N),I={name:"BiCustomColumn",components:{draggable:z.a},props:{columnName:{type:String,require:!0,default:""},listType:{type:String,require:!0,default:""},checkData:{type:Array,require:!0,default:()=>[]},tableColumn:{type:Array,default:()=>[]},defaultList:{type:Array,default:()=>[]},defaultColumn:{type:Object,default:()=>({left:[],center:[],right:[]})}},data(){return{tableColumnList:this.tableColumn,visible:!1,colList:[],checkList:[],checkAllData:!1,draggableList:[],leftColumnList:[],columnList:[],rightColumnList:[]}},computed:{columnLength(){return this.leftColumnList.length+this.columnList.length+this.rightColumnList.length}},watch:{colList:{handler(e){let t=!0;e.forEach(e=>{e.status=Boolean(e.status),e.status?this.checkAllData=e.status:t=!1,this.checkAllData=t})},deep:!0}},mounted(){const e={type:this.listType};this.defaultColumnInit(),this.getList(e),this.returnColumn()},beforeDestroy(){this.visible=!1},methods:{defaultColumnInit(){const e=this.getLocalStorage(),{left:t,center:n,right:a}=e||this.defaultColumn;t.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.leftColumnList.push(t)}),n.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.columnList.push(t)}),a.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.rightColumnList.push(t)})},async getList(e){this.colList=this.defaultList,this.defaultCheck()},checkAll(e){this.colList.forEach(t=>{this.handleCheckGroupAllChange(e,t),t.status=e}),e||(this.checkList=[])},defaultCheck(){this.colList.forEach(e=>{this.handleCheckGroupAll(e)})},deleteArrayItemForIndex(e,t){if(-1!==t)return e.splice(t,1)},handleCheckGroupAllChange(e,t){e?t.children.map(e=>{-1===this.checkList.indexOf(e.name)&&(this.checkList.push(e.name),this.insertColumn(e.name))}):t.children.map(e=>{this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e.name)),this.removeColumn(e.name)})},handleCheckGroupAll(e){let t=1;e.children.map(e=>{-1===this.checkList.indexOf(e.name)?(this.removeColumn(e.name),t=0):this.insertColumn(e.name)}),e.status=t},async setTheadList(){const e=JSON.parse(JSON.stringify(this.colList));var t=[];e.forEach(e=>{e.status=e.status?1:0,t.push(...e.children)})},clearAll(){this.checkList=[],this.checkAll(!1)},closeColumn(e){this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e)),this.removeColumn(e),this.defaultCheck()},insertColumn(e){const t=this.tableColumnList.find(t=>t.prop===e);this.leftColumnList.find(t=>t.prop===e)||this.rightColumnList.find(t=>t.prop===e)||this.columnList.find(t=>t.prop===e)||this.columnList.push(t)},removeColumn(e){if(this.leftColumnList.length&&this.leftColumnList.find(t=>t.prop===e)){const t=this.leftColumnList.findIndex(t=>t.prop===e);t>-1&&this.leftColumnList.splice(t,1)}if(this.columnList.length&&this.columnList.find(t=>t.prop===e)){const t=this.columnList.findIndex(t=>t.prop===e);t>-1&&this.columnList.splice(t,1)}if(this.rightColumnList.length&&this.rightColumnList.find(t=>t.prop===e)){const t=this.rightColumnList.findIndex(t=>t.prop===e);t>-1&&this.rightColumnList.splice(t,1)}},returnColumn(){this.leftColumnList.map(e=>{e.fixed=!0}),this.columnList.map(e=>{e.fixed=!1}),this.rightColumnList.map(e=>{e.fixed="right"}),this.$emit("handleTableColumn",[...this.leftColumnList,...this.columnList,...this.rightColumnList])},ok(){this.returnColumn(),this.saveLocalStorage(),this.visible=!1},saveLocalStorage(){const e={left:[],center:[],right:[]};this.leftColumnList.map(({prop:t})=>{t&&e.left.push(t)}),this.columnList.map(({prop:t})=>{t&&e.center.push(t)}),this.rightColumnList.map(({prop:t})=>{t&&e.right.push(t)}),localStorage.setItem(this.columnName,JSON.stringify(e))},getLocalStorage(){const e=localStorage.getItem(this.columnName);return e?JSON.parse(e):void 0},handleOpen(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[];const e=this.getLocalStorage();e&&this.defaultColumnInit()},close(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[],this.visible=!1,this.$emit("closeDialog",{visible:!1})}}},R=I,J=(n("bde6"),n("0c8e"),h(R,W,F,!1,null,"28f3ba1d",null)),$=J.exports;$.install=function(e){e.component($.name,$)};var U=$,G=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-date-picker",e._g(e._b({attrs:{"picker-options":e.componentPickerOptions,format:e.format,"value-format":e.valueFormat},model:{value:e.date,callback:function(t){e.date=t},expression:"date"}},"el-date-picker",e.$attrs,!1),e.$listeners))},B=[],V=n("caaf"),q=n.n(V);const K={daterange:{shortcuts:[{text:"今天",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"昨天",onClick(e){const t=q()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一周",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一月",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"上个月",onClick(e){const t=q()().startOf("month").subtract(1,"month").format("YYYY-MM-DD 00:00:00"),n=q()().endOf("month").subtract(1,"month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,n])}},{text:"本月",onClick(e){const t=q()().startOf("month").format("YYYY-MM-DD 00:00:00"),n=q()().endOf("month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,n])}}]},monthrange:{shortcuts:[{text:"本月",onClick(e){const t=q()().startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近三个月",onClick(e){const t=q()().subtract(2,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近六个月",onClick(e){const t=q()().subtract(5,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近一年",onClick(e){const t=q()().subtract(11,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"今年",onClick(e){const t=q()().startOf("year").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}}]},datetimerange:{shortcuts:[{text:"今天",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"昨天",onClick(e){const t=q()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一周",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一月",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"上个月",onClick(e){if(null!==e.value){const t=q()(e.value[1]).subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()(e.value[0]).subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}else{const t=q()().subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}}},{text:"本月",onClick(e){const t=q()().endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()().startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}}]}};var X=K,Z={name:"BiDatePicker",props:{pickerOption:{type:Object,default:()=>({})},format:{type:String,default:"yyyy-MM-dd"},valueFormat:{type:String,default:"yyyy-MM-dd"},value:{type:[String,Array],default:""}},computed:{date:{get(){return this.value},set(e){this.$emit("input",e)}},componentPickerOptions(){const e=this.$attrs.type;return"daterange"===e?Object.assign(X.daterange,this.pickerOption):"monthrange"===e?Object.assign(X.monthrange,this.pickerOption):"datetimerange"===e?Object.assign(X.datetimerange,this.pickerOption):this.pickerOption}},methods:{}},Q=Z,ee=(n("9895"),h(Q,G,B,!1,null,null,null)),te=ee.exports;te.install=function(e){e.component(te.name,te)};var ne=te;const ae=[C,U,ne],re=function(e){re.installed||ae.map(t=>e.component(t.name,t))};"undefined"!==typeof window&&window.Vue&&re(window.Vue);var se={install:re,BiTable:C,BiCustomColumn:U,BiDatePicker:ne};t["default"]=se},f621:function(e,t,n){"use strict";n("047b")},f9bb:function(e,t,n){(function(e,t){t(n("caaf"))})(0,(function(e){"use strict";
|
279
|
+
var t=e.defineLocale("hy-am",{months:{format:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_"),standalone:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_")},monthsShort:"հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_"),weekdays:"կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_"),weekdaysShort:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),weekdaysMin:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY թ.",LLL:"D MMMM YYYY թ., HH:mm",LLLL:"dddd, D MMMM YYYY թ., HH:mm"},calendar:{sameDay:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",ss:"%d վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiemParse:/գիշերվա|առավոտվա|ցերեկվա|երեկոյան/,isPM:function(e){return/^(ցերեկվա|երեկոյան)$/.test(e)},meridiem:function(e){return e<4?"գիշերվա":e<12?"առավոտվա":e<17?"ցերեկվա":"երեկոյան"},dayOfMonthOrdinalParse:/\d{1,2}|\d{1,2}-(ին|րդ)/,ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}});return t}))},f4a0:function(e,t,n){"use strict";if(n.r(t),"undefined"!==typeof window){var a=window.document.currentScript,r=n("79e4");a=r(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:r});var s=a&&a.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);s&&(n.p=s[1])}var i,o,d=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"bi-table"},[n("div",{staticClass:"bi-table-wrapper"},[n("el-table",e._g(e._b({directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"elTable",attrs:{data:e.data,"max-height":e.maxHeight}},"el-table",e.$attrs,!1),e.$listeners),[e._l(e.tbColumns,(function(t){return[t.slotScope?n("el-table-column",e._g(e._b({key:t.prop+t.label,scopedSlots:e._u([{key:"default",fn:function(n){return[e._t(t.prop,null,null,n)]}}],null,!0)},"el-table-column",t,!1),e.$listeners)):n("bi-column",e._b({key:t.prop+t.label,attrs:{column:t}},"bi-column",e.$attrs,!1))]}))],2)],1),e.pagination?[e.data.length>0?n("pagination",e._g(e._b({},"pagination",e.$attrs,!1),e.$listeners)):e._e()]:e._e()],2)},u=[],l=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-table-column",e._g(e._b({scopedSlots:e._u([{key:"header",fn:function(t){return[e.column.renderHeader?n("bi-render",{attrs:{scope:t,render:e.column.renderHeader}}):n("span",[e._v(e._s(t.column.label))])]}},{key:"default",fn:function(t){return[e.column.component?n(e.column.component,e._g(e._b({tag:"component"},"component",e.getCptBind(t,e.column),!1),e.column.listeners)):e.column.children?e._l(e.column.children,(function(e){return n("free-column",{key:e.prop,attrs:{column:e}})})):n("bi-render",{attrs:{scope:t,render:e.column.render}})]}}])},"el-table-column",e.column,!1),e.$listeners))},_=[],m={name:"BiRender",functional:!0,props:{scope:{type:Object,default:()=>({})},render:{type:Function,default:()=>()=>{}}},render:(e,t)=>t.props.render?t.props.render(e,t.props.scope):""},c=m;function h(e,t,n,a,r,s,i,o){var d,u="function"===typeof e?e.options:e;if(t&&(u.render=t,u.staticRenderFns=n,u._compiled=!0),a&&(u.functional=!0),s&&(u._scopeId="data-v-"+s),i?(d=function(e){e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,e||"undefined"===typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),r&&r.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(i)},u._ssrRegister=d):r&&(d=o?function(){r.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:r),d)if(u.functional){u._injectStyles=d;var l=u.render;u.render=function(e,t){return d.call(t),l(e,t)}}else{var _=u.beforeCreate;u.beforeCreate=_?[].concat(_,d):[d]}return{exports:e,options:u}}var f=h(c,i,o,!1,null,null,null),M=f.exports,p={selection:{renderHeader:function(e,{store:t}){return e("el-checkbox",{attrs:{disabled:t.states.data&&0===t.states.data.length,indeterminate:t.states.selection.length>0&&!this.isAllSelected,value:this.isAllSelected},nativeOn:{click:this.toggleAllSelection}})},renderCell:function(e,{row:t,column:n,store:a,$index:r}){return e("el-checkbox",{nativeOn:{click:e=>e.stopPropagation()},attrs:{value:a.isSelected(t),disabled:!!n.selectable&&!n.selectable.call(null,t,r)},on:{input:()=>{a.commit("rowSelectedChanged",t)}}})},sortable:!1,resizable:!1},index:{renderHeader:function(e,{column:t}){return t.label||"#"},renderCell:function(e,{$index:t,column:n}){let a=t+1;const r=n.index;return"number"===typeof r?a=t+r:"function"===typeof r&&(a=r(t)),e("div",[a])},sortable:!1},expand:{renderHeader:function(e,{column:t}){return t.label||""},renderCell:function(e,{row:t,store:n}){const a=["el-table__expand-icon"];n.states.expandRows.indexOf(t)>-1&&a.push("el-table__expand-icon--expanded");const r=function(e){e.stopPropagation(),n.toggleRowExpansion(t)};return e("div",{class:a,on:{click:r}},[e("i",{class:"el-icon el-icon-arrow-right"})])},sortable:!1,resizable:!1,className:"el-table__expand-column"}},y={name:"BiColumn",components:{BiRender:M},props:{column:{type:Object,default:()=>{}}},watch:{column:{handler:"renderColumn",immediate:!0}},methods:{renderColumn(){this.$createElement;const{column:e}=this;return e.type&&(e.renderHeader=p[e.type].renderHeader,e.render=e.render||p[e.type].renderCell),e.formatter&&(e.render=(e,t)=>e("span",[t.column.formatter(t.row,t.column,t.row[t.column.property],t.$index)])),e.render||(e.render=(e,t)=>e("span",[t.row[t.column.property]])),e},getColBind(e){const t=Object.assign({},this.$attrs,e);return delete t.component,delete t.listeners,delete t.propsHandler,t},getCptBind({row:e,column:t},n){const a={row:e,col:n,column:t},r=n.propsHandler;return r&&r(a)||a}}},L=y,Y=h(L,l,_,!1,null,null,null),g=Y.exports,v=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"pagination-container",class:{hidden:e.hidden}},[n("el-pagination",e._b({attrs:{background:e.background,"current-page":e.currentPage,"page-size":e.pageSize,layout:e.layout,"page-sizes":e.pageSizes,total:e.total},on:{"update:currentPage":function(t){e.currentPage=t},"update:current-page":function(t){e.currentPage=t},"update:pageSize":function(t){e.pageSize=t},"update:page-size":function(t){e.pageSize=t},"size-change":e.handleSizeChange,"current-change":e.handleCurrentChange}},"el-pagination",e.$attrs,!1))],1)},D=[];Math.easeInOutQuad=function(e,t,n,a){return e/=a/2,e<1?n/2*e*e+t:(e--,-n/2*(e*(e-2)-1)+t)};var k=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}();function b(e){document.documentElement.scrollTop=e,document.body.parentNode.scrollTop=e,document.body.scrollTop=e}function w(){return document.documentElement.scrollTop||document.body.parentNode.scrollTop||document.body.scrollTop}function T(e,t,n){const a=w(),r=e-a,s=20;let i=0;t="undefined"===typeof t?500:t;var o=function(){i+=s;var e=Math.easeInOutQuad(i,a,r,t);b(e),i<t?k(o):n&&"function"===typeof n&&n()};o()}var S={name:"BiPagination",props:{total:{required:!0,type:Number},page:{type:Number,default:1},limit:{type:Number,default:20},pageSizes:{type:Array,default(){return[10,20,30,50]}},layout:{type:String,default:"total, sizes, prev, pager, next, jumper"},background:{type:Boolean,default:!0},autoScroll:{type:Boolean,default:!0},hidden:{type:Boolean,default:!1}},computed:{currentPage:{get(){return this.page},set(e){this.$emit("update:page",e)}},pageSize:{get(){return this.limit},set(e){this.$emit("update:limit",e)}}},methods:{handleSizeChange(e){this.$emit("pagination",{page:this.currentPage,limit:e}),this.autoScroll&&T(0,800)},handleCurrentChange(e){this.$emit("pagination",{page:e,limit:this.pageSize}),this.autoScroll&&T(0,800)}}},H=S,x=(n("f621"),h(H,v,D,!1,null,"c276c1ba",null)),j=x.exports,O={name:"BiTable",components:{Pagination:j,BiColumn:g},props:{data:{type:Array,default:()=>[]},column:{type:Array,default:()=>[]},columnsProps:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},pagination:{type:Boolean,default:!1},fixed:{type:String,default:""},fixedOffset:{type:String,default:""}},data(){return{maxHeight:null}},computed:{tbColumns(){const{column:e,columnsProps:t}=this;return e.map(e=>{const n=Object.assign({},t,e);return n})},fixedHeader(){return this.fixed}},mounted(){"sticky"===this.fixedHeader?window.addEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.addEventListener("scroll",this.handleFixedHeader,!0)},destroyed(){"sticky"===this.fixedHeader?window.removeEventListener("scroll",this.handleStickyHeader,!0):"fullscreen"===this.fixedHeader&&window.removeEventListener("scroll",this.handleFixedHeader,!0)},methods:{handleStickyHeader(){const e=document.documentElement.scrollTop,t=this.$el.offsetTop;if(e>t+30){this.headerStatus||(this.headerStatus=!0,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="absolute",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="2");const n=e-(t+1)+Number(this.fixedOffset);this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.querySelector(".el-table__fixed").style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform=`translate3d(0px, ${n}px, 0px)`,this.$el.querySelector(".el-table__fixed-right").style.zIndex="4",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="4"}else this.headerStatus=!1,this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.position="relative",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.transform="translate3d(0px, 0px, 0px)",this.$el.getElementsByClassName("el-table__header-wrapper")[0].style.zIndex="3",this.$el.querySelector(".el-table__fixed .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.querySelector(".el-table__fixed-right .el-table__fixed-header-wrapper").style.zIndex="3",this.$el.getElementsByClassName("el-table__body-wrapper")[0].style.paddingTop="0"},handleFixedHeader(){const e=this.$el.getBoundingClientRect().top,t=window.innerHeight-Number(this.fixedOffset)-(this.pagination?72:0);Math.abs(t-this.maxHeight)>3&&(this.maxHeight=t),e<=Number(this.fixedOffset)+20&&e>=0?this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="auto":this.$el.querySelector(".bi-table-wrapper>.el-table>.el-table__body-wrapper").style.overflowY="hidden"}}},E=O,P=h(E,d,u,!1,null,null,null),A=P.exports;A.install=function(e){e.component(A.name,A)};var C=A,W=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-button",{attrs:{type:"primary"},on:{click:function(t){e.visible=!0}}},[e._v(" 自定义列 "),n("el-dialog",{attrs:{"custom-class":"bi-column-dialog",title:"自定义列",visible:e.visible,width:"800px",top:"8vh","append-to-body":""},on:{"update:visible":function(t){e.visible=t},open:e.handleOpen,close:e.close}},[n("div",{staticClass:"dialog-body",staticStyle:{"min-height":"160px"}},[n("div",{staticClass:"bi-column-container"},[n("div",{staticClass:"checkbox-container"},[n("el-card",{staticClass:"box-card"},[n("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[n("span",[e._v("可操作性的列")])]),e._l(e.colList,(function(t,a){return n("div",{key:a,staticClass:"checkbox-group"},[n("p",{staticClass:"checkbox-title"},[n("el-checkbox",{on:{change:function(n){return e.handleCheckGroupAllChange(n,t)}},model:{value:t.status,callback:function(n){e.$set(t,"status",n)},expression:"item.status"}},[e._v(e._s(t.content))])],1),n("p",[n("el-checkbox-group",{attrs:{"true-label":1,"false-label":0},on:{change:function(n){return e.handleCheckGroupAll(t)}},model:{value:e.checkList,callback:function(t){e.checkList=t},expression:"checkList"}},e._l(t.children,(function(t,a){return n("el-checkbox",{key:a,staticStyle:{width:"120px",margin:"0 15px 15px 0"},attrs:{label:t.name}},[e._v(" "+e._s(t.content)+" ")])})),1)],1)])}))],2)],1),n("div",{staticClass:"column-container"},[n("el-card",{staticClass:"box-card"},[n("div",{staticClass:"column-title",attrs:{slot:"header"},slot:"header"},[n("span",[e._v("已选"+e._s(e.columnLength)+"列")]),n("el-button",{attrs:{type:"text"},on:{click:e.clearAll}},[e._v("清空全部")])],1),n("p",{staticClass:"column-group-title"},[e._v("左侧固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.leftColumnList,callback:function(t){e.leftColumnList=t},expression:"leftColumnList"}},e._l(e.leftColumnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1),n("p",{staticClass:"column-group-title"},[e._v("中间不固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.columnList,callback:function(t){e.columnList=t},expression:"columnList"}},e._l(e.columnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1),n("p",{staticClass:"column-group-title"},[e._v("右侧固定列")]),n("div",{staticClass:"column-configurable"},[n("draggable",{attrs:{group:"column"},model:{value:e.rightColumnList,callback:function(t){e.rightColumnList=t},expression:"rightColumnList"}},e._l(e.rightColumnList,(function(t){return n("div",{key:t.prop,staticClass:"selected-column-item"},[n("i",{staticClass:"el-icon-menu"}),n("div",{staticClass:"column-name"},[e._v(e._s(t.content||t.label))]),n("i",{staticClass:"el-icon-close column-close",on:{click:function(n){return e.closeColumn(t.prop)}}})])})),0)],1)])],1)])]),n("span",{staticClass:"dialog-footer",staticStyle:{display:"flex","justify-content":"space-between"},attrs:{slot:"footer"},slot:"footer"},[n("span",{staticStyle:{display:"inline-block","line-height":"32px"}},[n("el-checkbox",{attrs:{label:"全选"},on:{change:e.checkAll},model:{value:e.checkAllData,callback:function(t){e.checkAllData=t},expression:"checkAllData"}},[e._v(" 全选 ")])],1),n("div",[n("el-button",{on:{click:e.close}},[e._v("关闭")]),n("el-button",{attrs:{type:"primary"},on:{click:e.ok}},[e._v("生效")])],1)])])],1)},F=[],N=n("3335"),z=n.n(N),I={name:"BiCustomColumn",components:{draggable:z.a},props:{columnName:{type:String,require:!0,default:""},listType:{type:String,require:!0,default:""},checkData:{type:Array,require:!0,default:()=>[]},tableColumn:{type:Array,default:()=>[]},defaultList:{type:Array,default:()=>[]},defaultColumn:{type:Object,default:()=>({left:[],center:[],right:[]})}},data(){return{tableColumnList:this.tableColumn,visible:!1,colList:[],checkList:[],checkAllData:!1,draggableList:[],leftColumnList:[],columnList:[],rightColumnList:[]}},computed:{columnLength(){return this.leftColumnList.length+this.columnList.length+this.rightColumnList.length}},watch:{colList:{handler(e){let t=!0;e.forEach(e=>{e.status=Boolean(e.status),e.status?this.checkAllData=e.status:t=!1,this.checkAllData=t})},deep:!0}},mounted(){const e={type:this.listType};this.defaultColumnInit(),this.getList(e),this.returnColumn()},beforeDestroy(){this.visible=!1},methods:{defaultColumnInit(){const e=this.getLocalStorage(),{left:t,center:n,right:a}=e||this.defaultColumn;t.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.leftColumnList.push(t)}),n.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.columnList.push(t)}),a.map(e=>{this.checkList.push(e);const t=this.tableColumnList.find(t=>t.prop===e);t&&this.rightColumnList.push(t)})},async getList(e){this.colList=this.defaultList,this.defaultCheck()},checkAll(e){this.colList.forEach(t=>{this.handleCheckGroupAllChange(e,t),t.status=e}),e||(this.checkList=[])},defaultCheck(){this.colList.forEach(e=>{this.handleCheckGroupAll(e)})},deleteArrayItemForIndex(e,t){if(-1!==t)return e.splice(t,1)},handleCheckGroupAllChange(e,t){e?t.children.map(e=>{-1===this.checkList.indexOf(e.name)&&(this.checkList.push(e.name),this.insertColumn(e.name))}):t.children.map(e=>{this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e.name)),this.removeColumn(e.name)})},handleCheckGroupAll(e){let t=1;e.children.map(e=>{-1===this.checkList.indexOf(e.name)?(this.removeColumn(e.name),t=0):this.insertColumn(e.name)}),e.status=t},async setTheadList(){const e=JSON.parse(JSON.stringify(this.colList));var t=[];e.forEach(e=>{e.status=e.status?1:0,t.push(...e.children)})},clearAll(){this.checkList=[],this.checkAll(!1)},closeColumn(e){this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(e)),this.removeColumn(e),this.defaultCheck()},insertColumn(e){const t=this.tableColumnList.find(t=>t.prop===e);this.leftColumnList.find(t=>t.prop===e)||this.rightColumnList.find(t=>t.prop===e)||this.columnList.find(t=>t.prop===e)||this.columnList.push(t)},removeColumn(e){if(this.leftColumnList.length&&this.leftColumnList.find(t=>t.prop===e)){const t=this.leftColumnList.findIndex(t=>t.prop===e);t>-1&&this.leftColumnList.splice(t,1)}if(this.columnList.length&&this.columnList.find(t=>t.prop===e)){const t=this.columnList.findIndex(t=>t.prop===e);t>-1&&this.columnList.splice(t,1)}if(this.rightColumnList.length&&this.rightColumnList.find(t=>t.prop===e)){const t=this.rightColumnList.findIndex(t=>t.prop===e);t>-1&&this.rightColumnList.splice(t,1)}},returnColumn(){this.leftColumnList.map(e=>{e.fixed=!0}),this.columnList.map(e=>{e.fixed=!1}),this.rightColumnList.map(e=>{e.fixed="right"}),this.$emit("handleTableColumn",[...this.leftColumnList,...this.columnList,...this.rightColumnList])},ok(){this.returnColumn(),this.saveLocalStorage(),this.visible=!1},saveLocalStorage(){const e={left:[],center:[],right:[]};this.leftColumnList.map(({prop:t})=>{t&&e.left.push(t)}),this.columnList.map(({prop:t})=>{t&&e.center.push(t)}),this.rightColumnList.map(({prop:t})=>{t&&e.right.push(t)}),localStorage.setItem(this.columnName,JSON.stringify(e))},getLocalStorage(){const e=localStorage.getItem(this.columnName);return e?JSON.parse(e):void 0},handleOpen(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[];const e=this.getLocalStorage();e&&this.defaultColumnInit()},close(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[],this.visible=!1,this.$emit("closeDialog",{visible:!1})}}},R=I,J=(n("bde6"),n("0c8e"),h(R,W,F,!1,null,"28f3ba1d",null)),$=J.exports;$.install=function(e){e.component($.name,$)};var U=$,G=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-date-picker",e._g(e._b({attrs:{"picker-options":e.componentPickerOptions,format:e.format,"value-format":e.valueFormat},model:{value:e.date,callback:function(t){e.date=t},expression:"date"}},"el-date-picker",e.$attrs,!1),e.$listeners))},B=[],V=n("caaf"),q=n.n(V);const K={daterange:{shortcuts:[{text:"今天",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"昨天",onClick(e){const t=q()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一周",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一月",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"上个月",onClick(e){const t=q()().startOf("month").subtract(1,"month").format("YYYY-MM-DD 00:00:00"),n=q()().endOf("month").subtract(1,"month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,n])}},{text:"本月",onClick(e){const t=q()().startOf("month").format("YYYY-MM-DD 00:00:00"),n=q()().endOf("month").format("YYYY-MM-DD 23:59:59");e.$emit("pick",[t,n])}}]},monthrange:{shortcuts:[{text:"本月",onClick(e){const t=q()().startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近三个月",onClick(e){const t=q()().subtract(2,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近六个月",onClick(e){const t=q()().subtract(5,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"最近一年",onClick(e){const t=q()().subtract(11,"month").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}},{text:"今年",onClick(e){const t=q()().startOf("year").startOf("month").format("YYYY-MM-DD"),n=q()().endOf("month").format("YYYY-MM-DD");e.$emit("pick",[t,n])}}]},datetimerange:{shortcuts:[{text:"今天",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"昨天",onClick(e){const t=q()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一周",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"近一月",onClick(e){const t=q()().format("YYYY-MM-DD 23:59:59"),n=q()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}},{text:"上个月",onClick(e){if(null!==e.value){const t=q()(e.value[1]).subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()(e.value[0]).subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}else{const t=q()().subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()().subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}}},{text:"本月",onClick(e){const t=q()().endOf("month").format("YYYY-MM-DD 23:59:59"),n=q()().startOf("month").format("YYYY-MM-DD 00:00:00");e.$emit("pick",[n,t])}}]}};var X=K,Z={name:"BiDatePicker",props:{pickerOption:{type:Object,default:()=>({})},format:{type:String,default:"yyyy-MM-dd"},valueFormat:{type:String,default:"yyyy-MM-dd"},value:{type:[String,Array],default:""}},computed:{date:{get(){return this.value},set(e){this.$emit("input",e)}},componentPickerOptions(){const e=this.$attrs.type,t=Object.assign({},X[e]);return"daterange"===e||"monthrange"===e||"datetimerange"===e?Object.assign(t,this.pickerOption):this.pickerOption}},methods:{}},Q=Z,ee=(n("9895"),h(Q,G,B,!1,null,null,null)),te=ee.exports;te.install=function(e){e.component(te.name,te)};var ne=te;const ae=[C,U,ne],re=function(e){re.installed||ae.map(t=>e.component(t.name,t))};"undefined"!==typeof window&&window.Vue&&re(window.Vue);var se={install:re,BiTable:C,BiCustomColumn:U,BiDatePicker:ne};t["default"]=se},f621:function(e,t,n){"use strict";n("047b")},f9bb:function(e,t,n){(function(e,t){t(n("caaf"))})(0,(function(e){"use strict";
|
280
280
|
//! moment.js locale configuration
|
281
281
|
var t=["Eanáir","Feabhra","Márta","Aibreán","Bealtaine","Meitheamh","Iúil","Lúnasa","Meán Fómhair","Deireadh Fómhair","Samhain","Nollaig"],n=["Ean","Feabh","Márt","Aib","Beal","Meith","Iúil","Lún","M.F.","D.F.","Samh","Noll"],a=["Dé Domhnaigh","Dé Luain","Dé Máirt","Dé Céadaoin","Déardaoin","Dé hAoine","Dé Sathairn"],r=["Domh","Luan","Máirt","Céad","Déar","Aoine","Sath"],s=["Do","Lu","Má","Cé","Dé","A","Sa"],i=e.defineLocale("ga",{months:t,monthsShort:n,monthsParseExact:!0,weekdays:a,weekdaysShort:r,weekdaysMin:s,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Inniu ag] LT",nextDay:"[Amárach ag] LT",nextWeek:"dddd [ag] LT",lastDay:"[Inné ag] LT",lastWeek:"dddd [seo caite] [ag] LT",sameElse:"L"},relativeTime:{future:"i %s",past:"%s ó shin",s:"cúpla soicind",ss:"%d soicind",m:"nóiméad",mm:"%d nóiméad",h:"uair an chloig",hh:"%d uair an chloig",d:"lá",dd:"%d lá",M:"mí",MM:"%d míonna",y:"bliain",yy:"%d bliain"},dayOfMonthOrdinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){var t=1===e?"d":e%10===2?"na":"mh";return e+t},week:{dow:1,doy:4}});return i}))},fa2c:function(e,t,n){(function(e,t){t(n("caaf"))})(0,(function(e){"use strict";
|
282
282
|
//! moment.js locale configuration
|
package/package.json
CHANGED
package/src/views/Date.vue
CHANGED
@@ -2,48 +2,56 @@
|
|
2
2
|
<div class="free-table">
|
3
3
|
<div class="example-table-box">
|
4
4
|
<p>基础日期-{{ date }}</p>
|
5
|
-
<
|
5
|
+
<BiDatePicker
|
6
6
|
v-model="date"
|
7
7
|
type="date"
|
8
8
|
placeholder="选择日期"
|
9
|
-
></
|
9
|
+
></BiDatePicker>
|
10
10
|
</div>
|
11
11
|
<div class="example-table-box">
|
12
12
|
<p>基础周-{{ date1 }}</p>
|
13
|
-
<
|
13
|
+
<BiDatePicker
|
14
14
|
v-model="date1"
|
15
15
|
type="week"
|
16
16
|
placeholder="选择周"
|
17
|
-
></
|
17
|
+
></BiDatePicker>
|
18
18
|
</div>
|
19
19
|
<div class="example-table-box">
|
20
20
|
<p>基础月-{{ date2 }}</p>
|
21
|
-
<
|
21
|
+
<BiDatePicker
|
22
22
|
v-model="date2"
|
23
23
|
type="month"
|
24
24
|
placeholder="选择周"
|
25
|
-
></
|
25
|
+
></BiDatePicker>
|
26
26
|
</div>
|
27
27
|
<div class="example-table-box">
|
28
28
|
<p>范围日期-{{ date3 }}</p>
|
29
|
-
<
|
29
|
+
<BiDatePicker
|
30
30
|
v-model="date3"
|
31
31
|
type="daterange"
|
32
|
-
placeholder="选择日期"
|
33
|
-
|
32
|
+
placeholder="选择日期1"
|
33
|
+
:picker-option="pickerOptions1"
|
34
|
+
></BiDatePicker>
|
35
|
+
<p>范围日期-{{ date7 }}</p>
|
36
|
+
<BiDatePicker
|
37
|
+
v-model="date7"
|
38
|
+
type="daterange"
|
39
|
+
placeholder="选择日期2"
|
40
|
+
:picker-option="pickerOptions2"
|
41
|
+
></BiDatePicker>
|
34
42
|
</div>
|
35
43
|
<div class="example-table-box">
|
36
44
|
<p>范围月-{{ date5 }}</p>
|
37
|
-
<
|
45
|
+
<BiDatePicker
|
38
46
|
v-model="date5"
|
39
47
|
type="monthrange"
|
40
48
|
placeholder="选择日期"
|
41
49
|
format="yyyy-MM"
|
42
|
-
></
|
50
|
+
></BiDatePicker>
|
43
51
|
</div>
|
44
52
|
<div class="example-table-box">
|
45
53
|
<p>范围日期时间-{{ date6 }}</p>
|
46
|
-
<
|
54
|
+
<BiDatePicker
|
47
55
|
v-model="date6"
|
48
56
|
type="datetimerange"
|
49
57
|
format="yyyy-MM-dd HH:mm:ss"
|
@@ -52,17 +60,18 @@
|
|
52
60
|
range-separator="至"
|
53
61
|
start-placeholder="开始日期"
|
54
62
|
end-placeholder="结束日期"
|
55
|
-
></
|
63
|
+
></BiDatePicker>
|
56
64
|
</div>
|
57
65
|
</div>
|
58
66
|
</template>
|
59
67
|
|
60
68
|
<script>
|
61
|
-
import BiDatepicker from '@/components/BiDatePicker'
|
69
|
+
// import BiDatepicker from '@/components/BiDatePicker'
|
70
|
+
import moment from 'moment'
|
62
71
|
|
63
72
|
export default {
|
64
73
|
components: {
|
65
|
-
BiDatepicker
|
74
|
+
// BiDatepicker
|
66
75
|
},
|
67
76
|
data() {
|
68
77
|
return {
|
@@ -73,6 +82,7 @@ export default {
|
|
73
82
|
date4: [],
|
74
83
|
date5: [],
|
75
84
|
date6: [],
|
85
|
+
date7: [],
|
76
86
|
columnsProps: {
|
77
87
|
width: 'auto'
|
78
88
|
},
|
@@ -82,7 +92,19 @@ export default {
|
|
82
92
|
limit: 20
|
83
93
|
},
|
84
94
|
editForm: {},
|
85
|
-
dialogVisible: false
|
95
|
+
dialogVisible: false,
|
96
|
+
pickerOptions1: {
|
97
|
+
firstDayOfWeek: 1,
|
98
|
+
onPick: ({ minDate, maxDate }) => {
|
99
|
+
console.log(1, moment(minDate).format('YYYY-MM-DD'))
|
100
|
+
}
|
101
|
+
},
|
102
|
+
pickerOptions2: {
|
103
|
+
firstDayOfWeek: 1,
|
104
|
+
onPick: ({ minDate, maxDate }) => {
|
105
|
+
console.log(2, moment(minDate).format('YYYY-MM-DD'))
|
106
|
+
}
|
107
|
+
}
|
86
108
|
}
|
87
109
|
},
|
88
110
|
methods: {
|
@@ -1 +0,0 @@
|
|
1
|
-
.free-button{margin:10px 0}.example-table-box[data-v-39644852]{margin:25px 50px}.example-table-box p[data-v-39644852]{text-align:left;font-weight:700}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["about"],{"0f0e":function(t,e,a){},"3a43":function(t,e,a){"use strict";a.r(e);var o=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"free-table"},[a("div",{staticClass:"example-table-box"},[a("p",[t._v("基础日期-"+t._s(t.date))]),a("bi-datepicker",{attrs:{type:"date",placeholder:"选择日期"},model:{value:t.date,callback:function(e){t.date=e},expression:"date"}})],1),a("div",{staticClass:"example-table-box"},[a("p",[t._v("基础周-"+t._s(t.date1))]),a("bi-datepicker",{attrs:{type:"week",placeholder:"选择周"},model:{value:t.date1,callback:function(e){t.date1=e},expression:"date1"}})],1),a("div",{staticClass:"example-table-box"},[a("p",[t._v("基础月-"+t._s(t.date2))]),a("bi-datepicker",{attrs:{type:"month",placeholder:"选择周"},model:{value:t.date2,callback:function(e){t.date2=e},expression:"date2"}})],1),a("div",{staticClass:"example-table-box"},[a("p",[t._v("范围日期-"+t._s(t.date3))]),a("bi-datepicker",{attrs:{type:"daterange",placeholder:"选择日期"},model:{value:t.date3,callback:function(e){t.date3=e},expression:"date3"}})],1),a("div",{staticClass:"example-table-box"},[a("p",[t._v("范围月-"+t._s(t.date5))]),a("bi-datepicker",{attrs:{type:"monthrange",placeholder:"选择日期",format:"yyyy-MM"},model:{value:t.date5,callback:function(e){t.date5=e},expression:"date5"}})],1),a("div",{staticClass:"example-table-box"},[a("p",[t._v("范围日期时间-"+t._s(t.date6))]),a("bi-datepicker",{attrs:{type:"datetimerange",format:"yyyy-MM-dd HH:mm:ss","value-format":"yyyy-MM-dd HH:mm:ss","default-time":["00:00:00","23:59:59"],"range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},model:{value:t.date6,callback:function(e){t.date6=e},expression:"date6"}})],1)])},n=[],s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("el-date-picker",t._g(t._b({attrs:{"picker-options":t.componentPickerOptions,format:t.format,"value-format":t.valueFormat},model:{value:t.date,callback:function(e){t.date=e},expression:"date"}},"el-date-picker",t.$attrs,!1),t.$listeners))},i=[],r=a("caaf"),c=a.n(r);const Y={daterange:{shortcuts:[{text:"今天",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"昨天",onClick(t){const e=c()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=c()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"近一周",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"近一月",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"上个月",onClick(t){const e=c()().startOf("month").subtract(1,"month").format("YYYY-MM-DD 00:00:00"),a=c()().endOf("month").subtract(1,"month").format("YYYY-MM-DD 23:59:59");t.$emit("pick",[e,a])}},{text:"本月",onClick(t){const e=c()().startOf("month").format("YYYY-MM-DD 00:00:00"),a=c()().endOf("month").format("YYYY-MM-DD 23:59:59");t.$emit("pick",[e,a])}}]},monthrange:{shortcuts:[{text:"本月",onClick(t){const e=c()().startOf("month").format("YYYY-MM-DD"),a=c()().endOf("month").format("YYYY-MM-DD");t.$emit("pick",[e,a])}},{text:"最近三个月",onClick(t){const e=c()().subtract(2,"month").startOf("month").format("YYYY-MM-DD"),a=c()().endOf("month").format("YYYY-MM-DD");t.$emit("pick",[e,a])}},{text:"最近六个月",onClick(t){const e=c()().subtract(5,"month").startOf("month").format("YYYY-MM-DD"),a=c()().endOf("month").format("YYYY-MM-DD");t.$emit("pick",[e,a])}},{text:"最近一年",onClick(t){const e=c()().subtract(11,"month").startOf("month").format("YYYY-MM-DD"),a=c()().endOf("month").format("YYYY-MM-DD");t.$emit("pick",[e,a])}},{text:"今年",onClick(t){const e=c()().startOf("year").startOf("month").format("YYYY-MM-DD"),a=c()().endOf("month").format("YYYY-MM-DD");t.$emit("pick",[e,a])}}]},datetimerange:{shortcuts:[{text:"今天",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"昨天",onClick(t){const e=c()().subtract(1,"days").format("YYYY-MM-DD 23:59:59"),a=c()().subtract(1,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"近一周",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().subtract(7,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"近一月",onClick(t){const e=c()().format("YYYY-MM-DD 23:59:59"),a=c()().subtract(30,"days").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}},{text:"上个月",onClick(t){if(null!==t.value){const e=c()(t.value[1]).subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=c()(t.value[0]).subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}else{const e=c()().subtract(1,"months").endOf("month").format("YYYY-MM-DD 23:59:59"),a=c()().subtract(1,"months").startOf("month").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}}},{text:"本月",onClick(t){const e=c()().endOf("month").format("YYYY-MM-DD 23:59:59"),a=c()().startOf("month").format("YYYY-MM-DD 00:00:00");t.$emit("pick",[a,e])}}]}};var m=Y,l={name:"BiDatepicker",props:{pickerOption:{type:Object,default:()=>({})},format:{type:String,default:"yyyy-MM-dd"},valueFormat:{type:String,default:"yyyy-MM-dd"},value:{type:String||Array,default:""}},computed:{date:{get(){return this.value},set(t){this.$emit("input",t)}},componentPickerOptions(){const t=this.$attrs.type;return"daterange"===t?Object.assign(m.daterange,this.pickerOption):"monthrange"===t?Object.assign(m.monthrange,this.pickerOption):"datetimerange"===t?Object.assign(m.datetimerange,this.pickerOption):this.pickerOption}},methods:{}},d=l,p=(a("6593"),a("cba8")),f=Object(p["a"])(d,s,i,!1,null,null,null),M=f.exports,u={components:{BiDatepicker:M},data(){return{date:"",date1:"",date2:"",date3:[],date4:[],date5:[],date6:[],columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1}},methods:{selectionChange(t){console.log("selected",t)},getList(){},openDialog({row:t}){this.editForm=Object.assign({},t),this.dialogVisible=!0}}},D=u,k=(a("afa3"),Object(p["a"])(D,o,n,!1,null,"39644852",null));e["default"]=k.exports},6593:function(t,e,a){"use strict";a("cc7f")},afa3:function(t,e,a){"use strict";a("0f0e")},cc7f:function(t,e,a){}}]);
|
2
|
-
//# sourceMappingURL=about.93275045.js.map
|