◆ prepare()
◆ step_1()
| ilMailDatabaseUpdateSteps::step_1 |
( |
| ) |
|
Definition at line 30 of file class.ilMailDatabaseUpdateSteps.php.
32 if ($this->db->tableExists(
'mail') && $this->db->tableColumnExists(
'mail',
'm_email')) {
33 $this->db->dropTableColumn(
'mail',
'm_email');
◆ step_10()
| ilMailDatabaseUpdateSteps::step_10 |
( |
| ) |
|
Definition at line 157 of file class.ilMailDatabaseUpdateSteps.php.
159 if (!$this->db->tableColumnExists(
'mail_options',
'absence_ar_subject')) {
160 $this->db->addTableColumn(
162 'absence_ar_subject',
◆ step_11()
| ilMailDatabaseUpdateSteps::step_11 |
( |
| ) |
|
Definition at line 173 of file class.ilMailDatabaseUpdateSteps.php.
175 if (!$this->db->tableExists(
'mail_auto_responder')) {
176 $this->db->createTable(
177 'mail_auto_responder',
190 'type' =>
'timestamp',
195 $this->db->addPrimaryKey(
'mail_auto_responder', [
'sender_id',
'receiver_id']);
◆ step_12()
| ilMailDatabaseUpdateSteps::step_12 |
( |
| ) |
|
Definition at line 199 of file class.ilMailDatabaseUpdateSteps.php.
References $res, ILIAS\LTI\ToolProvider\$settings, and ilDBConstants\T_TEXT.
202 'mail_system_sys_signature',
203 'mail_system_usr_from_name',
207 $res = $this->db->queryF(
208 "SELECT value FROM settings WHERE keyword = %s AND value IS NOT NULL AND value != ''",
212 if ($this->db->numRows(
$res) === 1) {
213 $value = $this->db->fetchAssoc(
$res)[
'value'] ??
'';
218 $value = preg_replace(
224 $this->db->manipulateF(
225 'UPDATE settings SET value = %s WHERE keyword = %s',
◆ step_2()
| ilMailDatabaseUpdateSteps::step_2 |
( |
| ) |
|
Definition at line 37 of file class.ilMailDatabaseUpdateSteps.php.
39 $result = $this->db->queryF(
'SELECT value FROM settings WHERE module = %s AND keyword = %s', [
'text',
'text'], [
'common',
'mail_system_sys_signature']);
40 $row = $this->db->fetchAssoc($result);
41 if (isset($row[
'value']) && $row[
'value'] !==
'') {
42 $new_value = str_replace([
'[CLIENT_NAME]',
'[CLIENT_DESC]',
'[CLIENT_URL]'], [
'[INSTALLATION_NAME]',
'[INSTALLATION_DESC]',
'[ILIAS_URL]'], $row[
'value']);
43 if ($new_value !== $row[
'value']) {
44 $this->db->manipulateF(
45 'UPDATE settings SET value = %s WHERE module = %s AND keyword = %s',
46 [
'text',
'text',
'text'],
47 [$new_value,
'common',
'mail_system_sys_signature']
◆ step_3()
| ilMailDatabaseUpdateSteps::step_3 |
( |
| ) |
|
Definition at line 53 of file class.ilMailDatabaseUpdateSteps.php.
55 $result = $this->db->query(
"SELECT tpl_id, m_message FROM mail_man_tpl WHERE m_message LIKE '%[CLIENT_NAME]%'");
56 while ($row = $this->db->fetchAssoc($result)) {
57 if (isset($row[
'm_message'], $row[
'tpl_id']) && $row[
'm_message'] !==
'' && $row[
'tpl_id'] !==
'') {
58 $new_value = str_replace(
'[CLIENT_NAME]',
'[INSTALLATION_NAME]', $row[
'm_message']);
59 if ($new_value !== $row[
'm_message']) {
60 $this->db->manipulateF(
61 'UPDATE mail_man_tpl SET m_message = %s WHERE tpl_id = %s',
63 [$new_value, $row[
'tpl_id']]
◆ step_4()
| ilMailDatabaseUpdateSteps::step_4 |
( |
| ) |
|
Definition at line 70 of file class.ilMailDatabaseUpdateSteps.php.
72 $result = $this->db->query(
"SELECT lang, type, body FROM mail_template WHERE body LIKE '%[CLIENT_NAME]%'");
73 while ($row = $this->db->fetchAssoc($result)) {
74 if (isset($row[
'lang'], $row[
'type'], $row[
'body']) && $row[
'body'] !==
'') {
75 $new_value = str_replace(
'[CLIENT_NAME]',
'[INSTALLATION_NAME]', $row[
'body']);
76 if ($new_value !== $row[
'body']) {
77 $this->db->manipulateF(
78 'UPDATE mail_template SET body = %s WHERE lang = %s AND type = %s',
79 [
'text',
'text',
'text'],
80 [$new_value, $row[
'lang'], $row[
'type']]
◆ step_5()
| ilMailDatabaseUpdateSteps::step_5 |
( |
| ) |
|
Definition at line 87 of file class.ilMailDatabaseUpdateSteps.php.
89 if ($this->db->tableExists(
'mail_options') && $this->db->tableColumnExists(
'mail_options',
'linebreak')) {
90 $this->db->dropTableColumn(
'mail_options',
'linebreak');
◆ step_6()
| ilMailDatabaseUpdateSteps::step_6 |
( |
| ) |
|
◆ step_7()
| ilMailDatabaseUpdateSteps::step_7 |
( |
| ) |
|
◆ step_8()
| ilMailDatabaseUpdateSteps::step_8 |
( |
| ) |
|
◆ step_9()
| ilMailDatabaseUpdateSteps::step_9 |
( |
| ) |
|
◆ $db
The documentation for this class was generated from the following file: