• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP FormVariables类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: extract

 * feasible for technical reasons, the Appropriate Legal Notices must display
 * the words "Powered by TimeTrex".
 ********************************************************************************/
/*
 * $Revision: 11151 $
 * $Id: Login.php 11151 2013-10-14 22:00:30Z ipso $
 * $Date: 2013-10-14 15:00:30 -0700 (Mon, 14 Oct 2013) $
 */
require_once '../includes/global.inc.php';
$authenticate = FALSE;
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
$smarty->assign('title', TTi18n::gettext('Secure Login'));
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'user_name', 'password', 'password_reset', 'language')));
$validator = new Validator();
$action = Misc::findSubmitButton();
switch ($action) {
    case 'submit':
        //Debug::setVerbosity( 11 );
        Debug::Text('User Name: ' . $user_name, __FILE__, __LINE__, __METHOD__, 10);
        if (isset($config_vars['other']['web_session_expire']) and $config_vars['other']['web_session_expire'] != '') {
            $authentication->setEnableExpireSession((int) $config_vars['other']['web_session_expire']);
        }
        $authentication_result = $authentication->Login($user_name, $password);
        if ($authentication_result === TRUE) {
            $authentication->Check();
            Debug::text('Login Language: ' . $language, __FILE__, __LINE__, __METHOD__, 10);
            TTi18n::setCountry(TTi18n::getCountryFromLocale());
            TTi18n::setLanguage($language);
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:Login.php


示例2: extract

 */
require_once '../../includes/global.inc.php';
//Debug::setVerbosity(11);
$skip_message_check = TRUE;
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('schedule', 'enabled') or !($permission->Check('schedule', 'edit') or $permission->Check('schedule', 'edit_own') or $permission->Check('schedule', 'edit_child'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Mass Schedule'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'id', 'data', 'filter_user_id')));
$data = Misc::preSetArrayValues($data, array('start_date_stamp', 'end_date_stamp', 'start_time', 'end_time'), NULL);
if (isset($data)) {
    if ($data['start_date_stamp'] != '' and !is_numeric($data['start_date_stamp']) and $data['end_date_stamp'] != '' and !is_numeric($data['end_date_stamp']) and $data['start_time'] != '' and !is_numeric($data['end_time']) and $data['end_time'] != '' and !is_numeric($data['end_time'])) {
        $data['start_full_time_stamp'] = TTDate::parseDateTime($data['start_date_stamp'] . ' ' . $data['start_time']);
        $data['end_full_time_stamp'] = TTDate::parseDateTime($data['end_date_stamp'] . ' ' . $data['end_time']);
    } else {
        $data['start_full_time_stamp'] = NULL;
        $data['end_full_time_stamp'] = NULL;
    }
    if ($data['start_date_stamp'] != '') {
        $data['start_date_stamp'] = TTDate::parseDateTime($data['start_date_stamp']);
    }
    if ($data['end_date_stamp'] != '') {
        $data['end_date_stamp'] = TTDate::parseDateTime($data['end_date_stamp']);
    }
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:AddMassSchedule.php


示例3: extract

 * $Id: EditUserAbsence.php 9993 2013-05-24 20:16:41Z ipso $
 * $Date: 2013-05-24 13:16:41 -0700 (Fri, 24 May 2013) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('absence', 'enabled') or !($permission->Check('absence', 'edit') or $permission->Check('absence', 'edit_own') or $permission->Check('absence', 'edit_child'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Edit Absence'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'id', 'user_id', 'date_stamp', 'udt_data')));
if (isset($udt_data)) {
    if ($udt_data['total_time'] != '') {
        $udt_data['total_time'] = TTDate::parseTimeUnit($udt_data['total_time']);
    }
}
$udtf = TTnew('UserDateTotalFactory');
$action = Misc::findSubmitButton();
$action = strtolower($action);
switch ($action) {
    case 'delete':
        Debug::Text('Delete!', __FILE__, __LINE__, __METHOD__, 10);
        //Debug::setVerbosity(11);
        $udtlf = TTnew('UserDateTotalListFactory');
        $udtlf->getById($udt_data['id']);
        if ($udtlf->getRecordCount() > 0) {
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditUserAbsence.php


示例4: extract

 * $Revision: 5178 $
 * $Id: EditPayPeriodSchedule.php 5178 2011-08-30 21:13:34Z ipso $
 * $Date: 2011-08-30 14:13:34 -0700 (Tue, 30 Aug 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('pay_period_schedule', 'enabled') or !($permission->Check('pay_period_schedule', 'edit') or $permission->Check('pay_period_schedule', 'edit_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Edit Pay Period Schedule'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'id', 'user_id', 'pay_period_schedule_data')));
//var_dump($pay_period_schedule_data);
if (isset($pay_period_schedule_data)) {
    if (isset($pay_period_schedule_data['anchor_date'])) {
        $pay_period_schedule_data['anchor_date'] = TTDate::parseDateTime($pay_period_schedule_data['anchor_date']);
    }
    if (isset($pay_period_schedule_data['day_start_time'])) {
        $pay_period_schedule_data['day_start_time'] = TTDate::parseTimeUnit($pay_period_schedule_data['day_start_time']);
    }
    if (isset($pay_period_schedule_data['new_day_trigger_time'])) {
        $pay_period_schedule_data['new_day_trigger_time'] = TTDate::parseTimeUnit($pay_period_schedule_data['new_day_trigger_time']);
    }
    if (isset($pay_period_schedule_data['maximum_shift_time'])) {
        $pay_period_schedule_data['maximum_shift_time'] = TTDate::parseTimeUnit($pay_period_schedule_data['maximum_shift_time']);
    }
}
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditPayPeriodSchedule.php


示例5: extract

 * $Revision: 5519 $
 * $Id: PremiumPolicyList.php 5519 2011-11-15 19:28:49Z ipso $
 * $Date: 2011-11-15 11:28:49 -0800 (Tue, 15 Nov 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('premium_policy', 'enabled') or !($permission->Check('premium_policy', 'view') or $permission->Check('premium_policy', 'view_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Premium Policy List'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'page', 'sort_column', 'sort_order', 'ids')));
URLBuilder::setURL($_SERVER['SCRIPT_NAME'], array('sort_column' => $sort_column, 'sort_order' => $sort_order, 'page' => $page));
$sort_array = NULL;
if ($sort_column != '') {
    $sort_array = array($sort_column => $sort_order);
}
Debug::Arr($ids, 'Selected Objects', __FILE__, __LINE__, __METHOD__, 10);
$action = Misc::findSubmitButton();
switch ($action) {
    case 'add':
        Redirect::Page(URLBuilder::getURL(NULL, 'EditPremiumPolicy.php', FALSE));
        break;
    case 'delete':
    case 'undelete':
        if (strtolower($action) == 'delete') {
            $delete = TRUE;
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:PremiumPolicyList.php


示例6: extract

 * $Id: EditUserTax.php 1246 2007-09-14 23:47:42Z ipso $
 * $Date: 2007-09-14 16:47:42 -0700 (Fri, 14 Sep 2007) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('user_tax', 'enabled') or !($permission->Check('user_tax', 'edit') or $permission->Check('user_tax', 'edit_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Edit Employee Tax Options'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'user_id', 'tax_data', 'data_saved')));
$utf = new UserTaxFactory();
$action = Misc::findSubmitButton();
switch ($action) {
    case 'submit':
        Debug::Text('Submit!', __FILE__, __LINE__, __METHOD__, 10);
        $utf->setId($tax_data['id']);
        $utf->setUser($tax_data['user_id']);
        if (isset($tax_data['federal_claim'])) {
            $utf->setFederalClaim($tax_data['federal_claim']);
        }
        if (isset($tax_data['provincial_claim'])) {
            $utf->setProvincialClaim($tax_data['provincial_claim']);
        }
        if ($tax_data['federal_additional_deduction'] != '') {
            $utf->setFederalAdditionalDeduction($tax_data['federal_additional_deduction']);
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:EditUserTax.php


示例7: extract

/*
 * $Revision: 3021 $
 * $Id: Requirements.php 3021 2009-11-11 23:33:03Z ipso $
 * $Date: 2009-11-11 15:33:03 -0800 (Wed, 11 Nov 2009) $
 */
@ini_set('display_errors', true);
$disable_database_connection = TRUE;
require_once '../../includes/global.inc.php';
$authenticate = FALSE;
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
$smarty->assign('title', TTi18n::gettext($title = '2. System Check Acceptance'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'data', 'external_installer')));
if (DEPLOYMENT_ON_DEMAND == FALSE) {
    $cache->clean();
    //Clear all cache.
}
$smarty->clear_all_cache();
$install_obj = new Install();
if ($install_obj->isInstallMode() == FALSE) {
    Redirect::Page(URLBuilder::getURL(NULL, 'install.php'));
}
$action = Misc::findSubmitButton();
switch ($action) {
    case 'phpinfo':
        phpinfo();
        exit;
        break;
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:Requirements.php


示例8: extract

 * $Date: 2009-01-19 17:13:01 -0800 (Mon, 19 Jan 2009) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('pay_stub', 'enabled') or !($permission->Check('pay_stub', 'view') or $permission->Check('pay_stub', 'view_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Employee Pay Stub'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'page', 'sort_column', 'sort_order', 'hide_employer_rows', 'id', 'ids')));
switch ($action) {
    default:
        if (isset($id) and !isset($ids)) {
            $ids = array($id);
        }
        if (count($ids) > 0) {
            $pslf = new PayStubListFactory();
            if ($permission->Check('pay_stub', 'view')) {
                $pslf->getByCompanyIdAndId($current_company->getId(), $ids);
            } else {
                $pslf->getByUserIdAndId($current_user->getId(), $ids);
            }
            //foreach ($ids as $id) {
            $i = 0;
            foreach ($pslf as $pay_stub_obj) {
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:ViewPayStub.php


示例9: extract

 * $Date: 2011-10-25 09:23:28 -0700 (Tue, 25 Oct 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//require_once(Environment::getBasePath() .'classes/class.progressbar.php');
//Debug::setVerbosity(11);
if (!$permission->Check('pay_period_schedule', 'enabled') or !($permission->Check('pay_period_schedule', 'edit') or $permission->Check('pay_period_schedule', 'edit_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'View Pay Period'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'pay_period_id', 'status_id')));
$ppf = TTnew('PayPeriodFactory');
$action = Misc::findSubmitButton();
switch ($action) {
    case 'submit':
        $pplf = TTnew('PayPeriodListFactory');
        $pplf->getByIdAndCompanyId($pay_period_id, $current_company->getId());
        foreach ($pplf as $pay_period_obj) {
            $pay_period_obj->setStatus($status_id);
            $pay_period_obj->save();
        }
        Redirect::Page(URLBuilder::getURL(array('pay_period_id' => $pay_period_id), 'ViewPayPeriod.php'));
        break;
    case 'generate_paystubs':
        Debug::Text('Generate Pay Stubs!', __FILE__, __LINE__, __METHOD__, 10);
        Redirect::Page(URLBuilder::getURL(array('action' => 'generate_paystubs', 'pay_period_ids' => $pay_period_id, 'next_page' => URLBuilder::getURL(array('filter_pay_period_id' => $pay_period_id), '../pay_stub/PayStubList.php')), '../progress_bar/ProgressBarControl.php'));
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:ViewPayPeriod.php


示例10: extract

 * You should have received a copy of the GNU Affero General Public License along
 * with this program; if not, see http://www.gnu.org/licenses or write to the Free
 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301 USA.
 *
 * You can contact TimeTrex headquarters at Unit 22 - 2475 Dobbin Rd. Suite
 * #292 Westbank, BC V4T 2E9, Canada or at email address [email protected].
 *
 * The interactive user interfaces in modified source and object code versions
 * of this program must display Appropriate Legal Notices, as required under
 * Section 5 of the GNU Affero General Public License version 3.
 *
 * In accordance with Section 7(b) of the GNU Affero General Public License
 * version 3, these Appropriate Legal Notices must retain the display of the
 * "Powered by TimeTrex" logo. If the display of the logo is not reasonably
 * feasible for technical reasons, the Appropriate Legal Notices must display
 * the words "Powered by TimeTrex".
 ********************************************************************************/
/*
 * $Revision: 1902 $
 * $Id: DownForMaintenance.php 1902 2008-06-06 17:27:56Z ipso $
 * $Date: 2008-06-06 10:27:56 -0700 (Fri, 06 Jun 2008) $
 */
$disable_database_connection = TRUE;
require_once '../includes/global.inc.php';
$authenticate = FALSE;
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
extract(FormVariables::GetVariables(array('exception')));
$smarty->assign('title', TTi18n::gettext('Down for Maintenance'));
$smarty->assign('exception', strtolower($exception));
$smarty->display('DownForMaintenance.tpl');
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:DownForMaintenance.php


示例11: extract

 * $Date: 2009-01-27 10:18:32 -0800 (Tue, 27 Jan 2009) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('punch', 'enabled') or !($permission->Check('punch', 'view') or $permission->Check('punch', 'view_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Hour List'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'page', 'sort_column', 'sort_order', 'filter_user_id', 'filter_date', 'filter_system_time', 'prev_day', 'next_day', 'prev_week', 'next_week', 'ids')));
if ($filter_user_id != '') {
    $user_id = $filter_user_id;
} else {
    $user_id = $current_user->getId();
}
if ($filter_date != '') {
    $filter_date = TTDate::getBeginDayEpoch(TTDate::parseDateTime($filter_date));
}
if (isset($prev_day)) {
    $filter_date = TTDate::getBeginDayEpoch($filter_date - 86400);
} elseif (isset($next_day)) {
    $filter_date = TTDate::getBeginDayEpoch($filter_date + 86400);
}
if (isset($prev_week)) {
    $filter_date = TTDate::getBeginDayEpoch($filter_date - 86400 * 7);
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:UserDateTotalList.php


示例12: extract

 * $Id: ViewUserAccrualList.php 6791 2012-05-17 19:46:31Z ipso $
 * $Date: 2012-05-17 12:46:31 -0700 (Thu, 17 May 2012) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('accrual', 'enabled') or !($permission->Check('accrual', 'view') or $permission->Check('accrual', 'view_own') or $permission->Check('accrual', 'view_child'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Accrual List'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'page', 'sort_column', 'sort_order', 'user_id', 'accrual_policy_id', 'ids')));
if ($permission->Check('accrual', 'view') or $permission->Check('accrual', 'view_child')) {
    $user_id = $user_id;
} else {
    $user_id = $current_user->getId();
}
URLBuilder::setURL($_SERVER['SCRIPT_NAME'], array('user_id' => $user_id, 'accrual_policy_id' => $accrual_policy_id, 'sort_column' => $sort_column, 'sort_order' => $sort_order, 'page' => $page));
$sort_array = NULL;
if ($sort_column != '') {
    $sort_array = array($sort_column => $sort_order);
}
Debug::Arr($ids, 'Selected Objects', __FILE__, __LINE__, __METHOD__, 10);
$action = Misc::findSubmitButton();
switch ($action) {
    case 'add':
        Redirect::Page(URLBuilder::getURL(NULL, 'EditUserAccrual.php'));
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:ViewUserAccrualList.php


示例13: extract

 * $Date: 2012-06-18 13:23:23 -0700 (Mon, 18 Jun 2012) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('pay_stub_amendment', 'enabled') or !($permission->Check('pay_stub_amendment', 'view') or $permission->Check('pay_stub_amendment', 'view_child') or $permission->Check('pay_stub_amendment', 'view_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Pay Stub Amendment List'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'form', 'page', 'filter_data', 'sort_column', 'sort_order', 'saved_search_id', 'filter_user_id', 'recurring_ps_amendment_id', 'export_type', 'ids')));
$columns = array('-1010-first_name' => TTi18n::gettext('First Name'), '-1020-middle_name' => TTi18n::gettext('Middle Name'), '-1030-last_name' => TTi18n::gettext('Last Name'), '-1040-status' => TTi18n::gettext('Status'), '-1050-type' => TTi18n::gettext('Type'), '-1060-pay_stub_account_name' => TTi18n::gettext('Account'), '-1070-effective_date' => TTi18n::gettext('Effective Date'), '-1080-amount' => TTi18n::gettext('Amount'), '-1090-rate' => TTi18n::gettext('Rate'), '-1100-units' => TTi18n::gettext('Units'), '-1110-description' => TTi18n::gettext('Description'), '-1120-ytd_adjustment' => TTi18n::gettext('YTD'));
if ($saved_search_id == '' and !isset($filter_data['columns'])) {
    //Default columns.
    $filter_data['columns'] = array('-1010-first_name', '-1030-last_name', '-1040-status', '-1060-pay_stub_account_name', '-1070-effective_date', '-1080-amount', '-1110-description');
    if ($sort_column == '') {
        $sort_column = $filter_data['sort_column'] = 'effective_date';
        $sort_order = $filter_data['sort_order'] = 'desc';
    }
}
$ugdlf = TTnew('UserGenericDataListFactory');
$ugdf = TTnew('UserGenericDataFactory');
$pplf = TTnew('PayPeriodListFactory');
//Get Permission Hierarchy Children first, as this can be used for viewing, or editing.
$hlf = TTnew('HierarchyListFactory');
$permission_children_ids = $hlf->getHierarchyChildrenByCompanyIdAndUserIdAndObjectTypeID($current_company->getId(), $current_user->getId());
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:PayStubAmendmentList.php


示例14: extract

 * $Id: UserRequestList.php 4207 2011-02-02 00:54:08Z ipso $
 * $Date: 2011-02-01 16:54:08 -0800 (Tue, 01 Feb 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('request', 'enabled') or !($permission->Check('request', 'view') or $permission->Check('request', 'view_own') or $permission->Check('request', 'view_child'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Request List'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'page', 'sort_column', 'sort_order', 'filter_user_id', 'filter_start_date', 'filter_end_date', 'ids')));
URLBuilder::setURL($_SERVER['SCRIPT_NAME'], array('filter_user_id' => $filter_user_id, 'filter_start_date' => $filter_start_date, 'filter_end_date' => $filter_end_date, 'sort_column' => $sort_column, 'sort_order' => $sort_order, 'page' => $page));
$sort_array = NULL;
if ($sort_column != '') {
    $sort_array = array($sort_column => $sort_order);
}
$filter_data = array();
//Get Permission Hierarchy Children first, as this can be used for viewing, or editing.
$permission_children_ids = array();
if ($permission->Check('request', 'view') == FALSE) {
    $hlf = TTnew('HierarchyListFactory');
    $permission_children_ids = $hlf->getHierarchyChildrenByCompanyIdAndUserIdAndObjectTypeID($current_company->getId(), $current_user->getId());
    if ($permission->Check('request', 'view_child') == FALSE) {
        $permission_children_ids = array();
    }
    if ($permission->Check('request', 'view_own')) {
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:UserRequestList.php


示例15: extract

 * $Date: 2009-07-31 13:50:37 -0700 (Fri, 31 Jul 2009) $
 */
require_once '../../includes/global.inc.php';
//Debug::setVerbosity(11);
$skip_message_check = TRUE;
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('punch', 'enabled') or !($permission->Check('punch', 'edit') or $permission->Check('punch', 'edit_own') or $permission->Check('punch', 'edit_child'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'Edit Punch'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'id', 'punch_control_id', 'user_id', 'date_stamp', 'status_id', 'pc_data')));
$punch_full_time_stamp = NULL;
if (isset($pc_data)) {
    if ($pc_data['date_stamp'] != '' and $pc_data['time_stamp'] != '') {
        $punch_full_time_stamp = TTDate::parseDateTime($pc_data['date_stamp'] . ' ' . $pc_data['time_stamp']);
        $pc_data['punch_full_time_stamp'] = $punch_full_time_stamp;
        $pc_data['time_stamp'] = $punch_full_time_stamp;
    } else {
        $pc_data['punch_full_time_stamp'] = NULL;
    }
    if ($pc_data['date_stamp'] != '') {
        $pc_data['date_stamp'] = TTDate::parseDateTime($pc_data['date_stamp']);
    }
}
$pcf = new PunchControlFactory();
$pf = new PunchFactory();
开发者ID:J-P-Hanafin,项目名称:TimeTrex-1,代码行数:31,代码来源:EditPunch.php


示例16: redirectMobileBrowser

 static function redirectMobileBrowser()
 {
     //FIXME: Add GET parameter override to prevent any redirection from happening.
     //Set mobile=1
     extract(FormVariables::GetVariables(array('desktop')));
     if (getTTProductEdition() != TT_PRODUCT_COMMUNITY and $desktop != 1) {
         $browser = self::detectMobileBrowser();
         if ($browser == 'ios') {
             Redirect::Page(URLBuilder::getURL(NULL, Environment::getBaseURL() . '/iphone/punch/punch.php'));
         } elseif ($browser == 'html5' or $browser == 'android') {
             Redirect::Page(URLBuilder::getURL(NULL, Environment::getBaseURL() . '/quick_punch/QuickPunchLogin.php'));
         } elseif ($browser == 'wap') {
             Redirect::Page(URLBuilder::getURL(NULL, Environment::getBaseURL() . '/wap/WAPPunch.php'));
         }
     } else {
         Debug::Text('Desktop browser override: ' . (int) $desktop, __FILE__, __LINE__, __METHOD__, 10);
     }
     return FALSE;
 }
开发者ID:alachaum,项目名称:timetrex,代码行数:19,代码来源:Misc.class.php


示例17: extract

	</head>
	<body>

	<div align="center">
	<?php 
    echo $progress_bar->toHtml();
}
/*
 *
 * END Progress Bar Header...
 *
 */
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'next_page', 'pay_period_ids', 'filter_user_id', 'pay_stub_ids', 'data')));
Debug::text('Next Page: ' . $next_page, __FILE__, __LINE__, __METHOD__, 10);
$ppf = TTnew('PayPeriodFactory');
$action = strtolower($action);
switch ($action) {
    case 'recalculate_company':
    case 'recalculate_employee':
        Debug::text('Recalculating Employee Timesheet: User ID: ' . $filter_user_id . ' Pay Period ID: ' . $pay_period_ids, __FILE__, __LINE__, __METHOD__, 10);
        //Debug::setVerbosity(11);
        //Make sure pay period is not CLOSED.
        //We can re-calc on locked though.
        $pplf = TTnew('PayPeriodListFactory');
        $pplf->getById($pay_period_ids);
        if ($pplf->getRecordCount() > 0) {
            $pp_obj = $pplf->getCurrent();
            if ($pp_obj->getStatus() != 20) {
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:ProgressBar.php


示例18: extract

 * $Id: EditHierarchyControl.php 4919 2011-07-03 23:01:01Z ipso $
 * $Date: 2011-07-03 16:01:01 -0700 (Sun, 03 Jul 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('hierarchy', 'enabled') or !($permission->Check('hierarchy', 'edit') or $permission->Check('hierarchy', 'edit_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
//Debug::setVerbosity(11);
$smarty->assign('title', TTi18n::gettext($title = 'Edit Hierarchy List'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'ids', 'hierarchy_control_id', 'hierarchy_control_data', 'hierarchy_level_data')));
$hcf = TTnew('HierarchyControlFactory');
$hlf = TTnew('HierarchyLevelFactory');
$action = Misc::findSubmitButton();
switch ($action) {
    case 'submit':
        //Debug::setVerbosity(11);
        Debug::Text('Submit!', __FILE__, __LINE__, __METHOD__, 10);
        $redirect = 0;
        $hcf->StartTransaction();
        //Since this class has sub-classes, when creating a new row make sure we have the ID set.
        if (isset($hierarchy_control_data['id']) and $hierarchy_control_data['id'] > 0) {
            $hcf->setId($hierarchy_control_data['id']);
        } else {
            $hcf->setID($hcf->getNextInsertId());
        }
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:EditHierarchyControl.php


示例19: extract

 * $Id: ViewHierarchy.php 4104 2011-01-04 19:04:05Z ipso $
 * $Date: 2011-01-04 11:04:05 -0800 (Tue, 04 Jan 2011) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
if (!$permission->Check('hierarchy', 'enabled') or !($permission->Check('hierarchy', 'view') or $permission->Check('hierarchy', 'view_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'View Hierarchy'));
// See index.php
BreadCrumb::setCrumb($title);
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'hierarchy_id', 'id')));
switch ($action) {
    default:
        if (isset($id)) {
            $hlf = TTnew('HierarchyListFactory');
            $tmp_id = $id;
            $i = 0;
            do {
                Debug::Text(' Iteration...', __FILE__, __LINE__, __METHOD__, 10);
                $parents = $hlf->getParentLevelIdArrayByHierarchyControlIdAndUserId($hierarchy_id, $tmp_id);
                $level = $hlf->getFastTreeObject()->getLevel($tmp_id) - 1;
                if (is_array($parents) and count($parents) > 0) {
                    $parent_users = array();
                    foreach ($parents as $user_id) {
                        //Get user information
                        $ulf = TTnew('UserListFactory');
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:ViewHierarchy.php


示例20: extract

 * $Id: ViewRequest.php 7628 2012-09-12 19:21:29Z ipso $
 * $Date: 2012-09-12 12:21:29 -0700 (Wed, 12 Sep 2012) $
 */
require_once '../../includes/global.inc.php';
require_once Environment::getBasePath() . 'includes/Interface.inc.php';
//Debug::setVerbosity(11);
if (!$permission->Check('request', 'enabled') or !($permission->Check('request', 'edit') or $permission->Check('request', 'edit_own'))) {
    $permission->Redirect(FALSE);
    //Redirect
}
$smarty->assign('title', TTi18n::gettext($title = 'View Request'));
// See index.php
/*
 * Get FORM variables
 */
extract(FormVariables::GetVariables(array('action', 'id', 'hierarchy_type_id', 'request_id', 'request_queue_ids', 'selected_level')));
if (isset($request_queue_ids)) {
    $request_queue_ids = unserialize(base64_decode(urldecode($request_queue_ids)));
    Debug::Arr($request_queue_ids, ' Input Request Queue IDs ' . $action, __FILE__, __LINE__, __METHOD__, 10);
}
if (isset($data)) {
    $data['date_stamp'] = TTDate::parseDateTime($data['date_stamp']);
}
$rf = TTnew('RequestFactory');
$action = Misc::findSubmitButton();
switch ($action) {
    case 'pass':
        if (count($request_queue_ids) > 1) {
            //Remove the authorized/declined request from the stack.
            array_shift($request_queue_ids);
            Redirect::Page(URLBuilder::getURL(array('id' => $request_queue_ids[0], 'selected_level' => $selected_level, 'request_queue_ids' => base64_encode(serialize($request_queue_ids))), 'ViewRequest.php'));
开发者ID:alachaum,项目名称:timetrex,代码行数:31,代码来源:ViewRequest.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Form_Button类代码示例发布时间:2022-05-23
下一篇:
PHP FormValidator类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap