(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["components/form/FormRegionItem"],{"4fe5":function(e,i,n){"use strict";n.r(i);var t=n("92c1"),o=n.n(t);for(var r in t)["default"].indexOf(r)<0&&function(e){n.d(i,e,(function(){return t[e]}))}(r);i["default"]=o.a},"92c1":function(e,i,n){"use strict";(function(e){Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0;var n={name:"FormRegionItem",props:{value:{type:[Array],default:""},label:{type:String,default:""},type:{type:String,default:"text"},maxlength:{type:Number,default:140},required:{type:Boolean,default:!1}},data:function(){return{chooseRegion:[],regions:[],region_list:[],regionIndex:[0,0,0]}},watch:{value:{handler:function(e,i){this.chooseRegion=JSON.parse(JSON.stringify(e))},deep:!0}},mounted:function(){this.getRegions()},methods:{regionColumn:function(e){var i=e.detail,n=i.column,t=i.value;this.regionIndex[n]=t;for(var o=n+1;o<this.regionIndex.length;o++)this.regionIndex[o]=0;this.$forceUpdate(),this.setRegion(1)},regionPicker:function(e){this.regionIndex=e.detail.value;var i=[];i.push(this.region_list[0][this.regionIndex[0]]),i.push(this.region_list[1][this.regionIndex[1]]),i.push(this.region_list[2][this.regionIndex[2]]),this.chooseRegion=i,this.handleChange()},getRegions:function(){var i=this,n=e.getStorageSync("regions");n?(this.regions=n,this.setRegion()):this.$util.get("common/getRegions").then((function(n){1==n.code&&(i.regions=n.data,i.setRegion(),e.setStorageSync("regions",i.regions))}))},setRegion:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(0==e&&this.chooseRegion.length>0){for(var i=0;i<this.regions.length;i++)if(this.chooseRegion[0]==this.regions[i].name){this.regionIndex[0]=i;break}for(var n=0;n<this.regions[this.regionIndex[0]].children.length;n++)if(this.chooseRegion[1]==this.regions[this.regionIndex[0]].children[n].name){this.regionIndex[1]=n;break}for(var t=0;t<this.regions[this.regionIndex[0]].children[this.regionIndex[1]].children.length;t++)if(this.chooseRegion[2]==this.regions[this.regionIndex[0]].children[this.regionIndex[1]].children[t].name){this.regionIndex[2]=t;break}this.$forceUpdate()}this.region_list[0]=[];for(var o=0;o<this.regions.length;o++)this.region_list[0].push(this.regions[o].name);this.region_list[1]=[];for(var r=0;r<this.regions[this.regionIndex[0]].children.length;r++)this.region_list[1].push(this.regions[this.regionIndex[0]].children[r].name);this.region_list[2]=[];for(var s=0;s<this.regions[this.regionIndex[0]].children[this.regionIndex[1]].children.length;s++)this.region_list[2].push(this.regions[this.regionIndex[0]].children[this.regionIndex[1]].children[s].name)},handleChange:function(){this.$emit("input",JSON.parse(JSON.stringify(this.chooseRegion)))}}};i.default=n}).call(this,n("df3c")["default"])},c213:function(e,i,n){},de19:function(e,i,n){"use strict";n.d(i,"b",(function(){return t})),n.d(i,"c",(function(){return o})),n.d(i,"a",(function(){}));var t=function(){var e=this.$createElement,i=(this._self._c,this.chooseRegion.filter((function(e){return e})).join("-")||"请选择地区");this.$mp.data=Object.assign({},{$root:{g0:i}})},o=[]},e6da:function(e,i,n){"use strict";var t=n("c213"),o=n.n(t);o.a},fb1c:function(e,i,n){"use strict";n.r(i);var t=n("de19"),o=n("4fe5");for(var r in o)["default"].indexOf(r)<0&&function(e){n.d(i,e,(function(){return o[e]}))}(r);n("e6da");var s=n("828b"),h=Object(s["a"])(o["default"],t["b"],t["c"],!1,null,"4c63aa48",null,!1,t["a"],void 0);i["default"]=h.exports}}]);
;(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
    'components/form/FormRegionItem-create-component',
    {
        'components/form/FormRegionItem-create-component':(function(module, exports, __webpack_require__){
            __webpack_require__('df3c')['createComponent'](__webpack_require__("fb1c"))
        })
    },
    [['components/form/FormRegionItem-create-component']]
]);
