Browse Source

yshop1.4.2 商品新增多图评价,订单新增快递查询,导出最新sql

master
hupeng 5 years ago
parent
commit
df35c59b9b
  1. 4
      src/views/shop/goods/index.vue
  2. 18
      src/views/shop/order/form.vue
  3. 24
      src/views/shop/reply/index.vue

4
src/views/shop/goods/index.vue

@ -44,9 +44,9 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column v-if="checkPermission(['ADMIN','YXSTOREPRODUCT_ALL','YXSTOREPRODUCT_EDIT','YXSTOREPRODUCT_DELETE'])" label="操作" width="185px" align="center"> <el-table-column v-if="checkPermission(['ADMIN','YXSTOREPRODUCT_ALL','YXSTOREPRODUCT_EDIT','YXSTOREPRODUCT_DELETE'])" label="操作" width="205px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button slot="reference" type="danger" size="mini" @click="attr(scope.row)">属性</el-button> <el-button slot="reference" type="danger" size="mini" @click="attr(scope.row)">规格属性</el-button>
<el-dropdown size="mini" split-button type="primary" trigger="click"> <el-dropdown size="mini" split-button type="primary" trigger="click">
操作 操作
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">

18
src/views/shop/order/form.vue

@ -2,7 +2,14 @@
<el-dialog :append-to-body="true" :close-on-click-modal="false" :before-close="cancel" :visible.sync="dialog" :title="isAdd ? '新增' : '去发货'" width="500px"> <el-dialog :append-to-body="true" :close-on-click-modal="false" :before-close="cancel" :visible.sync="dialog" :title="isAdd ? '新增' : '去发货'" width="500px">
<el-form ref="form" :model="form" :rules="rules" size="small" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" size="small" label-width="80px">
<el-form-item label="快递公司" > <el-form-item label="快递公司" >
<el-input v-model="form.deliveryName" style="width: 370px;"/> <!--<el-input v-model="form.deliveryName" style="width: 370px;"/>-->
<el-select v-model="form.deliveryName" filterable placeholder="请选择" style="width: 370px;">
<el-option
v-for="item in dicts"
:key="item.id"
:label="item.label"
:value="item.id" />
</el-select>
</el-form-item> </el-form-item>
<el-form-item label="快递单号" > <el-form-item label="快递单号" >
<el-input v-model="form.deliveryId" style="width: 370px;"/> <el-input v-model="form.deliveryId" style="width: 370px;"/>
@ -16,8 +23,17 @@
</template> </template>
<script> <script>
import initDict from '@/mixins/initDict'
import { add, edit } from '@/api/yxStoreOrder' import { add, edit } from '@/api/yxStoreOrder'
export default { export default {
mixins: [initDict],
created() {
this.$nextTick(() => {
//
this.getDict('express_companys')
})
},
props: { props: {
isAdd: { isAdd: {
type: Boolean, type: Boolean,

24
src/views/shop/reply/index.vue

@ -3,15 +3,7 @@
<!--工具栏--> <!--工具栏-->
<div class="head-container"> <div class="head-container">
<!-- 新增 --> <!-- 新增 -->
<div style="display: inline-block;margin: 0px 2px;">
<el-button
v-permission="['ADMIN','YXSTOREPRODUCTREPLY_ALL','YXSTOREPRODUCTREPLY_CREATE']"
class="filter-item"
size="mini"
type="primary"
icon="el-icon-plus"
@click="add">新增</el-button>
</div>
</div> </div>
<!--表单组件--> <!--表单组件-->
<eForm ref="form" :is-add="isAdd"/> <eForm ref="form" :is-add="isAdd"/>
@ -23,7 +15,16 @@
<el-table-column prop="productScore" label="商品分数"/> <el-table-column prop="productScore" label="商品分数"/>
<el-table-column prop="serviceScore" label="服务分数"/> <el-table-column prop="serviceScore" label="服务分数"/>
<el-table-column prop="comment" label="评论内容"/> <el-table-column prop="comment" label="评论内容"/>
<el-table-column prop="pics" label="评论图片"/> <el-table-column prop="" label="评论图片">
<template slot-scope="scope">
<div v-if="scope.row.pics">
<a :href="pic" v-for="pic in handlePic(scope.row.pics)" style="color: #42b983" target="_blank">
<img :src="pic" alt="点击打开" class="el-avatar">
</a>
</div>
<div v-else>无图</div>
</template>
</el-table-column>
<el-table-column prop="addTime" label="评论时间"> <el-table-column prop="addTime" label="评论时间">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ formatTime(scope.row.addTime) }}</span> <span>{{ formatTime(scope.row.addTime) }}</span>
@ -78,6 +79,9 @@ export default {
}) })
}, },
methods: { methods: {
handlePic(pics) {
return pics.split(',')
},
formatTime, formatTime,
checkPermission, checkPermission,
beforeInit() { beforeInit() {

Loading…
Cancel
Save