质量缺陷修复

dev-scheduling
jinna 3 weeks ago
parent 8ee0e7b255
commit baff048dec
  1. 9
      src/views/productionTesting/prPlanTestRec.vue
  2. 32
      src/views/productionTesting/productionQuality.vue
  3. 881
      src/views/qualityManagement/reviewFormMess/index.vue

@ -66,7 +66,7 @@ export default {
labelWidth: 120,
searchLabelWidth: 120,
menu: true,
menuWidth: 120,
menuWidth: 80,
dialogWidth: 1200,
dialogClickModal: false,
searchEnter: true,
@ -81,13 +81,14 @@ export default {
searchLabelPosition:'left',
searchGutter:24,
searchSpan:6,
menuAlign: 'left',
menuAlign: 'center',
gridBtn:false,
searchMenuPosition:'right',
column: [
{
label: '流程卡号',
prop: 'cardNo',
prop:"code",
// prop: 'cardNo',
// bind: 'prWorkPlan.prWorkOrder.cardNo',
width: 200,
search: true,
@ -103,7 +104,7 @@ export default {
},
{
label: '转试人',
prop: 'testUserRealName',
prop: 'testUserName',
// bind: 'testUser.userName',
width: 200,
search: false,

@ -165,24 +165,28 @@
circle
type="danger"
icon="el-icon-delete"
@click="removeRules(scope.row.wpItemDetailList,subScope.$index, subScope.row)"
@click="removeRules(scope.row.wpItemDetailList,subScope.$index, scope.row)"
/>
</template>
</el-table-column>
<el-table-column label="镀前镀后" prop="testType" align="center">
<template #default="scope">
<el-input v-model="scope.row.testType" :disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "></el-input>
<template #default="scope1">
<el-input v-model="scope1.row.testType"
:disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "
></el-input>
</template>
</el-table-column>
<el-table-column label="尺寸" prop="ruleSize" align="center">
<template #default="scope">
<el-input v-model="scope.row.ruleSize" :disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "></el-input>
<template #default="scope1">
<el-input v-model="scope1.row.ruleSize"
:disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "
></el-input>
</template>
</el-table-column>
<el-table-column label="量具" prop="tools" align="center">
<template #default="scope">
<template #default="scope1">
<!-- {{scope.row.mtName}} -->
<el-input v-model="scope.row.mtName" :disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "></el-input>
<el-input v-model="scope1.row.mtName" :disabled="scope.row.checkUserRealName != null && scope.row.checkUserRealName != '' "></el-input>
</template>
</el-table-column>
<el-table-column label="量具编号" prop="trialNo" align="center">
@ -261,7 +265,7 @@
circle
type="danger"
icon="el-icon-delete"
@click="removeSpecimen(subScope.$index, subScope.row)"
@click="removeSpecimen(subScope.$index, subScope.row,scope.row)"
/>
</template>
</el-table-column>
@ -344,17 +348,17 @@
>
<template #default="scope"> {{scope.row.standard && scope.row.standard.name}} </template>
</el-table-column>
<el-table-column label="标准值" prop="trialStandard" align="center" width="150px">
<template #default="scope">
<!-- <el-table-column label="标准值" prop="trialStandard" align="center" width="150px">
<template #default="scope"> -->
<!-- {{scope.row.standard && scope.row.standard.standardValue}}
{{'(' + scope.row.standard && scope.row.standard.downValue + '~' + scope.row.standard && scope.row.standard.upValue+ ')'}} -->
<span v-if="scope.row.standard">
<!-- <span v-if="scope.row.standard">
{{scope.row.standard.standardValue}}
<span v-if="scope.row.standard.downValue && scope.row.standard.upValue">{{'(' + scope.row.standard.downValue + '~' + scope.row.standard.upValue+ ')'}}</span>
</span>
<span v-else></span>
</template>
</el-table-column>
</el-table-column> -->
<!-- <el-table-column label="上下限" prop="trialStandard" align="center"></el-table-column>
<el-table-column label="下限" prop="trialStandard" align="center"></el-table-column> -->
<el-table-column
@ -975,8 +979,8 @@ export default {
}
this.thicknessData.push({})
},
removeSpecimen(index,row){
if(row.checkUserRealName != null && row.checkUserRealName != ''){
removeSpecimen(index,row,val){
if(val.checkUserRealName != null && val.checkUserRealName != ''){
return
}
this.thicknessData.splice(index,1)

@ -1,446 +1,481 @@
<template>
<basic-container>
<el-tabs v-model="tabPosition" class="demo-tabs" @tab-change="tabPositionChange">
<el-tab-pane label="erp审理" name="erpHear">
<avue-crud :option="option" :table-loading="loading" :data="data" v-model="form" v-model:page="page" ref="crud"
@row-del="rowDel" @search-change="searchChange" @search-reset="searchReset"
@selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange"
@refresh-change="refreshChange" @on-load="onLoad">
<template #menu-left>
</template>
<template #menu-right>
</template>
<template #menu="{ row }">
<basic-container>
<el-tabs v-model="tabPosition" class="demo-tabs" @tab-change="tabPositionChange">
<el-tab-pane label="erp审理" name="erpHear"> </el-tab-pane>
<el-tab-pane label="内部审理" name="insideHear"> </el-tab-pane>
</el-tabs>
<div v-if="tabPosition == 'erpHear'">
<avue-crud
:option="option"
:table-loading="loading"
:data="data"
v-model="form"
v-model:page="page"
ref="crud"
@row-del="rowDel"
@search-change="searchChange"
@search-reset="searchReset"
@selection-change="selectionChange"
@current-change="currentChange"
@size-change="sizeChange"
@refresh-change="refreshChange"
@on-load="onLoad"
>
<template #menu-left> </template>
<template #menu-right> </template>
<template #menu="{ row }"> </template>
</template>
<template #heatTreat="scope">
<el-tag v-if="scope.row.afterPlating" type="success"></el-tag>
<el-tag v-else type="warning"></el-tag>
</template>
</avue-crud>
</div>
<div v-if="tabPosition == 'insideHear'">
<avue-crud
:option="insideOption"
:table-loading="loading"
:data="insideData"
v-model="form"
v-model:page="insidePage"
ref="crud"
@row-del="rowDel"
@search-change="searchChange"
@search-reset="searchReset"
@selection-change="selectionChange"
@current-change="currentChange"
@size-change="sizeChange"
@refresh-change="refreshChange"
@on-load="onLoad"
>
<template #menu-left> </template>
<template #menu-right> </template>
<template #qty="{ row }">
<span v-if="row.bizType == 1">{{ row.reDoNum }}</span>
<span v-if="row.bizType == 2">{{ row.scrapNum }}</span>
</template>
<template #menu="{ row }">
<el-button
type="text"
@click="reviewFn(row)"
v-if="row.selfReviewFlag != 1 && row.selfReviewFlag != 2"
>审理</el-button
>
</template>
</avue-crud>
</div>
<template #heatTreat="scope">
<el-tag v-if="scope.row.afterPlating" type="success"></el-tag>
<el-tag v-else type="warning"></el-tag>
</template>
</avue-crud>
</el-tab-pane>
<el-tab-pane label="内部审理" name="insideHear">
<avue-crud :option="insideOption" :table-loading="loading" :data="insideData" v-model="form" v-model:page="insidePage" ref="crud"
@row-del="rowDel" @search-change="searchChange" @search-reset="searchReset"
@selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange"
@refresh-change="refreshChange" @on-load="onLoad">
<template #menu-left>
</template>
<template #menu-right>
</template>
<template #qty="{row}">
<span v-if="row.bizType == 1">{{row.reDoNum}}</span>
<span v-if="row.bizType == 2">{{row.scrapNum}}</span>
</template>
<template #menu="{ row }">
<el-button type="text" @click="reviewFn(row)" v-if="row.selfReviewFlag != 1 && row.selfReviewFlag != 2">审理</el-button>
</template>
</avue-crud>
</el-tab-pane>
</el-tabs>
<reviewDialog v-if="isReviewOpen" :id="checkId" :showDialog="isReviewOpen" @closeDialog="closeDialog"></reviewDialog>
</basic-container>
<reviewDialog
v-if="isReviewOpen"
:id="checkId"
:showDialog="isReviewOpen"
@closeDialog="closeDialog"
></reviewDialog>
</basic-container>
</template>
<script>
import reviewDialog from "@/views/qualityManagement/reworkOrderReview/components/reviewDialog.vue"
import reviewDialog from '@/views/qualityManagement/reworkOrderReview/components/reviewDialog.vue';
import {
add,
getRole,
getRoleAlias,
getRoleTreeById,
grant,
grantTree,
remove,
update,
add,
getRole,
getRoleAlias,
getRoleTreeById,
grant,
grantTree,
remove,
update,
} from '@/api/system/role';
import { mapGetters } from 'vuex';
import { validatenull } from '@/utils/validate';
import {insideOption,erpOption} from './options'
import {getInnerReviewList,getErpReviewList} from "@/api/qualityManagement/productionTesting/reviewFormMess"
import { insideOption, erpOption } from './options';
import {
getInnerReviewList,
getErpReviewList,
} from '@/api/qualityManagement/productionTesting/reviewFormMess';
export default {
components: {
reviewDialog
},
data() {
return {
checkId:'',
insideQuery:{},
isReviewOpen:false,
tabPosition:'erpHear',
inBatchesOpen: false,
platingSmallOpen: false,
planOrderArr: [],
isOpen: false,
rowItem: {},
poId: null,
form: {},
box: false,
props: {
label: 'title',
value: 'key',
},
menuGrantList: [],
dataScopeGrantList: [],
apiScopeGrantList: [],
apiGrantList: [],
menuTreeObj: [],
dataScopeTreeObj: [],
apiScopeTreeObj: [],
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
total: 0,
},
option: erpOption,
insideOption:insideOption,
components: {
reviewDialog,
},
data() {
return {
checkId: '',
insideQuery: {},
isReviewOpen: false,
tabPosition: 'erpHear',
inBatchesOpen: false,
platingSmallOpen: false,
planOrderArr: [],
isOpen: false,
rowItem: {},
poId: null,
form: {},
box: false,
props: {
label: 'title',
value: 'key',
},
menuGrantList: [],
dataScopeGrantList: [],
apiScopeGrantList: [],
apiGrantList: [],
menuTreeObj: [],
dataScopeTreeObj: [],
apiScopeTreeObj: [],
selectionList: [],
query: {},
loading: true,
page: {
pageSize: 10,
currentPage: 1,
total: 0,
},
option: erpOption,
insideOption: insideOption,
data: [],
isRushOpen: false,//
isBatchOpen: false,//
insideData:[],
insidePage:{
pageSize: 10,
currentPage: 1,
total: 0,
}
};
data: [],
isRushOpen: false, //
isBatchOpen: false, //
insideData: [],
insidePage: {
pageSize: 10,
currentPage: 1,
total: 0,
},
};
},
methods: {
tabPositionChange(val) {
this.tabPosition = val;
if (this.tabPosition == 'erpHear') {
this.getErpList();
} else if (this.tabPosition == 'insideHear') {
this.getInsideList();
}
},
methods: {
tabPositionChange(val){
this.tabPosition = val
if(this.tabPosition == 'erpHear'){
this.getErpList()
}else if(this.tabPosition == 'insideHear'){
this.getInsideList()
}
},
reviewFn(row){
this.checkId = row.id
this.isReviewOpen = true
},
getErpList(){
this.loading = true;
getErpReviewList({
current:this.page.currentPage,
size:this.page.pageSize,
...this.query
}).then(res =>{
this.data = res.data.data.records
this.page.total = res.data.data.total
this.loading = false
})
},
getInsideList(){
if(this.insideQuery.crDate){
delete this.insideQuery.crDate
}
if(this.insideQuery.reviewDate){
delete this.insideQuery.reviewDate
}
getInnerReviewList({
current:this.insidePage.currentPage,
size:this.insidePage.pageSize,
// bizType:0,
...this.insideQuery
}).then(res =>{
this.insideData = res.data.data.records
this.insidePage.total = res.data.data.total
})
},
//
batchReceiving() {
this.$confirm('确定将选择数据批量接收?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
// return remove(row.id);
})
.then(() => {
// this.onLoad(this.page);
// this.$message({
// type: 'success',
// message: '!',
// });
});
},
//
batchDel() {
this.$confirm('确定将选择数据批量删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
// return remove(row.id);
})
.then(() => {
// this.onLoad(this.page);
// this.$message({
// type: 'success',
// message: '!',
// });
});
},
//
rushFn() {
this.isRushOpen = true
},
closeDialog(val) {
this.isRushOpen = false
this.isBatchOpen = false
this.isReviewOpen = false
if(val){
this.tabPositionChange('insideHear')
}
},
inBatchesFn(row) {
this.rowItem = row;
this.isBatchOpen = true;
},
subclass() {
this.platingSmallOpen = true;
},
lookProcessRoute(row) {
this.isOpen = true;
this.rowItem = row;
},
cancel(refresh) {
if (refresh) {
this.$refs.myTable.load();
}
this.inBatchesOpen = false;
this.isOpen = false;
this.planFormOpen = false;
this.platingSmallOpen = false;
},
initData(roleId) {
getRoleTreeById(roleId).then(res => {
const column = this.findObject(this.option.column, 'parentId');
column.dicData = res.data.data;
});
},
submit() {
const menuList = this.$refs.treeMenu.getCheckedKeys();
const dataScopeList = this.$refs.treeDataScope.getCheckedKeys();
const apiScopeList = this.$refs.treeApiScope.getCheckedKeys();
grant(this.idsArray, menuList, dataScopeList, apiScopeList).then(() => {
this.box = false;
this.$message({
type: 'success',
message: '操作成功!',
});
this.selectionList = [];
this.onLoad(this.page);
});
},
rowSave(row, done, loading) {
add(row).then(
() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
done();
},
error => {
window.console.log(error);
loading();
}
);
},
rowUpdate(row, index, done, loading) {
update(row).then(
() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
done();
},
error => {
window.console.log(error);
loading();
}
);
reviewFn(row) {
this.checkId = row.id;
this.isReviewOpen = true;
},
getErpList() {
this.loading = true;
getErpReviewList({
current: this.page.currentPage,
size: this.page.pageSize,
...this.query,
}).then(res => {
this.data = res.data.data.records;
this.page.total = res.data.data.total;
this.loading = false;
});
},
getInsideList() {
this.loading = true;
if (this.insideQuery.crDate) {
delete this.insideQuery.crDate;
}
if (this.insideQuery.reviewDate) {
delete this.insideQuery.reviewDate;
}
getInnerReviewList({
current: this.insidePage.currentPage,
size: this.insidePage.pageSize,
// bizType:0,
...this.insideQuery,
}).then(res => {
this.loading = false;
this.insideData = res.data.data.records;
this.insidePage.total = res.data.data.total;
});
},
//
batchReceiving() {
this.$confirm('确定将选择数据批量接收?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
// return remove(row.id);
})
.then(() => {
// this.onLoad(this.page);
// this.$message({
// type: 'success',
// message: '!',
// });
});
},
//
batchDel() {
this.$confirm('确定将选择数据批量删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
// return remove(row.id);
})
.then(() => {
// this.onLoad(this.page);
// this.$message({
// type: 'success',
// message: '!',
// });
});
},
//
rushFn() {
this.isRushOpen = true;
},
closeDialog(val) {
this.isRushOpen = false;
this.isBatchOpen = false;
this.isReviewOpen = false;
if (val) {
this.tabPositionChange('insideHear');
}
},
inBatchesFn(row) {
this.rowItem = row;
this.isBatchOpen = true;
},
subclass() {
this.platingSmallOpen = true;
},
lookProcessRoute(row) {
this.isOpen = true;
this.rowItem = row;
},
cancel(refresh) {
if (refresh) {
this.$refs.myTable.load();
}
this.inBatchesOpen = false;
this.isOpen = false;
this.planFormOpen = false;
this.platingSmallOpen = false;
},
initData(roleId) {
getRoleTreeById(roleId).then(res => {
const column = this.findObject(this.option.column, 'parentId');
column.dicData = res.data.data;
});
},
submit() {
const menuList = this.$refs.treeMenu.getCheckedKeys();
const dataScopeList = this.$refs.treeDataScope.getCheckedKeys();
const apiScopeList = this.$refs.treeApiScope.getCheckedKeys();
grant(this.idsArray, menuList, dataScopeList, apiScopeList).then(() => {
this.box = false;
this.$message({
type: 'success',
message: '操作成功!',
});
this.selectionList = [];
this.onLoad(this.page);
});
},
rowSave(row, done, loading) {
add(row).then(
() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
done();
},
rowDel(row) {
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(row.id);
})
.then(() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
error => {
window.console.log(error);
loading();
}
);
},
rowUpdate(row, index, done, loading) {
update(row).then(
() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
done();
},
error => {
window.console.log(error);
loading();
}
);
},
rowDel(row) {
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(row.id);
})
.then(() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
});
},
searchReset() {
if(this.tabPosition == 'erpHear'){
this.query = {}
this.getErpList()
}else if(this.tabPosition == 'insideHear'){
this.insideQuery = {}
this.getInsideList()
}
// this.query = {};
// this.onLoad(this.page);
},
searchChange(params, done) {
console.log('tab---------',this.tabPosition)
if(this.tabPosition == 'erpHear'){
this.query = params;
this.page.currentPage = 1;
this.getErpList();
done();
}else if(this.tabPosition == 'insideHear'){
this.insideQuery = params;
this.insideQuery.createTimeStart = params.crDate && params.crDate.length != 0 && params.crDate[0]
this.insideQuery.createTimeEnd = params.crDate && params.crDate.length != 0 && params.crDate[1]
this.insideQuery.reviewTimeStart = params.reviewDate && params.reviewDate.length != 0 && params.reviewDate[1]
this.insideQuery.reviewTimeEnd = params.reviewDate && params.reviewDate.length != 0 && params.reviewDate[1]
this.insidePage.currentPage = 1;
this.getInsideList();
done();
}
},
selectionChange(list) {
this.selectionList = list;
},
selectionClear() {
this.selectionList = [];
this.$refs.crud.toggleSelection();
},
beforeOpen(done, type) {
if (['add', 'edit'].includes(type)) {
this.initData(this.form.id);
}
if (['edit', 'view'].includes(type)) {
if (this.form.parentId === '0') {
this.form.parentId = '';
}
}
getRoleAlias().then(res => {
const column = this.findObject(this.option.column, 'currentAlias');
column.dicData = res.data.data;
});
done();
},
handleRole() {
if (this.selectionList.length !== 1) {
this.$message.warning('只能选择一条数据');
return;
}
this.menuTreeObj = [];
this.dataScopeTreeObj = [];
this.apiScopeTreeObj = [];
grantTree().then(res => {
this.menuGrantList = res.data.data.menu;
this.dataScopeGrantList = res.data.data.dataScope;
this.apiScopeGrantList = res.data.data.apiScope;
getRole(this.ids).then(res => {
this.menuTreeObj = res.data.data.menu;
this.dataScopeTreeObj = res.data.data.dataScope;
this.apiScopeTreeObj = res.data.data.apiScope;
this.box = true;
});
});
},
handleRowRole(row) {
this.menuTreeObj = [];
this.dataScopeTreeObj = [];
this.apiScopeTreeObj = [];
grantTree().then(res => {
this.menuGrantList = res.data.data.menu;
this.dataScopeGrantList = res.data.data.dataScope;
this.apiScopeGrantList = res.data.data.apiScope;
getRole(row.id).then(res => {
this.menuTreeObj = res.data.data.menu;
this.dataScopeTreeObj = res.data.data.dataScope;
this.apiScopeTreeObj = res.data.data.apiScope;
this.selectionList.push(row);
this.box = true;
});
});
},
handleDelete() {
if (this.selectionList.length === 0) {
this.$message.warning('请选择至少一条数据');
return;
}
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(this.ids);
})
.then(() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
this.$refs.crud.toggleSelection();
});
},
currentChange(currentPage) {
this.page.currentPage = currentPage;
},
sizeChange(pageSize) {
this.page.pageSize = pageSize;
},
refreshChange() {
this.onLoad(this.page, this.query);
},
handleChange(file, fileList) {
// proxy.$Export.xlsx(file.raw).then((data) => {
// data.value = data.results;
// });
this.$message({
type: 'success',
message: '操作成功!',
});
},
searchReset() {
if (this.tabPosition == 'erpHear') {
this.query = {};
this.getErpList();
} else if (this.tabPosition == 'insideHear') {
this.insideQuery = {};
this.getInsideList();
}
// this.query = {};
// this.onLoad(this.page);
},
searchChange(params, done) {
console.log('tab---------', this.tabPosition);
if (this.tabPosition == 'erpHear') {
this.query = params;
this.page.currentPage = 1;
this.getErpList();
done();
} else if (this.tabPosition == 'insideHear') {
this.insideQuery = params;
this.insideQuery.createTimeStart =
params.crDate && params.crDate.length != 0 && params.crDate[0];
this.insideQuery.createTimeEnd =
params.crDate && params.crDate.length != 0 && params.crDate[1];
this.insideQuery.reviewTimeStart =
params.reviewDate && params.reviewDate.length != 0 && params.reviewDate[1];
this.insideQuery.reviewTimeEnd =
params.reviewDate && params.reviewDate.length != 0 && params.reviewDate[1];
this.insidePage.currentPage = 1;
this.getInsideList();
done();
}
},
selectionChange(list) {
this.selectionList = list;
},
selectionClear() {
this.selectionList = [];
this.$refs.crud.toggleSelection();
},
beforeOpen(done, type) {
if (['add', 'edit'].includes(type)) {
this.initData(this.form.id);
}
if (['edit', 'view'].includes(type)) {
if (this.form.parentId === '0') {
this.form.parentId = '';
}
}
getRoleAlias().then(res => {
const column = this.findObject(this.option.column, 'currentAlias');
column.dicData = res.data.data;
});
done();
},
handleRole() {
if (this.selectionList.length !== 1) {
this.$message.warning('只能选择一条数据');
return;
}
this.menuTreeObj = [];
this.dataScopeTreeObj = [];
this.apiScopeTreeObj = [];
grantTree().then(res => {
this.menuGrantList = res.data.data.menu;
this.dataScopeGrantList = res.data.data.dataScope;
this.apiScopeGrantList = res.data.data.apiScope;
getRole(this.ids).then(res => {
this.menuTreeObj = res.data.data.menu;
this.dataScopeTreeObj = res.data.data.dataScope;
this.apiScopeTreeObj = res.data.data.apiScope;
this.box = true;
});
});
},
handleRowRole(row) {
this.menuTreeObj = [];
this.dataScopeTreeObj = [];
this.apiScopeTreeObj = [];
grantTree().then(res => {
this.menuGrantList = res.data.data.menu;
this.dataScopeGrantList = res.data.data.dataScope;
this.apiScopeGrantList = res.data.data.apiScope;
getRole(row.id).then(res => {
this.menuTreeObj = res.data.data.menu;
this.dataScopeTreeObj = res.data.data.dataScope;
this.apiScopeTreeObj = res.data.data.apiScope;
this.selectionList.push(row);
this.box = true;
});
});
},
handleDelete() {
if (this.selectionList.length === 0) {
this.$message.warning('请选择至少一条数据');
return;
}
this.$confirm('确定将选择数据删除?', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
return remove(this.ids);
})
.then(() => {
this.onLoad(this.page);
this.$message({
type: 'success',
message: '操作成功!',
});
this.$refs.crud.toggleSelection();
});
},
currentChange(currentPage) {
this.page.currentPage = currentPage;
},
sizeChange(pageSize) {
this.page.pageSize = pageSize;
},
refreshChange() {
this.onLoad(this.page, this.query);
},
handleChange(file, fileList) {
// proxy.$Export.xlsx(file.raw).then((data) => {
// data.value = data.results;
// });
this.$message({
type: 'success',
message: '操作成功!',
});
},
onLoad(page, params = {}) {
this.getErpList()
// this.loading = true;
// this.data = [
onLoad(page, params = {}) {
this.getErpList();
// this.loading = true;
// this.data = [
// ]
// this.page.total = this.data.length
// // getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
// // this.data = res.data.data.records;
// this.loading = false;
// // this.page.total = res.data.data.total
// // this.selectionClear();
// // });
},
// ]
// this.page.total = this.data.length
// // getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
// // this.data = res.data.data.records;
// this.loading = false;
// // this.page.total = res.data.data.total
// // this.selectionClear();
// // });
},
mounted() {
}
},
mounted() {},
};
</script>

Loading…
Cancel
Save