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


PHP URLBuilder::getURL方法代码示例

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


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

示例1: smarty_function_URLBuilder

/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */
function smarty_function_URLBuilder($params, &$smarty)
{
    $values = $params['values'];
    $script = $params['script'];
    $merge = strtolower(trim($params['merge']));
    if ($merge == 'false') {
        $merge = FALSE;
    } else {
        $merge = TRUE;
    }
    /*
        if ( empty($script) ) {
            $smarty->trigger_error("URLBuilder: missing 'script' parameter");
        }
    */
    if (!empty($values)) {
        $values_arr = explode(",", $values);
        $url_builder_arr = array();
        foreach ($values_arr as $value_pair) {
            $split_pairs = explode("=", $value_pair);
            $url_builder_arr[$split_pairs[0]] = $split_pairs[1];
        }
        $retval = URLBuilder::getURL($url_builder_arr, $script, $merge);
    } else {
        $retval = URLBuilder::getURL(NULL, $script);
    }
    //Debug::Text('URL: '. $retval, __FILE__, __LINE__, __METHOD__, 10);
    return $retval;
}
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:34,代码来源:function.urlbuilder.php

示例2: smarty_function_EmbeddedDocumentAttachmentList

/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */
function smarty_function_EmbeddedDocumentAttachmentList($params, &$smarty)
{
    $object_type_id = $params['object_type_id'];
    $object_id = $params['object_id'];
    $height = $params['height'];
    if (empty($height)) {
        $height = 75;
    }
    $url = URLBuilder::getURL(array('object_type_id' => $object_type_id, 'object_id' => $object_id), Environment::getBaseURL() . '/document/EmbeddedDocumentAttachmentList.php');
    $retval = '<iframe style="width:100%; height:' . $height . 'px; border: 5px" id="DocumentAttachmentFactory" name="DocumentAttachmentFactory" src="' . $url . '"></iframe>';
    return $retval;
}
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:17,代码来源:function.embeddeddocumentattachmentlist.php

示例3: smarty_function_EmbeddedMessageList

/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */
function smarty_function_EmbeddedMessageList($params, &$smarty)
{
    $object_type_id = $params['object_type_id'];
    $object_id = $params['object_id'];
    $height = $params['height'];
    if (empty($height)) {
        $height = 250;
    }
    //urlbuilder script="../message/EmbeddedMessageList.php" values="object_type_id=10,object_id=$default_schedule_control_id" merge="FALSE"}
    $url = URLBuilder::getURL(array('object_type_id' => $object_type_id, 'object_id' => $object_id), Environment::getBaseURL() . '/message/EmbeddedMessageList.php');
    //$retval = '<iframe style="width:100%; height:'.$height.'px; border: 0px" id="MessageFactory" name="MessageFactory" src="'.$url.'#form_start"></iframe>';
    $retval = '<iframe style="width:100%; height:' . $height . 'px; border: 5px" id="MessageFactory" name="MessageFactory" src="' . $url . '"></iframe>';
    return $retval;
}
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:19,代码来源:function.embeddedmessagelist.php

示例4: smarty_function_LayerMessageList

/**
 * Smarty plugin
 * @package Smarty
 * @subpackage plugins
 */
function smarty_function_LayerMessageList($params, &$smarty)
{
    $object_type_id = $params['object_type_id'];
    $object_id = $params['object_id'];
    $height = $params['height'];
    if ($object_type_id == '') {
        return FALSE;
    }
    if ($object_id == '') {
        return FALSE;
    }
    if (empty($height)) {
        $height = 335;
    }
    $url = URLBuilder::getURL(array('template' => 1, 'object_type_id' => $object_type_id, 'object_id' => $object_id), Environment::getBaseURL() . '/message/EmbeddedMessageList.php');
    $retval = '
<div id="MessageFactoryLayer" style="background:#000000;visibility:hidden; position: absolute; left: 5000px; top: 130px; width: 90%; height:' . $height . 'px">
<div id="rowContent">
  <div id="titleTab"><div class="textTitle"><span class="textTitleSub">Messages</span></div></div>
</div>
<div id="rowContentInner">
	<div id="contentBoxTwoEdit">
			<table class="tblList">
				<tr>
					<td>
    ';
    $retval .= '<iframe style="width:100%; height:' . $height . 'px; border: 5px" id="LayerMessageFactoryFrame" name="LayerMessageFactoryFrame" src="' . $url . '"></iframe>';
    $retval .= '
					</td>
				</tr>
			</table>
	</div>
</div>
</div>
';
    return $retval;
}
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:42,代码来源:function.layermessagelist.php

示例5: TTnew

     } else {
         $delete = FALSE;
     }
     $aplf = TTnew('AccrualPolicyListFactory');
     foreach ($ids as $id) {
         $aplf->getByIdAndCompanyId($id, $current_company->getId());
         $aplf->StartTransaction();
         foreach ($aplf as $ap_obj) {
             $ap_obj->setDeleted($delete);
             if ($ap_obj->isValid()) {
                 $ap_obj->Save();
             }
         }
         $aplf->CommitTransaction();
     }
     Redirect::Page(URLBuilder::getURL(NULL, 'AccrualPolicyList.php'));
     break;
 default:
     $aplf = TTnew('AccrualPolicyListFactory');
     $aplf->getByCompanyId($current_company->getId());
     $pager = new Pager($aplf);
     $type_options = $aplf->getOptions('type');
     $show_no_policy_group_notice = FALSE;
     foreach ($aplf as $ap_obj) {
         if ((int) $ap_obj->getColumn('assigned_policy_groups') == 0) {
             $show_no_policy_group_notice = TRUE;
         }
         $policies[] = array('id' => $ap_obj->getId(), 'name' => $ap_obj->getName(), 'type_id' => $ap_obj->getType(), 'type' => $type_options[$ap_obj->getType()], 'assigned_policy_groups' => (int) $ap_obj->getColumn('assigned_policy_groups'), 'deleted' => $ap_obj->getDeleted());
     }
     $smarty->assign_by_ref('policies', $policies);
     $smarty->assign_by_ref('show_no_policy_group_notice', $show_no_policy_group_notice);
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:AccrualPolicyList.php

示例6: TTnew

     if (isset($department_data['other_id3'])) {
         $df->setOtherID3($department_data['other_id3']);
     }
     if (isset($department_data['other_id4'])) {
         $df->setOtherID4($department_data['other_id4']);
     }
     if (isset($department_data['other_id5'])) {
         $df->setOtherID5($department_data['other_id5']);
     }
     if ($df->isValid()) {
         $df->Save(FALSE);
         if (isset($department_data['branch_list'])) {
             $df->setBranch($department_data['branch_list']);
             $df->Save(TRUE);
         }
         Redirect::Page(URLBuilder::getURL(NULL, 'DepartmentList.php'));
         break;
     }
 default:
     if (isset($id)) {
         BreadCrumb::setCrumb($title);
         $dlf = TTnew('DepartmentListFactory');
         $dlf->GetByIdAndCompanyId($id, $current_company->getId());
         foreach ($dlf as $department) {
             Debug::Arr($department, 'Department', __FILE__, __LINE__, __METHOD__, 10);
             $department_data = array('id' => $department->getId(), 'company_name' => $current_company->getName(), 'status' => $department->getStatus(), 'name' => $department->getName(), 'manual_id' => $department->getManualID(), 'branch_list' => $department->getBranch(), 'other_id1' => $department->getOtherID1(), 'other_id2' => $department->getOtherID2(), 'other_id3' => $department->getOtherID3(), 'other_id4' => $department->getOtherID4(), 'other_id5' => $department->getOtherID5(), 'created_date' => $department->getCreatedDate(), 'created_by' => $department->getCreatedBy(), 'updated_date' => $department->getUpdatedDate(), 'updated_by' => $department->getUpdatedBy(), 'deleted_date' => $department->getDeletedDate(), 'deleted_by' => $department->getDeletedBy());
         }
     } elseif ($action != 'submit') {
         $next_available_manual_id = DepartmentListFactory::getNextAvailableManualId($current_company->getId());
         $department_data = array('next_available_manual_id' => $next_available_manual_id);
     }
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditDepartment.php

