Commit b748a906 authored by 秦嘉's avatar 秦嘉

Merge remote-tracking branch 'origin/master'

parents ed49a369 f7c7cedc
......@@ -3,18 +3,6 @@ ENV = 'production'
# 生产环境
# base api
VUE_APP_BASE_API = 'http://117.122.212.91:8082'
# workFlow链接地址
VUE_APP_WORKFLOW = 'http://zt.cebitic.com:10184/workFlow'
# internal链接地址
VUE_APP_INTERNAL = 'http://zt.cebitic.com:10184/internal'
# login地址
VUE_APP_LOGIN = 'http://login.cebitic.com:10181/#/login'
# 中台地址
VUE_APP_ZT = 'http://zt.cebitic.com:10181'
# 内勤地址
VUE_APP_NQ = 'http://nq.cebitic.com:10181'
# 根域名
VUE_APP_ROOT = 'cebitic.com'
# 模板地址
VUE_APP_TEMPLATE = 'http://zt.cebitic.com:10191/'
# VUE_APP_BASE_API = 'http://172.20.23.96:8085'
VUE_APP_BASE_API = 'http://124.71.16.228:8085'
......@@ -12,7 +12,8 @@
"build:test": "vue-cli-service build --mode test",
"preview": "node build/index.js --preview",
"lint": "eslint --ext .js,.vue src",
"svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml"
"svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml",
"postinstall": "patch-package"
},
"dependencies": {
"@riophae/vue-treeselect": "^0.4.0",
......@@ -60,6 +61,7 @@
"html-webpack-plugin": "3.2.0",
"mockjs": "1.0.1-beta3",
"node-sass": "^4.9.0",
"patch-package": "^6.4.7",
"runjs": "^4.3.2",
"sass-loader": "^7.1.0",
"script-ext-html-webpack-plugin": "2.1.3",
......
......@@ -220,9 +220,9 @@
right: 12px!important;
}
.is-active.submenu-title-noDropdown {
background-color: #fff !important;
}
//.is-active.submenu-title-noDropdown {
// background-color: #fff !important;
//}
#app .sidebar-container .el-submenu .el-menu-item.is-active {
background-color: #D20A10 !important;
......
......@@ -16,11 +16,10 @@
:clearable="false"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
@change="changeTime"
style="width: 220px"
:default-time="'07:00:00'"
>
</el-date-picker>
@change="changeTime"
/>
<span>-</span>
<el-date-picker
v-model="queryParams.endDate"
......@@ -32,10 +31,9 @@
:clearable="false"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
@change="changeTime"
:default-time="'07:00:00'"
>
</el-date-picker>
@change="changeTime"
/>
</el-form-item>
</el-form>
</div>
......@@ -53,7 +51,7 @@
<img src="@/assets/image/jihuashuliang@2x.png" class="logoClass">
<div class="cardLabel">
<div>计划数量</div>
<div style="color: #D94142; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.planSum}}</div>
<div style="color: #D94142; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.planSum }}</div>
</div>
</div>
</div>
......@@ -64,7 +62,7 @@
<img src="@/assets/image/wanchengshuliang@2x.png" class="logoClass">
<div class="cardLabel">
<div>完成数量</div>
<div style="color: #EC7E15; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.completeSum}}</div>
<div style="color: #EC7E15; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.completeSum }}</div>
</div>
</div>
</div>
......@@ -75,7 +73,7 @@
<img src="@/assets/image/wangonglv@2x.png" class="logoClass">
<div class="cardLabel">
<div>完工率</div>
<div style="color: #E8AC08; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.complePropo + '%'}}</div>
<div style="color: #E8AC08; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.complePropo + '%' }}</div>
</div>
</div>
</div>
......@@ -86,7 +84,7 @@
<img src="@/assets/image/yicilianglv@2x.png" class="logoClass">
<div class="cardLabel">
<div>一次良率</div>
<div style="color: #86B504; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.goodPropo + '%'}}</div>
<div style="color: #86B504; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.goodPropo + '%' }}</div>
</div>
</div>
</div>
......@@ -106,7 +104,7 @@
<img src="@/assets/image/jihuashuliang2@2x.png" class="logoClass">
<div class="cardLabel">
<div>计划数量</div>
<div style="color: #7875CD; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.planSum1}}</div>
<div style="color: #7875CD; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.planSum1 }}</div>
</div>
</div>
</div>
......@@ -117,7 +115,7 @@
<img src="@/assets/image/wanchengshuliang2@2x.png" class="logoClass">
<div class="cardLabel">
<div>完成数量</div>
<div style="color: #2396EF; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.completeSum1}}</div>
<div style="color: #2396EF; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.completeSum1 }}</div>
</div>
</div>
</div>
......@@ -128,7 +126,7 @@
<img src="@/assets/image/wangonglv2@2x.png" class="logoClass">
<div class="cardLabel">
<div>完工率</div>
<div style="color: #17B5CE; margin-top: 10px; font-size: 20px;font-weight: 700;">{{imagData.complePropo1 + '%'}}</div>
<div style="color: #17B5CE; margin-top: 10px; font-size: 20px;font-weight: 700;">{{ imagData.complePropo1 + '%' }}</div>
</div>
</div>
</div>
......@@ -151,7 +149,7 @@
<div class="heightLine">
<div class="span_middle">生产看板</div>
</div>
<home-page-table></home-page-table>
<home-page-table />
</el-card>
</div>
</div>
......@@ -171,16 +169,16 @@ export default {
const date = new Date()
return {
// 开始时间范围限定
start_date:{
disabledDate:time => {
if(this.queryParams.endDate) {
start_date: {
disabledDate: time => {
if (this.queryParams.endDate) {
return time.getTime() >= new Date(this.queryParams.endDate).getTime() - 86400000
}
}
},
// 结束时间范围限定
end_date:{
disabledDate:time => {
end_date: {
disabledDate: time => {
return time.getTime() <= new Date(this.queryParams.startDate).getTime()
}
},
......@@ -353,7 +351,7 @@ export default {
trigger: 'axis',
axisPointer: {
type: 'cross'
},
}
},
grid: {
right: '10%',
......@@ -374,13 +372,13 @@ export default {
axisLabel: {
// x轴文字的配置
show: true,
interval: 0 ,// 使x轴文字显示全
interval: 0, // 使x轴文字显示全
// x轴文字过长遮挡其他文字
formatter: function (value) {
let res = value;
formatter: function(value) {
let res = value
// 长度大于15的加入省略号
if (res.length > 15) {
res = res.substring(0, 14) + "..."
res = res.substring(0, 14) + '...'
}
return res
}
......@@ -441,10 +439,10 @@ export default {
yAxisIndex: 1,
data: data3,
tooltip: {
valueFormatter: function (value) {
return value + ' %';
valueFormatter: function(value) {
return value + ' %'
}
},
}
}
]
}
......@@ -455,7 +453,7 @@ export default {
*/
getImagData() {
const params = {
startDate: this.queryParams.startDate ,
startDate: this.queryParams.startDate,
endDate: this.queryParams.endDate
}
getImagData(params).then(response => {
......
......@@ -7,3 +7,9 @@ export function getDataDetails(params) {
params
})
}
export function getProDetails(params) {
return request({
url: '/datamonitor/getStatisticsForProduce/' + '?beginDate=' + params.beginDate + '&endDate=' + params.endDate + '&type=' + params.type,
method: 'get'
})
}
......@@ -8,30 +8,31 @@
</div>
<el-date-picker
v-model="queryParams.startDate"
:picker-options="choseType === 'day' ? start_date :choseType === 'week' ? week_date : choseType === 'month' ? month_date : '' "
:picker-options="choseType === 'day' ? start_date :choseType === 'week' ? week_date : choseType === 'month' ? month_date : start_date "
type="datetime"
placeholder="选择日期"
popper-class="date_picker"
:editable="false"
:clearable="false"
format="yyyy-MM-dd HH:mm:ss"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd HH:mm:ss"
style="width: 220px"
:default-time="'07:00:00'"
:default-time="'00:00:00'"
@change="changeTime"
/>
<span>-</span>
<el-date-picker
v-model="queryParams.endDate"
:picker-options="choseType === 'day' ? end_date :choseType === 'week' ? week_end :choseType === 'month' ? month_end : ''"
:picker-options="choseType === 'day' ? end_date :choseType === 'week' ? week_end :choseType === 'month' ? month_end : end_date"
type="datetime"
popper-class="date_picker"
placeholder="选择日期"
:editable="false"
:clearable="false"
format="yyyy-MM-dd HH:mm:ss"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd HH:mm:ss"
:default-time="'07:00:00'"
style="width: 220px"
:default-time="'23:59:59'"
@change="changeTime"
/>
</el-form-item>
......@@ -66,9 +67,43 @@
>
<el-table-column type="index" label="序号" width="50" />
<el-table-column align="center" prop="type" :show-overflow-tooltip="true">
<template slot="header">
<div>统计日期</div>
<div>Statistical Date</div>
<template #header>
<div v-if="choseType === 'day' || choseType === 'week' || choseType === 'month'">
<div>统计日期</div>
<div>Statistical Date</div>
</div>
<div v-if="choseType === 'reason' || choseType === 'phenomenon'">
<div>报修原因</div>
<div>Reason</div>
</div>
<div v-if="choseType === 'parts'">
<div>不良部件</div>
<div>Parts</div>
</div>
<div v-if="choseType === 'disadvantage'">
<div>不良描述</div>
<div>Disadvantage</div>
</div>
<div v-if="choseType === 'operation'">
<div>维修操作</div>
<div>Operation</div>
</div>
<div v-if="choseType === 'xtCode'">
<div>线体号</div>
<div>XtCode</div>
</div>
<div v-if="choseType === 'station'">
<div>报修工站</div>
<div>Station</div>
</div>
<div v-if="choseType === 'materCode'">
<div>成品料号</div>
<div>MaterCode</div>
</div>
<div v-if="choseType === 'family'">
<div>按项目</div>
<div>Project</div>
</div>
</template>
<template slot-scope="scope">
{{ scope.row.type || '-' }}
......@@ -76,7 +111,8 @@
</el-table-column>
<el-table-column align="center" prop="defectQty" :show-overflow-tooltip="true">
<template slot="header">
<div>不良数量</div>
<div v-if="choseType === 'day' || choseType === 'week' || choseType === 'month'">不良数量</div>
<div v-else>维修数量</div>
<div>DefectQty</div>
</template>
<template slot-scope="scope">
......@@ -84,9 +120,10 @@
</template>
</el-table-column>
<el-table-column align="center" prop="inPut" :show-overflow-tooltip="true">
<template slot="header">
<div>计划生产数量</div>
<div>InPut</div>
<template #header>
<div>生产完成数量</div>
<div v-if="choseType === 'reason'">InPut</div>
<div v-else>OutPut</div>
</template>
<template slot-scope="scope">
{{ scope.row.inPut || '-' }}
......@@ -98,7 +135,8 @@
<div>FailureRate</div>
</template>
<template slot-scope="scope">
{{ scope.row.failureRate || '-' }}
<span v-if="scope.row.failureRate"> {{ scope.row.failureRate }}%</span>
<span v-else>-</span>
</template>
</el-table-column>
<el-table-column align="center" prop="failureProportion" :show-overflow-tooltip="true">
......@@ -114,7 +152,8 @@
</template>
<template slot-scope="scope">
<span v-if="choseType === 'day'|| choseType === 'week'|| choseType === 'month' ">
{{ scope.row.failureProportion || '-' }}
<span v-if="scope.row.failureProportion"> {{ scope.row.failureProportion }}%</span>
<span v-else>-</span>
</span>
<span v-else>
{{ scope.row.errorNum || '-' }}
......@@ -166,28 +205,33 @@ export default {
// 结束时间范围限定
end_date: {
disabledDate: time => {
return time.getTime() >= new Date(moment(new Date()).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 20).format('YYYY-MM-DD')).getTime()
if (this.queryParams.startDate) {
return time.getTime() >= new Date(moment(new Date()).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 20).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date(this.queryParams.startDate).getTime()).format('YYYY-MM-DD')).getTime()
}
}
},
// 选周报时结束时间范围(20周内)
week_end: {
disabledDate: time => {
return time.getTime() >= new Date(moment(new Date()).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 7 * 20).format('YYYY-MM-DD')).getTime()
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 7 * 20).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date(this.queryParams.startDate).getTime()).format('YYYY-MM-DD')).getTime()
}
},
// 选月报时结束时间范围(20月内)
month_end: {
disabledDate: time => {
return time.getTime() >= new Date(moment(new Date()).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 30 * 20).format('YYYY-MM-DD')).getTime()
time.getTime() < new Date(moment(new Date().getTime() - 3600 * 1000 * 24 * 30 * 20).format('YYYY-MM-DD')).getTime() ||
time.getTime() < new Date(moment(new Date(this.queryParams.startDate).getTime()).format('YYYY-MM-DD')).getTime()
}
},
// 搜索框数据
queryParams: {
startDate: moment(new Date().setTime(new Date().getTime() - 3600 * 1000 * 24 * 19)).format('YYYY-MM-DD') + ' 07:00:00',
endDate: moment(new Date()).format('YYYY-MM-DD') + ' 07:00:00'
startDate: moment(new Date().setTime(new Date().getTime() - 3600 * 1000 * 24 * 19)).format('YYYY-MM-DD') + ' 00:00:00',
endDate: moment(new Date()).format('YYYY-MM-DD') + ' 23:59:59'
},
HistoricalInvestigation: [],
logo: require('@/assets/image/btnChose.png'),
......@@ -204,6 +248,7 @@ export default {
{ dictLabel: '维修操作', dictValue: 'operation' },
{ dictLabel: '线体号', dictValue: 'xtCode' },
{ dictLabel: '报修工站', dictValue: 'station' },
{ dictLabel: '按项目', dictValue: 'family' },
{ dictLabel: '成品料号', dictValue: 'materCode' }
]
}
......@@ -269,6 +314,7 @@ export default {
/** 生产线监控*/
getProLineMonitor() {
const myChartAge = echarts.init(document.getElementById('dataCharts_proLineMonitor'))
const _this = this
const colors = ['#209DFF', '#BC2C29', '#FF8919']
const xData = [] // x轴显示
const defectQtyData = [] // y不良数量
......@@ -336,7 +382,7 @@ export default {
show: true
},
axisLabel: {
formatter: '{value} %'
formatter: _this.choseType === 'day' || _this.choseType === 'week' || _this.choseType === 'month' ? '{value} %' : '{value}'
}
}
......@@ -357,13 +403,17 @@ export default {
data: inputData
},
{
name: '不良占比',
name: _this.choseType === 'day' || _this.choseType === 'week' || _this.choseType === 'month' ? '不良占比' : '误测次数',
type: 'line',
yAxisIndex: 1,
data: failureProportionData,
tooltip: {
valueFormatter: function(value) {
return value + ' %'
if (_this.choseType === 'day' || _this.choseType === 'week' || _this.choseType === 'month') {
return value + ' %'
} else {
return value
}
}
}
}
......
......@@ -87,10 +87,10 @@ export default {
}
updateUserPwd(params).then(res => {
this.$message.success('密码修改成功!')
this.$router.push('/login')
// this.$store.dispatch('LogOut').then(() => {
// location.reload()
// })
// this.$router.push('/login')
this.$store.dispatch('FedLogOut').then(() => {
location.reload()
})
})
} else {
return false
......
......@@ -81,17 +81,9 @@ module.exports = {
[process.env.VUE_APP_BASE_API]: {
// target: `http://192.168.1.17:10010/internal`,
// target: `http://10.5.87.231:10010/internal`,
target: `http://117.122.212.91:8082/`,
// target: `http://192.168.1.88:8082/`,
// target: `http://192.168.1.44:8082/`,
// target: `http://192.168.1.45:8082/`,
// target: `http://192.168.1.69:8082/`,
// target: `http://192.168.1.95:8082/`,
// target: `http://192.168.1.63:8082/`,
// target: `http://192.168.1.25:8088/`,
// target: `http://192.168.1.18:8082/`,
// target: `http://192.168.1.11:8082/`,
// target: `http://192.168.1.12:8082/`,
target: `http://124.71.16.228:8085/`,
// target: `http://192.168.1.20:8083/`,
// target: `http://192.168.1.47:8082/`,
changeOrigin: true,
pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: ''
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment