当前位置: 首页>>代码示例>>PHP>>正文


PHP DBC::requireLess方法代码示例

本文整理汇总了PHP中DBC::requireLess方法的典型用法代码示例。如果您正苦于以下问题:PHP DBC::requireLess方法的具体用法?PHP DBC::requireLess怎么用?PHP DBC::requireLess使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DBC的用法示例。


在下文中一共展示了DBC::requireLess方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: search

 public function search($request, $response)
 {
     /*{{{*/
     $this->privilegeManagement();
     $nowPage = $request->page;
     $nowPage = isset($nowPage) ? $nowPage : 1;
     $searchType = $request->searchtype;
     $startTime = $request->starttime;
     $endTime = $request->endtime;
     if (empty($startTime) == false && empty($endTime) == false) {
         //HACK:hc
         //如果直接使用日期选择器,默认没有时分秒,主动加上
         if (strlen($startTime) < 11) {
             $startTime .= " 00:00:00";
             $endTime .= " 23:59:59";
         }
         DBC::requireLess($startTime, $endTime, "开始时间必须比结束时间小");
     } else {
         $startTime = 0;
     }
     $type = $request->type;
     $type = isset($type) ? $type : 0;
     $mark = $request->mark;
     $mark = isset($mark) ? $mark : 0;
     $status = $request->status;
     $status = isset($status) ? $status : 0;
     $searchText = $request->searchtext;
     $searchText = isset($searchText) ? $searchText : "";
     //sth.do
     list($feedbacklist, $pageInfo) = UserFeedbackClient::getInstance()->search($searchType, $startTime, $endTime, $type, $mark, $status, $searchText, $nowPage, $this::PAGE_SIZE);
     $response->feedbacklist = $feedbacklist;
     $response->inspector = $this->curInspector;
     $response->searchtype = $searchType;
     $response->starttime = $startTime;
     $response->endtime = $endTime;
     $response->type = $type;
     $response->mark = $mark;
     $response->status = $status;
     $response->searchtext = $searchText;
     $response->pagelink = PageNav::getNavLink(PageNav::getPageNavTemplate("/userfeedback/search?\n                type=" . $type . "&searchtype=" . $searchType . "&starttime=" . $startTime . "&endtime=" . $endTime . "&mark=" . $mark . "&status=" . $status . "&searchtext=" . $searchText . "&page="), $pageInfo['nowpage'], $pageInfo['pagesize'], $pageInfo['total']);
 }
开发者ID:sdgdsffdsfff,项目名称:hdf-client,代码行数:41,代码来源:userfeedbackcontroller.php

示例2: addEvent

 public function addEvent($request, $response)
 {
     /*{{{*/
     //操作人
     $space = DAL::get()->find('space', $request->spaceId);
     $orderDateFrom = $request->orderDateFrom . " 00:00:00";
     $orderDateTo = $request->orderDateTo . " 23:59:59";
     $remark = $request->remark;
     $user = $this->curInspector->user;
     DBC::requireLess($orderDateFrom, $orderDateTo, "开始时间必须比结束时间小");
     //增加事件同时增加任务,方法加到addEvent中
     BookingTaskClient::getInstance()->addEvent($space, $user, $orderDateFrom, $orderDateTo, $remark);
     $response->doctorName = $space->name;
     $response->msg = '添加成功';
 }
开发者ID:sdgdsffdsfff,项目名称:hdf-client,代码行数:15,代码来源:bookingcontroller.php


注:本文中的DBC::requireLess方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。