Renamed JavaScript variables isValidated to isValid in the forms.

This commit is contained in:
依瑪貓 2021-08-27 07:35:03 +08:00
parent dec53c09f3
commit 62b59e7380
2 changed files with 14 additions and 14 deletions

View File

@ -96,10 +96,10 @@ function updateParent(code) {
* @private
*/
function validateForm() {
let isValidated = true;
isValidated = isValidated && validateCode();
isValidated = isValidated && validateTitle();
return isValidated;
let isValid = true;
isValid = isValid && validateCode();
isValid = isValid && validateTitle();
return isValid;
}
/**

View File

@ -337,28 +337,28 @@ function resetRecordButtons() {
* @private
*/
function validateForm() {
let isValidated = true;
isValidated = isValidated && validateDate();
let isValid = true;
isValid = isValid && validateDate();
$(".debit-record").each(function () {
isValidated = isValidated && validateRecord(this);
isValid = isValid && validateRecord(this);
});
$(".credit-account").each(function () {
isValidated = isValidated && validateRecord(this);
isValid = isValid && validateRecord(this);
});
$(".record-account").each(function () {
isValidated = isValidated && validateAccount(this);
isValid = isValid && validateAccount(this);
});
$(".record-summary").each(function () {
isValidated = isValidated && validateSummary(this);
isValid = isValid && validateSummary(this);
});
$(".record-amount").each(function () {
isValidated = isValidated && validateAmount(this);
isValid = isValid && validateAmount(this);
});
if (isTransfer()) {
isValidated = isValidated && validateBalance();
isValid = isValid && validateBalance();
}
isValidated = isValidated && validateNote();
return isValidated;
isValid = isValid && validateNote();
return isValid;
}
/**