Browse Source

加退补备注

sunhao 5 years ago
parent
commit
28106a9d5c

+ 2 - 0
app/Http/Controllers/Admin/OrderController.php

@@ -809,6 +809,7 @@ class OrderController extends Controller
809 809
         $cost = $request->input('cost');
810 810
         $freight_cost = $request->input('freight_cost');
811 811
         $send_note = trim($request->input('send_note'));
812
+        $refund_note = trim($request->input('refund_note'));
812 813
         $buyerMemo = $request->input('buyerMemo');
813 814
         $sellerMemo = $request->input('sellerMemo');
814 815
 
@@ -825,6 +826,7 @@ class OrderController extends Controller
825 826
         if(isset($buyerMemo)) $data['buyerMemo'] = $buyerMemo;
826 827
         if(isset($sellerMemo)) $data['sellerMemo'] = $sellerMemo;
827 828
         if(isset($send_note)) $data['send_note'] = $send_note;
829
+        if(isset($refund_note)) $data['refund_note'] = $refund_note;
828 830
         if($id>0 && !empty($data)){
829 831
             $res = Order::where('id', $id)->update($data);
830 832
         }

+ 7 - 4
resources/views/order/orderlist.blade.php

@@ -60,13 +60,15 @@
60 60
                     <th width="4%">加粉时间</th>                   
61 61
                     <th width="2%">是否复购</th>                  
62 62
                     <th width="2%">是否退补单</th>                                                       
63
-                    <th width="4%">应该退补差价</th>                  
63
+                    <th width="4%">应该退补差价</th> 
64
+                    <th width="5%">退补备注</th>                 
64 65
                     <th width="4%">所属销售</th> 
65 66
                     <th width="4%">订单状态</th>                  
66 67
                     @if($self_role =='销售' )<th width="5%">驳回原因</th>@endif                  
67 68
                     <th width="3%">是否退款</th>                  
68
-                    <th width="6%">买家备注</th>                  
69
-                    <th width="6%">卖家备注</th>                  
69
+                    <th width="5%">买家备注</th>                  
70
+                    <th width="5%">卖家备注</th>                                                        
71
+                    <th width="5%">发货备注</th>                                                        
70 72
                     <th width="5%">操作</th>                 
71 73
                 </tr>
72 74
                 </thead>
@@ -105,6 +107,7 @@
105 107
                             <td>@if($a['is_fugou']==1) 是 @else 否 @endif</td>
106 108
                             <td>@if($a['is_refund']==1) 是 @else 否 @endif</td>
107 109
                             <td>{{$a['refund_price']}}</td>
110
+                            <td>{{$a['refund_note']}}</td>
108 111
                             <td>{{$a['admin_name']}}</td>
109 112
                             <td id="order_verify{{$a['id']}}">{{$a['status_name']}}</td>
110 113
                             @if($self_role =='销售' ) <td>@if($a['status'] == 0)<font color='red'> {{$a['refuse_reason']}} </font> @endif</td> @endif
@@ -120,7 +123,7 @@
120 123
                                 <input id="sellerMemo_2{{$a['id']}}" style="display: none" type='text' name='sellerMemo' value="{{$a['sellerMemo']}}" onblur="change_sellerMemo({{$a['id']}})" />
121 124
                                 <span class="sort_icon" hidden  onClick='change_sellerMemo_click("{{$a['id']}}","{{$a['cost']}}")' style="cursor:pointer"><i class="Hui-iconfont">&#xe647;</i></span>
122 125
                             </td> 
123
-                                                                                                                                   
126
+                            <td>{{$a['send_note']}}</td>                                                                                                  
124 127
                             <td>
125 128
                                 @if($a['enable_status'])
126 129
                                     @foreach($a['enable_status'] as $item)

+ 26 - 0
resources/views/order/warehouselist.blade.php

@@ -47,6 +47,7 @@
47 47
                     <th width="5%">货品成本</th>                  
48 48
                     <th width="5%">运费成本</th>                  
49 49
                     <th width="5%">发货备注</th>                  
50
+                    <th width="5%">退补备注</th>                  
50 51
                     <th width="6%">创建时间</th>                   
51 52
                    
52 53
                 </tr>
@@ -81,6 +82,11 @@
81 82
                                 <p id="send_note_1{{$a['id']}}">{{$a['send_note']}}</p> 
82 83
                                 <textarea id="send_note_2{{$a['id']}}" rows=4 style="display: none"  name='send_note' onblur="change_send_note({{$a['id']}})" >{{$a['send_note']}}</textarea>
83 84
                                 <span class="sort_icon" hidden  onClick='change_send_note_click("{{$a['id']}}","{{$a['send_note']}}")' style="cursor:pointer"><i class="Hui-iconfont">&#xe647;</i></span>
85
+                            </td> 
86
+                            <td class ="change_logistics_id"> 
87
+                                <p id="refund_note_1{{$a['id']}}">{{$a['refund_note']}}</p> 
88
+                                <textarea id="refund_note_2{{$a['id']}}" rows=4 style="display: none"  name='refund_note' onblur="change_refund_note({{$a['id']}})" >{{$a['refund_note']}}</textarea>
89
+                                <span class="sort_icon" hidden  onClick='change_refund_note_click("{{$a['id']}}","{{$a['refund_note']}}")' style="cursor:pointer"><i class="Hui-iconfont">&#xe647;</i></span>
84 90
                             </td>                                                         
85 91
                             <td>{{$a['createTime']}}</td>                                                                                                          
86 92
                                                                                                                                                                  
@@ -257,6 +263,26 @@
257 263
             });
258 264
         }
259 265
 
266
+        function change_refund_note_click(id, refund_note){
267
+            $("#refund_note_1"+id).hide();
268
+            $("#refund_note_2"+id).show();
269
+            $("#refund_note_2"+id).focus();
270
+        }
271
+
272
+        function change_refund_note(id){
273
+            var refund_note = $("#refund_note_2"+id).val();
274
+            $.ajax({
275
+                url: '/admin/order/editLogisticsId?id='+id+'&refund_note='+refund_note,
276
+                type: 'get',
277
+                dateType: 'json',
278
+                success:function(msg){
279
+                    $("#refund_note_1"+id).html(refund_note);
280
+                    $("#refund_note_1"+id).show();
281
+                    $("#refund_note_2"+id).hide();
282
+                }
283
+            });
284
+        }
285
+
260 286
         //批量导入
261 287
         function importExcel(){
262 288
             $("#modal-demo1").modal("show");