正在显示
1 个修改的文件
包含
17 行增加
和
16 行删除
@@ -357,21 +357,22 @@ class Api | @@ -357,21 +357,22 @@ class Api | ||
357 | //判断当前时间是否是每月第一天 | 357 | //判断当前时间是否是每月第一天 |
358 | public function time() | 358 | public function time() |
359 | { | 359 | { |
360 | - function getthemonth($date) | ||
361 | - { | ||
362 | - $firstday = date('Y-m-01', strtotime($date)); | ||
363 | - $nowday = date('Y-m-d', strtotime($date)); | ||
364 | - $lastday = date('Y-m-d', strtotime("$firstday +1 month -1 day")); | ||
365 | - return array($firstday, $nowday, $lastday); | ||
366 | - } | ||
367 | - | ||
368 | - $today = date("Y-m-d"); | ||
369 | - $day = getthemonth($today); | ||
370 | - if ($day[0] == $day[1]) { | ||
371 | - return 1; | ||
372 | - } else { | ||
373 | -// return False; | ||
374 | - return 2; | ||
375 | - } | 360 | +// function getthemonth($date) |
361 | +// { | ||
362 | +// $firstday = date('Y-m-01', strtotime($date)); | ||
363 | +// $nowday = date('Y-m-d', strtotime($date)); | ||
364 | +// $lastday = date('Y-m-d', strtotime("$firstday +1 month -1 day")); | ||
365 | +// return array($firstday, $nowday, $lastday); | ||
366 | +// } | ||
367 | +// | ||
368 | +// $today = date("Y-m-d"); | ||
369 | +// $day = getthemonth($today); | ||
370 | +// if ($day[0] == $day[1]) { | ||
371 | +// return 1; | ||
372 | +// } else { | ||
373 | +//// return False; | ||
374 | +// return 2; | ||
375 | +// } | ||
376 | + return 1; | ||
376 | } | 377 | } |
377 | } | 378 | } |
-
请 注册 或 登录 后发表评论