Пример #1
0
function make_xml_entry($rss_or_atom, $entryarray) {
    $entrydate = dcdateformat($entryarray['time']);
    $entryurl = make_url($entryarray['id']);
    $entrytext = substr(strip_tags($entryarray['entry']),0,300);
    $content = "";

    switch ($rss_or_atom) {
    case "rss":
	    $content .= "<item>";
	    $content .= "<title>".$entryarray['title']."</title>";
	    $content .= "<link>\"$entryurl\"</link>";
    	    $content .= "<description>$entrytext</description>";
	    $content .= "<dc:creator>solostyle</dc:creator>";
	    $content .= "<dc:date>$entrydate</dc:date>";
	    $content .= "<guid isPermaLink=\"true\">$entryurl</guid>";
	    $content .= "</item>";
	    break;
    case "atom":
    	    $content .= "<entry>";
	    $content .= "<title>".$entryarray['title']."</title>";
	    $content .= "<link href=\"$entryurl\" />";
	    $content .= "<id>".$entryarray['id']."</id>";
	    $content .= "<summary>$entrytext</summary>";
	    $content .= "<author><name>solostyle</name></author>";
	    $content .= "<updated>$entrydate</updated>";
	    $content .= "</entry>";
	    break;
    }
    return $content;
}
function log_in_user($user, $user_id)
{
    $_SESSION['active_user'] = array(
        'name' => $user,
        'id'   => $user_id);

    redirect_to(make_url("messages"));
}
Пример #3
0
function log_in_user($user, $user_id, $user_type)
{
    $_SESSION['active_user'] = array(
        'name' => $user,
        'id'   => $user_id,
        'type' => $user_type);

    redirect_to(make_url('admin'));
}
function warning_forum_link($postid)
{
    global $locale;
    $query = dbquery("SELECT p.forum_id as forum_id, p.post_id as post_id, p.thread_id as thread_id, t.thread_subject as subject FROM " . DB_POSTS . " AS p\r\n\t                             LEFT JOIN " . DB_THREADS . " AS t ON t.thread_id=p.thread_id WHERE post_id='" . (int) $postid . "'");
    if (dbrows($query) == 1) {
        $data = dbarray($query);
        return "<a href='" . make_url(FORUM . "viewthread.php?thread_id=" . $data['thread_id'] . "&amp;pid=" . $data['post_id'], BASEDIR . "forum-thread-" . $data['thread_id'] . "-pid" . $data['post_id'] . "-", $data['subject'], ".html") . "#post_" . $data['post_id'] . "'>" . $locale['WARN219'] . " " . $data['subject'] . "</a>";
    } else {
        return $locale['WARN220'];
    }
}
 public function componentLeftmenu()
 {
     $i18n = TBGContext::getI18n();
     $config_sections = array();
     if (TBGContext::getUser()->getScope()->getID() == 1) {
         $config_sections[TBGSettings::CONFIGURATION_SECTION_SCOPES] = array('route' => 'configure_scopes', 'description' => $i18n->__('Scopes'), 'icon' => 'scopes', 'module' => 'core');
     }
     $config_sections[TBGSettings::CONFIGURATION_SECTION_SETTINGS] = array('route' => 'configure_settings', 'description' => $i18n->__('Settings'), 'icon' => 'general', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_PERMISSIONS] = array('route' => 'configure_permissions', 'description' => $i18n->__('Permissions'), 'icon' => 'permissions', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_AUTHENTICATION] = array('route' => 'configure_authentication', 'description' => $i18n->__('Authentication'), 'icon' => 'authentication', 'module' => 'core');
     if (TBGContext::getScope()->isUploadsEnabled()) {
         $config_sections[TBGSettings::CONFIGURATION_SECTION_UPLOADS] = array('route' => 'configure_files', 'description' => $i18n->__('Uploads &amp; attachments'), 'icon' => 'files', 'module' => 'core');
     }
     $config_sections[TBGSettings::CONFIGURATION_SECTION_IMPORT] = array('route' => 'configure_import', 'description' => $i18n->__('Import data'), 'icon' => 'import', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_PROJECTS] = array('route' => 'configure_projects', 'description' => $i18n->__('Projects'), 'icon' => 'projects', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_ISSUETYPES] = array('icon' => 'issuetypes', 'description' => $i18n->__('Issue types'), 'route' => 'configure_issuetypes', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_ISSUEFIELDS] = array('icon' => 'resolutiontypes', 'description' => $i18n->__('Issue fields'), 'route' => 'configure_issuefields', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_WORKFLOW] = array('icon' => 'workflow', 'description' => $i18n->__('Workflow'), 'route' => 'configure_workflow', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_USERS] = array('route' => 'configure_users', 'description' => $i18n->__('Users, teams, clients &amp; groups'), 'icon' => 'users', 'module' => 'core');
     $config_sections[TBGSettings::CONFIGURATION_SECTION_MODULES][] = array('route' => 'configure_modules', 'description' => $i18n->__('Modules'), 'icon' => 'modules', 'module' => 'core');
     foreach (TBGContext::getModules() as $module) {
         if ($module->hasConfigSettings() && $module->isEnabled()) {
             $config_sections[TBGSettings::CONFIGURATION_SECTION_MODULES][] = array('route' => array('configure_module', array('config_module' => $module->getName())), 'description' => $module->getConfigTitle(), 'icon' => $module->getName(), 'module' => $module->getName());
         }
     }
     $breadcrumblinks = array();
     foreach ($config_sections as $section) {
         if (is_array($section) && !array_key_exists('route', $section)) {
             foreach ($section as $subsection) {
                 $url = is_array($subsection['route']) ? make_url($subsection['route'][0], $subsection['route'][1]) : make_url($subsection['route']);
                 $breadcrumblinks[] = array('url' => $url, 'title' => $subsection['description']);
             }
         } else {
             $breadcrumblinks[] = array('url' => make_url($section['route']), 'title' => $section['description']);
         }
     }
     $this->breadcrumblinks = $breadcrumblinks;
     $this->config_sections = $config_sections;
     if ($this->selected_section == TBGSettings::CONFIGURATION_SECTION_MODULES) {
         if (TBGContext::getRouting()->getCurrentRouteName() == 'configure_modules') {
             $this->selected_subsection = 'core';
         } else {
             $this->selected_subsection = TBGContext::getRequest()->getParameter('config_module');
         }
     }
 }
Пример #6
0
    function display_navigation()
    {
        $m_navi = instance_model('navigation');
        $navi = $m_navi->get_all('Order');

        $m_page = instance_model('page');

        $output = array();
        foreach($navi as $row)
        {
            $out_title = '';
            $out_url   = '';

            if($row['Type'] == 'page')
            {
                $page = $m_page->get_by_id($row['Data']);

                if($page == array())
                {
                    $out_title = '[Not Found]';
                    $out_url   = '#';
                }
                else
                {
                    $out_title = $row['Title'];
                    $out_url   = make_url('page', $page[0]['Clean_title']);
                
                }
            }
            else if($row['Type'] == 'url')
            {
                $out_title = $row['Title'];
                $out_url   = $row['Data'];
            }

            $output []= array(
                'title' => $out_title,
                'url'   => $out_url);
        }

        $view = instance_view('navigation');
        $view->parse(array(
            'navi' => $output
        ));
    }
Пример #7
0
    function note()
    {
        $path = get_app_root();
        $params = $this->params;

        $note_db = instance_model('notes');

        if(!isset($params[2]))
        {
            $note_id = $note_db->allocate_note();
            redirect_to(make_url('kindlenote', 'note', $note_id));
        }

        $note_id = $params[2];
        $note = $note_db->get_note($note_id);

        $view = instance_view('note_edit');
        $view->parse(array(
            'path'    => $path,
            'note_id' => $note_id,
            'note'    => $note 
        ));
    }
