pages-analysis-condition.1a81a30a.js
12.7 KB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-analysis-condition"],{2205:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i={data:function(){return{navheight:0}},created:function(){var t=this;uni.getStorage({key:"statusBarH",success:function(e){e.data&&(t.navheight=e.data)}})},props:{leftText:{type:String,default:""},rightText:{type:String,default:""},leftImgSrc:{type:String,default:""},rightImgSrc:{type:String,default:""},title:{type:String,default:""}},methods:{rClick:function(){this.$emit("rightClick")},lClick:function(){this.$emit("leftClick")}}};e.default=i},"2a34":function(t,e,a){"use strict";var i=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",[a("div",{style:{height:t.navheight+"px",background:"#0069FF"}}),a("v-uni-view",{staticClass:"indexNav"},[a("v-uni-text",{staticClass:"left",on:{click:function(e){e=t.$handleEvent(e),t.lClick(e)}}},[t._v(t._s(t.leftText))]),a("v-uni-image",{staticClass:"lImg",attrs:{src:t.leftImgSrc},on:{click:function(e){e=t.$handleEvent(e),t.lClick(e)}}}),t._v(t._s(t.title)),a("span",{staticClass:"right",on:{click:function(e){e=t.$handleEvent(e),t.rClick(e)}}},[t._v(t._s(t.rightText))]),a("v-uni-image",{staticClass:"rImg",attrs:{src:t.rightImgSrc},on:{click:function(e){e=t.$handleEvent(e),t.rClick(e)}}})],1),a("v-uni-view",{staticClass:"blanks"})],1)},n=[];a.d(e,"a",function(){return i}),a.d(e,"b",function(){return n})},3600:function(t,e,a){var i=a("b813");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=a("4f06").default;n("7460085d",i,!0,{sourceMap:!1,shadowMode:!1})},4407:function(t,e,a){"use strict";a.r(e);var i=a("2205"),n=a.n(i);for(var r in i)"default"!==r&&function(t){a.d(e,t,function(){return i[t]})}(r);e["default"]=n.a},5745:function(t,e,a){"use strict";var i=a("3600"),n=a.n(i);n.a},"6b2d":function(t,e,a){"use strict";var i=a("8423"),n=a.n(i);n.a},"770d":function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=r(a("d448")),n=r(a("ce42"));function r(t){return t&&t.__esModule?t:{default:t}}var s={data:function(){return{leftImg:i.default,rightText:"保存",navheight:0,activeType:"store",picker:{textTitle:"选择",textConfirm:"确定",textCancel:"取消",colorConfirm:"#ffffff",colorCancel:"#ffffff"},currentDateType:"day",yearData:[],monthData:[],weekData:[],dayData:[],dateData:[],currentDate:[],currentMonth:[],currentWeek:[],currentYear:[],currentDay:[],date:"",dateText:"",accountText:""}},created:function(){var t=this;uni.getStorage({key:"statusBarH",success:function(e){e.data&&(t.navheight=e.data)}}),uni.getStorage({key:"selectAccountNameArr",success:function(e){t.accountText=JSON.parse(e.data)[0]},complete:function(t){}}),this.accountText||uni.getStorage({key:"accountList",success:function(e){if(e.data){var a=JSON.parse(e.data);a.forEach(function(e,a){0==a&&(t.accountText=e.name)})}}}),this.getDateData()},computed:{i18n:function(){return this.$t("index")}},components:{headerComp:n.default},methods:{backFun:function(){uni.navigateBack({delta:1})},save:function(){uni.navigateTo({url:"staticReport"})},goStoreList:function(){uni.navigateTo({url:"../list/moreMallList?url=../analysis/condition",animationType:"slide-in-right",animationDuration:200})},itemClick:function(t){this.activeType=t},dateShow:function(){this.$refs.picker.show()},dateClick:function(t){switch(this.currentDateType=t,t){case"day":this.dateData=this.dayData,console.log("currentDay",this.currentDay),this.currentDate=this.currentDay;break;case"week":this.dateData=this.weekData,this.currentDate=this.currentWeek;break;case"month":this.dateData=this.monthData,this.currentDate=this.currentMonth;break;case"year":this.dateData=this.yearData,this.currentDate=this.currentYear;break}},getDateData:function(){var t=this;uni.getStorage({key:"dayData",success:function(e){e.data&&(t.dayData=JSON.parse(e.data))}}),uni.getStorage({key:"weekData",success:function(e){e.data&&(t.weekData=JSON.parse(e.data))}}),uni.getStorage({key:"monthData",success:function(e){e.data&&(t.monthData=JSON.parse(e.data))}}),uni.getStorage({key:"yearData",success:function(e){e.data&&(t.yearData=JSON.parse(e.data))}}),uni.getStorage({key:"currentDay",success:function(e){e.data&&(t.currentDay=JSON.parse(e.data))}}),uni.getStorage({key:"currentWeek",success:function(e){e.data&&(t.currentWeek=JSON.parse(e.data))}}),uni.getStorage({key:"currentMonth",success:function(e){e.data&&(t.currentMonth=JSON.parse(e.data))}}),uni.getStorage({key:"currentYear",success:function(e){e.data&&(t.currentYear=JSON.parse(e.data))}}),this.dateData=JSON.parse(JSON.stringify(this.dayData)),this.currentDate=this.currentDay;var e=new Date,a=e.getFullYear(),i=e.getMonth(),n=i+1>9?i+1:"0"+(i+1),r=e.getDate(),s=r>9?r:"0"+r;this.dateText=a+"-"+n+"-"+s,uni.getStorage({key:"selectDate",success:function(e){-1!=e.data.indexOf(",")?t.dateText=e.data.split(",")[0]+"至"+e.data.split(",")[1]:t.dateText=e.data},complete:function(t){}})},dateConfirm:function(t){"day"==this.currentDateType?this.handleDayConfirm(t):"week"==this.currentDateType?this.handleWeekConfirm(t):"month"==this.currentDateType?this.handleMonthConfirm(t):"year"==this.currentDateType&&this.handleYearConfirm(t)},handleDayConfirm:function(t){var e=1999+t[0].index,a=t[1].index+1,i=t[2].index+1;a=a>9?a:"0"+a,i=i>9?i:"0"+i,this.date=e+"-"+a+"-"+i,this.dateText=this.date,uni.setStorage({key:"selectDate",data:this.date}),uni.setStorage({key:"currentDay",data:JSON.stringify(t)}),console.log(t)},handleWeekConfirm:function(t){var e=1999+t[0].index,a=t[1].index+1;a=a>9?a:"0"+a;var i=new Date;i.setFullYear(e,a-1,1);var n=i.getDay();i.setFullYear(e,a,0);var r,s=i.getDate();r=7-n+1;var c="",o="";if(0==t[2].index){c=e+"-"+a+"-01";var d=r>9?r:"0"+r;o=e+"-"+a+"-"+d}else{var l=r+7*(t[2].index-1)+1;d=r+7*t[2].index;if(l>s){for(var u=t[2].index-1;u>=0;u--)if(l=r+7*(u-1),d=r+7*u,l<=s){d>s&&(d=s);break}}else l<=s&&d>s&&(d=s);l=l>9?l:"0"+l,d=d>9?d:"0"+d,c=e+"-"+a+"-"+l,o=e+"-"+a+"-"+d}this.date=c+","+o,this.dateText=c+"至"+o,uni.setStorage({key:"selectDate",data:this.date}),uni.setStorage({key:"currentWeek",data:JSON.stringify(t)})},handleMonthConfirm:function(t){var e=1999+t[0].index,a=t[1].index+1,i=(new Date).getFullYear(),n=(new Date).getMonth()+1,r="",s="";if(e==i&&a==n){a=a>9?a:"0"+a,r=e+"-"+a+"-01";var c=(new Date).getDate();c=c>9?c:"0"+c,s=e+"-"+a+"-"+c}else{a=a>9?a:"0"+a,r=e+"-"+a+"-01";c=new Date(e,a,0).getDate();c=c>9?c:"0"+c,s=e+"-"+a+"-"+c}this.date=r+","+s,this.dateText=r+"至"+s,uni.setStorage({key:"selectDate",data:this.date}),uni.setStorage({key:"currentWeek",data:JSON.stringify(t)})},handleYearConfirm:function(t){var e="",a="",i=1999+t[0].index;e=i+"-01-01",a=i+"-12-31",this.date=e+","+a,this.dateText=e+"至"+a,uni.setStorage({key:"selectDate",data:this.date}),uni.setStorage({key:"currentWeek",data:JSON.stringify(t)})}}};e.default=s},8423:function(t,e,a){var i=a("ce36");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=a("4f06").default;n("585722e4",i,!0,{sourceMap:!1,shadowMode:!1})},b813:function(t,e,a){e=t.exports=a("2350")(!1),e.push([t.i,".indexNav[data-v-39e8dde9]{height:%?77.89?%;line-height:%?77.89?%;text-align:center;background:#0069ff;position:fixed;font-size:%?33?%;color:#fff;width:100%;z-index:9}.blanks[data-v-39e8dde9]{height:%?77.89?%}.left[data-v-39e8dde9]{float:left;font-size:%?25.36?%;display:inline-block;height:%?77.89?%;line-height:%?77.89?%;padding-left:%?23.55?%}.right[data-v-39e8dde9]{float:right;font-size:%?25.36?%;display:inline-block;height:%?77.89?%;line-height:%?77.89?%;padding-right:%?23.55?%}.lImg[data-v-39e8dde9]{width:%?12.68?%;height:%?23.55?%;float:left;position:relative;top:%?27.17?%}.rImg[data-v-39e8dde9]{width:%?28.98?%;height:%?28.98?%;float:right;position:relative;top:%?27.17?%}",""])},c560:function(t,e,a){"use strict";var i=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticStyle:{position:"relative"}},[a("headerComp",{attrs:{leftImgSrc:t.leftImg,rightText:t.rightText},on:{leftClick:function(e){e=t.$handleEvent(e),t.backFun(e)},rightClick:function(e){e=t.$handleEvent(e),t.save(e)}}}),a("div",{staticClass:"headFlex",style:{top:t.navheight+"px"}},[a("div",{staticClass:"headItems",class:{activeItem:"store"==t.activeType},on:{click:function(e){e=t.$handleEvent(e),t.itemClick("store")}}},[t._v(t._s(t.i18n.store))]),a("div",{staticClass:"headItems",class:{activeItem:"gate"==t.activeType},on:{click:function(e){e=t.$handleEvent(e),t.itemClick("gate")}}},[t._v("出入口")])]),a("div",{directives:[{name:"show",rawName:"v-show",value:"store"==t.activeType,expression:"activeType=='store'"}],staticClass:"handleContent"},[a("div",{staticClass:"conditionItem",on:{click:function(e){e=t.$handleEvent(e),t.goStoreList(e)}}},[a("span",{staticClass:"cTitle"},[t._v(t._s(t.i18n.store))]),a("span",{staticClass:"selectItem"},[t._v(t._s(t.accountText))]),a("v-uni-image",{staticClass:"rArrow",attrs:{src:"../../static/analysis/rArrow.png",mode:"widthFix"}})],1),a("div",{staticClass:"conditionItem",on:{click:function(e){e=t.$handleEvent(e),t.dateShow(e)}}},[a("span",{staticClass:"cTitle"},[t._v("日期")]),a("span",{staticClass:"selectItem"},[t._v(t._s(t.dateText))]),a("v-uni-image",{staticClass:"rArrow",attrs:{src:"../../static/analysis/rArrow.png",mode:"widthFix"}})],1)]),a("div",{directives:[{name:"show",rawName:"v-show",value:"zone"==t.activeType,expression:"activeType=='zone'"}],staticClass:"handleContent"},[t._v("22")]),a("div",{directives:[{name:"show",rawName:"v-show",value:"floor"==t.activeType,expression:"activeType=='floor'"}],staticClass:"handleContent"},[t._v("11")]),a("div",{directives:[{name:"show",rawName:"v-show",value:"area"==t.activeType,expression:"activeType=='area'"}],staticClass:"handleContent"},[t._v("22")]),a("awesome-picker",{ref:"picker",attrs:{data:t.dateData,textConfirm:t.picker.textConfirm,colorConfirm:t.picker.colorConfirm,textCancel:t.picker.textCancel,colorCancel:t.picker.colorCancel,anchor:t.currentDate},on:{confirm:function(e){e=t.$handleEvent(e),t.dateConfirm(e)}}},[a("div",{staticClass:"typeBox"},[a("span",{class:{activeDateType:"day"==t.currentDateType},on:{click:function(e){e=t.$handleEvent(e),t.dateClick("day")}}},[t._v("日")]),a("span",{class:{activeDateType:"week"==t.currentDateType},on:{click:function(e){e=t.$handleEvent(e),t.dateClick("week")}}},[t._v("周")]),a("span",{class:{activeDateType:"month"==t.currentDateType},on:{click:function(e){e=t.$handleEvent(e),t.dateClick("month")}}},[t._v("月")]),a("span",{class:{activeDateType:"year"==t.currentDateType},on:{click:function(e){e=t.$handleEvent(e),t.dateClick("year")}}},[t._v("年")])])])],1)},n=[];a.d(e,"a",function(){return i}),a.d(e,"b",function(){return n})},ce36:function(t,e,a){e=t.exports=a("2350")(!1),e.push([t.i,".headFlex[data-v-26b4f676]{width:%?543.47?%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;font-size:%?32.6?%;color:#80b4ff;position:absolute;top:0;left:0;z-index:10;height:%?77.89?%;line-height:%?77.89?%;right:0;margin:auto}.headItems[data-v-26b4f676]{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;text-align:center;cursor:pointer}.activeItem[data-v-26b4f676]{color:#fff}.conditionItem[data-v-26b4f676]{height:%?90.57?%;line-height:%?90.57?%;background:#fff;border-bottom:1px solid #979797;position:relative}.cTitle[data-v-26b4f676]{font-size:%?25.36?%;color:#333;position:absolute;top:0;left:%?23.55?%}.selectItem[data-v-26b4f676]{font-size:%?25.36?%;color:#9b9b9b;position:absolute;top:0;right:%?45.28?%}.rArrow[data-v-26b4f676]{width:%?10.86?%;height:%?19.92?%;position:absolute;top:%?38.04?%;right:%?23.55?%}",""])},ce42:function(t,e,a){"use strict";a.r(e);var i=a("2a34"),n=a("4407");for(var r in n)"default"!==r&&function(t){a.d(e,t,function(){return n[t]})}(r);a("5745");var s=a("2877"),c=Object(s["a"])(n["default"],i["a"],i["b"],!1,null,"39e8dde9",null);e["default"]=c.exports},d448:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAaCAYAAAHwCF3KAAAABGdBTUEAALGPC/xhBQAAANtJREFUOBHtVDsOwjAMDTvXoUdiZWBB4lIcgp25B2DvxmjeM7HlBEeCAQkkLLV23nt2nE9byosmInPBa1E9AvHEfuCS2SUxaOSR0Bis53twcxnoNZ4jgRVfBOB2jNUIKGOAeRCPggbQE3wiUrCqOTtNO4iVPAb5nmjU7YSSWy9rAcpPbAC2MUw9gA8QbKI1nRpztWgdgTxTkJIEv0hwHTbZE2iaW8ubQsvvdUyCKCYwsT2sKGb8Gwn5mSdrOWE9ZuMvpU+sG8GvRy9RrfAvILJPfxLZBtomwh/wXO6bsa0ZxbdJWQAAAABJRU5ErkJggg=="},e0ac:function(t,e,a){"use strict";a.r(e);var i=a("c560"),n=a("f08d");for(var r in n)"default"!==r&&function(t){a.d(e,t,function(){return n[t]})}(r);a("6b2d");var s=a("2877"),c=Object(s["a"])(n["default"],i["a"],i["b"],!1,null,"26b4f676",null);e["default"]=c.exports},f08d:function(t,e,a){"use strict";a.r(e);var i=a("770d"),n=a.n(i);for(var r in i)"default"!==r&&function(t){a.d(e,t,function(){return i[t]})}(r);e["default"]=n.a}}]);