示例7: TTnew

     }
     $ppf->setStartDate($data['start_date']);
     $ppf->setEndDate($data['end_date'] + 59);
     $ppf->setTransactionDate($data['transaction_date'] + 59);
     if (isset($data['advance_end_date'])) {
         $ppf->setAdvanceEndDate($data['advance_end_date']);
     }
     if (isset($data['advance_transaction_date'])) {
         $ppf->setAdvanceTransactionDate($data['advance_transaction_date']);
     }
     $ppf->setEnableImportData(TRUE);
     //Import punches when creating new pay periods.
     if ($ppf->isValid()) {
         $ppf->Save();
         $ppf->CommitTransaction();
         Redirect::Page(URLBuilder::getURL(array('id' => $data['pay_period_schedule_id']), 'PayPeriodList.php'));
         break;
     }
     $ppf->FailTransaction();
 default:
     if (isset($id)) {
         BreadCrumb::setCrumb($title);
         $pplf = TTnew('PayPeriodListFactory');
         $pplf->getByIdAndCompanyId($id, $current_company->getId());
         foreach ($pplf as $pp_obj) {
             //Debug::Arr($station,'Department', __FILE__, __LINE__, __METHOD__,10);
             $data = array('id' => $pp_obj->getId(), 'company_id' => $pp_obj->getCompany(), 'pay_period_schedule_id' => $pp_obj->getPayPeriodSchedule(), 'pay_period_schedule_type_id' => $pp_obj->getPayPeriodScheduleObject()->getType(), 'start_date' => $pp_obj->getStartDate(), 'end_date' => $pp_obj->getEndDate(), 'transaction_date' => $pp_obj->getTransactionDate(), 'advance_end_date' => $pp_obj->getAdvanceEndDate(), 'advance_transaction_date' => $pp_obj->getAdvanceTransactionDate(), 'deleted' => $pp_obj->getDeleted(), 'created_date' => $pp_obj->getCreatedDate(), 'created_by' => $pp_obj->getCreatedBy(), 'updated_date' => $pp_obj->getUpdatedDate(), 'updated_by' => $pp_obj->getUpdatedBy(), 'deleted_date' => $pp_obj->getDeletedDate(), 'deleted_by' => $pp_obj->getDeletedBy());
         }
     } else {
         if (isset($pay_period_schedule_id) and $pay_period_schedule_id != '') {
             $ppslf = TTnew('PayPeriodScheduleListFactory');
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditPayPeriod.php

示例8: unset

         } else {
             echo TTi18n::gettext("No Data To Export!") . "<br>\n";
         }
     } else {
         $smarty->assign_by_ref('generated_time', TTDate::getTime());
         $smarty->assign_by_ref('pay_period_options', $pay_period_options);
         $smarty->assign_by_ref('filter_data', $filter_data);
         $smarty->assign_by_ref('columns', $filter_columns);
         $smarty->assign_by_ref('rows', $rows);
         $smarty->display('report/TimesheetSummaryReport.tpl');
     }
     break;
 case 'delete':
 case 'save':
     Debug::Text('Action: ' . $action, __FILE__, __LINE__, __METHOD__, 10);
     $generic_data['id'] = UserGenericDataFactory::reportFormDataHandler($action, $filter_data, $generic_data, URLBuilder::getURL(NULL, $_SERVER['SCRIPT_NAME']));
     unset($generic_data['name']);
 default:
     BreadCrumb::setCrumb($title);
     if ($action == 'load') {
         Debug::Text('Loading Report!', __FILE__, __LINE__, __METHOD__, 10);
         extract(UserGenericDataFactory::getReportFormData($generic_data['id']));
     } elseif ($action == '') {
         //Check for default saved report first.
         $ugdlf->getByUserIdAndScriptAndDefault($current_user->getId(), $_SERVER['SCRIPT_NAME']);
         if ($ugdlf->getRecordCount() > 0) {
             Debug::Text('Found Default Report!', __FILE__, __LINE__, __METHOD__, 10);
             $ugd_obj = $ugdlf->getCurrent();
             $filter_data = $ugd_obj->getData();
             $generic_data['id'] = $ugd_obj->getId();
         } else {
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:TimesheetSummary.php

示例9: unset

            $cj_obj = $cjlf->getCurrent();
            if (PRODUCTION == TRUE and DEMO_MODE == FALSE and $cj_obj->getLastRunDate() < time() - 172800 and $cj_obj->getCreatedDate() < time() - 172800) {
                $cron_out_of_date = 1;
            } else {
                $cron_out_of_date = 0;
            }
        }
        unset($cjlf, $cj_obj);
    } else {
        Debug::text('User NOT! Authenticated', __FILE__, __LINE__, __METHOD__, 10);
        if (isset($enable_wap) and $enable_wap == TRUE) {
            Redirect::Page(URLBuilder::getURL(NULL, Environment::GetBaseURL() . 'wap/wap_login.php'));
        } elseif (isset($enable_iphone) and $enable_iphone == TRUE) {
            Redirect::Page(URLBuilder::getURL(NULL, Environment::GetBaseURL() . 'iphone/login/login.php'));
        } else {
            Redirect::Page(URLBuilder::getURL(NULL, Environment::GetBaseURL() . 'Login.php'));
        }
        //exit;
    }
}
require_once Environment::getBasePath() . 'classes' . DIRECTORY_SEPARATOR . 'smarty' . DIRECTORY_SEPARATOR . 'libs' . DIRECTORY_SEPARATOR . 'Smarty.class.php';
$smarty = new Smarty();
$smarty->compile_check = TRUE;
$smarty->template_dir = Environment::getTemplateDir();
$smarty->compile_dir = Environment::getTemplateCompileDir();
$smarty->assign('css_file', 'global.css.php');
$smarty->assign('IMAGES_URL', Environment::getImagesURL());
$smarty->assign('BASE_PATH', Environment::getBasePath());
$smarty->assign('APPLICATION_NAME', APPLICATION_NAME);
$smarty->assign('APPLICATION_VERSION', APPLICATION_VERSION);
$smarty->assign('DEPLOYMENT_ON_DEMAND', DEPLOYMENT_ON_DEMAND);
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:Interface.inc.php

