diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/views/system/fileConfiguration/addDDialog.vue b/src/views/system/fileConfiguration/addDDialog.vue
index c953ac5..85d631d 100644
--- a/src/views/system/fileConfiguration/addDDialog.vue
+++ b/src/views/system/fileConfiguration/addDDialog.vue
@@ -89,11 +89,11 @@
}
getFileType()
// 判断文件类型与上传文件是否一致
-const checkFile = () => {
+const checkFile = (type: string) => {
const data = fileTypeList.value.filter((item: any) => item.value === ruleForm.value.fileType)
if (data.length) {
const val = data[0].name
- const fileName = ruleForm.value.minioFileName.split('.')[ruleForm.value.minioFileName.split('.').length - 1]
+ const fileName = type
if (val !== fileName) {
ElMessage.warning('上传文件与所选文件类型不一致')
return false
@@ -107,9 +107,9 @@
await formEl.validate((valid, fields) => {
if (valid) {
if (title.value === '新增') {
- if (!checkFile()) {
- return
- }
+ // if (!checkFile()) {
+ // return
+ // }
addeFileListPage(ruleForm.value).then((res) => {
ElMessage({
type: 'success',
@@ -158,10 +158,16 @@
// 创建formdata对象
const fd = new FormData()
fd.append('multipartFile', event.target.files[0])
+ const type = event.target.files[0].name.split('.')[event.target.files[0].name.split('.').length - 1]
+ if (!checkFile(type)) {
+ fileRef.value.value = ''
+ return
+ }
uploadApi(fd).then((res) => {
if (res.code === 200) {
ruleFormRef.value?.clearValidate('minioFileName')
ruleForm.value.minioFileName = res.data[0]
+ fileRef.value.value = ''
ElMessage.success('上传成功')
}
else {
@@ -193,7 +199,7 @@
-
+
@@ -219,7 +225,7 @@
-
+
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/views/system/fileConfiguration/addDDialog.vue b/src/views/system/fileConfiguration/addDDialog.vue
index c953ac5..85d631d 100644
--- a/src/views/system/fileConfiguration/addDDialog.vue
+++ b/src/views/system/fileConfiguration/addDDialog.vue
@@ -89,11 +89,11 @@
}
getFileType()
// 判断文件类型与上传文件是否一致
-const checkFile = () => {
+const checkFile = (type: string) => {
const data = fileTypeList.value.filter((item: any) => item.value === ruleForm.value.fileType)
if (data.length) {
const val = data[0].name
- const fileName = ruleForm.value.minioFileName.split('.')[ruleForm.value.minioFileName.split('.').length - 1]
+ const fileName = type
if (val !== fileName) {
ElMessage.warning('上传文件与所选文件类型不一致')
return false
@@ -107,9 +107,9 @@
await formEl.validate((valid, fields) => {
if (valid) {
if (title.value === '新增') {
- if (!checkFile()) {
- return
- }
+ // if (!checkFile()) {
+ // return
+ // }
addeFileListPage(ruleForm.value).then((res) => {
ElMessage({
type: 'success',
@@ -158,10 +158,16 @@
// 创建formdata对象
const fd = new FormData()
fd.append('multipartFile', event.target.files[0])
+ const type = event.target.files[0].name.split('.')[event.target.files[0].name.split('.').length - 1]
+ if (!checkFile(type)) {
+ fileRef.value.value = ''
+ return
+ }
uploadApi(fd).then((res) => {
if (res.code === 200) {
ruleFormRef.value?.clearValidate('minioFileName')
ruleForm.value.minioFileName = res.data[0]
+ fileRef.value.value = ''
ElMessage.success('上传成功')
}
else {
@@ -193,7 +199,7 @@
-
+
@@ -219,7 +225,7 @@
-
+
diff --git a/src/views/system/resource/listResource.vue b/src/views/system/resource/listResource.vue
index 6da9413..9789dcc 100644
--- a/src/views/system/resource/listResource.vue
+++ b/src/views/system/resource/listResource.vue
@@ -132,6 +132,7 @@
+
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/views/system/fileConfiguration/addDDialog.vue b/src/views/system/fileConfiguration/addDDialog.vue
index c953ac5..85d631d 100644
--- a/src/views/system/fileConfiguration/addDDialog.vue
+++ b/src/views/system/fileConfiguration/addDDialog.vue
@@ -89,11 +89,11 @@
}
getFileType()
// 判断文件类型与上传文件是否一致
-const checkFile = () => {
+const checkFile = (type: string) => {
const data = fileTypeList.value.filter((item: any) => item.value === ruleForm.value.fileType)
if (data.length) {
const val = data[0].name
- const fileName = ruleForm.value.minioFileName.split('.')[ruleForm.value.minioFileName.split('.').length - 1]
+ const fileName = type
if (val !== fileName) {
ElMessage.warning('上传文件与所选文件类型不一致')
return false
@@ -107,9 +107,9 @@
await formEl.validate((valid, fields) => {
if (valid) {
if (title.value === '新增') {
- if (!checkFile()) {
- return
- }
+ // if (!checkFile()) {
+ // return
+ // }
addeFileListPage(ruleForm.value).then((res) => {
ElMessage({
type: 'success',
@@ -158,10 +158,16 @@
// 创建formdata对象
const fd = new FormData()
fd.append('multipartFile', event.target.files[0])
+ const type = event.target.files[0].name.split('.')[event.target.files[0].name.split('.').length - 1]
+ if (!checkFile(type)) {
+ fileRef.value.value = ''
+ return
+ }
uploadApi(fd).then((res) => {
if (res.code === 200) {
ruleFormRef.value?.clearValidate('minioFileName')
ruleForm.value.minioFileName = res.data[0]
+ fileRef.value.value = ''
ElMessage.success('上传成功')
}
else {
@@ -193,7 +199,7 @@
-
+
@@ -219,7 +225,7 @@
-
+
diff --git a/src/views/system/resource/listResource.vue b/src/views/system/resource/listResource.vue
index 6da9413..9789dcc 100644
--- a/src/views/system/resource/listResource.vue
+++ b/src/views/system/resource/listResource.vue
@@ -132,6 +132,7 @@
+
diff --git a/src/views/tested/MeasurementPlan/plan/components/list.vue b/src/views/tested/MeasurementPlan/plan/components/list.vue
index 0f028d7..975fbcc 100644
--- a/src/views/tested/MeasurementPlan/plan/components/list.vue
+++ b/src/views/tested/MeasurementPlan/plan/components/list.vue
@@ -223,7 +223,12 @@
displayName: item.text,
}
})
- printJSON(list.value, properties, '计量计划列表')
+ if (selectList.value.length) {
+ printJSON(selectList.value, properties, '计量计划列表')
+ }
+ else {
+ printJSON(list.value, properties, '计量计划列表')
+ }
}
else {
ElMessage.warning('无可打印内容')
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/views/system/fileConfiguration/addDDialog.vue b/src/views/system/fileConfiguration/addDDialog.vue
index c953ac5..85d631d 100644
--- a/src/views/system/fileConfiguration/addDDialog.vue
+++ b/src/views/system/fileConfiguration/addDDialog.vue
@@ -89,11 +89,11 @@
}
getFileType()
// 判断文件类型与上传文件是否一致
-const checkFile = () => {
+const checkFile = (type: string) => {
const data = fileTypeList.value.filter((item: any) => item.value === ruleForm.value.fileType)
if (data.length) {
const val = data[0].name
- const fileName = ruleForm.value.minioFileName.split('.')[ruleForm.value.minioFileName.split('.').length - 1]
+ const fileName = type
if (val !== fileName) {
ElMessage.warning('上传文件与所选文件类型不一致')
return false
@@ -107,9 +107,9 @@
await formEl.validate((valid, fields) => {
if (valid) {
if (title.value === '新增') {
- if (!checkFile()) {
- return
- }
+ // if (!checkFile()) {
+ // return
+ // }
addeFileListPage(ruleForm.value).then((res) => {
ElMessage({
type: 'success',
@@ -158,10 +158,16 @@
// 创建formdata对象
const fd = new FormData()
fd.append('multipartFile', event.target.files[0])
+ const type = event.target.files[0].name.split('.')[event.target.files[0].name.split('.').length - 1]
+ if (!checkFile(type)) {
+ fileRef.value.value = ''
+ return
+ }
uploadApi(fd).then((res) => {
if (res.code === 200) {
ruleFormRef.value?.clearValidate('minioFileName')
ruleForm.value.minioFileName = res.data[0]
+ fileRef.value.value = ''
ElMessage.success('上传成功')
}
else {
@@ -193,7 +199,7 @@
-
+
@@ -219,7 +225,7 @@
-
+
diff --git a/src/views/system/resource/listResource.vue b/src/views/system/resource/listResource.vue
index 6da9413..9789dcc 100644
--- a/src/views/system/resource/listResource.vue
+++ b/src/views/system/resource/listResource.vue
@@ -132,6 +132,7 @@
+
diff --git a/src/views/tested/MeasurementPlan/plan/components/list.vue b/src/views/tested/MeasurementPlan/plan/components/list.vue
index 0f028d7..975fbcc 100644
--- a/src/views/tested/MeasurementPlan/plan/components/list.vue
+++ b/src/views/tested/MeasurementPlan/plan/components/list.vue
@@ -223,7 +223,12 @@
displayName: item.text,
}
})
- printJSON(list.value, properties, '计量计划列表')
+ if (selectList.value.length) {
+ printJSON(selectList.value, properties, '计量计划列表')
+ }
+ else {
+ printJSON(list.value, properties, '计量计划列表')
+ }
}
else {
ElMessage.warning('无可打印内容')
diff --git a/src/views/tested/dashboard/components/listApprove.vue b/src/views/tested/dashboard/components/listApprove.vue
index 000477f..50d0e4f 100644
--- a/src/views/tested/dashboard/components/listApprove.vue
+++ b/src/views/tested/dashboard/components/listApprove.vue
@@ -110,7 +110,7 @@
query: {
row: JSON.stringify({ id: row.bizId, equipmentId: row.bizId, taskId: row.taskId }),
id: row.bizId,
- statusName: current.value === '未审批' ? '待审批' : '已审批',
+ statusName: current.value === '未处理' ? '待审批' : '已审批',
},
})
}
@@ -120,7 +120,7 @@
query: {
row: JSON.stringify({ id: row.bizId, equipmentId: row.bizId, taskId: row.taskId }),
id: row.bizId,
- statusName: current.value === '未审批' ? '待审批' : '已审批',
+ statusName: current.value === '未处理' ? '待审批' : '已审批',
},
})
}
diff --git a/src/components/Echart/PieChart.vue b/src/components/Echart/PieChart.vue
index 95a44cc..6855601 100644
--- a/src/components/Echart/PieChart.vue
+++ b/src/components/Echart/PieChart.vue
@@ -153,7 +153,12 @@
*/
hoverFormatter: {
type: String,
- default: '{b}
数量:{c}
占比:{d}%',
+ default: '',
+ },
+ // 总计
+ count: {
+ type: Number,
+ default: 0,
},
})
@@ -190,17 +195,36 @@
// 标题
if (props.title) {
option.title = {
- show: false,
- text: props.title,
- textStyle: {
- color: props.fontColor,
- fontWeight: 'normal',
- fontSize: 16,
- },
- top: 0,
- left: '35%',
- textAlign: 'cenetr',
+ show: !!props.title,
+ // text: props.title,
+ // textStyle: {
+ // color: props.fontColor,
+ // fontWeight: 'normal',
+ // fontSize: 16,
+ // },
+ // top: 0,
+ // left: '35%',
+ // textAlign: 'cenetr',
// right: 'middle',
+ // text: `{name|${total}}\n{val| (处)}`,
+ text: `{name|总计}\n{val| ${props.data.reduce((pre, target) => pre + Number(target.value), 0)}}`,
+ top: 'center',
+ left: 'center',
+ textStyle: {
+ rich: {
+ name: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ padding: [10, 0],
+ },
+ val: {
+ fontSize: 16,
+ fontWeight: 'bold',
+ color: '#000',
+ },
+ },
+ },
}
}
// 标题
@@ -219,10 +243,12 @@
startAngle: 140,
right: props.right,
label: {
+ // avoidLabelOverlap: true,
show: props.labelShow,
- position: props.labelPosition,
- formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n{style2|{d}%}' : '{style1|{b}}\n{style2|{c}}'),
- fontSize: 20,
+ // position: props.labelPosition,
+ // formatter: props.labelFormatter ? props.labelFormatter : (props.valueType == 'percentage' ? '{style1|{b}}\n\n{style2|{d}%}' : '{style1|{b}}\n\n{style2|{c}}'),
+ // formatter
+ fontSize: 14,
fontWeight: 'bold',
rich: {
style1: {
@@ -243,6 +269,14 @@
},
},
},
+ labelLine: {
+ normal: {
+ show: true,
+ length: 25,
+ length2: 15,
+ smooth: true,
+ },
+ },
data: props.data,
}
option.series = [series]
diff --git a/src/router/modules/common.ts b/src/router/modules/common.ts
index 7957fe2..20d7428 100644
--- a/src/router/modules/common.ts
+++ b/src/router/modules/common.ts
@@ -28,31 +28,31 @@
},
],
},
- {
- path: '/resource',
- component: Layout,
- redirect: '/resource/list',
- name: 'ResourceManage',
- meta: {
- title: '资源管理',
- icon: 'ep:key',
- auth: '/sys/resource',
- },
- children: [
- {
- path: 'list',
- name: 'ResourceList',
- component: () => import('@/views/system/resource/listResource.vue'),
- meta: {
- title: '资源管理',
- auth: '/sys/resource',
- sidebar: false,
- breadcrumb: false,
- activeMenu: '/resource',
- },
- },
- ],
- },
+ // {
+ // path: '/resource',
+ // component: Layout,
+ // redirect: '/resource/list',
+ // name: 'ResourceManage',
+ // meta: {
+ // title: '资源管理',
+ // icon: 'ep:key',
+ // auth: '/sys/resource',
+ // },
+ // children: [
+ // {
+ // path: 'list',
+ // name: 'ResourceList',
+ // component: () => import('@/views/system/resource/listResource.vue'),
+ // meta: {
+ // title: '资源管理',
+ // auth: '/sys/resource',
+ // sidebar: false,
+ // breadcrumb: false,
+ // activeMenu: '/resource',
+ // },
+ // },
+ // ],
+ // },
{
path: '/dept',
component: Layout,
diff --git a/src/views/system/expire/device.vue b/src/views/system/expire/device.vue
index 64bef89..11a218d 100644
--- a/src/views/system/expire/device.vue
+++ b/src/views/system/expire/device.vue
@@ -195,7 +195,7 @@
-
+
diff --git a/src/views/system/expire/edit.vue b/src/views/system/expire/edit.vue
index fab17c3..9288444 100644
--- a/src/views/system/expire/edit.vue
+++ b/src/views/system/expire/edit.vue
@@ -249,7 +249,7 @@
-
+ 天
diff --git a/src/views/system/expire/list.vue b/src/views/system/expire/list.vue
index 8a74d99..d3bb96e 100644
--- a/src/views/system/expire/list.vue
+++ b/src/views/system/expire/list.vue
@@ -6,9 +6,9 @@
// 表头
const columns = ref([
{ text: '提醒名称', value: 'remindName', align: 'center' },
- { text: '提醒设备名称', value: 'equipmentNames', align: 'center' },
- { text: '提醒任务名称', value: 'taskNames', align: 'center' },
- { text: '提醒时间', value: 'remindTime', align: 'center' },
+ { text: '设备提醒名称', value: 'equipmentNames', align: 'center' },
+ { text: '任务提醒名称', value: 'taskNames', align: 'center' },
+ { text: '提醒时间(天)', value: 'remindTime', align: 'center' },
])
const list = ref([])
const total = ref(20)
diff --git a/src/views/system/expire/task.vue b/src/views/system/expire/task.vue
index 57015f4..58d83c2 100644
--- a/src/views/system/expire/task.vue
+++ b/src/views/system/expire/task.vue
@@ -127,7 +127,7 @@
-
+
diff --git a/src/views/system/fileConfiguration/addDDialog.vue b/src/views/system/fileConfiguration/addDDialog.vue
index c953ac5..85d631d 100644
--- a/src/views/system/fileConfiguration/addDDialog.vue
+++ b/src/views/system/fileConfiguration/addDDialog.vue
@@ -89,11 +89,11 @@
}
getFileType()
// 判断文件类型与上传文件是否一致
-const checkFile = () => {
+const checkFile = (type: string) => {
const data = fileTypeList.value.filter((item: any) => item.value === ruleForm.value.fileType)
if (data.length) {
const val = data[0].name
- const fileName = ruleForm.value.minioFileName.split('.')[ruleForm.value.minioFileName.split('.').length - 1]
+ const fileName = type
if (val !== fileName) {
ElMessage.warning('上传文件与所选文件类型不一致')
return false
@@ -107,9 +107,9 @@
await formEl.validate((valid, fields) => {
if (valid) {
if (title.value === '新增') {
- if (!checkFile()) {
- return
- }
+ // if (!checkFile()) {
+ // return
+ // }
addeFileListPage(ruleForm.value).then((res) => {
ElMessage({
type: 'success',
@@ -158,10 +158,16 @@
// 创建formdata对象
const fd = new FormData()
fd.append('multipartFile', event.target.files[0])
+ const type = event.target.files[0].name.split('.')[event.target.files[0].name.split('.').length - 1]
+ if (!checkFile(type)) {
+ fileRef.value.value = ''
+ return
+ }
uploadApi(fd).then((res) => {
if (res.code === 200) {
ruleFormRef.value?.clearValidate('minioFileName')
ruleForm.value.minioFileName = res.data[0]
+ fileRef.value.value = ''
ElMessage.success('上传成功')
}
else {
@@ -193,7 +199,7 @@
-
+
@@ -219,7 +225,7 @@
-
+
diff --git a/src/views/system/resource/listResource.vue b/src/views/system/resource/listResource.vue
index 6da9413..9789dcc 100644
--- a/src/views/system/resource/listResource.vue
+++ b/src/views/system/resource/listResource.vue
@@ -132,6 +132,7 @@
+
diff --git a/src/views/tested/MeasurementPlan/plan/components/list.vue b/src/views/tested/MeasurementPlan/plan/components/list.vue
index 0f028d7..975fbcc 100644
--- a/src/views/tested/MeasurementPlan/plan/components/list.vue
+++ b/src/views/tested/MeasurementPlan/plan/components/list.vue
@@ -223,7 +223,12 @@
displayName: item.text,
}
})
- printJSON(list.value, properties, '计量计划列表')
+ if (selectList.value.length) {
+ printJSON(selectList.value, properties, '计量计划列表')
+ }
+ else {
+ printJSON(list.value, properties, '计量计划列表')
+ }
}
else {
ElMessage.warning('无可打印内容')
diff --git a/src/views/tested/dashboard/components/listApprove.vue b/src/views/tested/dashboard/components/listApprove.vue
index 000477f..50d0e4f 100644
--- a/src/views/tested/dashboard/components/listApprove.vue
+++ b/src/views/tested/dashboard/components/listApprove.vue
@@ -110,7 +110,7 @@
query: {
row: JSON.stringify({ id: row.bizId, equipmentId: row.bizId, taskId: row.taskId }),
id: row.bizId,
- statusName: current.value === '未审批' ? '待审批' : '已审批',
+ statusName: current.value === '未处理' ? '待审批' : '已审批',
},
})
}
@@ -120,7 +120,7 @@
query: {
row: JSON.stringify({ id: row.bizId, equipmentId: row.bizId, taskId: row.taskId }),
id: row.bizId,
- statusName: current.value === '未审批' ? '待审批' : '已审批',
+ statusName: current.value === '未处理' ? '待审批' : '已审批',
},
})
}
diff --git a/src/views/tested/dashboard/index.vue b/src/views/tested/dashboard/index.vue
index 1982176..3c829a9 100644
--- a/src/views/tested/dashboard/index.vue
+++ b/src/views/tested/dashboard/index.vue
@@ -589,7 +589,7 @@
-
+
@@ -605,7 +605,7 @@
>
-
![]()
+
{{ item.name }}
@@ -631,9 +631,9 @@
-