Minor changes and fixes:
* Fixed provider disabling sync privileges problem. * Fixed backend/services categories tab footer position. * Corrected success message in frontent. * Fixed provider appointment link on emails (on manage mode). * Downcreased email header (in order to display bigger company names).
This commit is contained in:
parent
2f69889c36
commit
457b3212f9
8 changed files with 31 additions and 22 deletions
|
@ -196,7 +196,7 @@ class Backend_api extends CI_Controller {
|
|||
|
||||
$provider_title = 'Appointment details have changed.';
|
||||
$provider_message = '';
|
||||
$provider_link = $this->config->item('base_url') . 'backend/'
|
||||
$provider_link = $this->config->item('base_url') . 'backend/index/'
|
||||
. $appointment['hash'];
|
||||
}
|
||||
|
||||
|
@ -332,14 +332,15 @@ class Backend_api extends CI_Controller {
|
|||
*/
|
||||
public function ajax_disable_provider_sync() {
|
||||
try {
|
||||
if ($this->privileges[PRIV_USERS]['edit'] == FALSE) {
|
||||
throw new Exception('You do not have the required privileges for this task.');
|
||||
}
|
||||
|
||||
if (!isset($_POST['provider_id'])) {
|
||||
throw new Exception('Provider id not specified.');
|
||||
}
|
||||
|
||||
if ($this->privileges[PRIV_USERS]['edit'] == FALSE
|
||||
&& $this->session->userdata('user_id') != $_POST['provider_id']) {
|
||||
throw new Exception('You do not have the required privileges for this task.');
|
||||
}
|
||||
|
||||
$this->load->model('providers_model');
|
||||
$this->providers_model->set_setting('google_sync', FALSE, $_POST['provider_id']);
|
||||
$this->providers_model->set_setting('google_token', NULL, $_POST['provider_id']);
|
||||
|
|
|
@ -200,16 +200,18 @@
|
|||
}
|
||||
}
|
||||
|
||||
foreach($grouped_services as $group) {
|
||||
$group_label = ($group[0]['category_name'] != NULL)
|
||||
? $group[0]['category_name'] : 'Uncategorized';
|
||||
|
||||
echo '<optgroup label="' . $group_label . '">';
|
||||
foreach($group as $service) {
|
||||
echo '<option value="' . $service['id'] . '">'
|
||||
. $service['name'] . '</option>';
|
||||
foreach($grouped_services as $key => $group) {
|
||||
$group_label = ($key != 'uncategorized')
|
||||
? $group[0]['category_name'] : 'Uncategorized';
|
||||
|
||||
if (count($group) > 0) {
|
||||
echo '<optgroup label="' . $group_label . '">';
|
||||
foreach($group as $service) {
|
||||
echo '<option value="' . $service['id'] . '">'
|
||||
. $service['name'] . '</option>';
|
||||
}
|
||||
echo '</optgroup>';
|
||||
}
|
||||
echo '</optgroup>';
|
||||
}
|
||||
} else {
|
||||
foreach($available_services as $service) {
|
||||
|
|
|
@ -146,7 +146,7 @@
|
|||
'<div class="alert alert-success">' +
|
||||
'<h4>Success!</h4>' +
|
||||
'<p>' +
|
||||
'Your appointment has successfully been added to ' +
|
||||
'Your appointment has been added to ' +
|
||||
'your Google Calendar account. <br>' +
|
||||
'<a href="' + response.htmlLink + '" target="_blank">' +
|
||||
'Click here to view your appointment on Google ' +
|
||||
|
|
|
@ -6,8 +6,9 @@
|
|||
<div class="email-container" style="width: 650px;border: 1px solid #eee;">
|
||||
<div id="header" style="background-color: #3DD481; border-bottom: 4px solid #1A865F;
|
||||
height: 40px;padding: 10px 15px;">
|
||||
<strong id="logo" style="color: white; font-size: 31px;
|
||||
text-shadow: 1px 1px 1px #8F8888;">$company_name</strong>
|
||||
<strong id="logo" style="color: white; font-size: 24px;
|
||||
text-shadow: 1px 1px 1px #8F8888; margin-top: 5px; display: inline-block">
|
||||
$company_name</strong>
|
||||
</div>
|
||||
|
||||
<div id="content" style="padding: 10px 15px;">
|
||||
|
|
|
@ -6,8 +6,9 @@
|
|||
<div class="email-container" style="width: 650px;border: 1px solid #eee;">
|
||||
<div id="header" style="background-color: #3DD481; border-bottom: 4px solid #1A865F;
|
||||
height: 40px;padding: 10px 15px;">
|
||||
<strong id="logo" style="color: white; font-size: 31px;
|
||||
text-shadow: 1px 1px 1px #8F8888;">$company_name</strong>
|
||||
<strong id="logo" style="color: white; font-size: 24px;
|
||||
text-shadow: 1px 1px 1px #8F8888; margin-top: 5px; display: inline-block">
|
||||
$company_name</strong>
|
||||
</div>
|
||||
|
||||
<div id="content" style="padding: 10px 15px;">
|
||||
|
|
|
@ -6,8 +6,9 @@
|
|||
<div class="email-container" style="width: 650px;border: 1px solid #eee;">
|
||||
<div id="header" style="background-color: #3DD481; border-bottom: 4px solid #1A865F;
|
||||
height: 40px;padding: 10px 15px;">
|
||||
<strong id="logo" style="color: white; font-size: 31px;
|
||||
text-shadow: 1px 1px 1px #8F8888;">$company_name</strong>
|
||||
<strong id="logo" style="color: white; font-size: 24px;
|
||||
text-shadow: 1px 1px 1px #8F8888; margin-top: 5px; display: inline-block">
|
||||
$company_name</strong>
|
||||
</div>
|
||||
|
||||
<div id="content" style="padding: 10px 15px;">
|
||||
|
|
|
@ -610,7 +610,7 @@ var BackendCalendar = {
|
|||
}
|
||||
|
||||
// Display success message to the user.
|
||||
$dialog.find('.modal-message').text('Appointment saved successfully!');
|
||||
$dialog.find('.modal-message').text('Unavailable period saved successfully!');
|
||||
$dialog.find('.modal-message').removeClass('alert-error');
|
||||
$dialog.find('.modal-message').addClass('alert-success');
|
||||
$dialog.find('.modal-message').fadeIn();
|
||||
|
@ -680,6 +680,7 @@ var BackendCalendar = {
|
|||
$('#enable-sync i').addClass('icon-white');
|
||||
$('#enable-sync span').text('Disable Sync');
|
||||
$('#google-sync').prop('disabled', false);
|
||||
$('#select-filter-item option:selected').attr('google-sync', 'true');
|
||||
}
|
||||
}
|
||||
}, 100);
|
||||
|
@ -699,6 +700,7 @@ var BackendCalendar = {
|
|||
$('#enable-sync i').removeClass('icon-white');
|
||||
$('#enable-sync span').text('Enable Sync');
|
||||
$('#google-sync').prop('disabled', true);
|
||||
$('#select-filter-item option:selected').attr('google-sync', 'false');
|
||||
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -69,6 +69,7 @@ var BackendServices = {
|
|||
BackendServices.helper.resetForm();
|
||||
BackendServices.helper.filter('');
|
||||
$('.filter-key').val('');
|
||||
Backend.placeFooterToBottom();
|
||||
});
|
||||
|
||||
ServicesHelper.prototype.bindEventHandlers();
|
||||
|
|
Loading…
Reference in a new issue