Change reception sound + improve format for accessing datas of contact in template

This commit is contained in:
osaajani 2020-05-30 20:21:41 +02:00
parent 87301827bd
commit fdb01ffabc
8 changed files with 18 additions and 4 deletions

View File

@ -88,7 +88,7 @@ namespace adapters;
* @return array : [ * @return array : [
* bool 'error' => false if no error, true else * bool 'error' => false if no error, true else
* ?string 'error_message' => null if no error, else error message * ?string 'error_message' => null if no error, else error message
* array 'uid' => Uid of the sms created on success * ?string 'uid' => Uid of the sms created on success
* ] * ]
*/ */
public function send(string $destination, string $text, bool $flash = false); public function send(string $destination, string $text, bool $flash = false);

View File

@ -171,7 +171,7 @@ namespace adapters;
* @return array : [ * @return array : [
* bool 'error' => false if no error, true else * bool 'error' => false if no error, true else
* ?string 'error_message' => null if no error, else error message * ?string 'error_message' => null if no error, else error message
* array 'uid' => Uid of the sms created on success * ?string 'uid' => Uid of the sms created on success
* ] * ]
*/ */
public function send(string $destination, string $text, bool $flash = false) public function send(string $destination, string $text, bool $flash = false)

View File

@ -365,6 +365,12 @@ footer img
margin-top: 20px; margin-top: 20px;
} }
#adapter-datas-fields
{
padding-top: 15px;
padding-left: 15px;
}
/* DATATABLES */ /* DATATABLES */
.dataTables_paginate .dataTables_paginate
{ {
@ -375,3 +381,11 @@ footer img
{ {
width: 20px; width: 20px;
} }
/*
* FORMS
*/
.form-group
{
margin-bottom: 30px;
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -335,7 +335,7 @@ namespace controllers\internals;
if ((int) ($users_settings[$scheduled['id_user']]['templating'] ?? false)) if ((int) ($users_settings[$scheduled['id_user']]['templating'] ?? false))
{ {
$contact['datas'] = json_decode($contact['datas'], true); $contact['datas'] = json_decode($contact['datas'], true);
$datas = ['contact' => $contact]; $datas = ['contact' => $contact['datas']];
$render = $internal_templating->render($scheduled['text'], $datas); $render = $internal_templating->render($scheduled['text'], $datas);
if (!$render['success']) if (!$render['success'])

View File

@ -69,7 +69,7 @@ namespace controllers\publics;
$contact['datas'] = json_decode($contact['datas'], true); $contact['datas'] = json_decode($contact['datas'], true);
$datas = [ $datas = [
'contact' => $contact, 'contact' => $contact['datas'],
]; ];
$result = $this->internal_templating->render($template, $datas); $result = $this->internal_templating->render($template, $datas);