forked from mirrors/easyappointments
Rename $adminId selector variable to $id.
This commit is contained in:
parent
7481ebca65
commit
a513ee895e
1 changed files with 4 additions and 4 deletions
|
@ -16,7 +16,7 @@
|
||||||
*/
|
*/
|
||||||
App.Pages.Admins = (function () {
|
App.Pages.Admins = (function () {
|
||||||
const $admins = $('#admins');
|
const $admins = $('#admins');
|
||||||
const $adminId = $('#admin-id');
|
const $id = $('#admin-id');
|
||||||
const $firstName = $('#admin-first-name');
|
const $firstName = $('#admin-first-name');
|
||||||
const $lastName = $('#admin-last-name');
|
const $lastName = $('#admin-last-name');
|
||||||
const $email = $('#admin-email');
|
const $email = $('#admin-email');
|
||||||
|
@ -197,7 +197,7 @@ App.Pages.Admins = (function () {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Include id if changed.
|
// Include id if changed.
|
||||||
if ($adminId.val() !== '') {
|
if ($id.val() !== '') {
|
||||||
admin.id = $('#admin-id').val();
|
admin.id = $('#admin-id').val();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -214,7 +214,7 @@ App.Pages.Admins = (function () {
|
||||||
* Cancel add or edit of an admin record.
|
* Cancel add or edit of an admin record.
|
||||||
*/
|
*/
|
||||||
$admins.on('click', '#cancel-admin', function () {
|
$admins.on('click', '#cancel-admin', function () {
|
||||||
const id = $adminId.val();
|
const id = $id.val();
|
||||||
|
|
||||||
resetForm();
|
resetForm();
|
||||||
|
|
||||||
|
@ -330,7 +330,7 @@ App.Pages.Admins = (function () {
|
||||||
* @param {Object} admin Contains the admin record data.
|
* @param {Object} admin Contains the admin record data.
|
||||||
*/
|
*/
|
||||||
function display(admin) {
|
function display(admin) {
|
||||||
$adminId.val(admin.id);
|
$id.val(admin.id);
|
||||||
$firstName.val(admin.first_name);
|
$firstName.val(admin.first_name);
|
||||||
$lastName.val(admin.last_name);
|
$lastName.val(admin.last_name);
|
||||||
$email.val(admin.email);
|
$email.val(admin.email);
|
||||||
|
|
Loading…
Reference in a new issue