紧急修复了一些bug
This commit is contained in:
@@ -946,6 +946,7 @@
|
||||
// 提交
|
||||
handleSubmit (name) {
|
||||
this.onChangeGroup()
|
||||
if( this.formValidate.specType && this.formValidate.attr.length < 1 ) return this.$message.warning("请填写多规格属性!");
|
||||
this.formValidate.cateId = this.formValidate.cateIds.join(',')
|
||||
this.formValidate.sliderImage = JSON.stringify(this.formValidate.sliderImages)
|
||||
if(this.formValidate.specType){
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -98,6 +98,7 @@
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-switch
|
||||
:disabled="tableFrom.type === '5'"
|
||||
v-model="scope.row.isShow"
|
||||
:active-value="true"
|
||||
:inactive-value="false"
|
||||
@@ -120,7 +121,8 @@
|
||||
<router-link :to="{path: '/store/list/creatProduct/' + scope.row.id}">
|
||||
<el-button type="text" size="small" class="mr10">编辑</el-button>
|
||||
</router-link>
|
||||
<el-button type="text" size="small" @click="handleDelete(scope.row.id, scope.$index)">删除</el-button>
|
||||
<el-button v-if="tableFrom.type === '5'" type="text" size="small" @click="handleRestore(scope.row.id, scope.$index)">恢复商品</el-button>
|
||||
<el-button type="text" size="small" @click="handleDelete(scope.row.id, scope.$index)">{{ tableFrom.type === '5' ? '删除' : '加入回收站' }}</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -148,7 +150,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { productLstApi, productDeleteApi, categoryApi, putOnShellApi, offShellApi, productHeadersApi, productExportApi } from '@/api/store'
|
||||
import { productLstApi, productDeleteApi, categoryApi, putOnShellApi, offShellApi, productHeadersApi, productExportApi, restoreApi } from '@/api/store'
|
||||
import { getToken } from '@/utils/auth'
|
||||
import taoBao from './taoBao'
|
||||
export default {
|
||||
@@ -188,6 +190,16 @@ export default {
|
||||
this.getCategorySelect()
|
||||
},
|
||||
methods: {
|
||||
handleRestore(id) {
|
||||
this.$modalSure("恢复商品").then(() => {
|
||||
restoreApi(id)
|
||||
.then((res) => {
|
||||
this.$message.success('操作成功');
|
||||
this.goodHeade();
|
||||
this.getList();
|
||||
})
|
||||
});
|
||||
},
|
||||
seachList() {
|
||||
this.tableFrom.page = 1
|
||||
this.getList()
|
||||
|
||||
@@ -17,15 +17,27 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="商品搜索:" class="mr10">
|
||||
<el-input v-model="tableFrom.productId" placeholder="请输入商品名称,关键字,产品编号" class="selWidth" size="small">
|
||||
<el-input v-model="tableFrom.productSearch" placeholder="请输入商品名称,商品id" class="selWidth" size="small">
|
||||
<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="用户名称:">
|
||||
<el-input v-model="tableFrom.nickname" placeholder="请输入用户名称" class="selWidth" size="small">
|
||||
<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>
|
||||
</el-input>
|
||||
{{uids}}
|
||||
<el-select v-model="uids" style="width: 500px" reserve-keyword multiple remote filterable
|
||||
:remote-method="remoteMethod" :loading="loading" placeholder="请输入用户名称" clearable @change="seachList">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.uid"
|
||||
:label="item.nickname"
|
||||
:value="item.uid">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!--<el-form-item label="用户名称:">-->
|
||||
<!--<el-input v-model="tableFrom.nickname" placeholder="请输入用户名称" class="selWidth" size="small">-->
|
||||
<!--<el-button slot="append" icon="el-icon-search" @click="seachList" size="small"/>-->
|
||||
<!--</el-input>-->
|
||||
<!--</el-form-item>-->
|
||||
</el-form>
|
||||
</div>
|
||||
<el-button size="small" type="primary" @click="add">添加虚拟评论</el-button>
|
||||
@@ -120,6 +132,7 @@
|
||||
import creatComment from './creatComment.vue'
|
||||
import { categoryApi, replyListApi, replyDeleteApi, replyCommentApi } from '@/api/store'
|
||||
import { formatDates } from '@/utils/index';
|
||||
import { userListApi } from '@/api/user'
|
||||
export default {
|
||||
name: 'StoreComment',
|
||||
filters: {
|
||||
@@ -163,11 +176,14 @@ export default {
|
||||
limit: 20,
|
||||
isReply: '',
|
||||
dateLimit: '',
|
||||
nickname: '',
|
||||
productId:'',
|
||||
uid: '',
|
||||
productSearch:'',
|
||||
isDel: false
|
||||
},
|
||||
timeVal: []
|
||||
timeVal: [],
|
||||
loading: false,
|
||||
uids: [],
|
||||
options: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
@@ -176,6 +192,19 @@ export default {
|
||||
this.getCategorySelect()
|
||||
},
|
||||
methods:{
|
||||
remoteMethod(query) {
|
||||
if (query !== '') {
|
||||
this.loading = true;
|
||||
setTimeout(() => {
|
||||
this.loading = false;
|
||||
userListApi({keywords: query, page: 1, limit: 10}).then(res => {
|
||||
this.options = res.list
|
||||
})
|
||||
}, 200);
|
||||
} else {
|
||||
this.options = [];
|
||||
}
|
||||
},
|
||||
seachList() {
|
||||
this.tableFrom.page = 1
|
||||
this.getList()
|
||||
@@ -278,6 +307,7 @@ export default {
|
||||
// 列表
|
||||
getList() {
|
||||
this.listLoading = true
|
||||
this.tableFrom.uid = this.uids.join(',')
|
||||
replyListApi(this.tableFrom).then(res => {
|
||||
this.tableData.data = res.list
|
||||
this.tableData.total = res.total
|
||||
|
||||
Reference in New Issue
Block a user