No calendars are being displayed in the calendar table view while being logged in as a secretary (#1418)
This commit is contained in:
parent
e6b3ffd66b
commit
65aacce924
2 changed files with 3 additions and 1 deletions
|
@ -615,6 +615,8 @@ class Providers_model extends EA_Model
|
||||||
->result_array();
|
->result_array();
|
||||||
|
|
||||||
foreach ($providers as &$provider) {
|
foreach ($providers as &$provider) {
|
||||||
|
$this->cast($provider);
|
||||||
|
|
||||||
$provider['settings'] = $this->db->get_where('user_settings', ['id_users' => $provider['id']])->row_array();
|
$provider['settings'] = $this->db->get_where('user_settings', ['id_users' => $provider['id']])->row_array();
|
||||||
|
|
||||||
unset(
|
unset(
|
||||||
|
|
|
@ -403,7 +403,7 @@ App.Utils.CalendarTableView = (function () {
|
||||||
(provider) =>
|
(provider) =>
|
||||||
vars('role_slug') === App.Layouts.Backend.DB_SLUG_ADMIN ||
|
vars('role_slug') === App.Layouts.Backend.DB_SLUG_ADMIN ||
|
||||||
(vars('role_slug') === App.Layouts.Backend.DB_SLUG_SECRETARY &&
|
(vars('role_slug') === App.Layouts.Backend.DB_SLUG_SECRETARY &&
|
||||||
vars('secretary_providers').indexOf(provider.id) !== -1) ||
|
vars('secretary_providers').indexOf(Number(provider.id)) !== -1) ||
|
||||||
(vars('role_slug') === App.Layouts.Backend.DB_SLUG_PROVIDER &&
|
(vars('role_slug') === App.Layouts.Backend.DB_SLUG_PROVIDER &&
|
||||||
Number(provider.id) === Number(vars('user_id')))
|
Number(provider.id) === Number(vars('user_id')))
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue