mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-12-25 16:13:17 +03:00
Converted normal functions to arrow functions
This commit is contained in:
parent
34fbd2060d
commit
f14643725d
2 changed files with 6 additions and 6 deletions
|
@ -48,7 +48,7 @@ App.Pages.Account = (function () {
|
|||
|
||||
let missingRequiredFields = false;
|
||||
|
||||
$('#account .required').each(function (index, requiredField) {
|
||||
$('#account .required').each((index, requiredField) => {
|
||||
const $requiredField = $(requiredField);
|
||||
|
||||
if (!$requiredField.val()) {
|
||||
|
@ -154,7 +154,7 @@ App.Pages.Account = (function () {
|
|||
|
||||
const account = serialize();
|
||||
|
||||
App.Http.Account.save(account).done(function () {
|
||||
App.Http.Account.save(account).done(() => {
|
||||
Backend.displayNotification(App.Lang.settings_saved);
|
||||
|
||||
$footerUserDisplayName.text('Hello, ' + $firstName.val() + ' ' + $lastName.val() + '!');
|
||||
|
|
|
@ -30,7 +30,7 @@ App.Pages.GeneralSettings = (function () {
|
|||
|
||||
let missingRequiredFields = false;
|
||||
|
||||
$('#general-settings .required').each(function (index, requiredField) {
|
||||
$('#general-settings .required').each((index, requiredField) => {
|
||||
const $requiredField = $(requiredField);
|
||||
|
||||
if (!$requiredField.val()) {
|
||||
|
@ -51,7 +51,7 @@ App.Pages.GeneralSettings = (function () {
|
|||
}
|
||||
|
||||
function serialize(generalSettings) {
|
||||
generalSettings.forEach(function (generalSetting) {
|
||||
generalSettings.forEach((generalSetting) => {
|
||||
$('[data-field="' + generalSetting.name + '"]').val(generalSetting.value);
|
||||
});
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ App.Pages.GeneralSettings = (function () {
|
|||
function deserialize() {
|
||||
const generalSettings = [];
|
||||
|
||||
$('[data-field]').each(function (index, field) {
|
||||
$('[data-field]').each((index, field) => {
|
||||
const $field = $(field);
|
||||
|
||||
generalSettings.push({
|
||||
|
@ -83,7 +83,7 @@ App.Pages.GeneralSettings = (function () {
|
|||
|
||||
const generalSettings = deserialize();
|
||||
|
||||
App.Http.GeneralSettings.save(generalSettings).done(function () {
|
||||
App.Http.GeneralSettings.save(generalSettings).done(() => {
|
||||
Backend.displayNotification(App.Lang.settings_saved);
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue