AnonSec Shell
Server IP : 54.36.91.62  /  Your IP : 216.73.217.112
Web Server : Apache
System : Linux webm013.cluster127.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : coopiak ( 151928)
PHP Version : 8.3.23
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/coopiak/amisdesseniors-fr/nice2/administrator/components/com_jlexreview/models/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/coopiak/amisdesseniors-fr/nice2/administrator/components/com_jlexreview/models/mailq.php
<?php
/**
 * @package     JLex Review
 * @version     4.2.3
 * @copyright   Copyright (c) 2013-2018 JLexArt. All rights reserved
 * @license     GNU General Public License version 2 or later;
 * @author      www.jlexart.com
 */

defined('_JEXEC') or die;

class JLexReviewModelMailQ extends JModelLegacy
{
	public $limitstart = 0;

	public $limit = 20;

	public $total = 0;

    public $sort = "m.created_time DESC";

	public function getMailQueries()
	{
		$query 	= $this->_db->getQuery(true);
		$query->select("SQL_CALC_FOUND_ROWS m.*")
              ->select("u.username r_name, u.email r_email")
			  ->from("#__jlexreview_notification AS m")
              ->leftJoin("#__users AS u ON m.user_remind=u.id")

              ->select("IF(m.created_by>0,u2.username,m.guest_name) s_name")
              ->leftJoin("#__users AS u2 ON m.created_by=u2.id")
              ->where("IF(m.created_by>0,m.created_by!=m.user_remind,1)")
              ->order($this->sort);

		$items = $this->_db->setQuery($query, $this->limitstart, $this->limit)->loadObjectList();
		$this->total = $this->_db->setQuery("SELECT FOUND_ROWS()" )->loadResult();

		if(!$items) return null;

        foreach($items as $k=>$item)
        {
            $items[$k]->created_time = JHtml::date($item->created_time, $this->_db->getDateFormat());
            $items[$k]->sender_jprofile = JUri::base(true) . "/index.php?option=com_users&task=user.edit&id=" . $item->created_by;
            $items[$k]->receiver_jprofile = JUri::base(true) . "/index.php?option=com_users&task=user.edit&id=" . $item->user_remind;

            $items[$k]->action_text = "Unknown";
            switch ($item->action_type)
            {
                case "CM_REVIEW":
                    $items[$k]->action_text = JText::_("JR_COMMENT_REVIEW");
                    break;

                case "CM_REPLY":
                    $items[$k]->action_text = JText::_("JR_REPLY_COMMENT");
                    break;

                case "REVIEW_ADDED":
                	$items[$k]->action_text = JText::_("JR_REVIEW_ADDED");
                	break;

                case "REVIEW_MODIFIED":
                	$items[$k]->action_text = JText::_("JR_REVIEW_MODIFIED");
                	break;

                case "CM_ADDED":
                	$items[$k]->action_text = JText::_("JR_COMMENT_ADDED");
                	break;

                case "CM_MODIFIED":
                	$items[$k]->action_text = JText::_("JR_COMMENT_MODIFIED");
                	break;
            }

            if($item->user_remind==0)
            {
            	$items[$k]->r_name = JText::_("JR_ADMIN_MOD");
            }
        }
		
		return $items;
	}

	public function getPagaNav()
	{
		jimport('joomla.html.pagination');
		return new JPagination($this->total, $this->limitstart, $this->limit);
	}

    public function cmd($task)
    {
        $app = JFactory::getApplication();
        $cid = $app->input->get("cid", null, "array");

        if(empty($cid) || !count($cid))
        {
            $this->setError("No row select.");
            return false;
        }

        $query = $this->_db->getQuery(true);

        switch ($task)
        {
            case "marksent":
            case "markpending":
                $query->update("#__jlexreview_notification")
                      ->set("sent=".($task=="marksent"?1:0))
                      ->where("id IN(".implode(",", $cid).")");
                break;

            case "remove":
                $query->delete("#__jlexreview_notification")
                      ->where("id IN(".implode(",", $cid).")");
                break;
        }

        $this->_db->setQuery($query)->execute();

        return true;
    }
}

Anon7 - 2022
AnonSec Team