提交 d23ced65 authored 作者: huaxinzhu's avatar huaxinzhu

添加,编辑商品增加默认图片

上级 d4270343
...@@ -18,6 +18,7 @@ export default { ...@@ -18,6 +18,7 @@ export default {
return { return {
allImg: [], allImg: [],
editor: null, editor: null,
defalutImg: require("@/assets/image/spring-festival-stbz.png")
}; };
}, },
mounted() { mounted() {
...@@ -73,6 +74,11 @@ export default { ...@@ -73,6 +74,11 @@ export default {
if (this.description) { if (this.description) {
this.editor.txt.html(this.description); this.editor.txt.html(this.description);
} }
// 增加默认图片
if (this.description.indexOf("default-Spring-Festival-stbz") == -1 ) {
this.editor.txt.html('<p><img id="default-Spring-Festival-stbz" style="width:100%" src="/images/spring-festival-stbz.png" /></p>' +this.description);
}
}, },
methods: { methods: {
initInfo() { initInfo() {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论