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

修改订单

... ... @@ -2,7 +2,6 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="e93f11c2-a7d9-4d35-8b1c-8dd18e7f5fef" name="Default" comment="">
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/application/api/controller/Pay.php" afterPath="$PROJECT_DIR$/application/api/controller/Pay.php" />
</list>
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
... ... @@ -90,8 +89,8 @@
<file leaf-file-name="Pay.php" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/application/api/controller/Pay.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="194">
<caret line="789" column="26" lean-forward="true" selection-start-line="789" selection-start-column="26" selection-end-line="789" selection-end-column="26" />
<state relative-caret-position="-106">
<caret line="786" column="40" lean-forward="true" selection-start-line="786" selection-start-column="40" selection-end-line="786" selection-end-column="40" />
<folding>
<element signature="e#574#693#0#PHP" expanded="false" />
<element signature="e#699#1012#0#PHP" expanded="false" />
... ... @@ -99,11 +98,11 @@
<element signature="e#3099#3419#0#PHP" expanded="false" />
<element signature="e#3424#5506#0#PHP" expanded="false" />
<element signature="e#5512#5930#0#PHP" expanded="false" />
<element signature="e#5935#16029#0#PHP" expanded="false" />
<element signature="e#6179#6269#0#PHP" expanded="false" />
<element signature="e#6347#6443#0#PHP" expanded="false" />
<element signature="e#11546#11997#0#PHP" expanded="false" />
<element signature="e#13212#13330#0#PHP" expanded="false" />
<element signature="e#14187#15962#0#PHP" expanded="false" />
<element signature="e#16035#16455#0#PHP" expanded="false" />
<element signature="e#16460#26484#0#PHP" expanded="false" />
<element signature="e#18227#19634#0#PHP" expanded="false" />
... ... @@ -114,16 +113,26 @@
<element signature="e#26803#27196#0#PHP" expanded="false" />
<element signature="e#27223#30701#0#PHP" expanded="false" />
<element signature="e#30730#33635#0#PHP" expanded="false" />
<element signature="e#34478#35794#0#PHP" expanded="false" />
<element signature="e#35815#39319#0#PHP" expanded="false" />
<element signature="e#37893#38280#0#PHP" expanded="false" />
<element signature="e#38341#39297#0#PHP" expanded="false" />
<element signature="e#39958#47130#0#PHP" expanded="false" />
<element signature="e#34441#35758#0#PHP" expanded="false" />
<element signature="e#35804#39309#0#PHP" expanded="false" />
<element signature="e#37883#38270#0#PHP" expanded="false" />
<element signature="e#38331#39287#0#PHP" expanded="false" />
<element signature="e#39948#47120#0#PHP" expanded="false" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="verify.php" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/application/extra/verify.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="375">
<caret line="18" column="45" lean-forward="false" selection-start-line="18" selection-start-column="45" selection-end-line="18" selection-end-column="45" />
<folding />
</state>
</provider>
</entry>
</file>
</leaf>
</component>
<component name="FindInProjectRecents">
... ... @@ -211,9 +220,9 @@
<sorting>DEFINITION_ORDER</sorting>
</component>
<component name="PhpWorkspaceProjectConfiguration" backward_compatibility_performed="true" />
<component name="ProjectFrameBounds" extendedState="1">
<option name="x" value="2" />
<option name="y" value="11" />
<component name="ProjectFrameBounds" extendedState="7">
<option name="x" value="96" />
<option name="y" value="92" />
<option name="width" value="1871" />
<option name="height" value="996" />
</component>
... ... @@ -263,8 +272,7 @@
<item name="areial" type="b2602c69:ProjectViewProjectNode" />
<item name="areial" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="application" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="api" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="lang" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="extra" type="2a2b976b:PhpTreeStructureProvider$1" />
</path>
<path>
<item name="areial" type="b2602c69:ProjectViewProjectNode" />
... ... @@ -370,7 +378,7 @@
<workItem from="1575599624364" duration="95000" />
<workItem from="1575680867057" duration="23412000" />
<workItem from="1575708184460" duration="1768000" />
<workItem from="1575771325770" duration="637000" />
<workItem from="1575771325770" duration="1401000" />
</task>
<task id="LOCAL-00001" summary="调试">
<created>1574145133364</created>
... ... @@ -383,7 +391,7 @@
<servers />
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="335716000" />
<option name="totallyTimeSpent" value="336480000" />
</component>
<component name="TodoView">
<todo-panel id="selected-file">
... ... @@ -395,17 +403,16 @@
</todo-panel>
</component>
<component name="ToolWindowManager">
<frame x="2" y="11" width="1871" height="996" extended-state="1" />
<editor active="true" />
<frame x="-8" y="-8" width="1936" height="1056" extended-state="7" />
<layout>
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.17393705" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.16791044" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32912987" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.15813954" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.1577802" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
... ... @@ -448,7 +455,7 @@
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
<option name="time" value="18" />
<option name="time" value="19" />
</breakpoint-manager>
<watches-manager />
</component>
... ... @@ -510,13 +517,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/extra/verify.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="450">
<caret line="18" column="45" lean-forward="false" selection-start-line="18" selection-start-column="45" selection-end-line="18" selection-end-column="45" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/library/traits/Backend.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="225">
... ... @@ -862,10 +862,18 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/extra/verify.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="375">
<caret line="18" column="45" lean-forward="false" selection-start-line="18" selection-start-column="45" selection-end-line="18" selection-end-column="45" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Pay.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="194">
<caret line="789" column="26" lean-forward="true" selection-start-line="789" selection-start-column="26" selection-end-line="789" selection-end-column="26" />
<state relative-caret-position="-106">
<caret line="786" column="40" lean-forward="true" selection-start-line="786" selection-start-column="40" selection-end-line="786" selection-end-column="40" />
<folding>
<element signature="e#574#693#0#PHP" expanded="false" />
<element signature="e#699#1012#0#PHP" expanded="false" />
... ... @@ -873,11 +881,11 @@
<element signature="e#3099#3419#0#PHP" expanded="false" />
<element signature="e#3424#5506#0#PHP" expanded="false" />
<element signature="e#5512#5930#0#PHP" expanded="false" />
<element signature="e#5935#16029#0#PHP" expanded="false" />
<element signature="e#6179#6269#0#PHP" expanded="false" />
<element signature="e#6347#6443#0#PHP" expanded="false" />
<element signature="e#11546#11997#0#PHP" expanded="false" />
<element signature="e#13212#13330#0#PHP" expanded="false" />
<element signature="e#14187#15962#0#PHP" expanded="false" />
<element signature="e#16035#16455#0#PHP" expanded="false" />
<element signature="e#16460#26484#0#PHP" expanded="false" />
<element signature="e#18227#19634#0#PHP" expanded="false" />
... ... @@ -888,11 +896,11 @@
<element signature="e#26803#27196#0#PHP" expanded="false" />
<element signature="e#27223#30701#0#PHP" expanded="false" />
<element signature="e#30730#33635#0#PHP" expanded="false" />
<element signature="e#34478#35794#0#PHP" expanded="false" />
<element signature="e#35815#39319#0#PHP" expanded="false" />
<element signature="e#37893#38280#0#PHP" expanded="false" />
<element signature="e#38341#39297#0#PHP" expanded="false" />
<element signature="e#39958#47130#0#PHP" expanded="false" />
<element signature="e#34441#35758#0#PHP" expanded="false" />
<element signature="e#35804#39309#0#PHP" expanded="false" />
<element signature="e#37883#38270#0#PHP" expanded="false" />
<element signature="e#38331#39287#0#PHP" expanded="false" />
<element signature="e#39948#47120#0#PHP" expanded="false" />
</folding>
</state>
</provider>
... ...
... ... @@ -690,19 +690,22 @@ class Pay extends Api
public function picOrderNotify(){
$config = config('verify.wx_pay');
$app = Factory::payment($config);
$response = $app->handlePaidNotify(function($message, $fail){
//找到该订单信息
$data = Db::name('order')->where('id',$message['out_trade_no'])->find();
$pic_id = explode(',',$data['pic_id']);
$video_id = unserialize($data['video_id']);
//查询该用户信息以及是否为会员身份
$user = Db::name('user')->where('id',$data['user_id'])->find();
$mobile = $user['mobile'];
$str = "【仁甲看见】";
//return_code 表示通信状态
if ($message['return_code'] === 'SUCCESS') {
if ($message['result_code'] === 'SUCCESS') {
//找到该订单信息
$data = Db::name('order')->where('id',$message['out_trade_no'])->find();
$pic_id = explode(',',$data['pic_id']);
$video_id = unserialize($data['video_id']);
//查询该用户信息以及是否为会员身份
$user = Db::name('user')->where('id',$data['user_id'])->find();
$mobile = $user['mobile'];
$str = "【仁甲看见】";
if(empty($pic_id)){
//图片
if(!empty($pic_id)){
//将购买次数加1
foreach ($pic_id as $key => $v){
//非会员
... ... @@ -723,7 +726,8 @@ class Pay extends Api
$str .= "图片标题:$pic[title],云盘地址:$pic[url],提取码:$pic[code],";
}
}
if(empty($video_id)){
//视频
if(!empty($video_id)){
//判断是否为会员
if($user['is_vip'] == 0){
//不是会员的情况
... ...
... ... @@ -6612,7 +6612,7 @@
<div class="row mt0 footer">
<div class="col-md-6" align="left">
Generated on 2019-12-07 17:02:33 </div>
Generated on 2019-12-08 10:38:45 </div>
<div class="col-md-6" align="right">
<a href="https://www.fastadmin.net" target="_blank">FastAdmin</a>
</div>
... ...