商品评论
parent
c336b3ba42
commit
ec54625802
|
|
@ -181,5 +181,71 @@ class Goods extends Common
|
|||
$data = GoodsService::GoodsCategory($params);
|
||||
return DataReturn('success', 0, $data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 商品评分
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2019-07-11
|
||||
* @desc description
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function GoodsScore()
|
||||
{
|
||||
if(empty($this->data_post['goods_id']))
|
||||
{
|
||||
return DataReturn('参数有误', -1);
|
||||
}
|
||||
|
||||
// 获取商品评分
|
||||
return GoodsCommentsService::GoodsCommentsScore($this->data_post['goods_id']);
|
||||
}
|
||||
|
||||
/**
|
||||
* 商品评论
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @datetime 2019-05-13T21:47:41+0800
|
||||
*/
|
||||
public function Comment()
|
||||
{
|
||||
// 参数
|
||||
$params = $this->data_post;
|
||||
|
||||
// 分页
|
||||
$number = 10;
|
||||
$page = max(1, isset($params['page']) ? intval($params['page']) : 1);
|
||||
|
||||
// 条件
|
||||
$where = [
|
||||
'goods_id' => $params['goods_id'],
|
||||
'is_show' => 1,
|
||||
];
|
||||
|
||||
// 获取总数
|
||||
$total = GoodsCommentsService::GoodsCommentsTotal($where);
|
||||
$page_total = ceil($total/$number);
|
||||
$start = intval(($page-1)*$number);
|
||||
|
||||
// 获取列表
|
||||
$data_params = array(
|
||||
'm' => $start,
|
||||
'n' => $number,
|
||||
'where' => $where,
|
||||
'is_public' => 1,
|
||||
);
|
||||
$data = GoodsCommentsService::GoodsCommentsList($data_params);
|
||||
|
||||
// 返回数据
|
||||
$result = [
|
||||
'number' => $number,
|
||||
'total' => $total,
|
||||
'page_total' => $page_total,
|
||||
'data' => $data['data'],
|
||||
];
|
||||
return DataReturn('success', 0, $result);
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
@ -322,3 +322,4 @@ class Goods extends Common
|
|||
return DataReturn('请求成功', 0, $result);
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
@ -0,0 +1,249 @@
|
|||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | ShopXO 国内领先企业级B2C免费开源电商系统
|
||||
// +----------------------------------------------------------------------
|
||||
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
|
||||
// +----------------------------------------------------------------------
|
||||
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
|
||||
// +----------------------------------------------------------------------
|
||||
// | Author: Devil
|
||||
// +----------------------------------------------------------------------
|
||||
namespace payment;
|
||||
|
||||
/**
|
||||
* 码付宝-微信
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-19
|
||||
* @desc description
|
||||
*/
|
||||
class MafubaoWeixin
|
||||
{
|
||||
// 插件配置参数
|
||||
private $config;
|
||||
|
||||
/**
|
||||
* 构造方法
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-17
|
||||
* @desc description
|
||||
* @param [array] $params [输入参数(支付配置参数)]
|
||||
*/
|
||||
public function __construct($params = [])
|
||||
{
|
||||
$this->config = $params;
|
||||
}
|
||||
|
||||
/**
|
||||
* 配置信息
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-19
|
||||
* @desc description
|
||||
*/
|
||||
public function Config()
|
||||
{
|
||||
// 基础信息
|
||||
$base = [
|
||||
'name' => '码付宝-微信', // 插件名称
|
||||
'version' => '0.0.1', // 插件版本
|
||||
'apply_version' => '不限', // 适用系统版本描述
|
||||
'apply_terminal'=> ['pc','h5'], // 适用终端 默认全部 ['pc', 'h5', 'ios', 'android', 'alipay', 'weixin', 'baidu']
|
||||
'desc' => '适用PC+H5,即时到帐支付方式,免费帮助个人实现支付后立即通知。 <a href="http://pay.shopxo.net/" target="_blank">立即申请</a>', // 插件描述(支持html)
|
||||
'author' => 'Devil', // 开发者
|
||||
'author_url' => 'http://shopxo.net/', // 开发者主页
|
||||
];
|
||||
|
||||
// 配置信息
|
||||
$element = [
|
||||
[
|
||||
'element' => 'input',
|
||||
'type' => 'text',
|
||||
'default' => '',
|
||||
'name' => 'appid',
|
||||
'placeholder' => 'appid',
|
||||
'title' => 'appid',
|
||||
'is_required' => 0,
|
||||
'message' => '请填写appid',
|
||||
],
|
||||
[
|
||||
'element' => 'input',
|
||||
'type' => 'text',
|
||||
'default' => '',
|
||||
'name' => 'appsecret',
|
||||
'placeholder' => 'appsecret',
|
||||
'title' => 'appsecret',
|
||||
'is_required' => 0,
|
||||
'message' => '请填写通信密钥appsecret',
|
||||
],
|
||||
];
|
||||
|
||||
return [
|
||||
'base' => $base,
|
||||
'element' => $element,
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付入口
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-19
|
||||
* @desc description
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
public function Pay($params = [])
|
||||
{
|
||||
// 参数
|
||||
if(empty($params))
|
||||
{
|
||||
return DataReturn('参数不能为空', -1);
|
||||
}
|
||||
|
||||
// 配置信息
|
||||
if(empty($this->config))
|
||||
{
|
||||
return DataReturn('支付缺少配置', -1);
|
||||
}
|
||||
|
||||
// 处理支付
|
||||
$parameter = array(
|
||||
'appid' => $this->config['appid'],
|
||||
'channel' => 'wechat',
|
||||
'notify_url' => $params['notify_url'],
|
||||
'return_url' => $params['call_back_url'],
|
||||
|
||||
// 业务参数
|
||||
'goodsname' => $params['name'],
|
||||
'out_trade_no' => $params['order_no'],
|
||||
'money' => $params['total_price'],
|
||||
);
|
||||
|
||||
$param = $this->GetParamSign($parameter);
|
||||
$url = 'http://payapi.shopxo.net/api/pay/mchCreateOrder/?'.$param['urls'].'&sign='.md5($param['sign'].'&key='.$this->config['appsecret']);
|
||||
return DataReturn('处理成功', 0, $url);
|
||||
}
|
||||
|
||||
/**
|
||||
* [GetParamSign 签名生成]
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @datetime 2018-09-28T00:28:07+0800
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
private function GetParamSign($params = [])
|
||||
{
|
||||
$sign = '';
|
||||
$urls = '';
|
||||
ksort($params);
|
||||
reset($params);
|
||||
|
||||
foreach($params AS $key => $val)
|
||||
{
|
||||
// 跳过这些不参数签名
|
||||
if($val == '' || $key == 'sign')
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
//后面追加&拼接URL
|
||||
if($sign != '')
|
||||
{
|
||||
$sign .= "&";
|
||||
$urls .= "&";
|
||||
}
|
||||
$sign .= "$key=$val"; //拼接为url参数形式
|
||||
$urls .= "$key=" . urlencode($val); //拼接为url参数形式并URL编码参数值
|
||||
}
|
||||
|
||||
$result = array(
|
||||
'urls' => $urls,
|
||||
'sign' => $sign,
|
||||
);
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付回调处理
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-19
|
||||
* @desc description
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
public function Respond($params = [])
|
||||
{
|
||||
if(empty($this->config))
|
||||
{
|
||||
return DataReturn('配置有误', -1);
|
||||
}
|
||||
if(empty($params['pay_no']))
|
||||
{
|
||||
return DataReturn('支付失败', -1);
|
||||
}
|
||||
|
||||
// 签名验证
|
||||
$param = $this->GetParamSign($params);
|
||||
if(md5($param['sign'].$this->config['key']) != $params['sign'])
|
||||
{
|
||||
return DataReturn('签名错误', -1);
|
||||
}
|
||||
|
||||
// 支付状态
|
||||
if(isset($params['status']))
|
||||
{
|
||||
switch($params['status'])
|
||||
{
|
||||
// 成功
|
||||
case 0 :
|
||||
$ret = DataReturn('支付成功', 0, $this->ReturnData($params));
|
||||
break;
|
||||
|
||||
// 失败
|
||||
case 1 :
|
||||
$ret = DataReturn('支付失败', -100);
|
||||
break;
|
||||
|
||||
// 参数有误
|
||||
case 2 :
|
||||
$ret = DataReturn('支付参数有误', -1001);
|
||||
break;
|
||||
|
||||
// 默认
|
||||
default :
|
||||
$ret = DataReturn('支付异常错误', -1002);
|
||||
}
|
||||
} else {
|
||||
$ret = DataReturn('支付异常错误', -1003);
|
||||
}
|
||||
return $ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* [ReturnData 返回数据统一格式]
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @datetime 2018-10-06T16:54:24+0800
|
||||
* @param [array] $data [返回数据]
|
||||
*/
|
||||
private function ReturnData($data)
|
||||
{
|
||||
// 返回数据固定基础参数
|
||||
$data['trade_no'] = isset($data['pay_no']) ? $data['pay_no'] : ''; // 支付平台 - 订单号
|
||||
$data['buyer_user'] = isset($data['pay_id']) ? $data['pay_id'] : ''; // 支付平台 - 用户
|
||||
$data['out_trade_no'] = substr($data['pay_id'], 0, strlen($data['pay_id'])-6); // 本系统发起支付的 - 订单号
|
||||
$data['subject'] = isset($data['param']) ? $data['param'] : ''; // 本系统发起支付的 - 商品名称
|
||||
$data['pay_price'] = $data['money']; // 本系统发起支付的 - 总价
|
||||
|
||||
return $data;
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
|
@ -213,9 +213,6 @@
|
|||
.goods-base .base-grid view {
|
||||
width: calc(33.33% - 1px);
|
||||
}
|
||||
.goods-base .base-grid view:not(:last-child) {
|
||||
border-right: 1px solid #f5f5f5;
|
||||
}
|
||||
.goods-base .base-grid view .cr-main {
|
||||
padding-left: 10rpx;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
</block>
|
||||
</swiper>
|
||||
|
||||
<!-- 基础信息 -->
|
||||
<!-- 基础信息 -->
|
||||
<view class="goods-base bg-white">
|
||||
<view class="goods-title multi-text" style="color:{{goods.title_color}}">{{goods.title}}</view>
|
||||
<view class="goods-price single-text">
|
||||
|
|
@ -30,7 +30,7 @@
|
|||
<view a:if="{{(goods.original_price || null) != null}}" class="original-price">¥{{goods.original_price}}</view>
|
||||
</view>
|
||||
<view class="base-grid oh">
|
||||
<view class="fl tc">
|
||||
<view class="fl tl">
|
||||
<text class="cr-888">累计销量</text>
|
||||
<text class="cr-main">{{goods.sales_count}}</text>
|
||||
</view>
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
<text class="cr-888">浏览次数</text>
|
||||
<text class="cr-main">{{goods.access_count}}</text>
|
||||
</view>
|
||||
<view class="fl tc">
|
||||
<view class="fl tr">
|
||||
<text class="cr-888">累计评论</text>
|
||||
<text class="cr-main">{{goods.comments_count}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -56,12 +56,13 @@ App({
|
|||
"message": "消息",
|
||||
"user_integral": "我的积分",
|
||||
"user_goods_browse": "我的足迹",
|
||||
"goods_comment": "商品评论",
|
||||
},
|
||||
|
||||
// 请求地址
|
||||
// request_url: "{{request_url}}",
|
||||
request_url: 'http://tp5-dev.com/',
|
||||
request_url: 'https://test.shopxo.net/',
|
||||
//request_url: 'https://test.shopxo.net/',
|
||||
|
||||
// 基础信息
|
||||
application_title: "{{application_title}}",
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"pages": [
|
||||
"pages": ["pages/goods-comment/goods-comment",
|
||||
"pages/index/index",
|
||||
"pages/goods-category/goods-category",
|
||||
"pages/cart/cart",
|
||||
|
|
|
|||
|
|
@ -0,0 +1,168 @@
|
|||
const app = getApp();
|
||||
Page({
|
||||
data: {
|
||||
data_list_loding_status: 1,
|
||||
data_bottom_line_status: false,
|
||||
data_list: [],
|
||||
data_page_total: 0,
|
||||
data_page: 1,
|
||||
goods_score: null,
|
||||
params: null,
|
||||
progress_class: ['progress-bar-danger', 'progress-bar-warning', 'progress-bar-secondary', '', 'progress-bar-success'],
|
||||
},
|
||||
|
||||
onLoad(params) {
|
||||
params['goods_id']=2;
|
||||
this.setData({ params: params });
|
||||
this.init();
|
||||
},
|
||||
|
||||
onShow() {
|
||||
wx.setNavigationBarTitle({ title: app.data.common_pages_title.goods_comment });
|
||||
},
|
||||
|
||||
// 初始化
|
||||
init() {
|
||||
// 获取数据
|
||||
this.goods_score();
|
||||
this.get_data_list();
|
||||
},
|
||||
|
||||
// 获取商品评分
|
||||
goods_score() {
|
||||
wx.request({
|
||||
url: app.get_request_url("goodsscore", "goods"),
|
||||
method: "POST",
|
||||
data: { goods_id: this.data.params.goods_id },
|
||||
dataType: "json",
|
||||
header: { 'content-type': 'application/x-www-form-urlencoded' },
|
||||
success: res => {
|
||||
if (res.data.code == 0) {
|
||||
this.setData({
|
||||
goods_score: res.data.data || null,
|
||||
});
|
||||
} else {
|
||||
app.showToast(res.data.msg);
|
||||
}
|
||||
},
|
||||
fail: () => {
|
||||
app.showToast("服务器请求出错");
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
// 获取数据列表
|
||||
get_data_list(is_mandatory) {
|
||||
// 参数校验
|
||||
if ((this.data.params.goods_id || null) == null) {
|
||||
wx.stopPullDownRefresh();
|
||||
this.setData({
|
||||
data_bottom_line_status: false,
|
||||
data_list_loding_status: 2,
|
||||
});
|
||||
} else {
|
||||
var self = this;
|
||||
|
||||
// 分页是否还有数据
|
||||
if ((is_mandatory || 0) == 0) {
|
||||
if (this.data.data_bottom_line_status == true) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// 加载loding
|
||||
wx.showLoading({ title: "加载中..." });
|
||||
this.setData({
|
||||
data_list_loding_status: 1
|
||||
});
|
||||
|
||||
wx.request({
|
||||
url: app.get_request_url("comment", "goods"),
|
||||
method: "POST",
|
||||
data: { goods_id: this.data.params.goods_id, page: this.data.data_page },
|
||||
dataType: "json",
|
||||
header: { 'content-type': 'application/x-www-form-urlencoded' },
|
||||
success: res => {
|
||||
wx.hideLoading();
|
||||
wx.stopPullDownRefresh();
|
||||
if (res.data.code == 0) {
|
||||
if (res.data.data.data.length > 0) {
|
||||
if (this.data.data_page <= 1) {
|
||||
var temp_data_list = res.data.data.data;
|
||||
} else {
|
||||
var temp_data_list = this.data.data_list;
|
||||
var temp_data = res.data.data.data;
|
||||
for (var i in temp_data) {
|
||||
temp_data_list.push(temp_data[i]);
|
||||
}
|
||||
}
|
||||
this.setData({
|
||||
data_list: temp_data_list,
|
||||
data_total: res.data.data.total,
|
||||
data_page_total: res.data.data.page_total,
|
||||
data_list_loding_status: 3,
|
||||
data_page: this.data.data_page + 1
|
||||
});
|
||||
|
||||
// 是否还有数据
|
||||
if (this.data.data_page > 1 && this.data.data_page > this.data.data_page_total) {
|
||||
this.setData({ data_bottom_line_status: true });
|
||||
} else {
|
||||
this.setData({ data_bottom_line_status: false });
|
||||
}
|
||||
} else {
|
||||
this.setData({
|
||||
data_list_loding_status: 0,
|
||||
});
|
||||
if (this.data.data_page <= 1) {
|
||||
this.setData({
|
||||
data_list: [],
|
||||
data_bottom_line_status: false,
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.setData({
|
||||
data_list_loding_status: 0
|
||||
});
|
||||
|
||||
app.showToast(res.data.msg);
|
||||
}
|
||||
},
|
||||
fail: () => {
|
||||
wx.hideLoading();
|
||||
wx.stopPullDownRefresh();
|
||||
|
||||
this.setData({
|
||||
data_list_loding_status: 2
|
||||
});
|
||||
app.showToast("服务器请求出错");
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
// 下拉刷新
|
||||
onPullDownRefresh() {
|
||||
this.setData({
|
||||
data_page: 1
|
||||
});
|
||||
this.get_data_list(1);
|
||||
},
|
||||
|
||||
// 滚动加载
|
||||
scroll_lower(e) {
|
||||
this.get_data_list();
|
||||
},
|
||||
|
||||
// 详情图片查看
|
||||
goods_detail_images_view_event(e) {
|
||||
var value = e.currentTarget.dataset.value || null;
|
||||
if (value != null) {
|
||||
wx.previewImage({
|
||||
current: 0,
|
||||
urls: [value]
|
||||
});
|
||||
}
|
||||
},
|
||||
});
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"usingComponents": {}
|
||||
}
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
<!-- 评分 -->
|
||||
<view wx:if="{{goods_score != null}}" class="score-container oh br-b">
|
||||
<view class="score fl tc">
|
||||
<view class="cr-666">动态评分</view>
|
||||
<view class="value">{{goods_score.avg || '0.0'}}</view>
|
||||
</view>
|
||||
<view class="progress fr tc">
|
||||
<block a:for="{{goods_score.rating}}" for-key="key">
|
||||
<view class="progress-bar {{progress_class[key]}}" style="width: {{item.portion}}%;">{item.name}}({{item.portion}}%)</view>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 列表 -->
|
||||
<scroll-view scroll-y="{{true}}" class="scroll-box" bindscrolltolower="scroll_lower" lower-threshold="30">
|
||||
<view wx:for="{{data_list}}" wx:key="key" class="comment-item br-b spacing-mt">
|
||||
<view class="oh nav">
|
||||
<image class="avatar dis-block fl" src="{{item.user.avatar || '/images/default-user.png'}}" mode="aspectFit"></image>
|
||||
<view class="base-nav fr">
|
||||
<text>{{item.user.user_name_view}}</text>
|
||||
<text class="cr-ccc">评论于</text>
|
||||
<text class="cr-666">{{item.add_time_time}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="base-content oh">
|
||||
<view class="content cr-666">{{item.content}}</view>
|
||||
<view wx:if="{{(item.msg || null) != null}}" class="spec">{{item.msg}}</view>
|
||||
<view wx:if="{{item.is_reply == 1 && (item.reply || null) != null}}" class="reply br-t-dashed">
|
||||
<text class="cr-666">管理员回复:</text>
|
||||
<text class="reply-desc">{{item.reply}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view wx:if="{{data_list.length == 0}}">
|
||||
<import src="/pages/common/nodata.wxml" />
|
||||
<template is="nodata" data="{{status: data_list_loding_status}}"></template>
|
||||
</view>
|
||||
|
||||
<import src="/pages/common/bottom_line.wxml" />
|
||||
<template is="bottom_line" data="{{status: data_bottom_line_status}}"></template>
|
||||
</scroll-view>
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
.score-container {
|
||||
padding: 10rpx;
|
||||
}
|
||||
.score-container .score {
|
||||
width: 180rpx;
|
||||
border-right: 1px solid #eee;
|
||||
}
|
||||
.score-container .score .value {
|
||||
color: #f03726;
|
||||
font-weight: bold;
|
||||
font-size: 60rpx;
|
||||
line-height: 60rpx;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
|
||||
.progress {
|
||||
overflow: hidden;
|
||||
height: 40rpx;
|
||||
margin-top: 40rpx;
|
||||
background-color: #f5f5f5;
|
||||
border-radius: 0;
|
||||
width: calc(100% - 200rpx);
|
||||
}
|
||||
.progress-bar {
|
||||
float: left;
|
||||
width: 0;
|
||||
height: 100%;
|
||||
font-size: 24rpx;
|
||||
line-height: 40rpx;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
background-color: #0e90d2;
|
||||
}
|
||||
.progress-bar-danger {
|
||||
background-color: #dd514c;
|
||||
}
|
||||
.progress-bar-warning {
|
||||
background-color: #F37B1D;
|
||||
}
|
||||
.progress-bar-secondary {
|
||||
background-color: #3bb4f2;
|
||||
}
|
||||
.progress-bar-success {
|
||||
background-color: #5eb95e;
|
||||
}
|
||||
|
||||
|
||||
.comment-item {
|
||||
padding: 0 10rpx 10rpx 10rpx;
|
||||
}
|
||||
.comment-item .nav {
|
||||
background: #eee;
|
||||
padding: 10rpx 0;
|
||||
}
|
||||
.comment-item .avatar {
|
||||
width: 70rpx;
|
||||
height: 70rpx;
|
||||
border-radius: 50%;
|
||||
border: 1px solid #e2e2e2;
|
||||
}
|
||||
.comment-item .base-nav {
|
||||
width: calc(100% - 90rpx);
|
||||
line-height: 70rpx;
|
||||
}
|
||||
.comment-item .base-nav text:not(:last-child) {
|
||||
margin-right: 5rpx;
|
||||
}
|
||||
|
||||
.base-content {
|
||||
padding: 10rpx;
|
||||
}
|
||||
.base-content .content, .base-content .reply {
|
||||
line-height: 46rpx;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
.base-content .spec {
|
||||
margin-top: 20rpx;
|
||||
color: #B0B0B0;
|
||||
}
|
||||
.base-content .reply {
|
||||
margin-top: 20rpx;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
.base-content .reply-desc {
|
||||
color: #905602;
|
||||
}
|
||||
|
|
@ -79,6 +79,7 @@ Page({
|
|||
method: "POST",
|
||||
data: {goods_id: this.data.params.goods_id},
|
||||
dataType: "json",
|
||||
header: { 'content-type': 'application/x-www-form-urlencoded' },
|
||||
success: res => {
|
||||
wx.stopPullDownRefresh();
|
||||
wx.hideLoading();
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@
|
|||
<view wx:if="{{(goods.original_price || null) != null}}" class="original-price">¥{{goods.original_price}}</view>
|
||||
</view>
|
||||
<view class="base-grid oh">
|
||||
<view class="fl tc">
|
||||
<view class="fl tl">
|
||||
<text class="cr-888">累计销量</text>
|
||||
<text class="cr-main">{{goods.sales_count}}</text>
|
||||
</view>
|
||||
|
|
@ -47,7 +47,7 @@
|
|||
<text class="cr-888">浏览次数</text>
|
||||
<text class="cr-main">{{goods.access_count}}</text>
|
||||
</view>
|
||||
<view class="fl tc">
|
||||
<view class="fl tr">
|
||||
<text class="cr-888">累计评论</text>
|
||||
<text class="cr-main">{{goods.comments_count}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -210,9 +210,6 @@
|
|||
.goods-base .base-grid view {
|
||||
width: calc(33.33% - 1px);
|
||||
}
|
||||
.goods-base .base-grid view:not(:last-child) {
|
||||
border-right: 1px solid #f5f5f5;
|
||||
}
|
||||
.goods-base .base-grid view .cr-main {
|
||||
padding-left: 10rpx;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue