作者 郭盛
1 个管道 的构建 通过 耗费 1 秒

修改回收员已完成订单,修改家政预约地址表写错

@@ -25,11 +25,11 @@ @@ -25,11 +25,11 @@
25 </component> 25 </component>
26 <component name="FileEditorManager"> 26 <component name="FileEditorManager">
27 <leaf SIDE_TABS_SIZE_LIMIT_KEY="300"> 27 <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
28 - <file leaf-file-name="HomeController.php" pinned="false" current-in-tab="true"> 28 + <file leaf-file-name="HomeController.php" pinned="false" current-in-tab="false">
29 <entry file="file://$PROJECT_DIR$/api/index/controller/HomeController.php"> 29 <entry file="file://$PROJECT_DIR$/api/index/controller/HomeController.php">
30 <provider selected="true" editor-type-id="text-editor"> 30 <provider selected="true" editor-type-id="text-editor">
31 - <state relative-caret-position="653">  
32 - <caret line="352" column="48" lean-forward="false" selection-start-line="352" selection-start-column="48" selection-end-line="352" selection-end-column="48" /> 31 + <state relative-caret-position="635">
  32 + <caret line="218" column="35" lean-forward="false" selection-start-line="218" selection-start-column="35" selection-end-line="218" selection-end-column="35" />
33 <folding> 33 <folding>
34 <element signature="e#329#544#0#PHP" expanded="false" /> 34 <element signature="e#329#544#0#PHP" expanded="false" />
35 <element signature="e#549#890#0#PHP" expanded="false" /> 35 <element signature="e#549#890#0#PHP" expanded="false" />
@@ -43,26 +43,28 @@ @@ -43,26 +43,28 @@
43 <element signature="e#3702#4540#0#PHP" expanded="false" /> 43 <element signature="e#3702#4540#0#PHP" expanded="false" />
44 <element signature="e#4546#4859#0#PHP" expanded="false" /> 44 <element signature="e#4546#4859#0#PHP" expanded="false" />
45 <element signature="e#4864#5239#0#PHP" expanded="false" /> 45 <element signature="e#4864#5239#0#PHP" expanded="false" />
46 - <element signature="e#5245#5602#0#PHP" expanded="false" />  
47 - <element signature="e#5607#6015#0#PHP" expanded="false" />  
48 - <element signature="e#6021#6403#0#PHP" expanded="false" />  
49 - <element signature="e#6408#7078#0#PHP" expanded="false" />  
50 - <element signature="e#7084#7527#0#PHP" expanded="false" />  
51 - <element signature="e#7532#8382#0#PHP" expanded="false" />  
52 - <element signature="e#8388#8655#0#PHP" expanded="false" />  
53 - <element signature="e#8660#9135#0#PHP" expanded="false" />  
54 - <element signature="e#10660#11027#0#PHP" expanded="false" />  
55 - <element signature="e#11032#11472#0#PHP" expanded="false" /> 46 + <element signature="e#5245#5597#0#PHP" expanded="false" />
  47 + <element signature="e#5602#6010#0#PHP" expanded="false" />
  48 + <element signature="e#6016#6398#0#PHP" expanded="false" />
  49 + <element signature="e#6403#7073#0#PHP" expanded="false" />
  50 + <element signature="e#7079#7522#0#PHP" expanded="false" />
  51 + <element signature="e#7527#8377#0#PHP" expanded="false" />
  52 + <element signature="e#8383#8650#0#PHP" expanded="false" />
  53 + <element signature="e#8655#9130#0#PHP" expanded="false" />
  54 + <element signature="e#9136#9631#0#PHP" expanded="false" />
  55 + <element signature="e#9636#10649#0#PHP" expanded="false" />
  56 + <element signature="e#10655#11022#0#PHP" expanded="false" />
  57 + <element signature="e#11027#11467#0#PHP" expanded="false" />
56 </folding> 58 </folding>
57 </state> 59 </state>
58 </provider> 60 </provider>
59 </entry> 61 </entry>
60 </file> 62 </file>
61 - <file leaf-file-name="UserController.php" pinned="false" current-in-tab="false"> 63 + <file leaf-file-name="UserController.php" pinned="false" current-in-tab="true">
62 <entry file="file://$PROJECT_DIR$/api/index/controller/UserController.php"> 64 <entry file="file://$PROJECT_DIR$/api/index/controller/UserController.php">
63 <provider selected="true" editor-type-id="text-editor"> 65 <provider selected="true" editor-type-id="text-editor">
64 - <state relative-caret-position="700">  
65 - <caret line="799" column="32" lean-forward="true" selection-start-line="799" selection-start-column="32" selection-end-line="799" selection-end-column="32" /> 66 + <state relative-caret-position="328">
  67 + <caret line="823" column="27" lean-forward="false" selection-start-line="823" selection-start-column="27" selection-end-line="823" selection-end-column="27" />
66 <folding> 68 <folding>
67 <element signature="e#131#169#0#PHP" expanded="true" /> 69 <element signature="e#131#169#0#PHP" expanded="true" />
68 <element signature="e#366#715#0#PHP" expanded="false" /> 70 <element signature="e#366#715#0#PHP" expanded="false" />
@@ -101,15 +103,15 @@ @@ -101,15 +103,15 @@
101 <element signature="e#22049#23129#0#PHP" expanded="false" /> 103 <element signature="e#22049#23129#0#PHP" expanded="false" />
102 <element signature="e#23135#23559#0#PHP" expanded="false" /> 104 <element signature="e#23135#23559#0#PHP" expanded="false" />
103 <element signature="e#23564#24175#0#PHP" expanded="false" /> 105 <element signature="e#23564#24175#0#PHP" expanded="false" />
104 - <element signature="e#25235#25519#0#PHP" expanded="false" />  
105 - <element signature="e#25524#26102#0#PHP" expanded="false" />  
106 - <element signature="e#26123#26442#0#PHP" expanded="false" />  
107 - <element signature="e#26448#26856#0#PHP" expanded="false" />  
108 - <element signature="e#26862#27621#0#PHP" expanded="false" />  
109 - <element signature="e#27641#28505#0#PHP" expanded="false" />  
110 - <element signature="e#28532#28932#0#PHP" expanded="false" />  
111 - <element signature="e#28956#29529#0#PHP" expanded="false" />  
112 - <element signature="e#29552#30362#0#PHP" expanded="false" /> 106 + <element signature="e#25795#26079#0#PHP" expanded="false" />
  107 + <element signature="e#26084#26662#0#PHP" expanded="false" />
  108 + <element signature="e#26683#27002#0#PHP" expanded="false" />
  109 + <element signature="e#27008#27416#0#PHP" expanded="false" />
  110 + <element signature="e#27422#28181#0#PHP" expanded="false" />
  111 + <element signature="e#28201#29065#0#PHP" expanded="false" />
  112 + <element signature="e#29092#29492#0#PHP" expanded="false" />
  113 + <element signature="e#29516#30089#0#PHP" expanded="false" />
  114 + <element signature="e#30112#30922#0#PHP" expanded="false" />
113 </folding> 115 </folding>
114 </state> 116 </state>
115 </provider> 117 </provider>
@@ -184,8 +186,8 @@ @@ -184,8 +186,8 @@
184 <option value="$PROJECT_DIR$/public/themes/admin_simpleboot3/admin/subhome/index.html" /> 186 <option value="$PROJECT_DIR$/public/themes/admin_simpleboot3/admin/subhome/index.html" />
185 <option value="$PROJECT_DIR$/public/themes/admin_simpleboot3/admin/subhome/edit.html" /> 187 <option value="$PROJECT_DIR$/public/themes/admin_simpleboot3/admin/subhome/edit.html" />
186 <option value="$PROJECT_DIR$/app/admin/controller/SubhomeController.php" /> 188 <option value="$PROJECT_DIR$/app/admin/controller/SubhomeController.php" />
187 - <option value="$PROJECT_DIR$/api/index/controller/UserController.php" />  
188 <option value="$PROJECT_DIR$/api/index/controller/HomeController.php" /> 189 <option value="$PROJECT_DIR$/api/index/controller/HomeController.php" />
  190 + <option value="$PROJECT_DIR$/api/index/controller/UserController.php" />
189 </list> 191 </list>
190 </option> 192 </option>
191 </component> 193 </component>
@@ -203,11 +205,11 @@ @@ -203,11 +205,11 @@
203 <sorting>DEFINITION_ORDER</sorting> 205 <sorting>DEFINITION_ORDER</sorting>
204 </component> 206 </component>
205 <component name="PhpWorkspaceProjectConfiguration" backward_compatibility_performed="true" /> 207 <component name="PhpWorkspaceProjectConfiguration" backward_compatibility_performed="true" />
206 - <component name="ProjectFrameBounds" extendedState="1">  
207 - <option name="x" value="379" />  
208 - <option name="y" value="63" /> 208 + <component name="ProjectFrameBounds">
  209 + <option name="x" value="402" />
  210 + <option name="y" value="184" />
209 <option name="width" value="1582" /> 211 <option name="width" value="1582" />
210 - <option name="height" value="965" /> 212 + <option name="height" value="813" />
211 </component> 213 </component>
212 <component name="ProjectView"> 214 <component name="ProjectView">
213 <navigator currentView="ProjectPane" proportions="" version="1"> 215 <navigator currentView="ProjectPane" proportions="" version="1">
@@ -348,15 +350,15 @@ @@ -348,15 +350,15 @@
348 <workItem from="1575246616478" duration="21722000" /> 350 <workItem from="1575246616478" duration="21722000" />
349 <workItem from="1575278769037" duration="7395000" /> 351 <workItem from="1575278769037" duration="7395000" />
350 <workItem from="1575332430854" duration="21245000" /> 352 <workItem from="1575332430854" duration="21245000" />
351 - <workItem from="1575359408189" duration="7910000" /> 353 + <workItem from="1575359408189" duration="9455000" />
352 </task> 354 </task>
353 <servers /> 355 <servers />
354 </component> 356 </component>
355 <component name="TimeTrackingManager"> 357 <component name="TimeTrackingManager">
356 - <option name="totallyTimeSpent" value="439613000" /> 358 + <option name="totallyTimeSpent" value="441158000" />
357 </component> 359 </component>
358 <component name="ToolWindowManager"> 360 <component name="ToolWindowManager">
359 - <frame x="379" y="63" width="1582" height="965" extended-state="1" /> 361 + <frame x="402" y="184" width="1582" height="813" extended-state="0" />
360 <editor active="true" /> 362 <editor active="true" />
361 <layout> 363 <layout>
362 <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.1977661" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" /> 364 <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.1977661" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
@@ -854,10 +856,43 @@ @@ -854,10 +856,43 @@
854 </state> 856 </state>
855 </provider> 857 </provider>
856 </entry> 858 </entry>
  859 + <entry file="file://$PROJECT_DIR$/api/index/controller/HomeController.php">
  860 + <provider selected="true" editor-type-id="text-editor">
  861 + <state relative-caret-position="635">
  862 + <caret line="218" column="35" lean-forward="false" selection-start-line="218" selection-start-column="35" selection-end-line="218" selection-end-column="35" />
  863 + <folding>
  864 + <element signature="e#329#544#0#PHP" expanded="false" />
  865 + <element signature="e#549#890#0#PHP" expanded="false" />
  866 + <element signature="e#896#1112#0#PHP" expanded="false" />
  867 + <element signature="e#1117#1500#0#PHP" expanded="false" />
  868 + <element signature="e#1506#1726#0#PHP" expanded="false" />
  869 + <element signature="e#1731#2119#0#PHP" expanded="false" />
  870 + <element signature="e#2126#2643#0#PHP" expanded="false" />
  871 + <element signature="e#2648#3163#0#PHP" expanded="false" />
  872 + <element signature="e#3169#3697#0#PHP" expanded="false" />
  873 + <element signature="e#3702#4540#0#PHP" expanded="false" />
  874 + <element signature="e#4546#4859#0#PHP" expanded="false" />
  875 + <element signature="e#4864#5239#0#PHP" expanded="false" />
  876 + <element signature="e#5245#5597#0#PHP" expanded="false" />
  877 + <element signature="e#5602#6010#0#PHP" expanded="false" />
  878 + <element signature="e#6016#6398#0#PHP" expanded="false" />
  879 + <element signature="e#6403#7073#0#PHP" expanded="false" />
  880 + <element signature="e#7079#7522#0#PHP" expanded="false" />
  881 + <element signature="e#7527#8377#0#PHP" expanded="false" />
  882 + <element signature="e#8383#8650#0#PHP" expanded="false" />
  883 + <element signature="e#8655#9130#0#PHP" expanded="false" />
  884 + <element signature="e#9136#9631#0#PHP" expanded="false" />
  885 + <element signature="e#9636#10649#0#PHP" expanded="false" />
  886 + <element signature="e#10655#11022#0#PHP" expanded="false" />
  887 + <element signature="e#11027#11467#0#PHP" expanded="false" />
  888 + </folding>
  889 + </state>
  890 + </provider>
  891 + </entry>
