后台页面优化

main
home.fengxinyhyl 9 months ago
parent 890eff6b24
commit 8ba4cd88c3
  1. 2
      app/common/repositories/store/product/ProductRepository.php
  2. 2
      app/controller/admin/store/StoreProduct.php
  3. 2
      view/admin/src/views/login/index.vue
  4. 73
      view/admin/src/views/product/productExamine/index.vue
  5. 142
      view/admin/src/views/product/productExamine/proDetails.vue
  6. 2
      view/admin/src/views/user/group/index.vue

@ -77,7 +77,7 @@ class ProductRepository extends BaseRepository
['product_type', 0], ['product_type', 0],
['good_ids', []], ['good_ids', []],
]; ];
protected $admin_filed = 'Product.product_id,Product.mer_id,brand_id,spec_type,unit_name,mer_status,rate,reply_count,store_info,cate_id,Product.image,slider_image,Product.store_name,Product.keyword,Product.sort,U.rank,Product.is_show,Product.sales,Product.price,extension_type,refusal,cost,Product.ot_price,stock,is_gift_bag,Product.care_count,Product.status,is_used,Product.create_time,Product.product_type,old_product_id,star,ficti,integral_total,integral_price_total,sys_labels,Product.param_temp_id,Product.mer_svip_status,Product.svip_price,Product.svip_price_type,Product.mer_form_id,Product.good_ids'; protected $admin_filed = 'Product.product_id,Product.mer_id,brand_id,spec_type,unit_name,mer_status,rate,reply_count,store_info,cate_id,Product.image,slider_image,Product.store_name,Product.keyword,Product.sort,U.rank,Product.is_show,is_hot,Product.sales,Product.price,extension_type,refusal,cost,Product.ot_price,stock,is_gift_bag,Product.care_count,Product.status,is_used,Product.create_time,Product.product_type,old_product_id,star,ficti,integral_total,integral_price_total,sys_labels,Product.param_temp_id,Product.mer_svip_status,Product.svip_price,Product.svip_price_type,Product.mer_form_id,Product.good_ids';
protected $filed = 'Product.product_id,Product.mer_id,brand_id,unit_name,spec_type,mer_status,rate,reply_count,store_info,cate_id,Product.image,slider_image,Product.store_name,Product.keyword,Product.sort,Product.is_show,Product.sales,Product.price,extension_type,refusal,cost,Product.ot_price,stock,is_gift_bag,Product.care_count,Product.status,is_used,Product.create_time,Product.product_type,old_product_id,integral_total,integral_price_total,mer_labels,Product.is_good,Product.is_del,Product.type,Product.param_temp_id,Product.mer_svip_status,Product.svip_price,Product.svip_price_type,Product.mer_form_id,Product.good_ids'; protected $filed = 'Product.product_id,Product.mer_id,brand_id,unit_name,spec_type,mer_status,rate,reply_count,store_info,cate_id,Product.image,slider_image,Product.store_name,Product.keyword,Product.sort,Product.is_show,Product.sales,Product.price,extension_type,refusal,cost,Product.ot_price,stock,is_gift_bag,Product.care_count,Product.status,is_used,Product.create_time,Product.product_type,old_product_id,integral_total,integral_price_total,mer_labels,Product.is_good,Product.is_del,Product.type,Product.param_temp_id,Product.mer_svip_status,Product.svip_price,Product.svip_price_type,Product.mer_form_id,Product.good_ids';
const NOTIC_MSG = [ const NOTIC_MSG = [

@ -51,7 +51,7 @@ class StoreProduct extends BaseController
{ {
[$page, $limit] = $this->getPage(); [$page, $limit] = $this->getPage();
$type = $this->request->param('type', 1); $type = $this->request->param('type', 1);
$where = $this->request->params(['cate_id', 'keyword', 'mer_cate_id', 'pid', 'store_name', 'is_trader', 'us_status', 'product_id', 'star', 'sys_labels', 'hot_type', 'svip_price_type', 'is_ficti', 'product_ids', 'form_id']); $where = $this->request->params(['cate_id', 'keyword', 'mer_cate_id', 'pid', 'store_name', 'is_trader', 'us_status', 'product_id', 'star', 'sys_labels', 'hot_type', 'is_hot', 'is_ficti', 'product_ids', 'form_id']);
$mer_id = $this->request->param('mer_id', ''); $mer_id = $this->request->param('mer_id', '');
$merId = $mer_id ? $mer_id : null; $merId = $mer_id ? $mer_id : null;
$where['is_gift_bag'] = 0; $where['is_gift_bag'] = 0;

@ -346,7 +346,7 @@ export default {
.then(res => { .then(res => {
this.loading = false; this.loading = false;
this.$router.push({ this.$router.push({
path: "/" path: "/admin/product/examine"
}); });
this.$root.closeNotice(); this.$root.closeNotice();
}); });

@ -21,33 +21,32 @@
<el-option v-for="item in productStatusList" :key="item.value" :label="item.label" :value="item.value" /> <el-option v-for="item in productStatusList" :key="item.value" :label="item.label" :value="item.value" />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="推荐级别:" prop="star"> <!-- <el-form-item label="推荐级别:" prop="star">-->
<el-select v-model="tableFrom.star" placeholder="请选择" class="filter-item selWidth" clearable @change="getList(1)"> <!-- <el-select v-model="tableFrom.star" placeholder="请选择" class="filter-item selWidth" clearable @change="getList(1)">-->
<el-option v-for="item in recommendedLevelStatus" :key="item.value" :label="item.label" :value="item.value" /> <!-- <el-option v-for="item in recommendedLevelStatus" :key="item.value" :label="item.label" :value="item.value" />-->
</el-select> <!-- </el-select> -->
</el-form-item> <!-- </el-form-item>-->
<el-form-item label="标签:" prop="sys_labels"> <!-- <el-form-item label="标签:" prop="sys_labels">-->
<el-select v-model="tableFrom.sys_labels" placeholder="请选择" class="filter-item selWidth" clearable filterable @change="getList(1)"> <!-- <el-select v-model="tableFrom.sys_labels" placeholder="请选择" class="filter-item selWidth" clearable filterable @change="getList(1)">-->
<el-option v-for="item in labelList" :key="item.id" :label="item.name" :value="item.id" /> <!-- <el-option v-for="item in labelList" :key="item.id" :label="item.name" :value="item.id" />-->
</el-select> <!-- </el-select> -->
</el-form-item> <!-- </el-form-item>-->
<el-form-item label="会员价:" prop="svip_price_type"> <el-form-item label="商品类型:" prop="is_hot">
<el-select v-model="tableFrom.svip_price_type" placeholder="请选择" class="selWidth" clearable @change="getList(1)"> <el-select v-model="tableFrom.is_hot" placeholder="请选择" class="selWidth" clearable @change="getList(1)">
<el-option label="未设置" value="0" /> <el-option label="普通商品" value="0" />
<el-option label="默认设置" value="1" /> <el-option label="爆单商品" value="1" />
<el-option label="自定义设置" value="2" />
</el-select>
</el-form-item>
<el-form-item label="商品推荐:" prop="hot_type">
<el-select v-model="tableFrom.hot_type" placeholder="请选择" class="filter-item selWidth" clearable filterable @change="getList(1)">
<el-option v-for="item in recommendList" :key="item.value" :label="item.name" :value="item.value" />
</el-select>
</el-form-item>
<el-form-item label="商品类型:" prop="is_ficti">
<el-select v-model="tableFrom.is_ficti" placeholder="请选择" class="filter-item selWidth" clearable @change="getList(1)">
<el-option v-for="item in productTypeList" :key="item.value" :label="item.label" :value="item.value" />
</el-select> </el-select>
</el-form-item> </el-form-item>
<!-- <el-form-item label="商品推荐:" prop="hot_type">-->
<!-- <el-select v-model="tableFrom.hot_type" placeholder="请选择" class="filter-item selWidth" clearable filterable @change="getList(1)">-->
<!-- <el-option v-for="item in recommendList" :key="item.value" :label="item.name" :value="item.value" />-->
<!-- </el-select> -->
<!-- </el-form-item>-->
<!-- <el-form-item label="商品类型:" prop="is_ficti">-->
<!-- <el-select v-model="tableFrom.is_ficti" placeholder="请选择" class="filter-item selWidth" clearable @change="getList(1)">-->
<!-- <el-option v-for="item in productTypeList" :key="item.value" :label="item.label" :value="item.value" />-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<el-form-item label="商品搜索:" prop="keyword"> <el-form-item label="商品搜索:" prop="keyword">
<el-input v-model="tableFrom.keyword" @keyup.enter.native="getList(1)" placeholder="请输入商品名称,关键字,产品编号" class="selWidth" /> <el-input v-model="tableFrom.keyword" @keyup.enter.native="getList(1)" placeholder="请输入商品名称,关键字,产品编号" class="selWidth" />
</el-form-item> </el-form-item>
@ -61,14 +60,14 @@
<el-tabs v-model="tableFrom.type" @tab-click="getList(1),getLstFilterApi()"> <el-tabs v-model="tableFrom.type" @tab-click="getList(1),getLstFilterApi()">
<el-tab-pane v-for="(item,index) in headeNum" :key="index" :name="item.type.toString()" :label="item.name +'('+item.count +')' " /> <el-tab-pane v-for="(item,index) in headeNum" :key="index" :name="item.type.toString()" :label="item.name +'('+item.count +')' " />
</el-tabs> </el-tabs>
<div class="mt5 mb20"> <!-- <div class="mt5 mb20">-->
<el-button v-show="tableFrom.type === '6'" size="small" :disabled="multipleSelection.length==0" @click="batch">批量审核</el-button> <!-- <el-button v-show="tableFrom.type === '6'" size="small" :disabled="multipleSelection.length==0" @click="batch">批量审核</el-button>-->
<el-button size="small" :disabled="multipleSelection.length==0 " @click="batchOff">批量强制下架</el-button> <!-- <el-button size="small" :disabled="multipleSelection.length==0 " @click="batchOff">批量强制下架</el-button>-->
<el-button size="small" :disabled="multipleSelection.length==0 " @click="batchShow(0)">批量不显示</el-button> <!-- <el-button size="small" :disabled="multipleSelection.length==0 " @click="batchShow(0)">批量不显示</el-button>-->
<el-button size="small" :disabled="multipleSelection.length==0 " @click="batchShow(1)">批量显示</el-button> <!-- <el-button size="small" :disabled="multipleSelection.length==0 " @click="batchShow(1)">批量显示</el-button>-->
<el-button :disabled="multipleSelection.length==0" size="small" @click="batchLabel">批量设置标签</el-button> <!-- <el-button :disabled="multipleSelection.length==0" size="small" @click="batchLabel">批量设置标签</el-button>-->
<el-button :disabled="multipleSelection.length==0" size="small" @click="batchRecommend">批量设置推荐</el-button> <!-- <el-button :disabled="multipleSelection.length==0" size="small" @click="batchRecommend">批量设置推荐</el-button>-->
</div> <!-- </div>-->
<el-table v-loading="listLoading" :data="tableData.data" size="small" @selection-change="handleSelectionChange"> <el-table v-loading="listLoading" :data="tableData.data" size="small" @selection-change="handleSelectionChange">
<el-table-column v-if="Number(tableFrom.type)<7" key="2" type="selection" width="55" /> <el-table-column v-if="Number(tableFrom.type)<7" key="2" type="selection" width="55" />
<el-table-column type="expand"> <el-table-column type="expand">
@ -119,6 +118,11 @@
<span>{{ scope.row.merchant ? scope.row.merchant.mer_name : '' }}</span> <span>{{ scope.row.merchant ? scope.row.merchant.mer_name : '' }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="商品类型" min-width="80" >
<template slot-scope="scope">
<span>{{ scope.row.is_hot ? '爆单商品' : '普通商品' }}</span>
</template>
</el-table-column>
<el-table-column prop="price" label="商品售价" min-width="80" /> <el-table-column prop="price" label="商品售价" min-width="80" />
<el-table-column prop="sales" label="销量" min-width="70" /> <el-table-column prop="sales" label="销量" min-width="70" />
<el-table-column prop="stock" label="库存" min-width="70" /> <el-table-column prop="stock" label="库存" min-width="70" />
@ -143,7 +147,7 @@
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" size="small" @click="onDetails(scope.row.product_id)">详情</el-button> <el-button type="text" size="small" @click="onDetails(scope.row.product_id)">详情</el-button>
<el-button v-if="tableFrom.type === '6'" type="text" size="small" @click.native="toExamine(scope.row.product_id)">审核</el-button> <el-button v-if="tableFrom.type === '6'" type="text" size="small" @click.native="toExamine(scope.row.product_id)">审核</el-button>
<el-button type="text" size="small" class="mr10" @click="handlePreview(scope.row.product_id)">预览</el-button> <!-- <el-button type="text" size="small" class="mr10" @click="handlePreview(scope.row.product_id)">预览</el-button>-->
<el-dropdown> <el-dropdown>
<span class="el-dropdown-link"> <span class="el-dropdown-link">
更多<i class="el-icon-arrow-down el-icon--right" /> 更多<i class="el-icon-arrow-down el-icon--right" />
@ -392,6 +396,7 @@ export default {
hot_type: '', hot_type: '',
star: '', star: '',
svip_price_type: '', svip_price_type: '',
is_hot: '',
product_id: this.$route.query.id ? this.$route.query.id : "" product_id: this.$route.query.id ? this.$route.query.id : ""
}, },
categoryList: [], categoryList: [],

@ -21,7 +21,7 @@
<ul class="list"> <ul class="list">
<li class="item"> <li class="item">
<div class="title">商品类型</div> <div class="title">商品类型</div>
<div>{{productData.type == 0 ? '普通商品' : productData.type == 1 ? '虚拟商品' : '卡密商品' }}</div> <div>{{productData.is_hot == 0 ? '普通商品' :'爆单商品' }}</div>
</li> </li>
<li class="item"> <li class="item">
<div class="title">商品状态</div> <div class="title">商品状态</div>
@ -210,69 +210,6 @@
<div class="contentPic" v-html="productData.content"/> <div class="contentPic" v-html="productData.content"/>
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="营销信息" name="marketing">
<div class="section">
<ul class="list">
<li class="item">
<div class="item-title">店铺推荐</div>
<div class="value">{{productData.is_good ? '是' : '否'}}</div>
</li>
<li class="item">
<div class="item-title">平台推荐</div>
<div v-if="productData.is_benefit||productData.is_new||productData.is_best||productData.is_hot" class="value">
<span class="value-item" v-if="productData.is_benefit">促销单品</span>
<span class="value-item" v-if="productData.is_new">首发新品</span>
<span class="value-item" v-if="productData.is_best">精品推荐</span>
<span class="value-item" v-if="productData.is_hot">热门榜单</span>
</div>
<div v-else class="value-item"></div>
</li>
<li class="item">
<div class="item-title">分销礼包</div>
<div class="value">{{productData.is_gift_bag ? '是' : '否'}}</div>
</li>
<li v-if="productData.star" class="item">
<div class="item-title">平台推荐星级</div>
<div class="value">
<el-rate disabled v-model="productData.star" :colors="colors"></el-rate>
</div>
</li>
<li v-if="productData.merchant&&productData.integral_rate!=0" class="item">
<div class="item-title">积分抵扣比例</div>
<div v-if="productData.integral_rate == -1&&productData.merchant" class="value">默认设置{{'('+productData.merchant.mer_integral_rate+'%)'}}</div>
<div v-else-if="productData.integral_rate > 0" class="value">单独设置{{'('+productData.integral_rate+'%)'}}</div>
</li>
<li v-if="productData.integral_rate!=0" class="item">
<div class="item-title">积分抵扣金额</div>
<div class="value">{{productData.integral_price_total}}</div>
</li>
<li v-if="productData.coupon&&productData.coupon.length>0" class="item">
<div class="item-title">优惠券(赠送券)</div>
<div class="value">
<span v-for="(itm,idx) in productData.coupon" :key="idx" class="value-item"> {{itm.title}} </span>
</div>
</li>
<li class="item">
<div class="item-title">收藏人数</div>
<div class="value">
<span> {{productData.care_count}}</span>
</div>
</li>
<li class="item">
<div class="item-title">已售数量</div>
<div class="value">
<span> {{productData.ficti}} (指手动添加数量)</span>
</div>
</li>
<li class="item">
<div class="item-title">实际销量 </div>
<div class="value">
<span> {{productData.sales-productData.ficti}} (指实际售出数量)</span>
</div>
</li>
</ul>
</div>
</el-tab-pane>
<el-tab-pane label="其它信息" name="others"> <el-tab-pane label="其它信息" name="others">
<div class="section"> <div class="section">
<ul class="list"> <ul class="list">
@ -408,83 +345,6 @@
</ul> </ul>
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="商品操作记录" name="records">
<div class="section">
<el-form size="small" label-width="90px">
<div class="acea-row">
<el-form-item label="操作端:">
<el-select
v-model="recordForm.type"
placeholder="请选择"
class="selWidth mr10"
clearable
filterable
@change="getRecordData(productId)"
>
<el-option label="平台端" value="1" />
<el-option label="商户端" value="2" />
</el-select>
</el-form-item>
<el-form-item label="操作时间:">
<el-date-picker
class="selWidth"
v-model="timeVal"
type="datetimerange"
placeholder="选择日期"
value-format="yyyy/MM/dd HH:mm:ss"
clearable
@change="onchangeTime"
>
</el-date-picker>
</el-form-item>
</div>
</el-form>
<el-table
border
ref="productRecords"
:data="recordData.data"
row-key="operate_log_id"
size="small"
class="ones"
>
<el-table-column
align="center"
label="序号"
min-width="60"
prop="operate_log_id"
/>
<el-table-column align="center" label="操作记录" min-width="120">
<template slot-scope="scope">
<span>{{scope.row.category_name}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="操作端" min-width="100">
<template slot-scope="scope">
<span>{{scope.row.type}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="操作角色" min-width="100">
<template slot-scope="scope">
<span>{{scope.row.operator_role_nickname}}</span>
</template>
</el-table-column>
<el-table-column align="center" label="操作人" min-width="100">
<template slot-scope="scope">
<span>{{scope.row.operator_nickname}}</span>
</template>
</el-table-column>
<el-table-column
align="center"
label="操作时间"
min-width="100"
prop="create_time"
/>
</el-table>
<div class="block">
<el-pagination :page-size="recordForm.limit" :current-page="recordForm.page" layout="prev, pager, next, jumper" :total="recordData.total" @size-change="handleSizeChange" @current-change="pageChange" />
</div>
</div>
</el-tab-pane>
</el-tabs> </el-tabs>
</div> </div>
</el-drawer> </el-drawer>

@ -19,7 +19,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
:label="$route.path.indexOf('group') !== -1 ? '分组名称' : '标签名称'" :label="$route.path.indexOf('group') !== -1 ? '等级名称' : '标签名称'"
min-width="180" min-width="180"
> >
<template slot-scope="{row}"> <template slot-scope="{row}">

Loading…
Cancel
Save