prod
lily.zhang 3 years ago
parent 9afcd10cf6
commit ed20bb56a3

@ -79,7 +79,7 @@ export default {
watch: { watch: {
$route: { $route: {
handler(val) { handler(val) {
if (val.path === "/eventDEC") { if (val.path === "/eventDEC" || val.path === "/industryDataExport") {
this.timeShow = false; this.timeShow = false;
} else { } else {
this.timeShow = true; this.timeShow = true;

@ -89,7 +89,7 @@ export default {
watch: { watch: {
$route: { $route: {
handler(val) { handler(val) {
if (val.path === "/eventDEC" || val.path === "/eventComparison") { if (val.path === "/eventDEC" || val.path === "/eventComparison" || val.path === "/industryDataExport") {
this.timeShow = false; this.timeShow = false;
} else { } else {
this.timeShow = true; this.timeShow = true;

@ -1,7 +1,7 @@
/* /*
* @Author: your name * @Author: your name
* @Date: 2021-10-08 10:13:32 * @Date: 2021-10-08 10:13:32
* @LastEditTime: 2021-11-18 11:29:41 * @LastEditTime: 2021-11-19 17:57:49
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/utils/gol/index.js * @FilePath: /data-show/src/utils/gol/index.js
@ -9,7 +9,7 @@
import * as echarts from "echarts"; import * as echarts from "echarts";
import { bigNumberTransform } from "@/utils/gol/dataTool" import { bigNumberTransform } from "@/utils/gol/dataTool"
// import {doStr} from "./dataTool" // import {doStr} from "./dataTool"
export function createSingleColumnar(dx=[], ds=[], color='#3373CC') { export function createSingleColumnar(dx=[], ds=[], color='#3373CC', n = 4) {
return { return {
grid: { grid: {
top: 20, top: 20,
@ -41,10 +41,11 @@ export function createSingleColumnar(dx=[], ds=[], color='#3373CC') {
type: "category", type: "category",
axisLabel :{ axisLabel :{
interval:0, interval:0,
with: 1 / dx.length * 100 + '%', formatter: function (value) {
overflow: 'truncate', return (value.length > n ? (value.slice(0,n)+"...") : value )
ellipsis: '...' },
}, },
triggerEvent: false,
axisTick: { axisTick: {
show: false, show: false,
}, },
@ -109,7 +110,7 @@ export function createSingleColumnar(dx=[], ds=[], color='#3373CC') {
}, },
{ {
offset: 1, offset: 1,
color: color, // 100% 处的颜色#3373CC color: color ? color : '#3373CC', // 100% 处的颜色#3373CC
}, },
], ],
false false

@ -1,7 +1,7 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-19 09:46:17 * @Date: 2021-10-19 09:46:17
* @LastEditTime: 2021-10-19 09:58:01 * @LastEditTime: 2021-11-19 17:53:15
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/EventComparison/CWIEC/index.vue * @FilePath: /data-show/src/views/EventComparison/CWIEC/index.vue
@ -56,7 +56,7 @@ export default {
dx.push(e.key); dx.push(e.key);
ds.push(e.value); ds.push(e.value);
}); });
this.opt = createSingleColumnar(dx,ds); this.opt = createSingleColumnar(dx,ds, '', 6);
this.load = false; this.load = false;
}) })
} }

@ -1,7 +1,7 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-10-19 10:01:25 * @Date: 2021-10-19 10:01:25
* @LastEditTime: 2021-10-19 10:09:12 * @LastEditTime: 2021-11-19 17:57:06
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/EventComparison/cotwiEc/index.vue * @FilePath: /data-show/src/views/EventComparison/cotwiEc/index.vue
@ -28,7 +28,7 @@ export default {
name: "cotwiEc", name: "cotwiEc",
data() { data() {
return { return {
opt: createSingleColumnar(["事件一", "事件二"], [2200, 1900], "#52bb90"), opt: {},
form: { form: {
token: "", token: "",
sRele: "", sRele: "",
@ -60,7 +60,7 @@ export default {
dx.push(e.key); dx.push(e.key);
ds.push(e.value); ds.push(e.value);
}); });
this.opt = createSingleColumnar(dx, ds,"#52bb90"); this.opt = createSingleColumnar(dx, ds,"#52bb90", 6);
this.load = false; this.load = false;
}); });
}, },

@ -1,7 +1,7 @@
/* /*
* @Author: your name * @Author: your name
* @Date: 2021-10-09 09:49:50 * @Date: 2021-10-09 09:49:50
* @LastEditTime: 2021-10-28 13:07:24 * @LastEditTime: 2021-11-19 18:06:54
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/Index/userPortrait/opt.js * @FilePath: /data-show/src/views/Index/userPortrait/opt.js
@ -37,17 +37,17 @@ export default function createOpt(ds = [], color = []) {
{ {
name: 'Access From0', name: 'Access From0',
type: 'pie', type: 'pie',
radius: ['65%', '80%'], radius: ['60%', '70%'],
avoidLabelOverlap: false, avoidLabelOverlap: false,
label: { label: {
show: false, show: false,
position: 'center', position: 'center',
lineHeight: 30 lineHeight: 36
}, },
emphasis: { emphasis: {
label: { label: {
show: true, show: true,
fontSize: '16', fontSize: '20',
color: "#ffff", color: "#ffff",
fontWeight: 'bold', fontWeight: 'bold',
formatter: function (p) { formatter: function (p) {
@ -63,7 +63,7 @@ export default function createOpt(ds = [], color = []) {
{ {
name: 'Access From1', name: 'Access From1',
type: 'pie', type: 'pie',
radius: ['86%', '94%'], radius: ['72%', '75%'],
avoidLabelOverlap: false, avoidLabelOverlap: false,
label: { label: {
show: false, show: false,

@ -1,7 +1,7 @@
<!-- <!--
* @Author: your name * @Author: your name
* @Date: 2021-11-03 11:54:08 * @Date: 2021-11-03 11:54:08
* @LastEditTime: 2021-11-05 18:50:42 * @LastEditTime: 2021-11-19 17:31:59
* @LastEditors: Please set LastEditors * @LastEditors: Please set LastEditors
* @Description: In User Settings Edit * @Description: In User Settings Edit
* @FilePath: /data-show/src/views/MarketingComparison/mcChooseModel/index.vue * @FilePath: /data-show/src/views/MarketingComparison/mcChooseModel/index.vue
@ -74,6 +74,9 @@ export default {
brand: "", brand: "",
model: "", model: "",
chooseIndex: -1, chooseIndex: -1,
startVal: "",
endValue: "",
offsetDays: 86400000 * 30, //7
form: { form: {
token: "", token: "",
sBrandName: "", sBrandName: "",
@ -168,7 +171,6 @@ export default {
}); });
this.$emit("del", n); this.$emit("del", n);
this.$emit("change", filterArr); this.$emit("change", filterArr);
}, },
// //
handlerBrand(arr) { handlerBrand(arr) {
@ -179,6 +181,19 @@ export default {
}, },
// //
handlerTime(item) { handlerTime(item) {
let t1 = item.startTime ? moment(item.startTime).valueOf() : 0;
let t2 = item.endTime ? moment(item.endTime).valueOf() : 0;
let current = new Date().getTime();
if(t1 > current) {
item.startTime = "";
this.$message.warning("开始时间不能大于当前时间");
return;
}
if(t2 > current) {
item.endTime = "";
this.$message.warning("结束时间不能大于当前时间");
return;
}
if (item.startTime && item.endTime) { if (item.startTime && item.endTime) {
let isBefore = moment(item.startTime).isBefore(item.endTime); let isBefore = moment(item.startTime).isBefore(item.endTime);
if (!isBefore) { if (!isBefore) {
@ -192,6 +207,8 @@ export default {
} }
} }
}, },
}, },
}; };
</script> </script>

Loading…
Cancel
Save