Version 0.1.4

This commit is contained in:
dmzx
2015-09-18 20:14:51 +02:00
parent 915baec526
commit 2135b21de6
5 changed files with 19 additions and 20 deletions

View File

@@ -3,7 +3,7 @@
"type": "phpbb-extension", "type": "phpbb-extension",
"description": "mChat Extension for phpbb 3.1.x", "description": "mChat Extension for phpbb 3.1.x",
"homepage": "http://www.dmzx-web.net", "homepage": "http://www.dmzx-web.net",
"version": "0.1.3", "version": "0.1.4",
"time": "2015-03-10", "time": "2015-03-10",
"keywords": ["phpbb", "extension", "mchat"], "keywords": ["phpbb", "extension", "mchat"],
"license": "GPL-2.0", "license": "GPL-2.0",

View File

@@ -54,7 +54,6 @@ services:
- @log - @log
- @dbal.conn - @dbal.conn
- @cache - @cache
- @service_container
- %core.table_prefix% - %core.table_prefix%
- %dmzx.mchat.table.mchat% - %dmzx.mchat.table.mchat%
- %dmzx.mchat.table.mchat_config% - %dmzx.mchat.table.mchat_config%

View File

@@ -27,9 +27,6 @@ class functions_mchat
/** @var \phpbb\cache\service */ /** @var \phpbb\cache\service */
protected $cache; protected $cache;
/** @var \phpbb\event\dispatcher_interface */
protected $dispatcher;
protected $table_prefix; protected $table_prefix;
/** /**
@@ -53,14 +50,13 @@ class functions_mchat
* @param \phpbb\cache\service $cache * @param \phpbb\cache\service $cache
* @param $table_prefix * @param $table_prefix
*/ */
public function __construct(\phpbb\template\template $template, \phpbb\user $user, \phpbb\auth\auth $auth, \phpbb\log\log_interface $log, \phpbb\db\driver\driver_interface $db, \phpbb\cache\service $cache, $dispatcher, $table_prefix, $mchat_table, $mchat_config_table, $mchat_sessions_table) public function __construct(\phpbb\template\template $template, \phpbb\user $user, \phpbb\auth\auth $auth, \phpbb\log\log_interface $log, \phpbb\db\driver\driver_interface $db, \phpbb\cache\service $cache, $table_prefix, $mchat_table, $mchat_config_table, $mchat_sessions_table)
{ {
$this->template = $template; $this->template = $template;
$this->user = $user; $this->user = $user;
$this->auth = $auth; $this->auth = $auth;
$this->db = $db; $this->db = $db;
$this->cache = $cache; $this->cache = $cache;
$this->dispatcher = $dispatcher;
$this->phpbb_log = $log; $this->phpbb_log = $log;
$this->table_prefix = $table_prefix; $this->table_prefix = $table_prefix;
$this->mchat_table = $mchat_table; $this->mchat_table = $mchat_table;
@@ -386,16 +382,4 @@ class functions_mchat
} }
$this->db->sql_freeresult($result); $this->db->sql_freeresult($result);
} }
function functions_mchat_aft()
{
/**
* Event functions_mchat_aft
*
* @event dmzx.mchat.core.functions_mchat_aft
* @since 0.1.2
*/
$this->dispatcher->trigger_event('dmzx.mchat.core.functions_mchat_aft');
}
} }

View File

@@ -806,6 +806,14 @@ class render_helper
// If read mode request set true // If read mode request set true
$mchat_read_mode = true; $mchat_read_mode = true;
/**
* Event render_helper_edit
*
* @event dmzx.mchat.core.render_helper_edit
* @since 0.1.4
*/
$this->dispatcher->trigger_event('dmzx.mchat.core.render_helper_edit');
break; break;
// Delete function... // Delete function...
@@ -837,6 +845,14 @@ class render_helper
throw new \phpbb\exception\http_exception(403, 'MCHAT_ERROR_FORBIDDEN'); throw new \phpbb\exception\http_exception(403, 'MCHAT_ERROR_FORBIDDEN');
} }
/**
* Event render_helper_delete
*
* @event dmzx.mchat.core.render_helper_delete
* @since 0.1.4
*/
$this->dispatcher->trigger_event('dmzx.mchat.core.render_helper_delete');
// Run delete! // Run delete!
$sql = 'DELETE FROM ' . $this->mchat_table . ' $sql = 'DELETE FROM ' . $this->mchat_table . '
WHERE message_id = ' . (int) $message_id; WHERE message_id = ' . (int) $message_id;

View File

@@ -11,7 +11,7 @@ namespace dmzx\mchat\migrations;
class mchat_schema extends \phpbb\db\migration\migration class mchat_schema extends \phpbb\db\migration\migration
{ {
var $ext_version = '0.1.3'; var $ext_version = '0.1.4';
public function update_data() public function update_data()
{ {