aboutsummaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
Diffstat (limited to 'frontend')
-rw-r--r--frontend/src/app/_data/User.ts4
-rw-r--r--frontend/src/app/_elements/form-dataset/form-dataset.component.css22
-rw-r--r--frontend/src/app/_elements/form-dataset/form-dataset.component.html24
-rw-r--r--frontend/src/app/_modals/register-modal/register-modal.component.ts4
-rw-r--r--frontend/src/app/_pages/profile/profile.component.ts9
5 files changed, 34 insertions, 29 deletions
diff --git a/frontend/src/app/_data/User.ts b/frontend/src/app/_data/User.ts
index be42ed0a..527bac77 100644
--- a/frontend/src/app/_data/User.ts
+++ b/frontend/src/app/_data/User.ts
@@ -6,6 +6,8 @@ export default class User {
public password: string = '',
public firstName: string = '',
public lastName: string = '',
- public photoId: string = '1' //difoltna profilna slika
+ public photoId: string = '1', //difoltna profilna slika
+ public isPermament:boolean=false,
+ public dateCreated:Date=new Date()
) { }
} \ No newline at end of file
diff --git a/frontend/src/app/_elements/form-dataset/form-dataset.component.css b/frontend/src/app/_elements/form-dataset/form-dataset.component.css
index 953daa0c..079711d0 100644
--- a/frontend/src/app/_elements/form-dataset/form-dataset.component.css
+++ b/frontend/src/app/_elements/form-dataset/form-dataset.component.css
@@ -5,25 +5,27 @@
}
.topBar {
+ display: table;
width: 100%;
- margin: 1rem;
- align-items: flex-start;
+ height: 100px;
+ margin-left: 1.5%;
+ margin-top: 1.5% ;
+}
+.kolona{
+ float: left;
+ margin-left: 20px;
}
-
.topBar label{
font-size: 30px;
}
.topBar mat-form-field{
width: 250px;
+ margin: 0;
}
-.toptop{
- margin-left: 1.5%;
- width: 50%;
-}
-
-.fileButton{
- margin-top: 10px;
+.fileButton button{
+ height: 51px;
+ width: 250px;
}
.file-container {
diff --git a/frontend/src/app/_elements/form-dataset/form-dataset.component.html b/frontend/src/app/_elements/form-dataset/form-dataset.component.html
index 281f9c05..055c3fd3 100644
--- a/frontend/src/app/_elements/form-dataset/form-dataset.component.html
+++ b/frontend/src/app/_elements/form-dataset/form-dataset.component.html
@@ -1,18 +1,16 @@
<div class="folderBox" *ngIf="dataset">
- <div class="row" style="margin-right: 0;">
+
<div class="topBar">
- <div class="row toptop">
- <div class="col-sm mb-3">
+ <div class="kolona mb-3">
<div class="fileButton">
<button type="button" mat-raised-button (click)="fileInput.click()">Dodaj izvor podataka</button>
</div>
</div>
- <div class="col-sm">
+ <div class="kolona">
<div role="group">
- <div class="row">
<mat-form-field class="example-full-width" appearance="fill">
<mat-label>Naziv</mat-label>
<input type="text" matInput value="{{dataset?.name}}" [(ngModel)]="dataset.name">
@@ -22,10 +20,9 @@
Naziv je <strong>obavezan</strong>
</mat-error>
</mat-form-field>
- </div>
</div>
</div>
- <div class="col-sm">
+ <div class="kolona">
<mat-form-field appearance="fill">
<mat-label>Delimiter</mat-label>
<mat-select id="delimiterOptions" [(ngModel)]="dataset.delimiter" (change)="update()" value=",">
@@ -35,17 +32,12 @@
</mat-select>
</mat-form-field>
</div>
- <div class="col-sm">
-
- </div>
- </div>
- <div class="row" *ngIf="firstInput">
- <label class=" mt-5">{{filename}}</label>
-
- </div>
</div>
- </div>
+
+ <div class="row" *ngIf="firstInput">
+ <label class=" mt-5">{{filename}}</label>
+ </div>
<div class="row" style="margin-right: 0;">
<div class="file-container" [ngClass]="{'dottedClass': !tableData.hasInput}">
diff --git a/frontend/src/app/_modals/register-modal/register-modal.component.ts b/frontend/src/app/_modals/register-modal/register-modal.component.ts
index 9da5484d..575fc717 100644
--- a/frontend/src/app/_modals/register-modal/register-modal.component.ts
+++ b/frontend/src/app/_modals/register-modal/register-modal.component.ts
@@ -150,7 +150,9 @@ export class RegisterModalComponent implements OnInit {
username: this.username,
password: this.pass1,
email: this.email,
- photoId: "1"
+ photoId: "1",
+ isPermament:true,
+ dateCreated:new Date()
}
this.authService.register(user)
diff --git a/frontend/src/app/_pages/profile/profile.component.ts b/frontend/src/app/_pages/profile/profile.component.ts
index ae9fb12c..fdcd347c 100644
--- a/frontend/src/app/_pages/profile/profile.component.ts
+++ b/frontend/src/app/_pages/profile/profile.component.ts
@@ -28,6 +28,8 @@ export class ProfileComponent implements OnInit {
newPass2: string = '';
photoId: string = '';
photoPath: string = '';
+ isPermament:boolean=false;
+ dateCreated:Date=new Date();
wrongPassBool: boolean = false;
wrongNewPassBool: boolean = false;
@@ -60,6 +62,9 @@ export class ProfileComponent implements OnInit {
this.firstName = this.user.firstName;
this.lastName = this.user.lastName;
this.photoId = this.user.photoId;
+ this.dateCreated=this.user.dateCreated;
+ this.isPermament=this.user.isPermament;
+
for (let i = 0; i < this.pictures.length; i++) {
if (this.pictures[i].photoId.toString() === this.photoId) {
@@ -81,7 +86,9 @@ export class ProfileComponent implements OnInit {
password: this.user.password,
firstName: this.firstName,
lastName: this.lastName,
- photoId: this.photoId
+ photoId: this.photoId,
+ isPermament:this.isPermament,
+ dateCreated:this.dateCreated
}
this.userInfoService.changeUserInfo(editedUser).subscribe((response: any) =>{