Browse Source

订单调整,换支付账号等

lizhen_gitee 6 months ago
parent
commit
121e10ad11

+ 1 - 1
addons/epay/config.php

@@ -23,7 +23,7 @@ return [
             'app_id' => '',
             'app_secret' => '',
             'miniapp_id' => 'wx1ed359bf9ef1525f',
-            'mch_id' => '',
+            'mch_id' => '1691702429',
             'key' => 'X1qt6aYRSLkcvwUmWLJZI4itVcIPvLQn',
             'key_v3' => '',
             'mode' => 'normal',

+ 2 - 2
addons/unishop/controller/Order.php

@@ -416,7 +416,7 @@ class Order extends Base
         if ($order['status'] == \addons\unishop\model\Order::STATUS_NORMAL && $order['have_received'] == \addons\unishop\model\Order::RECEIVED_NO) {
 
             $refund_amount = $order['total_price'];
-            $refund_status = 3;
+            $refund_status = 3; //申请售后状态 0=无,1=申请中,2=通过(让用户发货),3=通过,4=拒绝
 
             // 退款
             $params = [
@@ -459,7 +459,7 @@ class Order extends Base
     // 退款
     public function old_refund($order, $refund_price)
     {
-        return true;
+        /*return true;*/
         $table = 'unishop_order';
         $remark = '订单退款';
 

+ 1 - 1
application/admin/model/unishop/Order.php

@@ -41,7 +41,7 @@ class Order extends Model
 
     public function getStatusList()
     {
-        return ['-1' => __('Refund'), '0' => __('Cancel'), '1' => __('Normal')];
+        return [/*'-1' => __('Refund'),*/ '0' => __('Cancel'), '1' => __('Normal')];
     }
 
     public function getRefundStatusList()

+ 1 - 20
application/admin/view/unishop/dashboard/index.html

@@ -19,7 +19,6 @@
         {:build_heading(null, false)}
         <ul class="nav nav-tabs">
             <li class="active"><a href="#one" data-toggle="tab">{:__('Dashboard')}</a></li>
-            <li><a href="#two" data-toggle="tab">{:__('Custom')}</a></li>
         </ul>
     </div>
     <div class="panel-body">
@@ -128,25 +127,7 @@
                         </div>
                     </div>
 
-                    <div class="col-xs-6 col-md-2">
-                        <div class="panel bg-yellow-gradient no-border">
-                            <div class="panel-body">
-                                <div class="panel-title">
-                                    <h5>{:__('Ads count')}</h5>
-                                </div>
-                                <div class="panel-content">
-                                    <div class="row">
-                                        <div class="col-md-12">
-                                            <h1 class="no-margins">{$totalAds}</h1>
-                                            <div class="font-bold"><i class="fa fa-buysellads"></i>
-                                                <small>{:__('Ads count tips')}</small>
-                                            </div>
-                                        </div>
-                                    </div>
-                                </div>
-                            </div>
-                        </div>
-                    </div>
+
                 </div>
 
                 <!-- 商品销量。每天,每月,每年,能导出 -->

+ 18 - 18
application/admin/view/unishop/order/edit.html

@@ -5,40 +5,40 @@
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="username" class="form-control selectpage" name="row[user_id]" type="text" value="{$row.user_id}">
+            <input id="c-user_id" disabled data-rule="required" data-source="user/user/index" data-field="username" class="form-control selectpage" name="row[user_id]" type="text" value="{$row.user_id}">
         </div>
     </div>
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Out_trade_no')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-out_trade_no" class="form-control" name="row[out_trade_no]" type="text" value="{$row.out_trade_no}">
+            <input id="c-out_trade_no" disabled class="form-control" name="row[out_trade_no]" type="text" value="{$row.out_trade_no}">
         </div>
     </div>
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Order_price')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-order_price" class="form-control" step="0.01" name="row[order_price]" type="number" value="{$row.order_price}">
+            <input id="c-order_price" disabled class="form-control" step="0.01" name="row[order_price]" type="number" value="{$row.order_price}">
         </div>
     </div>
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Discount_price')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-discount_price" class="form-control" step="0.01" name="row[discount_price]" type="number" value="{$row.discount_price}">
+            <input id="c-discount_price" disabled class="form-control" step="0.01" name="row[discount_price]" type="number" value="{$row.discount_price}">
         </div>
     </div>
-    <div class="form-group">
+    <!--<div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Delivery_price')}:</label>
         <div class="col-xs-12 col-sm-8">
             <input id="c-delivery_price" class="form-control" step="0.01" name="row[delivery_price]" type="number" value="{$row.delivery_price}">
         </div>
-    </div>
+    </div>-->
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Total_price')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-total_price" class="form-control" step="0.01" name="row[total_price]" type="number" value="{$row.total_price}">
+            <input id="c-total_price" disabled class="form-control" step="0.01" name="row[total_price]" type="number" value="{$row.total_price}">
         </div>
     </div>
-    <div class="form-group">
+    <!--<div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Pay_type')}:</label>
         <div class="col-xs-12 col-sm-8">
 
@@ -49,13 +49,13 @@
             </select>
 
         </div>
-    </div>
-    <div class="form-group">
+    </div>-->
+    <!--<div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Ip')}:</label>
         <div class="col-xs-12 col-sm-8">
             <input id="c-ip" class="form-control" name="row[ip]" type="text" value="{$row.ip}">
         </div>
-    </div>
+    </div>-->
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Remark')}:</label>
         <div class="col-xs-12 col-sm-8">
@@ -68,7 +68,7 @@
 
             <div class="radio">
             {foreach name="statusList" item="vo"}
-            <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="row[status]" type="radio" value="{$key}" {in name="key" value="$row.status"}checked{/in} /> {$vo}</label>
+            <label for="row[status]-{$key}"><input id="row[status]-{$key}" disabled name="row[status]" type="radio" value="{$key}" {in name="key" value="$row.status"}checked{/in} /> {$vo}</label>
             {/foreach}
             </div>
 
@@ -81,7 +81,7 @@
 
             <div class="radio">
                 {foreach name="refundStatusList" item="vo"}
-                <label for="row[refund_status]-{$key}"><input id="row[refund_status]-{$key}" name="row[refund_status]" type="radio" value="{$key}" {in name="key" value="$row.refund_status"}checked{/in} /> {$vo}</label>
+                <label for="row[refund_status]-{$key}"><input id="row[refund_status]-{$key}" disabled name="row[refund_status]" type="radio" value="{$key}" {in name="key" value="$row.refund_status"}checked{/in} /> {$vo}</label>
                 {/foreach}
             </div>
 
@@ -91,13 +91,13 @@
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Pay time')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-have_paid" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_paid]" type="text" value="{:$row.have_paid?datetime($row.have_paid):''}">
+            <input id="c-have_paid" disabled class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_paid]" type="text" value="{:$row.have_paid?datetime($row.have_paid):''}">
         </div>
     </div>
-    <div class="form-group">
+    <!--<div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Delivered time')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-have_delivered" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_delivered]" type="text" value="{:$row.have_delivered?datetime($row.have_delivered):''}">
+            <input id="c-have_delivered" disabled class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_delivered]" type="text" value="{:$row.have_delivered?datetime($row.have_delivered):''}">
         </div>
     </div>
     <div class="form-group">
@@ -105,11 +105,11 @@
         <div class="col-xs-12 col-sm-8">
             <input id="c-have_commented" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_commented]" type="text" value="{:$row.have_commented?datetime($row.have_commented):''}">
         </div>
-    </div>
+    </div>-->
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Received time')}:</label>
         <div class="col-xs-12 col-sm-8">
-            <input id="c-have_received" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_received]" type="text" value="{:$row.have_received?datetime($row.have_received):''}">
+            <input id="c-have_received" disabled class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[have_received]" type="text" value="{:$row.have_received?datetime($row.have_received):''}">
         </div>
     </div>
     <div class="form-group layer-footer">

+ 4 - 4
application/admin/view/unishop/order/index.html

@@ -18,17 +18,17 @@
                     <div id="toolbar" class="toolbar">
                         <a href="javascript:;" class="btn btn-primary btn-refresh" title="{:__('Refresh')}" ><i class="fa fa-refresh"></i> </a>
 <!--                        <a href="javascript:;" class="btn btn-success btn-add {:$auth->check('unishop/order/add')?'':'hide'}" title="{:__('Add')}" ><i class="fa fa-plus"></i> {:__('Add')}</a>-->
-                        <a href="javascript:;" class="btn btn-success btn-edit btn-disabled disabled {:$auth->check('unishop/order/edit')?'':'hide'}" title="{:__('Edit')}" ><i class="fa fa-pencil"></i> {:__('Edit')}</a>
-                        <a href="javascript:;" class="btn btn-danger btn-del btn-disabled disabled {:$auth->check('unishop/order/del')?'':'hide'}" title="{:__('Delete')}" ><i class="fa fa-trash"></i> {:__('Delete')}</a>
+                        <!--<a href="javascript:;" class="btn btn-success btn-edit btn-disabled disabled {:$auth->check('unishop/order/edit')?'':'hide'}" title="{:__('Edit')}" ><i class="fa fa-pencil"></i> {:__('Edit')}</a>-->
+                        <!--<a href="javascript:;" class="btn btn-danger btn-del btn-disabled disabled {:$auth->check('unishop/order/del')?'':'hide'}" title="{:__('Delete')}" ><i class="fa fa-trash"></i> {:__('Delete')}</a>-->
 <!--                        <a href="javascript:;" class="btn btn-danger btn-import {:$auth->check('unishop/order/import')?'':'hide'}" title="{:__('Import')}" id="btn-import-file" data-url="ajax/upload" data-mimetype="csv,xls,xlsx" data-multiple="false"><i class="fa fa-upload"></i> {:__('Import')}</a>-->
 
