?>
</textarea>
	</td>
</tr>
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category">
		<?php 
echo lang_get('released');
?>
	</td>
	<td>
		<input type="checkbox" name="released" <?php 
check_checked($t_version->released, VERSION_RELEASED);
?>
 />
	</td>
</tr>
<tr>
	<td>
		&nbsp;
	</td>
	<td>
		<input type="submit" class="button" value="<?php 
echo lang_get('update_version_button');
?>
" />
	</td>
</tr>
Пример #2
0
/**
 * Print plugin filter fields as defined by MantisFilter objects.
 * @param string $p_field_name    Field name.
 * @param object $p_filter_object Filter object.
 * @return void
 */
function print_filter_plugin_field($p_field_name, $p_filter_object)
{
    global $g_select_modifier, $g_filter, $f_view_type;
    $t_size = (int) $p_filter_object->size;
    switch ($p_filter_object->type) {
        case FILTER_TYPE_STRING:
            echo '<input name="', string_attribute($p_field_name), '"', $t_size > 0 ? ' size="' . $t_size . '"' : '', ' value="', string_attribute($g_filter[$p_field_name]), '"/>';
            break;
        case FILTER_TYPE_INT:
            echo '<input name="', string_attribute($p_field_name), '"', $t_size > 0 ? ' size="' . $t_size . '"' : '', ' value="', (int) $g_filter[$p_field_name], '"/>';
            break;
        case FILTER_TYPE_BOOLEAN:
            echo '<input name="', string_attribute($p_field_name), '" type="checkbox"', $t_size > 0 ? ' size="' . $t_size . '"' : '', check_checked((bool) $g_filter[$p_field_name]), '"/>';
            break;
        case FILTER_TYPE_MULTI_STRING:
            echo '<select', $g_select_modifier, $t_size > 0 ? ' size="' . $t_size . '"' : '', ' name="', string_attribute($p_field_name), '[]">', '<option value="', META_FILTER_ANY, '"', check_selected($g_filter[$p_field_name], META_FILTER_ANY), '>[', lang_get('any'), ']</option>';
            foreach ($p_filter_object->options() as $t_option_value => $t_option_name) {
                echo '<option value="', string_attribute($t_option_value), '" ', check_selected($g_filter[$p_field_name], $t_option_value), '>', string_display_line($t_option_name), '</option>';
            }
            echo '</select>';
            break;
        case FILTER_TYPE_MULTI_INT:
            echo '<select', $g_select_modifier, $t_size > 0 ? ' size="' . $t_size . '"' : '', ' name="', string_attribute($p_field_name), '[]">', '<option value="', META_FILTER_ANY, '"', check_selected($g_filter[$p_field_name], META_FILTER_ANY), '>[', lang_get('any'), ']</option>';
            foreach ($p_filter_object->options() as $t_option_value => $t_option_name) {
                echo '<option value="', (int) $t_option_value, '" ', check_selected($g_filter[$p_field_name], (int) $t_option_value), '>', string_display_line($t_option_name), '</option>';
            }
            echo '</select>';
            break;
    }
}
Пример #3
0
	</tr>
<?php 
}
?>
	<tr>
		<th class="category">
			<?php 
print_documentation_link('report_stay');
?>
		</th>
		<td>
			<label><input <?php 
echo helper_get_tab_index();
?>
 type="checkbox" id="report_stay" name="report_stay" <?php 
check_checked($f_report_stay);
?>
 /> <?php 
echo lang_get('check_report_more_bugs');
?>
</label>
		</td>
	</tr>
	<tr>
		<td class="left">
			<span class="required"> * <?php 
echo lang_get('required');
?>
</span>
		</td>
		<td class="center">
Пример #4
0
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for=""><span><?php echo lang_get( 'post_to' ) ?></span></label>
				<span class="select">
					<select name="project_id"><?php
						$t_sitewide = false;
						if ( current_user_is_administrator() ) {
							$t_sitewide = true;
						}
						print_project_option_list( $v_project_id, $t_sitewide ); ?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for="news-update-announcement"><span><?php echo lang_get( 'announcement' ) ?></span> <span class="help-text"><?php echo lang_get( 'stays_on_top' ) ?></span></label>
				<span class="checkbox"><input type="checkbox" id="news-update-announcement" name="announcement" <?php check_checked( $v_announcement, 1 ); ?> /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for=""><span><?php echo lang_get( 'view_status' ) ?></span></label>
				<span class="select">
					<select name="view_state">
						<?php print_enum_string_option_list( 'view_state', $v_view_state ) ?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>
			<span class="submit-button"><input type="submit" class="button" value="<?php echo lang_get( 'update_news_button' ) ?>" /></span>
		</fieldset>
	</form>
</div><?php
Пример #5
0
/**
 * Display html form to edit account preferences
 *
 * @param integer $p_user_id            A valid user identifier.
 * @param boolean $p_error_if_protected Whether to error if the account is protected.
 * @param boolean $p_accounts_menu      Display account preferences menu.
 * @param string  $p_redirect_url       Redirect URI.
 * @return void
 */