857 <entry file="file://$PROJECT_DIR$/api/index/controller/UserController.php"> 892 <entry file="file://$PROJECT_DIR$/api/index/controller/UserController.php">
858 <provider selected="true" editor-type-id="text-editor"> 893 <provider selected="true" editor-type-id="text-editor">
859 - <state relative-caret-position="700">  
860 - <caret line="799" column="32" lean-forward="true" selection-start-line="799" selection-start-column="32" selection-end-line="799" selection-end-column="32" /> 894 + <state relative-caret-position="328">
  895 + <caret line="823" column="27" lean-forward="false" selection-start-line="823" selection-start-column="27" selection-end-line="823" selection-end-column="27" />
861 <folding> 896 <folding>
862 <element signature="e#131#169#0#PHP" expanded="true" /> 897 <element signature="e#131#169#0#PHP" expanded="true" />
863 <element signature="e#366#715#0#PHP" expanded="false" /> 898 <element signature="e#366#715#0#PHP" expanded="false" />
@@ -896,46 +931,15 @@ @@ -896,46 +931,15 @@
896 <element signature="e#22049#23129#0#PHP" expanded="false" /> 931 <element signature="e#22049#23129#0#PHP" expanded="false" />
897 <element signature="e#23135#23559#0#PHP" expanded="false" /> 932 <element signature="e#23135#23559#0#PHP" expanded="false" />
898 <element signature="e#23564#24175#0#PHP" expanded="false" /> 933 <element signature="e#23564#24175#0#PHP" expanded="false" />
899 - <element signature="e#25235#25519#0#PHP" expanded="false" />  
900 - <element signature="e#25524#26102#0#PHP" expanded="false" />  
901 - <element signature="e#26123#26442#0#PHP" expanded="false" />  
902 - <element signature="e#26448#26856#0#PHP" expanded="false" />  
903 - <element signature="e#26862#27621#0#PHP" expanded="false" />  
904 - <element signature="e#27641#28505#0#PHP" expanded="false" />  
905 - <element signature="e#28532#28932#0#PHP" expanded="false" />  
906 - <element signature="e#28956#29529#0#PHP" expanded="false" />  
907 - <element signature="e#29552#30362#0#PHP" expanded="false" />  
908 - </folding>  
909 - </state>  
910 - </provider>  
911 - </entry>  
912 - <entry file="file://$PROJECT_DIR$/api/index/controller/HomeController.php">  
913 - <provider selected="true" editor-type-id="text-editor">  
914 - <state relative-caret-position="653">  
915 - <caret line="352" column="48" lean-forward="false" selection-start-line="352" selection-start-column="48" selection-end-line="352" selection-end-column="48" />  
916 - <folding>  
917 - <element signature="e#329#544#0#PHP" expanded="false" />  
918 - <element signature="e#549#890#0#PHP" expanded="false" />  
919 - <element signature="e#896#1112#0#PHP" expanded="false" />  
920 - <element signature="e#1117#1500#0#PHP" expanded="false" />  
921 - <element signature="e#1506#1726#0#PHP" expanded="false" />  
922 - <element signature="e#1731#2119#0#PHP" expanded="false" />  
923 - <element signature="e#2126#2643#0#PHP" expanded="false" />  
924 - <element signature="e#2648#3163#0#PHP" expanded="false" />  
925 - <element signature="e#3169#3697#0#PHP" expanded="false" />  
926 - <element signature="e#3702#4540#0#PHP" expanded="false" />  
927 - <element signature="e#4546#4859#0#PHP" expanded="false" />  
928 - <element signature="e#4864#5239#0#PHP" expanded="false" />  
929 - <element signature="e#5245#5602#0#PHP" expanded="false" />  
930 - <element signature="e#5607#6015#0#PHP" expanded="false" />  
931 - <element signature="e#6021#6403#0#PHP" expanded="false" />  
932 - <element signature="e#6408#7078#0#PHP" expanded="false" />  
933 - <element signature="e#7084#7527#0#PHP" expanded="false" />  
934 - <element signature="e#7532#8382#0#PHP" expanded="false" />  
935 - <element signature="e#8388#8655#0#PHP" expanded="false" />  
936 - <element signature="e#8660#9135#0#PHP" expanded="false" />  
937 - <element signature="e#10660#11027#0#PHP" expanded="false" />  
938 - <element signature="e#11032#11472#0#PHP" expanded="false" /> 934 + <element signature="e#25795#26079#0#PHP" expanded="false" />
  935 + <element signature="e#26084#26662#0#PHP" expanded="false" />
  936 + <element signature="e#26683#27002#0#PHP" expanded="false" />
  937 + <element signature="e#27008#27416#0#PHP" expanded="false" />
  938 + <element signature="e#27422#28181#0#PHP" expanded="false" />
  939 + <element signature="e#28201#29065#0#PHP" expanded="false" />
  940 + <element signature="e#29092#29492#0#PHP" expanded="false" />
  941 + <element signature="e#29516#30089#0#PHP" expanded="false" />
  942 + <element signature="e#30112#30922#0#PHP" expanded="false" />
