This commit is contained in:
cosarty 2024-12-13 21:15:51 +08:00
parent 28b7beece6
commit 59a10c0c9e
2 changed files with 25 additions and 6 deletions

View File

@ -49,6 +49,21 @@
</div>
</template>
</el-table-column>
<el-table-column
prop="viceImage"
header-align="center"
align="center"
label="背景图">
<template slot-scope="scope">
<div class="demo-image__preview">
<el-image
style="width: 36px; height: 36px"
:src="scope.row.viceImage"
:preview-src-list="[scope.row.viceImage]"
/>
</div>
</template>
</el-table-column>
<el-table-column
prop="productPrice"

View File

@ -136,14 +136,14 @@
</el-form-item>
<el-form-item label="热门新品图" prop="hotImage">
<!-- <el-form-item label="热门新品图" prop="hotImage">
<el-switch v-model="dataForm.hotImage" :active-value="1" :inactive-value="0"></el-switch>
</el-form-item>
<el-form-item label="认领状态" prop="status">
</el-form-item> -->
<!-- <el-form-item label="认领状态" prop="status">
<el-switch v-model="dataForm.status" :active-value="1" :inactive-value="0"></el-switch>
</el-form-item>
</el-form-item> -->
</el-form>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false">取消</el-button>
@ -293,12 +293,16 @@ export default {
if (!this.dataForm.id){
plantCreateApi(this.dataForm).then(res => {
this.$message.success('添加成功')
this.$router.go(0);
setTimeout(() => {
this.$router.go(0);
}, 1000);
});
}else {
plantUpdateApi(this.dataForm).then(res => {
this.$message.success('更新成功')
this.$router.go(0);
setTimeout(() => {
this.$router.go(0);
}, 1000);
});
}