function edit_account_prefs($p_user_id = null, $p_error_if_protected = true, $p_accounts_menu = true, $p_redirect_url = '')
{
    if (null === $p_user_id) {
        $p_user_id = auth_get_current_user_id();
    }
    $t_redirect_url = $p_redirect_url;
    if (is_blank($t_redirect_url)) {
        $t_redirect_url = 'account_prefs_page.php';
    }
    # protected account check
    if (user_is_protected($p_user_id)) {
        if ($p_error_if_protected) {
            trigger_error(ERROR_PROTECTED_ACCOUNT, ERROR);
        } else {
            return;
        }
    }
    $t_pref = user_pref_get($p_user_id);
    # Account Preferences Form BEGIN
    ?>

<div id="account-prefs-update-div" class="form-container">
	<form id="account-prefs-update-form" method="post" action="account_prefs_update.php">
		<fieldset>
			<legend><span><?php 
    echo lang_get('default_account_preferences_title');
    ?>
</span></legend>
			<?php 
    echo form_security_field('account_prefs_update');
    ?>
			<input type="hidden" name="user_id" value="<?php 
    echo $p_user_id;
    ?>
" />
			<input type="hidden" name="redirect_url" value="<?php 
    echo $t_redirect_url;
    ?>
" />
		<?php 
    if ($p_accounts_menu) {
        print_account_menu('account_prefs_page.php');
    }
    ?>
			<div class="field-container">
				<label for="default-project-id"><span><?php 
    echo lang_get('default_project');
    ?>
</span></label>
				<span class="select">
					<select id="default-project-id" name="default_project">
<?php 
    # Count number of available projects
    $t_projects = current_user_get_accessible_projects();
    $t_num_proj = count($t_projects);
    if ($t_num_proj == 1) {
        $t_num_proj += count(current_user_get_accessible_subprojects($t_projects[0]));
    }
    # Don't display "All projects" in selection list if there is only 1
    print_project_option_list((int) $t_pref->default_project, $t_num_proj != 1);
    ?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="refresh-delay"><span><?php 
    echo lang_get('refresh_delay');
    ?>
</span></label>
				<span class="input"><input id="refresh-delay" type="text" name="refresh_delay" size="4" maxlength="4" value="<?php 
    echo $t_pref->refresh_delay;
    ?>
" /> <?php 
    echo lang_get('minutes');
    ?>
</span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="redirect-delay"><span><?php 
    echo lang_get('redirect_delay');
    ?>
</span></label>
				<span class="input"><input id="redirect-delay" type="text" name="redirect_delay" size="4" maxlength="3" value="<?php 
    echo $t_pref->redirect_delay;
    ?>
" /> <?php 
    echo lang_get('seconds');
    ?>
</span>
				<span class="label-style"></span>
			</div>
			<fieldset class="field-container">
				<legend><span><?php 
    echo lang_get('bugnote_order');
    ?>
</span></legend>
				<span class="radio"><input id="bugnote-order-desc" type="radio" name="bugnote_order" value="DESC" <?php 
    check_checked($t_pref->bugnote_order, 'DESC');
    ?>
 /></span>
				<label for="bugnote-order-desc"><span><?php 
    echo lang_get('bugnote_order_desc');
    ?>
</span></label>
				<span class="radio"><input id="bugnote-order-asc" type="radio" name="bugnote_order" value="ASC" <?php 
    check_checked($t_pref->bugnote_order, 'ASC');
    ?>
 /></span>
				<label for="bugnote-order-asc"><span><?php 
    echo lang_get('bugnote_order_asc');
    ?>
</span></label>
				<span class="label-style"></span>
			</fieldset>
			<?php 
    if (ON == config_get('enable_email_notification')) {
        ?>
			<fieldset class="field-container">
				<legend><label for="email-on-new"><?php 
        echo lang_get('email_on_new');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-new" type="checkbox" name="email_on_new" <?php 
        check_checked((int) $t_pref->email_on_new, ON);
        ?>
 /></span>
				<label for="email-on-new-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-new-min-severity" name="email_on_new_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_new_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-assigned"><?php 
        echo lang_get('email_on_assigned');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-assigned" type="checkbox" name="email_on_assigned" <?php 
        check_checked((int) $t_pref->email_on_assigned, ON);
        ?>
 /></span>
				<label for="email-on-assigned-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-assigned-min-severity" name="email_on_assigned_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_assigned_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-feedback"><?php 
        echo lang_get('email_on_feedback');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-feedback" type="checkbox" name="email_on_feedback" <?php 
        check_checked((int) $t_pref->email_on_feedback, ON);
        ?>
 /></span>
				<label for="email-on-feedback-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-feedback-min-severity" name="email_on_feedback_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_feedback_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-resolved"><?php 
        echo lang_get('email_on_resolved');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-resolved" type="checkbox" name="email_on_resolved" <?php 
        check_checked((int) $t_pref->email_on_resolved, ON);
        ?>
 /></span>
				<label for="email-on-resolved-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-resolved-min-severity" name="email_on_resolved_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_resolved_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-closed"><?php 
        echo lang_get('email_on_closed');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-closed" type="checkbox" name="email_on_closed" <?php 
        check_checked((int) $t_pref->email_on_closed, ON);
        ?>
 /></span>
				<label for="email-on-closed-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-closed-min-severity" name="email_on_closed_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_closed_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-reopened"><?php 
        echo lang_get('email_on_reopened');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-reopened" type="checkbox" name="email_on_reopened" <?php 
        check_checked((int) $t_pref->email_on_reopened, ON);
        ?>
 /></span>
				<label for="email-on-reopened-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-reopened-min-severity" name="email_on_reopened_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_reopened_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-bugnote-added"><?php 
        echo lang_get('email_on_bugnote_added');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-bugnote-added" type="checkbox" name="email_on_bugnote" <?php 
        check_checked((int) $t_pref->email_on_bugnote, ON);
        ?>
 /></span>
				<label for="email-on-bugnote-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-bugnote-min-severity" name="email_on_bugnote_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_bugnote_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-status"><?php 
        echo lang_get('email_on_status_change');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-status" type="checkbox" name="email_on_status" <?php 
        check_checked((int) $t_pref->email_on_status, ON);
        ?>
 /></span>
				<label for="email-on-status-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-status-min-severity" name="email_on_status_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_status_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<fieldset class="field-container">
				<legend><label for="email-on-priority-change"><?php 
        echo lang_get('email_on_priority_change');
        ?>
</label></legend>
				<span class="checkbox"><input id="email-on-priority-change" type="checkbox" name="email_on_priority" <?php 
        check_checked((int) $t_pref->email_on_priority, ON);
        ?>
 /></span>
				<label for="email-on-priority-min-severity" class="email-on-severity-label"><span><?php 
        echo lang_get('with_minimum_severity');
        ?>
</span></label>
				<span class="select email-on-severity">
					<select id="email-on-priority-min-severity" name="email_on_priority_min_severity">
						<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
						<option disabled="disabled">-----</option>
						<?php 
        print_enum_string_option_list('severity', (int) $t_pref->email_on_priority_min_severity);
        ?>
					</select>
				</span>
				<span class="label-style"></span>
			</fieldset>
			<div class="field-container">
				<label for="email-bugnote-limit"><span><?php 
        echo lang_get('email_bugnote_limit');
        ?>
</span></label>
				<span class="input"><input id="email-bugnote-limit" type="text" name="email_bugnote_limit" maxlength="2" size="2" value="<?php 
        echo $t_pref->email_bugnote_limit;
        ?>
" /></span>
				<span class="label-style"></span>
			</div>
<?php 
    } else {
        ?>
			<input type="hidden" name="email_on_new"      value="<?php 
        echo $t_pref->email_on_new;
        ?>
" />
			<input type="hidden" name="email_on_assigned" value="<?php 
        echo $t_pref->email_on_assigned;
        ?>
" />
			<input type="hidden" name="email_on_feedback" value="<?php 
        echo $t_pref->email_on_feedback;
        ?>
" />
			<input type="hidden" name="email_on_resolved" value="<?php 
        echo $t_pref->email_on_resolved;
        ?>
" />
			<input type="hidden" name="email_on_closed"   value="<?php 
        echo $t_pref->email_on_closed;
        ?>
" />
			<input type="hidden" name="email_on_reopened" value="<?php 
        echo $t_pref->email_on_reopened;
        ?>
" />
			<input type="hidden" name="email_on_bugnote"  value="<?php 
        echo $t_pref->email_on_bugnote;
        ?>
" />
			<input type="hidden" name="email_on_status"   value="<?php 
        echo $t_pref->email_on_status;
        ?>
" />
			<input type="hidden" name="email_on_priority" value="<?php 
        echo $t_pref->email_on_priority;
        ?>
" />
			<input type="hidden" name="email_on_new_min_severity"      value="<?php 
        echo $t_pref->email_on_new_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_assigned_min_severity" value="<?php 
        echo $t_pref->email_on_assigned_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_feedback_min_severity" value="<?php 
        echo $t_pref->email_on_feedback_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_resolved_min_severity" value="<?php 
        echo $t_pref->email_on_resolved_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_closed_min_severity"   value="<?php 
        echo $t_pref->email_on_closed_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_reopened_min_severity" value="<?php 
        echo $t_pref->email_on_reopened_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_bugnote_min_severity"  value="<?php 
        echo $t_pref->email_on_bugnote_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_status_min_severity"   value="<?php 
        echo $t_pref->email_on_status_min_severity;
        ?>
" />
			<input type="hidden" name="email_on_priority_min_severity" value="<?php 
        echo $t_pref->email_on_priority_min_severity;
        ?>
" />
			<input type="hidden" name="email_bugnote_limit" value="<?php 
        echo $t_pref->email_bugnote_limit;
        ?>
" />
<?php 
    }
    ?>
			<div class="field-container">
				<label for="timezone"><span><?php 
    echo lang_get('timezone');
    ?>
</span></label>
				<span class="select">
					<select id="timezone" name="timezone">
						<?php 
    print_timezone_option_list($t_pref->timezone ? $t_pref->timezone : config_get_global('default_timezone'));
    ?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="language"><span><?php 
    echo lang_get('language');
    ?>
</span></label>
				<span class="select">
					<select id="language" name="language">
						<?php 
    print_language_option_list($t_pref->language);
    ?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>

			<?php 
    event_signal('EVENT_ACCOUNT_PREF_UPDATE_FORM', array($p_user_id));
    ?>
			<span class="submit-button"><input type="submit" class="button" value="<?php 
    echo lang_get('update_prefs_button');
    ?>
" /></span>
		</fieldset>
	</form>
</div>

<div id="account-prefs-reset-div" class="form-container">
	<form id="account-prefs-reset-form" method="post" action="account_prefs_reset.php">
		<fieldset>
			<?php 
    echo form_security_field('account_prefs_reset');
    ?>
			<input type="hidden" name="user_id" value="<?php 
    echo $p_user_id;
    ?>
" />
			<input type="hidden" name="redirect_url" value="<?php 
    echo $t_redirect_url;
    ?>
" />
			<span class="submit-button"><input type="submit" class="button" value="<?php 
    echo lang_get('reset_prefs_button');
    ?>
" /></span>
		</fieldset>
	</form>
</div>

<?php 
}
Пример #6
0
    # spacer
    echo '<tr class="spacer"><td colspan="6"></td></tr>';
    echo '<tr class="hidden"></tr>';
}
# Bugnote Text Box
echo '<tr>';
echo '<th class="category"><label for="bugnote_text">' . lang_get('add_bugnote_title') . '</label></th>';
echo '<td colspan="5"><textarea ', helper_get_tab_index(), ' id="bugnote_text" name="bugnote_text" cols="80" rows="10"></textarea></td></tr>';
# Bugnote Private Checkbox (if permitted)
if (access_has_bug_level(config_get('private_bugnote_threshold'), $t_bug_id)) {
    echo '<tr>';
    echo '<th class="category">' . lang_get('private') . '</th>';
    echo '<td colspan="5">';
    $t_default_bugnote_view_status = config_get('default_bugnote_view_status');
    if (access_has_bug_level(config_get('set_view_status_threshold'), $t_bug_id)) {
        echo '<input ', helper_get_tab_index(), ' type="checkbox" id="private" name="private" ', check_checked(config_get('default_bugnote_view_status'), VS_PRIVATE), ' />';
        echo lang_get('private');
    } else {
        echo get_enum_element('view_state', $t_default_bugnote_view_status);
    }
    echo '</td></tr>';
}
# Time Tracking (if permitted)
if (config_get('time_tracking_enabled')) {
    if (access_has_bug_level(config_get('time_tracking_edit_threshold'), $t_bug_id)) {
        echo '<tr>';
        echo '<th class="category"><label for="time_tracking">' . lang_get('time_tracking') . '</label></th>';
        echo '<td colspan="5"><input type="text" id="time_tracking" name="time_tracking" size="5" placeholder="hh:mm" /></td></tr>';
    }
}
event_signal('EVENT_BUGNOTE_ADD_FORM', array($t_bug_id));
Пример #7
0
	</td>