-                        <div class="dropdown btn-group {:$auth->check('unishop/order/multi')?'':'hide'}">
+                       <!-- <div class="dropdown btn-group {:$auth->check('unishop/order/multi')?'':'hide'}">
                             <a class="btn btn-primary btn-more dropdown-toggle btn-disabled disabled" data-toggle="dropdown"><i class="fa fa-cog"></i> {:__('More')}</a>
                             <ul class="dropdown-menu text-left" role="menu">
                                 <li><a class="btn btn-link btn-multi btn-disabled disabled" href="javascript:;" data-params="status=normal"><i class="fa fa-eye"></i> {:__('Set to normal')}</a></li>
                                 <li><a class="btn btn-link btn-multi btn-disabled disabled" href="javascript:;" data-params="status=hidden"><i class="fa fa-eye-slash"></i> {:__('Set to hidden')}</a></li>
                             </ul>
-                        </div>
+                        </div>-->
 
                         <a class="btn btn-success btn-recyclebin btn-dialog {:$auth->check('unishop/order/recyclebin')?'':'hide'}" href="unishop/order/recyclebin" title="{:__('Recycle bin')}"><i class="fa fa-recycle"></i> {:__('Recycle bin')}</a>
                     </div>

+ 2 - 14
application/admin/view/unishop/order/product.html

@@ -5,7 +5,7 @@
             订单金额:¥{$order.order_price}
         </li>
         <li class="list-group-item">
-            实付金额:¥{$order.total_price}元 (包含优惠¥{$order.discount_price},物流费用¥{$order.delivery_price})
+            实付金额:¥{$order.total_price}元 (包含优惠¥{$order.discount_price})
         </li>
     </ul>
 
@@ -37,19 +37,7 @@
             <div>{$item.number} ✖ {$item.price}</div>
             <div class="total-price">总共:{$item.price * $item.number} 元</div>
         </div>
-        {if empty($evaluate[$item.product_id])}
-        <div class="media-body">
-            <h4 class="media-heading">未评价</h4>
-        </div>
-        {else/}
-        <div class="media-body">
-            <h4 class="media-heading">评价:{$evaluate[$item.product_id]['rate']} 星</h4>
-            <div>评价内容: {$evaluate[$item.product_id]['comment']}</div>
-            <div>评价时间: {:date('Y-m-d H:i:s',$evaluate[$item.product_id]['createtime'])}</div>
-            <div>匿名: {$evaluate[$item.product_id]['anonymous'] ? '是' : '否'}</div>
-            <div>置顶: {$evaluate[$item.product_id]['toptime'] ? '是' : '否'}</div>
-        </div>
-        {/if}
+
     </div>
     {/foreach}
 

+ 6 - 6
application/config.php

@@ -326,10 +326,10 @@ return [
         'client_secret' => '',
     ],
 
-    //微信小程序 鲁享途中
+    //微信小程序 客户正式
     'wxMiniProgram' => [
-        'appid'  => 'wx9a7153e5b40d9663',
-        'secret' => '8a743955faa5873af394f31d4a58c086',
+        'appid'  => 'wx1ed359bf9ef1525f',
+        'secret' => '8aca1d002675d343889602630c2fdcc4',
     ],
 
     //腾讯云 IM
@@ -375,10 +375,10 @@ return [
 
     //微信支付退款用,和epay保持一直, 健康E家的配置
     'wechatpay' => [
-        'app_id' => 'wxbe5585d53a9b5062',  //小程序appid
+        'app_id' => 'wx1ed359bf9ef1525f',  //小程序appid
         //'app_app_id' => 'wx6844c1575498710e',  //APP appid ,暂时用不到
-        'mch_id' => '1636573418',
-        'key'    => '0Ed5rUZWDF80Bt2gzneL6lVq7wf6Sl8l',//v2密钥
+        'mch_id' => '1691702429',
+        'key'    => 'X1qt6aYRSLkcvwUmWLJZI4itVcIPvLQn',//v2密钥
         'refund_notify' => '',
     ],
 

+ 1 - 1
public/assets/js/backend/unishop/order.js

@@ -95,7 +95,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                         {field: 'discount_price', title: __('Discount_price'), operate:'BETWEEN'},
 //                        {field: 'delivery_price', title: __('Delivery_price'), operate:'BETWEEN'},
                         {field: 'total_price', title: __('Total_price'), operate:'BETWEEN'},
-                        {field: 'status', title: __('Status'), searchList: {"-1":__('Refund'),"0":__('Cancel'),"1":__('Normal')}, formatter: Table.api.formatter.status},
+                        {field: 'status', title: __('Status'), searchList: {/*"-1":__('Refund'),*/"0":__('Cancel'),"1":__('Normal')}, formatter: Table.api.formatter.status},
 //                        {field: 'pay_type', title: __('Pay_type'), searchList: {"1":__('Online'),"2":__('Offline'),"3":__('wxPay'),"4":__('aliPay')}, formatter: Table.api.formatter.normal},
 //                        {field: 'ip', title: __('Ip'), visible:false},
                         {field: 'have_paid_status', title: __('Have_paid'), searchList: {"0":__('No'),"1":__('Yes')}, formatter: Table.api.formatter.statusCustom},