Browse Source

修复商配刷新

dev-xx
马远东 1 year ago
parent
commit
1f92e42f9b
  1. 29
      src/api/classify/classify.js
  2. 49
      src/option/supervise/supervise.js
  3. 9
      src/views/distribution/turndelivery/deliveryDiscuss.vue
  4. 193
      src/views/supervise/IndicatorList.vue
  5. 11
      src/views/supervise/classify.vue
  6. 168
      src/views/supervise/management.vue
  7. 4
      vite.config.js

29
src/api/classify/classify.js

@ -44,3 +44,32 @@ export const $_classifyAddChild = (data) => {
data
})
}
// 指标管理编辑
export const $_classifupdateChild = (data) => {
return request({
url: '/api/logpm-supervise/classify/updateChild',
method: 'post',
data
})
}
// 指标列表list
export const $_findIndicatorsList = (data) => {
return request({
url: '/api/logpm-supervise/indicators/findIndicatorsList',
method: 'post',
data
})
}
// 指标列表查询详情
export const $_findIndicatorsDetail = (data) => {
return request({
url: '/api/logpm-supervise/indicators/findIndicatorsDetail',
method: 'post',
data
})
}

49
src/option/supervise/supervise.js

@ -90,18 +90,7 @@ export const IndicatorColumnList = [
fixed: true,
},
{
prop: 'name',
label: '指标编号',
type: 1,
values: '',
width: '130',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'description',
prop: 'classifyName',
label: '指标名称',
type: 1,
values: '',
@ -112,7 +101,7 @@ export const IndicatorColumnList = [
head: false,
},
{
prop: 'description',
prop: 'parentClassifyName',
label: '指标分类',
type: 1,
values: '',
@ -124,7 +113,7 @@ export const IndicatorColumnList = [
},
{
prop: 'createTime',
prop: 'assessDeptName',
label: '考核部门',
type: 1,
values: '',
@ -135,7 +124,7 @@ export const IndicatorColumnList = [
head: false,
},
{
prop: 'createTime',
prop: 'point',
label: '考核分数',
type: 1,
values: '',
@ -146,7 +135,7 @@ export const IndicatorColumnList = [
head: false,
},
{
prop: 'createTime',
prop: 'objectionRemark',
label: '描述',
type: 1,
values: '',
@ -157,9 +146,9 @@ export const IndicatorColumnList = [
head: false,
},
{
prop: 'createTime',
label: '照片',
type: 1,//7
prop: 'assessUserName',
label: '考核人',
type: 1,
values: '',
width: '130',
checkarr: [],
@ -169,7 +158,7 @@ export const IndicatorColumnList = [
},
{
prop: 'createTime',
label: '附件',
label: '考评时间',
type: 1,
values: '',
width: '130',
@ -179,8 +168,8 @@ export const IndicatorColumnList = [
head: false,
},
{
prop: 'createTime',
label: '考核人',
prop: 'indicatorsStatus',
label: '指标状态',
type: 1,
values: '',
width: '130',
@ -189,9 +178,10 @@ export const IndicatorColumnList = [
sortable: true,
head: false,
},
{
prop: 'createTime',
label: '考评事件',
prop: 'isObjection',
label: '是否存在异议',//1 表示提交 2 表示审核 通过 3 表示审核失败
type: 1,
values: '',
width: '130',
@ -200,6 +190,17 @@ export const IndicatorColumnList = [
sortable: true,
head: false,
},
// {
// prop: 'objectionRemark',
// label: '异议备注',
// type: 1,
// values: '',
// width: '130',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
{
prop: '',
label: '操作',

9
src/views/distribution/turndelivery/deliveryDiscuss.vue

@ -2167,7 +2167,7 @@ const PackageFn = async () => {
};
//
const ViewEvent = (val,index) => {
function ViewEvent (val,index) {
console.log(index,'下标')
wrapData.value = [];
loading.value = true; //
@ -2322,8 +2322,11 @@ const isZeroNumber = val => {
};
//
const refresh = () => {
onLoad();
// loading.value = !loading.value;
if(!wrapLoading.value){
AddInfo()
}else{
ViewEvent(Packageow.value)
}
};
//
const search = () => {

193
src/views/supervise/IndicatorList.vue

@ -8,40 +8,50 @@
<!-- 查询模块 -->
<el-form :inline="true" :model="searchFrom" class="el-fr-d">
<!-- 查询按钮 -->
<div class="el_seaTop">
<el-form-item label="考核部门:">
<el-select v-model="searchFrom.a" class="m-2" placeholder="请选择考核部门" style="width: 240px">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<div class="el_seaTop">
<el-form-item label="考核部门:">
<el-select
v-model="searchFrom.a"
class="m-2"
placeholder="请选择考核部门"
style="width: 240px"
>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="指标类型:">
<el-select v-model="searchFrom.b" class="m-2" placeholder="请选择指标类型" style="width: 240px">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="指标类型:">
<el-select
v-model="searchFrom.b"
class="m-2"
placeholder="请选择指标类型"
style="width: 240px"
>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="填写时间:">
<el-date-picker
v-model="searchFrom.c"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
:size="size"
/>
</el-form-item>
</div>
<el-form-item label="填写时间:">
<el-date-picker
v-model="searchFrom.c"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
:size="size"
/>
</el-form-item>
</div>
<el-form-item class="el-btn">
<el-button type="primary" icon="el-icon-search" @click="searchChange">查询</el-button>
<!-- <el-button icon="el-icon-delete" @click="searchReset()"> </el-button> -->
@ -128,12 +138,12 @@
class="el_listForm"
>
<el-form-item label="指标名称">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.classifyName" placeholder="暂无" />
</el-form-item>
<el-form-item label="指标分类">
<el-input
v-model="lassificationform.description"
v-model="lassificationform.parentClassifyName"
:rows="2"
type="textarea"
placeholder="暂无"
@ -141,15 +151,15 @@
</el-form-item>
<el-form-item label="考核部门">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.assessDeptName" placeholder="暂无" />
</el-form-item>
<el-form-item label="考核分数">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.point" placeholder="暂无" />
</el-form-item>
<el-form-item label="描述">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.objectionRemark" placeholder="暂无" />
</el-form-item>
<el-form-item label="附件">
@ -157,13 +167,30 @@
</el-form-item>
<el-form-item label="考核人">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.assessUserName" placeholder="暂无" />
</el-form-item>
<el-form-item label="考评时间">
<el-input v-model="lassificationform.name" placeholder="暂无" />
<el-input v-model="lassificationform.createTime" placeholder="暂无" />
</el-form-item>
<el-form-item label="是否异议">
<!-- /1 2 3 -->
<el-input
v-model="lassificationform.isObjection"
placeholder="
暂无
"
/>
</el-form-item>
<el-form-item label="指标状态">
<!-- /1 2 3 -->
<el-input
v-model="lassificationform.isObjection"
placeholder="
暂无
"
/>
</el-form-item>
<el-form-item> </el-form-item>
<el-form-item label="照片">
<div class="demo-image__preview">
<el-image
@ -188,6 +215,17 @@
</span>
</template>
</el-dialog>
<!-- 编辑弹窗 -->
<el-dialog v-model="IndicatorEditing" title="Tips" width="40%">
<template #footer>
<span class="dialog-footer">
<el-button @click="IndicatorEditing = false">关闭</el-button>
<el-button type="primary" @click="IndicatorEditingFn"> 确定 </el-button>
</span>
</template>
</el-dialog>
</basic-container>
<!-- 列表配置显示 -->
@ -208,16 +246,19 @@ import {
$_newlyadded,
$_newlyremove,
$_classifyAddChild,
$_findIndicatorsList,
$_findIndicatorsDetail,
} from '@/api/classify/classify';
const loadingclassification = ref(false); //
const classificationdata = ref([]); //
const current = ref(1); //
const total = ref(10); //
const IndicatorEditing = ref(false); //
const pageSize = ref(50);
const lassificationform = ref({}); //
const title = ref(true); //
const EditID = ref(true); //ID
const newlyAdded = ref(true); //
const newlyAdded = ref(false); //
const loadingAddPopup = ref(false); //
const selectionList = ref([]); //
const searchFrom = ref({}); //
@ -236,24 +277,20 @@ const onLoad = () => {
let data = {
current: current.value,
size: pageSize.value,
isPid: 1,
};
loadingclassification.value = true; //
$_Getclassify(data)
$_findIndicatorsList(data)
.then(res => {
console.log(res);
if (res.data.data.records) {
classificationdata.value = res.data.data.records; //
} else {
}
total.value = res.data.data.total; //
})
.catch(res => {})
.finally(() => {
loadingclassification.value = false; //
});
classificationdata.value = [{}];
};
onLoad();
//
@ -264,9 +301,7 @@ const currentChange = () => {};
const ClassificationDditing = val => {
EditID.value = val.row.id; //ID
let data = val.row;
lassificationform.value.name = data.name; //
lassificationform.value.description = data.description; //
lassificationform.value.remark = data.remark; //
IndicatorEditing.value = true; //
};
//
@ -337,7 +372,6 @@ const CategoryDeletion = val => {
};
// /
const newlyAddedFn = () => {
loadingAddPopup.value = true; //
loadingclassification.value = true; //
let data = {
...lassificationform.value,
@ -379,11 +413,42 @@ const searchHide = () => {
//
const ClassificationIndicatorView = val => {
console.log(val, '查看信息');
newlyAdded.value = true; //
$_findIndicatorsDetail({ id: val.row.id })
.then(res => {
loadingAddPopup.value = true; //
console.log(res, '查看信息返回值');
lassificationform.value = res.data.data; //
// 1 2 3
if(res.data.data. indicatorsStatus== 1){
lassificationform.value.isObjection='提交'
}else if(res.data.data.isObjection == 2){
lassificationform.value.isObjection='审核通过'
}else if(res.data.data.isObjection == 3){
lassificationform.value.isObjection='审核失败'
}
// 0 1
if(res.data.data.isObjection ){
lassificationform.value.isObjection='没有'
}else{
}lassificationform.value.isObjection='存在'
if (res.data.data.pictures.length) {
//
res.data.data.pictures.forEach(res => {
srcList.value.push(res.url);
});
}
})
.catch(res => {})
.finally(() => {
loadingAddPopup.value = false; //
});
};
//
const IndicatorEditingFn = () => {};
//
const searchChange=()=>{
}
const searchChange = () => {};
</script>
<style scoped lang="scss">
@ -419,21 +484,21 @@ const searchChange=()=>{
width: 100%;
height: 200px;
}
.el_header_top{
.el-form{
.el_header_top {
.el-form {
display: flex;
justify-content: space-between;
width: 100%;
.el-form-item{
margin: 4px 0;
margin-right: 10px;
}
.el-btn{
margin-right: 0;
}
.el-form-item {
margin: 4px 0;
margin-right: 10px;
}
:deep(.el-date-editor){
height: 100% !important;
.el-btn {
margin-right: 0;
}
}
:deep(.el-date-editor) {
height: 100% !important;
}
}
</style>

11
src/views/supervise/classify.vue

@ -1,9 +1,7 @@
<template>
<basic-container>
<!-- 首页表格 -->
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
<el-tab-pane label="分类列表" name="first"> </el-tab-pane>
</el-tabs>
<div class="avue-crud">
<!-- 搜索模块 -->
<el-row v-if="search">
@ -242,14 +240,17 @@ const CategoryDeletion = val => {
message: res.data.msg,
type: 'success',
});
onLoad();
})
.catch(res => {})
.finally(() => {
loadingclassification.value = false; //
});
onLoad();
})
.catch(() => {});
.catch(() => {}).finally(()=>{
loadingclassification.value = false; //
});
};
// /
const newlyAddedFn = () => {

168
src/views/supervise/management.vue

@ -1,9 +1,7 @@
<template>
<basic-container>
<!-- 首页表格 -->
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
<el-tab-pane label="分类列表" name="first"> </el-tab-pane>
</el-tabs>
<div class="avue-crud">
<!-- 搜索模块 -->
<el-row v-if="search">
@ -88,12 +86,17 @@
<el-dialog v-model="newlyAdded" :title="title ? '新增指标' : '编辑指标'" width="30%">
<el-form v-loading="loadingAddPopup" :model="lassificationform" label-width="120px">
<el-form-item label="指标分类">
<el-select v-model="classificationoptionsvalue" filterable placeholder="请选择指标分类" style="width: 240px">
<el-select
v-model="lassificationform.classificationoptionsvalue"
filterable
placeholder="请选择指标分类"
style="width:100%"
>
<el-option
v-for="item in classificationoptions"
:key="item.value"
:label="item.label"
:value="item.value"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
@ -110,6 +113,18 @@
placeholder="请输入指标描述"
/>
</el-form-item>
<div class="el_integral">
<el-form-item label="积分值">
<el-input-number
v-for="item in PointsList"
v-model="item.integral"
class="mx-4"
controls-position="right"
@change="handleChange"
/>
</el-form-item>
<div class="el_add" @click="integralAdd">+</div>
</div>
</el-form>
<template #footer>
<span class="dialog-footer">
@ -120,6 +135,9 @@
</span>
</template>
</el-dialog>
</basic-container>
<!-- 列表配置显示 -->
@ -135,7 +153,14 @@
import { ElMessage, ElMessageBox } from 'element-plus';
import { ref, reactive, computed, onMounted } from 'vue';
import { classificationColumnList } from '@/option/supervise/supervise.js';
import { $_Getclassify, $_newlyadded, $_newlyremove,$_selectParentCalssifyList } from '@/api/classify/classify';
import {
$_Getclassify,
$_newlyadded,
$_newlyremove,
$_selectParentCalssifyList,
$_classifyAddChild,
$_classifupdateChild,
} from '@/api/classify/classify';
const loadingclassification = ref(false); //
const classificationdata = ref([]); //
const current = ref(1); //
@ -147,8 +172,9 @@ const EditID = ref(true); //编辑需要的ID
const newlyAdded = ref(false); //
const loadingAddPopup = ref(false); //
const selectionList = ref([]); //
const classificationoptions= ref([]);//
const classificationoptionsvalue = ref([]);//
const classificationoptions = ref([]); //
const classificationoptionsvalue = ref([]); //
const PointsList = ref([{ integral: 0 }]); //
const onLoad = () => {
let data = {
current: current.value,
@ -166,12 +192,12 @@ const onLoad = () => {
.finally(() => {
loadingclassification.value = false; //
});
//
$_selectParentCalssifyList().then(res=>{
console.log(res,'指标分类');
classificationoptions.value = res.data.data.records
})
//
$_selectParentCalssifyList().then(res => {
console.log(res, '指标分类');
classificationoptions.value = res.data.data;
console.log(classificationoptions.value, '存储的指标');
});
};
onLoad();
//
@ -180,13 +206,19 @@ const currentPage = () => {};
const currentChange = () => {};
//
const ClassificationDditing = val => {
console.log(val);
EditID.value = val.row.id; //ID
title.value = false; //
newlyAdded.value = true; //
PointsList.value=[];//
let data = val.row;
lassificationform.value.classificationoptionsvalue = data.pid; //
lassificationform.value.name = data.name; //
lassificationform.value.description = data.description; //
lassificationform.value.remark = data.remark; //
//
data.pointsEntities.forEach(res=>{
PointsList.value.push({integral:res.point})
})
};
//
@ -194,6 +226,7 @@ const AddCategory = () => {
title.value = true; //
newlyAdded.value = true; //
lassificationform.value = {}; //
PointsList.value=[{integral:0}];//
};
//
@ -237,7 +270,6 @@ const CategoryDeletion = val => {
})
.then(() => {
loadingclassification.value = true; //
console.log(val, '分类删除');
let data = {
ids: [],
};
@ -250,52 +282,86 @@ const CategoryDeletion = val => {
message: res.data.msg,
type: 'success',
});
onLoad();
})
.catch(res => {})
.finally(() => {
loadingclassification.value = false; //
});
onLoad();
})
.catch(() => {});
};
// /
//
const newlyAddedFn = () => {
loadingAddPopup.value = true; //
loadingclassification.value = true; //
let data = {
...lassificationform.value,
pId: 0, /// 0
};
name: lassificationform.value.name, //
description: lassificationform.value.description, //
pid: lassificationform.value.classificationoptionsvalue,//ID
pointsEntities: [], //
};
loadingAddPopup.value = true; //
if (title.value) {
console.log(data, '新增分类');
//
PointsList.value.forEach(res => {
data['pointsEntities'].push({ point: res.integral });
});
$_classifyAddChild(data)
.then(res => {
if (res.data.code == 200) {
newlyAdded.value = false; //
ElMessage({
message: res.data.msg,
type: 'success',
});
onLoad();
}
})
.catch(res => {})
.finally(() => {
loadingAddPopup.value = false; //
});
} else {
data.id = EditID.value;
}
$_newlyadded(data)
.then(res => {
console.log(res, '新增成功返回值');
if (res.data.code == 200) {
onLoad();
//
data.id =EditID.value,//id
PointsList.value.forEach(res => {
data['pointsEntities'].push({ point: res.integral });
});
$_classifupdateChild(data).then(res=>{
console.log(res,'编辑成功');
if(res.data.code == 200){
newlyAdded.value = false; //
ElMessage({
message: res.data.msg,
type: 'success',
});
message: res.data.msg,
type: 'success',
});
onLoad();
}
}).catch(res=>{
}).finally(()=>{
loadingAddPopup.value = false; //
})
.catch(res => {})
.finally(() => {
loadingAddPopup.value = false; //
loadingclassification.value = false; //
});
}
};
//
const selectionChange = list => {
selectionList.value = list;
console.log(selectionList.value, '已经选中的数据');
};
//
const integralAdd = () => {
PointsList.value.push({ integral: 0 });
};
//
const IntegralEditing=()=>{
}
//
const PointsManagementFn=()=>{
}
</script>
<style scoped lang="scss">
@ -310,4 +376,24 @@ const selectionChange = list => {
display: flex;
justify-content: space-evenly;
}
:deep(.el_integral) {
display: flex;
.el-form-item {
width: 100% !important;
margin-right: 0;
.el-input-number {
width: 100%;
margin-bottom: 14px;
}
}
.el_add {
font-size: 20px;
width: 24px;
height: 24px;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
}
}
</style>

4
vite.config.js

@ -23,8 +23,8 @@ export default ({ mode, command }) => {
// 新zyc
// target: 'http://192.168.6.116:8777',
// target: 'http://192.168.6.122:8777',
target: 'http://192.168.10.57:13000',
// target: 'http://192.168.10.25:2888',
// target: 'http://192.168.10.57:13000',
target: 'http://192.168.10.25:13000',
// target: 'http://192.168.6.169:9777',//CYZ
// target: 'http://192.168.10.57:13000',
// target: 'http://192.168.10.200:13000',

Loading…
Cancel
Save