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


PHP calendar::getCalendarInfoE方法代码示例

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


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

示例1: calendarEdit

 /**
  * CALENDAR
  * getting default list
  *
  * @param string $httpData->PRO_UID (opional)
  */
 public function calendarEdit($httpData)
 {
     global $RBAC;
     //$RBAC->requirePermissions('PM_SETUP_ADVANCE');
     G::LoadClass('configuration');
     G::LoadClass('calendar');
     $CalendarUid = str_replace('"', '', isset($_GET['id']) ? $_GET['id'] : G::GenerateUniqueID());
     $calendarObj = new calendar();
     if (isset($_GET['id']) && $_GET['id'] != "") {
         $fields = $calendarObj->getCalendarInfoE($CalendarUid);
         $fields['OLD_NAME'] = $fields['CALENDAR_NAME'];
     }
     // For a new Calendar
     if (!isset($fields['CALENDAR_UID'])) {
         $fields['CALENDAR_UID'] = $CalendarUid;
         $fields['OLD_NAME'] = '';
         //Default Business Hour
         $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_DAY'] = 7;
         $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_START'] = "09:00";
         $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_END'] = "17:00";
     }
     // Copy Calendar
     if (isset($_GET['cp']) && $_GET['cp'] == 1) {
         $fields['CALENDAR_UID'] = G::GenerateUniqueID();
         $fields['CALENDAR_NAME'] = G::LoadTranslation("ID_COPY_OF") . " " . $fields['CALENDAR_NAME'];
         $fields['OLD_NAME'] = $fields['CALENDAR_NAME'];
     }
     $c = new Configurations();
     $configPage = $c->getConfiguration('additionalTablesList', 'pageSize', '', $_SESSION['USER_LOGGED']);
     $Config['pageSize'] = isset($configPage['pageSize']) ? $configPage['pageSize'] : 20;
     $this->includeExtJS('admin/calendarEdit');
     $this->setView('admin/calendarEdit');
     $businessDayArray = array();
     for ($i = 0; $i < sizeof($fields['BUSINESS_DAY']); $i++) {
         $businessDayArray[$i] = $fields['BUSINESS_DAY'][$i + 1];
     }
     $fields['BUSINESS_DAY'] = $businessDayArray;
     //validating if the calendar is new, it means that we don't have the $_GET array
     $fields['HOLIDAY'] = isset($_GET['id']) && $_GET['id'] != '' ? $fields['HOLIDAY'] : array();
     $holidayArray = array();
     for ($i = 0; $i < sizeof($fields['HOLIDAY']); $i++) {
         $holidayArray[$i] = $fields['HOLIDAY'][$i + 1];
     }
     $_GET['id'] = isset($_GET['id']) && $_GET['id'] != '' ? $_GET['id'] : '';
     $fields['HOLIDAY'] = $holidayArray;
     $fields['NEWCALENDAR'] = 'NO';
     if (isset($_GET['id']) && $_GET['id'] == '') {
         $fields['CALENDAR_UID'] = G::GenerateUniqueID();
         $fields['NEWCALENDAR'] = 'YES';
     }
     $this->setJSVar('CALENDAR_UID', $fields['CALENDAR_UID']);
     $this->setJSVar('fields', $fields);
     G::RenderPage('publish', 'extJs');
 }
开发者ID:emildev35,项目名称:processmaker,代码行数:60,代码来源:admin.php

示例2: isset

 */
if ($RBAC->userCanAccess('PM_SETUP') != 1 && $RBAC->userCanAccess('PM_SETUP_ADVANCE') != 1) {
    G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels');
    //G::header('location: ../login/login');
    die;
}
$G_MAIN_MENU = 'processmaker';
$G_SUB_MENU = 'setup';
$G_ID_MENU_SELECTED = 'SETUP';
$G_ID_SUB_MENU_SELECTED = 'CALENDAR';
$CalendarUid = str_replace('"', '', isset($_GET['id']) ? $_GET['id'] : G::GenerateUniqueID());
//TODO: Add validation before save for all fields
G::LoadClass('calendar');
$calendarObj = new calendar();
if (isset($_GET['id']) && $_GET['id'] != "") {
    $fields = $calendarObj->getCalendarInfoE($CalendarUid);
    $fields['OLD_NAME'] = $fields['CALENDAR_NAME'];
}
if (!isset($fields['CALENDAR_UID'])) {
    //For a new Calendar
    $fields['CALENDAR_UID'] = $CalendarUid;
    $fields['OLD_NAME'] = '';
    //Default Business Hour
    $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_DAY'] = 7;
    $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_START'] = "09:00";
    $fields['BUSINESS_DAY'][1]['CALENDAR_BUSINESS_END'] = "17:00";
}
if (isset($_GET['cp']) && $_GET['cp'] == 1) {
    // Copy Calendar
    $fields['CALENDAR_UID'] = G::GenerateUniqueID();
    $fields['CALENDAR_NAME'] = G::LoadTranslation("ID_COPY_OF") . " " . $fields['CALENDAR_NAME'];
开发者ID:nshong,项目名称:processmaker,代码行数:31,代码来源:calendarEdit.php


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