Merge branch 'dev-scheduling' of http://42.192.7.176:3000/suojin/jonhon-mes-web into dev-scheduling

dev-scheduling
zhangdi 1 month ago
commit 423474b977
  1. 10
      src/api/performanceManagement/performanceDisclosure.js
  2. 12
      src/views/energyManagement/components/electricityQuota.vue
  3. 2
      src/views/energyManagement/components/electricityTarget.vue
  4. 11
      src/views/energyManagement/components/waterQuota.vue
  5. 7
      src/views/energyManagement/components/waterTarget.vue
  6. 2
      src/views/energyManagement/electricityManagement.vue
  7. 2
      src/views/energyManagement/energyMonitoring.vue
  8. 1
      src/views/energyManagement/peakFlatValley.vue
  9. 2
      src/views/energyManagement/waterManagement.vue
  10. 412
      src/views/personnelEfficiencyManagement/performanceManagement/performanceDisclosure.vue

@ -0,0 +1,10 @@
// 绩效公示相关接口
import request from '@/axios';
// 1. 绩效公示分页查询
export function pageBsEfficiencyTaskReport(params) {
return request({
url: '/blade-desk/bsEfficiencyTaskReport/page',
method: 'get',
params
})
}

@ -48,6 +48,7 @@ export default {
data:[],
isShowImport:false,
selectionList: [],
query:{},
option: {
height: "auto",
calcHeight: 32,
@ -78,12 +79,12 @@ export default {
filterBtn: true,
searchShowBtn: false,
columnSort: true,
excelBtn: true,
columnSort: true,
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelWidth: "auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",
@ -160,6 +161,7 @@ export default {
prop: "date",
type:'date',
search: true,
searchRange: true,
sortable: true,
filter: true,
span: 24,
@ -324,11 +326,17 @@ export default {
},
onLoad() {
this.loading = true;
let param = {
...this.query,
startDate:this.query.date && this.query.date.length != 0 && this.query.date[0],
endDate:this.query.date && this.query.date.length != 0 && this.query.date[1]
}
if(param.date) delete param.date
pageList({
current:this.page.currentPage,
size:this.page.pageSize,
type:2,
...this.query
...param
}).then(res =>{
this.data = res.data.data.records;
this.page.total = res.data.data.total;

@ -79,12 +79,12 @@ export default {
filterBtn: true,
searchShowBtn: false,
columnSort: true,
excelBtn: true,
columnSort: true,
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelWidth: "auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",

@ -63,12 +63,12 @@ export default {
filterBtn: true,
searchShowBtn: false,
columnSort: true,
excelBtn: true,
columnSort: true,
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelWidth: "auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",
@ -152,6 +152,7 @@ export default {
filter: true,
span: 24,
type: 'date',
searchRange: true,
format: "YYYY-MM-DD",
valueFormat: "YYYY-MM-DD",
rules: [
@ -370,11 +371,17 @@ export default {
},
onLoad() {
this.loading = true;
let param = {
...this.query,
startDate:this.query.date && this.query.date.length != 0 && this.query.date[0],
endDate:this.query.date && this.query.date.length != 0 && this.query.date[1]
}
if(param.date) delete param.date
pageList({
type: 1,
current:this.page.currentPage,
size:this.page.pageSize,
...this.query
...param
}).then(res => {
this.data = res.data.data.records;
this.page.total = res.data.data.total;

@ -85,12 +85,12 @@ export default {
filterBtn: true,
searchShowBtn: false,
columnSort: true,
excelBtn: true,
columnSort: true,
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelWidth: "auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",
@ -209,8 +209,11 @@ export default {
},
closeDialog(){
closeDialog(val){
this.isShowImport = false
if(val){
this.onLoad()
}
},
handleImport() {
this.isShowImport = true

@ -183,7 +183,7 @@ export default {
delBtnIcon: ' ',
addBtn: false,
labelWidth: 120,
// searchLabelWidth: 120,
searchLabelWidth: "auto",
menu: true,
menuWidth: 100,
dialogWidth: 600,

@ -102,7 +102,7 @@ export default {
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelWidth: "auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",

@ -71,6 +71,7 @@ export default {
index: false,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelWidth:"auto",
searchGutter: 24,
searchSpan: 6,
menuAlign: "center",

@ -47,7 +47,7 @@ export default {
delBtnIcon: " ",
addBtn: false,
labelWidth: 120,
// searchLabelWidth: 80,
searchLabelWidth: "auto",
menu: false,
menuWidth: 200,
dialogWidth: 600,

@ -8,21 +8,16 @@
v-model="form"
v-model:page="page"
ref="crud"
@row-update="rowUpdate"
@row-save="rowSave"
@search-change="searchChange"
@search-reset="searchReset"
@selection-change="selectionChange"
@current-change="currentChange"
@size-change="sizeChange"
@refresh-change="refreshChange"
@on-load="onLoad"
@cell-click="cellClick"
>
<!-- <template #menu="scope">
<el-button type="text" @click="viewRow(scope.row)">详情</el-button>
</template> -->
</avue-crud>
<!-- 绩效详情弹窗 -->
<el-dialog title="公示详情" v-model="showExcel" append-to-body width="85%">
<div>
月份
@ -33,143 +28,65 @@
:disabled-date="pickerOptions"
>
</el-date-picker>
<el-button type="primary" style="margin-left: 10px" @click="queryPerformance">查询</el-button>
<el-button type="primary" style="margin-left: 10px" @click="queryPerformance">
查询
</el-button>
</div>
<el-table :data="tableData" style="margin-top: 10px">
<el-table-column
align="center"
label="KPI得分"
prop="KPI"
width="75"
></el-table-column>
<el-table-column
align="center"
label="量化得分"
prop="lh"
width="80"
></el-table-column>
<el-table-column
align="center"
label="订单准时完成率"
prop="orderTime"
width="130"
></el-table-column>
<el-table-column
align="center"
label="重点零件完成率"
prop="keyPoint"
width="130"
></el-table-column>
<el-table-column
align="center"
label="后工序审理单分数"
prop="after"
width="140"
></el-table-column>
<el-table-column
align="center"
label="出厂不合格率DPP"
prop="unqualified"
width="140"
></el-table-column>
<el-table-column
align="center"
label="成本费用率"
prop="costMoney"
width="95"
></el-table-column>
<el-table-column align="center" label="通报" prop="notice"></el-table-column>
<el-table-column
align="center"
label="请假扣分"
prop="leave"
width="80"
></el-table-column>
<el-table-column
align="center"
label="考勤扣分"
prop="check"
width="80"
></el-table-column>
<el-table-column align="center" label="投稿加分项" prop="add" width="100"></el-table-column>
<el-table-column
align="center"
label="群策群力"
prop="all"
width="80"
></el-table-column>
<el-table-column
align="center"
label="优秀员工加分"
prop="excellence"
width="120"
></el-table-column>
<el-table-column
align="center"
label="成本"
prop="cost"
width="55"
></el-table-column>
<el-table-column
align="center"
label="总分"
prop="total"
width="55"
></el-table-column>
<el-table :data="detailList" style="margin-top: 10px" border>
<el-table-column align="center" label="KPI得分" prop="KPI" width="75" />
<el-table-column align="center" label="量化得分" prop="lh" width="80" />
<el-table-column align="center" label="订单准时完成率" prop="orderTime" width="130" />
<el-table-column align="center" label="重点零件完成率" prop="keyPoint" width="130" />
<el-table-column align="center" label="后工序审理单分数" prop="after" width="140" />
<el-table-column align="center" label="出厂不合格率DPP" prop="unqualified" width="140" />
<el-table-column align="center" label="成本费用率" prop="costMoney" width="95" />
<el-table-column align="center" label="通报" prop="notice" />
<el-table-column align="center" label="请假扣分" prop="leave" width="80" />
<el-table-column align="center" label="考勤扣分" prop="check" width="80" />
<el-table-column align="center" label="投稿加分项" prop="add" width="100" />
<el-table-column align="center" label="群策群力" prop="all" width="80" />
<el-table-column align="center" label="优秀员工加分" prop="excellence" width="120" />
<el-table-column align="center" label="成本" prop="cost" width="55" />
<el-table-column align="center" label="总分" prop="total" width="55" />
</el-table>
</el-dialog>
</basic-container>
</template>
<script>
import { pageBsEfficiencyTaskReport } from '@/api/performanceManagement/performanceDisclosure';
export default {
name: 'PerformanceDisclosure',
data() {
return {
//
showExcel: false,
monthValue: "2025-09",
pickerOptions: (time) => {
const year = new Date().getFullYear()
return time.getFullYear() !== year; //
},
tableData: [
{
KPI: 70,
lh: 26,
orderTime: 0,
keyPoint: "",
after: "",
unqualified: "",
costMoney: "",
notice: 0,
all: 0,
leave: 0,
check: 0,
add: 0,
excellence: 2,
cost: 0,
total: 98,
},
],
monthArr: [
{ label: "一月", value: 1 },
{ label: "一月", value: 1 },
{ label: "一月", value: 1 },
{ label: "一月", value: 1 },
],
monthValue: '',
//
detailList: [],
//
loading: false,
data: [],
form: {},
query: {},
//
page: {
pageSize: 10,
currentPage: 1,
total: 0,
},
//
pickerOptions: time => {
const year = new Date().getFullYear();
return time.getFullYear() !== year;
},
//
option: {
height: "auto",
align: "center",
height: 'auto',
align: 'center',
calcHeight: 32,
rowKey: "id",
rowParentKey: "parentId",
rowKey: 'id',
rowParentKey: 'parentId',
tip: false,
simplePage: true,
searchShow: true,
@ -184,12 +101,12 @@ export default {
delBtn: false,
addBtn: false,
editBtn: false,
editBtnText: "修改",
addBtnIcon: " ",
viewBtnIcon: " ",
delBtnIcon: " ",
editBtnIcon: " ",
viewBtnText: "详情",
editBtnText: '修改',
addBtnIcon: ' ',
viewBtnIcon: ' ',
delBtnIcon: ' ',
editBtnIcon: ' ',
viewBtnText: '详情',
// labelWidth: 120,
searchLabelWidth: 40,
menu: false,
@ -204,120 +121,119 @@ export default {
excelBtn: true,
columnSort: true,
showOverflowTooltip: true,
searchLabelPosition: "left",
searchLabelPosition: "left",
searchLabelPosition: 'left',
searchGutter: 24,
searchSpan: 6,
menuAlign: "left",
menuAlign: 'left',
gridBtn: false,
searchMenuPosition: "right",
searchMenuPosition: 'right',
column: [
{
label: "工号",
prop: "userCode",
label: '工号',
prop: 'employeeCode',
search: true,
sortable: true,
overHidden: true,
},
{
label: "姓名",
prop: "userName",
label: '姓名',
prop: 'employeeName',
search: true,
sortable: true,
overHidden: true,
width:120,
width: 120,
},
{
label: "一月",
prop: "january",
label: '一月',
prop: 'm01Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "二月",
prop: "february",
label: '二月',
prop: 'm02Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "三月",
prop: "march",
label: '三月',
prop: 'm03Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "四月",
prop: "april",
label: '四月',
prop: 'm04Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "五月",
prop: "may",
label: '五月',
prop: 'm05Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "六月",
prop: "june",
label: '六月',
prop: 'm06Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "七月",
prop: "july",
label: '七月',
prop: 'm07Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "八月",
prop: "august",
label: '八月',
prop: 'm08Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "九月",
prop: "september",
label: '九月',
prop: 'm09Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "十月",
prop: "october",
label: '十月',
prop: 'm10Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "十一月",
prop: "november",
label: '十一月',
prop: 'm11Score',
search: false,
sortable: true,
overHidden: true,
click: true,
},
{
label: "十二月",
prop: "december",
label: '十二月',
prop: 'm12Score',
search: false,
sortable: true,
overHidden: true,
@ -328,138 +244,96 @@ export default {
};
},
mounted() {
this.viewOpen();
// this.onLoad();
},
methods: {
cellClick(row, column, cell, event) {
const monthProps = [
"january", "february", "march", "april", "may", "june",
"july", "august", "september", "october", "november", "december"
];
if (monthProps.includes(column.property)) {
const monthMap = {
"january": "01",
"february": "02",
"march": "03",
"april": "04",
"may": "05",
"june": "06",
"july": "07",
"august": "08",
"september": "09",
"october": "10",
"november": "11",
"december": "12"
};
const currentYear = new Date().getFullYear();
this.monthValue = `${currentYear}-${monthMap[column.property]}`;
// -
cellClick(row, column) {
const monthMap = {
m01Score: '01',
m02Score: '02',
m03Score: '03',
m04Score: '04',
m05Score: '05',
m06Score: '06',
m07Score: '07',
m08Score: '08',
m09Score: '09',
m10Score: '10',
m11Score: '11',
m12Score: '12',
};
const month = monthMap[column.prop];
if (!month) return;
this.showExcel = true;
}
},
viewRow(row) {
//
this.monthValue = `${row.year}-${month}`;
this.showExcel = true;
//
this.queryPerformance();
},
queryPerformance() {
const month = this.monthValue.split("-")[1];
//
// const baseScore = 70 + parseInt(month) * 2;
// this.tableData = [{
// KPI: baseScore,
// lh: 20 + parseInt(month),
// orderTime: Math.floor(Math.random() * 10),
// keyPoint: Math.floor(Math.random() * 10),
// after: Math.floor(Math.random() * 10),
// unqualified: (Math.random() * 5).toFixed(2),
// costMoney: (Math.random() * 10).toFixed(2),
// notice: Math.floor(Math.random() * 5),
// all: Math.floor(Math.random() * 5),
// leave: Math.floor(Math.random() * 5),
// check: Math.floor(Math.random() * 5),
// add: Math.floor(Math.random() * 10),
// excellence: Math.floor(Math.random() * 5),
// cost: Math.floor(Math.random() * 5),
// total: baseScore + 20 + parseInt(month),
// }];
//
async queryPerformance() {
if (!this.monthValue) {
this.$message.warning('请选择月份');
return;
}
this.loading = true;
try {
//
// const res = await getPerformanceDetail({ month: this.monthValue });
// this.detailList = res.data || [];
// /
this.detailList = [];
} finally {
this.loading = false;
}
},
// //
currentChange(currentPage) {
this.page.currentPage = currentPage;
this.onLoad();
},
sizeChange(pageSize) {
this.page.pageSize = pageSize;
this.onLoad();
},
refreshChange() {
this.page.currentPage = 1;
this.onLoad(this.page, this.query);
},
searchReset() {
this.query = {};
this.treeDeptId = "";
this.onLoad(this.page);
this.page.currentPage = 1;
this.onLoad(this.page, this.query);
},
searchChange(params, done) {
this.query = params;
this.page.currentPage = 1;
this.onLoad(this.page, params);
this.onLoad(this.page, this.query);
done();
},
selectionChange(list) {
this.selectionList = list;
},
selectionClear() {
this.selectionList = [];
this.$refs.crud.toggleSelection();
},
onLoad() {
this.data = [
{
id: 1,
userCode: "001",
userName: "张三(2026-03)",
january: 98,
february: 97.5,
march: 96,
april: 98,
may: 96,
june: 95.5,
july: 97,
august: 98.5,
september: 95,
},
{
id: 2,
userCode: "002",
userName: "李四",
january: 98,
february: 96.5,
march: 97,
april: 96,
may: 98,
june: 97.5,
july: 95,
august: 96.5,
september: 98,
},
{
id: 3,
userCode: "003",
userName: "王五",
january: 96,
february: 98.5,
march: 97,
april: 95,
may: 97,
june: 98.5,
july: 96,
august: 96.5,
september: 97,
},
];
this.page.total = this.data.length;
//
async onLoad() {
this.loading = true;
try {
const params = {
pageNum: this.page.currentPage,
pageSize: this.page.pageSize,
...this.query,
};
const res = await pageBsEfficiencyTaskReport(params);
if (res.code === 200) {
this.data = res.data.records || [];
this.page.total = res.data.total || 0;
}
} catch (error) {
this.$message.error('加载失败');
} finally {
this.loading = false;
}
},
},
};
</script>
<style></style>

Loading…
Cancel
Save