Commit dfc12df6 by 张恒

j

parent 50eb0865
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="83262c17-7030-4f8f-af17-e1cc55f76944" name="Default" comment=""> <list default="true" id="83262c17-7030-4f8f-af17-e1cc55f76944" 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/Home/Controller/IndexController.class.php" afterPath="$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php" afterPath="$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php" />
</list> </list>
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
...@@ -55,8 +56,8 @@ ...@@ -55,8 +56,8 @@
<file leaf-file-name="IndexController.class.php" pinned="false" current-in-tab="true"> <file leaf-file-name="IndexController.class.php" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php"> <entry file="file://$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="76"> <state relative-caret-position="323">
<caret line="138" column="9" lean-forward="true" selection-start-line="138" selection-start-column="9" selection-end-line="138" selection-end-column="9" /> <caret line="66" column="25" lean-forward="true" selection-start-line="66" selection-start-column="25" selection-end-line="66" selection-end-column="25" />
<folding> <folding>
<element signature="e#34#44#0#PHP" expanded="true" /> <element signature="e#34#44#0#PHP" expanded="true" />
</folding> </folding>
...@@ -81,8 +82,8 @@ ...@@ -81,8 +82,8 @@
<file leaf-file-name="main.scss" pinned="false" current-in-tab="true"> <file leaf-file-name="main.scss" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/Public/static/css/main.scss"> <entry file="file://$PROJECT_DIR$/Public/static/css/main.scss">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="425"> <state relative-caret-position="292">
<caret line="182" column="1" lean-forward="true" selection-start-line="182" selection-start-column="1" selection-end-line="182" selection-end-column="1" /> <caret line="175" column="16" lean-forward="true" selection-start-line="175" selection-start-column="16" selection-end-line="175" selection-end-column="16" />
<folding /> <folding />
</state> </state>
</provider> </provider>
...@@ -454,16 +455,16 @@ ...@@ -454,16 +455,16 @@
<option name="presentableId" value="Default" /> <option name="presentableId" value="Default" />
<updated>1562502557206</updated> <updated>1562502557206</updated>
<workItem from="1562502558877" duration="2926000" /> <workItem from="1562502558877" duration="2926000" />
<workItem from="1562505554364" duration="1589000" /> <workItem from="1562505554364" duration="1857000" />
</task> </task>
<servers /> <servers />
</component> </component>
<component name="TimeTrackingManager"> <component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="4515000" /> <option name="totallyTimeSpent" value="4783000" />
</component> </component>
<component name="ToolWindowManager"> <component name="ToolWindowManager">
<frame x="0" y="23" width="1440" height="821" extended-state="6" /> <frame x="0" y="23" width="1440" height="821" extended-state="6" />
<editor active="true" /> <editor active="false" />
<layout> <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.1881259" sideWeight="0.5" order="0" 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.1881259" sideWeight="0.5" order="0" 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.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="TODO" 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="6" side_tool="false" content_ui="tabs" />
...@@ -472,7 +473,7 @@ ...@@ -472,7 +473,7 @@
<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="8" 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="8" 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.32921812" sideWeight="0.5" order="2" 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.32921812" sideWeight="0.5" order="2" 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="1" 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="1" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.23045267" sideWeight="0.5" order="9" 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.23045267" sideWeight="0.5" order="9" 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="4" side_tool="true" 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="4" 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="3" side_tool="false" 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="3" 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="4" 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="4" side_tool="false" content_ui="tabs" />
...@@ -618,8 +619,8 @@ ...@@ -618,8 +619,8 @@
</entry> </entry>
<entry file="file://$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php"> <entry file="file://$PROJECT_DIR$/Application/Home/Controller/IndexController.class.php">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="76"> <state relative-caret-position="323">
<caret line="138" column="9" lean-forward="true" selection-start-line="138" selection-start-column="9" selection-end-line="138" selection-end-column="9" /> <caret line="66" column="25" lean-forward="true" selection-start-line="66" selection-start-column="25" selection-end-line="66" selection-end-column="25" />
<folding> <folding>
<element signature="e#34#44#0#PHP" expanded="true" /> <element signature="e#34#44#0#PHP" expanded="true" />
</folding> </folding>
......
...@@ -61,13 +61,14 @@ class IndexController extends Controller ...@@ -61,13 +61,14 @@ class IndexController extends Controller
public function get_random_prize($user) public function get_random_prize($user)
{ {
$v = rand(0, 1000000) / 1000000; $v = rand(0, 1000000) / 1000000;
$now = time();
$from = strtotime(date('Y-m-d-h:i', $now));
// if($from>=strtotime('2017-7-07-'))
$today_ratio = 0; $today_ratio = 0;
if ($v > $today_ratio) { if ($v > $today_ratio) {
return false; return false;
} }
$now = time();
$from = strtotime(date('Y-m-d', $now));
$to = strtotime(date('Y-m-d', $now + 86400)); $to = strtotime(date('Y-m-d', $now + 86400));
$req_type = array(); $req_type = array();
$type_list = array(1); $type_list = array(1);
...@@ -155,6 +156,7 @@ class IndexController extends Controller ...@@ -155,6 +156,7 @@ class IndexController extends Controller
'data' => array( 'data' => array(
'prize' => 0, 'prize' => 0,
'time'=>$from, 'time'=>$from,
'data'=>date('Y-m-d-h:i', $now)
) )
)); ));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment