Exemplo n.º 1
0
 function display($tpl = NULL)
 {
     if (!FSS_Permission::CanModerate()) {
         return FSS_Admin_Helper::NoPerm();
     }
     $this->comments = new FSS_Comments(null, null);
     if ($this->comments->Process()) {
         return;
     }
     parent::display();
 }
Exemplo n.º 2
0
 function in()
 {
     $current_user = JFactory::getUser()->id;
     $manager = FSS_Permission::auth("fss.ticket_admin.ooo", "com_fss.support_admin", JFactory::getUser()->id);
     $user_id = FSS_Input::getInt('user_id');
     if (!$manager && $current_user != $user_id) {
         return $this->cancel();
     }
     // update the current users setting
     $values = SupportUsers::getAllSettings($user_id);
     $values->out_of_office = 0;
     SupportUsers::updateUserSettings($values, $user_id);
     JFactory::getApplication()->redirect(FSSRoute::_("index.php?option=com_fss&view=admin_support&layout=listhandlers", false));
 }
Exemplo n.º 3
0
 function display($tpl = null)
 {
     $this->layout = FSS_Input::getCmd('layout', FSS_Input::getCmd('_layout', ''));
     $this->view = FSS_Input::getCmd('view', FSS_Input::getCmd('_view', ''));
     if (!FSS_Permission::PermAnyContent()) {
         return FSS_Admin_Helper::NoPerm();
     }
     $this->type = FSS_Input::getCmd('type', '');
     if ($this->type != "") {
         return $this->displayType();
     }
     $this->artcounts = FSS_ContentEdit::getArticleCounts();
     parent::display();
 }
Exemplo n.º 4
0
 function display($tpl = null)
 {
     $layout = FSS_Input::getCmd('layout');
     if ($layout == "support") {
         return JFactory::getApplication()->redirect(FSSRoute::_('index.php?option=com_fss&view=admin_support', false));
     }
     if ($layout == "content") {
         return JFactory::getApplication()->redirect(FSSRoute::_('index.php?option=com_fss&view=admin_content', false));
     }
     if ($layout == "moderate") {
         return JFactory::getApplication()->redirect(FSSRoute::_('index.php?option=com_fss&view=admin_moderate', false));
     }
     if ($layout == "shortcut") {
         return JFactory::getApplication()->redirect(FSSRoute::_('index.php?option=com_fss&view=admin_shortcut', false));
     }
     $can_view = false;
     $view = array();
     if (FSS_Permission::PermAnyContent()) {
         $view[] = FSSRoute::_('index.php?option=com_fss&view=admin_content', false);
         $can_view = true;
     }
     if (FSS_Permission::AdminGroups()) {
         $view[] = FSSRoute::_('index.php?option=com_fss&view=admin_groups', false);
         $can_view = true;
     }
     if (FSS_Permission::auth("fss.reports", "com_fss.reports")) {
         $view[] = FSSRoute::_('index.php?option=com_fss&view=admin_report', false);
         $can_view = true;
     }
     if (FSS_Permission::auth("fss.handler", "com_fss.support_admin")) {
         $view[] = FSSRoute::_('index.php?option=com_fss&view=admin_support', false);
         $can_view = true;
     }
     if (FSS_Permission::CanModerate()) {
         $view[] = FSSRoute::_('index.php?option=com_fss&view=admin_moderate', false);
         $can_view = true;
     }
     if (!$can_view) {
         return FSS_Admin_Helper::NoPerm();
     }
     // if only 1 section visible, then view that section only
     if (count($view) == 1) {
         $mainframe = JFactory::getApplication();
         $link = reset($view);
         $mainframe->redirect($link);
     }
     $this->comments = new FSS_Comments(null, null);
     $this->artcounts = FSS_ContentEdit::getArticleCounts();
     parent::display();
 }
Exemplo n.º 5
0
 function display($tpl = NULL)
 {
     $this->current_userid = JFactory::getUser()->id;
     $this->userid = FSS_Input::getInt('user_id', $this->current_userid);
     if (!FSS_Permission::auth("fss.ticket_admin.ooo", "com_fss.support_admin", JFactory::getUser()->id)) {
         $this->userid = $this->current_userid;
     }
     $this->user = JFactory::getUser($this->userid);
     $this->loadTicketList();
     $values = SupportUsers::getAllSettings($this->userid);
     if ($values->out_of_office) {
         return $this->showUserOut();
     } else {
         return $this->showUserIn();
     }
     //
 }
Exemplo n.º 6
0
 function display($tpl = null)
 {
     if (FSS_Settings::Get('support_only_admin_open')) {
         return $this->noPermission("Access Denied", "CREATING_NEW_TICKETS_BY_USERS_IS_CURRENTLY_DISABLED");
     }
     if (!FSS_Permission::auth("fss.ticket.open", "com_fss.support_user")) {
         return FSS_Helper::NoPerm();
     }
     $mainframe = JFactory::getApplication();
     $user = JFactory::getUser();
     $userid = $user->get('id');
     $this->assign('userid', $userid);
     $this->assign('email', '');
     // defaults for blank ticket
     $this->ticket = new stdClass();
     $this->ticket->prodid = FSS_Input::getInt('prodid');
     $this->ticket->deptid = FSS_Input::getInt('deptid');
     $this->ticket->catid = FSS_Input::getInt('catid');
     $this->ticket->priid = FSS_Input::getInt('priid');
     $this->ticket->subject = FSS_Input::getString('subject');
     $this->ticket->body = FSS_Input::getBBCode('body');
     $this->errors['subject'] = '';
     $this->errors['body'] = '';
     $this->errors['cat'] = '';
     $what = FSS_Input::getCmd('what');
     // done with ticket, try and save, if not, display any errors
     if ($what == "add") {
         if ($this->saveTicket()) {
             echo "Saved OK!";
             exit;
             $link = 'index.php?option=com_fss&view=ticket&layout=view&Itemid=' . FSS_Input::getInt('Itemid') . '&ticketid=' . $this->ticketid;
             $mainframe->redirect($link);
             return;
         }
     }
     $this->product = $this->get('Product');
     $this->dept = $this->get('Department');
     $this->cats = SupportHelper::getCategories();
     $this->pris = SupportHelper::getPriorities();
     $this->support_user_attach = FSS_Settings::get('support_user_attach');
     $this->fields = FSSCF::GetCustomFields(0, $prodid, $deptid);
     parent::display();
 }
Exemplo n.º 7
0
 function _buildQuery()
 {
     $query = "SELECT * FROM #__fss_announce ";
     $where = array();
     if (FSS_Permission::auth("core.edit", "com_fss.announce")) {
     } else {
         if (FSS_Permission::auth("core.edit.own", "com_fss.announce")) {
             $where[] = " ( published = 1 OR author = {$this->content->userid} ) ";
         } else {
             $where[] = "published = 1";
         }
     }
     // add language and access to query where
     $db = JFactory::getDBO();
     $where[] = 'language in (' . $db->Quote(JFactory::getLanguage()->getTag()) . ',' . $db->Quote('*') . ')';
     $user = JFactory::getUser();
     $where[] = 'access IN (' . implode(',', $user->getAuthorisedViewLevels()) . ')';
     if (count($where) > 0) {
         $query .= " WHERE " . implode(" AND ", $where);
     }
     $query .= " ORDER BY added DESC";
     return $query;
 }
Exemplo n.º 8
0
 function doDisplayTicket()
 {
     if (!FSS_Permission::auth("fss.ticket.view", "com_fss.support_user")) {
         return FSS_Helper::NoPerm();
     }
     if (!$this->GetTicket()) {
         return;
     }
     $this->readonly = false;
     SupportSource::doUser_View_Redirect($this->ticket);
     $this->redirectMergedTickets();
     $this->getCCInfo();
     // update lang code on ticket
     $lang = JFactory::getLanguage()->getTag();
     $db = JFactory::getDBO();
     $qry = "UPDATE #__fss_ticket_ticket SET lang = '" . FSSJ3Helper::getEscaped($db, $lang) . "' WHERE id = " . $this->ticket['id'];
     $db->setQuery($qry);
     $db->Query();
     $what = FSS_Input::getCmd('what');
     if ($what == "print") {
         return parent::display("print");
     }
     $this->FixTicketStatus();
     FSS_Helper::IncludeModal();
     parent::display();
 }
Exemplo n.º 9
0
 function Report($report_name)
 {
     if (!FSS_Permission::auth("fss.reports.report." . $report_name, "com_fss.reports") && !FSS_Permission::auth("fss.reports.all", "com_fss.reports")) {
         return FSS_Admin_Helper::NoPerm();
     }
     $lang = JFactory::getLanguage();
     $lang->load("report_shared", JPATH_COMPONENT);
     $lang->load("report_" . $report_name . ".sys", JPATH_COMPONENT);
     $lang->load("report_" . $report_name, JPATH_COMPONENT);
     $report = $this->LoadXML($report_name);
     if (!$report) {
         echo "Unable to open report xml<br>";
         return;
     }
     $this->graph = 0;
     if (isset($report->graph)) {
         $this->graph = 1;
     }
     $report->getData();
     $report->translateData();
     //print_p($report);
     $this->OutputData($report);
 }
Exemplo n.º 10
0
        ?>
					<span class="label"><?php 
        echo JText::_('INHERITED');
        ?>
</span>
				<?php 
    }
    ?>
		
			</td>
			<td>
				<?php 
    if (isset($rules->reports)) {
        ?>
					<?php 
        if (FSS_Permission::auth("fss.reports", "com_fss.reports", $row->user_id)) {
            ?>
						<span class="label label-success"><?php 
            echo JText::_('ALLOWED');
            ?>
</span>
					<?php 
        } else {
            ?>
						<span class="label label-important"><?php 
            echo JText::_('DENIED');
            ?>
</span>
					<?php 
        }
        ?>
Exemplo n.º 11
0
 function __construct($parent)
 {
     $this->comments = $parent;
     $this->comments->use_comments = 1;
     $this->comments->showheader = 0;
     $this->comments->show_item_select = 1;
     $this->comments->use_email = FSS_Settings::get('test_use_email');
     //FSJ_Settings::GetComponentSetting( fsj_get_com(), 'comments_email', 1 );
     $this->comments->use_website = FSS_Settings::get('test_use_website');
     //FSJ_Settings::GetComponentSetting( fsj_get_com(), 'comments_website', 1 );
     //$this->comments->opt_display = 0;
     $this->comments->add_a_comment = JText::_('ADD_A_TESTIMONIAL');
     $this->comments->post_comment = JText::_('POST_TESTIMONIAL');
     $this->email_title = "A Testimonial";
     $this->email_article_type = JText::_('PRODUCT');
     $this->description = JText::_('TESTIMONIALS');
     $this->descriptions = JText::_('TESTIMONIALS');
     $this->long_desc = JText::_('TESTIMONIALS');
     $this->article_link = "index.php?option=com_fss&view=test&prodid={id}";
     if (FSS_Settings::get('test_allow_no_product')) {
         $this->item_select_default = JText::_('GENERAL_TESTIMONIAL');
     } else {
         $this->item_select_default = JText::_('SELECT_PRODUCT');
         $this->item_select_must_have = 1;
     }
     if (FSS_Settings::get('test_who_can_add') == "anyone") {
         $this->comments->can_add = 1;
     } else {
         if (FSS_Settings::get('test_who_can_add') == "moderators") {
             if (!FSS_Permission::CanModerate()) {
                 $this->comments->can_add = 0;
             }
         } else {
             if (FSS_Settings::get('test_who_can_add') == "registered") {
                 if (JFactory::getUser()->id == 0) {
                     $this->comments->can_add = 0;
                 }
             } else {
                 // who can add is an ACL, so need to do the acl test
                 //echo "Testimonials ACL : " . FSS_Settings::get('test_who_can_add') . "<br>";
                 $user = JFactory::getUser();
                 $authed = $user->getAuthorisedViewLevels();
                 if (!in_array(FSS_Settings::get('test_who_can_add'), $authed)) {
                     $this->comments->can_add = 0;
                 } else {
                     $this->comments->can_add = 1;
                 }
             }
         }
     }
     // set up moderation
     $commod = FSS_Settings::get('test_moderate');
     $this->comments->moderate = 0;
     if ($commod == "all") {
         $this->comments->moderate = 1;
     } elseif ($commod == "guests") {
         if (JFactory::getUser()->id == 0) {
             $this->comments->moderate = 1;
         }
     } elseif ($commod == "registered") {
         if (!FSS_Permission::CanModerate()) {
             $this->comments->moderate = 1;
         }
     }
     if (FSS_Permission::CanModerate()) {
         $this->comments->moderate = 0;
     }
     $this->comments->dest_email = FSS_Settings::get('test_email_on_submit');
     $this->table = "#__fss_prod";
     $this->has_published = 1;
     $this->field_title = "title";
     $this->field_id = "id";
 }
Exemplo n.º 12
0
defined('_JEXEC') or die;
echo FSS_Helper::PageStylePopup(true);
echo FSS_Helper::PageTitlePopup(JText::_("Select related article"));
?>

<form method="post" action="<?php 
echo FSSRoute::x('&');
?>
" id="fssForm" name="fssForm">
	
	<div class="pull-right">
		<?php 
echo $this->filter_html['published'];
?>
		<?php 
if (FSS_Permission::auth("core.edit", "com_fss.kb")) {
    ?>
			<?php 
    echo $this->filter_html['userid'];
    ?>
		<?php 
}
?>

		<?php 
foreach ($this->fields[$this->pick_field]->filters as $filter) {
    ?>
			<?php 
    echo $this->filter_html[$filter->field];
    ?>
		<?php 
Exemplo n.º 13
0
			<span id="captcha_cont"><?php 
    echo $this->captcha;
    ?>
</span>
			<span class="help-inline"><?php 
    echo $this->errors['captcha'] ? $this->errors['captcha'] : FSS_Helper::HelpText("support_open_main_field_captcha");
    ?>
</span>
		</div>
	</div>
<?php 
}
?>

<?php 
if (FSS_Settings::get('support_choose_handler') == "user" || $this->admin_create > 0 && FSS_Settings::get('support_choose_handler') == "admin" || FSS_Settings::get('support_choose_handler') == "handlers" && FSS_Permission::auth("fss.handler", "com_fss.support_admin")) {
    ?>
	<?php 
    if (count($this->handlers) > 1) {
        ?>
		<div class="control-group cg-handler">
			<label class="control-label"><?php 
        echo JText::_("HANDLER");
        ?>
</label>
			<div class="controls">
				<select class='input-large' id='handler' name='handler'>

					<?php 
        if ($this->admin_create > 0) {
            ?>
Exemplo n.º 14
0
 static function getHandlersTicket($prodid, $deptid, $catid, $allownoauto = false, $assign_ticket = true, $explicit = false, $use_out_of_office = true)
 {
     $users = self::getHandlers($explicit, $use_out_of_office);
     $okusers = array();
     foreach ($users as $user) {
         $perm_set = "fss.handler.view";
         if (FSS_Permission::auth("fss.handler.assign.separate", "com_fss.support_admin", $user->id) && $assign_ticket) {
             $perm_set = "fss.handler.assign";
         }
         if (FSS_Permission::auth("fss.handler.dontassign", "com_fss.support_admin", $user->id) && !$allownoauto) {
             continue;
         }
         if ($prodid > 0 && !FSS_Permission::auth($perm_set . ".products", "com_fss.support_admin", $user->id)) {
             if (!FSS_Permission::auth($perm_set . ".product." . $prodid, "com_fss.support_admin", $user->id)) {
                 continue;
             }
         }
         if ($deptid > 0 && !FSS_Permission::auth($perm_set . ".departments", "com_fss.support_admin", $user->id)) {
             if (!FSS_Permission::auth($perm_set . ".department." . $deptid, "com_fss.support_admin", $user->id)) {
                 continue;
             }
         }
         //echo "Skip : Not department<br>";
         if ($catid > 0 && !FSS_Permission::auth($perm_set . ".categories", "com_fss.support_admin", $user->id)) {
             if (!FSS_Permission::auth($perm_set . ".category." . $catid, "com_fss.support_admin", $user->id)) {
                 continue;
             }
         }
         //echo "Skip : Not category<br>";
         $okusers[] = $user->id;
     }
     return $okusers;
 }
Exemplo n.º 15
0
'>
				<img src='<?php 
    echo JURI::root(true);
    ?>
/components/com_fss/assets/images/support/groups_16.png'>
				<?php 
    echo JText::_("GROUPS");
    ?>
			</a>
		</li>
	<?php 
}
?>

	<?php 
if (FSS_Permission::auth("fss.reports", "com_fss.reports")) {
    ?>
		<li class="<?php 
    if ($this->view == "admin_report") {
        echo "active";
    }
    ?>
">
			<a href='<?php 
    echo FSSRoute::_('index.php?option=com_fss&view=admin_report');
    ?>
'>
				<img src='<?php 
    echo JURI::root(true);
    ?>
/components/com_fss/assets/images/support/report_16.png'>
Exemplo n.º 16
0
 function auth($item)
 {
     return FSS_Permission::auth($item, $this->getAsset());
 }
Exemplo n.º 17
0
 function can_Close()
 {
     if (!$this->is_Restricted()) {
         return true;
     }
     return FSS_Permission::auth("fss.{$this->ticket_type}.close", "com_fss.support_admin", JFactory::getUser()->id);
 }
Exemplo n.º 18
0
echo FSS_Helper::PageTitle("Reports");
?>

<?php 
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin' . DS . 'snippet' . DS . '_tabbar.php');
?>

<?php 
$count = 0;
?>

<?php 
foreach ($this->reports as $report) {
    ?>
	<?php 
    if (!FSS_Permission::auth("fss.reports.report." . $report->name, "com_fss.reports") && !FSS_Permission::auth("fss.reports.all", "com_fss.reports")) {
        continue;
    }
    ?>
	<?php 
    $count++;
    ?>
	<div class="well well-mini">
	<div class="pull-right margin-mini vert-center">
			<a class="btn btn-default" href='<?php 
    echo JRoute::_('index.php?option=com_fss&view=admin_report&report=' . $report->name);
    ?>
'>
				<?php 
    echo JText::_('VIEW_REPORT');
    ?>
Exemplo n.º 19
0
 function CreateGroup()
 {
     if (!FSS_Permission::auth("fss.groups", "com_fss.groups")) {
         return FSS_Admin_Helper::NoPerm();
     }
     $this->creating = true;
     $this->group = new stdclass();
     $this->group->id = 0;
     $this->group->groupname = null;
     $this->group->description = null;
     $this->group->allsee = 0;
     $this->group->allemail = 0;
     $this->group->allprods = 1;
     $this->group->ccexclude = 0;
     $this->buildGroupEditForm();
     parent::display('group');
 }
Exemplo n.º 20
0
 static function AnyAdmin()
 {
     if (self::CanModerate()) {
         return true;
     }
     if (self::AdminGroups()) {
         return true;
     }
     if (self::PermAnyContent()) {
         return true;
     }
     if (FSS_Permission::auth("fss.handler", "com_fss.support_admin")) {
         return true;
     }
     if (FSS_Permission::auth("fss.reports", "com_fss.reports")) {
         return true;
     }
     return false;
 }
Exemplo n.º 21
0
 function display($tpl = null)
 {
     if (!FSS_Permission::auth("fss.view", "com_fss.glossary")) {
         return FSS_Helper::NoPerm();
     }
     $mainframe = JFactory::getApplication();
     $db = JFactory::getDBO();
     $aparams = FSS_Settings::GetViewSettingsObj('glossary');
     $this->use_letter_bar = $aparams->get('use_letter_bar', 0);
     $this->long_desc = $aparams->get('long_desc', 0);
     if ($this->use_letter_bar) {
         $this->letters = array();
         if (FSS_Settings::get('glossary_all_letters')) {
             $letters = array('A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z');
             foreach ($letters as $letter) {
                 $this->letters[$letter] = 0;
             }
         }
         $qry = "SELECT UPPER(SUBSTR(word,1,1)) as letter FROM #__fss_glossary";
         $where = array();
         $where[] = "published = 1";
         $where[] = 'language in (' . $db->Quote(JFactory::getLanguage()->getTag()) . ',' . $db->Quote('*') . ')';
         $user = JFactory::getUser();
         $where[] = 'access IN (' . implode(',', $user->getAuthorisedViewLevels()) . ')';
         if (count($where) > 0) {
             $qry .= " WHERE " . implode(" AND ", $where);
         }
         $qry .= " GROUP BY letter ORDER BY letter";
         $db->setQuery($qry);
         $letters = $db->loadObjectList();
         foreach ($letters as $letter) {
             $this->letters[$letter->letter] = 1;
         }
         if (count($this->letters) == 0) {
             return parent::display("empty");
         }
     }
     $this->curletter = "";
     // if we are showing on a per letter basis only
     if ($this->use_letter_bar == 2) {
         reset($this->letters);
         $this->curletter = FSS_Input::getString('letter', key($this->letters));
     }
     if (FSS_Input::getCmd('layout') == "word") {
         return $this->showWord();
     }
     $where = array();
     $where[] = "published = 1";
     $query = "SELECT * FROM #__fss_glossary";
     if ($this->curletter) {
         $where[] = "SUBSTR(word,1,1) = '" . FSSJ3Helper::getEscaped($db, $this->curletter) . "'";
     }
     $where[] = 'language in (' . $db->Quote(JFactory::getLanguage()->getTag()) . ',' . $db->Quote('*') . ')';
     $user = JFactory::getUser();
     $where[] = 'access IN (' . implode(',', $user->getAuthorisedViewLevels()) . ')';
     if (count($where) > 0) {
         $query .= " WHERE " . implode(" AND ", $where);
     }
     $query .= " ORDER BY word";
     $db->setQuery($query);
     $this->rows = $db->loadObjectList();
     $pathway = $mainframe->getPathway();
     if (FSS_Helper::NeedBaseBreadcrumb($pathway, array('view' => 'glossary'))) {
         $pathway->addItem("Glossary");
     }
     if (FSS_Settings::get('glossary_use_content_plugins')) {
         // apply plugins to article body
         $dispatcher = JDispatcher::getInstance();
         JPluginHelper::importPlugin('content');
         $art = new stdClass();
         $this->params = $mainframe->getParams('com_fss');
         foreach ($this->rows as &$row) {
             if ($row->description) {
                 $art->text = $row->description;
                 $art->noglossary = 1;
                 $results = $dispatcher->trigger('onContentPrepare', array('com_fss.glossary', &$art, &$this->params, 0));
                 $row->description = $art->text;
             }
             if ($row->longdesc) {
                 $art->text = $row->longdesc;
                 $art->noglossary = 1;
                 $results = $dispatcher->trigger('onContentPrepare', array('com_fss.glossary.long', &$art, &$this->params, 0));
                 $row->longdesc = $art->text;
             }
         }
     }
     FSS_Helper::IncludeModal();
     parent::display($tpl);
 }
Exemplo n.º 22
0
 * @package Freestyle Joomla
 * @author Freestyle Joomla
 * @copyright (C) 2013 Freestyle Joomla
 * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
**/
defined('_JEXEC') or die;
echo FSS_Helper::PageStyle();
echo FSS_Helper::PageTitle("CONTENT_MANAGEMENT");
?>

<?php 
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin' . DS . 'snippet' . DS . '_tabbar.php');
?>

<?php 
if (FSS_Permission::PermAnyContent()) {
    ?>
	<?php 
    include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_content' . DS . 'snippet' . DS . '_contentbar.php');
    ?>
	<?php 
    include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_content' . DS . 'snippet' . DS . '_overview.php');
} else {
    ?>
	No permission!
<?php 
}
?>


<?php 
Exemplo n.º 23
0
echo FSS_Helper::PageStyle();
echo FSS_Helper::PageTitle('SUPPORT_ADMIN', "VIEW_SUPPORT_TICKET");
?>

<?php 
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin' . DS . 'snippet' . DS . '_tabbar.php');
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_support' . DS . 'snippet' . DS . '_supportbar.php');
?>

<?php 
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_support' . DS . 'snippet' . DS . '_ticket_notices.php');
?>

<?php 
include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_support' . DS . 'snippet' . DS . '_ticket_toolbar.php');
if (FSS_Permission::auth("core.create", "com_fss.kb") || FSS_Permission::auth("core.create", "com_fss.faq")) {
    include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_support' . DS . 'snippet' . DS . '_export.php');
}
?>

<?php 
if (FSS_Settings::get("messages_at_top") == 2 || FSS_Settings::get("messages_at_top") == 3) {
    include $this->snippet(JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'views' . DS . 'admin_support' . DS . 'snippet' . DS . '_messages_cont.php');
}
?>

<?php 
echo FSS_Helper::PageSubTitle("TICKET_DETAILS");
?>

<?php 
Exemplo n.º 24
0
<?php

/**
 * @package Freestyle Joomla
 * @author Freestyle Joomla
 * @copyright (C) 2013 Freestyle Joomla
 * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
**/
defined('_JEXEC') or die;
if (!$this->parser) {
    $this->parser = new FSSParser();
    $this->parser->Load($this->template, $this->template_type);
}
$this->parser->Clear();
$moderation = "";
if (FSS_Permission::CanModerate() && array_key_exists('id', $this->comment)) {
    $lbl_type = "success";
    if ($this->comment['published'] == 0) {
        $lbl_type = "info";
    }
    if ($this->comment['published'] == 2) {
        $lbl_type = "warning";
    }
    $moderation .= '<span class="pull-right label label-' . $lbl_type . '">';
    $show_tick = "";
    $show_cross = "";
    $show_delete = "";
    $show_edit = "";
    if ($this->comment['published'] == 1) {
        $show_tick = "style='display: none'";
        $show_delete = "style='display: none'";
Exemplo n.º 25
0
        }
        ?>
		</div>
	<?php 
    }
    ?>

<?php 
}
?>

<?php 
if (FSS_Permission::CanModerate() && !$params->get('hide_moderate')) {
    ?>
	<?php 
    if (FSS_Permission::auth("fss.handler", "com_fss.support_admin") && !$params->get('hide_tickets')) {
        ?>
		<h4><?php 
        echo JText::_("MODERATE");
        ?>
</h4>
	<?php 
    }
    ?>
	
	<ul>
		<?php 
    $comments->DisplayModStatus("modstatus_module.php");
    ?>
	</ul>
	
Exemplo n.º 26
0
 function display($tpl = null)
 {
     $mainframe = JFactory::getApplication();
     $aparams = $mainframe->getPageParameters('com_fss');
     $this->template = $aparams->get('template');
     if ($this->template == "") {
         $this->template = "grid";
     }
     $this->show_desc = $aparams->get('show_desc');
     $this->mainwidth = $aparams->get('mainwidth');
     $this->maincolums = $aparams->get('maincolums');
     if ($this->maincolums == 0 || $this->maincolums == "") {
         $this->maincolums = 3;
     }
     $this->hideicons = $aparams->get('hideicons');
     $this->imagewidth = $aparams->get('imagewidth');
     if ($this->imagewidth == 0 || $this->imagewidth == "") {
         $this->imagewidth = 128;
     }
     $this->imageheight = $aparams->get('imageheight');
     if ($this->imageheight == 0 || $this->imageheight == "") {
         $this->imageheight = 128;
     }
     $this->border = $aparams->get('border');
     $this->info_top = $aparams->get('info_top');
     $this->info_well = $aparams->get('info_well');
     if ($this->info_top === null) {
         $this->info_top = 1;
     }
     if ($this->info_well === null) {
         $this->info_well = 1;
     }
     $db = JFactory::getDBO();
     $query = 'SELECT * FROM #__menu';
     $db->setQuery($query);
     $this->joomlamenus = $db->loadAssocList('id');
     // work out permissions, and if to show admin or not
     $showadmin = false;
     $showgroups = false;
     if (FSS_Permission::AnyAdmin()) {
         $showadmin = true;
     }
     if (FSS_Permission::AdminGroups()) {
         $showgroups = true;
     }
     $this->showadmin = $showadmin;
     if ($showadmin) {
         $this->getSupportOverView();
     }
     $query = 'SELECT * FROM #__fss_main_menu ';
     $where = array();
     if (!$showadmin) {
         $where[] = 'itemtype != 9';
     }
     if (!$showgroups) {
         $where[] = 'itemtype != 10';
     }
     // add language and access to query where
     $where[] = 'language in (' . $db->Quote(JFactory::getLanguage()->getTag()) . ',' . $db->Quote('*') . ')';
     $user = JFactory::getUser();
     $where[] = 'access IN (' . implode(',', $user->getAuthorisedViewLevels()) . ')';
     $where[] = "published = 1";
     if (count($where) > 0) {
         $query .= " WHERE " . implode(" AND ", $where);
     }
     $query .= " ORDER BY ordering";
     $db->setQuery($query);
     $this->menus = $db->loadAssocList('id');
     FSS_Translate_Helper::Tr($this->menus);
     $this->ValidateMenuLinks();
     parent::display();
 }
Exemplo n.º 27
0
            ?>
" class="fss_publish_button" state="<?php 
            echo $item['published'];
            ?>
">
								<?php 
            echo FSS_Helper::GetPublishedText($item['published']);
            ?>
							</a>
						</td>
					<?php 
        }
        ?>

					<?php 
        if (FSS_Permission::auth("core.edit", $this->getAsset())) {
            ?>
					<?php 
            if ($this->list_user) {
                ?>
						<td><?php 
                echo $item['name'];
                ?>
</td>
					<?php 
            }
            ?>
					<?php 
        }
        ?>
				</tr>
Exemplo n.º 28
0
 function display($tpl = null)
 {
     if (!FSS_Permission::auth("fss.view", "com_fss.kb")) {
         return FSS_Helper::NoPerm();
     }
     $mainframe = JFactory::getApplication();
     require_once JPATH_SITE . DS . 'components' . DS . 'com_fss' . DS . 'helper' . DS . 'content' . DS . 'kb.php';
     $this->content = new FSS_ContentEdit_KB();
     $this->content->Init();
     $this->pagetitle = "";
     $model = $this->getModel();
     $model->content = $this->content;
     $this->assign('search', '');
     $what = FSS_Input::getCmd('what');
     // basic permissions on article stats stop people seeing stats when disabled
     if (!FSS_Settings::get('kb_show_views')) {
         $what = "";
     }
     if ($what == "recent" && !FSS_Settings::get('kb_show_recent')) {
         $what = "";
     }
     if ($what == "viewed" && !FSS_Settings::get('kb_show_viewed')) {
         $what = "";
     }
     if ($what == "rated" && !FSS_Settings::get('kb_show_rated')) {
         $what = "";
     }
     $user = JFactory::getUser();
     $userid = $user->id;
     /*$db = JFactory::getDBO();
     		$query = "SELECT * FROM #__fss_user WHERE user_id = '".FSSJ3Helper::getEscaped($db, $userid)."'";
     		$db->setQuery($query);
     		$this->_permissions = $db->loadAssoc();*/
     $fileid = FSS_Input::getInt('fileid');
     if ($fileid > 0) {
         return $this->downloadFile();
     }
     FSS_Helper::IncludeModal();
     if ($what != "") {
         return $this->showWhat();
     }
     $search = FSS_Input::getString('kbsearch');
     if ($search != "") {
         return $this->searchArticles();
     }
     $search = FSS_Input::getString('prodsearch');
     if ($search != "") {
         return $this->searchProducts();
     }
     $kbartid = FSS_Input::getInt('kbartid');
     if ($kbartid > 0) {
         return $this->showArt();
     }
     $catid = FSS_Input::getInt('catid');
     if ($catid > 0) {
         return $this->showCat();
     }
     $prodid = FSS_Input::getInt('prodid');
     if ($prodid > 0) {
         return $this->showProd();
     }
     $this->showMain();
 }
Exemplo n.º 29
0
</a>			
			</td>
			<td>
			    <?php 
    echo $row->name;
    ?>
			
			</td>
			<td>
			    <?php 
    echo $row->email;
    ?>
			
			</td>
<?php 
    if (FSS_Permission::auth("fss.groups", "com_fss.groups")) {
        ?>
				
			<td>
				<?php 
        echo $row->lf1;
        ?>
			
			</td>
<?php 
    }
    ?>
	
		</tr>
        <?php 
    $k = 1 - $k;
Exemplo n.º 30
0
 function DoDeleteComment()
 {
     $commentid = FSS_Input::getInt('commentid', 0);
     if (!FSS_Permission::CanModerate()) {
         return;
     }
     if (!$commentid) {
         return;
     }
     $db = JFactory::getDBO();
     $qry = "DELETE FROM #__fss_comments WHERE id = '" . FSSJ3Helper::getEscaped($db, $commentid) . "'";
     $db->SetQuery($qry);
     $db->Query();
     exit;
     return true;
 }