本文整理汇总了PHP中select::get_link方法的典型用法代码示例。如果您正苦于以下问题:PHP select::get_link方法的具体用法?PHP select::get_link怎么用?PHP select::get_link使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类select
的用法示例。
在下文中一共展示了select::get_link方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: showrecords
function showrecords()
{
global $Ticket_Number, $name, $tts, $prefix, $hlpdsk_prefix, $hlpdsk_theme, $nuke_user_table, $nuke_user_last_name_fieldname, $nuke_username_fieldname, $hours, $mins, $javascript, $nuke_user_id_fieldname, $nuke_user_first_name_fieldname, $datepicker, $cmdOk, $cmdReset, $GO_SECURITY, $acl_read, $acl_write, $GO_LANGUAGE;
require $GO_LANGUAGE->get_language_file('opentts');
$acl_read = get_cross_value("{$prefix}{$hlpdsk_prefix}_tickets", 'acl_read', "where ticket_number='{$Ticket_Number}'");
$acl_write = get_cross_value("{$prefix}{$hlpdsk_prefix}_tickets", 'acl_write', "where ticket_number='{$Ticket_Number}'");
if ($GO_SECURITY->user_in_acl(whoami(), $acl_read) or $GO_SECURITY->user_in_acl(whoami(), $acl_write) or Security::is_action_allowed("view_all_tickets")) {
$query_condition = " ";
} else {
$query_condition = " and (t_from='" . whoami() . "' or t_assigned='" . whoami() . "')";
}
$querytext = "select * from {$prefix}{$hlpdsk_prefix}_tickets where Ticket_Number='{$Ticket_Number}' {$query_condition} ";
$tts->query($querytext);
$recordcount = $tts->num_rows();
$row = 0;
if ($recordcount = 0) {
return 'missing';
}
while ($tts->next_record()) {
$post_date = $tts->f('post_date');
$due_date = $tts->f('due_date');
$end_date = $tts->f('end_date');
$complete = $tts->f('complete');
$t_from = $tts->f('t_from');
$t_stage = $tts->f('t_stage');
$t_category = $tts->f('t_category');
$t_priority = $tts->f('t_priority');
$t_subject = htmlspecialchars($tts->f('t_subject'));
$t_description = htmlspecialchars($tts->f('t_description'));
#$t_description=str_replace("\n"," <br> ",$t_description);
$t_assigned = $tts->f('t_assigned');
$t_email = $tts->f('t_email');
$t_sms = $tts->f('t_sms');
$t_status = $tts->f('t_status');
$change_date = htmlspecialchars($tts->f('change_date'));
$activity_id = $tts->f('activity_id');
$project_id = $tts->f('project_id');
$due_date = date("Y/m/d H:i", $due_date);
$end_date = date("Y/m/d H:i", $end_date);
$action_changes = $javascript;
if ($t_sms == "on") {
$t_sms = " CHECKED";
}
if ($t_email == "on") {
$t_email = " CHECKED";
}
if ($GO_SECURITY->user_in_acl(whoami(), $acl_write)) {
$button = new button();
$action_changes .= $button->get_button($cmdOk, "javascript:document.change_status.submit()");
$action_changes .= $button->get_button($cmdReset, "javascript:document.change_status.reset()");
} else {
$action_changes .= '';
}
$action_changes .= "</form></center>";
$tts_lang_ticket_number = "Ticket Number:";
$tts_lang_post_date_value = date("{$_SESSION['GO_SESSION']['date_format']} H:i", $post_date);
$fullname = opentts::get_fullname($t_from);
if (Security::is_action_allowed("imperson", 0, $acl_write)) {
$select = new select('user', 'change_status', 't_from', $t_from);
$tts_lang_issuer = $select->get_link("{$tts_lang_issuer}");
$tts_lang_issuer_value = $select->get_field();
} else {
$tts_lang_issuer_value = "{$fullname}";
}
$stage_name = Security::htmlsecure(get_cross_value("{$prefix}{$hlpdsk_prefix}_stages", "stage_name", " where stage_id='{$t_stage}'"));
$category_name = Security::htmlsecure(get_cross_value("{$prefix}{$hlpdsk_prefix}_categories", "category_name", " where category_id='{$t_category}'"));
$project_name = Security::htmlsecure(get_cross_value("{$prefix}{$hlpdsk_prefix}_projects", "project_name", " where project_id='{$project_id}'"));
$select_complete = "<select name='complete' class=textbox>" . "<option value='0' >0%</option>" . "<option value='10'>10%</option>" . "<option value='20'>20%</option>" . "<option value='30'>30%</option>" . "<option value='40'>40%</option>" . "<option value='50'>50%</option>" . "<option value='60'>60%</option>" . "<option value='70'>70%</option>" . "<option value='80'>80%</option>" . "<option value='90'>90%</option>" . "<option value='100'>100%</option>" . "</select>";
$t_assigned_name = Security::whatsmyname($t_assigned);
if (Security::is_action_allowed("change_subject", 0, $acl_write)) {
$tts_lang_subject_value = "<input name=t_subject value=\"" . Security::sqlsecure($t_subject) . "\" class=textbox max=80 size=80>";
} else {
$tts_lang_subject_value = "<input name=t_subject value=\"" . Security::sqlsecure($t_subject) . "\" class=textbox max=80 size=80 readonly>";
}
$tts_lang_description_value = "<textarea name=t_description cols=80 rows=12 class=textbox readonly>" . Security::sqlsecure($t_description) . "</textarea>";
$tts_lang_change_date_VALUE = date("{$_SESSION['GO_SESSION']['date_format']} H:i", $change_date);
$tts_lang_email = "Email {$tts_lang_issuer}: <input type=checkbox name=t_email_issuer value=1><br>Email {$tts_lang_assigned} <input type=checkbox name=t_email_agent value=1>";
$post_changes = "<form name=\"change_status\" method=\"POST\" action=\"change_ticket.php?Ticket_Number={$Ticket_Number}&func=change_status\">";
if (Security::is_action_allowed("change_project", 0, $acl_write)) {
$project_name = select_option("{$project_id}", fill_select("project_id", "{$prefix}{$hlpdsk_prefix}_projects", "project_id", "project_name", " order by project_id"));
$tts_lang_project_value = "{$project_name}";
} else {
$project_name = Security::htmlsecure(get_cross_value("{$prefix}{$hlpdsk_prefix}_projects", "project_name", " where project_id='{$project_id}'"));
$tts_lang_project_value = "{$project_name}";
}
$fullname = opentts::get_fullname($t_assigned);
if (Security::is_action_allowed("change_assigned", 0, $acl_write)) {
$select = new select('user', 'change_status', 't_assigned', $t_assigned);
$tts_lang_assign_to = $select->get_link("{$tts_lang_assign_to}");
$tts_lang_assign_to_value = $select->get_field();
} else {
$tts_lang_assign_to_value = "{$fullname}";
}
if (Security::is_action_allowed("change_end_date", 0, $acl_write)) {
$time = strtotime($end_date);
#$end_date_d_m_y=date("Y/m/d",$time);
$end_date_h = date("H", $time);
$end_date_i = date("i", $time);
$today = date($_SESSION['GO_SESSION']['date_format'], $time);
$end_date = $datepicker->get_date_picker('end_date_d_m_y', $_SESSION['GO_SESSION']['date_format'], $today);
//.........这里部分代码省略.........
示例2: date
$end_date_h = $due_date_h = date("H", $time);
$end_date_i = $due_date_i = round(date("i", $time) / 100, 1) * 100;
$complete = "<select name='complete' class=textbox>" . "<option value='0'>0%</option>" . "<option value='10'>10%</option>" . "<option value='20'>20%</option>" . "<option value='30'>30%</option>" . "<option value='40'>40%</option>" . "<option value='50'>50%</option>" . "<option value='60'>60%</option>" . "<option value='70'>70%</option>" . "<option value='80'>80%</option>" . "<option value='90'>90%</option>" . "<option value='100'>100%</option>" . "</select>";
$t_categories = fill_select("t_category", "{$prefix}{$hlpdsk_prefix}_categories", "category_id", "category_name", " order by category_name");
$t_priorities = fill_select("t_priority", "{$prefix}{$hlpdsk_prefix}_priorities", "priority_id", "priority_name", " ");
$project_id = fill_select("project_id", "{$prefix}{$hlpdsk_prefix}_projects", "project_id", "project_name", " order by project_id");
if (Security::is_action_allowed("imperson")) {
$select = new select('user', 'new_ticket', 't_from', whoami());
$tts_lang_issuer_value = $select->get_link("{$tts_lang_issuer}");
$tts_lang_issuer_value = $select->get_field();
} else {
$tts_lang_issuer_value = opentts::get_fullname(whoami());
}
if (Security::is_action_allowed("set_assigned")) {
$select = new select('user', 'new_ticket', 't_assigned', whoami());
$tts_lang_assign_to = $select->get_link("{$tts_lang_assign_to}");
$tts_lang_assign_to_value = $select->get_field();
} else {
$tts_lang_assign_to_value = "{$t_from}";
}
$tts_lang_category_value = "{$t_categories}";
$tts_lang_subject_value = "<INPUT class=textbox name=t_subject style=\"HEIGHT: 22px; WIDTH: 400px\" value=\"\">";
$tts_lang_description_value = "<textarea class=textbox name=t_description cols=80 rows=12></textarea>";
if (Security::is_action_allowed("set_priority")) {
$tts_lang_priority_value = "{$t_priorities}";
} else {
$tts_lang_priority_value = "";
}
if (Security::is_action_allowed("set_project")) {
$tts_lang_project_value = "{$project_id}";
} else {