示例10: TTnew

             $cdf->setIncludePayStubEntryAccount(array());
         }
         if (isset($data['exclude_pay_stub_entry_account_ids'])) {
             $cdf->setExcludePayStubEntryAccount($data['exclude_pay_stub_entry_account_ids']);
         } else {
             $cdf->setExcludePayStubEntryAccount(array());
         }
         if (isset($data['user_ids'])) {
             $cdf->setUser($data['user_ids']);
         } else {
             $cdf->setUser(array());
         }
         if ($cdf->isValid()) {
             $cdf->Save(TRUE);
             $cdf->CommitTransaction();
             Redirect::Page(URLBuilder::getURL(NULL, 'CompanyDeductionList.php'));
             break;
         }
     }
 default:
     if (isset($id)) {
         BreadCrumb::setCrumb($title);
         $cdlf = TTnew('CompanyDeductionListFactory');
         $cdlf->getByCompanyIdAndId($current_company->getId(), $id);
         foreach ($cdlf as $cd_obj) {
             //Debug::Arr($station,'Department', __FILE__, __LINE__, __METHOD__,10);
             $data = array('id' => $cd_obj->getId(), 'company_id' => $cd_obj->getCompany(), 'status_id' => $cd_obj->getStatus(), 'type_id' => $cd_obj->getType(), 'name' => $cd_obj->getName(), 'start_date' => $cd_obj->getStartDate(), 'end_date' => $cd_obj->getEndDate(), 'minimum_length_of_service' => $cd_obj->getMinimumLengthOfService(), 'minimum_length_of_service_unit_id' => $cd_obj->getMinimumLengthOfServiceUnit(), 'maximum_length_of_service' => $cd_obj->getMaximumLengthOfService(), 'maximum_length_of_service_unit_id' => $cd_obj->getMaximumLengthOfServiceUnit(), 'minimum_user_age' => $cd_obj->getMinimumUserAge(), 'maximum_user_age' => $cd_obj->getMaximumUserAge(), 'calculation_id' => $cd_obj->getCalculation(), 'calculation_order' => $cd_obj->getCalculationOrder(), 'country' => $cd_obj->getCountry(), 'province' => $cd_obj->getProvince(), 'district' => $cd_obj->getDistrict(), 'company_value1' => $cd_obj->getCompanyValue1(), 'company_value2' => $cd_obj->getCompanyValue2(), 'user_value1' => $cd_obj->getUserValue1(), 'user_value2' => $cd_obj->getUserValue2(), 'user_value3' => $cd_obj->getUserValue3(), 'user_value4' => $cd_obj->getUserValue4(), 'user_value5' => $cd_obj->getUserValue5(), 'user_value6' => $cd_obj->getUserValue6(), 'user_value7' => $cd_obj->getUserValue7(), 'user_value8' => $cd_obj->getUserValue8(), 'user_value9' => $cd_obj->getUserValue9(), 'user_value10' => $cd_obj->getUserValue10(), 'lock_user_value1' => $cd_obj->getLockUserValue1(), 'lock_user_value2' => $cd_obj->getLockUserValue2(), 'lock_user_value3' => $cd_obj->getLockUserValue3(), 'lock_user_value4' => $cd_obj->getLockUserValue4(), 'lock_user_value5' => $cd_obj->getLockUserValue5(), 'lock_user_value6' => $cd_obj->getLockUserValue6(), 'lock_user_value7' => $cd_obj->getLockUserValue7(), 'lock_user_value8' => $cd_obj->getLockUserValue8(), 'lock_user_value9' => $cd_obj->getLockUserValue9(), 'lock_user_value10' => $cd_obj->getLockUserValue10(), 'pay_stub_entry_account_id' => $cd_obj->getPayStubEntryAccount(), 'include_pay_stub_entry_account_ids' => $cd_obj->getIncludePayStubEntryAccount(), 'exclude_pay_stub_entry_account_ids' => $cd_obj->getExcludePayStubEntryAccount(), 'include_account_amount_type_id' => $cd_obj->getIncludeAccountAmountType(), 'exclude_account_amount_type_id' => $cd_obj->getExcludeAccountAmountType(), 'user_ids' => $cd_obj->getUser(), 'created_date' => $cd_obj->getCreatedDate(), 'created_by' => $cd_obj->getCreatedBy(), 'updated_date' => $cd_obj->getUpdatedDate(), 'updated_by' => $cd_obj->getUpdatedBy(), 'deleted_date' => $cd_obj->getDeletedDate(), 'deleted_by' => $cd_obj->getDeletedBy());
         }
     } elseif ($action != 'submit') {
         $data = array('country' => 0, 'province' => 0, 'district' => 0, 'user_value1' => 0, 'user_value2' => 0, 'user_value3' => 0, 'user_value4' => 0, 'user_value5' => 0, 'user_value6' => 0, 'user_value7' => 0, 'user_value8' => 0, 'user_value9' => 0, 'user_value10' => 0, 'minimum_length_of_service' => 0, 'maximum_length_of_service' => 0, 'minimum_user_age' => 0, 'maximum_user_age' => 0, 'calculation_order' => 100);
     }
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditCompanyDeduction.php