</tr>

<!-- Protected Checkbox -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category">
		<?php 
echo lang_get('protected');
?>
	</td>
	<td>
		<input type="checkbox" name="protected" <?php 
check_checked($t_user['protected'], ON);
?>
 />
	</td>
</tr>

<!-- Submit Button -->
<tr>
	<td colspan="2" class="center">
	<?php 
if (config_get('enable_email_notification') == ON) {
    echo lang_get('notify_user');
    ?>
		<input type="checkbox" name="send_email_notification" checked />
	<?php 
}
Пример #8
0
print_project_option_list($v_project_id, $t_sitewide);
?>
					</select>
				</span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="news-update-announcement"><span><?php 
echo lang_get('announcement');
?>
</span> <span class="help-text"><?php 
echo lang_get('stays_on_top');
?>
</span></label>
				<span class="checkbox"><input type="checkbox" id="news-update-announcement" name="announcement" <?php 
check_checked((int) $v_announcement, 1);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for=""><span><?php 
echo lang_get('view_status');
?>
</span></label>
				<span class="select">
					<select name="view_state">
						<?php 
print_enum_string_option_list('view_state', $v_view_state);
?>
					</select>
?>
</span></label>
				<span class="checkbox"><input id="edit-enabled" type="checkbox" name="enabled" <?php 