Пример #8
0
 function create_archive_nav_menu($arr)
 {
     // start the html
     $html = '<div id="archmenuWP">';
     $html .= '<ul class="archlev1 archmenu_list_years" id="archmenu">';
     $years = array_keys($arr);
     foreach ($years as $y) {
         $html .= '<li id="archmenu_li_y_' . $y . '">';
         $html .= make_link($y . ' (' . $arr[$y]['count'] . ')', make_url($y . '/'));
         $html .= '<span class="archmenu_ty archToggleButton" id="archmenu_ty_' . $y . '">+</span>';
         // handle clicks with JS
         $html .= '</li>';
         unset($arr[$y]['count']);
         $months = array_keys($arr[$y]);
         $html .= '<ul class="archlev2 archmenu_list_months hidden" id="archmenu_y_' . $y . '">';
         foreach ($months as $m) {
             $html .= '<li id="archmenu_li_y_' . $y . '_m_' . $m . '">';
             $html .= make_link(monthname($m) . ' (' . $arr[$y][$m]['count'] . ')', make_url($y . '/' . $m . '/'));
             $html .= '<span class="archmenu_tm archToggleButton" id="archmenu_ty_' . $y . '_tm_' . $m . '">+</span>';
             // handle clicks with JS
             $html .= '</li>';
             unset($arr[$y][$m]['count']);
             $entries = $arr[$y][$m];
             $html .= '<ul class="archlev3 archmenu_list_titles hidden" id="archmenu_y_' . $y . '_m_' . $m . '">';
             foreach ($entries as $id => $entry) {
                 $html .= '<li id="archmenu_li_id_' . $id . '">';
                 $html .= make_link($entry['title'], make_url($id));
                 $html .= '</li>';
             }
             $html .= '</ul>';
         }
         $html .= '</ul>';
     }
     $html .= '</ul></div>';
     return $html;
 }
Пример #9
0
 public function componentLeftmenu()
 {
     $config_sections = TBGSettings::getConfigSections(TBGContext::getI18n());
     $breadcrumblinks = array();
     foreach ($config_sections as $key => $sections) {
         foreach ($sections as $section) {
             if ($key == TBGSettings::CONFIGURATION_SECTION_MODULES) {
                 $url = is_array($section['route']) ? make_url($section['route'][0], $section['route'][1]) : make_url($section['route']);
                 $breadcrumblinks[] = array('url' => $url, 'title' => $section['description']);
             } else {
                 $breadcrumblinks[] = array('url' => make_url($section['route']), 'title' => $section['description']);
             }
         }
     }
     $this->breadcrumblinks = $breadcrumblinks;
     $this->config_sections = $config_sections;
     if ($this->selected_section == TBGSettings::CONFIGURATION_SECTION_MODULES) {
         if (TBGContext::getRouting()->getCurrentRouteName() == 'configure_modules') {
             $this->selected_subsection = 'core';
         } else {
             $this->selected_subsection = TBGContext::getRequest()->getParameter('config_module');
         }
     }
 }
Пример #10
0
	Bonjour %user_buddyname%,<br>
	<?php 
echo $issue->getIssuetype()->getName();
?>
 <?php 
echo $issue->getFormattedTitle(true);
?>
 a &eacute;t&eacute; mise &agrave; jour par <?php 
echo $updated_by->getName();
?>
.<br>
	<br>
	<?php 
echo tbg_parse_text($comment);
?>
	<br>
	<div style="color: #888;">
		--
		<br>
		Affiche la demande : <?php 
echo link_tag(make_url('viewissue', array('project_key' => $issue->getProject()->getKey(), 'issue_no' => $issue->getFormattedIssueNo()), false));
?>
<br>
		Affiche le tableau de bord du projet <?php 
echo $issue->getProject()->getName();
?>
 : <?php 
echo link_tag(make_url('project_dashboard', array('project_key' => $issue->getProject()->getKey()), false));
?>
	</div>
</div>
Пример #11
0
</h4>
	<table style="clear: both; width: 780px;" class="padded_table" cellpadding=0 cellspacing=0>
		<tr>
			<td><label for="workflow_scheme"><?php 
echo __('Workflow scheme');
?>
</label></td>
			<td style="padding: 5px;">
				<?php 
echo $project->getWorkflowScheme()->getName();
?>
				<?php 
if ($access_level == TBGSettings::ACCESS_FULL) {
    ?>
				<div class="button button-blue" style="float: right; margin-top: -10px;" onclick="TBG.Main.Helpers.Backdrop.show('<?php 
    echo make_url('get_partial_for_backdrop', array('key' => 'project_workflow', 'project_id' => $project->getId()));
    ?>
');"><span><?php 
    echo __('Change workflow scheme');
    ?>
</span></div>
					<?php 
    /*<select name="workflow_scheme" id="workflow_scheme">
    			<?php foreach (TBGWorkflowScheme::getAll() as $workflow_scheme): ?>
    				<option value=<?php echo $workflow_scheme->getID(); ?><?php if ($project->getWorkflowScheme()->getID() == $workflow_scheme->getID()): ?> selected<?php endif; ?>><?php echo $workflow_scheme->getName(); ?></option>
    			<?php endforeach; ?>
    		</select> */
    ?>
				<?php 
}
?>
Пример #12
0
        echo __('Project wikis');
        ?>
