1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-3c03f66e"],{"0f36":function(t,e,o){t.exports=o.p+"static/img/hor_big_bg.d716cdc0.png"},1148:function(t,e,o){"use strict";var r=o("a691"),a=o("577e"),n=o("1d80");t.exports=function(t){var e=a(n(this)),o="",i=r(t);if(i<0||i==1/0)throw RangeError("Wrong number of repetitions");for(;i>0;(i>>>=1)&&(e+=e))1&i&&(o+=e);return o}},"3eec":function(t,e,o){t.exports=o.p+"static/img/jiaquan.c034aaff.png"},4038:function(t,e,o){t.exports=o.p+"static/img/wendu.867faec9.png"},"408a":function(t,e,o){var r=o("c6b6");t.exports=function(t){if("number"!=typeof t&&"Number"!=r(t))throw TypeError("Incorrect invocation");return+t}},4098:function(t,e,o){"use strict";o.r(e);var r=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"horTwo"},[o("div",{staticClass:"bg"},[o("img",{attrs:{src:t.bgImg,alt:""}})]),o("div",{staticClass:"container"},[o("div",{staticClass:"hor-head"},[o("pageHead")],1),o("div",[o("HorFloorSpace")],1)])])},a=[],n=o("2b0e"),i=o("3cda"),c=o("5311"),s=o("0f36"),l=n["default"].extend({components:{pageHead:i["a"],HorFloorSpace:c["a"]},data:function(){return{bgImg:s}}}),u=l,d=(o("d47a"),o("2877")),f=Object(d["a"])(u,r,a,!1,null,"05c30178",null);e["default"]=f.exports},"4a22":function(t,e,o){t.exports=o.p+"static/img/co2.d1e1e870.png"},5311:function(t,e,o){"use strict";var r=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"floorSpace"},[o("div",{staticClass:"leftChange"},[o("div",{staticClass:"allIndicator"},t._l(t.allIndicator,(function(e,r){return o("div",{staticClass:"eachItem ",class:{select:e.id==t.selIndicator.id},on:{click:function(e){return t.clickIndicator(r)}}},[o("div",{staticClass:"title"},[t._v(t._s(e.name))]),o("div",{directives:[{name:"show",rawName:"v-show",value:e.id==t.selIndicator.id,expression:"item.id==selIndicator.id"}],staticClass:"textCont"},[t._v(t._s(t.totalAvgValues)+t._s(t.selIndicator.unit)),o("br"),o("span",{staticClass:"name"},[t._v("平均"+t._s(t.selIndicator.name))])]),o("img",{directives:[{name:"show",rawName:"v-show",value:e.id==t.selIndicator.id,expression:"item.id==selIndicator.id"}],staticClass:"img",attrs:{src:t.selIndicator.img}})])})),0)]),o("div",{staticClass:"floorWrap"},t._l(t.showFloors,(function(e,r){return o("div",{key:r,staticClass:"floor-item"},[o("div",{staticClass:"floor-num"},[o("span",[t._v(t._s(e.localName))])]),o("div",{staticClass:"floor-space"},t._l(e.dataSpaces,(function(r,a){return o("div",{key:a,staticClass:"space-box",style:{width:e.spacewidth+"%"}},[o("div",{staticClass:"space-name",style:{backgroundColor:t.selectColor(r.avgValues,t.selIndicatorId,!0)}},[t._v(t._s(r.localName))])])})),0)])})),0)])},a=[],n=(o("a9e3"),o("4de4"),o("fb6a"),o("d81d"),o("99af"),o("b680"),o("c7cd"),o("159b"),o("b0c0"),o("c1df")),i=o.n(n),c=o("5e54"),s={name:"FloorSpace",data:function(){return{selIndicator:{},selIndicatorId:"",nowIndicatorIndex:null,allIndicator:[{id:"temp",code:"Tdb",name:"温度",img:o("4038"),unit:"℃",fixed:1},{id:"humidity",code:"RH",name:"湿度",img:o("d7c9"),unit:"%",fixed:0},{id:"co2",code:"CO2",name:"CO₂",img:o("4a22"),unit:"ppm",fixed:0},{id:"methanal",code:"HCHO",name:"甲醛",img:o("3eec"),unit:"mg/m³",fixed:2},{id:"pm25",code:"PM2d5",name:"PM2.5",img:o("b9dd"),unit:"ug/m³",fixed:0}],allFloor:[],firstPageParams:[],secondPageParams:[],nowPage:1,pageNum:0,showFloors:[],totalAvgValues:null}},props:{showPing:{type:Number,default:function(){return 0}}},watch:{showPing:function(t,e){2==t&&(this.nowPage=1,this.queryFs())}},mounted:function(){},destroyed:function(){console.log("horfloorspace---destroyed")},methods:{selectColor:c["a"],clickIndicator:function(t){this.nowIndicatorIndex=t},getTimeFloorParam:function(){var t=this,e=1==this.nowPage?this.firstPageParams:this.secondPageParams,o=this;this.queryParam(e).then((function(){setTimeout((function(){if(o.nowIndicatorIndex=o.nowIndicatorIndex+1,5==o.nowIndicatorIndex){if(o.pageNum==o.nowPage)return o.nowIndicatorIndex=0,void o.$emit("donetowpage");2==o.pageNum&&1==o.nowPage&&(o.nowPage=2,o.nowIndicatorIndex=0)}t.getTimeFloorParam()}),2e3)}))},queryFs:function(){var t=this;this.$axios.post(this.$api.queryFs,{criteria:{projectId:"Pj1101020002"},size:14,page:1,orders:[{column:"floorSequenceId",asc:!0}]}).then((function(e){var o=e.data.content||[];o=o.filter((function(t){return t.spaceNum>0})),t.allFloor=o;var r,a,n=o.length;n<=7?(r=n,a=0,t.pageNum=1):(r=Math.ceil(n/2),a=Math.floor(n/2),t.pageNum=2);var i=t.floorHandle(r),c=t.floorHandle(a),s=o.slice(0,r),l=o.slice(r);t.firstPageParams=s.map((function(t){var e={};return e.id=t.id,e.projectId="Pj1101020002",e.spaceNum=i,e})),t.secondPageParams=l.map((function(t){var e={};return e.id=t.id,e.projectId="Pj1101020002",e.spaceNum=c,e})),t.nowIndicatorIndex=0,t.getTimeFloorParam()})).catch((function(t){}))},queryParam:function(t){var e=this,o=i()(),r=i()().subtract(30,"minutes"),a=r.format("YYYYMMDDHHmmss"),n=o.format("YYYYMMDDHHmmss"),c=this.nowIndicatorIndex;this.selIndicator=this.allIndicator[c];var s=this.selIndicator.code;return this.$axios.post("".concat(this.$api.queryParam,"?endTime=").concat(n,"&startTime=").concat(a,"¶m=").concat(s),t).then((function(t){var o=t.data.data.floors||[];e.totalAvgValues=t.data.data.avgValues||null,e.totalAvgValues&&(e.totalAvgValues=e.totalAvgValues.toFixed(e.selIndicator.fixed)),o.forEach((function(t){var r=e.allFloor.filter((function(e){return e.id==t.id})),a=r[0]||{};t.name=a.name,t.localId=a.localId,t.localName=a.localName;var n=t.dataSpaces.length,i=e.spaceHandle(n,o.length);t.spacewidth=100/i})),e.showFloors=o,e.selIndicatorId=e.selIndicator.id})).catch((function(t){}))},spaceHandle:function(t,e){var o=t;if(1==e)t>2&&t<=24?o=t/2:t>24&&t<=36?o=Math.ceil(t/3):t>36&&t<=48?o=Math.ceil(t/4):t>48&&t<=60&&(o=Math.ceil(t/5));else{var r=Math.ceil(t/16);o=Math.ceil(t/r)}return o},floorHandle:function(t){var e=1;switch(t){case 1:e=60;break;case 2:e=48;break;case 3:case 4:e=32;break;case 5:case 6:case 7:e=16;break}return e}}},l=s,u=(o("fe12"),o("2877")),d=Object(u["a"])(l,r,a,!1,null,"69661f85",null);e["a"]=d.exports},5899:function(t,e){t.exports="\t\n\v\f\r \u2028\u2029\ufeff"},"58a8":function(t,e,o){var r=o("1d80"),a=o("577e"),n=o("5899"),i="["+n+"]",c=RegExp("^"+i+i+"*"),s=RegExp(i+i+"*$"),l=function(t){return function(e){var o=a(r(e));return 1&t&&(o=o.replace(c,"")),2&t&&(o=o.replace(s,"")),o}};t.exports={start:l(1),end:l(2),trim:l(3)}},"5e54":function(t,e,o){"use strict";o.d(e,"a",(function(){return r}));o("a9e3"),o("159b"),o("b680");var r=function(t,e,o){if(null===t||void 0===t)return null;var r={temp:[{min:Number.NEGATIVE_INFINITY,max:20,color:"#52A0FF",fcolor:"#CEE3FC"},{min:20,max:22,color:"#40DDCE",fcolor:"#C4F2EE"},{min:22,max:27,color:"#7ED874",fcolor:"#D9F5D6"},{min:27,max:28,color:"#C4E34F",fcolor:"#E5F3C9"},{min:28,max:30,color:"#EE9F2B",fcolor:"#F9DFB8"},{min:30,max:Number.POSITIVE_INFINITY,color:"#F5483D",fcolor:"#FCC8C5"}],humidity:[{min:0,max:30,color:"#F5483D",fcolor:"#F9DFB8"},{min:30,max:35,color:"#EE9F2B",fcolor:"#E5F3C9"},{min:35,max:65,color:"#7ED874",fcolor:"#D9F5D6"},{min:65,max:95,color:"#40DDCE",fcolor:"#C4F2EE"},{min:95,max:Number.POSITIVE_INFINITY,color:"#52A0FF",fcolor:"#CEE3FC"}],co2:[{min:0,max:800,color:"#7ED874",fcolor:"#D9F5D6"},{min:800,max:1e3,color:"#C4E34F",fcolor:"#E5F3C9"},{min:1e3,max:2500,color:"#EE9F2B",fcolor:"#F9DFB8"},{min:2500,max:Number.POSITIVE_INFINITY,color:"#F5483D",fcolor:"#FCC8C5"}],methanal:[{min:0,max:.08,color:"#7ED874",fcolor:"#D9F5D6"},{min:.08,max:.1,color:"#C4E34F",fcolor:"#E5F3C9"},{min:.1,max:.2,color:"#EE9F2B",fcolor:"#F9DFB8"},{min:.2,max:Number.POSITIVE_INFINITY,color:"#F5483D",fcolor:"#FCC8C5"}],pm25:[{min:0,max:35,color:"#7ED874",fcolor:"#D9F5D6"},{min:35,max:75,color:"#C4E34F",fcolor:"#E5F3C9"},{min:75,max:150,color:"#EFD62E",fcolor:"#F7F0C0"},{min:150,max:250,color:"#EE9F2B",fcolor:"#F9DFB8"},{min:250,max:Number.POSITIVE_INFINITY,color:"#F5483D",fcolor:"#FCC8C5"}]},a=r[e],n=null;return a.forEach((function(e){t>e.min&&t<e.max&&(n=o?e.fcolor:e.color)})),n}},7156:function(t,e,o){var r=o("861d"),a=o("d2bb");t.exports=function(t,e,o){var n,i;return a&&"function"==typeof(n=e.constructor)&&n!==o&&r(i=n.prototype)&&i!==o.prototype&&a(t,i),t}},"7f05":function(t,e,o){},"857a":function(t,e,o){var r=o("1d80"),a=o("577e"),n=/"/g;t.exports=function(t,e,o,i){var c=a(r(t)),s="<"+e;return""!==o&&(s+=" "+o+'="'+a(i).replace(n,""")+'"'),s+">"+c+"</"+e+">"}},"99af":function(t,e,o){"use strict";var r=o("23e7"),a=o("d039"),n=o("e8b5"),i=o("861d"),c=o("7b0b"),s=o("50c4"),l=o("8418"),u=o("65f0"),d=o("1dde"),f=o("b622"),m=o("2d00"),p=f("isConcatSpreadable"),h=9007199254740991,g="Maximum allowed index exceeded",v=m>=51||!a((function(){var t=[];return t[p]=!1,t.concat()[0]!==t})),I=d("concat"),F=function(t){if(!i(t))return!1;var e=t[p];return void 0!==e?!!e:n(t)},x=!v||!I;r({target:"Array",proto:!0,forced:x},{concat:function(t){var e,o,r,a,n,i=c(this),d=u(i,0),f=0;for(e=-1,r=arguments.length;e<r;e++)if(n=-1===e?i:arguments[e],F(n)){if(a=s(n.length),f+a>h)throw TypeError(g);for(o=0;o<a;o++,f++)o in n&&l(d,f,n[o])}else{if(f>=h)throw TypeError(g);l(d,f++,n)}return d.length=f,d}})},a9e3:function(t,e,o){"use strict";var r=o("83ab"),a=o("da84"),n=o("94ca"),i=o("6eeb"),c=o("5135"),s=o("c6b6"),l=o("7156"),u=o("d9b5"),d=o("c04e"),f=o("d039"),m=o("7c73"),p=o("241c").f,h=o("06cf").f,g=o("9bf2").f,v=o("58a8").trim,I="Number",F=a[I],x=F.prototype,b=s(m(x))==I,E=function(t){if(u(t))throw TypeError("Cannot convert a Symbol value to a number");var e,o,r,a,n,i,c,s,l=d(t,"number");if("string"==typeof l&&l.length>2)if(l=v(l),e=l.charCodeAt(0),43===e||45===e){if(o=l.charCodeAt(2),88===o||120===o)return NaN}else if(48===e){switch(l.charCodeAt(1)){case 66:case 98:r=2,a=49;break;case 79:case 111:r=8,a=55;break;default:return+l}for(n=l.slice(2),i=n.length,c=0;c<i;c++)if(s=n.charCodeAt(c),s<48||s>a)return NaN;return parseInt(n,r)}return+l};if(n(I,!F(" 0o1")||!F("0b1")||F("+0x1"))){for(var C,w=function(t){var e=arguments.length<1?0:t,o=this;return o instanceof w&&(b?f((function(){x.valueOf.call(o)})):s(o)!=I)?l(new F(E(e)),o,w):E(e)},N=r?p(F):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger,fromString,range".split(","),P=0;N.length>P;P++)c(F,C=N[P])&&!c(w,C)&&g(w,C,h(F,C));w.prototype=x,x.constructor=w,i(a,I,w)}},af03:function(t,e,o){var r=o("d039");t.exports=function(t){return r((function(){var e=""[t]('"');return e!==e.toLowerCase()||e.split('"').length>3}))}},b0c0:function(t,e,o){var r=o("83ab"),a=o("9bf2").f,n=Function.prototype,i=n.toString,c=/^\s*function ([^ (]*)/,s="name";r&&!(s in n)&&a(n,s,{configurable:!0,get:function(){try{return i.call(this).match(c)[1]}catch(t){return""}}})},b680:function(t,e,o){"use strict";var r=o("23e7"),a=o("a691"),n=o("408a"),i=o("1148"),c=o("d039"),s=1..toFixed,l=Math.floor,u=function(t,e,o){return 0===e?o:e%2===1?u(t,e-1,o*t):u(t*t,e/2,o)},d=function(t){var e=0,o=t;while(o>=4096)e+=12,o/=4096;while(o>=2)e+=1,o/=2;return e},f=function(t,e,o){var r=-1,a=o;while(++r<6)a+=e*t[r],t[r]=a%1e7,a=l(a/1e7)},m=function(t,e){var o=6,r=0;while(--o>=0)r+=t[o],t[o]=l(r/e),r=r%e*1e7},p=function(t){var e=6,o="";while(--e>=0)if(""!==o||0===e||0!==t[e]){var r=String(t[e]);o=""===o?r:o+i.call("0",7-r.length)+r}return o},h=s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!c((function(){s.call({})}));r({target:"Number",proto:!0,forced:h},{toFixed:function(t){var e,o,r,c,s=n(this),l=a(t),h=[0,0,0,0,0,0],g="",v="0";if(l<0||l>20)throw RangeError("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return String(s);if(s<0&&(g="-",s=-s),s>1e-21)if(e=d(s*u(2,69,1))-69,o=e<0?s*u(2,-e,1):s/u(2,e,1),o*=4503599627370496,e=52-e,e>0){f(h,0,o),r=l;while(r>=7)f(h,1e7,0),r-=7;f(h,u(10,r,1),0),r=e-1;while(r>=23)m(h,1<<23),r-=23;m(h,1<<r),f(h,1,1),m(h,2),v=p(h)}else f(h,0,o),f(h,1<<-e,0),v=p(h)+i.call("0",l);return l>0?(c=v.length,v=g+(c<=l?"0."+i.call("0",l-c)+v:v.slice(0,c-l)+"."+v.slice(c-l))):v=g+v,v}})},b919:function(t,e,o){},b9dd:function(t,e,o){t.exports=o.p+"static/img/pm25.0ee7d1d0.png"},c7cd:function(t,e,o){"use strict";var r=o("23e7"),a=o("857a"),n=o("af03");r({target:"String",proto:!0,forced:n("fixed")},{fixed:function(){return a(this,"tt","","")}})},d47a:function(t,e,o){"use strict";o("7f05")},d7c9:function(t,e,o){t.exports=o.p+"static/img/shidu.62e5bc4c.png"},d81d:function(t,e,o){"use strict";var r=o("23e7"),a=o("b727").map,n=o("1dde"),i=n("map");r({target:"Array",proto:!0,forced:!i},{map:function(t){return a(this,t,arguments.length>1?arguments[1]:void 0)}})},fb6a:function(t,e,o){"use strict";var r=o("23e7"),a=o("861d"),n=o("e8b5"),i=o("23cb"),c=o("50c4"),s=o("fc6a"),l=o("8418"),u=o("b622"),d=o("1dde"),f=d("slice"),m=u("species"),p=[].slice,h=Math.max;r({target:"Array",proto:!0,forced:!f},{slice:function(t,e){var o,r,u,d=s(this),f=c(d.length),g=i(t,f),v=i(void 0===e?f:e,f);if(n(d)&&(o=d.constructor,"function"!=typeof o||o!==Array&&!n(o.prototype)?a(o)&&(o=o[m],null===o&&(o=void 0)):o=void 0,o===Array||void 0===o))return p.call(d,g,v);for(r=new(void 0===o?Array:o)(h(v-g,0)),u=0;g<v;g++,u++)g in d&&l(r,u,d[g]);return r.length=u,r}})},fe12:function(t,e,o){"use strict";o("b919")}}]);
|