示例11: array

 case 'submit':
     //Debug::setVerbosity(11);
     Debug::Text('Submit!', __FILE__, __LINE__, __METHOD__, 10);
     $fail_transaction = FALSE;
     if (TTDate::getDayDifference($data['start_date_stamp'], $data['end_date_stamp']) > 31) {
         Debug::Text('Date Range Exceeds 31 days, truncating', __FILE__, __LINE__, __METHOD__, 10);
         $sf->Validator->isTrue('date_stamp', FALSE, TTi18n::getText('Date range exceeds the maximum of 31 days'));
     }
     if (!(isset($filter_user_id) and is_array($filter_user_id) and count($filter_user_id) > 0)) {
         $sf->Validator->isTrue('user_id', FALSE, TTi18n::getText('Please select at least one employee'));
     }
     if (!($data['start_full_time_stamp'] != '' and $data['end_full_time_stamp'] != '' and $data['start_full_time_stamp'] >= time() - 86400 * 365 and $data['end_full_time_stamp'] <= time() + 86400 * 365)) {
         $sf->Validator->isTrue('date_stamp', FALSE, TTi18n::getText('Start or End dates are invalid'));
     }
     if ($sf->Validator->isValid()) {
         Redirect::Page(URLBuilder::getURL(array('action' => 'add_mass_schedule', 'filter_user_id' => $filter_user_id, 'data' => $data), '../progress_bar/ProgressBarControl.php'));
     }
 default:
     if ($action != 'submit' and !is_array($data)) {
         Debug::Text(' ID was NOT passed: ' . $id, __FILE__, __LINE__, __METHOD__, 10);
         $user_id = NULL;
         $user_date_id = NULL;
         $user_full_name = NULL;
         $user_default_branch = NULL;
         $user_default_department = NULL;
         $pay_period_is_locked = FALSE;
         $time_stamp = $start_date_stamp = $end_date_stamp = TTDate::getBeginDayEpoch(TTDate::getTime()) + 3600 * 12;
         //Noon
         $data = array('start_date_stamp' => $start_date_stamp, 'end_date_stamp' => $end_date_stamp, 'start_time' => strtotime('08:00 AM'), 'parsed_start_time' => strtotime('08:00 AM'), 'end_time' => strtotime('05:00 PM'), 'parsed_end_time' => strtotime('05:00 PM'), 'total_time' => 3600 * 9, 'branch_id' => $user_default_branch, 'department_id' => $user_default_department, 'dow' => array(1 => TRUE, 2 => TRUE, 3 => TRUE, 4 => TRUE, 5 => TRUE));
     }
     //var_dump($data);
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:AddMassSchedule.php

