刘翔宇-旅管家 3 years ago
parent b1c1d68f7a
commit d45f98403b

@ -352,8 +352,8 @@
poster: res?.poster, poster: res?.poster,
poster_url: res?.poster_url, poster_url: res?.poster_url,
merchantId: { merchantId: {
label: res.merchant.name, label: res.merchant?.name,
value: res.merchant.id value: res.merchant?.id
}, },
shopIds: res?.shop_ids, shopIds: res?.shop_ids,
productTypePid: res?.product_type_pid, productTypePid: res?.product_type_pid,
@ -423,7 +423,7 @@
submit() { submit() {
if (this.type === 'add') { if (this.type === 'add'||this.type === 'copy') {
store({ store({
name: this.form.name, name: this.form.name,
poster: this.form.poster, poster: this.form.poster,
@ -486,10 +486,10 @@
watch: { watch: {
isShow(newVal) { isShow(newVal) {
if (newVal) { if (newVal) {
if (this.type === 'editor'||this.type === 'copy') {
if (this.type === 'editor') {
this.getDetail() this.getDetail()
} }
} else { } else {
this.$refs['tinymce'].setContent(' ') this.$refs['tinymce'].setContent(' ')
this.$refs['dialog'].reset() this.$refs['dialog'].reset()

@ -99,9 +99,10 @@
<xy-table :total="total" :list="list" :table-item="table" @pageSizeChange="pageSizeChange" @pageIndexChange="pageChange"> <xy-table :total="total" :list="list" :table-item="table" @pageSizeChange="pageSizeChange" @pageIndexChange="pageChange">
<template v-slot:btns> <template v-slot:btns>
<el-table-column fixed="right" label="操作" width="230" header-align="center"> <el-table-column fixed="right" label="操作" width="300" header-align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<Button type="primary" size="small" @click="editorShow(scope.row.id)"></Button> <Button type="primary" size="small" @click="editorShow(scope.row.id,'editor')"></Button>
<Button type="primary" size="small" style="margin-left: 10px;" @click="editorShow(scope.row.id,'copy')"></Button>
<Poptip <Poptip
transfer transfer
confirm confirm
@ -253,10 +254,10 @@ this.searchProducts();
this.getProducts() this.getProducts()
}) })
}, },
editorShow(id){ editorShow(id,type){
this.$refs['addProduct'].type = 'editor' this.$refs['addProduct'].type = type;
this.$refs['addProduct'].id = id this.$refs['addProduct'].id = id;
this.$refs['addProduct'].isShow = true this.$refs['addProduct'].isShow = true;
}, },
async getProducts(){ async getProducts(){

Loading…
Cancel
Save