check_checked((int) $t_user['enabled'], ON);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<!-- Protected Checkbox -->
			<div class="field-container">
				<label for="edit-protected"><span><?php 
echo lang_get('protected_label');
?>
</span></label>
				<span class="checkbox"><input id="edit-protected" type="checkbox" name="protected" <?php 
check_checked((int) $t_user['protected'], ON);
?>
 /></span>
				<span class="label-style"></span>
			</div><?php 
if (config_get('enable_email_notification') == ON) {
    echo '<div class="field-container">';
    echo '<label for="send-email"><span>' . lang_get('notify_user') . '</span></label>';
    echo '<span class="checkbox"><input id="send-email" type="checkbox" name="send_email_notification" checked="checked" /></span>';
    echo '<span class="label-style"></span>';
    echo '</div>';
}
?>
			<!-- Submit Button -->
			<span class="submit-button"><input type="submit" class="button" value="<?php 
echo lang_get('update_user_button');
	</td>
</tr>

<!-- Enabled -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category">
		<?php 
echo lang_get('enabled');
?>
	</td>
	<td>
		<input type="checkbox" name="enabled" <?php 
check_checked($row['enabled'], ON);
?>
 />
	</td>
</tr>

<!-- View Status (public/private) -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category">
		<?php 
echo lang_get('view_status');
?>
	</td>
Пример #11
0
echo $c_dir;
?>
" />
			<input type="hidden" name="save" value="1" />
			<input type="hidden" name="filter" value="<?php 
echo $c_filter;
?>
" />
			<input type="checkbox" name="hideinactive" value="1" <?php 
check_checked((int) $c_hide_inactive, 1);
?>
 /> <?php 
echo lang_get('hide_inactive');
?>
			<input type="checkbox" name="showdisabled" value="1" <?php 
check_checked((int) $c_show_disabled, 1);
?>
 /> <?php 
echo lang_get('show_disabled');
?>
			<input type="submit" class="button" value="<?php 
echo lang_get('filter_button');
?>
" />
		</fieldset>
	</form>

	<table>
		<thead>
			<tr class="row-category">
<?php 
Пример #12
0
<?php 
    if (access_has_project_level(config_get('private_bugnote_threshold'), $t_project_id)) {
        ?>
<tr>
	<th class="category">
		<?php 
        echo lang_get('view_status');
        ?>
	</th>
	<td>
<?php 
        $t_default_bugnote_view_status = config_get('default_bugnote_view_status');
        if (access_has_project_level(config_get('set_view_status_threshold'), $t_project_id)) {
            ?>
			<input type="checkbox" name="private" <?php 
            check_checked($t_default_bugnote_view_status, VS_PRIVATE);
            ?>
 />
<?php 
            echo lang_get('private');
        } else {
            echo get_enum_element('project_view_state', $t_default_bugnote_view_status);
        }
        ?>
	</td>
</tr>
<?php 
    }
    ?>

