mirror of
https://gitee.com/zongzhige/shopxo.git
synced 2026-06-06 03:56:57 +08:00
v3.0.1
This commit is contained in:
@ -10,12 +10,12 @@
|
||||
<!-- 2. 格子大小 -->
|
||||
<!-- 3. 内容位置居(左|中|右) -->
|
||||
<!-- 4. 格子是否固定(left|right 左|右) -->
|
||||
<th class="
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}}am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}}am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}}am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}}am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}}am-operate-grid {{/if}}
|
||||
<th class="form-table-search-item-head-title-{{$t.unique_key}}
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}} am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}} am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}} am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}} am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}} am-operate-grid {{/if}}
|
||||
"
|
||||
style="
|
||||
{{if !empty($t['width'])}}
|
||||
|
||||
@ -6,12 +6,12 @@
|
||||
{{/if}}
|
||||
{{foreach $form_table['form'] as $k=>$t}}
|
||||
{{if !isset($t['is_list']) or $t['is_list'] eq 1}}
|
||||
<td class="
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}}am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}}am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}}am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}}am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}}am-operate-grid {{/if}}
|
||||
<td class="form-table-search-item-head-value-{{$t.unique_key}}
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}} am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}} am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}} am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}} am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}} am-operate-grid {{/if}}
|
||||
"
|
||||
style="
|
||||
{{if !empty($t['width'])}}
|
||||
|
||||
@ -62,7 +62,7 @@
|
||||
|
||||
<!-- 快递 - 用户地址 -->
|
||||
{{if isset($base['site_model']) and $base['site_model'] eq 0}}
|
||||
<div id="buy-items-address" class="address user-address-container">
|
||||
<div id="buy-items-address" class="address user-address-container address-phone-padding">
|
||||
<div class="control am-margin-bottom-main">
|
||||
<h3>
|
||||
<span>{{:MyLang('buy.confirm_delivery_address_name')}}</span>
|
||||
@ -117,7 +117,7 @@
|
||||
'msg' => MyLang('buy.no_address_info_tips'),
|
||||
'icon' => $attachment_host.'/static/common/images/no-address.png',
|
||||
])}}
|
||||
<button class="am-btn am-text-xs am-background-white am-color-main am-border-main am-radius am-margin-top-main address-submit-save" type="button" data-url="{{:MyUrl('index/useraddress/saveinfo')}}">{{:MyLang('buy.use_new_address_name')}}</button>
|
||||
<button class="am-btn am-text-xs am-background-white am-color-main am-border-main am-radius am-margin-bottom-main address-submit-save" type="button" data-url="{{:MyUrl('index/useraddress/saveinfo')}}">{{:MyLang('buy.use_new_address_name')}}</button>
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
@ -453,17 +453,17 @@
|
||||
{{/php}}
|
||||
<!-- 分组商品详情基础底部钩子-结束 -->
|
||||
</td>
|
||||
<td class="price am-hide-sm-only">
|
||||
<td class="am-hide-sm-only">
|
||||
{{if $goods['original_price'] gt 0}}
|
||||
<p class="original-price">{{$currency_symbol}}{{$goods.original_price}}</p>
|
||||
{{/if}}
|
||||
<p class="original-price">{{$currency_symbol}}{{$goods.price}}</p>
|
||||
<p>{{$currency_symbol}}{{$goods.price}}</p>
|
||||
</td>
|
||||
<td class="number am-hide-sm-only am-color-grey">
|
||||
{{$goods.stock}} {{$goods.inventory_unit}}
|
||||
</td>
|
||||
<td class="total-price am-hide-sm-only am-color-grey-dark am-text-center">
|
||||
<span>{{$currency_symbol}}</span><strong class="total-price-content">{{$goods.total_price}}</strong>
|
||||
<span>{{$currency_symbol}}</span><strong class="line-price total-price-content">{{$goods.total_price}}</strong>
|
||||
</td>
|
||||
</tr>
|
||||
{{/foreach}}
|
||||
@ -505,12 +505,11 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3"></td>
|
||||
<td class="am-text-center am-text-bottom">
|
||||
<td colspan="4" class="am-text-right am-text-bottom">
|
||||
<!-- 含运费小计 -->
|
||||
<div class="buy-point-discharge">
|
||||
<div class="am-text-right">
|
||||
{{if $v['order_base']['total_price'] neq $v['order_base']['actual_price']}}
|
||||
<span class="original-price am-margin-right-xs">{{$currency_symbol}}{{$v.order_base.total_price}}</span>
|
||||
<span class="original-price am-margin-right-sm">{{$currency_symbol}}{{$v.order_base.total_price}}</span>
|
||||
{{/if}}
|
||||
<span class="buy-point-discharge-sum">
|
||||
<span>{{:MyLang('buy.goods_item_total_name')}}</span>
|
||||
|
||||
@ -372,8 +372,7 @@
|
||||
{{else /}}
|
||||
<!-- 空购物车 -->
|
||||
<div class="mixed-tips">
|
||||
<!-- <i class="am-icon-cart-plus am-fl icon"></i> -->
|
||||
<img class="am-fl" src="{{$attachment_host}}/static/plugins/images/intellectstools/cart.png" />
|
||||
<img class="am-fl" src="{{$attachment_host}}/static/index/{{$default_theme}}/images/empty-cart.png" />
|
||||
<div class="mixed-tips-content am-fl">
|
||||
<h1>{{:MyLang('cart.no_cart_data_tips')}}</h1>
|
||||
<ul>
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name":"默认主题",
|
||||
"ver":"3.0.0",
|
||||
"ver":"3.0.1",
|
||||
"author":"Devil",
|
||||
"home":"https://shopxo.net/"
|
||||
}
|
||||
@ -55,7 +55,7 @@
|
||||
{{/php}}
|
||||
|
||||
<a href="{{$v.goods_url}}" target="_blank">
|
||||
<img src="{{$v.images}}" alt="{{$v.title}}" />
|
||||
<img src="{{$v.images}}" alt="{{$v.title}}" class="goods-images am-radius" />
|
||||
</a>
|
||||
|
||||
<!-- 商品信息售价顶部钩子 -->
|
||||
|
||||
@ -53,7 +53,7 @@
|
||||
{{/php}}
|
||||
|
||||
<a href="{{$v.goods_url}}" target="_blank">
|
||||
<img src="{{$v.images}}" alt="{{$v.title}}" class="am-images-scale" />
|
||||
<img src="{{$v.images}}" alt="{{$v.title}}" class="goods-images am-radius am-images-scale" />
|
||||
</a>
|
||||
|
||||
<!-- 商品信息售价顶部钩子 -->
|
||||
|
||||
@ -77,7 +77,7 @@
|
||||
<li class="am-fl am-text-center title">友情链接</li>
|
||||
{{foreach $link_list as $v}}
|
||||
<li class="am-fl am-text-center">
|
||||
<a href="{{$v.url}}" {{if $v['is_new_window_open'] eq 1}} target="_blank"{{/if}} title="{{$v.describe}}">{{$v.name}}</a>
|
||||
<a href="{{$v.url}}" {{if $v['is_new_window_open'] eq 1}} target="_blank"{{/if}}>{{$v.name}}</a>
|
||||
</li>
|
||||
{{/foreach}}
|
||||
</ul>
|
||||
|
||||
@ -15,8 +15,8 @@
|
||||
{{foreach $goods_category_list as $k=>$v}}
|
||||
<li class="first" data-index="{{$k}}">
|
||||
{{if $category_show_level gt 1}}
|
||||
<img class="category-fillet-top am-hide" src="{{$attachment_host}}/static/index/default/images/corner_round_top.png" />
|
||||
<img class="category-fillet-bottom am-hide" src="{{$attachment_host}}/static/index/default/images/corner_round_bottom.png" />
|
||||
<img class="category-fillet-top am-hide" src="{{$attachment_host}}/static/index/{{$default_theme}}/images/corner_round_top.png" />
|
||||
<img class="category-fillet-bottom am-hide" src="{{$attachment_host}}/static/index/{{$default_theme}}/images/corner_round_bottom.png" />
|
||||
{{/if}}
|
||||
<a href="{{:MyUrl('index/search/index', ['cid'=>$v['id']])}}" class="am-block">
|
||||
<div class="category-info">
|
||||
|
||||
@ -10,12 +10,12 @@
|
||||
<!-- 2. 格子大小 -->
|
||||
<!-- 3. 内容位置居(左|中|右) -->
|
||||
<!-- 4. 格子是否固定(left|right 左|右) -->
|
||||
<th class="
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}}am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}}am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}}am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}}am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}}am-operate-grid {{/if}}
|
||||
<th class="form-table-search-item-head-title-{{$t.unique_key}}
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}} am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}} am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}} am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}} am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}} am-operate-grid {{/if}}
|
||||
"
|
||||
style="
|
||||
{{if !empty($t['width'])}}
|
||||
|
||||
@ -6,12 +6,12 @@
|
||||
{{/if}}
|
||||
{{foreach $form_table['form'] as $k=>$t}}
|
||||
{{if !isset($t['is_list']) or $t['is_list'] eq 1}}
|
||||
<td class="
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}}am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}}am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}}am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}}am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}}am-operate-grid {{/if}}
|
||||
<td class="form-table-search-item-head-value-{{$t.unique_key}}
|
||||
{{if isset($t['is_middle']) and $t['is_middle'] eq 1}} am-text-middle {{/if}}
|
||||
{{if !empty($t['grid_size'])}} am-grid-{{$t.grid_size}} {{/if}}
|
||||
{{if !empty($t['align'])}} am-text-{{$t.align}} {{/if}}
|
||||
{{if !empty($t['fixed'])}} am-grid-fixed-{{$t.fixed}} {{/if}}
|
||||
{{if !empty($t['view_type']) and $t['view_type'] eq 'operate'}} am-operate-grid {{/if}}
|
||||
"
|
||||
style="
|
||||
{{if !empty($t['width'])}}
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{block name="form_navigation"}}
|
||||
<div class="am-background-grey-f9 am-radius-lg am-margin-bottom-main am-padding-main am-flex am-flex-items-center am-flex-justify-center">
|
||||
<div class="available am-padding-vertical-module am-flex-1 am-flex am-flex-items-center am-flex-justify-center am-divider-dashed-right">
|
||||
<img src="{{$attachment_host}}/static/index/default/images/integral.png" alt="" width="50">
|
||||
<img src="{{$attachment_host}}/static/index/{{$default_theme}}/images/integral.png" alt="" width="50">
|
||||
<div class="am-padding-left-xs">
|
||||
<div>{{:MyLang('userintegral.base_normal_title')}}</div>
|
||||
<div class="am-text-xl am-font-weight">
|
||||
@ -15,7 +15,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="locking am-padding-vertical-module am-flex-1 am-flex am-flex-items-center am-flex-justify-center">
|
||||
<img src="{{$attachment_host}}/static/index/default/images/lock.png" alt="" width="50">
|
||||
<img src="{{$attachment_host}}/static/index/{{$default_theme}}/images/lock.png" alt="" width="50">
|
||||
<div class="am-padding-left-xs">
|
||||
<div class="am-color-grey-dark">{{:MyLang('userintegral.base_locking_title')}}</div>
|
||||
<div class="am-text-xl am-font-weight">
|
||||
|
||||
@ -120,6 +120,7 @@ class ConstService
|
||||
'2.3.2' => ['value' => '2.3.2', 'name' => 'v2.3.2'],
|
||||
'2.3.3' => ['value' => '2.3.3', 'name' => 'v2.3.3'],
|
||||
'3.0.0' => ['value' => '3.0.0', 'name' => 'v3.0.0'],
|
||||
'3.0.1' => ['value' => '3.0.1', 'name' => 'v3.0.1'],
|
||||
],
|
||||
|
||||
// 搜索排序方式
|
||||
|
||||
@ -2264,10 +2264,32 @@ class GoodsService
|
||||
{
|
||||
$base = Db::name('GoodsSpecBase')->find($goods_service_goods_spec_base_static_data[$key]);
|
||||
} else {
|
||||
// 有规格值
|
||||
$base = [];
|
||||
if(!empty($spec))
|
||||
// 商品信息
|
||||
$info = Db::name('Goods')->where(['id'=>$goods_id])->field('id,title,is_exist_many_spec')->find();
|
||||
if(empty($info))
|
||||
{
|
||||
return DataReturn('【'.$goods_id.'】'.MyLang('no_goods'), -1);
|
||||
}
|
||||
|
||||
// 规格值校验处理
|
||||
$base = [];
|
||||
if(empty($spec))
|
||||
{
|
||||
// 没有指定规格、但是商品已存在规则则报错
|
||||
if($info['is_exist_many_spec'] == 1)
|
||||
{
|
||||
return DataReturn('【'.$info['title'].'】'.MyLang('common_service.goods.base_spec_not_choice_tips'), -1);
|
||||
}
|
||||
|
||||
// 单个规则则直接获取规格基础
|
||||
$base = Db::name('GoodsSpecBase')->where($where)->find();
|
||||
} else {
|
||||
// 指定规格规格、但是商品没有规格则报错
|
||||
if($info['is_exist_many_spec'] == 0)
|
||||
{
|
||||
return DataReturn('【'.$info['title'].'】'.MyLang('common_service.goods.base_spec_empty_tips'), -1);
|
||||
}
|
||||
|
||||
// 获取规格值基础值id
|
||||
$where['value'] = $spec;
|
||||
$ids = Db::name('GoodsSpecValue')->where($where)->column('goods_spec_base_id');
|
||||
@ -2304,8 +2326,6 @@ class GoodsService
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$base = Db::name('GoodsSpecBase')->where($where)->find();
|
||||
}
|
||||
if(!empty($base))
|
||||
{
|
||||
|
||||
@ -2005,7 +2005,7 @@ class OrderService
|
||||
$ret = ParamsChecked($params, $p);
|
||||
if($ret !== true)
|
||||
{
|
||||
throw new \Exception($ret['msg']);
|
||||
throw new \Exception($ret);
|
||||
}
|
||||
|
||||
// 用户类型
|
||||
@ -2045,7 +2045,7 @@ class OrderService
|
||||
$ret = ParamsChecked($params, $p);
|
||||
if($ret !== true)
|
||||
{
|
||||
throw new \Exception($ret['msg']);
|
||||
throw new \Exception($ret);
|
||||
}
|
||||
break;
|
||||
|
||||
@ -2061,7 +2061,7 @@ class OrderService
|
||||
$ret = ParamsChecked($params, $p);
|
||||
if($ret !== true)
|
||||
{
|
||||
throw new \Exception($ret['msg']);
|
||||
throw new \Exception($ret);
|
||||
}
|
||||
|
||||
// 校验
|
||||
@ -2076,42 +2076,59 @@ class OrderService
|
||||
}
|
||||
break;
|
||||
}
|
||||
// 订单更新
|
||||
$upd_data = [
|
||||
'status' => 3,
|
||||
'express_id' => isset($params['express_id']) ? intval($params['express_id']) : 0,
|
||||
'express_number' => isset($params['express_number']) ? $params['express_number'] : '',
|
||||
'delivery_time' => time(),
|
||||
'upd_time' => time(),
|
||||
];
|
||||
if(!Db::name('Order')->where($where)->update($upd_data))
|
||||
{
|
||||
throw new \Exception(MyLang('delivery_fail'));
|
||||
}
|
||||
|
||||
// 库存扣除
|
||||
$ret = BuyService::OrderInventoryDeduct(['order_id'=>$order['id'], 'opt_type'=>'delivery']);
|
||||
if($ret['code'] != 0)
|
||||
{
|
||||
throw new \Exception($ret['msg']);
|
||||
}
|
||||
|
||||
// 用户消息
|
||||
$lang = MyLang('common_service.order.order_delivery_message_data');
|
||||
MessageService::MessageAdd($order['user_id'], $lang['title'], $lang['desc'], self::BusinessTypeName(), $order['id']);
|
||||
|
||||
// 订单状态日志
|
||||
$creator = isset($params['creator']) ? intval($params['creator']) : 0;
|
||||
$creator_name = isset($params['creator_name']) ? htmlentities($params['creator_name']) : '';
|
||||
self::OrderHistoryAdd($order['id'], $upd_data['status'], $order['status'], MyLang('delivery_title'), $creator, $creator_name);
|
||||
|
||||
// 完成
|
||||
return DataReturn(MyLang('delivery_success'), 0);
|
||||
// 发货更新操作
|
||||
return self::OrderDeliveryUpdateHandle($order, $params);
|
||||
} catch(\Exception $e) {
|
||||
return DataReturn($e->getMessage(), -1);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 订单发货更新处理
|
||||
* @author Devil
|
||||
* @blog http://gong.gg/
|
||||
* @version 1.0.0
|
||||
* @date 2018-09-30
|
||||
* @desc description
|
||||
* @param [array] $order [订单信息]
|
||||
* @param [array] $params[输入参数]
|
||||
*/
|
||||
public static function OrderDeliveryUpdateHandle($order, $params = [])
|
||||
{
|
||||
// 订单更新
|
||||
$upd_data = [
|
||||
'status' => 3,
|
||||
'express_id' => isset($params['express_id']) ? intval($params['express_id']) : 0,
|
||||
'express_number' => isset($params['express_number']) ? $params['express_number'] : '',
|
||||
'delivery_time' => time(),
|
||||
'upd_time' => time(),
|
||||
];
|
||||
if(!Db::name('Order')->where(['id'=>$order['id']])->update($upd_data))
|
||||
{
|
||||
return DataReturn(MyLang('delivery_fail'), -1);
|
||||
}
|
||||
|
||||
// 库存扣除
|
||||
$ret = BuyService::OrderInventoryDeduct(['order_id'=>$order['id'], 'opt_type'=>'delivery']);
|
||||
if($ret['code'] != 0)
|
||||
{
|
||||
return $ret;
|
||||
}
|
||||
|
||||
// 用户消息
|
||||
$lang = MyLang('common_service.order.order_delivery_message_data');
|
||||
MessageService::MessageAdd($order['user_id'], $lang['title'], $lang['desc'], self::BusinessTypeName(), $order['id']);
|
||||
|
||||
// 订单状态日志
|
||||
$creator = isset($params['creator']) ? intval($params['creator']) : 0;
|
||||
$creator_name = isset($params['creator_name']) ? htmlentities($params['creator_name']) : '';
|
||||
self::OrderHistoryAdd($order['id'], $upd_data['status'], $order['status'], MyLang('delivery_title'), $creator, $creator_name);
|
||||
|
||||
// 完成
|
||||
return DataReturn(MyLang('delivery_success'), 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* 订单收货
|
||||
* @author Devil
|
||||
|
||||
@ -397,12 +397,15 @@ class UserService
|
||||
* @param [string] $where_field [字段名称]
|
||||
* @param [string] $where_value [字段值]
|
||||
* @param [string] $field [指定字段]
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
public static function UserPlatformInfo($where_field, $where_value, $field = '*')
|
||||
public static function UserPlatformInfo($where_field, $where_value, $field = '*', $params = [])
|
||||
{
|
||||
$system_type = empty($params['system_type_name']) ? SYSTEM_TYPE : $params['system_type_name'];
|
||||
$platform = empty($params['platform']) ? APPLICATION_CLIENT_TYPE : $params['platform'];
|
||||
$where = [
|
||||
['system_type', '=', SYSTEM_TYPE],
|
||||
['platform', '=', APPLICATION_CLIENT_TYPE],
|
||||
['system_type', '=', $system_type],
|
||||
['platform', '=', $platform],
|
||||
[$where_field, '=', $where_value],
|
||||
];
|
||||
return Db::name('UserPlatform')->where($where)->field($field)->find();
|
||||
@ -418,8 +421,9 @@ class UserService
|
||||
* @param [string] $where_field [字段名称]
|
||||
* @param [string] $where_value [字段值]
|
||||
* @param [string] $field [指定字段]
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
public static function UserInfo($where_field, $where_value, $field = '*')
|
||||
public static function UserInfo($where_field, $where_value, $field = '*', $params = [])
|
||||
{
|
||||
// 用户平台表结构
|
||||
$structure = ResourcesService::TableStructureData('UserPlatform');
|
||||
@ -446,9 +450,11 @@ class UserService
|
||||
}
|
||||
|
||||
// 查询用户信息
|
||||
$system_type = empty($params['system_type_name']) ? SYSTEM_TYPE : $params['system_type_name'];
|
||||
$platform = empty($params['platform']) ? APPLICATION_CLIENT_TYPE : $params['platform'];
|
||||
$where = [
|
||||
['up.system_type', '=', SYSTEM_TYPE],
|
||||
['up.platform', '=', APPLICATION_CLIENT_TYPE],
|
||||
['up.system_type', '=', $system_type],
|
||||
['up.platform', '=', $platform],
|
||||
[$where_field, '=', $where_value],
|
||||
['u.is_delete_time', '=', 0],
|
||||
['u.is_logout_time', '=', 0],
|
||||
@ -503,8 +509,9 @@ class UserService
|
||||
if($where_field != 'id')
|
||||
{
|
||||
$system_type = empty($params['system_type_name']) ? SYSTEM_TYPE : $params['system_type_name'];
|
||||
$platform = empty($params['platform']) ? APPLICATION_CLIENT_TYPE : $params['platform'];
|
||||
$where[] = ['system_type', '=', $system_type];
|
||||
$where[] = ['platform', '=', APPLICATION_CLIENT_TYPE];
|
||||
$where[] = ['platform', '=', $platform];
|
||||
}
|
||||
$data['upd_time'] = time();
|
||||
return Db::name('UserPlatform')->where($where)->update($data);
|
||||
@ -792,13 +799,14 @@ class UserService
|
||||
* @datetime 2017-03-09T11:37:43+0800
|
||||
* @param [int] $user_id [用户id]
|
||||
* @param [array] $user [用户信息]
|
||||
* @param [array] $params [输入参数]
|
||||
* @return [boolean] [记录成功true, 失败false]
|
||||
*/
|
||||
public static function UserLoginRecord($user_id = 0, $user = [])
|
||||
public static function UserLoginRecord($user_id = 0, $user = [], $params = [])
|
||||
{
|
||||
if(!empty($user_id) && empty($user))
|
||||
{
|
||||
$user = self::UserHandle(self::UserInfo('id', $user_id));
|
||||
$user = self::UserHandle(self::UserInfo('id', $user_id, '*', $params));
|
||||
}
|
||||
if(!empty($user))
|
||||
{
|
||||
@ -1291,7 +1299,7 @@ class UserService
|
||||
$body_html = [];
|
||||
|
||||
// 用户登录后钩子
|
||||
$user = self::UserHandle(self::UserInfo('id', $user_id));
|
||||
$user = self::UserHandle(self::UserInfo('id', $user_id, '*', $params));
|
||||
|
||||
// 会员码生成处理
|
||||
if(empty($user['number_code']))
|
||||
@ -2687,12 +2695,12 @@ class UserService
|
||||
* @param [array] $data [用户信息]
|
||||
* @param [array] $params [输入参数]
|
||||
*/
|
||||
public static function UserBaseHandle($data, $params)
|
||||
public static function UserBaseHandle($data, $params = [])
|
||||
{
|
||||
// 系统类型
|
||||
if(empty($data['system_type']))
|
||||
{
|
||||
$data['system_type'] = SYSTEM_TYPE;
|
||||
$data['system_type'] = empty($params['system_type_name']) ? SYSTEM_TYPE : $params['system_type_name'];
|
||||
}
|
||||
|
||||
// 基础参数处理
|
||||
|
||||
@ -1,3 +1,19 @@
|
||||
+=========================================================+
|
||||
ShopXO 3.0.1 Release 20230903 http://shopxo.net
|
||||
+=========================================================+
|
||||
1. 订单管理再次支付默认选中上一次的支付方式
|
||||
2. 订单发货业务模块拆分
|
||||
3. 订单确认页面导航和合计样式错位修复
|
||||
4. 用户服务层基础方法优化,扩展性更高
|
||||
5. 友情链接标题未显示修复并去除title属性
|
||||
6. 富文本图片去除title属性
|
||||
7. 公共title忽略图片标签
|
||||
8. 购物车无数据提示icon错误修复
|
||||
9. 订单确认页面地址切换样式错位优化
|
||||
10. 动态数据表格支持头部class唯一表示
|
||||
|
||||
|
||||
|
||||
+=========================================================+
|
||||
ShopXO 3.0.0 Release 20230828 http://shopxo.net
|
||||
+=========================================================+
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
// 系统版本
|
||||
define('APPLICATION_VERSION', 'v3.0.0');
|
||||
define('APPLICATION_VERSION', 'v3.0.1');
|
||||
|
||||
// 检测PHP环境
|
||||
if(version_compare(PHP_VERSION,'7.4.0','<'))
|
||||
|
||||
@ -39,16 +39,20 @@ $(function()
|
||||
var $form_pay = $('form.form-validation-pay');
|
||||
$(document).on('click', '.submit-pay', function()
|
||||
{
|
||||
$form_pay.find('input[name=id]').val($(this).data('id'));
|
||||
var payment_id = parseInt($(this).data('payment-id') || 0);
|
||||
if($('.payment-items-'+payment_id).length > 0)
|
||||
$form_pay.find('input[name=id]').val($(this).data('id'));
|
||||
$form_pay.find('input[name=payment_id]').val(0);
|
||||
$form_pay.find('ul.payment-list li').each(function(k, v)
|
||||
{
|
||||
$form_pay.find('input[name=payment_id]').val(payment_id);
|
||||
$('.payment-items-'+payment_id).addClass('selected').siblings('li').removeClass('selected');
|
||||
} else {
|
||||
$form_pay.find('input[name=payment_id]').val(0);
|
||||
$('ul.payment-list li.selected').removeClass('selected');
|
||||
}
|
||||
var temp = parseInt($(this).data('value') || 0);
|
||||
if(temp == payment_id)
|
||||
{
|
||||
$(this).addClass('selected');
|
||||
$form_pay.find('input[name=payment_id]').val(payment_id);
|
||||
} else {
|
||||
$(this).removeClass('selected');
|
||||
}
|
||||
});
|
||||
});
|
||||
// 支付操作表单
|
||||
$form_pay.find('button[type=submit]').on('click', function()
|
||||
|
||||
@ -495,6 +495,7 @@ form.am-form .am-form-group.am-form-icon {
|
||||
}
|
||||
.common-prompt .am-close {
|
||||
font-size: 1.8rem;
|
||||
color: #666;
|
||||
}
|
||||
.common-prompt i{
|
||||
position: absolute;
|
||||
@ -506,19 +507,16 @@ form.am-form .am-form-group.am-form-icon {
|
||||
background-color: #FFEBE0;
|
||||
border-color: #EB5E12;
|
||||
color: #EB5E12;
|
||||
/* box-shadow: 0 0.2rem 0.4rem #fef0f0, 0 0 0.6rem rgba(0, 0, 0, 0); */
|
||||
}
|
||||
.common-prompt.am-alert-warning {
|
||||
background-color: #FFF6E3;
|
||||
border-color: #FAAD14;
|
||||
color: #FAAD14;
|
||||
/* box-shadow: 0 0.2rem 0.4rem #ffe7d5, 0 0 0.6rem rgba(0, 0, 0, 0); */
|
||||
}
|
||||
.common-prompt.am-alert-success {
|
||||
background: #E9FFF0;
|
||||
border-color: #38b865;
|
||||
color: #38B865;
|
||||
/* box-shadow: 0 0.2rem 0.4rem #e3fbd6, 0 0 0.6rem rgba(0, 0, 0, 0); */
|
||||
}
|
||||
.common-prompt .prompt-content { text-align: left; font-size: 1.2rem; }
|
||||
.common-prompt .prompt-msg {
|
||||
@ -1097,7 +1095,7 @@ button.colorpicker-submit img {
|
||||
* 表格-基础样式
|
||||
*/
|
||||
.am-table-scrollable-horizontal {
|
||||
border: 0.1rem solid rgba(0,0,0,.02);
|
||||
border: 0.1rem solid rgba(0,0,0,.04);
|
||||
position: relative;
|
||||
}
|
||||
.am-table-scrollable-horizontal .form-table-no-data {
|
||||
@ -1219,14 +1217,11 @@ button.colorpicker-submit img {
|
||||
/**
|
||||
* 表格-用户信息
|
||||
*/
|
||||
.am-form-table-data-container ul.user-base {
|
||||
padding-top: 0.2rem;
|
||||
}
|
||||
.am-form-table-data-container ul.user-base li {
|
||||
line-height: 1.2rem;
|
||||
line-height: 1.4rem;
|
||||
}
|
||||
.am-form-table-data-container ul.user-base li:first-child {
|
||||
margin-bottom: 0.7rem;
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
.am-form-table-data-container ul.user-base .user-number-code .am-dropdown-content {
|
||||
min-width: 10rem;
|
||||
|
||||
@ -3392,7 +3392,7 @@ fieldset[disabled] .am-checkbox-inline {
|
||||
text-decoration: none;
|
||||
line-height: 1.2rem;
|
||||
background-color: #fff;
|
||||
border: 0.1rem solid rgba(0,0,0,.02);
|
||||
border: 0.1rem solid rgba(0,0,0,.06);
|
||||
border-radius: 0;
|
||||
margin-bottom: 0.5rem;
|
||||
margin-right: 0.5rem;
|
||||
@ -4014,6 +4014,7 @@ fieldset[disabled] .am-checkbox-inline {
|
||||
text-align: center;
|
||||
background-color: #999999;
|
||||
border-radius: 0;
|
||||
border: 0;
|
||||
}
|
||||
.am-badge:empty {
|
||||
display: none;
|
||||
|
||||
@ -15,19 +15,6 @@
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.buy-items table tbody tr td .buy-point-discharge {
|
||||
display: flex;
|
||||
flex-flow: row wrap;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.buy-items table tbody tr td .buy-point-discharge-sum {
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.warehouse-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@ -214,7 +201,7 @@ ul.address-list li .user-base .address-detail .user {
|
||||
/*合计*/
|
||||
.buy-order-nav .box {
|
||||
float: left;
|
||||
width: calc(100% - 12rem);
|
||||
width: calc(100% - 14rem);
|
||||
height: 5rem;
|
||||
line-height: 5rem;
|
||||
text-align: left;
|
||||
|
||||
@ -1184,7 +1184,7 @@ ul.am-dropdown-content>li>a:focus {
|
||||
}
|
||||
|
||||
.mixed-tips-content {
|
||||
margin-top: 0.5rem;
|
||||
margin: 0.5rem 0 0 2rem;
|
||||
}
|
||||
|
||||
.mixed-tips-content h1 {
|
||||
@ -1381,7 +1381,8 @@ ul.am-dropdown-content>li>a:focus {
|
||||
.friendship-list ul li.title {
|
||||
font-weight: 500;
|
||||
font-size: 1.4rem;
|
||||
color: #FFFFFF;
|
||||
color: #333;
|
||||
margin-right: 2rem;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -25,7 +25,7 @@ ul, li, ol {list-style: none;}
|
||||
.floor {position: relative; }
|
||||
|
||||
/*小标签*/
|
||||
.aggregation .word{overflow: hidden; padding: 2rem 1.5rem; margin: 1.5rem;background: rgba(255,255,255,0.6);}
|
||||
.aggregation .word{overflow: hidden; padding: 2rem 1.5rem; margin: 1.5rem;background: rgba(255,255,255,0.6); width: calc(100% - 3rem); }
|
||||
.word .outer {margin: 0.5rem; width: calc(50% - 1.4rem); height: 2.6rem; line-height: 2.6rem; text-align: center;color: #666666;display: inline-block; border: 0.1rem solid #cecece; text-decoration: none; overflow: hidden;}
|
||||
|
||||
/*楼层左侧*/
|
||||
@ -224,5 +224,5 @@ ul, li, ol {list-style: none;}
|
||||
@media only screen and (min-width: 641px) {
|
||||
.category-content .category{background: rgba(238,238,238,.32); }
|
||||
/*楼层左侧*/
|
||||
.aggregation .word{ padding: 0.5rem 1rem; position: absolute;bottom: 0;}
|
||||
.aggregation .word{ padding: 0.5rem 1rem; position: absolute;bottom: 0; }
|
||||
}
|
||||
@ -202,12 +202,8 @@
|
||||
|
||||
.module-goods-list-base .item .goods-info {
|
||||
width: 14rem;
|
||||
border-radius: 0.4rem;
|
||||
overflow: hidden;
|
||||
display: inline-block;
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
height: 14rem;
|
||||
border-radius: var(--border-radius);
|
||||
}
|
||||
|
||||
.module-goods-list-base .item .goods-info img {
|
||||
@ -310,6 +306,7 @@
|
||||
@media only screen and (min-width: 1600px) {
|
||||
.module-goods-list-base .item .goods-info {
|
||||
width: 16rem;
|
||||
height: 16rem;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
BIN
public/static/index/default/images/empty-cart.png
Normal file
BIN
public/static/index/default/images/empty-cart.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.8 KiB |
BIN
public/static/index/default/images/preview.jpg
Executable file → Normal file
BIN
public/static/index/default/images/preview.jpg
Executable file → Normal file
Binary file not shown.
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 54 KiB |
@ -12,14 +12,18 @@ $(function()
|
||||
ids = ids.join(',');
|
||||
}
|
||||
$('form.pay-form input[name=ids]').val(ids);
|
||||
if((payment_id || null) != null && $('.payment-items-'+payment_id).length > 0)
|
||||
$('form.pay-form input[name=payment_id]').val(0);
|
||||
$('form.pay-form ul.payment-list li').each(function(k, v)
|
||||
{
|
||||
$('form.pay-form input[name=payment_id]').val(payment_id);
|
||||
$('.payment-items-'+payment_id).addClass('selected').siblings('li').removeClass('selected');
|
||||
} else {
|
||||
$('form.pay-form input[name=payment_id]').val(0);
|
||||
$('ul.payment-list li.selected').removeClass('selected');
|
||||
}
|
||||
var temp = parseInt($(this).data('value') || 0);
|
||||
if(temp == payment_id)
|
||||
{
|
||||
$(this).addClass('selected');
|
||||
$('form.pay-form input[name=payment_id]').val(payment_id);
|
||||
} else {
|
||||
$(this).removeClass('selected');
|
||||
}
|
||||
});
|
||||
}
|
||||
// 支付操作
|
||||
$(document).on('click', '.submit-pay', function()
|
||||
@ -68,7 +72,10 @@ $(function()
|
||||
// 是否自动打开支付窗口
|
||||
if($pay_popup.data('is-auto') == 1)
|
||||
{
|
||||
$pay_popup.modal();
|
||||
setTimeout(function()
|
||||
{
|
||||
$('.submit-pay').trigger('click');
|
||||
}, 100);
|
||||
}
|
||||
|
||||
// 是否自动提交支付表单
|
||||
|
||||
Reference in New Issue
Block a user