Commit 350eaf52 authored by rencs's avatar rencs

Update index.vue

parent 7f81c760
...@@ -807,91 +807,111 @@ export default { ...@@ -807,91 +807,111 @@ export default {
); );
} }
}); });
});
}, },
/** /**
* 选择数据-关闭弹窗 * 选择数据-关闭弹窗
*/ */
selectDataEvent(e){ selectDataEvent(e) {
if(e){ if (e) {
this.getList() this.getList();
} }
this.selectDataVisible = false this.selectDataVisible = false;
}, },
/** /**
* 查看 * 查看
*/ */
handleSee(row){ handleSee(row) {
this.oneRow = row this.oneRow = row;
this.orderSendDetailVisible = true; this.orderSendDetailVisible = true;
}, },
/** /**
* 发货弹窗关闭 * 发货弹窗关闭
*/ */
sendEvent(e){ sendEvent(e) {
if(e){ if (e) {
this.getList() this.getList();
} }
this.sendVisible = false this.sendVisible = false;
}, },
/** /**
* 开票发货 * 开票发货
*/ */
handleInvoice(row){ handleInvoice(row) {
this.oneRow = row this.oneRow = row;
this.title = '发票发货' this.title = "发票发货";
this.sendVisible = true this.sendVisible = true;
}, },
/** /**
* 发货 * 发货
*/ */
handleSend(row){ handleSend(row) {
this.oneRow = row this.oneRow = row;
this.title = '订单发货' this.title = "订单发货";
this.sendVisible = true this.sendVisible = true;
}, },
/** /**
* 选择数据 * 选择数据
*/ */
handleData(row){ handleData(row) {
this.oneRow = row this.oneRow = row;
this.selectDataVisible = true this.selectDataVisible = true;
}, },
/** /**
* 商品品牌列表 * 商品品牌列表
*/ */
getList() { getList() {
let _this = this let _this = this;
this.listLoading = true; this.listLoading = true;
if(this.times && this.times.length>0){ if (this.times && this.times.length > 0) {
this.listQuery.startTime = this.times[0] this.listQuery.startTime = this.times[0];
this.listQuery.endTime = this.times[1] this.listQuery.endTime = this.times[1];
} }
getOrderList(this.listQuery).then((response) => { getOrderList(this.listQuery).then((response) => {
let a = response.data.data let a = response.data.data;
a.map(function(item) { a.map(function (item) {
if(item.orderItemList){ if (item.orderItemList) {
item.orderItemList.map(function(iitem){ item.orderItemList.map(function (iitem) {
iitem.detailJson = iitem.detailJson ? JSON.parse(iitem.detailJson) : {} iitem.detailJson = iitem.detailJson
if(iitem.type == 2){ // 影像图库-尺寸 ? JSON.parse(iitem.detailJson)
iitem.fileWidth = iitem.detailJson.imageInfoRelationList && iitem.detailJson.imageInfoRelationList.length>0 ? iitem.detailJson.imageInfoRelationList[0].fileWidth:'' : {};
if (iitem.type == 2) {
// 影像图库-尺寸
iitem.fileWidth =
iitem.detailJson.imageInfoRelationList &&
iitem.detailJson.imageInfoRelationList.length > 0
? iitem.detailJson.imageInfoRelationList[0].fileWidth
: "";
} }
if(iitem.type == 3){ if (iitem.type == 3) {
// 行业应用-类别 // 行业应用-类别
iitem.firstTitle = iitem.detailJson.firstTitle ? iitem.detailJson.firstTitle : '' iitem.firstTitle = iitem.detailJson.firstTitle
? iitem.detailJson.firstTitle
: "";
} }
if (iitem.type == 1) { if (iitem.type == 1) {
// 标准数据 // 标准数据
iitem.imageResolutionStr = iitem.detailJson.imageResolution?iitem.detailJson.imageResolution.replace(/{/g, ""):'' iitem.imageResolutionStr = iitem.detailJson.imageResolution
iitem.imageResolutionStr = iitem.imageResolutionStr?iitem.imageResolutionStr.replace(/}/g, ""):'' ? iitem.detailJson.imageResolution.replace(/{/g, "")
: "";
iitem.imageResolutionStr = iitem.imageResolutionStr
? iitem.imageResolutionStr.replace(/}/g, "")
: "";
} }
}) });
} }
if(item.customerJson){ if (item.customerJson) {
item.customerJson = JSON.parse(item.customerJson) item.customerJson = JSON.parse(item.customerJson);
item.customerJson.startTimeStr = timestamp2DateAuto(item.customerJson.startTime, "yyyy-MM-dd"); item.customerJson.startTimeStr = timestamp2DateAuto(
item.customerJson.endTimeStr = timestamp2DateAuto(item.customerJson.endTime, "yyyy-MM-dd"); item.customerJson.startTime,
"yyyy-MM-dd"
);
item.customerJson.endTimeStr = timestamp2DateAuto(
item.customerJson.endTime,
"yyyy-MM-dd"
);
} }
}) });
_this.list = a; _this.list = a;
_this.total = response.data.totalCount; _this.total = response.data.totalCount;
_this.listLoading = false; _this.listLoading = false;
...@@ -901,7 +921,7 @@ export default { ...@@ -901,7 +921,7 @@ export default {
* 清空筛选条件 * 清空筛选条件
*/ */
clear_search() { clear_search() {
this.times = [] this.times = [];
this.listQuery = { this.listQuery = {
name: undefined, // 商品名称 name: undefined, // 商品名称
page: 1, page: 1,
...@@ -918,7 +938,6 @@ export default { ...@@ -918,7 +938,6 @@ export default {
this.getList(); this.getList();
}, },
}, },
},
}; };
</script> </script>
<style lang="scss"> <style lang="scss">
......
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