案例
\views\bc-couponcenter\coupon-main\components\page\index.vue
\views\bc\bc-mall\bc-mall-order-cg\d-list
index.vue
data() {
return {
// #region 临时交互数据
selectedDataV: {},
changeField: {
changed: false,
},
selectedOpUser: {},
selectedUserType: [],
selectedError: '',
data: {},
dialog: {
// view: {
// fromMkey: "report-view",
// data: {},
// show: false,
// title: "详情"
// }
},
// #endregion 临时交互数据
// #region 分页进度条
currentRate: 90,
gradientColor: {
'0%': '#3fecff',
'100%': '#6149f6',
},
mapperTypes: {
current: 11,
// 未完成工单
"11": {}
},
// #endregion 分页进度条
num: 3,
footConfig: {
// selected: "couponcenter-coupon-main",
},
//公共必须参数 start
scrollId: "",
rootMeta: {
mkey: null,
field: null
},
filter: {
pageIndex: 1,
pageSize: 21,
word: '',
status: -1,
// _menuId: null,
_nodejs: "common-data",
},
dimData: {
status: []
},
//公共参数 end
//===========公共部分 start
userActions: [],
descriptionEmpty: "数据加载中",
firstLoad: true,
loading: false,
merc: {
data: [],
value: null,
},
used: {
data: [],
paging: {}
},
pullToBottom: {
loading: true,
finished: false,
error: false,
errorText: "请求失败,点击重新加载",
finishedText: "没有更多了",
},
//===========公共部分 end
};
},
// #region 业务处理
handleLoadMyBiz(v) {
let that = this;
that.filter.word = v;
// that.dialog.sqjr.show = false;
// that.dialog.dh.show = false;
method.loadDataComm(that, {
pushName: this.filter.word,
// _columnAlias: '',
_mapperType: that.mapperTypes.current || 1,
}, that.filter, {
mkey: "mall-coupon",
field: "receive",
}, {})
},
// #endregion 业务处理
method.js
import methodData from "../data/method-data";
// import methodPlugin from "../data/method-plugin";
import methodRulesChanges from '../data/method-rules-changes';
// import methodSave from '../save/method';
//,"paging":{"pageSize":15,"totalCount":13,"totalPage":0,"pageIndex":1,"currentCount":13,"currentRate":100,"limtStartIndex":0}
/* eslint-disable no-unused-vars */
/* eslint-disable no-undef */
export default {
init(that) {
// this.loadDataComm(that);
that.rules = methodRulesChanges.rules;
that.changeEvents = methodRulesChanges.changes(that);
that.fieldAttrs = methodRulesChanges.attrs;
// that.dimData.status = methodData.dimData.status.map(temp => {
// return {
// "value": temp.value,
// "text": temp.name,
// }
// });
// methodPlugin.getUserFunction(that);
that.handleLoadMyBiz();
},
loadDataComm(that, filterT = {}, filter = {}, meta = {}, dataCol = {}) {
// 数据二次处理
let thisT = this;
const callback = (thatN, dataColN, methodDataN) => {
thisT.callbackMyBiz(thatN, dataColN, methodDataN);
}
that.$bsAjax.getBizPage(that, methodData, {...filter,...filterT}, meta, dataCol, callback);
},
callbackMyBiz(that, dataCol, methodData) {
// const auditStatusClass = methodData.auditStatusClass;
// const statusClass = methodData.statusClass;
// const levelClass = methodData.levelClass;
let usedN = {};
if (dataCol.data) {
usedN = that.used[dataCol.data].data
} else {
usedN = that.used.data;
}
usedN.forEach(element => {
});
}
}
文档更新时间: 2022-12-16 19:00 作者:admin