@ecan-bi/datav 1.2.34 → 1.2.35
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/index.es.js +249 -248
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +2 -2
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @ecan-bi/datav@1.2.
|
|
1
|
+
/*! @ecan-bi/datav@1.2.35 */
|
|
2
2
|
(function(H,a){typeof exports=="object"&&typeof module<"u"?a(exports,require("vue"),require("echarts/core"),require("resize-detector"),require("ant-design-vue"),require("ant-design-vue/es/spin/style"),require("ant-design-vue/es/skeleton/style"),require("lodash-es"),require("dayjs"),require("axios"),require("mitt"),require("ant-design-vue/es/progress/style"),require("ant-design-vue/es/input/style"),require("ant-design-vue/es/date-picker/style"),require("ant-design-vue/es/date-picker/locale/zh_CN"),require("ant-design-vue/es/button/style"),require("ant-design-vue/es/checkbox/style"),require("ant-design-vue/es/select/style"),require("ant-design-vue/es/tree-select/style"),require("echarts/renderers"),require("echarts/charts"),require("echarts/components"),require("ant-design-vue/es/modal/style"),require("echarts"),require("ant-design-vue/es/table/style"),require("ant-design-vue/es/notification/style"),require("xlsx"),require("big.js")):typeof define=="function"&&define.amd?define(["exports","vue","echarts/core","resize-detector","ant-design-vue","ant-design-vue/es/spin/style","ant-design-vue/es/skeleton/style","lodash-es","dayjs","axios","mitt","ant-design-vue/es/progress/style","ant-design-vue/es/input/style","ant-design-vue/es/date-picker/style","ant-design-vue/es/date-picker/locale/zh_CN","ant-design-vue/es/button/style","ant-design-vue/es/checkbox/style","ant-design-vue/es/select/style","ant-design-vue/es/tree-select/style","echarts/renderers","echarts/charts","echarts/components","ant-design-vue/es/modal/style","echarts","ant-design-vue/es/table/style","ant-design-vue/es/notification/style","xlsx","big.js"],a):(H=typeof globalThis<"u"?globalThis:H||self,a(H["@ecan/bi-datav"]={},H.Vue,H["echarts/core"],H.ResizeDetector,H.AntDesignVue,null,null,H.LodashEs,H.Dayjs,H.Axios,H.Mitt,null,null,null,H["ant-design-vue/es/date-picker/locale/zh_CN"],null,null,null,null,H["echarts/renderers"],H["echarts/charts"],H["echarts/components"],null,H.Echarts,null,null,H.Xlsx,H.big.js))})(this,function(H,a,Ve,ua,ne,Jf,ed,Ge,Ne,ri,ii,td,nd,od,ha,ad,rd,id,sd,ct,Ue,he,ld,si,cd,fd,Dt,li){var $0,Z0,Y0,K0;"use strict";function ci(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const fi=ci(si),di=["getWidth","getHeight","getDom","getOption","resize","dispatchAction","convertToPixel","convertFromPixel","containPixel","getDataURL","getConnectedDataURL","appendData","clear","isDisposed","dispose"];function ui(e,n){function t(r){return(...i)=>{if(e.value||n(),!e.value)throw new Error("ECharts is not initialized yet.");return e.value[r].apply(e.value,i)}}function o(){const r=Object.create(null);return di.forEach(i=>{r[i]=t(i)}),r}return o()}function hi(e,n,t){let o=null;a.watch([t,e,n],([r,i,l],s,f)=>{r&&i&&l&&(o=Ve.throttle(()=>{i.resize()},100),ua.addListener(r,o)),f(()=>{o&&r&&ua.removeListener(r,o)})})}const gi={autoresize:Boolean},mi="ecLoadingOptions";function xi(e,n,t){const o=a.inject(mi,{}),r=a.computed(()=>({...a.unref(o),...t==null?void 0:t.value}));a.watchEffect(()=>{const i=e.value;i&&(n.value?i.showLoading(r.value):i.hideLoading())})}const yi={loading:Boolean,loadingOptions:Object},dd="",pi=/^on[^a-z]/,vi=e=>pi.test(e);function bi(e){const n={};for(const t in e)vi(t)||(n[t]=e[t]);return n}const Si="x-vue-echarts",wi="ecTheme",Ci="ecInitOptions",Ai="ecUpdateOptions",Qe=a.defineComponent({name:"echarts",props:{option:Object,theme:{type:[Object,String]},initOptions:Object,updateOptions:Object,group:String,manualUpdate:Boolean,...gi,...yi},inheritAttrs:!1,setup(e,{attrs:n,listeners:t}){const o=a.shallowRef(),r=a.shallowRef(),i=a.shallowRef(),l=a.inject(wi,null),s=a.inject(Ci,null),f=a.inject(Ai,null),{autoresize:c,manualUpdate:d,loading:b,loadingOptions:u}=a.toRefs(e),h=a.computed(()=>i.value||e.option||Object.create(null)),g=a.computed(()=>e.theme||a.unref(l)||{}),m=a.computed(()=>e.initOptions||a.unref(s)||{}),S=a.computed(()=>e.updateOptions||a.unref(f)||{}),C=a.computed(()=>bi(n));function v(E){if(r.value||!o.value)return;const T=r.value=Ve.init(o.value,g.value,m.value);e.group&&(T.group=e.group);let B=t;B||(B={},Object.keys(n).filter(R=>R.indexOf("on")===0&&R.length>2).forEach(R=>{const N=R.charAt(2).toLowerCase()+R.slice(3);B[N]=n[R]})),Object.keys(B).forEach(R=>{const N=B[R];N&&(R.indexOf("zr:")===0?T.getZr().on(R.slice(3).toLowerCase(),N):T.on(R.toLowerCase(),N))});function w(){if(T&&!T.isDisposed())try{T.resize()}catch(R){if(R.message==="Cannot read property 'get' of undefined")return;throw R}}function k(){T.setOption(E||h.value,S.value)}c.value?a.nextTick(()=>{w(),k()}):k()}function x(E,T){e.manualUpdate&&(i.value=E),r.value?r.value.setOption(E,T||{}):v(E)}function p(){r.value&&(r.value.dispose(),r.value=void 0)}let A=null;a.watch(d,E=>{typeof A=="function"&&(A(),A=null),E||(A=a.watch(()=>e.option,T=>{T&&(r.value?r.value.setOption(T,S.value):v())},{deep:!0}))},{immediate:!0}),a.watch([g,m],()=>{p(),v()},{deep:!0}),a.watchEffect(()=>{e.group&&r.value&&(r.value.group=e.group)});const y=ui(r,v);return xi(r,b,u),hi(r,c,o),a.onMounted(()=>{e.option&&v()}),a.onUnmounted(p),{chart:r,root:o,setOption:x,nonEventAttrs:C,...y}},render(){const e={...this.nonEventAttrs};return e.ref="root",e.class=e.class?["echarts"].concat(e.class):"echarts",a.h(Si,e)}});function Me(e,n){ki(e)&&(e="100%");var t=Ei(e);return e=n===360?e:Math.min(n,Math.max(0,parseFloat(e))),t&&(e=parseInt(String(e*n),10)/100),Math.abs(e-n)<1e-6?1:(n===360?e=(e<0?e%n+n:e%n)/parseFloat(String(n)):e=e%n/parseFloat(String(n)),e)}function ki(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function Ei(e){return typeof e=="string"&&e.indexOf("%")!==-1}function Ti(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function Mt(e){return e<=1?"".concat(Number(e)*100,"%"):e}function nn(e){return e.length===1?"0"+e:String(e)}function Bi(e,n,t){return{r:Me(e,255)*255,g:Me(n,255)*255,b:Me(t,255)*255}}function on(e,n,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?e+(n-e)*(6*t):t<1/2?n:t<2/3?e+(n-e)*(2/3-t)*6:e}function _i(e,n,t){var o,r,i;if(e=Me(e,360),n=Me(n,100),t=Me(t,100),n===0)r=t,i=t,o=t;else{var l=t<.5?t*(1+n):t+n-t*n,s=2*t-l;o=on(s,l,e+1/3),r=on(s,l,e),i=on(s,l,e-1/3)}return{r:o*255,g:r*255,b:i*255}}function Di(e,n,t){e=Me(e,255),n=Me(n,255),t=Me(t,255);var o=Math.max(e,n,t),r=Math.min(e,n,t),i=0,l=o,s=o-r,f=o===0?0:s/o;if(o===r)i=0;else{switch(o){case e:i=(n-t)/s+(n<t?6:0);break;case n:i=(t-e)/s+2;break;case t:i=(e-n)/s+4;break}i/=6}return{h:i,s:f,v:l}}function Ri(e,n,t){e=Me(e,360)*6,n=Me(n,100),t=Me(t,100);var o=Math.floor(e),r=e-o,i=t*(1-n),l=t*(1-r*n),s=t*(1-(1-r)*n),f=o%6,c=[t,l,i,i,s,t][f],d=[s,t,t,l,i,i][f],b=[i,i,s,t,t,l][f];return{r:c*255,g:d*255,b:b*255}}function Ii(e,n,t,o){var r=[nn(Math.round(e).toString(16)),nn(Math.round(n).toString(16)),nn(Math.round(t).toString(16))];return o&&r[0].startsWith(r[0].charAt(1))&&r[1].startsWith(r[1].charAt(1))&&r[2].startsWith(r[2].charAt(1))?r[0].charAt(0)+r[1].charAt(0)+r[2].charAt(0):r.join("")}function ga(e){return Ie(e)/255}function Ie(e){return parseInt(e,16)}var ma={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Rt(e){var n={r:0,g:0,b:0},t=1,o=null,r=null,i=null,l=!1,s=!1;return typeof e=="string"&&(e=Ni(e)),typeof e=="object"&&(We(e.r)&&We(e.g)&&We(e.b)?(n=Bi(e.r,e.g,e.b),l=!0,s=String(e.r).substr(-1)==="%"?"prgb":"rgb"):We(e.h)&&We(e.s)&&We(e.v)?(o=Mt(e.s),r=Mt(e.v),n=Ri(e.h,o,r),l=!0,s="hsv"):We(e.h)&&We(e.s)&&We(e.l)&&(o=Mt(e.s),i=Mt(e.l),n=_i(e.h,o,i),l=!0,s="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(t=e.a)),t=Ti(t),{ok:l,format:e.format||s,r:Math.min(255,Math.max(n.r,0)),g:Math.min(255,Math.max(n.g,0)),b:Math.min(255,Math.max(n.b,0)),a:t}}var Oi="[-\\+]?\\d+%?",Li="[-\\+]?\\d*\\.\\d+%?",Je="(?:".concat(Li,")|(?:").concat(Oi,")"),an="[\\s|\\(]+(".concat(Je,")[,|\\s]+(").concat(Je,")[,|\\s]+(").concat(Je,")\\s*\\)?"),rn="[\\s|\\(]+(".concat(Je,")[,|\\s]+(").concat(Je,")[,|\\s]+(").concat(Je,")[,|\\s]+(").concat(Je,")\\s*\\)?"),ze={CSS_UNIT:new RegExp(Je),rgb:new RegExp("rgb"+an),rgba:new RegExp("rgba"+rn),hsl:new RegExp("hsl"+an),hsla:new RegExp("hsla"+rn),hsv:new RegExp("hsv"+an),hsva:new RegExp("hsva"+rn),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function Ni(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var n=!1;if(ma[e])e=ma[e],n=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var t=ze.rgb.exec(e);return t?{r:t[1],g:t[2],b:t[3]}:(t=ze.rgba.exec(e),t?{r:t[1],g:t[2],b:t[3],a:t[4]}:(t=ze.hsl.exec(e),t?{h:t[1],s:t[2],l:t[3]}:(t=ze.hsla.exec(e),t?{h:t[1],s:t[2],l:t[3],a:t[4]}:(t=ze.hsv.exec(e),t?{h:t[1],s:t[2],v:t[3]}:(t=ze.hsva.exec(e),t?{h:t[1],s:t[2],v:t[3],a:t[4]}:(t=ze.hex8.exec(e),t?{r:Ie(t[1]),g:Ie(t[2]),b:Ie(t[3]),a:ga(t[4]),format:n?"name":"hex8"}:(t=ze.hex6.exec(e),t?{r:Ie(t[1]),g:Ie(t[2]),b:Ie(t[3]),format:n?"name":"hex"}:(t=ze.hex4.exec(e),t?{r:Ie(t[1]+t[1]),g:Ie(t[2]+t[2]),b:Ie(t[3]+t[3]),a:ga(t[4]+t[4]),format:n?"name":"hex8"}:(t=ze.hex3.exec(e),t?{r:Ie(t[1]+t[1]),g:Ie(t[2]+t[2]),b:Ie(t[3]+t[3]),format:n?"name":"hex"}:!1)))))))))}function We(e){return!!ze.CSS_UNIT.exec(String(e))}var Pt=2,xa=.16,Mi=.05,Pi=.05,zi=.15,ya=5,pa=4,Fi=[{index:7,opacity:.15},{index:6,opacity:.25},{index:5,opacity:.3},{index:5,opacity:.45},{index:5,opacity:.65},{index:5,opacity:.85},{index:4,opacity:.9},{index:3,opacity:.95},{index:2,opacity:.97},{index:1,opacity:.98}];function va(e){var n=e.r,t=e.g,o=e.b,r=Di(n,t,o);return{h:r.h*360,s:r.s,v:r.v}}function zt(e){var n=e.r,t=e.g,o=e.b;return"#".concat(Ii(n,t,o,!1))}function Hi(e,n,t){var o=t/100,r={r:(n.r-e.r)*o+e.r,g:(n.g-e.g)*o+e.g,b:(n.b-e.b)*o+e.b};return r}function ba(e,n,t){var o;return Math.round(e.h)>=60&&Math.round(e.h)<=240?o=t?Math.round(e.h)-Pt*n:Math.round(e.h)+Pt*n:o=t?Math.round(e.h)+Pt*n:Math.round(e.h)-Pt*n,o<0?o+=360:o>=360&&(o-=360),o}function Sa(e,n,t){if(e.h===0&&e.s===0)return e.s;var o;return t?o=e.s-xa*n:n===pa?o=e.s+xa:o=e.s+Mi*n,o>1&&(o=1),t&&n===ya&&o>.1&&(o=.1),o<.06&&(o=.06),Number(o.toFixed(2))}function wa(e,n,t){var o;return t?o=e.v+Pi*n:o=e.v-zi*n,o>1&&(o=1),Number(o.toFixed(2))}function sn(e){for(var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t=[],o=Rt(e),r=ya;r>0;r-=1){var i=va(o),l=zt(Rt({h:ba(i,r,!0),s:Sa(i,r,!0),v:wa(i,r,!0)}));t.push(l)}t.push(zt(o));for(var s=1;s<=pa;s+=1){var f=va(o),c=zt(Rt({h:ba(f,s),s:Sa(f,s),v:wa(f,s)}));t.push(c)}return n.theme==="dark"?Fi.map(function(d){var b=d.index,u=d.opacity,h=zt(Hi(Rt(n.backgroundColor||"#141414"),Rt(t[b]),u*100));return h}):t}var ln={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1890FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},cn={},fn={};Object.keys(ln).forEach(function(e){cn[e]=sn(ln[e]),cn[e].primary=cn[e][5],fn[e]=sn(ln[e],{theme:"dark",backgroundColor:"#141414"}),fn[e].primary=fn[e][5]});var Ca=[],It=[],qi="insert-css: You need to provide a CSS string. Usage: insertCss(cssString[, options]).";function Vi(){var e=document.createElement("style");return e.setAttribute("type","text/css"),e}function ji(e,n){if(n=n||{},e===void 0)throw new Error(qi);var t=n.prepend===!0?"prepend":"append",o=n.container!==void 0?n.container:document.querySelector("head"),r=Ca.indexOf(o);r===-1&&(r=Ca.push(o)-1,It[r]={});var i;return It[r]!==void 0&&It[r][t]!==void 0?i=It[r][t]:(i=It[r][t]=Vi(),t==="prepend"?o.insertBefore(i,o.childNodes[0]):o.appendChild(i)),e.charCodeAt(0)===65279&&(e=e.substr(1,e.length)),i.styleSheet?i.styleSheet.cssText+=e:i.textContent+=e,i}function Aa(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?Object(arguments[n]):{},o=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(o=o.concat(Object.getOwnPropertySymbols(t).filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable}))),o.forEach(function(r){Gi(e,r,t[r])})}return e}function Gi(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function Ui(e,n){process.env.NODE_ENV!=="production"&&!e&&console!==void 0&&console.error("Warning: ".concat(n))}function Wi(e,n){Ui(e,"[@ant-design/icons-vue] ".concat(n))}function ka(e){return typeof e=="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(typeof e.icon=="object"||typeof e.icon=="function")}function dn(e,n,t){return t?a.h(e.tag,Aa({key:n},t,e.attrs),(e.children||[]).map(function(o,r){return dn(o,"".concat(n,"-").concat(e.tag,"-").concat(r))})):a.h(e.tag,Aa({key:n},e.attrs),(e.children||[]).map(function(o,r){return dn(o,"".concat(n,"-").concat(e.tag,"-").concat(r))}))}function Ea(e){return sn(e)[0]}function Ta(e){return e?Array.isArray(e)?e:[e]:[]}var $i=`
|
|
3
3
|
.anticon {
|
|
4
4
|
display: inline-block;
|
|
@@ -94,7 +94,7 @@ version: 2.9.0
|
|
|
94
94
|
`,t+="-----END RSA PRIVATE KEY-----",t},n.prototype.getPublicKey=function(){var t=`-----BEGIN PUBLIC KEY-----
|
|
95
95
|
`;return t+=n.wordwrap(this.getPublicBaseKeyB64())+`
|
|
96
96
|
`,t+="-----END PUBLIC KEY-----",t},n.hasPublicKeyProperty=function(t){return t=t||{},t.hasOwnProperty("n")&&t.hasOwnProperty("e")},n.hasPrivateKeyProperty=function(t){return t=t||{},t.hasOwnProperty("n")&&t.hasOwnProperty("e")&&t.hasOwnProperty("d")&&t.hasOwnProperty("p")&&t.hasOwnProperty("q")&&t.hasOwnProperty("dmp1")&&t.hasOwnProperty("dmq1")&&t.hasOwnProperty("coeff")},n.prototype.parsePropertiesFrom=function(t){this.n=t.n,this.e=t.e,t.hasOwnProperty("d")&&(this.d=t.d,this.p=t.p,this.q=t.q,this.dmp1=t.dmp1,this.dmq1=t.dmq1,this.coeff=t.coeff)},n}(Al),io,_l=typeof process<"u"?(io=process.env)===null||io===void 0?void 0:io.npm_package_version:void 0,Dl=function(){function e(n){n===void 0&&(n={}),n=n||{},this.default_key_size=n.default_key_size?parseInt(n.default_key_size,10):1024,this.default_public_exponent=n.default_public_exponent||"010001",this.log=n.log||!1,this.key=null}return e.prototype.setKey=function(n){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new Lr(n)},e.prototype.setPrivateKey=function(n){this.setKey(n)},e.prototype.setPublicKey=function(n){this.setKey(n)},e.prototype.decrypt=function(n){try{return this.getKey().decrypt(kr(n))}catch{return!1}},e.prototype.encrypt=function(n){try{return jt(this.getKey().encrypt(n))}catch{return!1}},e.prototype.sign=function(n,t,o){try{return jt(this.getKey().sign(n,t,o))}catch{return!1}},e.prototype.verify=function(n,t,o){try{return this.getKey().verify(n,kr(t),o)}catch{return!1}},e.prototype.getKey=function(n){if(!this.key){if(this.key=new Lr,n&&{}.toString.call(n)==="[object Function]"){this.key.generateAsync(this.default_key_size,this.default_public_exponent,n);return}this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},e.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},e.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},e.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},e.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},e.version=_l,e}();const Nr=new Dl,Et=Rl();function Rl(){let n=Math.random().toString(36).substr(2);for(;n.length<16;)n+=Math.random().toString(36).substr(2);return n=n.substr(0,16),n}const Mr=Oe.enc.Utf8.parse("ABCDEF1234123412");function Il(e,n){n=n||Et;const t=Oe.enc.Utf8.parse(n);let o="";switch(typeof e){case"string":o=Oe.enc.Utf8.parse(e);break;case"object":o=Oe.enc.Utf8.parse(JSON.stringify(e));break;default:o=Oe.enc.Utf8.parse(e.toString())}return Oe.AES.encrypt(o,t,{iv:Mr,mode:Oe.mode.CBC,padding:Oe.pad.ZeroPadding}).toString()}function Pr(e,n){n=n||Et;const t=Oe.enc.Utf8.parse(n),o=Oe.AES.decrypt(e,t,{iv:Mr,mode:Oe.mode.CBC,padding:Oe.pad.ZeroPadding});return Oe.enc.Utf8.stringify(o).toString()}function Ol(e){Nr.setPublicKey(e)}function Ll(e){return Nr.encrypt(e)}function zr(e=""){e.startsWith("/")||(e="/"+e),e=e.split("?")[0];const t=["/diagram","/dataview"].map(o=>`^(.*?)${o}(/|$)`);for(const o of t)if(new RegExp(o).test(e))return!0;return!1}function Nl(e){const{paramType:n,data:t,params:o,method:r}=e;n==="form"?["get","delete"].includes(r)?e.params=Tt(o,"string"):e.data=Tt(t,"string"):["get","delete"].includes(r)?e.params=Tt(o,"string"):e.data=Tt(t)}function Tt(e,n){let t=e||{};if(n==="string"){t="";for(const s in e)if(Object.hasOwnProperty.call(e,s)){const f=e[s];t+=`${s}=${encodeURIComponent(f)}&`}}Ol("MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAMKaTbS1XHH7u/4dhao1n5Lcegpy6AHKX2TjmTP7IDW6N4wznqlL3Tt+U0/Il1TlNp1/EN+tffYYg4dPrrCUDwcCAwEAAQ==");const r=Ll(Et);return{c:Il(t,Et),p:r}}window.getEncryptParam=Tt;function Ml(e,n){var t;(t=window==null?void 0:window.config)!=null&&t.encryptFlag&&zr(e.url)&&(e.data instanceof FormData?e.data=Pl(e.data):Nl(e))}function Pl(e){const n=e.entries(),t=new FormData,o={};for(const i of n){const l=i[0],s=i[1];s instanceof Blob?t.append(l,s):o[l]=s}const r=Tt(o,"json");return typeof r=="object"&&(t.append("c",r.c),t.append("p",r.p)),t}window.xhaesKey=Et,window.xhaesDecrypt=Pr;function Fr(e,n){var t;if((t=window==null?void 0:window.config)!=null&&t.encryptFlag&&zr(e.config.url)&&!(e.data instanceof Blob)&&e.data.data!==void 0){const o=Pr(e.data.data.content,Et);e.data=JSON.parse(o)}}const Hr=window.config.requestErrorTip,ot=ri.create({timeout:1e3*180});ot.interceptors.request.use(e=>(Ml(e),e),e=>Promise.reject(e)),ot.interceptors.response.use(e=>{var n,t,o;return Hr&&+((n=e==null?void 0:e.data)==null?void 0:n.code)==500&&ne.message.error({content:((t=e==null?void 0:e.data)==null?void 0:t.msg)||((o=e==null?void 0:e.data)==null?void 0:o.message)||"服务器异常",key:"SERVER_ERROR"}),Fr(e),e},e=>{if(Fr(e==null?void 0:e.response),Hr)if(e.message.includes("timeout"))ne.message.error({content:"网络连接超时,请重试!",key:"TIMEOUT"});else{const{status:n}=(e==null?void 0:e.response)||{};n>=400&&n<500&&ne.message.error({content:"请求异常",key:"REQUEST_ERROR"}),n>=500&&ne.message.error({content:"服务器异常",key:"REQUEST_ERROR"})}return Promise.reject(e)});const zl=e=>e.replace(/\\n/g,`
|
|
97
|
-
`),so=(e,n=2)=>{const t=parseFloat(e+"");return isNaN(t)?e:t.toFixed(n).replace(/(\d)(?=(\d{3})+\.)/g,"$1,")},Fl=e=>{const n=parseFloat(e+"");return isNaN(n)?e:(n+"").replace(/\B(?=(\d{3})+(?!\d))/g,",")},Xt=(e,n=2)=>{const t=e+"";if(t.includes("%"))return e;const o=parseFloat(t);return isNaN(o)?e:`${(o*100).toFixed(n)}%`},Qt=(e,n)=>{if(typeof e=="string"&&typeof n=="string")return e.toLocaleLowerCase().includes(n.toLocaleLowerCase());if(typeof e=="string"&&Array.isArray(n)){const t=n.length;for(let o=0;o<t;o++){const r=n[o];if(typeof r=="string"&&e.toLocaleLowerCase().includes(r.toLocaleLowerCase()))return!0}}return!1},Jt=(e,n)=>{const t={dayjs:Ne,...n};let o="";const r=[];for(const s in t)o+=`${s},`,r.push(t[s]);o=o.replace(/,$/,"");const i=`function (${o}){return ${e}}`;let l;try{l=Function(`"use strict";return (${i})`)()(...r)}catch{return e}return l},be=(e="",{textData:n,codeData:t}={},{useNewline:o=!1,useSpace:r=!1}={})=>{const l={...window.config||{},...n},s=e.match(/\{(.+?)\}/g);if(s==null||s.length===0)return e;for(let f=0;f<s.length;f++){const c=s[f];let d=c.slice(1,-1).trim();const b=/[\u4e00-\u9fa5a-z-_A-Z0-9]*/g,u=d.match(b);for(let h=0;h<u.length;h++){const g=u[h],m=l[g];m!=null&&(d=d.replace(g,m))}(/\(.*\)/g.test(d)||/[+/\\*]/g.test(d))&&(d=Jt(d,t)),e=e.replace(c,d)}return o&&(e=e==null?void 0:e.replace(/\n|\\n/g,"<br/>")),r&&(e=e==null?void 0:e.replace(/\s{2,}?/g," ")),e},Re=(e,n=()=>{})=>{const{requestUrl:t,requestMethod:o,requestHeaders:r,requestParams:i,requestInterval:l,isOpenRequestTimer:s}=e,{contextRequestUrl:f,touchEventId:c}=a.inject(Ae,{contextRequestUrl:"",touchEventId:""}),{getGlobalModel:d}=a.inject(we,{getGlobalModel:g=>{}}),b=be(t),u=async(g={})=>{if(!b||!o||!r)return;let m={};i.forEach(p=>{const{key:A,value:y}=p;if(typeof y=="object"&&y!=null&&y.id){let E={};const{id:T,prop:B,propKey:w,operate:k}=y;T==="THIS"?E=d(a.unref(c))||{}:E=d(T)||{};const R=a.unref(E[B]);let N=null;if(["date","range"].some(D=>Qt(E==null?void 0:E.type,D))){const{value:D,type:P,mode:V}=k||{};if(D&&P&&V)switch(P){case"add":N=a.unref(R).add(D,V);break;case"minus":N=a.unref(R).subtract(D,V);break}N==null&&(N=a.unref(R)),N=(N==null?void 0:N.format((w==null?void 0:w.trim())||E.format))||""}else Object.prototype.toString.call(R)==="[object Object]"?w?N=R[w]:N=B?R[B]:R:Qt(E==null?void 0:E.type,"select")&&a.unref(R)&&B&&Array.isArray(a.unref(R))?N=a.unref(R).map(D=>Object.prototype.hasOwnProperty.call(D,B)?D[B]:D):N=R;m[A]=N}else typeof y=="string"&&(m[A]=be(y))}),m={...window.config.requestParams,...g,...m};let S="";const C=Object.keys(m),v=C.length-1,x=C.length;C.forEach((p,A)=>{let y=m[p];Object.prototype.toString.call(y)==="[object Object]"&&(y=JSON.stringify(y)),A===0?x!==1?S+=`?${p}=${y}&`:S+=`?${p}=${y}`:A===v?S+=`${p}=${y}`:S+=`${p}=${y}&`});try{const p=["get","head"].includes(o);let A=p?b+S:b;m.dataSqlId&&!A.includes("dataSqlId")&&(A+=`${A.includes("?")?"&":"?"}dataSqlId=${m.dataSqlId}`);const y=await ot({baseURL:a.unref(f)||"",url:A,method:o,headers:r,data:p?{}:m});return n(y),y}catch(p){console.error(p)}},h=s&&setInterval(u,l*1e3);return a.onUnmounted(()=>{clearInterval(h)}),u},at=(e=[],n)=>{let{name:t="name",types:o=[]}=n||{};t=(t==null?void 0:t.trim())||t;const r=new Set,i=new Map,l=e.length,s=o.length;if(l===1){const d=[];for(let u=0;u<s;u++){const h=o[u],{label:g,value:m}=h,S={...e[0],value:e[0][m]};r.add(g),d.push(S)}const b=e[0][t]||"";i.set(b,d)}else for(let d=0;d<l;d++){const b=e[d],u=b[t];r.add(u);for(let h=0;h<s;h++){const g=o[h],{label:m,value:S}=g,C={...b,value:b[S]};if(i.has(m)){const v=i.get(m);v.push(C),i.set(m,v)}else i.set(m,[C])}}const f=Array.from(r),c=[];for(const[d,b]of i)c.push({name:d,data:b});return{dimensions:f,dataset:c}},ht=(e,n=!1)=>{var o;if(!e)return e;let t="";return e!=null&&e.includes("://")?t=e:t=((o=window==null?void 0:window.config)==null?void 0:o.uploadPath)+e,n&&(t=`url(${t})`),t},qr=(e,n)=>{const t=`${za}/preview?pageId=${n}`,o=`${za}/${n}`;return e==="preview"?t:o},gt=(e,n)=>{var r;if(e==null)return n;const t=e.match(/\{.*\}/g);if(t==null||t.length===0)return n;const o=t.length;for(let i=0;i<o;i++){const l=t[i];if(l==null||l==="")break;let s=(r=l.slice(1,-1))==null?void 0:r.trim();s=s==null?void 0:s.replace(/value/g,n);try{let f=s;(/\(.*\)/g.test(s)||/[+/\\*]/g.test(s))&&(f=Jt(s)),e=e.replace(l,f)}catch{e=e.replace(l,s)}}return e},He=(e={})=>{const{requestToken:n}=a.inject(Ma,{requestToken:()=>{}});e.dataType==="indicator"&&n();const t=(l={})=>{const{label:s,name:f,location:c,show:d,indexCode:b}=l;return{label:s,columnName:f,location:c,show:d,calcType:"COLUMN",hrpIndexCode:b}},o=(l={})=>{const{label:s,name:f,location:c,show:d,indexCode:b,calcType:u="COLUMN",builtInFormula:h,builtInValueSource:g,builtInCalcWay:m,formula:S,conditions:C}=l;return{label:s,columnName:f,location:c,show:d,calcType:u,hrpIndexCode:b,aggregate:"SUM",builtInFormula:h,builtInValueSource:g,builtInCalcWay:m,formula:S,conditions:C}},{getGlobalModel:r}=a.inject(we,{getGlobalModel:l=>{}}),i=(l=[])=>{var c;const s=l.length;console.log("controlList",l);const f=[];for(let d=0;d<s;d++){const b=l[d],{id:u,conditionLabel:h,conditionKey:g,conditionValueType:m}=b,S={rule:"NONE",label:h,fieldName:g,fieldValue:"",valueType:m},C=r(u)||{};console.log("model",C);const{value:v,format:x="YYYY-MM-DD"}=C||{};Qt(C.type,"date")?(S.fieldValue=(c=a.unref(v))==null?void 0:c.format(x),S.dateFormat=x):S.fieldValue=a.unref(v),f.push(S)}return f};return async()=>{var R,N;const{graphicConfig:l,type:s}=e;let{source:f,dataViewId:c,plugin:d="1",layer:b,chartType:u,classificationList:h=[],seriesList:g=[],leftAxisList:m=[],rightAxisList:S=[],queryColumnList:C=[],indicators:v=[],controlList:x=[],dataSourceId:p,idxLibMode:A,preview:y=!1}=l||{};b==null&&(Qt(s,["table","text","proportion","select","checkbox","radio"])?b="1":b="2");let E;if(Array.isArray(h)&&h.length>0){const F=h.length;for(let D=0;D<F;D++){const P=h[D]||{},{label:V="",name:I="",show:L=!1,sort:M,customGroup:_,conditions:O}=P;if(L||F===1){E={label:V,columnName:I,show:L,sort:M,customGroup:_,conditions:O};break}}}let T;if(Array.isArray(g)&&g.length>0){const F=g.length;for(let D=0;D<F;D++){const P=g[D]||{},{label:V="",name:I="",show:L=!1,sort:M,customGroup:_,conditions:O}=P;if(L||F===1){T={label:V,columnName:I,show:L,sort:M,customGroup:_,conditions:O};break}}}const B=[];C==null||C.forEach(F=>{B.push(t(F))});const w=[];if(m==null||m.forEach(F=>{F.location="LEFT",w.push(o(F))}),S==null||S.forEach(F=>{F.location="RIGHT",w.push(o(F))}),v==null||v.forEach(F=>{F.location="LEFT",w.push(o(F))}),b==="1"&&B.length===0)return;if(b==="2"&&w.length===0)return;let k=[];(l==null?void 0:l.pageMode)==="design"?k=l.sqlConditions??[]:k=i(x);try{const F=(R=window==null?void 0:window.config)==null?void 0:R.pageId;return await ot.post(`${Ds}/diagram`,{source:f,dataViewId:c,plugin:d,layer:b,chartType:u,classification:E,series:T,indicatorList:w,queryColumns:B,pageFlag:!0,pageId:F,sqlConditions:k,dataSourceId:p,idxLibMode:A,preview:y},{headers:{Authentication:(N=window==null?void 0:window.config)==null?void 0:N.indicatorToken,operateContext:_s}})}catch(F){console.error(F)}}},Hl=()=>{const n=window.location.search.slice(1).split("&"),t=n.length,o={};for(let r=0;r<t;r++){const i=n[r];if(i==null||i==="")continue;const l=i.split("=");if(Array.isArray(l)){const s=l[0];o[s]=l[1]}}window.config.requestParams={...window.config.requestParams,...o},window.config={...window.config,...o}},ql=a.defineComponent({name:"EcanPageConfig",inheritAttrs:!1,props:{...yn},setup(e){const{width:n,height:t}=a.inject(Ae,{width:null,height:null}),o=a.computed(()=>({width:n.value,height:t.value,backgroundColor:e.backgroundColor,backgroundImage:ht(e.backgroundImage,!0),backgroundSize:e.backgroundSize})),r=a.ref(0),i=a.ref(0),l=a.ref(0),s=a.ref(0),f=a.ref(!1),c=a.ref();let d;const b=()=>new Promise(C=>{a.nextTick(()=>{n.value&&t.value?(r.value=parseFloat(n.value),i.value=parseFloat(t.value)):(r.value=c.value.clientWidth,i.value=c.value.clientHeight),(!l.value||!s.value)&&(l.value=window.screen.width,s.value=window.screen.height),C()})}),u=()=>{r.value&&i.value?(c.value.style.width=`${r.value}px`,c.value.style.height=`${i.value}px`):(c.value.style.width=`${l.value}px`,c.value.style.height=`${s.value}px`)};a.watch([n,t],async()=>{await b(),u(),h(),window.addEventListener("resize",g),m(),f.value=!0},{immediate:!0});const h=()=>{const C=document.body.clientWidth,v=document.body.clientHeight,x=r.value||l.value,p=i.value||s.value,A=C/x;let y=v/p;(r.value!==1920||i.value!==1080)&&(y=i.value/r.value*C/p),c.value&&(c.value.style.transform=`scale(${A}, ${y})`)},g=Ge.debounce(async()=>{await b(),h()},100),m=()=>{const C=window.MutationObserver;d=new C(g),d.observe(c.value,{attributes:!0,attributeFilter:["style"],attributeOldValue:!0})},S=()=>{d&&(d.disconnect(),d.takeRecords(),d=null)};return a.onMounted(()=>{f.value=!1}),a.onUnmounted(()=>{window.removeEventListener("resize",g),S()}),{style:o,container:c,ready:f}}}),md="",Vl={id:"container",ref:"container"};function jl(e,n,t,o,r,i){return a.openBlock(),a.createElementBlock("div",Vl,[e.ready?(a.openBlock(),a.createElementBlock("div",{key:0,class:"page-config",style:a.normalizeStyle(e.style)},[a.renderSlot(e.$slots,"default",{},void 0,!0)],4)):a.createCommentVNode("",!0)],512)}const Vr=se(ae(ql,[["render",jl],["__scopeId","data-v-06635c02"]])),lo={contextRequestUrl:"",pageMode:"normal",theme:"light",containerMap:{},width:"1920px",height:"1080px"},co=fe(lo),Gl=a.defineComponent({name:"EcanProviderConfig",inheritAttrs:!1,props:{...co},setup(e,{expose:n}){Hl();const t=a.ref(),o=()=>{t.value.setAttribute("datav-theme",e.theme)};a.watch(()=>e.theme,()=>{o()}),a.onMounted(()=>{o()});const r=a.computed(()=>be(e.contextRequestUrl)),i=a.computed(()=>e.pageMode),l=a.computed(()=>e.theme),s=a.computed(()=>e.width),f=a.computed(()=>e.height),c=a.ref("");a.provide(Ae,{contextRequestUrl:r,pageMode:i,theme:l,touchEventId:c,width:s,height:f});const d=new Map;console.log("globalModel",d);const b=V=>d.get(V),u=(V,I)=>{d.set(V,I)};a.provide(we,{getGlobalModel:b,setGlobalModel:u});const h=[],g=()=>{h.pop()},m=V=>{h.push(V)},S=new Map,C=V=>S.get(V),v=(V,I)=>{S.set(V,I)};a.provide(Pa,{popUseModalIds:g,pushUseModalIds:m,getModalModel:C,setModalModel:v});const x=ii(),p=new Set,A=(V,I)=>{p.add(V),x.on(V,L=>typeof I[L]=="function"&&I[L]()),a.onBeforeUnmount(()=>{y(V)})},y=V=>{p.delete(V),x.off(V)},E=(V,I)=>{if(V==="PAGE"){const L=h.length;let M=[];if(L===0)M=[...p];else{const _=h[L-1];M=[...C(_)]}M.forEach(_=>{x.emit(_,I)})}else x.emit(V,I)};a.provide(pn,{onEvent:A,offEvent:y,emitEvent:E});const T=a.ref(0),B=()=>{T.value=a.unref(T)+1};a.provide(Ma,{requestToken:B});const w=new Map,k=new Map,R=({requestFn:V=()=>{},sortNum:I=0,id:L=""})=>{if(w.has(I)){const M=w.get(I);M==null||M.push(V)}else w.set(I,[V]);k.set(L,V)},N=V=>new Promise((I,L)=>{const M=V.map(_=>_());Promise.all(M).then(_=>{I(_)}).catch(_=>{L(_)})}),F=V=>new Promise(async(I,L)=>{if(V){if(typeof V=="string"){const M=k.get(V);if(typeof M=="function"){const _=ot.interceptors.response.use(O=>(I(O),O),O=>(L(O),Promise.reject(O)));M(),ot.interceptors.response.eject(_)}}}else{const M=Array.from(w);M.sort((O,z)=>z[0]-O[0]);const _=M.length;try{e.pageMode!=="design"&&a.unref(T)>0;for(let O=0;O<_;O++){const z=M[O][1];await N(z)}}catch(O){console.error(O)}finally{w.clear(),I(null)}}});a.provide(Te,{setRequest:R,touchRequest:F});const D=()=>{x.emit(Lt)};a.provide(Lt,{emitRefreshPage:D});const P=V=>{x.on(Lt,()=>V()),a.onMounted(()=>{x.off(Lt)})};return a.onBeforeUnmount(()=>{w==null||w.clear(),k==null||k.clear()}),n({touchRequest:F,getGlobalModel:b,onRefreshPage:P}),{providerConfig:t}}}),Ul={id:"ProviderConfig",ref:"providerConfig"};function Wl(e,n,t,o,r,i){return a.openBlock(),a.createElementBlock("div",Ul,[a.renderSlot(e.$slots,"default")],512)}const jr=se(ae(Gl,[["render",Wl]])),fo={...ge,name:"文本",keyName:"文本",type:"ecanText",width:"100px",height:"40px",text:"文字",lineHeight:1,color:"#333",variableColor:"#f00",fontSize:"14px",fontFamily:"",fontWeight:400,textShadow:"",justifyContent:"center",alignItems:"center",variableFontSize:"14px",variableDefaultValue:"0",format:"",target:"self",href:"",linkPage:"",data:{},percentageSide:"left",increaseColor:"",declineColor:"",minusSignShow:!0,unitShow:!0,unitText:"",unitFontSize:"14px",unitFontWeight:400,unitColor:"#333",unitTop:"",unitLeft:"",graphicConfig:{}},uo=fe(fo),Gr=["refreshData","click","valueChange"],Ur="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAV1BMVEUAAAD/WzT/WjP/WDD/WzT/WzP/WzT/WzT/WzT/WjT/WzT/WDT/YED/WzT/WzT/WjT/YED/WzT/WzT/WzT/XDT/WzT/WjX/WjP/XDT/XDT/WTL/Tif/WzReH8z5AAAAHHRSTlMA8RgS9W9YHbePZyME5sVjCP7bzcCxgndOQC4GFJJgKwAAAIJJREFUKM+Nkd0OgyAMRjvqcLA53fzXvv9zaokmxq8mnsue5ACFDjiy+XyjLZ7yyK35OxN5mSFZKa2QojEIKRhrZKM0QnsMQxirmJ0kBubTIZvAtUyiFAT4JFoUIYmIotZ5xjDPfyoCAV16nM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jNFehCT8B3VoTAUID/xHURAn0B/g5fRQh0B/j7mOJkf2gTaKvY7YG8FsxXPe/hIVbgCTs5C+vAasU+xlooMGuLTrCVI/CDR0zVCgi9gzmUIgQmBbYmT+AdY5LjGMKWpNuaqHWKLrEY8JUkXeYi75iu4DzFfUi6ey9C4AvjeKviliTdRSHmsrvBbMU+lzNg0oidaLvox7LIK+IHdem/iqIROzL/jG+NrT1BRsXKNQAAAABJRU5ErkJggg==",ho=a.defineComponent({name:"EcanText",components:{Skeleton:Ht},props:{...uo},setup(e,{expose:n}){const t=ue(e),o=a.ref({}),r=a.computed(()=>e.variableFontSize||"14px"),i=a.computed(()=>"-"+a.unref(r));a.watch(()=>[e.data,e.dataType],([x,p])=>{p==="static"&&(o.value=x)},{immediate:!0});const l=a.computed(()=>{var B;const x=a.unref(o),p=e.increaseColor||e.color,A=e.declineColor||e.color;let y=e.text;y=y==null?void 0:y.replace(/\n|\\n/g,"<br/>"),y=y==null?void 0:y.replace(/\s(?!\{) | (?!\})\s/g," ");const E=y.match(/\{(.+?)\}/g)||[];let T="";if(E==null||E.length===0){if(y&&e.format==="percentage"&&!isNaN(+y)){const w=parseFloat(y),k=(w*100).toFixed(2);w>=0?y=`<span style="color: ${p||"#ED6643"};font-size:${a.unref(r)};display: inline-block;">
|
|
97
|
+
`),so=(e,n=2)=>{const t=parseFloat(e+"");return isNaN(t)?e:t.toFixed(n).replace(/(\d)(?=(\d{3})+\.)/g,"$1,")},Fl=e=>{const n=parseFloat(e+"");return isNaN(n)?e:(n+"").replace(/\B(?=(\d{3})+(?!\d))/g,",")},Xt=(e,n=2)=>{const t=e+"";if(t.includes("%"))return e;const o=parseFloat(t);return isNaN(o)?e:`${(o*100).toFixed(n)}%`},Qt=(e,n)=>{if(typeof e=="string"&&typeof n=="string")return e.toLocaleLowerCase().includes(n.toLocaleLowerCase());if(typeof e=="string"&&Array.isArray(n)){const t=n.length;for(let o=0;o<t;o++){const r=n[o];if(typeof r=="string"&&e.toLocaleLowerCase().includes(r.toLocaleLowerCase()))return!0}}return!1},Jt=(e,n)=>{const t={dayjs:Ne,...n};let o="";const r=[];for(const s in t)o+=`${s},`,r.push(t[s]);o=o.replace(/,$/,"");const i=`function (${o}){return ${e}}`;let l;try{l=Function(`"use strict";return (${i})`)()(...r)}catch{return e}return l},be=(e="",{textData:n,codeData:t}={},{useNewline:o=!1,useSpace:r=!1}={})=>{const l={...window.config||{},...n},s=e.match(/\{(.+?)\}/g);if(s==null||s.length===0)return e;for(let f=0;f<s.length;f++){const c=s[f];let d=c.slice(1,-1).trim();const b=/[\u4e00-\u9fa5a-z-_A-Z0-9]*/g,u=d.match(b);for(let h=0;h<u.length;h++){const g=u[h],m=l[g];m!=null&&(d=d.replace(g,m))}(/\(.*\)/g.test(d)||/[+/\\*]/g.test(d))&&(d=Jt(d,t)),e=e.replace(c,d)}return o&&(e=e==null?void 0:e.replace(/\n|\\n/g,"<br/>")),r&&(e=e==null?void 0:e.replace(/\s{2,}?/g," ")),e},Re=(e,n=()=>{})=>{const{requestUrl:t,requestMethod:o,requestHeaders:r,requestParams:i,requestInterval:l,isOpenRequestTimer:s}=e,{contextRequestUrl:f,touchEventId:c}=a.inject(Ae,{contextRequestUrl:"",touchEventId:""}),{getGlobalModel:d}=a.inject(we,{getGlobalModel:g=>{}}),b=be(t),u=async(g={})=>{if(!b||!o||!r)return;let m={};i.forEach(p=>{const{key:A,value:y}=p;if(typeof y=="object"&&y!=null&&y.id){let E={};const{id:T,prop:B,propKey:w,operate:k}=y;T==="THIS"?E=d(a.unref(c))||{}:E=d(T)||{};const R=a.unref(E[B]);let N=null;if(["date","range"].some(D=>Qt(E==null?void 0:E.type,D))){const{value:D,type:P,mode:V}=k||{};if(D&&P&&V)switch(P){case"add":N=a.unref(R).add(D,V);break;case"minus":N=a.unref(R).subtract(D,V);break}N==null&&(N=a.unref(R)),N=(N==null?void 0:N.format((w==null?void 0:w.trim())||E.format))||""}else Object.prototype.toString.call(R)==="[object Object]"?w?N=R[w]:N=B?R[B]:R:Qt(E==null?void 0:E.type,"select")&&a.unref(R)&&B&&Array.isArray(a.unref(R))?N=a.unref(R).map(D=>Object.prototype.hasOwnProperty.call(D,B)?D[B]:D):N=R;m[A]=N}else typeof y=="string"&&(m[A]=be(y))}),m={...window.config.requestParams,...g,...m};let S="";const C=Object.keys(m),v=C.length-1,x=C.length;C.forEach((p,A)=>{let y=m[p];Object.prototype.toString.call(y)==="[object Object]"&&(y=JSON.stringify(y)),A===0?x!==1?S+=`?${p}=${y}&`:S+=`?${p}=${y}`:A===v?S+=`${p}=${y}`:S+=`${p}=${y}&`});try{const p=["get","head"].includes(o);let A=p?b+S:b;m.dataSqlId&&!A.includes("dataSqlId")&&(A+=`${A.includes("?")?"&":"?"}dataSqlId=${m.dataSqlId}`);const y=await ot({baseURL:a.unref(f)||"",url:A,method:o,headers:r,data:p?{}:m});return n(y),y}catch(p){console.error(p)}},h=s&&setInterval(u,l*1e3);return a.onUnmounted(()=>{clearInterval(h)}),u},at=(e=[],n)=>{let{name:t="name",types:o=[]}=n||{};t=(t==null?void 0:t.trim())||t;const r=new Set,i=new Map,l=e.length,s=o.length;if(l===1){const d=[];for(let u=0;u<s;u++){const h=o[u],{label:g,value:m}=h,S={...e[0],value:e[0][m]};r.add(g),d.push(S)}const b=e[0][t]||"";i.set(b,d)}else for(let d=0;d<l;d++){const b=e[d],u=b[t];r.add(u);for(let h=0;h<s;h++){const g=o[h],{label:m,value:S}=g,C={...b,value:b[S]};if(i.has(m)){const v=i.get(m);v.push(C),i.set(m,v)}else i.set(m,[C])}}const f=Array.from(r),c=[];for(const[d,b]of i)c.push({name:d,data:b});return{dimensions:f,dataset:c}},ht=(e,n=!1)=>{var o;if(!e)return e;let t="";return e!=null&&e.includes("://")?t=e:t=((o=window==null?void 0:window.config)==null?void 0:o.uploadPath)+e,n&&(t=`url(${t})`),t},qr=(e,n)=>{const t=`${za}/preview?pageId=${n}`,o=`${za}/${n}`;return e==="preview"?t:o},gt=(e,n)=>{var r;if(e==null)return n;const t=e.match(/\{.*\}/g);if(t==null||t.length===0)return n;const o=t.length;for(let i=0;i<o;i++){const l=t[i];if(l==null||l==="")break;let s=(r=l.slice(1,-1))==null?void 0:r.trim();s=s==null?void 0:s.replace(/value/g,n);try{let f=s;(/\(.*\)/g.test(s)||/[+/\\*]/g.test(s))&&(f=Jt(s)),e=e.replace(l,f)}catch{e=e.replace(l,s)}}return e},He=(e={})=>{const{requestToken:n}=a.inject(Ma,{requestToken:()=>{}});e.dataType==="indicator"&&n();const t=(l={})=>{const{label:s,name:f,location:c,show:d,indexCode:b}=l;return{label:s,columnName:f,location:c,show:d,calcType:"COLUMN",hrpIndexCode:b}},o=(l={})=>{const{label:s,name:f,location:c,show:d,indexCode:b,calcType:u="COLUMN",builtInFormula:h,builtInValueSource:g,builtInCalcWay:m,formula:S,conditions:C}=l;return{label:s,columnName:f,location:c,show:d,calcType:u,hrpIndexCode:b,aggregate:"SUM",builtInFormula:h,builtInValueSource:g,builtInCalcWay:m,formula:S,conditions:C}},{getGlobalModel:r}=a.inject(we,{getGlobalModel:l=>{}}),i=(l=[])=>{var c,d;const s=l.length;console.log("controlList",l);const f=[];for(let b=0;b<s;b++){const u=l[b],{id:h,conditionLabel:g,conditionKey:m,conditionValueType:S,prop:C}=u,v={rule:"NONE",label:g,fieldName:m,fieldValue:"",valueType:S},x=r(h)||{};console.log("model",x);const{value:p,format:A="YYYY-MM-DD",type:y=""}=x||{};Qt(x.type,"date")?(v.fieldValue=(c=a.unref(p))==null?void 0:c.format(A),v.dateFormat=A):y==="ecanRangePicker"&&C?(C==="startTime"?v.rule="GREATER_EQUAL":C==="endTime"&&(v.rule="LESS_EQUAL"),v.fieldValue=(d=a.unref(x[C]))==null?void 0:d.format(A),v.dateFormat=A):v.fieldValue=a.unref(p),f.push(v)}return f};return async()=>{var R,N;const{graphicConfig:l,type:s}=e;let{source:f,dataViewId:c,plugin:d="1",layer:b,chartType:u,classificationList:h=[],seriesList:g=[],leftAxisList:m=[],rightAxisList:S=[],queryColumnList:C=[],indicators:v=[],controlList:x=[],dataSourceId:p,idxLibMode:A,preview:y=!1}=l||{};b==null&&(Qt(s,["table","text","proportion","select","checkbox","radio"])?b="1":b="2");let E;if(Array.isArray(h)&&h.length>0){const F=h.length;for(let D=0;D<F;D++){const P=h[D]||{},{label:V="",name:I="",show:L=!1,sort:M,customGroup:_,conditions:O}=P;if(L||F===1){E={label:V,columnName:I,show:L,sort:M,customGroup:_,conditions:O};break}}}let T;if(Array.isArray(g)&&g.length>0){const F=g.length;for(let D=0;D<F;D++){const P=g[D]||{},{label:V="",name:I="",show:L=!1,sort:M,customGroup:_,conditions:O}=P;if(L||F===1){T={label:V,columnName:I,show:L,sort:M,customGroup:_,conditions:O};break}}}const B=[];C==null||C.forEach(F=>{B.push(t(F))});const w=[];if(m==null||m.forEach(F=>{F.location="LEFT",w.push(o(F))}),S==null||S.forEach(F=>{F.location="RIGHT",w.push(o(F))}),v==null||v.forEach(F=>{F.location="LEFT",w.push(o(F))}),b==="1"&&B.length===0)return;if(b==="2"&&w.length===0)return;let k=[];(l==null?void 0:l.pageMode)==="design"?k=l.sqlConditions??[]:k=i(x);try{const F=(R=window==null?void 0:window.config)==null?void 0:R.pageId;return await ot.post(`${Ds}/diagram`,{source:f,dataViewId:c,plugin:d,layer:b,chartType:u,classification:E,series:T,indicatorList:w,queryColumns:B,pageFlag:!0,pageId:F,sqlConditions:k,dataSourceId:p,idxLibMode:A,preview:y},{headers:{Authentication:(N=window==null?void 0:window.config)==null?void 0:N.indicatorToken,operateContext:_s}})}catch(F){console.error(F)}}},Hl=()=>{const n=window.location.search.slice(1).split("&"),t=n.length,o={};for(let r=0;r<t;r++){const i=n[r];if(i==null||i==="")continue;const l=i.split("=");if(Array.isArray(l)){const s=l[0];o[s]=l[1]}}window.config.requestParams={...window.config.requestParams,...o},window.config={...window.config,...o}},ql=a.defineComponent({name:"EcanPageConfig",inheritAttrs:!1,props:{...yn},setup(e){const{width:n,height:t}=a.inject(Ae,{width:null,height:null}),o=a.computed(()=>({width:n.value,height:t.value,backgroundColor:e.backgroundColor,backgroundImage:ht(e.backgroundImage,!0),backgroundSize:e.backgroundSize})),r=a.ref(0),i=a.ref(0),l=a.ref(0),s=a.ref(0),f=a.ref(!1),c=a.ref();let d;const b=()=>new Promise(C=>{a.nextTick(()=>{n.value&&t.value?(r.value=parseFloat(n.value),i.value=parseFloat(t.value)):(r.value=c.value.clientWidth,i.value=c.value.clientHeight),(!l.value||!s.value)&&(l.value=window.screen.width,s.value=window.screen.height),C()})}),u=()=>{r.value&&i.value?(c.value.style.width=`${r.value}px`,c.value.style.height=`${i.value}px`):(c.value.style.width=`${l.value}px`,c.value.style.height=`${s.value}px`)};a.watch([n,t],async()=>{await b(),u(),h(),window.addEventListener("resize",g),m(),f.value=!0},{immediate:!0});const h=()=>{const C=document.body.clientWidth,v=document.body.clientHeight,x=r.value||l.value,p=i.value||s.value,A=C/x;let y=v/p;(r.value!==1920||i.value!==1080)&&(y=i.value/r.value*C/p),c.value&&(c.value.style.transform=`scale(${A}, ${y})`)},g=Ge.debounce(async()=>{await b(),h()},100),m=()=>{const C=window.MutationObserver;d=new C(g),d.observe(c.value,{attributes:!0,attributeFilter:["style"],attributeOldValue:!0})},S=()=>{d&&(d.disconnect(),d.takeRecords(),d=null)};return a.onMounted(()=>{f.value=!1}),a.onUnmounted(()=>{window.removeEventListener("resize",g),S()}),{style:o,container:c,ready:f}}}),md="",Vl={id:"container",ref:"container"};function jl(e,n,t,o,r,i){return a.openBlock(),a.createElementBlock("div",Vl,[e.ready?(a.openBlock(),a.createElementBlock("div",{key:0,class:"page-config",style:a.normalizeStyle(e.style)},[a.renderSlot(e.$slots,"default",{},void 0,!0)],4)):a.createCommentVNode("",!0)],512)}const Vr=se(ae(ql,[["render",jl],["__scopeId","data-v-06635c02"]])),lo={contextRequestUrl:"",pageMode:"normal",theme:"light",containerMap:{},width:"1920px",height:"1080px"},co=fe(lo),Gl=a.defineComponent({name:"EcanProviderConfig",inheritAttrs:!1,props:{...co},setup(e,{expose:n}){Hl();const t=a.ref(),o=()=>{t.value.setAttribute("datav-theme",e.theme)};a.watch(()=>e.theme,()=>{o()}),a.onMounted(()=>{o()});const r=a.computed(()=>be(e.contextRequestUrl)),i=a.computed(()=>e.pageMode),l=a.computed(()=>e.theme),s=a.computed(()=>e.width),f=a.computed(()=>e.height),c=a.ref("");a.provide(Ae,{contextRequestUrl:r,pageMode:i,theme:l,touchEventId:c,width:s,height:f});const d=new Map;console.log("globalModel",d);const b=V=>d.get(V),u=(V,I)=>{d.set(V,I)};a.provide(we,{getGlobalModel:b,setGlobalModel:u});const h=[],g=()=>{h.pop()},m=V=>{h.push(V)},S=new Map,C=V=>S.get(V),v=(V,I)=>{S.set(V,I)};a.provide(Pa,{popUseModalIds:g,pushUseModalIds:m,getModalModel:C,setModalModel:v});const x=ii(),p=new Set,A=(V,I)=>{p.add(V),x.on(V,L=>typeof I[L]=="function"&&I[L]()),a.onBeforeUnmount(()=>{y(V)})},y=V=>{p.delete(V),x.off(V)},E=(V,I)=>{if(V==="PAGE"){const L=h.length;let M=[];if(L===0)M=[...p];else{const _=h[L-1];M=[...C(_)]}M.forEach(_=>{x.emit(_,I)})}else x.emit(V,I)};a.provide(pn,{onEvent:A,offEvent:y,emitEvent:E});const T=a.ref(0),B=()=>{T.value=a.unref(T)+1};a.provide(Ma,{requestToken:B});const w=new Map,k=new Map,R=({requestFn:V=()=>{},sortNum:I=0,id:L=""})=>{if(w.has(I)){const M=w.get(I);M==null||M.push(V)}else w.set(I,[V]);k.set(L,V)},N=V=>new Promise((I,L)=>{const M=V.map(_=>_());Promise.all(M).then(_=>{I(_)}).catch(_=>{L(_)})}),F=V=>new Promise(async(I,L)=>{if(V){if(typeof V=="string"){const M=k.get(V);if(typeof M=="function"){const _=ot.interceptors.response.use(O=>(I(O),O),O=>(L(O),Promise.reject(O)));M(),ot.interceptors.response.eject(_)}}}else{const M=Array.from(w);M.sort((O,z)=>z[0]-O[0]);const _=M.length;try{e.pageMode!=="design"&&a.unref(T)>0;for(let O=0;O<_;O++){const z=M[O][1];await N(z)}}catch(O){console.error(O)}finally{w.clear(),I(null)}}});a.provide(Te,{setRequest:R,touchRequest:F});const D=()=>{x.emit(Lt)};a.provide(Lt,{emitRefreshPage:D});const P=V=>{x.on(Lt,()=>V()),a.onMounted(()=>{x.off(Lt)})};return a.onBeforeUnmount(()=>{w==null||w.clear(),k==null||k.clear()}),n({touchRequest:F,getGlobalModel:b,onRefreshPage:P}),{providerConfig:t}}}),Ul={id:"ProviderConfig",ref:"providerConfig"};function Wl(e,n,t,o,r,i){return a.openBlock(),a.createElementBlock("div",Ul,[a.renderSlot(e.$slots,"default")],512)}const jr=se(ae(Gl,[["render",Wl]])),fo={...ge,name:"文本",keyName:"文本",type:"ecanText",width:"100px",height:"40px",text:"文字",lineHeight:1,color:"#333",variableColor:"#f00",fontSize:"14px",fontFamily:"",fontWeight:400,textShadow:"",justifyContent:"center",alignItems:"center",variableFontSize:"14px",variableDefaultValue:"0",format:"",target:"self",href:"",linkPage:"",data:{},percentageSide:"left",increaseColor:"",declineColor:"",minusSignShow:!0,unitShow:!0,unitText:"",unitFontSize:"14px",unitFontWeight:400,unitColor:"#333",unitTop:"",unitLeft:"",graphicConfig:{}},uo=fe(fo),Gr=["refreshData","click","valueChange"],Ur="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAV1BMVEUAAAD/WzT/WjP/WDD/WzT/WzP/WzT/WzT/WzT/WjT/WzT/WDT/YED/WzT/WzT/WjT/YED/WzT/WzT/WzT/XDT/WzT/WjX/WjP/XDT/XDT/WTL/Tif/WzReH8z5AAAAHHRSTlMA8RgS9W9YHbePZyME5sVjCP7bzcCxgndOQC4GFJJgKwAAAIJJREFUKM+Nkd0OgyAMRjvqcLA53fzXvv9zaokmxq8mnsue5ACFDjiy+XyjLZ7yyK35OxN5mSFZKa2QojEIKRhrZKM0QnsMQxirmJ0k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4cZCxoE6//FaiXbEtThm87JjkPI+jN4E9xW4TAQoA/isjNFehCT8B3VoTAUID/xHURAn0B/g5fRQh0B/j7mOJkf2gTaKvY7YG8FsxXPe/hIVbgCTs5C+vAasU+xlooMGuLTrCVI/CDR0zVCgi9gzmUIgQmBbYmT+AdY5LjGMKWpNuaqHWKLrEY8JUkXeYi75iu4DzFfUi6ey9C4AvjeKviliTdRSHmsrvBbMU+lzNg0oidaLvox7LIK+IHdem/iqIROzL/jG+NrT1BRsXKNQAAAABJRU5ErkJggg==",ho=a.defineComponent({name:"EcanText",components:{Skeleton:Ht},props:{...uo},setup(e,{expose:n}){const t=ue(e),o=a.ref({}),r=a.computed(()=>e.variableFontSize||"14px"),i=a.computed(()=>"-"+a.unref(r));a.watch(()=>[e.data,e.dataType],([x,p])=>{p==="static"&&(o.value=x)},{immediate:!0});const l=a.computed(()=>{var B;const x=a.unref(o),p=e.increaseColor||e.color,A=e.declineColor||e.color;let y=e.text;y=y==null?void 0:y.replace(/\n|\\n/g,"<br/>"),y=y==null?void 0:y.replace(/\s(?!\{) | (?!\})\s/g," ");const E=y.match(/\{(.+?)\}/g)||[];let T="";if(E==null||E.length===0){if(y&&e.format==="percentage"&&!isNaN(+y)){const w=parseFloat(y),k=(w*100).toFixed(2);w>=0?y=`<span style="color: ${p||"#ED6643"};font-size:${a.unref(r)};display: inline-block;">
|
|
98
98
|
<div class="percentage-img-box">
|
|
99
99
|
<img style="width: ${a.unref(r)};filter: ${`drop-shadow(${p||"#ED6643"} ${a.unref(r)} 0px)`};" src="${Ur}"/>
|
|
100
100
|
</div>
|