<?php 
Пример #13
0
function print_filter_do_filter_by_date($p_hide_checkbox = false)
{
    global $t_filter;
    ?>
		<table cellspacing="0" cellpadding="0">
		<?php 
    if (!$p_hide_checkbox) {
        ?>
		<tr><td colspan="2">
			<input type="checkbox" name="do_filter_by_date" <?php 
        check_checked($t_filter['do_filter_by_date'], 'on');
        if (ON == config_get('use_javascript')) {
            print "onclick=\"SwitchDateFields();\"";
        }
        ?>
 />
			<?php 
        echo lang_get('use_date_filters');
        ?>
		</td></tr>
		<?php 
    }
    $t_menu_disabled = 'on' == $t_filter['do_filter_by_date'] ? '' : ' disabled ';
    ?>

		<!-- Start date -->
		<tr>
			<td>
			<?php 
    echo lang_get('start_date');
    ?>
:
			</td>
			<td nowrap="nowrap">
			<?php 
    $t_chars = preg_split('//', config_get('short_date_format'), -1, PREG_SPLIT_NO_EMPTY);
    foreach ($t_chars as $t_char) {
        if (strcasecmp($t_char, "M") == 0) {
            print "<select name=\"start_month\" {$t_menu_disabled}>";
            print_month_option_list($t_filter['start_month']);
            print "</select>\n";
        }
        if (strcasecmp($t_char, "D") == 0) {
            print "<select name=\"start_day\" {$t_menu_disabled}>";
            print_day_option_list($t_filter['start_day']);
            print "</select>\n";
        }
        if (strcasecmp($t_char, "Y") == 0) {
            print "<select name=\"start_year\" {$t_menu_disabled}>";
            print_year_option_list($t_filter['start_year']);
            print "</select>\n";
        }
    }
    ?>
			</td>
		</tr>
		<!-- End date -->
		<tr>
			<td>
			<?php 
    echo lang_get('end_date');
    ?>
:
			</td>
			<td>
			<?php 
    $t_chars = preg_split('//', config_get('short_date_format'), -1, PREG_SPLIT_NO_EMPTY);
    foreach ($t_chars as $t_char) {
        if (strcasecmp($t_char, "M") == 0) {
            print "<select name=\"end_month\" {$t_menu_disabled}>";
            print_month_option_list($t_filter['end_month']);
            print "</select>\n";
        }
        if (strcasecmp($t_char, "D") == 0) {
            print "<select name=\"end_day\" {$t_menu_disabled}>";
            print_day_option_list($t_filter['end_day']);
            print "</select>\n";
        }
        if (strcasecmp($t_char, "Y") == 0) {
            print "<select name=\"end_year\" {$t_menu_disabled}>";
            print_year_option_list($t_filter['end_year']);
            print "</select>\n";
        }
    }
    ?>
			</td>
		</tr>
		</table>
		<?php 
}
function print_released($edit_page, $version_index, $version)
{
    echo '<td class="center">';
    if ($edit_page) {
        ?>
      <label for="proj-version-released-<?php 
        echo $version_index;
        ?>
">
      <span class="checkbox"><input type="checkbox" id="proj-version-released-<?php 
        echo $version_index;
        ?>
"
                                    name="released<?php 
        echo $version_index;
        ?>
" <?php 
        check_checked((int) $version['released'], ON);
        ?>
 /></span>
      </label>
      <?php 
    } else {
        echo trans_bool($version['released']);
    }
    echo '</td>';
}
Пример #15
0
		</td>
	</tr>
	<!-- Avatar -->
 	<tr <?php 
echo helper_alternate_class();
?>
>
 		<td class="category">
			<?php 
echo lang_get('use_gravatar');
?>
:
		</td>
		<td>
			<input type="checkbox" name="use_gravatar" <?php 
check_checked($t_use_gravatar, ON);
?>
 />
		</td>
	</tr>
	<tr <?php 
echo helper_alternate_class();
?>
 >
		<td class="category">
			<?php 
echo lang_get('avatar');
?>
:
		</td>
		<td>
Пример #16
0
/**
 * print_custom_field_input
 * @param array $p_field_def          Custom field definition.
 * @param mixed $p_custom_field_value Custom field value.
 * @return void
 */
function cfdef_input_radio(array $p_field_def, $p_custom_field_value)
{
    $t_values = explode('|', custom_field_prepare_possible_values($p_field_def['possible_values']));
    $t_len = strlen($p_custom_field_value);
    if ($t_len >= 2 && $p_custom_field_value[0] == '|' && $p_custom_field_value[$t_len - 1] == '|') {
        $t_checked_value = substr($p_custom_field_value, 1, $t_len - 2);
    } else {
        $t_checked_value = $p_custom_field_value;
    }
    for ($i = 0; $i < count($t_values); $i++) {
        $t_input_id = 'custom_field_' . $p_field_def['id'] . '_value_' . $i;
        $t_input_name = 'custom_field_' . $p_field_def['id'];
        echo '<label class="nowrap">';
        echo '<input id="' . $t_input_id . '" ' . helper_get_tab_index() . ' type="radio" name="' . $t_input_name . '" value="' . string_attribute($t_values[$i]) . '"';
        check_checked($t_checked_value, $t_values[$i]);
        echo " />\n";
        echo string_display_line($t_values[$i]) . '</label>' . "\n";
    }
}
Пример #17
0
print_button('manage_user_create_page.php', lang_get('create_new_account_link'));
?>
	</td>
	<td class="center" colspan="2">
		<form method="post" action="manage_user_page.php">
		<input type="hidden" name="sort" value="<?php 
echo $c_sort;
?>
" />
		<input type="hidden" name="dir" value="<?php 
echo $c_dir;
?>
" />
		<input type="hidden" name="save" value="1" />
		<input type="checkbox" name="hide" value="1" <?php 
check_checked($c_hide, 1);
?>
 /> <?php 
echo lang_get('hide_inactive');
?>
		<input type="submit" class="button" value="<?php 
echo lang_get('filter_button');
?>
" />
		</form>
	</td>
</tr>
<tr class="row-category">
	<td>
		<?php 
print_manage_user_sort_link('manage_user_page.php', lang_get('username'), 'username', $c_dir, $c_sort, $c_hide);
>
	<td class="category">
		<?php 
    echo lang_get('private');
    ?>
	</td>
	<td colspan="5">
<?php 
    $t_default_bugnote_view_status = config_get('default_bugnote_view_status');
    if (access_has_bug_level(config_get('set_view_status_threshold'), $f_bug_id)) {
        ?>
			<input <?php 
        echo helper_get_tab_index();
        ?>
 type="checkbox" name="private" <?php 
        check_checked(config_get('default_bugnote_view_status'), VS_PRIVATE);
        ?>
 />
<?php 
        echo lang_get('private');
    } else {
        echo get_enum_element('view_state', $t_default_bugnote_view_status);
    }
    ?>
	</td>
</tr>
<?php 
}
?>

<!-- Time Tracking (if permitted) -->
Пример #19
0
echo lang_get('sticky');
?>
</td>
	<td class="small-caption" colspan="<?php 
echo 1 * $t_custom_cols;
?>
"><?php 
echo lang_get('changed');
?>
</td>
	<td class="small-caption" colspan="<?php 
echo 3 * $t_custom_cols;
?>
">
		<input type="checkbox" name="do_filter_by_date" <?php 
check_checked($t_filter['do_filter_by_date'], 'on');
if (ON == config_get('use_javascript')) {
    print "onclick=\"SwitchDateFields();\"";
}
?>
 />
		<?php 
