1
This commit is contained in:
@@ -8,7 +8,7 @@
|
|||||||
<link rel="icon" href="/favicon.ico" />
|
<link rel="icon" href="/favicon.ico" />
|
||||||
<script src="/node_modules/ace-builds/src-min-noconflict/ace.js" type="text/javascript"></script>
|
<script src="/node_modules/ace-builds/src-min-noconflict/ace.js" type="text/javascript"></script>
|
||||||
<title>NPCs</title>
|
<title>NPCs</title>
|
||||||
<script type="module" crossorigin src="/assets/index-e026e2d0.js"></script>
|
<script type="module" crossorigin src="/assets/index-13a97ef6.js"></script>
|
||||||
<link rel="modulepreload" crossorigin href="/assets/acebuilds-fbc0ccc6.js">
|
<link rel="modulepreload" crossorigin href="/assets/acebuilds-fbc0ccc6.js">
|
||||||
<link rel="modulepreload" crossorigin href="/assets/reactflow-c250d835.js">
|
<link rel="modulepreload" crossorigin href="/assets/reactflow-c250d835.js">
|
||||||
<link rel="modulepreload" crossorigin href="/assets/reactdrop-be699031.js">
|
<link rel="modulepreload" crossorigin href="/assets/reactdrop-be699031.js">
|
||||||
|
|||||||
@@ -29,12 +29,21 @@ function Chart({ options }) {
|
|||||||
options.series = [];
|
options.series = [];
|
||||||
|
|
||||||
options.xData.map((data,index) =>{
|
options.xData.map((data,index) =>{
|
||||||
options.pieData.push({'name':data,'value':options.data[options.legend[0]][index].split("%").join("")})
|
if(options.data[options.legend[0]][index] &&options.data[options.legend[0]][index].indexOf("%") !== -1){
|
||||||
|
options.pieData.push({'name':data,'value':options.data[options.legend[0]][index].split("%").join("")})
|
||||||
|
}else{
|
||||||
|
options.pieData.push({'name':data,'value':options.data[options.legend[0]][index]})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
options.legend.map((data,index) =>{
|
options.legend.map((data,index) =>{
|
||||||
let list = [];
|
let list = [];
|
||||||
options.data[data].map(data1 =>{
|
options.data[data].map(data1 =>{
|
||||||
list.push(data1.split("%").join(""))
|
console.log(data1.indexOf('%'))
|
||||||
|
if(data1.indexOf('%') !== -1){
|
||||||
|
list.push(data1.split("%").join(""))
|
||||||
|
}else{
|
||||||
|
list.push(data1)
|
||||||
|
}
|
||||||
});
|
});
|
||||||
options.series.push({
|
options.series.push({
|
||||||
name: data,
|
name: data,
|
||||||
|
|||||||
Reference in New Issue
Block a user