diff --git a/src/api/middlewares/register.middleware.ts b/src/api/middlewares/register.middleware.ts index f47b8c33e..cff49b365 100644 --- a/src/api/middlewares/register.middleware.ts +++ b/src/api/middlewares/register.middleware.ts @@ -100,8 +100,8 @@ export class RegisterMiddleware implements NestMiddleware { }, HttpStatus.BAD_REQUEST); } const result: any = {}; - if (usrName.length < 8) { - result.username = 'Nama Pengguna Minimal 8 Huruf'; + if (usrName.length < 6) { + result.username = 'Nama Pengguna Minimal 6 Huruf'; } if (!req.body.email.match(/^[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$/)) { result.email = 'Email Tidak Valid'; diff --git a/src/app/_pages/register/register.component.html b/src/app/_pages/register/register.component.html index 78bcfa703..a7cb71684 100644 --- a/src/app/_pages/register/register.component.html +++ b/src/app/_pages/register/register.component.html @@ -18,7 +18,7 @@

Hai, Selamat Datang! >_<"

@@ -30,7 +30,7 @@

Hai, Selamat Datang! >_<"

Username Tidak Boleh Kosong
- Username Minimal 8 Huruf
+ Username Minimal 6 Huruf
Username Hanya Boleh Huruf Kecil Dan Angka
@@ -84,13 +84,13 @@

Hai, Selamat Datang! >_<"

+ }}" placeholder="Password Minimal 6 Huruf" required formControlName="password" autocomplete="current-password, new-password" /> Password Tidak Boleh Kosong
- Password Minimal 8 Huruf
+ Password Minimal 6 Huruf
Password Hanya Boleh Huruf Standar Papan Ketik
diff --git a/src/app/_pages/register/register.component.ts b/src/app/_pages/register/register.component.ts index 4eb1af469..78a954861 100644 --- a/src/app/_pages/register/register.component.ts +++ b/src/app/_pages/register/register.component.ts @@ -88,10 +88,10 @@ export class RegisterComponent implements OnInit, OnDestroy { initForm(): void { this.fg = this.fb.group({ - username: [null, [Validators.required, Validators.minLength(8), Validators.pattern(/^[a-z0-9]+$/)]], + username: [null, [Validators.required, Validators.minLength(6), Validators.pattern(/^[a-z0-9]+$/)]], name: [null, [Validators.required, Validators.pattern(/^[a-zA-Z. ]+$/)]], email: [null, [Validators.required, Validators.email, Validators.pattern(CONSTANTS.regexEmail)]], - password: [null, [Validators.required, Validators.minLength(8), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]], + password: [null, [Validators.required, Validators.minLength(6), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]], agree_tatib: [null, [Validators.required]], agree_pp: [null, [Validators.required]], 'g-recaptcha-response': [null, [Validators.required, Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]] diff --git a/src/app/_pages/reset-password/reset-password.component.html b/src/app/_pages/reset-password/reset-password.component.html index 84cb6d23d..430b32855 100644 --- a/src/app/_pages/reset-password/reset-password.component.html +++ b/src/app/_pages/reset-password/reset-password.component.html @@ -78,13 +78,13 @@

Hikz, Akun Kamu Kenapa (?)

+ }}" placeholder="Password Minimal 6 Huruf" required formControlName="password" autocomplete="password" /> Password Tidak Boleh Kosong
- Password Minimal 8 Huruf
+ Password Minimal 6 Huruf
Password Hanya Boleh Huruf Standar Papan Ketik
diff --git a/src/app/_pages/reset-password/reset-password.component.ts b/src/app/_pages/reset-password/reset-password.component.ts index aaa9b0ec0..1c17c2848 100644 --- a/src/app/_pages/reset-password/reset-password.component.ts +++ b/src/app/_pages/reset-password/reset-password.component.ts @@ -117,7 +117,7 @@ export class ResetPasswordComponent implements OnInit, AfterViewInit, OnDestroy }); this.fg2 = this.fb.group({ token: [null, [Validators.required, Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]], - password: [null, [Validators.required, Validators.minLength(8), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]] + password: [null, [Validators.required, Validators.minLength(6), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)]] }); } diff --git a/src/app/_pages/user/user-edit/user-edit.component.html b/src/app/_pages/user/user-edit/user-edit.component.html index d359c58db..665a653b2 100644 --- a/src/app/_pages/user/user-edit/user-edit.component.html +++ b/src/app/_pages/user/user-edit/user-edit.component.html @@ -86,7 +86,7 @@

Password Tidak Boleh Kosong
-
Password Minimal 8 Huruf
+
Password Minimal 6 Huruf
Password Hanya Boleh Huruf Standar Papan Ketik
@@ -98,7 +98,7 @@

-
Password Minimal 8 Huruf
+
Password Minimal 6 Huruf
Password Hanya Boleh Huruf Standar Papan Ketik
diff --git a/src/app/_pages/user/user-edit/user-edit.component.ts b/src/app/_pages/user/user-edit/user-edit.component.ts index 4f7b1a9f7..d24c54ee5 100644 --- a/src/app/_pages/user/user-edit/user-edit.component.ts +++ b/src/app/_pages/user/user-edit/user-edit.component.ts @@ -120,8 +120,8 @@ export class UserEditComponent implements OnInit, OnDestroy { this.fg = this.fb.group({ nama: [data.kartu_tanda_penduduk_.nama, [Validators.required, Validators.pattern(/^[a-zA-Z. ]+$/)]], description: [data.profile_.description, Validators.compose([Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)])], - old_password: [null, Validators.compose([Validators.required, Validators.minLength(8), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)])], - new_password: [null, Validators.compose([Validators.minLength(8), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)])], + old_password: [null, Validators.compose([Validators.required, Validators.minLength(6), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)])], + new_password: [null, Validators.compose([Validators.minLength(6), Validators.pattern(CONSTANTS.regexEnglishKeyboardKeys)])], image_photo: [null, Validators.compose([Validators.pattern(CONSTANTS.regexUrl)])], image_cover: [null, Validators.compose([Validators.pattern(CONSTANTS.regexUrl)])], private: [data.private, Validators.compose([Validators.required])] diff --git a/src/app/_shared/services/auth.service.ts b/src/app/_shared/services/auth.service.ts index 31daf6f07..1c83cc9a7 100644 --- a/src/app/_shared/services/auth.service.ts +++ b/src/app/_shared/services/auth.service.ts @@ -78,6 +78,7 @@ export class AuthService { clearInterval(this.intervalLogout); this.intervalLogout = null; this.logoutTimerText = ''; + window.location.reload(); } }, 1000); } diff --git a/src/app/_shared/services/service-worker.service.ts b/src/app/_shared/services/service-worker.service.ts index b470ac89b..cc3f5dea3 100644 --- a/src/app/_shared/services/service-worker.service.ts +++ b/src/app/_shared/services/service-worker.service.ts @@ -56,7 +56,7 @@ export class ServiceWorkerService { this.dialogRef = this.ds.openInfoDialog({ data: { title: `Pembaharuan ${au ? 'Berhasil' : 'Gagal'}`, - htmlMessage: `Ingin Refresh Halaman (?)`, + htmlMessage: `Ingin Refresh Halaman Sekarang (?)`, confirmText: 'Ya', cancelText: 'Tidak' }