echo lang_get('use_date_filters');
?>
	</td>
	<td class="small-caption" colspan="<?php 
echo 1 * $t_custom_cols;
?>
">
		<?php 
echo lang_get('bug_relationships');
echo $c_dir;
?>
" />
		<input type="hidden" name="save" value="1" />
		<input type="hidden" name="filter" value="<?php 
echo $c_filter;
?>
" />
		<input type="checkbox" name="hideinactive" value="1" <?php 
check_checked($c_hide_inactive, 1);
?>
 /> <?php 
echo lang_get('hide_inactive');
?>
		<input type="checkbox" name="showdisabled" value="1" <?php 
check_checked($c_show_disabled, 1);
?>
 /> <?php 
echo lang_get('show_disabled');
?>
		<input type="submit" class="button" value="<?php 
echo lang_get('filter_button');
?>
" />
		</form>
	</td>
</tr>

<tr class="row-category">
<?php 
# Print column headers with sort links
Пример #21
0
print lang_get('query_name_label') . lang_get('word_separator');
?>
<form method="post" action="query_store.php">
<?php 
echo form_security_field('query_store');
?>
<input type="text" name="query_name" /><br />
<?php 
if (access_has_project_level(config_get('stored_query_create_shared_threshold'))) {
    print '<input type="checkbox" name="is_public" value="on" /> ';
    print lang_get('make_public');
    print '<br />';
}
?>
<input type="checkbox" name="all_projects" value="on" <?php 
check_checked(ALL_PROJECTS == helper_get_current_project());
?>
 >
<?php 
print lang_get('all_projects');
?>
<br /><br />
<input type="submit" class="button" value="<?php 
print lang_get('save_query');
?>
" />
</form>
<form action="view_all_bug_page.php">
<?php 
# CSRF protection not required here - form does not result in modifications
?>
Пример #22
0
echo lang_get('enabled');
?>
</span></label>
				<span class="checkbox"><input type="checkbox" id="project-enabled" name="enabled" <?php 
check_checked((int) $row['enabled'], ON);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="project-inherit-global"><span><?php 
echo lang_get('inherit_global');
?>
</span></label>
				<span class="checkbox"><input type="checkbox" id="project-inherit-global" name="inherit_global" <?php 
check_checked((int) $row['inherit_global'], ON);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="project-view-state"><span><?php 
echo lang_get('view_status');
?>
</span></label>
				<span class="select">
					<select id="project-view-state" name="view_state">
						<?php 
print_enum_string_option_list('view_state', (int) $row['view_state']);
?>
					</select>
Пример #23
0
	</td>
</tr>

<!-- Category Inheritance -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<th class="category">
		<?php 
echo lang_get('inherit_global');
?>
	</th>
	<td>
		<input type="checkbox" name="inherit_global" <?php 
check_checked($row['inherit_global'], ON);
?>
 />
	</td>
</tr>

<!-- View Status (public/private) -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<th class="category">
		<?php 
echo lang_get('view_status');
?>
	</th>
?>
 />
	</td>
</tr>
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category">
		<?php 
echo lang_get('obsolete');
?>
	</td>
	<td>
		<input type="checkbox" name="obsolete" <?php 
check_checked($t_version->obsolete, true);
?>
 />
	</td>
</tr>
<?php 
event_signal('EVENT_MANAGE_VERSION_UPDATE_FORM', array($t_version->id));
?>
<tr>
	<td>
		&#160;
	</td>
	<td>
		<input type="submit" class="button" value="<?php 