示例12: UserDeductionListFactory

     } else {
         $delete = FALSE;
     }
     $udlf = new UserDeductionListFactory();
     if (isset($ids) and is_array($ids)) {
         foreach ($ids as $id) {
             $udlf->getByCompanyIdAndId($current_company->getId(), $id, $current_company->getId());
             foreach ($udlf as $ud_obj) {
                 $ud_obj->setDeleted($delete);
                 if ($ud_obj->isValid()) {
                     $ud_obj->Save();
                 }
             }
         }
     }
     Redirect::Page(URLBuilder::getURL(array('user_id' => $user_id), 'UserDeductionList.php'));
     break;
 default:
     BreadCrumb::setCrumb($title);
     //Get Permission Hierarchy Children first, as this can be used for viewing, or editing.
     $hlf = new HierarchyListFactory();
     $permission_children_ids = $hlf->getHierarchyChildrenByCompanyIdAndUserIdAndObjectTypeID($current_company->getId(), $current_user->getId());
     $udlf = new UserDeductionListFactory();
     $udlf->getByCompanyIdAndUserId($current_company->getId(), $user_id);
     $pager = new Pager($udlf);
     $ulf->getByIdAndCompanyId($user_id, $current_company->getId());
     if ($ulf->getRecordCount() > 0) {
         $user_obj = $ulf->getCurrent();
         if (is_object($user_obj)) {
             $is_owner = $permission->isOwner($user_obj->getCreatedBy(), $user_obj->getID());
             $is_child = $permission->isChild($user_obj->getId(), $permission_children_ids);
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:UserDeductionList.php

示例13: extract

                 $rsc_obj->setUser($user_diff_arr);
             }
             if ($rsc_obj->isValid()) {
                 $rsc_obj->Save();
             }
         }
     }
     Redirect::Page(URLBuilder::getURL(NULL, 'RecurringScheduleControlList.php'));
     break;
 case 'search_form_delete':
 case 'search_form_update':
 case 'search_form_save':
 case 'search_form_clear':
 case 'search_form_search':
     Debug::Text('Action: ' . $action, __FILE__, __LINE__, __METHOD__, 10);
     $saved_search_id = UserGenericDataFactory::searchFormDataHandler($action, $filter_data, URLBuilder::getURL(NULL, 'RecurringScheduleControlList.php'));
 default:
     BreadCrumb::setCrumb($title);
     extract(UserGenericDataFactory::getSearchFormData($saved_search_id, $sort_column));
     Debug::Text('Sort Column: ' . $sort_column, __FILE__, __LINE__, __METHOD__, 10);
     Debug::Text('Saved Search ID: ' . $saved_search_id, __FILE__, __LINE__, __METHOD__, 10);
     if (isset($filter_template_id) and $filter_template_id != '') {
         $filter_data['template_id'] = array($filter_template_id);
     }
     $sort_array = NULL;
     if ($sort_column != '') {
         $sort_array = array(Misc::trimSortPrefix($sort_column) => $sort_order);
     }
     URLBuilder::setURL($_SERVER['SCRIPT_NAME'], array('sort_column' => Misc::trimSortPrefix($sort_column), 'sort_order' => $sort_order, 'saved_search_id' => $saved_search_id, 'page' => $page));
     $rsclf = new RecurringScheduleControlListFactory();
     $ulf = new UserListFactory();
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:RecurringScheduleControlList.php

