cloud-ide-model-schema
Version:
Pachage for schema management of Cloud IDEsys LMS
29 lines (28 loc) • 963 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.MPinCodeSelect = void 0;
/* INTERFACE END */
/* MODEL START */
var MPinCodeSelect = /** @class */ (function () {
function MPinCodeSelect(init) {
Object.assign(this, init);
}
MPinCodeSelect.prototype.Validate = function () {
var _a;
var errorLogger = {};
if (!this.sypin_pincode) {
errorLogger.sypin_pincode = "Pin Code is Required!";
}
else if (!this.sypin_id && !this.sypin_pincode) {
errorLogger.sypin_id = "Pin Code ID is Required!";
}
else if (this.sypin_pincode) {
if (((_a = this.sypin_pincode) === null || _a === void 0 ? void 0 : _a.length) < 5) {
errorLogger.sypin_pincode = "Pin Code must be 5 characters";
}
}
return errorLogger;
};
return MPinCodeSelect;
}());
exports.MPinCodeSelect = MPinCodeSelect;