|
@@ -263,6 +263,7 @@ export default {
|
|
|
endTime: null,
|
|
endTime: null,
|
|
|
id: "",
|
|
id: "",
|
|
|
informationId: "",
|
|
informationId: "",
|
|
|
|
|
+ informationName: "",
|
|
|
localArea: "",
|
|
localArea: "",
|
|
|
mediaTitle: null,
|
|
mediaTitle: null,
|
|
|
mediaTypeName: "",
|
|
mediaTypeName: "",
|
|
@@ -276,6 +277,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
file: "",
|
|
file: "",
|
|
|
dictList: [],
|
|
dictList: [],
|
|
|
|
|
+ onlineUrl: "http://8.136.230.133:8080",
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
@@ -331,12 +333,12 @@ export default {
|
|
|
})
|
|
})
|
|
|
.then((res) => {
|
|
.then((res) => {
|
|
|
console.log(res);
|
|
console.log(res);
|
|
|
|
|
+ //更新数据
|
|
|
|
|
+ this.choosePlatform();
|
|
|
})
|
|
})
|
|
|
.catch((err) => {
|
|
.catch((err) => {
|
|
|
console.log(err);
|
|
console.log(err);
|
|
|
});
|
|
});
|
|
|
- //更新数据
|
|
|
|
|
- this.choosePlatform();
|
|
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
toDel: function (n) {
|
|
toDel: function (n) {
|
|
@@ -353,6 +355,7 @@ export default {
|
|
|
});
|
|
});
|
|
|
} */
|
|
} */
|
|
|
this.showModal2 = !this.showModal2;
|
|
this.showModal2 = !this.showModal2;
|
|
|
|
|
+ //更新数据
|
|
|
this.choosePlatform();
|
|
this.choosePlatform();
|
|
|
},
|
|
},
|
|
|
/* 表格翻页 */
|
|
/* 表格翻页 */
|
|
@@ -404,7 +407,8 @@ export default {
|
|
|
i < this.tableData.length && j < data.length;
|
|
i < this.tableData.length && j < data.length;
|
|
|
i++, j++
|
|
i++, j++
|
|
|
) {
|
|
) {
|
|
|
- this.tableData.splice(i, 1, data[j]);
|
|
|
|
|
|
|
+ //this.tableData.splice(i, 1, data[j]);
|
|
|
|
|
+ this.$set(this.tableData, i, data[j]);
|
|
|
}
|
|
}
|
|
|
console.log(data.length, this.tableData.length);
|
|
console.log(data.length, this.tableData.length);
|
|
|
console.log(this.tableData);
|
|
console.log(this.tableData);
|
|
@@ -438,7 +442,10 @@ export default {
|
|
|
}, */
|
|
}, */
|
|
|
//导出excel
|
|
//导出excel
|
|
|
onOutputExcel: function () {
|
|
onOutputExcel: function () {
|
|
|
- this.$http({
|
|
|
|
|
|
|
+ let url = this.onlineUrl + "/exportNoFactory";
|
|
|
|
|
+ console.log("导出excel:", url);
|
|
|
|
|
+ window.open(url);
|
|
|
|
|
+ /* this.$http({
|
|
|
url: "/exportNoFactory",
|
|
url: "/exportNoFactory",
|
|
|
method: "get",
|
|
method: "get",
|
|
|
params: {
|
|
params: {
|
|
@@ -453,7 +460,7 @@ export default {
|
|
|
})
|
|
})
|
|
|
.catch((err) => {
|
|
.catch((err) => {
|
|
|
console.log(err);
|
|
console.log(err);
|
|
|
- });
|
|
|
|
|
|
|
+ }); */
|
|
|
},
|
|
},
|
|
|
//导入excel
|
|
//导入excel
|
|
|
/* onImportExcel: function () {
|
|
/* onImportExcel: function () {
|
|
@@ -530,12 +537,13 @@ export default {
|
|
|
obj = this.platform.find(function (item) {
|
|
obj = this.platform.find(function (item) {
|
|
|
return item.platformName === val;
|
|
return item.platformName === val;
|
|
|
});
|
|
});
|
|
|
- this.selectedPlatform = val;
|
|
|
|
|
|
|
+ this.selectedPlatform = obj.platformName;
|
|
|
this.selectedPlatformId = obj.id;
|
|
this.selectedPlatformId = obj.id;
|
|
|
|
|
+
|
|
|
//获取可发布数量
|
|
//获取可发布数量
|
|
|
this.getReleaseQuantity(obj.id);
|
|
this.getReleaseQuantity(obj.id);
|
|
|
|
|
|
|
|
- //发布平台ID
|
|
|
|
|
|
|
+ //更新列表数据
|
|
|
this.getDataList(obj.id);
|
|
this.getDataList(obj.id);
|
|
|
|
|
|
|
|
//获取发布版块
|
|
//获取发布版块
|
|
@@ -555,7 +563,7 @@ export default {
|
|
|
publishPlatformId: val,
|
|
publishPlatformId: val,
|
|
|
publishMonth: d,
|
|
publishMonth: d,
|
|
|
//id: val,
|
|
//id: val,
|
|
|
- // month: d,
|
|
|
|
|
|
|
+ //month: d,
|
|
|
},
|
|
},
|
|
|
})
|
|
})
|
|
|
.then((res) => {
|
|
.then((res) => {
|
|
@@ -600,8 +608,11 @@ export default {
|
|
|
},
|
|
},
|
|
|
//导入模板
|
|
//导入模板
|
|
|
importTemplate: function () {
|
|
importTemplate: function () {
|
|
|
- this.$http({
|
|
|
|
|
- //url: "/exportNoFactory",
|
|
|
|
|
|
|
+ let str = "反馈链接上传导入表模板(经销商).xlsx";
|
|
|
|
|
+ let url = this.onlineUrl + "/downloadTemplate?templateName=" + str;
|
|
|
|
|
+ console.log("下载导入模板:", url);
|
|
|
|
|
+ window.open(url);
|
|
|
|
|
+ /* this.$http({
|
|
|
url: "/downloadTemplate",
|
|
url: "/downloadTemplate",
|
|
|
method: "get",
|
|
method: "get",
|
|
|
params: {
|
|
params: {
|
|
@@ -616,29 +627,7 @@ export default {
|
|
|
})
|
|
})
|
|
|
.catch((err) => {
|
|
.catch((err) => {
|
|
|
console.log(err);
|
|
console.log(err);
|
|
|
- });
|
|
|
|
|
- /* return new Promise((resolve, reject) => {
|
|
|
|
|
- this.$http({
|
|
|
|
|
- url: "/exportNoFactory",
|
|
|
|
|
- method: "get",
|
|
|
|
|
- params: "反馈链接上传导入表模板(经销商).xlsx"
|
|
|
|
|
- })
|
|
|
|
|
- .then((res) => {
|
|
|
|
|
- console.log(res);
|
|
|
|
|
- resolve(res);
|
|
|
|
|
- let link = document.createElement("a");
|
|
|
|
|
- link.href = window.URL.createObjectURL(new Blob([res.data]));
|
|
|
|
|
- link.target = "_blank";
|
|
|
|
|
- //文件名和格式
|
|
|
|
|
- link.download = "文件模板.xlsx";
|
|
|
|
|
- document.body.appendChild(link);
|
|
|
|
|
- link.click();
|
|
|
|
|
- document.body.removeChild(link);
|
|
|
|
|
- })
|
|
|
|
|
- .catch((err) => {
|
|
|
|
|
- reject(err);
|
|
|
|
|
- });
|
|
|
|
|
- }); */
|
|
|
|
|
|
|
+ }); */
|
|
|
},
|
|
},
|
|
|
//导入
|
|
//导入
|
|
|
/* importFile: function () {
|
|
/* importFile: function () {
|