echo lang_get('update_version_button');
?>
Пример #25
0
function edit_account_prefs($p_user_id = null, $p_error_if_protected = true, $p_accounts_menu = true, $p_redirect_url = '')
{
    if (null === $p_user_id) {
        $p_user_id = auth_get_current_user_id();
    }
    $t_redirect_url = $p_redirect_url;
    if (is_blank($t_redirect_url)) {
        $t_redirect_url = 'account_prefs_page.php';
    }
    # protected account check
    if (user_is_protected($p_user_id)) {
        if ($p_error_if_protected) {
            trigger_error(ERROR_PROTECTED_ACCOUNT, ERROR);
        } else {
            return;
        }
    }
    if (!user_pref_exists($p_user_id)) {
        user_pref_set_default($p_user_id);
    }
    # prefix data with u_
    $t_pref = user_pref_get($p_user_id);
    # Account Preferences Form BEGIN
    ?>
<br />
<div align="center">
<form method="post" action="account_prefs_update.php">
<input type="hidden" name="user_id" value="<?php 
    echo $p_user_id;
    ?>
" />
<input type="hidden" name="redirect_url" value="<?php 
    echo $t_redirect_url;
    ?>
" />
<table class="width75" cellspacing="1">
<tr>
	<td class="form-title">
		<?php 
    echo lang_get('default_account_preferences_title');
    ?>
	</td>
	<td class="right">
		<?php 
    if ($p_accounts_menu) {
        print_account_menu('account_prefs_page.php');
    }
    ?>
	</td>
</tr>
<tr class="row-1">
	<td class="category" width="50%">
		<?php 
    echo lang_get('default_project');
    ?>
	</td>
	<td width="50%">
		<select name="default_project">
			<?php 
    print_project_option_list($t_pref->default_project);
    ?>
		</select>
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
    echo lang_get('advanced_report');
    ?>
	</td>
	<td>
		<input type="checkbox" name="advanced_report" <?php 
    check_checked($t_pref->advanced_report, ON);
    ?>
 />
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
    echo lang_get('advanced_view');
    ?>
	</td>
	<td>
		<input type="checkbox" name="advanced_view" <?php 
    check_checked($t_pref->advanced_view, ON);
    ?>
 />
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
    echo lang_get('advanced_update');
    ?>
	</td>
	<td>
		<input type="checkbox" name="advanced_update" <?php 
    check_checked($t_pref->advanced_update, ON);
    ?>
 />
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
    echo lang_get('refresh_delay');
    ?>
	</td>
	<td>
		<input type="text" name="refresh_delay" size="4" maxlength="4" value="<?php 
    echo $t_pref->refresh_delay;
    ?>
" />
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
    echo lang_get('redirect_delay');
    ?>
	</td>
	<td>
		<input type="text" name="redirect_delay" size="1" maxlength="1" value="<?php 
    echo $t_pref->redirect_delay;
    ?>
" />
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
    echo lang_get('bugnote_order');
    ?>
	</td>
	<td>
		<input type="radio" name="bugnote_order" value="ASC" <?php 
    check_checked($t_pref->bugnote_order, 'ASC');
    ?>
 /><?php 
    echo lang_get('bugnote_order_asc');
    ?>
		<input type="radio" name="bugnote_order" value="DESC" <?php 
    check_checked($t_pref->bugnote_order, 'DESC');
    ?>
 /><?php 
    echo lang_get('bugnote_order_desc');
    ?>
	</td>
</tr>
<?php 
    if (ON == config_get('enable_email_notification')) {
        ?>
<tr class="row-2">
	<td class="category">
		<?php 
        echo lang_get('email_on_new');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_new" <?php 
        check_checked($t_pref->email_on_new, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_new_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_new_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
        echo lang_get('email_on_assigned');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_assigned" <?php 
        check_checked($t_pref->email_on_assigned, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_assigned_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_assigned_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
        echo lang_get('email_on_feedback');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_feedback" <?php 
        check_checked($t_pref->email_on_feedback, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_feedback_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_feedback_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
        echo lang_get('email_on_resolved');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_resolved" <?php 
        check_checked($t_pref->email_on_resolved, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_resolved_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_resolved_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
        echo lang_get('email_on_closed');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_closed" <?php 
        check_checked($t_pref->email_on_closed, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_closed_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_closed_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
        echo lang_get('email_on_reopened');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_reopened" <?php 
        check_checked($t_pref->email_on_reopened, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_reopened_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_reopened_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
        echo lang_get('email_on_bugnote_added');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_bugnote" <?php 
        check_checked($t_pref->email_on_bugnote, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_bugnote_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_bugnote_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
        echo lang_get('email_on_status_change');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_status" <?php 
        check_checked($t_pref->email_on_status, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_status_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_status_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
        echo lang_get('email_on_priority_change');
        ?>
	</td>
	<td>
		<input type="checkbox" name="email_on_priority" <?php 
        check_checked($t_pref->email_on_priority, ON);
        ?>
 />
		<?php 
        echo lang_get('with_minimum_severity');
        ?>
		<select name="email_on_priority_min_severity">
			<option value="<?php 
        echo OFF;
        ?>
"><?php 
        echo lang_get('any');
        ?>
</option>
			<option value="<?php 
        echo OFF;
        ?>
"></option>
			<?php 
        print_enum_string_option_list('severity', $t_pref->email_on_priority_min_severity);
        ?>
		</select>
	</td>
</tr>
<tr class="row-1">
	<td class="category">
		<?php 
        echo lang_get('email_bugnote_limit');
        ?>
	</td>
	<td>
		<input type="text" name="email_bugnote_limit" maxlength="2" size="2" value="<?php 
        echo $t_pref->email_bugnote_limit;
        ?>
">
	</td>
</tr>
<?php 
    } else {
        ?>
		<input type="hidden" name="email_on_new"      value="<?php 
        echo $t_pref->email_on_new;
        ?>
" />
		<input type="hidden" name="email_on_assigned" value="<?php 
        echo $t_pref->email_on_assigned;
        ?>
" />
		<input type="hidden" name="email_on_feedback" value="<?php 
        echo $t_pref->email_on_feedback;
        ?>
" />
		<input type="hidden" name="email_on_resolved" value="<?php 
        echo $t_pref->email_on_resolved;
        ?>
" />
		<input type="hidden" name="email_on_closed"   value="<?php 
        echo $t_pref->email_on_closed;
        ?>
" />
		<input type="hidden" name="email_on_reopened" value="<?php 
        echo $t_pref->email_on_reopened;
        ?>
" />
		<input type="hidden" name="email_on_bugnote"  value="<?php 
        echo $t_pref->email_on_bugnote;
        ?>
" />
		<input type="hidden" name="email_on_status"   value="<?php 
        echo $t_pref->email_on_status;
        ?>
" />
		<input type="hidden" name="email_on_priority" value="<?php 
        echo $t_pref->email_on_priority;
        ?>
" />
		<input type="hidden" name="email_on_new_min_severity"      value="<?php 
        echo $t_pref->email_on_new_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_assigned_min_severity" value="<?php 
        echo $t_pref->email_on_assigned_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_feedback_min_severity" value="<?php 
        echo $t_pref->email_on_feedback_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_resolved_min_severity" value="<?php 
        echo $t_pref->email_on_resolved_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_closed_min_severity"   value="<?php 
        echo $t_pref->email_on_closed_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_reopened_min_severity" value="<?php 
        echo $t_pref->email_on_reopened_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_bugnote_min_severity"  value="<?php 
        echo $t_pref->email_on_bugnote_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_status_min_severity"   value="<?php 
        echo $t_pref->email_on_status_min_severity;
        ?>
" />
		<input type="hidden" name="email_on_priority_min_severity" value="<?php 
        echo $t_pref->email_on_priority_min_severity;
        ?>
" />
		<input type="hidden" name="email_bugnote_limit" value="<?php 
        echo $t_pref->email_bugnote_limit;
        ?>
" />
<?php 
    }
    ?>
<tr class="row-2">
	<td class="category">
		<?php 
    echo lang_get('language');
    ?>
	</td>
	<td>
		<select name="language">
			<?php 
    print_language_option_list($t_pref->language);
    ?>
		</select>
	</td>
</tr>
<tr>
	<td colspan="2" class="center">
		<input type="submit" class="button" value="<?php 
    echo lang_get('update_prefs_button');
    ?>
" />
	</td>
</tr>
</table>
</form>
</div>

<br />

<div class="border-center">
	<form method="post" action="account_prefs_reset.php">
	<input type="hidden" name="user_id" value="<?php 
    echo $p_user_id;
    ?>
" />
	<input type="hidden" name="redirect_url" value="<?php 
    echo $t_redirect_url;
    ?>
" />
	<input type="submit" class="button" value="<?php 
    echo lang_get('reset_prefs_button');
    ?>
" />
	</form>
</div>

<?php 
}
				<span class="checkbox"><input type="checkbox" id="custom-field-require-report" name="require_report" value="1" <?php check_checked( $t_definition['require_report'] ) ?> /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for="custom-field-require-update"><span><?php echo lang_get( 'custom_field_require_update' ) ?></span></label>
				<span class="checkbox"><input type="checkbox" id="custom-field-require-update" name="require_update" value="1" <?php check_checked( $t_definition['require_update'] ) ?> /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for="custom-field-require-resolved"><span><?php echo lang_get( 'custom_field_require_resolved' ) ?></span></label>
				<span class="checkbox"><input type="checkbox" id="custom-field-require-resolved" name="require_resolved" value="1" <?php check_checked( $t_definition['require_resolved'] ) ?> /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container <?php echo helper_alternate_class_no_attribute(); ?>">
				<label for="custom-field-require-closed"><span><?php echo lang_get( 'custom_field_require_closed' ) ?></span></label>
				<span class="checkbox"><input type="checkbox" id="custom-field-require-closed" name="require_closed" value="1" <?php check_checked( $t_definition['require_closed'] ) ?> /></span>
				<span class="label-style"></span>
			</div>
			<span class="submit-button"><input type="submit" class="button" value="<?php echo lang_get( 'update_custom_field_button' ) ?>" /></span>
		</fieldset>
	</form>
</div>

<br />

<div class="form-container">
	<form method="post" action="manage_custom_field_delete.php" class="action-button">
		<fieldset>
			<?php echo form_security_field( 'manage_custom_field_delete' ); ?>
			<input type="hidden" name="field_id" value="<?php echo $f_field_id ?>" />
			<input type="hidden" name="return" value="<?php echo string_attribute( $f_return ) ?>" />
Пример #27
0
	</td>
</tr>
<tr class="row-2">
	<td class="category">
		<?php 
echo lang_get('announcement');
?>
<br />
		<span class="small"><?php 
echo lang_get('stays_on_top');
?>
</span>
	</td>
	<td>
		<input type="checkbox" name="announcement" <?php 
check_checked($v_announcement, 1);
?>
 />
	</td>
</tr>
<tr class="row-1">
	<td class="category" width="25%">
		<?php 
echo lang_get('view_status');
?>
	</td>
	<td width="75%">
		<select name="view_state">
			<?php 
print_enum_string_option_list('view_state', $v_view_state);
?>
echo lang_get('custom_field_require_resolved');
?>
</span></label>
				<span class="checkbox"><input type="checkbox" id="custom-field-require-resolved" name="require_resolved" value="1" <?php 
check_checked((bool) $t_definition['require_resolved']);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<div class="field-container">
				<label for="custom-field-require-closed"><span><?php 
echo lang_get('custom_field_require_closed');
?>
</span></label>
				<span class="checkbox"><input type="checkbox" id="custom-field-require-closed" name="require_closed" value="1" <?php 
check_checked((bool) $t_definition['require_closed']);
?>
 /></span>
				<span class="label-style"></span>
			</div>
			<span class="submit-button"><input type="submit" class="button" value="<?php 
echo lang_get('update_custom_field_button');
?>
" /></span>
		</fieldset>
	</form>
</div>

<br />

<div class="form-container center">
Пример #29
0
function cfdef_input_radio($p_field_def, $p_custom_field_value)
{
    $t_values = explode('|', custom_field_prepare_possible_values($p_field_def['possible_values']));
    $t_len = strlen($p_custom_field_value);
    if ($t_len >= 2 && $p_custom_field_value[0] == '|' && $p_custom_field_value[$t_len - 1] == '|') {
        $t_checked_value = substr($p_custom_field_value, 1, $t_len - 2);
    } else {
        $t_checked_value = $p_custom_field_value;
    }
    for ($i = 0; $i < count($t_values); $i++) {
        $t_input_id = 'custom_field_' . $p_field_def['id'] . '_value_' . $i;
        $t_input_name = 'custom_field_' . $p_field_def['id'];
        echo "<input id=\"{$t_input_id}\" " . helper_get_tab_index() . " type=\"radio\" name=\"{$t_input_name}\" value=\"" . string_attribute($t_values[$i]) . '"';
        check_checked($t_checked_value, $t_values[$i]);
        echo " />\n";
        echo "<label for=\"{$t_input_id}\">" . string_display_line($t_values[$i]) . "</label>\n";
    }
}
Пример #30
0
# Check for an error
$t_error_msg = strip_tags( gpc_get_string( 'error_msg', null ) );
if ( $t_error_msg != null ) {
	print "<br />$t_error_msg<br /><br />";
}

print lang_get( 'query_name_label' ) . lang_get( 'word_separator' );
?>
<form method="post" action="query_store.php">
<?php echo form_security_field( 'query_store' ) ?>
<input type="text" name="query_name" /><br />
<?php
if ( access_has_project_level( config_get( 'stored_query_create_shared_threshold' ) ) ) {
	print '<input type="checkbox" name="is_public" value="on" /> ';
	print lang_get( 'make_public' );
	print '<br />';
}
?>
<input type="checkbox" name="all_projects" value="on" <?php check_checked( ALL_PROJECTS == helper_get_current_project() ) ?> >
<?php print lang_get( 'all_projects' ); ?><br /><br />
<input type="submit" class="button" value="<?php print lang_get( 'save_query' ); ?>" />
</form>
<form action="view_all_bug_page.php">
<?php # CSRF protection not required here - form does not result in modifications ?>
<input type="submit" class="button" value="<?php print lang_get( 'go_back' ); ?>" />
</form>
<?php
echo '</div>';
html_page_bottom();