config&配置&原料磨
This commit is contained in:
parent
748fa2479a
commit
aea01b7df0
Binary file not shown.
Before Width: | Height: | Size: 286 KiB |
Binary file not shown.
After Width: | Height: | Size: 493 KiB |
|
@ -2,6 +2,15 @@ import config from "@/config"
|
||||||
import http from "@/utils/request"
|
import http from "@/utils/request"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
config:{
|
||||||
|
base: {
|
||||||
|
url: `${config.API_URL}/system/base_config/`,
|
||||||
|
name: "账户信息",
|
||||||
|
req: async function(){
|
||||||
|
return await http.get(this.url);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
dept: {
|
dept: {
|
||||||
list: {
|
list: {
|
||||||
url: `${config.API_URL}/system/dept/`,
|
url: `${config.API_URL}/system/dept/`,
|
||||||
|
@ -392,5 +401,21 @@ export default {
|
||||||
return await http.get(this.url, params);
|
return await http.get(this.url, params);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
baseInfo: {
|
||||||
|
getInfo: {
|
||||||
|
url: `${config.API_URL}/system/config/`,
|
||||||
|
name: "获取系统信息",
|
||||||
|
req: async function(){
|
||||||
|
return await http.get(this.url);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
updateInfo: {
|
||||||
|
url: `${config.API_URL}/system/config/`,
|
||||||
|
name: "更新系统信息",
|
||||||
|
req: async function(data){
|
||||||
|
return await http.put(this.url, data);
|
||||||
|
}
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,284 @@
|
||||||
|
<template>
|
||||||
|
<el-dialog v-model="visible" :fullscreen="isFullscreen" v-bind="$attrs" :show-close="showClose">
|
||||||
|
<template #header>
|
||||||
|
<slot name="header">
|
||||||
|
<span class="el-dialog__title">{{ title }}</span>
|
||||||
|
</slot>
|
||||||
|
<div class="sc-dialog__headerbtn">
|
||||||
|
<button v-if="showFullscreen" aria-label="fullscreen" type="button" @click="setFullscreen">
|
||||||
|
<el-icon v-if="isFullscreen" class="el-dialog__close"><el-icon-bottom-left /></el-icon>
|
||||||
|
<el-icon v-else class="el-dialog__close"><el-icon-full-screen /></el-icon>
|
||||||
|
</button>
|
||||||
|
<button v-if="showClose" aria-label="close" type="button" @click="closeDialog">
|
||||||
|
<el-icon class="el-dialog__close"></el-icon>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<div v-loading="loading">
|
||||||
|
<div class="searchHead" v-if="type=='hours'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
placeholder="选择时间"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<span class="middleText">至</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='days'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='month'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="开始月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="结束月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='year'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="year"
|
||||||
|
format="YYYY"
|
||||||
|
value-format="YYYY"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="year"
|
||||||
|
format="YYYY"
|
||||||
|
value-format="YYYY"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div id="myChart" style="width:100%;height:400px;"></div>
|
||||||
|
</div>
|
||||||
|
<template #footer>
|
||||||
|
<slot name="footer"></slot>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
|
||||||
|
import * as echarts from 'echarts';
|
||||||
|
export default {
|
||||||
|
props: {
|
||||||
|
type: { type: String, default: "hours" },
|
||||||
|
title: { type: String, default: "" },
|
||||||
|
apiObj: { type: Object, default: () => { } },
|
||||||
|
showClose: { type: Boolean, default: true },
|
||||||
|
echartType: { type: String, default: 'bar' },
|
||||||
|
modelValue: { type: Boolean, default: false },
|
||||||
|
showFullscreen: { type: Boolean, default: true },
|
||||||
|
loading: { type: Boolean, default: false }
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
visible: false,
|
||||||
|
isFullscreen: false,
|
||||||
|
query:{
|
||||||
|
time:''
|
||||||
|
},
|
||||||
|
myChart:null,
|
||||||
|
option: {
|
||||||
|
title: {
|
||||||
|
text: '折线图',
|
||||||
|
subtext: '小标题',
|
||||||
|
x: 'center'
|
||||||
|
},
|
||||||
|
grid: { // 图表距离边框的距离,可用百分比和数字(px)配置
|
||||||
|
top: '20%',
|
||||||
|
left: '3%',
|
||||||
|
right: '10%',
|
||||||
|
bottom: '5%',
|
||||||
|
containLabel: true
|
||||||
|
},
|
||||||
|
legend: { // 图例配置选项
|
||||||
|
orient: 'horizontal', //图例布局方式:水平 'horizontal' 、垂直 'vertical'
|
||||||
|
x: 'right', // 横向放置位置,选项:'center'、'left'、'right'、'number'(横向值 px)
|
||||||
|
y: '10',// 纵向放置位置,选项:'top'、'bottom'、'center'、'number'(纵向值 px)
|
||||||
|
data: ['查询对象'],
|
||||||
|
},
|
||||||
|
xAxis: {
|
||||||
|
type: 'category',
|
||||||
|
data: ['1','2','3','4','5','6','7','8','9','10','11','12'],
|
||||||
|
name: '时间',
|
||||||
|
// x轴名称样式
|
||||||
|
nameTextStyle: {
|
||||||
|
fontWeight: 600,
|
||||||
|
fontSize: 14
|
||||||
|
},
|
||||||
|
axisLine: {
|
||||||
|
lineStyle: { // X 轴颜色配置
|
||||||
|
color: '#3366CC'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
axisLabel: {
|
||||||
|
rotate: 45, // X 轴标签文字旋转角度
|
||||||
|
interval: 0 //设置 X 轴数据间隔几个显示一个,为0表示都显示
|
||||||
|
},
|
||||||
|
boundaryGap: false, //数据从 Y 轴起始
|
||||||
|
},
|
||||||
|
yAxis: {
|
||||||
|
type: 'value',
|
||||||
|
name: '对象值',
|
||||||
|
// y轴名称样式
|
||||||
|
nameTextStyle: {
|
||||||
|
fontWeight: 500,
|
||||||
|
fontSize: 14
|
||||||
|
},
|
||||||
|
//min:0, // 配置 Y 轴刻度最小值
|
||||||
|
//max:4000, // 配置 Y 轴刻度最大值
|
||||||
|
//splitNumber:7, // 配置 Y 轴数值间隔
|
||||||
|
axisLine: {
|
||||||
|
lineStyle: { // Y 轴颜色配置
|
||||||
|
color: '#3366CC'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
tooltip: {
|
||||||
|
show: true, // 是否显示
|
||||||
|
trigger: 'axis', // axis item none
|
||||||
|
axisPointer: { // 坐标轴指示器配置项。
|
||||||
|
type: 'cross', // 'line' 直线指示器 'shadow' 阴影指示器 'none' 无指示器 'cross' 十字准星指示器。
|
||||||
|
axis: 'auto', // 指示器的坐标轴。
|
||||||
|
snap: true, // 坐标轴指示器是否自动吸附到点上
|
||||||
|
},
|
||||||
|
showContent: true,
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: '查询对象',
|
||||||
|
data: [4,1,9,2,11,3,5,7,8,10,6,12],
|
||||||
|
type: 'line',
|
||||||
|
// symbolSize: function(value) { // 点的大小跟随数值增加而变大
|
||||||
|
// return value / 150;
|
||||||
|
// },
|
||||||
|
symbolSize:8, //设置折线上圆点大小
|
||||||
|
symbol:'circle',
|
||||||
|
smooth: 0.5, // 设置折线弧度
|
||||||
|
itemStyle: {
|
||||||
|
normal: {
|
||||||
|
label : {
|
||||||
|
show: true // 在折线拐点上显示数据
|
||||||
|
},
|
||||||
|
lineStyle:{
|
||||||
|
width:1, // 设置虚线宽度
|
||||||
|
type:'dotted', // 虚线'dotted' 实线'solid'
|
||||||
|
color: '#3366CC'// 折线颜色设置为0,即只显示点,不显示折线
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
]
|
||||||
|
},
|
||||||
|
pickerOptions: {
|
||||||
|
disabledDate(time) {
|
||||||
|
return time.getTime() > Date.now();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch:{
|
||||||
|
modelValue(){
|
||||||
|
this.visible = this.modelValue
|
||||||
|
if(this.visible){
|
||||||
|
this.isFullscreen = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
console.log(this.type);
|
||||||
|
console.log(this.title);
|
||||||
|
console.log(this.echartType);
|
||||||
|
this.visible = this.modelValue;
|
||||||
|
this.$nextTick(res=>{
|
||||||
|
this.getChartsData();
|
||||||
|
})
|
||||||
|
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async getChartsData(){
|
||||||
|
let that = this;
|
||||||
|
// var res = await this.apiObj.req(this.query);
|
||||||
|
let chartDom = document.getElementById('myChart');
|
||||||
|
that.myChart = echarts.init(chartDom);
|
||||||
|
// var option = {};
|
||||||
|
that.myChart.setOption(that.option);
|
||||||
|
},
|
||||||
|
//关闭
|
||||||
|
closeDialog(){
|
||||||
|
this.visible = false;
|
||||||
|
|
||||||
|
},
|
||||||
|
//最大化
|
||||||
|
setFullscreen(){
|
||||||
|
this.isFullscreen = !this.isFullscreen
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.searchHead{
|
||||||
|
display:flex
|
||||||
|
}
|
||||||
|
.middleText{
|
||||||
|
height: 32px;
|
||||||
|
line-height: 32px;
|
||||||
|
margin: 0 5px;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
.searchBtn{
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
.sc-dialog__headerbtn {position: absolute;top: var(--el-dialog-padding-primary);right: var(--el-dialog-padding-primary);}
|
||||||
|
.sc-dialog__headerbtn button {padding: 0;background: transparent;border: none;outline: none;cursor: pointer;font-size: var(--el-message-close-size,16px);margin-left: 15px;color: var(--el-color-info);}
|
||||||
|
.sc-dialog__headerbtn button:hover .el-dialog__close {color: var(--el-color-primary);}
|
||||||
|
.sc-dialog:deep(.el-dialog).is-fullscreen {display: flex;flex-direction: column;top:0px !important;left:0px !important;}
|
||||||
|
.sc-dialog:deep(.el-dialog).is-fullscreen .el-dialog__header {}
|
||||||
|
.sc-dialog:deep(.el-dialog).is-fullscreen .el-dialog__body {flex:1;overflow: auto;}
|
||||||
|
.sc-dialog:deep(.el-dialog).is-fullscreen .el-dialog__footer {padding-bottom: 10px;border-top: 1px solid var(--el-border-color-base);}
|
||||||
|
</style>
|
|
@ -114,6 +114,78 @@ const routes = [
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "rm",
|
||||||
|
"path": "/rm",
|
||||||
|
"meta": {
|
||||||
|
"title": "原料磨",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"type": "menu",
|
||||||
|
"perms": ["bi"]
|
||||||
|
},
|
||||||
|
"children": [
|
||||||
|
{
|
||||||
|
"name": "report",
|
||||||
|
"path": "/rm/report",
|
||||||
|
"meta": {
|
||||||
|
"title": "生产报告",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/report"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "power",
|
||||||
|
"path": "/rm/power",
|
||||||
|
"meta": {
|
||||||
|
"title": "单位产品电耗",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/power"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "teamAnalysis",
|
||||||
|
"path": "/rm/teamAnalysis",
|
||||||
|
"meta": {
|
||||||
|
"title": "班组月度对比",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/teamAnalysis"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "workshopAnalysis",
|
||||||
|
"path": "/rm/workshopAnalysis",
|
||||||
|
"meta": {
|
||||||
|
"title": "车间单耗分析",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/workshopAnalysis"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "handoverLog",
|
||||||
|
"path": "/rm/handoverLog",
|
||||||
|
"meta": {
|
||||||
|
"title": "交接班日志",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/handoverLog"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "handovereEnter",
|
||||||
|
"path": "/rm/handovereEnter",
|
||||||
|
"meta": {
|
||||||
|
"title": "交接班记录",
|
||||||
|
"icon": "el-icon-grid",
|
||||||
|
"perms": ["dataset"]
|
||||||
|
},
|
||||||
|
"component": "rm/handovereEnter"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "em",
|
"name": "em",
|
||||||
"path": "/em",
|
"path": "/em",
|
||||||
|
@ -218,7 +290,6 @@ const routes = [
|
||||||
},
|
},
|
||||||
"component": "ecm/notify_setting"
|
"component": "ecm/notify_setting"
|
||||||
},
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
"name": "algo",
|
"name": "algo",
|
||||||
"path": "/ecm/algo",
|
"path": "/ecm/algo",
|
||||||
|
|
|
@ -31,8 +31,8 @@
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
hasChildren(item) {
|
hasChildren(item) {
|
||||||
console.log(item)
|
// console.log(item)
|
||||||
console.log(item.children && !item.children.every(item => item.meta.hidden))
|
// console.log(item.children && !item.children.every(item => item.meta.hidden))
|
||||||
return item.children && !item.children.every(item => item.meta.hidden)
|
return item.children && !item.children.every(item => item.meta.hidden)
|
||||||
},
|
},
|
||||||
blankPageClick(path){
|
blankPageClick(path){
|
||||||
|
@ -41,8 +41,8 @@
|
||||||
// let linkUrl = window.location.origin+"/#"+path;
|
// let linkUrl = window.location.origin+"/#"+path;
|
||||||
|
|
||||||
let routeUrl = this.$router.resolve({path: path});
|
let routeUrl = this.$router.resolve({path: path});
|
||||||
console.log(routeUrl.href)
|
// console.log(routeUrl.href)
|
||||||
debugger;
|
// debugger;
|
||||||
window.open(routeUrl.href);
|
window.open(routeUrl.href);
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,8 +4,10 @@
|
||||||
<header class="adminui-header">
|
<header class="adminui-header">
|
||||||
<div class="adminui-header-left">
|
<div class="adminui-header-left">
|
||||||
<div class="logo-bar">
|
<div class="logo-bar">
|
||||||
<img class="logo" src="img/bbmg1.png">
|
<!-- <img class="logo" src="img/bbmg1.png"> -->
|
||||||
<span>{{ $CONFIG.APP_NAME }}</span>
|
<!-- <span>{{ $CONFIG.APP_NAME }}</span> -->
|
||||||
|
<img class="logo" :src="baseLogo">
|
||||||
|
<span>{{ baseName }}</span>
|
||||||
</div>
|
</div>
|
||||||
<ul v-if="!ismobile" class="nav">
|
<ul v-if="!ismobile" class="nav">
|
||||||
<li v-for="item in menu" :key="item" :class="pmenu.path==item.path?'active':''" @click="showMenu(item)">
|
<li v-for="item in menu" :key="item" :class="pmenu.path==item.path?'active':''" @click="showMenu(item)">
|
||||||
|
@ -55,8 +57,10 @@
|
||||||
<header class="adminui-header">
|
<header class="adminui-header">
|
||||||
<div class="adminui-header-left">
|
<div class="adminui-header-left">
|
||||||
<div class="logo-bar">
|
<div class="logo-bar">
|
||||||
<img class="logo" src="img/bbmg.jpg">
|
<!-- <img class="logo" src="img/bbmg.jpg">
|
||||||
<span>{{ $CONFIG.APP_NAME }}</span>
|
<span>{{ $CONFIG.APP_NAME }}</span> -->
|
||||||
|
<img class="logo" :src="baseLogo">
|
||||||
|
<span>{{ baseName }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="adminui-header-right">
|
<div class="adminui-header-right">
|
||||||
|
@ -223,6 +227,12 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed:{
|
computed:{
|
||||||
|
baseName(){
|
||||||
|
return this.$TOOL.data.get("BASE_INFO").base.base_name;
|
||||||
|
},
|
||||||
|
baseLogo(){
|
||||||
|
return this.$TOOL.data.get("BASE_INFO").base.base_logo
|
||||||
|
},
|
||||||
ismobile(){
|
ismobile(){
|
||||||
return this.$store.state.global.ismobile
|
return this.$store.state.global.ismobile
|
||||||
},
|
},
|
||||||
|
@ -237,6 +247,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
document.title = this.$store.state.global.baseName
|
||||||
this.onLayoutResize();
|
this.onLayoutResize();
|
||||||
window.addEventListener('resize', this.onLayoutResize);
|
window.addEventListener('resize', this.onLayoutResize);
|
||||||
var menu = this.$router.sc_getMenu();
|
var menu = this.$router.sc_getMenu();
|
||||||
|
|
|
@ -12,8 +12,17 @@ export default {
|
||||||
layoutTags: config.LAYOUT_TAGS,
|
layoutTags: config.LAYOUT_TAGS,
|
||||||
//主题
|
//主题
|
||||||
theme: config.THEME,
|
theme: config.THEME,
|
||||||
|
//系统名称
|
||||||
|
baseName:config.APP_NAME,
|
||||||
|
baseLogo:'/media/default/logo.png',
|
||||||
},
|
},
|
||||||
mutations: {
|
mutations: {
|
||||||
|
SET_baseName(state, key) {
|
||||||
|
state.baseName = key;
|
||||||
|
},
|
||||||
|
SET_baseLogo(state, key) {
|
||||||
|
state.baseLogo = key;
|
||||||
|
},
|
||||||
SET_ismobile(state, key){
|
SET_ismobile(state, key){
|
||||||
state.ismobile = key
|
state.ismobile = key
|
||||||
},
|
},
|
||||||
|
|
|
@ -316,7 +316,7 @@ export default {
|
||||||
mounted() {
|
mounted() {
|
||||||
let that = this;
|
let that = this;
|
||||||
let host = window.location.host;
|
let host = window.location.host;
|
||||||
let jsUrl = host.indexOf('localhost')>-1?'http://222.222.144.147:6013/jsmap/jsmap.js':host+'/jsmap/jsmap.js';
|
let jsUrl = '/jsmap/jsmap.js';
|
||||||
that.loadScript('mapId',jsUrl, () => {
|
that.loadScript('mapId',jsUrl, () => {
|
||||||
that.canUseMap = true;
|
that.canUseMap = true;
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,85 +1,83 @@
|
||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-aside width="40%">
|
<el-aside width="40%">
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-header>
|
<el-header>
|
||||||
<div class="left-panel">
|
<div class="left-panel">
|
||||||
<el-button type="primary" icon="el-icon-plus" @click="add" v-auth="'dataset.create'"></el-button>
|
<el-button type="primary" icon="el-icon-plus" @click="add" v-auth="'dataset.create'"></el-button>
|
||||||
</div>
|
|
||||||
<div class="right-panel">
|
|
||||||
<div class="right-panel-search">
|
|
||||||
<el-input
|
|
||||||
v-model="query.search"
|
|
||||||
placeholder="名称"
|
|
||||||
clearable
|
|
||||||
@keyup.enter="handleQuery"
|
|
||||||
></el-input>
|
|
||||||
<el-button
|
|
||||||
type="primary"
|
|
||||||
icon="el-icon-search"
|
|
||||||
@click="handleQuery"
|
|
||||||
></el-button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<div class="right-panel">
|
||||||
</el-header>
|
<div class="right-panel-search">
|
||||||
<el-main class="nopadding">
|
<el-input
|
||||||
<scTable
|
v-model="query.search"
|
||||||
ref="table"
|
placeholder="名称"
|
||||||
:apiObj="apiObj"
|
clearable
|
||||||
row-key="id"
|
@keyup.enter="handleQuery"
|
||||||
|
></el-input>
|
||||||
stripe
|
|
||||||
|
|
||||||
>
|
|
||||||
<el-table-column label="#" type="index" width="50"></el-table-column>
|
|
||||||
<el-table-column label="名称" prop="name" width="200" :show-overflow-tooltip="true"></el-table-column>
|
|
||||||
<el-table-column label="sql语句" prop="sql_query" :show-overflow-tooltip="true"></el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="left" width="200">
|
|
||||||
<template #default="scope">
|
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
plain
|
icon="el-icon-search"
|
||||||
size="small"
|
@click="handleQuery"
|
||||||
@click="handleShow(scope.row)"
|
></el-button>
|
||||||
v-auth="'dataset.exec'"
|
</div>
|
||||||
>预览</el-button
|
</div>
|
||||||
>
|
</el-header>
|
||||||
|
<el-main class="nopadding">
|
||||||
|
<scTable
|
||||||
|
ref="table"
|
||||||
|
:apiObj="apiObj"
|
||||||
|
row-key="id"
|
||||||
|
stripe
|
||||||
|
>
|
||||||
|
<el-table-column label="#" type="index" width="50"></el-table-column>
|
||||||
|
<el-table-column label="名称" prop="name" width="200" :show-overflow-tooltip="true"></el-table-column>
|
||||||
|
<el-table-column label="sql语句" prop="sql_query" :show-overflow-tooltip="true"></el-table-column>
|
||||||
|
<el-table-column label="操作" fixed="right" align="left" width="200">
|
||||||
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
plain
|
type="primary"
|
||||||
type="warning"
|
plain
|
||||||
size="small"
|
size="small"
|
||||||
@click="table_edit(scope.row, scope.$index)"
|
@click="handleShow(scope.row)"
|
||||||
v-auth="'dataset.update'"
|
v-auth="'dataset.exec'"
|
||||||
>编辑</el-button
|
>预览</el-button
|
||||||
>
|
>
|
||||||
<el-popconfirm
|
<el-button
|
||||||
title="确定删除吗?"
|
plain
|
||||||
@confirm="table_del(scope.row, scope.$index)"
|
type="warning"
|
||||||
>
|
size="small"
|
||||||
<template #reference>
|
@click="table_edit(scope.row, scope.$index)"
|
||||||
<el-button plain type="danger" size="small" v-auth="'dataset.delete'">删除</el-button>
|
v-auth="'dataset.update'"
|
||||||
</template>
|
>编辑</el-button
|
||||||
</el-popconfirm>
|
>
|
||||||
</template>
|
<el-popconfirm
|
||||||
</el-table-column>
|
title="确定删除吗?"
|
||||||
</scTable>
|
@confirm="table_del(scope.row, scope.$index)"
|
||||||
</el-main>
|
>
|
||||||
</el-container>
|
<template #reference>
|
||||||
</el-aside>
|
<el-button plain type="danger" size="small" v-auth="'dataset.delete'">删除</el-button>
|
||||||
<el-main>
|
</template>
|
||||||
<div style="background-color: white;">
|
</el-popconfirm>
|
||||||
<scEcharts height="360px" :option="myOption" v-if="chartShow"></scEcharts>
|
</template>
|
||||||
</div>
|
</el-table-column>
|
||||||
</el-main>
|
</scTable>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</el-aside>
|
||||||
|
<el-main>
|
||||||
|
<div style="background-color: white;">
|
||||||
|
<scEcharts height="360px" :option="myOption" v-if="chartShow"></scEcharts>
|
||||||
|
</div>
|
||||||
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<save-dialog
|
<save-dialog
|
||||||
v-if="dialog.save"
|
v-if="dialog.save"
|
||||||
ref="saveDialog"
|
ref="saveDialog"
|
||||||
@success="handleSaveSuccess"
|
@success="handleSaveSuccess"
|
||||||
@closed="dialog.save = false"
|
@closed="dialog.save = false"
|
||||||
></save-dialog>
|
></save-dialog>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import scEcharts from "@/components/scEcharts";
|
import scEcharts from "@/components/scEcharts";
|
||||||
import saveDialog from "./dataset_form.vue";
|
import saveDialog from "./dataset_form.vue";
|
||||||
export default {
|
export default {
|
||||||
|
@ -109,22 +107,33 @@
|
||||||
datasetID:"",
|
datasetID:"",
|
||||||
adminvisible:false,
|
adminvisible:false,
|
||||||
|
|
||||||
//验证规则
|
//验证规则
|
||||||
rules: {
|
rules: {
|
||||||
phone: [
|
phone: [
|
||||||
{required: true, message: '请输入'}
|
{required: true, message: '请输入'}
|
||||||
],
|
],
|
||||||
name: [
|
name: [
|
||||||
{required: true, message: '请输入'}
|
{required: true, message: '请输入'}
|
||||||
],
|
],
|
||||||
username: [
|
username: [
|
||||||
{required: true, message: '请输入'}
|
{required: true, message: '请输入'}
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
Func(func,res){
|
||||||
|
var _this = "_this";
|
||||||
|
var dom = new Function(`return ${func}`)();
|
||||||
|
console.log(dom,'dom');
|
||||||
|
dom && dom(_this,res);
|
||||||
|
},
|
||||||
handleShow(row) {
|
handleShow(row) {
|
||||||
|
// var func = 'function test(_this,res){res.name="sj";console.log(res,"===",_this)}';
|
||||||
|
// var res = {name:'***',age:'21',sex:1,list:[1,2,3]};
|
||||||
|
// debugger;
|
||||||
|
// console.log(func)
|
||||||
|
// this.Func(func,res);
|
||||||
// this.$router.push({
|
// this.$router.push({
|
||||||
// path: "graph",
|
// path: "graph",
|
||||||
// query: {
|
// query: {
|
||||||
|
@ -136,6 +145,8 @@
|
||||||
.req(row.id)
|
.req(row.id)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
this.myOption = JSON.parse(res.echart_options);
|
this.myOption = JSON.parse(res.echart_options);
|
||||||
|
debugger;
|
||||||
|
console.log(this.myOption)
|
||||||
this.chartShow = true;
|
this.chartShow = true;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<div class="screen-main">
|
<div class="screen-main">
|
||||||
<!--头部展示-->
|
<!--头部展示-->
|
||||||
<div class="screen-header">
|
<div class="screen-header">
|
||||||
<div class="header-left-bg">曲阳金隅智能安全管控系统</div>
|
<div class="header-left-bg">{{$store.state.global.baseName}}</div>
|
||||||
<div class="header-right-action">
|
<div class="header-right-action">
|
||||||
<div class="right-action-clock">
|
<div class="right-action-clock">
|
||||||
<span class="action-time">{{ currentDay }}</span>
|
<span class="action-time">{{ currentDay }}</span>
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="login_bg">
|
<div class="login_bg">
|
||||||
<div class="login_adv" style="background-image: url(img/auth_banner.jpg);">
|
<!-- <div class="right-con" :style="{backgroundImage: 'url(' + baseConfig.base_logo + ')'}"></div> -->
|
||||||
|
<div class="login_adv" :style="{'background-image':baseConfig.base_logo_side==''?'url(img/logo_side.png)':'url('+baseConfig.base_logo_side+')'}">
|
||||||
<div class="login_adv__title">
|
<div class="login_adv__title">
|
||||||
<h2>曲阳金隅智能安全管控平台</h2>
|
<h2 v-if="baseConfig.base_name">{{baseConfig.base_name}}</h2>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="login_adv__mask"></div>
|
<div class="login_adv__mask"></div>
|
||||||
<div class="login_adv__bottom">
|
<div class="login_adv__bottom">
|
||||||
|
@ -17,9 +17,9 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="login-form">
|
<div class="login-form">
|
||||||
<div class="login-header">
|
<div class="login-header">
|
||||||
<div class="logo">
|
<div class="logo" v-if="baseConfig.base_name">
|
||||||
<img :alt="$CONFIG.APP_NAME" src="img/bbmg.jpg">
|
<img :alt="baseConfig.base_name" :src="'http://49.232.14.174:2226/'+baseConfig.base_logo">
|
||||||
<label>{{$CONFIG.APP_NAME}}</label>
|
<label>{{baseConfig.base_name}}</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<el-tabs>
|
<el-tabs>
|
||||||
|
@ -38,7 +38,7 @@
|
||||||
<el-button type="success" icon="sc-icon-wechat" circle @click="wechatLogin"></el-button>
|
<el-button type="success" icon="sc-icon-wechat" circle @click="wechatLogin"></el-button>
|
||||||
</div>
|
</div>
|
||||||
-->
|
-->
|
||||||
<div class="login-oauth">
|
<div class="login-oauth" v-if="baseConfig.base_name=='曲阳金隅安全智能管控平台'">
|
||||||
<el-button type="default" @click="appDown">安卓APP</el-button>
|
<el-button type="default" @click="appDown">安卓APP</el-button>
|
||||||
<el-button type="default" @click="h5Show">H5访问</el-button>
|
<el-button type="default" @click="h5Show">H5访问</el-button>
|
||||||
<el-button type="primary" @click="MonitorOpen" style="background-color:orange;border-color:orange">监控视频</el-button>
|
<el-button type="primary" @click="MonitorOpen" style="background-color:orange;border-color:orange">监控视频</el-button>
|
||||||
|
@ -93,6 +93,7 @@ import passwordForm from './components/passwordForm'
|
||||||
value: 'en',
|
value: 'en',
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
baseConfig:{},
|
||||||
WechatLoginCode: "",
|
WechatLoginCode: "",
|
||||||
showWechatLogin: false,
|
showWechatLogin: false,
|
||||||
isWechatLoginResult: false,
|
isWechatLoginResult: false,
|
||||||
|
@ -127,9 +128,24 @@ import passwordForm from './components/passwordForm'
|
||||||
this.$store.commit("clearViewTags")
|
this.$store.commit("clearViewTags")
|
||||||
this.$store.commit("clearKeepLive")
|
this.$store.commit("clearKeepLive")
|
||||||
this.$store.commit("clearIframeList")
|
this.$store.commit("clearIframeList")
|
||||||
console.log('%c SCUI %c Gitee: https://gitee.com/lolicode/scui', 'background:#666;color:#fff;border-radius:3px;', '')
|
|
||||||
|
//console.log('%c SCUI %c Gitee: https://gitee.com/lolicode/scui', 'background:#666;color:#fff;border-radius:3px;', '')
|
||||||
|
},
|
||||||
|
mounted(){
|
||||||
|
this.getDept();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
getDept(){
|
||||||
|
let that = this;
|
||||||
|
that.$API.system.config.base.req().then((res) => {
|
||||||
|
// debugger;
|
||||||
|
console.log(res)
|
||||||
|
that.baseConfig = res.base;
|
||||||
|
this.$store.commit("SET_baseName", res.base.base_name);
|
||||||
|
this.$store.commit("SET_baseLogo", res.base.base_logo);
|
||||||
|
this.$TOOL.data.set("BASE_INFO", res)
|
||||||
|
})
|
||||||
|
},
|
||||||
appDown() {
|
appDown() {
|
||||||
this.showApp = true;
|
this.showApp = true;
|
||||||
},
|
},
|
||||||
|
@ -169,13 +185,13 @@ import passwordForm from './components/passwordForm'
|
||||||
.login_adv__title div i {font-size: 40px;}
|
.login_adv__title div i {font-size: 40px;}
|
||||||
.login_adv__title div i.add {font-size: 20px;color: rgba(255,255,255,0.6);}
|
.login_adv__title div i.add {font-size: 20px;color: rgba(255,255,255,0.6);}
|
||||||
.login_adv__bottom {position: absolute;left:0px;right: 0px;bottom: 0px;color: #fff;padding: 40px;background-image:linear-gradient(transparent, #000);z-index: 3;}
|
.login_adv__bottom {position: absolute;left:0px;right: 0px;bottom: 0px;color: #fff;padding: 40px;background-image:linear-gradient(transparent, #000);z-index: 3;}
|
||||||
.login_adv__mask {position: absolute;top:0px;left:0px;right: 0px;bottom: 0px;background: rgba(0,0,0,0.5);z-index: 1;}
|
.login_adv__mask {position: absolute;top:0px;left:0px;right: 0px;bottom: 0px;z-index: 1;}
|
||||||
|
|
||||||
.login_main {flex: 1;overflow: auto;display:flex;}
|
.login_main {flex: 1;overflow: auto;display:flex;}
|
||||||
.login-form {width: 410px;margin: auto;padding:20px 0;}
|
.login-form {width: 410px;margin: auto;padding:20px 0;}
|
||||||
.login-header {margin-bottom: 40px; width: 460px;margin-left: -30px;}
|
.login-header {margin-bottom: 40px; width: 460px;margin-left: -30px;}
|
||||||
.login-header .logo {display: flex;align-items: center;}
|
.login-header .logo {display: flex;align-items: center;}
|
||||||
.login-header .logo img {width: 120px;height: 90px;vertical-align: bottom;margin-right: 10px;}
|
.login-header .logo img {width: 180px;vertical-align: bottom;margin-right: 10px;}
|
||||||
.login-header .logo label {font-size: 26px;font-weight: bold;}
|
.login-header .logo label {font-size: 26px;font-weight: bold;}
|
||||||
.login-oauth {display: flex;justify-content:space-around;}
|
.login-oauth {display: flex;justify-content:space-around;}
|
||||||
.login-form .el-divider {margin-top:40px;}
|
.login-form .el-divider {margin-top:40px;}
|
||||||
|
|
|
@ -1,57 +1,127 @@
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container class="page-user">
|
||||||
|
<el-aside style="width: 240px">
|
||||||
|
<el-container>
|
||||||
|
<el-header style="height: auto; display: block">
|
||||||
|
<div class="user-info-top">
|
||||||
|
<el-avatar
|
||||||
|
:size="100"
|
||||||
|
:src="$store.state.global.baseLogo"
|
||||||
|
shape="square"
|
||||||
|
></el-avatar>
|
||||||
|
<h3>{{ $store.state.global.baseName }}</h3>
|
||||||
|
</div>
|
||||||
|
</el-header>
|
||||||
|
<el-main class="nopadding">
|
||||||
|
<el-menu class="menu" :default-active="page">
|
||||||
|
<el-menu-item-group
|
||||||
|
v-for="group in menu"
|
||||||
|
:key="group.groupName"
|
||||||
|
:title="group.groupName"
|
||||||
|
>
|
||||||
|
<el-menu-item
|
||||||
|
v-for="item in group.list"
|
||||||
|
:key="item.component"
|
||||||
|
:index="item.component"
|
||||||
|
@click="openPage"
|
||||||
|
>
|
||||||
|
<el-icon v-if="item.icon"
|
||||||
|
><component :is="item.icon"
|
||||||
|
/></el-icon>
|
||||||
|
<template #title>
|
||||||
|
<span>{{ item.title }}</span>
|
||||||
|
</template>
|
||||||
|
</el-menu-item>
|
||||||
|
</el-menu-item-group>
|
||||||
|
</el-menu>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</el-aside>
|
||||||
<el-main>
|
<el-main>
|
||||||
<el-row :gutter="4">
|
<Suspense>
|
||||||
<el-col :md="8" :sm="24">
|
<template #default>
|
||||||
<el-card header="安卓APP" shadow="hover">
|
<component :is="page" />
|
||||||
<el-form >
|
</template>
|
||||||
<el-form-item label="版本号">
|
<template #fallback>
|
||||||
<el-input v-model="apk_form.version" placeholder="版本号"></el-input>
|
<el-skeleton :rows="3" />
|
||||||
</el-form-item>
|
</template>
|
||||||
<el-form-item label="文件">
|
</Suspense>
|
||||||
<sc-upload-file
|
|
||||||
v-model="apk_form.file"
|
|
||||||
:multiple="false"
|
|
||||||
:limit="1"
|
|
||||||
>
|
|
||||||
<el-button type="primary" icon="el-icon-upload">上传</el-button>
|
|
||||||
</sc-upload-file>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item style="float:right">
|
|
||||||
<el-button type="primary" :loading="apkSaveLoading" @click="apkSave">保存</el-button>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
|
||||||
</el-card>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { defineAsyncComponent } from "vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
name: "userCenter",
|
||||||
|
components: {
|
||||||
|
androisAPK: defineAsyncComponent(() => import("./settings/androisAPK.vue")),
|
||||||
|
smsSet: defineAsyncComponent(() => import("./settings/smsSet.vue")),
|
||||||
|
sysSet: defineAsyncComponent(() => import("./settings/sysSet.vue"))
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
apkSaveLoading: false,
|
menu: [
|
||||||
apk_form: {},
|
{
|
||||||
|
groupName: "系统配置",
|
||||||
|
list: [
|
||||||
|
{
|
||||||
|
icon: "el-icon-platform",
|
||||||
|
title: "系统信息",
|
||||||
|
component: "sysSet",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon: "el-icon-lock",
|
||||||
|
title: "APP",
|
||||||
|
component: "androisAPK",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
icon: "el-icon-postcard",
|
||||||
|
title: "短信",
|
||||||
|
component: "smsSet",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
userData: {},
|
||||||
|
page: "sysSet",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
//路由跳转进来 判断from是否有特殊标识做特殊处理
|
||||||
this.apkRead()
|
beforeRouteEnter(to, from, next) {
|
||||||
|
next((vm) => {
|
||||||
|
if (from.is) {
|
||||||
|
//删除特殊标识,防止标签刷新重复执行
|
||||||
|
delete from.is;
|
||||||
|
//执行特殊方法
|
||||||
|
vm.$alert("路由跳转过来后含有特殊标识,做特殊处理", "提示", {
|
||||||
|
type: "success",
|
||||||
|
center: true,
|
||||||
|
})
|
||||||
|
.then(() => {})
|
||||||
|
.catch(() => {});
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
methods:{
|
mounted() {
|
||||||
apkSave(){
|
this.getBaseInfo();
|
||||||
this.apkSaveLoading = true
|
},
|
||||||
this.$API.system.apk.create.req(this.apk_form).then(res=>{
|
methods: {
|
||||||
this.apkSaveLoading = false
|
openPage(item) {
|
||||||
this.$message.success("保存成功")
|
this.page = item.index;
|
||||||
}).catch(e=>{this.apkSaveLoading=true})
|
|
||||||
|
|
||||||
},
|
},
|
||||||
apkRead(){
|
|
||||||
this.$API.system.apk.read.req().then(res=>{
|
getBaseInfo() {
|
||||||
this.apk_form = res
|
this.$API.system.baseInfo.getInfo.req().then((res) => {
|
||||||
|
debugger;
|
||||||
|
console.log(res)
|
||||||
|
this.$TOOL.data.set("BASE_INFO", res)
|
||||||
})
|
})
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
</style>
|
||||||
|
|
|
@ -0,0 +1,66 @@
|
||||||
|
<template>
|
||||||
|
<el-container>
|
||||||
|
<el-main>
|
||||||
|
<el-card header="安卓APP" shadow="hover">
|
||||||
|
<el-form >
|
||||||
|
<el-form-item label="版本号">
|
||||||
|
<el-input v-model="form.apk_version" placeholder="版本号"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="文件">
|
||||||
|
<sc-upload-file
|
||||||
|
v-model="form.apk_file"
|
||||||
|
:multiple="false"
|
||||||
|
:limit="1"
|
||||||
|
>
|
||||||
|
<el-button type="primary" icon="el-icon-upload">上传</el-button>
|
||||||
|
</sc-upload-file>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注">
|
||||||
|
<el-input v-model="form.apk_remark" placeholder="备注"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item style="float:right">
|
||||||
|
<el-button type="primary" :loading="saveLoading" @click="submitForm">保存</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
saveLoading:false,
|
||||||
|
form: {
|
||||||
|
apk_version:'',
|
||||||
|
apk_file:'',
|
||||||
|
apk_remark:'',
|
||||||
|
},
|
||||||
|
configInfo:null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted(){
|
||||||
|
this.getBaseInfo()
|
||||||
|
},
|
||||||
|
methods:{
|
||||||
|
getBaseInfo() {
|
||||||
|
this.configInfo = this.$TOOL.data.get("BASE_INFO");
|
||||||
|
this.form = this.$TOOL.data.get("BASE_INFO").apk
|
||||||
|
},
|
||||||
|
submitForm(){
|
||||||
|
this.saveLoading = true;
|
||||||
|
let obj = {}
|
||||||
|
this.configInfo.apk = this.form;
|
||||||
|
obj.apk = this.form;
|
||||||
|
this.$API.system.baseInfo.updateInfo.req(obj).then((res) => {
|
||||||
|
this.$message.success("保存成功")
|
||||||
|
this.$TOOL.data.set("BASE_INFO", this.configInfo)
|
||||||
|
this.saveLoading = false;
|
||||||
|
}).catch(res=>{
|
||||||
|
this.saveLoading = false;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
|
@ -0,0 +1,64 @@
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never" header="短信信息">
|
||||||
|
<el-form
|
||||||
|
ref="form"
|
||||||
|
:model="form"
|
||||||
|
label-width="120px"
|
||||||
|
style="margin-top: 20px"
|
||||||
|
>
|
||||||
|
<el-form-item label="注册方">
|
||||||
|
<el-input v-model="form.xn_sign" readonly></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="key">
|
||||||
|
<el-input v-model="form.xn_key" readonly></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="密钥">
|
||||||
|
<el-input v-model="form.xn_secret" readonly></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item style="float:right">
|
||||||
|
<el-button type="primary" :loading="saveLoading" @click="submitForm">保存</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {
|
||||||
|
xn_sign:'',
|
||||||
|
xn_key:'',
|
||||||
|
xn_secret:'',
|
||||||
|
},
|
||||||
|
saveLoading:false,
|
||||||
|
configInfo:null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.getBaseInfo();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openPage(item) {
|
||||||
|
this.page = item.index;
|
||||||
|
},
|
||||||
|
getBaseInfo() {
|
||||||
|
this.configInfo = this.$TOOL.data.get("BASE_INFO");
|
||||||
|
this.form = this.$TOOL.data.get("BASE_INFO").sms
|
||||||
|
},
|
||||||
|
submitForm(){
|
||||||
|
this.saveLoading = true;
|
||||||
|
let obj = {}
|
||||||
|
obj.sms = this.form;
|
||||||
|
this.configInfo.sms = this.form
|
||||||
|
this.$API.system.baseInfo.updateInfo.req(obj).then((res) => {
|
||||||
|
this.$message.success("保存成功")
|
||||||
|
this.$TOOL.data.set("BASE_INFO", this.configInfo)
|
||||||
|
this.saveLoading = false;
|
||||||
|
}).catch(res=>{
|
||||||
|
this.saveLoading = false;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
|
@ -0,0 +1,81 @@
|
||||||
|
<template>
|
||||||
|
<el-card shadow="never" header="系统信息">
|
||||||
|
<el-form
|
||||||
|
ref="form"
|
||||||
|
:model="form"
|
||||||
|
label-width="120px"
|
||||||
|
style="margin-top: 20px"
|
||||||
|
>
|
||||||
|
<el-row>
|
||||||
|
<el-col>
|
||||||
|
<el-form-item label="系统名称">
|
||||||
|
<el-input v-model="form.base_name"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col>
|
||||||
|
<el-form-item label="系统简称">
|
||||||
|
<el-input v-model="form.base_name_short"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :md="12" :sm="24">
|
||||||
|
<el-form-item label="系统logo">
|
||||||
|
<sc-upload v-model="form.base_logo" :modelValue="form.base_logo" title="系统logo" ></sc-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :md="12" :sm="24">
|
||||||
|
<el-form-item label="登录背景图">
|
||||||
|
<sc-upload v-model="form.base_logo_side" :modelValue="form.base_logo_side" title="登录背景图"></sc-upload>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col>
|
||||||
|
<el-form-item style="float:right">
|
||||||
|
<el-button type="primary" @click="submitForm" :loading="saveLoading">提交</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
saveLoading:false,
|
||||||
|
form: {
|
||||||
|
base_logo: "/media/default/logo.png",
|
||||||
|
base_logo_side: "/media/default/logo_side.jpg",
|
||||||
|
base_name: "托克逊能源管理平台",
|
||||||
|
base_name_short: "托克逊能管"
|
||||||
|
},
|
||||||
|
configInfo:null,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.getBaseInfo();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
openPage(item) {
|
||||||
|
this.page = item.index;
|
||||||
|
},
|
||||||
|
|
||||||
|
getBaseInfo() {
|
||||||
|
this.configInfo = this.$TOOL.data.get("BASE_INFO");
|
||||||
|
this.form = this.$TOOL.data.get("BASE_INFO").base
|
||||||
|
},
|
||||||
|
submitForm(){
|
||||||
|
this.saveLoading = true;
|
||||||
|
let obj = {}
|
||||||
|
this.configInfo.base = this.form;
|
||||||
|
obj.base = this.form;
|
||||||
|
this.$API.system.baseInfo.updateInfo.req(obj).then((res) => {
|
||||||
|
this.$message.success("保存成功")
|
||||||
|
this.$TOOL.data.set("BASE_INFO", this.configInfo)
|
||||||
|
this.saveLoading = false;
|
||||||
|
}).catch(res=>{
|
||||||
|
this.saveLoading = false;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
|
@ -0,0 +1,194 @@
|
||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-card style="margin-top:10px">
|
||||||
|
<div ref="print" id="myReport" class="printContainer">
|
||||||
|
<h3 style="text-align: center;">主要设备(100KW以上)单位产品电耗数据表</h3>
|
||||||
|
<table border="1" width="1000" cellspacing="0" :key="timeStamp" id="numTable">
|
||||||
|
<thead style="background: #efefef;height: 40px;">
|
||||||
|
<tr>
|
||||||
|
<th>设备名称</th>
|
||||||
|
<th>设备编号</th>
|
||||||
|
<th>单位</th>
|
||||||
|
<th>上个小时</th>
|
||||||
|
<th>昨日</th>
|
||||||
|
<th>本月</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="(item) in tableDatas" :key="item">
|
||||||
|
<td class="numCell">{{item.name}}</td>
|
||||||
|
<td class="numCell">{{item.number}}</td>
|
||||||
|
<td class="numCell">{{item.unit}}</td>
|
||||||
|
<td class="numCell hoursItem" @click="itemClick('hours',item)" style="background: rgba(238, 179, 179, 0.8);">{{item[0]}}</td>
|
||||||
|
<td class="numCell monthItem" @click="itemClick('month',item)" style="background: rgba(238, 189, 124, 0.8);">{{item[2]}}</td>
|
||||||
|
<td class="numCell yearItem" @click="itemClick1('year',item)" style="background: rgba(186, 236, 135, 0.8);">{{item[3]}}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<sc-dialog v-model="chartShow" draggable title="创建/编辑人员证书">
|
||||||
|
<div class="searchHead" v-if="type=='hours'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
placeholder="选择时间"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<span class="middleText">至</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='days'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='month'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="开始月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="结束月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<scEcharts height="360px" :option="myOption" v-if="chartShow"></scEcharts>
|
||||||
|
</sc-dialog>
|
||||||
|
<charts
|
||||||
|
v-if="asynDialog"
|
||||||
|
:type="type"
|
||||||
|
:title="title"
|
||||||
|
:modelValue="modelValue"
|
||||||
|
:showClose="showClose"
|
||||||
|
:echartType='echartType'
|
||||||
|
@closed="asynDialog = false"
|
||||||
|
></charts>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import scEcharts from "@/components/scEcharts";
|
||||||
|
import { defineAsyncComponent } from 'vue'
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
scEcharts,
|
||||||
|
charts: defineAsyncComponent(() => import("@/components/scEnm/lineChartsdialog.vue")),
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
chartShow: false,
|
||||||
|
myOption: null,
|
||||||
|
timeStamp:0,
|
||||||
|
listQuery:{
|
||||||
|
belong_dept:'',
|
||||||
|
task2__year:'',
|
||||||
|
page:0
|
||||||
|
},
|
||||||
|
query:{
|
||||||
|
time:''
|
||||||
|
},
|
||||||
|
tableDatas:[
|
||||||
|
{name:'反击式破',number:'NM001',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
{name:'立磨主电',number:'NM002',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
{name:'循环风机',number:'NM003',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
{name:'烘干破主',number:'NM004',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
{name:'废气风机',number:'NM005',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
{name:'尾排风机',number:'NM006',unit:'KW·h/t',hours:'',days:'',month:''},
|
||||||
|
],
|
||||||
|
modelValue:true,
|
||||||
|
type:'hours',
|
||||||
|
title:'title',
|
||||||
|
apiObj:'',
|
||||||
|
showClose:true,
|
||||||
|
echartType:'line',
|
||||||
|
asynDialog:false,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
itemClick(type,item){
|
||||||
|
this.type=type;
|
||||||
|
this.asynDialog = true;
|
||||||
|
},
|
||||||
|
itemClick1(type,item){
|
||||||
|
this.chartShow = false;
|
||||||
|
this.$API.bi.dataset.exec
|
||||||
|
.req('3322567213885833216')
|
||||||
|
.then((res) => {
|
||||||
|
this.myOption = JSON.parse(res.echart_options);
|
||||||
|
debugger;
|
||||||
|
console.log(this.myOption)
|
||||||
|
this.chartShow = true;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handlePrint() {
|
||||||
|
this.$PRINT('#myReport');
|
||||||
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.printContainer{
|
||||||
|
width: 1075px;
|
||||||
|
}
|
||||||
|
#numTable{
|
||||||
|
margin-left: 37px;
|
||||||
|
}
|
||||||
|
#numTable td{
|
||||||
|
height: 32px;
|
||||||
|
padding-left: 5px;
|
||||||
|
}
|
||||||
|
.numCell{
|
||||||
|
width: 80px;
|
||||||
|
}
|
||||||
|
.numCell.numCell_last{
|
||||||
|
width: 100px;
|
||||||
|
}
|
||||||
|
.searchHead{
|
||||||
|
display:flex
|
||||||
|
}
|
||||||
|
.middleText{
|
||||||
|
height: 32px;
|
||||||
|
line-height: 32px;
|
||||||
|
margin: 0 5px;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
.searchBtn{
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,231 @@
|
||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-card style="margin-top:10px">
|
||||||
|
<div ref="print" id="myReport" class="printContainer">
|
||||||
|
<h3 style="text-align: center;">生产报告</h3>
|
||||||
|
<table border="1" width="1000" cellspacing="0" :key="timeStamp" id="numTable">
|
||||||
|
<thead style="background: #efefef;height: 40px;">
|
||||||
|
<tr>
|
||||||
|
<th colspan="2">参数</th>
|
||||||
|
<th>上个小时</th>
|
||||||
|
<th>昨日</th>
|
||||||
|
<th>本月</th>
|
||||||
|
<th>本年</th>
|
||||||
|
<th>月目标值</th>
|
||||||
|
<th>月完成度</th>
|
||||||
|
<th>年目标值</th>
|
||||||
|
<th>年完成度</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="(item,index) in tableDatas" :key="item">
|
||||||
|
<td v-if="index==0" rowspan="2">产量</td>
|
||||||
|
<td v-if="index==0">总产量(t)</td>
|
||||||
|
<td v-if="index==1">台时产量(t/h)</td>
|
||||||
|
<td v-if="index==2" rowspan="2">运转时间</td>
|
||||||
|
<td v-if="index==2">运转时间(t)</td>
|
||||||
|
<td v-if="index==3">运转率(%)</td>
|
||||||
|
<td v-if="index==4">能耗</td>
|
||||||
|
<td v-if="index==4">生料分布电耗(KW·h/t)</td>
|
||||||
|
<td v-if="index==5">成本</td>
|
||||||
|
<td v-if="index==5">生料成本(元/吨)</td>
|
||||||
|
<td v-if="index==6">质量</td>
|
||||||
|
<td v-if="index==6">合格率(%)</td>
|
||||||
|
<td class="numCell hoursItem" @click="itemClick('hours',item)" style="background: rgba(238, 179, 179, 0.8);">{{item[0]}}</td>
|
||||||
|
<td class="numCell daysItem" @click="itemClick('days',item)" style="background: rgba(239, 90, 90, 0.8);">{{item[1]}}</td>
|
||||||
|
<td class="numCell monthItem" @click="itemClick('month',item)" style="background: rgba(238, 189, 124, 0.8);">{{item[2]}}</td>
|
||||||
|
<td class="numCell yearItem" @click="itemClick1('year',item)" style="background: rgba(186, 236, 135, 0.8);">{{item[3]}}</td>
|
||||||
|
<td class="numCell">{{item[4]}}</td>
|
||||||
|
<td class="numCell">{{item[5]}}</td>
|
||||||
|
<td class="numCell">{{item[6]}}</td>
|
||||||
|
<td class="numCell">{{item[7]}}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<sc-dialog v-model="chartShow" draggable title="创建/编辑人员证书">
|
||||||
|
<div class="searchHead" v-if="type=='hours'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
placeholder="选择时间"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<span class="middleText">至</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='days'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="date"
|
||||||
|
format="YYYY-MM-DD"
|
||||||
|
value-format="YYYY-MM-DD"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='month'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="开始月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="month"
|
||||||
|
format="YYYY-MM"
|
||||||
|
value-format="YYYY-MM"
|
||||||
|
start-placeholder="结束月份"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<div class="searchHead" v-if="type=='year'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.start_time"
|
||||||
|
type="year"
|
||||||
|
format="YYYY"
|
||||||
|
value-format="YYYY"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="query.end_time"
|
||||||
|
type="year"
|
||||||
|
format="YYYY"
|
||||||
|
value-format="YYYY"
|
||||||
|
start-placeholder="结束日期"
|
||||||
|
:picker-options="pickerOptions"
|
||||||
|
/>
|
||||||
|
<el-button type="primary" class="searchBtn" @click="dataSearch">查询</el-button>
|
||||||
|
</div>
|
||||||
|
<scEcharts height="360px" :option="myOption" v-if="chartShow"></scEcharts>
|
||||||
|
</sc-dialog>
|
||||||
|
<charts
|
||||||
|
v-if="asynDialog"
|
||||||
|
:type="type"
|
||||||
|
:title="title"
|
||||||
|
:modelValue="modelValue"
|
||||||
|
:showClose="showClose"
|
||||||
|
:echartType='echartType'
|
||||||
|
@closed="asynDialog = false"
|
||||||
|
></charts>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import scEcharts from "@/components/scEcharts";
|
||||||
|
import { defineAsyncComponent } from 'vue'
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
scEcharts,
|
||||||
|
charts: defineAsyncComponent(() => import("@/components/scEnm/lineChartsdialog.vue")),
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
chartShow: false,
|
||||||
|
myOption: null,
|
||||||
|
timeStamp:0,
|
||||||
|
listQuery:{
|
||||||
|
belong_dept:'',
|
||||||
|
task2__year:'',
|
||||||
|
page:0
|
||||||
|
},
|
||||||
|
query:{
|
||||||
|
time:''
|
||||||
|
},
|
||||||
|
tableDatas:[
|
||||||
|
[0,0,0,0,0,0,0,0],
|
||||||
|
[1,1,1,1,1,1,1,1],
|
||||||
|
[2,2,2,2,2,2,2,2],
|
||||||
|
[3,3,3,3,3,3,3,3],
|
||||||
|
[4,4,4,4,4,4,4,4],
|
||||||
|
[5,5,5,5,5,5,5,5],
|
||||||
|
[6,6,6,6,6,6,6,6]
|
||||||
|
],
|
||||||
|
modelValue:true,
|
||||||
|
type:'hours',
|
||||||
|
title:'title',
|
||||||
|
apiObj:'',
|
||||||
|
showClose:true,
|
||||||
|
echartType:'line',
|
||||||
|
asynDialog:false,
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
itemClick(type,item){
|
||||||
|
this.type=type;
|
||||||
|
this.asynDialog = true;
|
||||||
|
},
|
||||||
|
itemClick1(type,item){
|
||||||
|
this.chartShow = false;
|
||||||
|
this.$API.bi.dataset.exec
|
||||||
|
.req('3322567213885833216')
|
||||||
|
.then((res) => {
|
||||||
|
this.myOption = JSON.parse(res.echart_options);
|
||||||
|
debugger;
|
||||||
|
console.log(this.myOption)
|
||||||
|
this.chartShow = true;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handlePrint() {
|
||||||
|
this.$PRINT('#myReport');
|
||||||
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.printContainer{
|
||||||
|
width: 1075px;
|
||||||
|
}
|
||||||
|
#numTable{
|
||||||
|
margin-left: 37px;
|
||||||
|
}
|
||||||
|
#numTable td{
|
||||||
|
height: 32px;
|
||||||
|
padding-left: 5px;
|
||||||
|
}
|
||||||
|
.numCell{
|
||||||
|
width: 80px;
|
||||||
|
}
|
||||||
|
.numCell.numCell_last{
|
||||||
|
width: 100px;
|
||||||
|
}
|
||||||
|
.searchHead{
|
||||||
|
display:flex
|
||||||
|
}
|
||||||
|
.middleText{
|
||||||
|
height: 32px;
|
||||||
|
line-height: 32px;
|
||||||
|
margin: 0 5px;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
.searchBtn{
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -0,0 +1,133 @@
|
||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-card style="margin-top:10px">
|
||||||
|
<div ref="print" id="myReport" class="printContainer">
|
||||||
|
<h3 style="text-align: center;">主要设备(100KW以上)单位产品电耗数据表</h3>
|
||||||
|
<table border="1" cellspacing="0" :key="timeStamp" id="numTable">
|
||||||
|
<thead style="background: #efefef;height: 40px;">
|
||||||
|
<tr>
|
||||||
|
<th rowspan="2">月份</th>
|
||||||
|
<th rowspan="2">班组</th>
|
||||||
|
<th colspan="2">产量</th>
|
||||||
|
<th>运转率</th>
|
||||||
|
<th>成本</th>
|
||||||
|
<th colspan="4">质量</th>
|
||||||
|
<th colspan="7">单位产品电耗</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>总产量(t)</th>
|
||||||
|
<th>台时产量(t/h)</th>
|
||||||
|
<th>运转率(%)</th>
|
||||||
|
<th>单位产品成本(元/吨)</th>
|
||||||
|
<th>细度(%)</th>
|
||||||
|
<th>Fe₂O₃(%)</th>
|
||||||
|
<th>水分(%)</th>
|
||||||
|
<th>CaO(%)</th>
|
||||||
|
<th>当期单位产品电耗(kW·h/h)</th>
|
||||||
|
<th>单位产品电耗目标值(kW·h/h)</th>
|
||||||
|
<th>当期单位产品电耗与目标值差值(kW·h/h)</th>
|
||||||
|
<th>环期单位产品电耗(kW·h/h)</th>
|
||||||
|
<th>当期单位产品电耗与环期差值(kW·h/h)</th>
|
||||||
|
<th>当期单位产品电耗环比增长率(%)</th>
|
||||||
|
<th>同比增长率(%)</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tr v-for="(item,index) in tableDatas" :key="index">
|
||||||
|
<td v-if="index%3==0" rowspan="3" style="width:50px">{{item.month}}</td>
|
||||||
|
<td class="numCell">{{item.name}}</td>
|
||||||
|
<td class="numCell">{{item.number}}</td>
|
||||||
|
<td class="numCell">{{item.unit}}</td>
|
||||||
|
<td class="numCell">{{item.hours}}</td>
|
||||||
|
<td class="numCell">{{item.days}}</td>
|
||||||
|
<td class="numCell">{{item.months}}</td>
|
||||||
|
<td class="numCell">{{item.hours}}</td>
|
||||||
|
<td class="numCell">{{item.days}}</td>
|
||||||
|
<td class="numCell">{{item.months}}</td>
|
||||||
|
<td class="numCell">{{item.hours}}</td>
|
||||||
|
<td class="numCell">{{item.days}}</td>
|
||||||
|
<td class="numCell">{{item.months}}</td>
|
||||||
|
<td class="numCell">{{item.months}}</td>
|
||||||
|
<td class="numCell">{{item.hours}}</td>
|
||||||
|
<td class="numCell">{{item.days}}</td>
|
||||||
|
<td class="numCell">{{item.months}}</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
timeStamp:0,
|
||||||
|
listQuery:{
|
||||||
|
belong_dept:'',
|
||||||
|
task2__year:'',
|
||||||
|
page:0
|
||||||
|
},
|
||||||
|
tableDatas:[
|
||||||
|
{month:'2023.1',name:'甲组',number:'NM001',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
{month:'2023.1',name:'乙组',number:'NM002',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
{month:'2023.1',name:'丙组',number:'NM003',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
{month:'2023.2',name:'甲组',number:'NM004',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
{month:'2023.2',name:'乙组',number:'NM005',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
{month:'2023.2',name:'丙组',number:'NM006',unit:'KW·h/t',hours:'1',days:'2',months:'3'},
|
||||||
|
],
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
itemClick(type,item){
|
||||||
|
this.type=type;
|
||||||
|
this.asynDialog = true;
|
||||||
|
},
|
||||||
|
itemClick1(type,item){
|
||||||
|
this.chartShow = false;
|
||||||
|
this.$API.bi.dataset.exec
|
||||||
|
.req('3322567213885833216')
|
||||||
|
.then((res) => {
|
||||||
|
this.myOption = JSON.parse(res.echart_options);
|
||||||
|
debugger;
|
||||||
|
console.log(this.myOption)
|
||||||
|
this.chartShow = true;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handlePrint() {
|
||||||
|
this.$PRINT('#myReport');
|
||||||
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style>
|
||||||
|
.printContainer{
|
||||||
|
width: 1075px;
|
||||||
|
}
|
||||||
|
#numTable{
|
||||||
|
margin-left: 37px;
|
||||||
|
}
|
||||||
|
#numTable td{
|
||||||
|
height: 32px;
|
||||||
|
padding-left: 5px;
|
||||||
|
}
|
||||||
|
.numCell{
|
||||||
|
width: 80px;
|
||||||
|
}
|
||||||
|
.numCell.numCell_last{
|
||||||
|
width: 100px;
|
||||||
|
}
|
||||||
|
.searchHead{
|
||||||
|
display:flex
|
||||||
|
}
|
||||||
|
.middleText{
|
||||||
|
height: 32px;
|
||||||
|
line-height: 32px;
|
||||||
|
margin: 0 5px;
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
.searchBtn{
|
||||||
|
margin-left: 5px;
|
||||||
|
}
|
||||||
|
</style>
|
Loading…
Reference in New Issue