unictive-angular 1.0.37 → 1.0.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/utils/createStructure.js +4 -0
- package/bin/utils/resource/.postcssrc.json +1 -2
- package/bin/utils/resource/src/app/API/auth/auth.service.ts +160 -0
- package/bin/utils/resource/src/app/PAGES/authentication/login/login.component.spec.ts +28 -0
- package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/login/login.component.ts +9 -3
- package/bin/utils/resource/src/app/PAGES/authentication/page404/page404.component.spec.ts +28 -0
- package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/page404/page404.component.ts +1 -2
- package/bin/utils/resource/src/app/PAGES/home/home.component.html +5 -0
- package/bin/utils/resource/src/app/PAGES/home/home.component.spec.ts +28 -0
- package/bin/utils/resource/src/app/{MODULES → PAGES}/home/home.component.ts +3 -3
- package/bin/utils/resource/src/app/app.config.ts +30 -0
- package/bin/utils/resource/src/app/app.routes.ts +4 -7
- package/bin/utils/resource/src/app/app.ts +6 -5
- package/bin/utils/resource/src/app/core/config/entity-store.ts +44 -15
- package/bin/utils/resource/src/app/core/config/single-store.ts +2 -0
- package/bin/utils/resource/src/app/core/guards/auth.guard.ts +43 -0
- package/bin/utils/resource/src/app/core/guards/login.guard.ts +37 -0
- package/bin/utils/resource/src/app/core/models/entities/user.entity.ts +36 -7
- package/bin/utils/resource/src/app/core/services/helper.service.ts +41 -28
- package/bin/utils/resource/src/app/core/services/listener.service.ts +25 -0
- package/bin/utils/resource/src/app/shared/ui/button/button.component.ts +96 -0
- package/bin/utils/resource/tsconfig.json +2 -2
- package/bin/utils/updatePackageJson.js +78 -54
- package/index.js +3 -2
- package/package.json +1 -1
- package/bin/utils/resource/src/app/MODULES/auth/README.md +0 -10
- package/bin/utils/resource/src/app/MODULES/authentication/login/login.module.ts +0 -19
- package/bin/utils/resource/src/app/MODULES/authentication/page404/page404.module.ts +0 -17
- package/bin/utils/resource/src/app/MODULES/authentication/register/register.component.html +0 -3
- package/bin/utils/resource/src/app/MODULES/authentication/register/register.component.ts +0 -16
- package/bin/utils/resource/src/app/MODULES/authentication/register/register.module.ts +0 -18
- package/bin/utils/resource/src/app/MODULES/dashboard/README.md +0 -10
- package/bin/utils/resource/src/app/MODULES/home/README.md +0 -10
- package/bin/utils/resource/src/app/MODULES/home/home.component.html +0 -4
- package/bin/utils/resource/src/app/MODULES/home/home.module.ts +0 -19
- package/bin/utils/resource/src/app/core/models/entities/screen.entity.spec.ts +0 -41
- package/bin/utils/resource/src/app/core/models/entities/screen.entity.ts +0 -16
- package/bin/utils/resource/src/app/core/respositories/screen_repo/screen.repo.ts +0 -19
- package/bin/utils/resource/src/app/core/respository/screen_repo/screen.repo.ts +0 -27
- package/bin/utils/resource/src/app/core/respository/user/user_repo.ts +0 -26
- package/bin/utils/resource/src/styles.scss +0 -2
- /package/bin/utils/resource/src/app/{MODULES/authentication/login/login.component.scss → PAGES/authentication/login/login.component.css} +0 -0
- /package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/login/login.component.html +0 -0
- /package/bin/utils/resource/src/app/{MODULES/authentication/page404/page404.component.scss → PAGES/authentication/page404/page404.component.css} +0 -0
- /package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/page404/page404.component.html +0 -0
- /package/bin/utils/resource/src/app/{MODULES/authentication/register/register.component.scss → PAGES/home/home.component.css} +0 -0
- /package/bin/utils/resource/src/{app/MODULES/home/home.component.scss → styles.css} +0 -0
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { Injectable } from '@angular/core';
|
|
2
|
-
import { HttpClient } from '@angular/common/http';
|
|
3
|
-
import { ScreenEntity } from '@core/models/entities/screen.entity';
|
|
4
|
-
import { logger } from '@shared/utils/logger';
|
|
5
|
-
|
|
6
|
-
@Injectable({ providedIn: 'root' })
|
|
7
|
-
export class RepoScreen {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
constructor() { }
|
|
11
|
-
|
|
12
|
-
setData(screen: any) {
|
|
13
|
-
ScreenEntity.set(screen);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
get getData() {
|
|
17
|
-
return ScreenEntity.state();
|
|
18
|
-
}
|
|
19
|
-
}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { Injectable } from '@angular/core';
|
|
2
|
-
import { HttpClient } from '@angular/common/http';
|
|
3
|
-
import { ScreenEntity } from '@core/models/entities/screen.entity';
|
|
4
|
-
import { logger } from '@shared/utils/logger';
|
|
5
|
-
import { Entity_User } from '@core/models/entities/user.entity';
|
|
6
|
-
import { UserService } from '@api/user.service';
|
|
7
|
-
|
|
8
|
-
@Injectable({ providedIn: 'root' })
|
|
9
|
-
export class RepoScreen {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
constructor(
|
|
13
|
-
private api: UserService
|
|
14
|
-
) { }
|
|
15
|
-
|
|
16
|
-
load_user() {
|
|
17
|
-
Entity_User.load(async () => {
|
|
18
|
-
const res = await this.api.get_user();
|
|
19
|
-
const response = res?.data ?? [];
|
|
20
|
-
return response; // hanya return user
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
get getData() {
|
|
25
|
-
return ScreenEntity.state();
|
|
26
|
-
}
|
|
27
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { Injectable } from "@angular/core";
|
|
2
|
-
import { UserService } from "@api/user.service";
|
|
3
|
-
import { Entity_User } from "@core/models/entities/user.entity";
|
|
4
|
-
|
|
5
|
-
@Injectable({ providedIn: 'root' })
|
|
6
|
-
export class Repo_User {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
constructor(
|
|
10
|
-
private api: UserService
|
|
11
|
-
) { }
|
|
12
|
-
|
|
13
|
-
load_user() {
|
|
14
|
-
Entity_User.load(async () => {
|
|
15
|
-
const res = await this.api.get_user();
|
|
16
|
-
const response = res?.data ?? null;
|
|
17
|
-
return response; // hanya return user
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
get getData() {
|
|
23
|
-
return Entity_User.state();
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
}
|
|
File without changes
|
/package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/login/login.component.html
RENAMED
|
File without changes
|
|
File without changes
|
/package/bin/utils/resource/src/app/{MODULES → PAGES}/authentication/page404/page404.component.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|