diff --git a/src/api/SaleRankMarket/index.js b/src/api/SaleRankMarket/index.js
index f1eace6..cc934ca 100644
--- a/src/api/SaleRankMarket/index.js
+++ b/src/api/SaleRankMarket/index.js
@@ -378,4 +378,41 @@ export function getSalesSpecName1TypesE(params) {
'content-type': 'application/x-www-form-urlencoded'
}
})
+}
+
+// 新能源 - 车型主销价格占比
+export function getSalesSpecNameByPriceRangeByEnergy(params) {
+ let obj = Object.assign({action: 'getSalesSpecNameByPriceRangeByEnergy', sType: 'Marketing'}, params)
+ return httpService({
+ url: `/api/v6.ashx`,
+ method: 'post',
+ data: obj,
+ headers: {
+ 'content-type': 'application/x-www-form-urlencoded'
+ }
+ })
+}
+// 新能源 - 主销价格区间 - 区间
+export function getSalesPriceRangeSTypesByEnergy(params) {
+ let obj = Object.assign({action: 'getSalesPriceRangeSTypesByEnergy', sType: 'Marketing'}, params)
+ return httpService({
+ url: `/api/v6.ashx`,
+ method: 'post',
+ data: obj,
+ headers: {
+ 'content-type': 'application/x-www-form-urlencoded'
+ }
+ })
+}
+// 新能源 - 主销价格区间 - 品牌
+export function getSalesPriceRangeSBrandByEnergy(params) {
+ let obj = Object.assign({action: 'getSalesPriceRangeSBrandByEnergy', sType: 'Marketing'}, params)
+ return httpService({
+ url: `/api/v6.ashx`,
+ method: 'post',
+ data: obj,
+ headers: {
+ 'content-type': 'application/x-www-form-urlencoded'
+ }
+ })
}
\ No newline at end of file
diff --git a/src/router/index.js b/src/router/index.js
index 89bae40..d805168 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -357,9 +357,17 @@ const router = [
component: resolve => require(['@/views/SaleRank/MarketSaleNE/mnePrecisionType/index.vue'], resolve),
},
{
- path: 'mneMainPrice', //新能源车市场销量分析 - 主销价格区间
+ path: 'mneMainPrice', //新能源车市场销量分析 - 车型类别
component: resolve => require(['@/views/SaleRank/MarketSaleNE/mneMainPrice/index.vue'], resolve),
},
+ {
+ path: 'mneMP', //新能源车市场销量分析 - 主销价格区间
+ component: resolve => require(['@/views/SaleRank/MarketSaleNE/mneMP/index.vue'], resolve),
+ },
+ {
+ path: 'mneMPPercent', //新能源车市场销量分析 - 主销价格占比
+ component: resolve => require(['@/views/SaleRank/MarketSaleNE/mneMPPercent/index.vue'], resolve),
+ },
]
},
{
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/index.vue b/src/views/SaleRank/MarketSaleNE/mneMP/index.vue
new file mode 100644
index 0000000..1643349
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/index.vue
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/index.vue b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/index.vue
new file mode 100644
index 0000000..6080090
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/index.vue
@@ -0,0 +1,132 @@
+
+
+
+ 导出报告
+
+
+ 导出报告
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/opt.js b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/opt.js
new file mode 100644
index 0000000..f53f5ea
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/opt.js
@@ -0,0 +1,137 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+import { bigNumberTransform } from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA'
+,'#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 24,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOpt(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#fff',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 14);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ min: 0,
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%';
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/optLight.js b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/optLight.js
new file mode 100644
index 0000000..9388fd0
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainBrand/optLight.js
@@ -0,0 +1,136 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA'
+,'#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 24,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOptLight(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#000',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 14);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ min: 0,
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%';
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/index.vue b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/index.vue
new file mode 100644
index 0000000..bc1339d
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/index.vue
@@ -0,0 +1,139 @@
+
+
+
+ 导出报告
+
+
+ 导出报告
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/opt.js b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/opt.js
new file mode 100644
index 0000000..89fd2c7
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/opt.js
@@ -0,0 +1,147 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+import { bigNumberTransform } from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090',
+'#62DDAA','#9DF5CA','#9DF5CA','#FFD470','#FFDE95','#FFEBBF','#E19D62','#F7B075','#FDC388','#FDD69B']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 36,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ label: {
+ show: true,
+ position: 'inside',
+ color: '#FFF',
+ fontWeight: 600,
+ fontSize: 12,
+ formatter: (res) => {
+ return res.data + '%'
+ }
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOpt(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#fff',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 10);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ min: 0,
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%';
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/optLight.js b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/optLight.js
new file mode 100644
index 0000000..4077507
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMP/mainCountry/optLight.js
@@ -0,0 +1,146 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090',
+'#62DDAA','#9DF5CA','#9DF5CA','#FFD470','#FFDE95','#FFEBBF','#E19D62','#F7B075','#FDC388','#FDD69B']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 36,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ label: {
+ show: true,
+ position: 'inside',
+ color: '#000',
+ fontWeight: 600,
+ fontSize: 12,
+ formatter: (res) => {
+ return res.data + '%'
+ }
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOptLight(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#000',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 10);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ min: 0,
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%';
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMPPercent/index.vue b/src/views/SaleRank/MarketSaleNE/mneMPPercent/index.vue
new file mode 100644
index 0000000..257ef30
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMPPercent/index.vue
@@ -0,0 +1,137 @@
+
+
+
+ 导出报告
+
+
+ 导出报告
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMPPercent/opt.js b/src/views/SaleRank/MarketSaleNE/mneMPPercent/opt.js
new file mode 100644
index 0000000..5d134a3
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMPPercent/opt.js
@@ -0,0 +1,146 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+import { bigNumberTransform } from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA'
+,'#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 48,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ label: {
+ show: true,
+ position: 'inside',
+ color: '#FFF',
+ fontWeight: 600,
+ formatter: (res) => {
+ return res.data + '%'
+ }
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOpt(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#fff',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 10);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#fff",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%'
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleNE/mneMPPercent/optLight.js b/src/views/SaleRank/MarketSaleNE/mneMPPercent/optLight.js
new file mode 100644
index 0000000..7f8cbc4
--- /dev/null
+++ b/src/views/SaleRank/MarketSaleNE/mneMPPercent/optLight.js
@@ -0,0 +1,145 @@
+/*
+ * @Author: your name
+ * @Date: 2021-10-09 11:01:19
+ * @LastEditTime: 2021-12-23 16:37:35
+ * @LastEditors: Please set LastEditors
+ * @Description: In User Settings Edit
+ * @FilePath: /data-show/src/views/Index/spreadTheSound/opt.js
+ */
+import * as echarts from "echarts";
+import {doStr} from "@/utils/gol/dataTool"
+let colors = ['#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA'
+,'#5B8FF9','#7DAAFF','#9AC5FF','#B9E2FF','#3A9EC0','#5BB9DB','#78D4F8','#63AECC','#19A576','#43C090','#43C090','#9DF5CA']
+function createData(ds = []) {
+ let arr = [];
+ for (let i = 0; i < ds.length; i++) {
+ let arr1 = ds[i];
+ for (let j = 0; j < arr1.length; j++) {
+ let n = arr.findIndex(ele => {
+ return ele.name === arr1[j].Key;
+ })
+ if (n === -1) {
+ let obj =
+ {
+ name: arr1[j].Key,
+ type: 'bar',
+ stack: 'total',
+ barWidth: 48,
+ barGap: "-100%",
+ emphasis: {
+ focus: 'series'
+ },
+ label: {
+ show: true,
+ position: 'inside',
+ color: '#000',
+ fontWeight: 600,
+ formatter: (res) => {
+ return res.data + '%'
+ }
+ },
+ itemStyle: {
+ normal: {
+ //柱体的颜色
+ //右,下,左,上(1,0,0,0)表示从正右开始向左渐变
+ color: function () {
+ return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+ {
+ offset: 0,
+ color: colors[j]
+ },
+ {
+ offset: 1,
+ color: colors[j]
+ }
+ ], false);
+ }
+ }
+
+ },
+ data: [arr1[j].Value]
+ }
+ arr.push(obj)
+ } else {
+ arr[n].data.push(arr1[j].Value)
+ }
+ }
+ }
+ return arr;
+}
+export default function createOpt(dx = [], ds = []) {
+ const data = createData(ds);
+ return {
+ grid: {
+ left: 10,
+ right: 10,
+ bottom: 10,
+ containLabel: true
+ },
+ tooltip: {
+ trigger: "axis",
+ backgroundColor: "#08182F",
+ color: "#fff",
+ borderColor: "#3373CC",
+ textStyle: {
+ color: "#fff", //设置文字颜色
+ },
+ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;"
+ },
+ color: colors,
+ legend: {
+ textStyle: { //图例文字的样式
+ color: '#000',
+ fontSize: 10
+ },
+ y: 10,
+ x: 10,
+ itemWidth: 12,
+ itemHeight: 12,
+ borderRadius: 1, //圆角半径
+ },
+ xAxis: {
+ type: 'category',
+ axisLabel :{
+ interval:0,
+ formatter: (value) => {
+ let res = doStr(value, 10);
+ return res
+ }
+ },
+ axisTick: {
+ show: false,
+ },
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ data: dx
+ },
+ yAxis: {
+ type: 'value',
+ max: 100,
+ axisLine: {
+ show: false,
+ lineStyle: {
+ color: "#000",
+ },
+ },
+ axisLabel: {
+ formatter: (value) => {
+ return value + '%'
+ }
+ },
+ splitLine: {
+ lineStyle: {
+ type: "dashed", // y轴分割线类型
+ color: "#012b4b",
+ },
+ },
+ },
+ series: data
+ }
+
+}
\ No newline at end of file
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/opt.js b/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/opt.js
index d5a1240..5d134a3 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/opt.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/opt.js
@@ -104,7 +104,7 @@ export default function createOpt(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 10);
return res
}
},
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/optLight.js b/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/optLight.js
index a696ba2..7f8cbc4 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/optLight.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMPPercent/optLight.js
@@ -103,7 +103,7 @@ export default function createOpt(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 10);
return res
}
},
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/opt.js b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/opt.js
index d4af7ed..f53f5ea 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/opt.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/opt.js
@@ -94,7 +94,7 @@ export default function createOpt(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 14);
return res
}
},
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/optLight.js b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/optLight.js
index 4ca4e9f..9388fd0 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/optLight.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainBrand/optLight.js
@@ -93,7 +93,7 @@ export default function createOptLight(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 14);
return res
}
},
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/opt.js b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/opt.js
index 42d4327..89fd2c7 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/opt.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/opt.js
@@ -104,7 +104,7 @@ export default function createOpt(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 10);
return res
}
},
diff --git a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/optLight.js b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/optLight.js
index e37b8b7..4077507 100644
--- a/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/optLight.js
+++ b/src/views/SaleRank/MarketSaleTraditional/mstMainPrice/mainCountry/optLight.js
@@ -103,7 +103,7 @@ export default function createOptLight(dx = [], ds = []) {
axisLabel :{
interval:0,
formatter: (value) => {
- let res = doStr(value, 8);
+ let res = doStr(value, 10);
return res
}
},
diff --git a/src/views/SaleRank/index.vue b/src/views/SaleRank/index.vue
index b19f1a8..4058f81 100644
--- a/src/views/SaleRank/index.vue
+++ b/src/views/SaleRank/index.vue
@@ -97,6 +97,12 @@
细分车型
+
+ 主销价格区间
+
+
+ 车型主销价格占比
+