You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
3.6 KiB
10 lines
3.6 KiB
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["components/areaWindow/index"],{"06ca":function(e,t,s){"use strict";s.r(t);var i=s("53d8"),d=s.n(i);for(var n in i)["default"].indexOf(n)<0&&function(e){s.d(t,e,(function(){return i[e]}))}(n);t["default"]=d.a},"53d8":function(e,t,s){"use strict";var i=s("47a9");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var d=i(s("af34")),n=s("a230"),r={},c={components:{tuiDrawer:function(){s.e("components/tui-drawer/tui-drawer").then(function(){return resolve(s("01c9"))}.bind(null,s)).catch(s.oe)}},props:{display:{type:Boolean,default:!1},cityShow:{type:Number,default:3},address:{type:Array|Object,default:[]},checkStrictly:{type:Boolean,default:!0}},data:function(){return{active:0,addressList:[],selectedArr:[],selectedIndex:-1,is_loading:!1,old:{scrollTop:0},scrollTop:0}},computed:{activeId:function(){return-1==this.selectedIndex?0:this.selectedArr[this.selectedIndex].id},showMore:function(){return!this.selectedArr.length||this.selectedArr[this.selectedArr.length-1].hasOwnProperty("children")&&(1==this.cityShow&&this.addressList.level<2||2==this.cityShow&&this.addressList.level<3||3==this.cityShow&&this.addressList.level<4)}},watch:{address:function(e){this.selectedArr=e?(0,d.default)(e):[]},display:function(e){e?this.loadAddress(0):(this.addressList=[],this.selectedArr=this.address?(0,d.default)(this.address):[],this.selectedIndex=-1,this.is_loading=!1)}},mounted:function(){this.loadAddress(0)},methods:{change:function(e,t){this.selectedIndex!=t&&(-1===e&&(e=this.selectedArr.length?this.selectedArr[this.selectedArr.length-1].id:0),this.selectedIndex=t,this.loadAddress(e))},loadAddress:function(e){var t=this;r[e]?this.addressList=r[e]:(this.is_loading=!0,(0,n.getCityData)(e).then((function(s){t.is_loading=!1,r[e]=s.data,t.addressList=s.data})),this.goTop())},selected:function(e){this.is_loading||(this.selectedIndex>-1?(this.selectedArr.splice(this.selectedIndex+1,999),this.selectedArr[this.selectedIndex]=e,this.selectedIndex=-1):e.pid?this.selectedArr.push(e):this.selectedArr=[e],e.hasOwnProperty("children")&&(1==this.cityShow&&this.addressList[0].level<2||2==this.cityShow&&this.addressList[0].level<3||3==this.cityShow&&this.addressList[0].level<4)?this.loadAddress(e.id):(this.$emit("submit",(0,d.default)(this.selectedArr)),this.$emit("changeClose")),this.goTop())},close:function(){this.$emit("changeClose")},scroll:function(e){this.old.scrollTop=e.detail.scrollTop},goTop:function(e){var t=this;this.scrollTop=this.old.scrollTop,this.$nextTick((function(){t.scrollTop=0}))},confirm:function(){this.$emit("submit",(0,d.default)(this.selectedArr)),this.$emit("changeClose")},refresh:function(){this.selectedArr=[],this.loadAddress(0)}}};t.default=c},"9c12":function(e,t,s){"use strict";s.d(t,"b",(function(){return i})),s.d(t,"c",(function(){return d})),s.d(t,"a",(function(){}));var i=function(){var e=this.$createElement;this._self._c},d=[]},bdaa:function(e,t,s){},d1e3:function(e,t,s){"use strict";var i=s("bdaa"),d=s.n(i);d.a},e740:function(e,t,s){"use strict";s.r(t);var i=s("9c12"),d=s("06ca");for(var n in d)["default"].indexOf(n)<0&&function(e){s.d(t,e,(function(){return d[e]}))}(n);s("d1e3");var r=s("828b"),c=Object(r["a"])(d["default"],i["b"],i["c"],!1,null,"16dceeb5",null,!1,i["a"],void 0);t["default"]=c.exports}}]);
|
|
;(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
|
|
'components/areaWindow/index-create-component',
|
|
{
|
|
'components/areaWindow/index-create-component':(function(module, exports, __webpack_require__){
|
|
__webpack_require__('df3c')['createComponent'](__webpack_require__("e740"))
|
|
})
|
|
},
|
|
[['components/areaWindow/index-create-component']]
|
|
]);
|
|
|