939 </folding> 943 </folding>
940 </state> 944 </state>
941 </provider> 945 </provider>
@@ -204,7 +204,7 @@ class HomeController extends RestBaseController @@ -204,7 +204,7 @@ class HomeController extends RestBaseController
204 * @title 预约家政服务地址详情 204 * @title 预约家政服务地址详情
205 * @description 205 * @description
206 * @author GuoSheng 206 * @author GuoSheng
207 - * @url /index/Shopgoods/recycleDetail 207 + * @url /index/Home/recycleDetail
208 * @method GET 208 * @method GET
209 * 209 *
210 * @header name:XX-Token require:1 default: desc:token 210 * @header name:XX-Token require:1 default: desc:token
@@ -789,6 +789,7 @@ class UserController extends RestBaseController @@ -789,6 +789,7 @@ class UserController extends RestBaseController
789 * @header name:XX-Token require:1 default: desc:token 789 * @header name:XX-Token require:1 default: desc:token
790 * 790 *
791 * @param name:order_id type:int require:1 other: desc:订单ID 791 * @param name:order_id type:int require:1 other: desc:订单ID
  792 + * @param name:get_integral type:int require:1 other: desc:获得积分
792 * 793 *
793 * @return id:订单ID 794 * @return id:订单ID
794 * @return num:订单号 795 * @return num:订单号
@@ -801,15 +802,26 @@ class UserController extends RestBaseController @@ -801,15 +802,26 @@ class UserController extends RestBaseController
801 { 802 {
802 $user_id = $this->getUserId(); 803 $user_id = $this->getUserId();
803 $order_id = $this->request->param('order_id'); 804 $order_id = $this->request->param('order_id');
  805 + $get_integral = $this->request->param('get_integral');
804 if(empty($order_id)){ 806 if(empty($order_id)){
805 $this->error('缺少必要参数'); 807 $this->error('缺少必要参数');
806 } 808 }
807 $data['order_id'] = $order_id; 809 $data['order_id'] = $order_id;
808 $data['user_id'] = $user_id; 810 $data['user_id'] = $user_id;
809 $data['create_time'] = time(); 811 $data['create_time'] = time();
  812 + $data['status'] = 2;
810 Db::name('subscribe') 813 Db::name('subscribe')
811 ->where('id',$order_id) 814 ->where('id',$order_id)
812 - ->update(['status'=>1]); 815 + ->update(['status'=>2,'get_integral'=>$get_integral]);
  816 + $info = Db::name('integral')
  817 + ->where('user_id',$user_id)
  818 + ->find();
  819 + $res['num'] = $info['num'] + 1;
  820 + $res['add_total'] = $info['add_total'] + $get_integral;
  821 + $res['now_integral'] = $info['now_integral'] + $get_integral;
  822 + Db::name('integral')
  823 + ->where('user_id',$user_id)
  824 + ->update($res);
813 $res = Db::name('collector') 825 $res = Db::name('collector')
814 ->insertGetId($data); 826 ->insertGetId($data);
815 if($res){ 827 if($res){