示例14: TTnew

                 $m_obj->setDeleted($delete);
                 $m_obj->Save();
             }
         } else {
             //Sent
             $mslf = TTnew('MessageSenderListFactory');
             $mslf->getByCompanyIdAndUserIdAndId($current_company->getId(), $current_user->getId(), $ids);
             foreach ($mslf as $m_obj) {
                 $m_obj->setDeleted($delete);
                 $m_obj->Save();
             }
         }
         //$mcf->FailTransaction();
         $mcf->CommitTransaction();
     }
     Redirect::Page(URLBuilder::getURL(array('filter_folder_id' => $filter_folder_id), 'UserMessageList.php'));
     break;
 default:
     $mclf = TTnew('MessageControlListFactory');
     $folder_options = $mclf->getOptions('folder');
     Debug::text('Filter Folder ID: ' . $filter_folder_id, __FILE__, __LINE__, __METHOD__, 9);
     if (!isset($filter_folder_id) or !in_array($filter_folder_id, array_keys($folder_options))) {
         Debug::text('Invalid Folder, using default ', __FILE__, __LINE__, __METHOD__, 9);
         $filter_folder_id = 10;
     }
     //Make sure folder and sort columns stays as we switch pages.
     URLBuilder::setURL(NULL, array('filter_folder_id' => $filter_folder_id, 'sort_column' => $sort_column, 'sort_order' => $sort_order));
     $mclf->getByCompanyIdAndUserIdAndFolder($current_user->getCompany(), $current_user->getId(), $filter_folder_id, $current_user_prefs->getItemsPerPage(), $page, NULL, $sort_array);
     $pager = new Pager($mclf);
     if ($mclf->getRecordCount() > 0) {
         $object_name_options = $mclf->getOptions('object_name');
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:UserMessageList.php

示例15: CurrencyListFactory

     } else {
         $delete = FALSE;
     }
     $clf = new CurrencyListFactory();
     if (isset($ids) and is_array($ids)) {
         foreach ($ids as $id) {
             $clf->getByIdAndCompanyId($id, $current_company->getId());
             foreach ($clf as $c_obj) {
                 $c_obj->setDeleted($delete);
                 if ($c_obj->isValid()) {
                     $c_obj->Save();
                 }
             }
         }
     }
     Redirect::Page(URLBuilder::getURL(NULL, 'CurrencyList.php'));
     break;
 default:
     BreadCrumb::setCrumb($title);
     $clf = new CurrencyListFactory();
     $clf->getByCompanyId($current_company->getId(), $current_user_prefs->getItemsPerPage(), $page, NULL, $sort_array);
     $pager = new Pager($clf);
     $iso_code_options = $clf->getISOCodesArray();
     $base_currency = FALSE;
     foreach ($clf as $c_obj) {
         if ($c_obj->getBase() === TRUE) {
             $base_currency = TRUE;
         }
         $rows[] = array('id' => $c_obj->GetId(), 'status_id' => $c_obj->getStatus(), 'name' => $c_obj->getName(), 'iso_code' => $c_obj->getISOCode(), 'currency_name' => Option::getByKey($c_obj->getISOCode(), $iso_code_options), 'conversion_rate' => $c_obj->getConversionRate(), 'auto_update' => $c_obj->getAutoUpdate(), 'is_base' => $c_obj->getBase(), 'is_default' => $c_obj->getDefault(), 'deleted' => $c_obj->getDeleted());
     }
     $smarty->assign_by_ref('currencies', $rows);
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:CurrencyList.php


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