|
|
@@ -148,7 +148,7 @@ export default {
|
|
|
},
|
|
|
fileName: {
|
|
|
type: String,
|
|
|
- default: '',
|
|
|
+ default: "",
|
|
|
},
|
|
|
},
|
|
|
data() {
|
|
|
@@ -188,6 +188,7 @@ export default {
|
|
|
|
|
|
releaseChannel: [],
|
|
|
releasePlate: [],
|
|
|
+ userId: '',
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -210,21 +211,22 @@ export default {
|
|
|
});
|
|
|
console.log("chexi ", obj);
|
|
|
//carTypeId 表示车系 id
|
|
|
- // this.carTypeId = obj.id;
|
|
|
+ // this.carTypeId = obj.id;
|
|
|
|
|
|
//当前月份
|
|
|
let date = new Date();
|
|
|
let m = date.getMonth() + 1;
|
|
|
let y = date.getFullYear();
|
|
|
let d = y + "/" + m;
|
|
|
-
|
|
|
+console.log(this.ziliaoId)
|
|
|
let config = {
|
|
|
url: "",
|
|
|
data: {
|
|
|
id: "", //主键值
|
|
|
month: d,
|
|
|
- dealerId: "254",
|
|
|
- dataId: "1386025423408103425",
|
|
|
+ dealerId: this.userId,
|
|
|
+ dataId: this.ziliaoId,
|
|
|
+ //dataId: "1386025423408103425",
|
|
|
informationName: this.ziliaoName,
|
|
|
releaseTime: this.ziliaoTime,
|
|
|
carService: this.carS,
|
|
|
@@ -257,7 +259,7 @@ export default {
|
|
|
} else {
|
|
|
//新增
|
|
|
config.url = "/dealerFeedback";
|
|
|
- console.log('新增',222)
|
|
|
+ console.log("新增", 222);
|
|
|
}
|
|
|
|
|
|
this.$emit("update", config);
|
|
|
@@ -299,7 +301,7 @@ export default {
|
|
|
data: {},
|
|
|
})
|
|
|
.then((res) => {
|
|
|
- console.log(res, 2222222222222222)
|
|
|
+ console.log(res, 2222222222222222);
|
|
|
if (res.data.code === 200) {
|
|
|
this.carType = res.data.data;
|
|
|
this.chooseCarType();
|
|
|
@@ -417,9 +419,12 @@ export default {
|
|
|
},
|
|
|
|
|
|
initialData: function () {
|
|
|
- console.log(this.fileName,this.$route.query.informationName)
|
|
|
+ console.log(this.fileName, this.$route.query.informationName);
|
|
|
this.ziliaoName = this.fileName;
|
|
|
- this.ziliaoId = this.LinkData.informationId;
|
|
|
+ if(this.LinkData.informationId) this.ziliaoId = this.LinkData.informationId;
|
|
|
+ else{
|
|
|
+ this.ziliaoId = this.$route.query.informationId;
|
|
|
+ }
|
|
|
|
|
|
this.mediaTitle = this.LinkData.mediaTitle;
|
|
|
this.mediaUrl = this.LinkData.mediaUrl;
|
|
|
@@ -427,14 +432,14 @@ export default {
|
|
|
|
|
|
this.carT = this.LinkData.carPlatformName;
|
|
|
let time = this.LinkData.publishDate; //发布时间
|
|
|
- if(time != null){
|
|
|
+ if (time != null) {
|
|
|
if (time.length > 4) {
|
|
|
- let y = time.slice(0, 4);
|
|
|
- let m = time.slice(5, 7);
|
|
|
- let d = time.slice(8, 10);
|
|
|
- let temp = y + "-" + m + "-" + d;
|
|
|
- this.ziliaoTime = temp;
|
|
|
- }
|
|
|
+ let y = time.slice(0, 4);
|
|
|
+ let m = time.slice(5, 7);
|
|
|
+ let d = time.slice(8, 10);
|
|
|
+ let temp = y + "-" + m + "-" + d;
|
|
|
+ this.ziliaoTime = temp;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
//publishPlatformName 发布渠道
|
|
|
@@ -485,7 +490,7 @@ this.readCount&&this.goodCount&& this.bbsCount&& this.lookingCount */
|
|
|
obj = this.releaseChannel.find(function (item) {
|
|
|
return item.platformName === val;
|
|
|
});
|
|
|
- console.log(this.releaseC, obj)
|
|
|
+ console.log(this.releaseC, obj);
|
|
|
//传当前渠道 id, 获取发布版块列表
|
|
|
this.chooseReleasePlate(obj.id);
|
|
|
}
|
|
|
@@ -516,12 +521,21 @@ this.readCount&&this.goodCount&& this.bbsCount&& this.lookingCount */
|
|
|
},
|
|
|
},
|
|
|
mounted() {
|
|
|
+ let localUserId = localStorage.getItem("userId");
|
|
|
+ if (localUserId) {
|
|
|
+ console.log("经销商ID", localUserId);
|
|
|
+ this.userId = localUserId;
|
|
|
+ } else {
|
|
|
+ console.log("经销商ID '-");
|
|
|
+ this.userId = "";
|
|
|
+ }
|
|
|
+
|
|
|
this.chooseDataName();
|
|
|
this.chooseCarSeries();
|
|
|
this.firstContent1Classify();
|
|
|
this.firstContent2Classify();
|
|
|
|
|
|
-this.chooseChannel();
|
|
|
+ this.chooseChannel();
|
|
|
|
|
|
this.initialData();
|
|
|
},
|