</div>
                <?php 
        foreach (\thebuggenie\core\entities\Project::getAll() as $project) {
            ?>
                    <?php 
            if (!$project->hasAccess() || isset($project_url) && $project->getID() == \thebuggenie\core\framework\Context::getCurrentProject()->getID()) {
                continue;
            }
            ?>
                    <?php 
            if (!$project->hasWikiURL()) {
                ?>
                        <?php 
                echo link_tag(make_url('publish_article', array('article_name' => ucfirst($project->getKey()) . ':MainPage')), $project->getName());
                ?>
                    <?php 
            } else {
                ?>
                        <?php 
                echo link_tag($project->getWikiURL(), $project->getName(), array('target' => 'blank'));
                ?>
                    <?php 
            }
            ?>
                <?php 
        }
        ?>
            <?php 
    }
Пример #13
0
<li style="vertical-align: middle; clear: both; height: 20px;">
	<?php 
echo image_tag('spinning_20.gif', array('id' => 'article_favourite_indicator_' . $article->getId() . '_' . $user->getID(), 'style' => 'display: none; float: left; margin-right: 5px;'));
?>
	<?php 
echo image_tag('star_faded_small.png', array('id' => 'article_favourite_faded_' . $article->getId() . '_' . $user->getID(), 'style' => 'cursor: pointer; display: none; float: left; margin-right: 5px;', 'onclick' => "TBG.Issues.toggleFavourite('" . make_url('toggle_favourite_article', array('article_id' => $article->getID(), 'user_id' => $user->getID())) . "', '" . $article->getID() . '_' . $user->getID() . "');"));
?>
	<?php 
echo image_tag('star_small.png', array('id' => 'article_favourite_normal_' . $article->getId() . '_' . $user->getID(), 'style' => 'cursor: pointer; float: left; margin-right: 5px;', 'onclick' => "TBG.Issues.toggleFavourite('" . make_url('toggle_favourite_article', array('article_id' => $article->getID(), 'user_id' => $user->getID())) . "', '" . $article->getID() . '_' . $user->getID() . "');"));
?>
	<?php 
include_component('main/userdropdown', compact('user'));
?>
</li>
<table style="width: 780px;" cellpadding=0 cellspacing=0>
	<tr>
		<td style="width: auto; padding-right: 5px; vertical-align: top;">
			<?php 
if ($access_level == TBGSettings::ACCESS_FULL) {
    ?>
				<form accept-charset="<?php 
    echo TBGContext::getI18n()->getCharset();
    ?>
" action="<?php 
    echo make_url('configure_projects_add_milestone', array('project_id' => $project->getID()));
    ?>
" method="post" id="add_milestone_form" onsubmit="addMilestone('<?php 
    echo make_url('configure_projects_add_milestone', array('project_id' => $project->getID()));
    ?>
');return false;">
					<div class="rounded_box yellow" style="padding: 5px; margin-bottom: 15px;">
						<table cellpadding=0 cellspacing=0 style="width: 770px;">
							<tr>
								<td style="width: 200px;"><label for="add_milestone_name"><?php 
    echo __('Add milestone');
    ?>
</label></td>
								<td style="width: 400px; padding: 2px;"><input type="text" id="add_milestone_name" style="width: 445px;" name="name"></td>
								<td style="width: 125px; padding: 2px;">
									<select name="milestone_type">
										<option value="1"><?php 
    echo __('Regular milestone');
    ?>
</option>
										<option value="2"><?php 
        echo __('This step is not connected to a specific status');
        ?>
</span>
                                <?php 
    }
    ?>
                            </dd>
                        </dl>
                        <?php 
    if (!$step->isCore()) {
        ?>
                            <form accept-charset="<?php 
        echo \thebuggenie\core\framework\Context::getI18n()->getCharset();
        ?>
" method="post" action="<?php 
        echo make_url('configure_workflow_step', array('workflow_id' => $step->getWorkflow()->getID(), 'step_id' => $step->getID(), 'mode' => 'edit'));
        ?>
" id="step_details_form" style="display: none;" onsubmit="$('step_update_indicator').show();$('update_step_buttons').hide();">
                                <dl>
                                    <dt><label for="step_name"><?php 
        echo __('Name');
        ?>
</label></dt>
                                    <dd><input type="text" name="name" id="step_name" value="<?php 
        echo $step->getName();
        ?>
" style="width: 150px;"></dd>
                                    <dt><label for="step_description"><?php 
        echo __('Description');
        ?>
</label></dt>
Пример #16
0
    ?>
					<?php 
    if ($module->hasAccountSettings()) {
        ?>
						<div id="tab_settings_<?php 
        echo $module_name;
        ?>
_pane" style="display: none;">
							<form accept-charset="<?php 
        echo TBGContext::getI18n()->getCharset();
        ?>
" action="<?php 
        echo make_url('account_save_module_settings', array('target_module' => $module_name));
        ?>
" onsubmit="updateProfileModuleSettings('<?php 
        echo make_url('account_save_module_settings', array('target_module' => $module_name));
        ?>
', '<?php 
        echo $module_name;
        ?>
'); return false;" method="post" id="profile_<?php 
        echo $module_name;
        ?>
_form">
								<div class="rounded_box borderless lightgrey cut_bottom" style="margin: 5px 0 0 0; width: 690px; border-bottom: 0;">
									<?php 
        include_component("{$module_name}/accountsettings", array('module' => $module));
        ?>
								</div>
								<div class="rounded_box iceblue borderless cut_top" style="margin: 0 0 5px 0; width: 690px; border-top: 0; padding: 8px 5px 2px 5px; height: 25px;">
									<div style="float: left; font-size: 13px; padding-top: 2px;"><?php 
<div class="rounded_box shadowed white" id="step_<?php 
echo $step->getID();
?>
_transition_add" style="width: 720px; position: absolute; padding: 5px; margin: 5px; display: none; z-index: 100;">
    <div class="header"><?php 
echo __('Add outgoing transition from step "%step_name"', array('%step_name' => $step->getName()));
?>
</div>
    <div class="content">
        <form accept-charset="<?php 
echo \thebuggenie\core\framework\Context::getI18n()->getCharset();
?>
" method="post" action="<?php 
echo make_url('configure_workflow_add_transition', array('workflow_id' => $step->getWorkflow()->getID(), 'step_id' => $step->getID()));
?>
">
            <ul class="simple_list">
                <li>
                    <input type="radio" name="add_transition_type" value="existing" id="step_<?php 
echo $step->getID();
?>
_add_existing_transition">
                    <label for="step_<?php 
echo $step->getID();
?>
_add_existing_transition"><?php 
echo __('Existing transition');
?>
</label>
                    <select name="existing_transition_id" onclick="$('step_<?php 
echo $step->getID();
        }
        ?>
                        <?php 
        echo link_tag(make_url('client_dashboard', array('client_id' => $client->getID())), image_tag('tab_clients.png') . $client->getName());
        ?>
                    <?php 
    }
    ?>
                </div>
            </li>
        <?php 
}
?>
        <?php 
framework\Event::createNew('core', 'templates/headermainmenu::projectmenulinks', framework\Context::getCurrentProject())->trigger();
?>
    </ul>
    <?php 
if (framework\Context::isProjectContext() && !framework\Context::getCurrentProject()->isArchived() && !framework\Context::getCurrentProject()->isLocked() && ($tbg_user->canReportIssues() || $tbg_user->canReportIssues(framework\Context::getCurrentProject()->getID()))) {
    ?>
        <div class="reportissue_button_container">
        <?php 
    echo javascript_link_tag(image_tag('icon-mono-add.png') . __('Report an issue'), array('onclick' => "TBG.Issues.Add('" . make_url('get_partial_for_backdrop', array('key' => 'reportissue', 'project_id' => framework\Context::getCurrentProject()->getId())) . "');", 'class' => 'button button-lightblue', 'id' => 'reportissue_button'));
    ?>
        </div>
    <?php 
}
framework\Event::createNew('core', 'before_header_userinfo')->trigger();
?>
</nav>
Пример #19
0
<div class="article">
    <div class="header">Special:<?php 
echo $projectnamespace != '' ? "<span class='faded_out'>{$projectnamespace}</span>" : '';
?>
All Pages</div>
        <div class="greybox" style="margin: 15px 0;">
            <?php 
if (\thebuggenie\core\framework\Context::isProjectContext()) {
    ?>
                <?php 
    echo __('Note: This page lists all articles for "%project_name". For a list of global articles, see %all_pages', array('%project_name' => \thebuggenie\core\framework\Context::getCurrentProject()->getName(), '%all_pages' => link_tag(make_url('publish_article', array('article_name' => "Special:AllPages")), 'Special:AllPages')));
    ?>
            <?php 
} else {
    ?>
                <?php 
    echo __('Note: This page lists all articles in the global scope. For a list of project articles, see the corresponding "All pages" for that specific project');
    ?>
            <?php 
}
?>
        </div>
    <p>
        <?php 
echo __('Below is a listing of all pages.');
?>
    </p>
    <?php 
include_component('publish/articleslist', compact('articles'));
?>
</div>
" /><?php 
                        echo __('%save or %cancel', array('%save' => '<input type="submit" value="' . __('Save') . '">', '%cancel' => '<a href="#" onclick="$(\'' . $field . '_change\').hide(); return false;">' . __('cancel') . '</a>'));
                        ?>
												</form>
											<?php 
                        break;
                    case TBGCustomDatatype::INPUT_TEXTAREA_SMALL:
                        ?>
												<form id="<?php 
                        echo $field;
                        ?>
_form" action="<?php 
                        echo make_url('issue_setfield', array('project_key' => $issue->getProject()->getKey(), 'issue_id' => $issue->getID(), 'field' => $field));
                        ?>
" method="post" onSubmit="TBG.Issues.Field.set('<?php 
                        echo make_url('issue_setfield', array('project_key' => $issue->getProject()->getKey(), 'issue_id' => $issue->getID(), 'field' => $field));
                        ?>
', '<?php 
                        echo $field;
                        ?>
', '<?php 
                        echo $field;
                        ?>
'); return false;">
													<?php 
                        include_template('main/textarea', array('area_name' => $field . '_value', 'target_type' => 'issue', 'target_id' => $issue->getID(), 'area_id' => $field . '_value', 'height' => '100px', 'width' => '100%', 'value' => $info['name']));
                        ?>
													<br><?php 
                        echo __('%save or %cancel', array('%save' => '<input type="submit" value="' . __('Save') . '">', '%cancel' => '<a href="#" onclick="$(\'' . $field . '_change\').hide(); return false;">' . __('cancel') . '</a>'));
                        ?>
												</form>
Пример #21
0
    $release_date_text = $build->hasReleaseDate() ? __('Released %release_date', array('%release_date' => tbg_formatTime($build->getReleaseDate(), 7, true, true))) : __('Released');
    ?>
        <?php 
} else {
    ?>
            <?php 
    $release_date_text = __('Not released yet');
    ?>
        <?php 
}
?>
        <?php 
if ($build->hasDownload()) {
    ?>
            <?php 
    $release_date_text = __('%release_date, download: %download_filename', array('%release_date' => $release_date_text, '%download_filename' => $build->hasFile() ? link_tag(make_url('downloadfile', array('id' => $build->getFile()->getID())), $build->getFile()->getOriginalFilename()) : link_tag($build->getFileURL())));
    ?>
        <?php 
} else {
    ?>
            <?php 
    $release_date_text = __('%release_date, no download available', array('%release_date' => $release_date_text));
    ?>
        <?php 
}
?>
        <?php 
if (!$build->isReleased()) {
    ?>
            <div id="build_<?php 
    echo $b_id;
Пример #22
0
    ?>
			<ul class="article_list">
				<?php 
    foreach ($latest_articles as $article) {
        ?>
					<li>
						<div>
							<?php 
        echo image_tag('news_item_medium.png', array('style' => 'float: left;'), false, 'publish');
        ?>
							<?php 
        echo link_tag(make_url('publish_article', array('article_name' => $article->getName())), get_spaced_name($article->getTitle()));
        ?>
							<br>
							<span><?php 
        echo __('%time, by %user', array('%time' => tbg_formatTime($article->getPostedDate(), 3), '%user' => '<b>' . ($article->getAuthor() instanceof TBGIdentifiable ? '<a href="javascript:void(0);" onclick="TBG.Main.Helpers.Backdrop.show(\'' . make_url('get_partial_for_backdrop', array('key' => 'usercard', 'user_id' => $article->getAuthor()->getID())) . '\');">' . $article->getAuthor()->getName() . '</a>' : __('System')) . '</b>'));
        ?>
</span>
						</div>
					</li>
				<?php 
    }
    ?>
			</ul>
		<?php 
} else {
    ?>
			<div class="no_items"><?php 
    echo __('There are no recent pages here');
    ?>
</div>
Пример #23
0
		<?php 
}
?>
	</td>
	<td class="workflow_step_actions">
		<?php 
if ($step->isCore()) {
    ?>
			<?php 
    echo link_tag(make_url('configure_workflow_step', array('workflow_id' => $step->getWorkflow()->getID(), 'step_id' => $step->getID())), __('Show step info'));
    ?>
		<?php 
} else {
    ?>
			<?php 
    echo link_tag(make_url('configure_workflow_step', array('workflow_id' => $step->getWorkflow()->getID(), 'step_id' => $step->getID())), __('Edit step'));
    ?>
 |
			<?php 
    if ($step->hasIncomingTransitions()) {
        ?>
				<span class="faded_out"><a href="javascript:void(0);" class="disabled" onclick="failedMessage('<?php 
        echo __('You cannot delete a step with incoming transitions');
        ?>
', '<?php 
        echo __('To delete a step that has incoming transitions, first remove all incoming transitions');
        ?>
');"><?php 
        echo __('Delete step');
        ?>
</a></span><br>
Пример #24
0
?>
</div>
    <div id="backdrop_detail_content" class="backdrop_detail_content">
        <h5><?php 
echo __('The selected username is available');
?>
</h5>
        <?php 
echo __('You cannot change the username after you have picked it. Please confirm that you want to use the following username: %username', array('%username' => '<h3>' . $username . '</h3>'));
?>
        <div style="text-align: center;">
            <form accept-charset="<?php 
echo \thebuggenie\core\framework\Context::getI18n()->getCharset();
?>
" action="<?php 
echo make_url('account_pick_username', array('selected_username' => $username));
?>
" method="post" id="pick_username_form">
                <input type="submit" value="<?php 
echo __('Yes');
?>
" class="button button-green">&nbsp;<?php 
echo __('%yes or %no', array('%yes' => '', '%no' => ''));
?>
&nbsp;<button onclick="TBG.Main.Helpers.Backdrop.reset(); return false;" class="button button-silver"><?php 
echo __('No');
?>
</button>
            </form>
        </div>
    </div>
"><?php 
    echo $user->getUsername();
    ?>
</span>
<?php 
} else {
    ?>
    <a href="javascript:void(0);" class="userlink<?php 
    if ($tbg_user->isFriend($user)) {
        ?>
 friend" title="<?php 
        echo __('This is one of your friends');
    }
    ?>
" onclick="TBG.Main.Helpers.Backdrop.show('<?php 
    echo make_url('get_partial_for_backdrop', array('key' => 'usercard', 'user_id' => $user->getID()));
    ?>
');">
        <?php 
    if (isset($in_email) && !$in_email && (!isset($userstate) || $userstate)) {
        ?>
<span class="userstate"><?php 
        echo tbg_get_userstate_image($user);
        ?>
</span><?php 
    }
    ?>
        <?php 
    if ($show_avatar) {
        ?>
            <?php 
		<?php 
        }
        ?>
	<?php 
    }
    ?>
	<?php 
    if (true || $resultcount - $cc > 0) {
        ?>
		<li class="find_more_issues last">
			<span class="informal"><?php 
        echo __('See %num% more articles ...', array('%num%' => $resultcount - $cc));
        ?>
</span>
			<div class="hidden url"><?php 
        echo TBGContext::isProjectContext() ? make_url('publish_find_project_articles', array('project_key' => TBGContext::getCurrentProject()->getKey())) : make_url('publish_find_articles');
        ?>
?articlename=<?php 
        echo $searchterm;
        ?>
</div>
		</li>
	<?php 
    }
} else {
    ?>
	<li class="disabled no_issues_found">
		<?php 
    echo __('No articles found matching your query');
    ?>
	</li>
    protected function renderBody()
    {
        ?>

<div id="<?php 
        echo $this->getDivId();
        ?>
">

<form action="<?php 
        echo_html(make_url('/admin/workers.php'));
        ?>
" method="post">

<fieldset>
<input type="hidden" name="action" value="<?php 
        echo $this->getAction();
        ?>
" />
<?php 
        if ($this->viewdata['worker']->id) {
            ?>
<input type="hidden" name="id" value="<?php 
            echo_html($this->viewdata['worker']->id);
            ?>
" />
<?php 
        }
        ?>
</fieldset>

<table class="entry centered">
    <tr>
        <th><label for="name">Name:</label></th>
        <td><input name="name" id="name" size="25" value="<?php 
        echo_html($this->viewdata['worker']->name);
        ?>
" /></td>
    </tr>
    <tr>
        <th><label for="password">Password:</label></th>
        <td><input name="password" id="password" size="25" value="<?php 
        echo_html($this->viewdata['worker']->password);
        ?>
" /></td>
    </tr>
    <tr class="submit">
        <td>&nbsp;</td>
        <td><input type="submit" value="<?php 
        echo $this->getSubmitValue();
        ?>
" /></td>
    </tr>
</table>

</form>

</div>

<?php 
    }
Пример #28
0
<?php

/**
 * Configuration for theme
 */
$tbg_response->addStylesheet(make_url('asset_css', array('theme_name' => 'oxygen', 'css' => 'theme.css')));
\thebuggenie\core\framework\Settings::setIconsetName('oxygen');
?>
<style>
    #tbg3_username, #fieldusername { background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
?>
user_mono.png'); }
    #fieldusername.invalid { background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
?>
icon_error.png'); background-color: rgba(255, 220, 220, 0.5); }
    #fieldusername.valid { background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
?>
icon_ok.png'); background-color: rgba(220, 255, 220, 0.5); }
    .login_popup input[type=password] { background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
?>
password_mono.png'); }
    #openid-signin-button.persona-button span:after{ background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
?>
openid_providers.small/openid.ico.png'); }
    #regular-signin-button.persona-button span:after{ background-image: url('<?php 
echo $webroot . 'iconsets/' . \thebuggenie\core\framework\Settings::getIconsetName() . '/';
Пример #29
0
    echo __('Are you sure?');
    ?>
</div>
		<div class="content">
			<?php 
    echo __('Please confirm that you want to delete this issue type scheme.');
    ?>
<br>
			<form accept-charset="<?php 
    echo TBGContext::getI18n()->getCharset();
    ?>
" action="<?php 
    echo make_url('configure_issuetypes_delete_scheme', array('scheme_id' => $scheme->getID()));
    ?>
" onsubmit="TBG.Config.IssuetypeScheme.remove('<?php 
    echo make_url('configure_issuetypes_delete_scheme', array('scheme_id' => $scheme->getID()));
    ?>
', <?php 
    echo $scheme->getID();
    ?>
);return false;" id="delete_issuetype_scheme_<?php 
    echo $scheme->getID();
    ?>
_form">
				<div style="text-align: right;">
					<?php 
    echo image_tag('spinning_16.gif', array('style' => 'margin-right: 5px; display: none;', 'id' => 'delete_issuetype_scheme_' . $scheme->getID() . '_indicator'));
    ?>
					<input type="submit" value="<?php 
    echo __('Yes, delete it');
    ?>
if (count($tbg_user->getAssociatedProjects()) > 0) {
    ?>
    <ul id="associated_projects">
        <?php 
    foreach ($tbg_user->getAssociatedProjects() as $project) {
        ?>
            <?php 
        if ($project->isDeleted()) {
            continue;
        }
        ?>
            <li style="text-align: right;">
                <div style="padding: 0 5px;">
                    <div class="project_name">
                        <?php 
        echo link_tag(make_url('project_dashboard', array('project_key' => $project->getKey())), $project->getName(), array('style' => 'font-weight: normal; font-size: 1.2em;'));
        ?>
                    </div>
                    <div style="float: right;" class="button-group">
                        <?php 
        foreach ($links as $link) {
            ?>
                            <?php 
            echo link_tag(str_replace('%25project_key%25', $project->getKey(), $link['url']), $link['text'], array('class' => 'button button-silver'));
            ?>
                        <?php 
        }
        ?>
                    </div>
                    <br style="clear: both;">
                </div>