diff --git a/FrontEnd/Library/src/app/addbooks/addbooks.component.css b/FrontEnd/Library/src/app/addbooks/addbooks.component.css index 5fbd13fe..42f8c76a 100644 --- a/FrontEnd/Library/src/app/addbooks/addbooks.component.css +++ b/FrontEnd/Library/src/app/addbooks/addbooks.component.css @@ -60,7 +60,7 @@ margin-left: 20%; table{ width: 90%; border: none; - text-align: center; + text-align: left; height: 100px; text-size-adjust: auto; @@ -68,12 +68,13 @@ margin-left: 20%; th { background-color: #ffffff; color: rgb(0, 0, 0); - text-align: center; + text-align: left; border: none; } td { border: none; padding-top: 6px;padding-bottom: 6px; + text-align: left; } /* .form-control{ width: fit-content; diff --git a/FrontEnd/Library/src/app/addbooks/addbooks.component.html b/FrontEnd/Library/src/app/addbooks/addbooks.component.html index e8536c29..767049f8 100644 --- a/FrontEnd/Library/src/app/addbooks/addbooks.component.html +++ b/FrontEnd/Library/src/app/addbooks/addbooks.component.html @@ -35,13 +35,6 @@ .form-control{ width: 30vh; } - - /* .col-md-6{ - display: flex; - flex-wrap: wrap; - flex-direction: row; - } */ - } @@ -67,7 +60,7 @@ - + @@ -198,104 +191,3 @@ - diff --git a/FrontEnd/Library/src/app/addbooks/addbooks.component.ts b/FrontEnd/Library/src/app/addbooks/addbooks.component.ts index 505840b5..112c2cfc 100644 --- a/FrontEnd/Library/src/app/addbooks/addbooks.component.ts +++ b/FrontEnd/Library/src/app/addbooks/addbooks.component.ts @@ -160,11 +160,16 @@ onTableDataChange(event:any) { const dialogConfig = new MatDialogConfig(); this.dialog.open(BooksComponent, { + closeOnNavigation: true, // width:'32%',height:'70%' width:'55%',height:'auto' } ); + this.router.events + .subscribe(() => { + this.dialog.closeAll(); + }); } @@ -194,10 +199,15 @@ onTableDataChange(event:any) { const dialogConfig = new MatDialogConfig(); this.dialog.open(BooksComponent, { + closeOnNavigation: true, width:'30%',height:'70%' } ); + this.router.events + .subscribe(() => { + this.dialog.closeAll(); + }); } @@ -208,6 +218,7 @@ onTableDataChange(event:any) { selectFile($event:any) { this.selectedFiles=$event.target.files; + console.log("sel-",this.selectedFiles) } @@ -223,15 +234,19 @@ selectFile($event:any) { console.log(res); if(res!==null){ this.toast.success({detail:'SUCCESS',summary:'The CSV File upload is successfull',duration:5000}); + setTimeout(() => { window.location.reload() - }, 5000); - + }, 5000); } - }) + }), + (error: any) =>{ + console.log("in error") + this.toast.error({detail:'CSV upload failed',summary:'Invalid csv file',duration:5000}); + console.log(error)}; } diff --git a/FrontEnd/Library/src/app/addcategory/addcategory.component.css b/FrontEnd/Library/src/app/addcategory/addcategory.component.css index 46baf45a..fa8b69b6 100644 --- a/FrontEnd/Library/src/app/addcategory/addcategory.component.css +++ b/FrontEnd/Library/src/app/addcategory/addcategory.component.css @@ -2,7 +2,7 @@ table{ width: auto; border: none; - text-align: center; + text-align: left; } /* tr{ @@ -11,12 +11,18 @@ th { background-color: #ffffff; color: rgb(0, 0, 0); - text-align: center; + text-align: left; + /* text-align: center; */ border: none; } td { border: none; padding-top: 16px;padding-bottom: 6px; - text-align: center; + text-align: left; + /* text-align: center; */ + } + + td text{ + padding-top: 30%; } \ No newline at end of file diff --git a/FrontEnd/Library/src/app/addcategory/addcategory.component.html b/FrontEnd/Library/src/app/addcategory/addcategory.component.html index f79951fe..e9d5b17f 100644 --- a/FrontEnd/Library/src/app/addcategory/addcategory.component.html +++ b/FrontEnd/Library/src/app/addcategory/addcategory.component.html @@ -7,11 +7,11 @@
- +
- - +
      + Category Name @@ -34,7 +34,7 @@ {{category.categoryName}} - + diff --git a/FrontEnd/Library/src/app/addcategory/addcategory.component.ts b/FrontEnd/Library/src/app/addcategory/addcategory.component.ts index 9e79391f..9c6ba825 100644 --- a/FrontEnd/Library/src/app/addcategory/addcategory.component.ts +++ b/FrontEnd/Library/src/app/addcategory/addcategory.component.ts @@ -124,11 +124,15 @@ editCategory(categoryId:any) { this.dialog.open(CategoryComponent, { - // width:'25%',height:'35%' + closeOnNavigation: true, width:'auto',height:'auto' } ); + this.router.events + .subscribe(() => { + this.dialog.closeAll(); + }); } diff --git a/FrontEnd/Library/src/app/books.service.ts b/FrontEnd/Library/src/app/books.service.ts index 66bff396..515d1576 100644 --- a/FrontEnd/Library/src/app/books.service.ts +++ b/FrontEnd/Library/src/app/books.service.ts @@ -23,6 +23,13 @@ handleError(err: HttpErrorResponse): any { localStorage.clear() this.router.navigateByUrl(`/login`); } } +handleCsvError(err: HttpErrorResponse): any { + console.log('hhhii'); + if ( err.status === 417) { + alert("CSV upload failed : Invalid csv file") + + } +} ////////////////////////////////////////////// @@ -37,7 +44,7 @@ handleError(err: HttpErrorResponse): any { const formData: FormData = new FormData(); formData.append('file', file); - return this.http.post('http://localhost:8080/csv/admin/upload', formData) + return this.http.post('http://localhost:8080/csv/admin/upload', formData).pipe((catchError(err => this.handleCsvError(err)))) } //pie diff --git a/FrontEnd/Library/src/app/books/books.component.html b/FrontEnd/Library/src/app/books/books.component.html index 4c509fff..f967989b 100644 --- a/FrontEnd/Library/src/app/books/books.component.html +++ b/FrontEnd/Library/src/app/books/books.component.html @@ -49,30 +49,31 @@
- + This field is mandatory.
- + This field is mandatory.
- + This field is mandatory.
- + This field is mandatory. +
                                   -     - +     +
@@ -103,49 +104,3 @@ - - - diff --git a/FrontEnd/Library/src/app/books/books.component.ts b/FrontEnd/Library/src/app/books/books.component.ts index 306c5d0b..d0801a09 100644 --- a/FrontEnd/Library/src/app/books/books.component.ts +++ b/FrontEnd/Library/src/app/books/books.component.ts @@ -30,6 +30,7 @@ export class BooksComponent implements OnInit { booksdata:any; catdata: any; ObjSampleForm:FormGroup; + displayStyle: any; constructor(private router:Router , private booksService:BooksService, @@ -45,7 +46,7 @@ export class BooksComponent implements OnInit { publication:new FormControl('',[Validators.required]), booksName:new FormControl('',[Validators.required]), auther:new FormControl('',[Validators.required]), - booksCopies:new FormControl('',[Validators.required]) , + booksCopies:new FormControl('',[Validators.required]) // categoryId:new FormControl('',[Validators.required]) , } ); @@ -77,7 +78,8 @@ LoadCategory() { clear() { localStorage.removeItem('categoryId'); - window.location.reload() + + } onSubmit(){ @@ -99,18 +101,19 @@ onSubmit(){ console.log("bid=",result.booksId) // MatDialog.close(); this.router.navigate(['/imageupload']) - + this.displayStyle = "none"; } else{ this.toast.error({detail:'Invalid',summary:'Add new Book Failed',duration:5000}); } }) - - } } +closePopup() { + this.displayStyle = "none"; +} loadEdit(): void{ diff --git a/FrontEnd/Library/src/app/borrow/borrow.component.css b/FrontEnd/Library/src/app/borrow/borrow.component.css index 8ff5235b..6b980aff 100644 --- a/FrontEnd/Library/src/app/borrow/borrow.component.css +++ b/FrontEnd/Library/src/app/borrow/borrow.component.css @@ -27,12 +27,23 @@ position: relative; top: 4%; left: 70%; + top:3%; transform: translate(-50%, -50%); text-align: center; display: flex; flex-wrap: nowrap; flex-direction: row; + } + + .centr { + position: relative; + top: 5%; + left: 40%; + transform: translate(-50%, -50%); + text-align: center; + + } .table-responsive{ overflow-x: hidden; @@ -46,18 +57,23 @@ table{ width: 90%; border: none; - text-align: center; + text-align: left; } th { - background-color: #ffffff; + background-color: #fffdfd; color: rgb(0, 0, 0); - text-align: center; + text-align: left; + /* border: 3px; */ } td { - + text-align: left; padding-top: 6px;padding-bottom: 6px; - } \ No newline at end of file + } + +.h2{ + margin-left: 10%; +} diff --git a/FrontEnd/Library/src/app/borrow/borrow.component.html b/FrontEnd/Library/src/app/borrow/borrow.component.html index 4e215b49..662750fd 100644 --- a/FrontEnd/Library/src/app/borrow/borrow.component.html +++ b/FrontEnd/Library/src/app/borrow/borrow.component.html @@ -29,16 +29,18 @@ -
+ +

Borrow Details

+ +

-

Borrow Details

- +
@@ -46,7 +48,7 @@

Borrow Details

         -         +                  

@@ -124,7 +126,7 @@

Borrow Details

@@ -176,12 +178,16 @@

Borrow Details

+ + + - + + - +
diff --git a/FrontEnd/Library/src/app/borrow/borrow.component.ts b/FrontEnd/Library/src/app/borrow/borrow.component.ts index 12530ac9..16854109 100644 --- a/FrontEnd/Library/src/app/borrow/borrow.component.ts +++ b/FrontEnd/Library/src/app/borrow/borrow.component.ts @@ -20,11 +20,12 @@ export class BorrowComponent implements OnInit { curDate= new Date() myDate:any; filename: any; + data1:number=0; borrowId:any; borrowdata:any; booksdata:any; - + d1:number=0; date:any; data: any; @@ -145,14 +146,33 @@ export class BorrowComponent implements OnInit { getFilter() { + if(this.d1==2){ console.log("d=",this.ObjSampleForm.controls['date1'].value) this.flag=1; this.service.filterBorrowPagination(this.ObjSampleForm.controls['date1'].value,this.ObjSampleForm.controls['date2'].value,this.page,this.tableSize,this.sort,this.direction1).subscribe(response=>{ this.result=response.content; this.count=response.totalElements console.log(this.result); - this.data=this.result; - }); + this.data=this.result; + + console.log("len>",this.result.length); + if(this.result.length!==0){ + this.data1=0; + + } + else if(this.result.length==0){ + this.data1=1; + console.log("else>",this.data1); + } + + + + }); + } + else + this.toast.warning({detail:'Warning',summary:'Choose start and end dates ',duration:5000}); + // this.d1=0; + console.log("d11==",this.d1) } @@ -252,6 +272,36 @@ console.log("d=",this.ObjSampleForm.controls['date1'].value) datas(){ this.val=this.ObjSampleForm.controls['date1'].value; console.log("date=",this.val) + + if(this.d1==0){ + this.d1=1; + console.log("d1=",this.d1) + } + else if(this.d1==1){ + this.d1=2; + } + + if(this.ObjSampleForm.controls['date1'].value!=null){ + this.d1=1; + } + + } + + datas1(){ + + if(this.d1==1){ + this.d1=2; + console.log("d1=",this.d1) + } + else if(this.d1==0){ + this.d1=1; + } + + // if(this.ObjSampleForm.controls['date2'].value!=null){ + // this.d1=1; + // } + + } diff --git a/FrontEnd/Library/src/app/category/category.component.html b/FrontEnd/Library/src/app/category/category.component.html index 03eeb768..e6e44408 100644 --- a/FrontEnd/Library/src/app/category/category.component.html +++ b/FrontEnd/Library/src/app/category/category.component.html @@ -9,7 +9,7 @@ - + This field is mandatory. diff --git a/FrontEnd/Library/src/app/category/category.component.ts b/FrontEnd/Library/src/app/category/category.component.ts index 14b2c4bb..354c79c7 100644 --- a/FrontEnd/Library/src/app/category/category.component.ts +++ b/FrontEnd/Library/src/app/category/category.component.ts @@ -87,7 +87,7 @@ onSubmit(){ if(result.categoryId){ console.log(result); this.toast.success({detail:'Success',summary:'The Category '+result.categoryName+' Added',duration:5000}); - + this.router.navigate(['/addCategory']) setTimeout(() => { window.location.reload() }, 1500); diff --git a/FrontEnd/Library/src/app/findby-category/findby-category.component.css b/FrontEnd/Library/src/app/findby-category/findby-category.component.css index a1d7c238..6103feba 100644 --- a/FrontEnd/Library/src/app/findby-category/findby-category.component.css +++ b/FrontEnd/Library/src/app/findby-category/findby-category.component.css @@ -58,6 +58,7 @@ th { color: white; width: 15%; text-align: center; + border: none; } td { background-color: #a7bdb08f; @@ -66,6 +67,7 @@ th { text-align: center; margin-top: auto; padding: auto; + border: none; } diff --git a/FrontEnd/Library/src/app/fine/fine.component.css b/FrontEnd/Library/src/app/fine/fine.component.css index d2cd3da3..b68c2589 100644 --- a/FrontEnd/Library/src/app/fine/fine.component.css +++ b/FrontEnd/Library/src/app/fine/fine.component.css @@ -48,7 +48,7 @@ table{ background-color: #ffffff; color: rgb(0, 0, 0); text-align: center; - /* border: none; */ + border: none; position:relative; } diff --git a/FrontEnd/Library/src/app/fine/fine.component.html b/FrontEnd/Library/src/app/fine/fine.component.html index f06a33c9..77f65c81 100644 --- a/FrontEnd/Library/src/app/fine/fine.component.html +++ b/FrontEnd/Library/src/app/fine/fine.component.html @@ -100,11 +100,14 @@

OUTSTANDING FINE DETAILS

{{borrow.issueDate| date:'dd/MM/yyyy'}} {{borrow.dueDate| date:'dd/MM/yyyy'}} {{borrow.dueDays}} - {{borrow.fine}} - - - + {{borrow.fine}} + + + NO RECORDS FOUND + + + diff --git a/FrontEnd/Library/src/app/fine/fine.component.ts b/FrontEnd/Library/src/app/fine/fine.component.ts index 8b0e478d..bb50d13b 100644 --- a/FrontEnd/Library/src/app/fine/fine.component.ts +++ b/FrontEnd/Library/src/app/fine/fine.component.ts @@ -1,5 +1,6 @@ import { Component, OnInit } from '@angular/core'; import { Router } from '@angular/router'; +import { elementAt } from 'rxjs'; import { BooksService } from '../books.service'; import { BorrowService } from '../borrow.service'; @@ -15,7 +16,7 @@ export class FineComponent implements OnInit { borrowId:any; borrowdata:any; booksdata:any; - + data:number=1; constructor(private router:Router ,private service:BorrowService,private booksService:BooksService) { this.borrowList=[]; @@ -32,71 +33,82 @@ export class FineComponent implements OnInit { LoadBorrow(){ this.service.LoadFine().subscribe((data: any)=>{ this.borrowdata=data; - console.log(data);}); + console.log(data); + console.log("9999",data.length) + + + + if(data.length!==0){ + this.data=0; + + } + else if(data.length==0){ + this.data=1; + } + + }); + + } - - home() - { - this.router.navigate(['/sidenav']) - } + - acceptRequest(borrow:any) - { - console.log("in borrow"); - console.log(borrow); - console.log(borrow.borrowId); + // acceptRequest(borrow:any) + // { + // console.log("in borrow"); + // console.log(borrow); + // console.log(borrow.borrowId); - sessionStorage.setItem('borrowId',borrow.borrowId) - this.router.navigate(['/acceptrequest']) - } + // sessionStorage.setItem('borrowId',borrow.borrowId) + // this.router.navigate(['/acceptrequest']) + // } - rejectRequest(borrow:any){ + // rejectRequest(borrow:any){ - console.log("in borrow"); - console.log(borrow); - console.log(borrow.borrowId); + // console.log("in borrow"); + // console.log(borrow); + // console.log(borrow.borrowId); - sessionStorage.setItem('borrowId',borrow.borrowId) - this.router.navigate(['/rejectrequest']) + // sessionStorage.setItem('borrowId',borrow.borrowId) + // this.router.navigate(['/rejectrequest']) - } + // } - bookReturn(borrow: any) { + // bookReturn(borrow: any) { - this.service.bookReturn(borrow.borrowId).subscribe({ - next: (Response: any) => { - console.log(Response); - alert(" Book Returned") - window.location.reload() - }, - error: (Response: any) => { - console.log(Response) - alert("invalid Borrow details") - } - }) - this.router.navigate(['/borrow']) - } - - - undo(borrow: any) { + // this.service.bookReturn(borrow.borrowId).subscribe({ + // next: (Response: any) => { + // console.log(Response); + // alert(" Book Returned") + // window.location.reload() + // }, + // error: (Response: any) => { + // console.log(Response) + // alert("invalid Borrow details") + // } + // }) + // this.router.navigate(['/borrow']) + // } + + + // undo(borrow: any) { - this.service.undo(borrow.borrowId).subscribe({ - next: (Response: any) => { - console.log(Response); - alert(" Book Returned status revoked") - window.location.reload() - }, - error: (Response: any) => { - console.log(Response) - alert("invalid Borrow details") - } - }) - this.router.navigate(['/borrow']) - } + // this.service.undo(borrow.borrowId).subscribe({ + // next: (Response: any) => { + // console.log(Response); + // alert(" Book Returned status revoked") + // window.location.reload() + // }, + // error: (Response: any) => { + // console.log(Response) + // alert("invalid Borrow details") + // } + // }) + // this.router.navigate(['/borrow']) + // } } \ No newline at end of file diff --git a/FrontEnd/Library/src/app/forgotpassword/forgotpassword.component.ts b/FrontEnd/Library/src/app/forgotpassword/forgotpassword.component.ts index fc6bd76d..24b45b14 100644 --- a/FrontEnd/Library/src/app/forgotpassword/forgotpassword.component.ts +++ b/FrontEnd/Library/src/app/forgotpassword/forgotpassword.component.ts @@ -67,7 +67,7 @@ export class ForgotpasswordComponent implements OnInit { this.emails.verify(this.ObjForgetForm.value).subscribe(result=>{ if(result){ - this.toast.success({detail:'psd changed',summary:'Please Login', duration:10000,position:'tr'}) + this.toast.success({detail:'password changed',summary:'Please Login', duration:10000,position:'tr'}) this.router.navigate(['/login']) } else{ @@ -113,7 +113,7 @@ export class ForgotpasswordComponent implements OnInit { } openSuccess(){ - this.toast.success({detail:'OTP Sent Success',summary:'Otp Has been Sent to your mail', duration:5000,position:'tr'}) + this.toast.success({detail:'OTP Sent Success',summary:'OTP Has been Sent to your mail', duration:5000,position:'tr'}) } } diff --git a/FrontEnd/Library/src/app/imageupload/imageupload.component.ts b/FrontEnd/Library/src/app/imageupload/imageupload.component.ts index 61f2d7f1..becece12 100644 --- a/FrontEnd/Library/src/app/imageupload/imageupload.component.ts +++ b/FrontEnd/Library/src/app/imageupload/imageupload.component.ts @@ -49,7 +49,7 @@ export class ImageuploadComponent implements OnInit { if(response) { - alert("IMAGE UPLOADED SUCCESSFULLY") + } }, error => { alert("Invalid Data\t " +error.HttpErrorResponse+" Status" +error.status) diff --git a/FrontEnd/Library/src/app/login/login.component.css b/FrontEnd/Library/src/app/login/login.component.css index 3a8834ff..e9438aef 100644 --- a/FrontEnd/Library/src/app/login/login.component.css +++ b/FrontEnd/Library/src/app/login/login.component.css @@ -68,8 +68,8 @@ body{ } .login input[type=text]{ - width: 250px; - height: 30px; + width: 350px; + height: 50px; background: transparent; border: 1px solid rgba(255,255,255,0.6); border-radius: 10px; @@ -83,8 +83,8 @@ body{ .login input[type=password]{ - width: 250px; - height: 30px; + width: 350px; + height: 50px; background: transparent; border: 1px solid rgba(255,255,255,0.6); border-radius: 10px; @@ -95,9 +95,11 @@ body{ padding: 4px; margin-top: 10px; } - +a{ + margin-left: 35%; +} .login input[type=button]{ - width: 260px; + width: 350px; height: 35px; background: #fff; border: 1px solid #fff; @@ -109,6 +111,8 @@ body{ font-weight: 400; padding: 6px; margin-top: 10px; + /* margin-left: 20%; */ + text-align: center; } .login input[type=button]:hover{ diff --git a/FrontEnd/Library/src/app/login/login.component.html b/FrontEnd/Library/src/app/login/login.component.html index a0004e7b..32b28486 100644 --- a/FrontEnd/Library/src/app/login/login.component.html +++ b/FrontEnd/Library/src/app/login/login.component.html @@ -18,10 +18,11 @@
- password is required
use (uppercase ,lowercase and numbers)
minimum 8 character
-
- - + password is required
use (uppercase ,lowercase and numbers)
minimum 8 character
+ use alphanumeric & special characters   + + +

Forgot_Password - + \ No newline at end of file diff --git a/FrontEnd/Library/src/app/login/login.component.ts b/FrontEnd/Library/src/app/login/login.component.ts index e5f7e39f..2f84b2c3 100644 --- a/FrontEnd/Library/src/app/login/login.component.ts +++ b/FrontEnd/Library/src/app/login/login.component.ts @@ -32,7 +32,7 @@ export class LoginComponent implements OnInit { login(){ - // if(this.ObjSampleForm.valid){ + if(this.loginForm.valid){ this.service.login(this.loginForm.value).subscribe(result=>{ if(result.userId){ this.responsedata=result @@ -48,7 +48,7 @@ export class LoginComponent implements OnInit { else{ localStorage.setItem('token',this.responsedata.accessToken.value) this.toast.info({detail:'Hello Admin : '+result.firstName,summary:'LogIn Successfull',duration:5000}); - this.router.navigate(['/sidenav']) + this.router.navigate(['/body']) } @@ -63,13 +63,13 @@ export class LoginComponent implements OnInit { console.log(error)}); - // } + } - // } - // else{ - // return; - // } + + else{ + this.toast.error({detail:'Login Failed',summary:'Fill up the fields',duration:5000}); + } } @@ -79,4 +79,4 @@ export class LoginComponent implements OnInit { } -} +} \ No newline at end of file diff --git a/FrontEnd/Library/src/app/user-details/user-details.component.css b/FrontEnd/Library/src/app/user-details/user-details.component.css index 5cca3143..6e4b3029 100644 --- a/FrontEnd/Library/src/app/user-details/user-details.component.css +++ b/FrontEnd/Library/src/app/user-details/user-details.component.css @@ -17,7 +17,7 @@ .right { right: 0; - width: 89%; + width: 80%; background-color: rgb(255, 255, 255); position: relative; left: 16%; @@ -31,26 +31,35 @@ transform: translate(-50%, -50%); text-align: center; } - +.centr { + position: relative; + top: 5%; + left: 45%; + transform: translate(-50%, -50%); + text-align: center; +} table{ - width:70%; + width:65%; border: none; - text-align: center; + text-align: left; border: none; } th { background-color: #ffffff; color: rgb(0, 0, 0); - text-align: center; + text-align: left; /* border: none; */ + border: none; } td { border: none; - padding-top: 16px;padding-bottom: 16px; + text-align: left; + padding-top: 12px;padding-bottom: 12px; + border: none; } .no-touch .scrollable.hover { overflow-y:hidden; diff --git a/FrontEnd/Library/src/app/user-details/user-details.component.html b/FrontEnd/Library/src/app/user-details/user-details.component.html index 0b077bf8..47f7d015 100644 --- a/FrontEnd/Library/src/app/user-details/user-details.component.html +++ b/FrontEnd/Library/src/app/user-details/user-details.component.html @@ -76,11 +76,11 @@

-

USER DETAILS

+

USER DETAILS

- + diff --git a/FrontEnd/Library/src/app/user-reg/user-reg.component.html b/FrontEnd/Library/src/app/user-reg/user-reg.component.html index 41b2b08a..0b8d5549 100644 --- a/FrontEnd/Library/src/app/user-reg/user-reg.component.html +++ b/FrontEnd/Library/src/app/user-reg/user-reg.component.html @@ -36,7 +36,8 @@
- Date-of-birth is required + Date-of-birth is required +

@@ -46,14 +47,13 @@ Phone n.o is required

- +
- pswd is required
use (uppercase,lowercase & numbers)
minimum 8 character
-
-

+ pswd is required + use alphanumeric & special characters   + minimum 8 character +

@@ -64,11 +64,10 @@


- +     - - - + + diff --git a/FrontEnd/Library/src/app/user-reg/user-reg.component.ts b/FrontEnd/Library/src/app/user-reg/user-reg.component.ts index 4b02094c..e0128b8f 100644 --- a/FrontEnd/Library/src/app/user-reg/user-reg.component.ts +++ b/FrontEnd/Library/src/app/user-reg/user-reg.component.ts @@ -1,6 +1,7 @@ import { Component, OnInit } from '@angular/core'; import { FormGroup, FormControl, Validators } from '@angular/forms'; import { Router,Route } from '@angular/router'; +import { NgToastService } from 'ng-angular-popup'; import { UserserviceService } from '../userservice.service'; @Component({ @@ -12,7 +13,7 @@ export class UserRegComponent implements OnInit { [x: string]: any; date: any; var:any; - constructor(private router:Router ,private service:UserserviceService) { } + constructor(private router:Router ,private service:UserserviceService,private toast : NgToastService) { } @@ -37,9 +38,9 @@ var:any; onSubmit(){ - console.log("aaaa"); - // if(this.ObjSampleForm.valid){ + + if(this.ObjSampleForm.valid){ this.var=this.ObjSampleForm.value this.service.add(this.ObjSampleForm.value).subscribe(result=>{ if(result.userId){ @@ -51,8 +52,18 @@ var:any; else{ alert("User Not added"); } - }) - // } + }, + (error: any) =>{ + this.toast.error({detail:'User Registration Failed',summary:'Email Already Registered',duration:5000}); + console.log(error)}); + + + } + else{ + this.toast.error({detail:'User Registration Failed',summary:'Fill up the fields',duration:2000}); + } + + } @@ -63,11 +74,50 @@ var:any; this.router.navigate(['/login']) } - clear(){ - window.location.reload() - } + // clear(){ + // // window.location.reload() + // this.ObjSampleForm.reset() + // } } + + + + + +//
+//
+//
+//
Library
+//
+//
+ +// +// library_books + +//
+//
+ +// Email is required +// + + +// +// pswd is required +// use alphanumeric & special characters   +// minimum 8 character +//

+ +// + +// +// +// Forgot_Password +// diff --git a/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.css b/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.css index 40064745..376bc9ea 100644 --- a/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.css +++ b/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.css @@ -27,5 +27,6 @@ border: none; color: rgb(0, 0, 0); width: auto; padding: 8px; + text-align: left; } diff --git a/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.html b/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.html index 205ff04e..61f26308 100644 --- a/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.html +++ b/FrontEnd/Library/src/app/view-adminprofile/view-adminprofile.component.html @@ -24,10 +24,15 @@ .main { float: left; - width: 100%; + /* right: 80%; */ + width: 50%; padding: 0 20px; + margin-left: 30%; text-align: center; } + .tb{ + margin-left: 30%; + } .right { background-color: #e5e5e5; @@ -37,11 +42,15 @@ margin-top: 7px; text-align: center; } - + @media only screen and (max-width: 620px) { /* For mobile phones: */ - .menu, .main, .right { + .main { width: 100%; + margin-left: 5%; + } + .tb{ + margin-left: 15%; } } @@ -53,8 +62,8 @@



PROFILE

-
User Results
- +
+ @@ -91,21 +100,3 @@

PROFILE

- -
Profile
NAME :{{userdata[0].firstName}} {{userdata.lastName}}
ADDRESS :{{userdata[0].address}}
PHONE :{{userdata[0].phone}}
- - - - - - - - - -
NAME :{{userdata[0].firstName}} {{userdata.lastName}}
ADDRESS :{{userdata[0].address}}
PHONE :{{userdata[0].phone}}
EMAIL :{{userdata[0].email}}
DOB :{{userdata[0].dob| date:'dd/MM/yyyy'}}
CREATED DATE :{{userdata[0].createDate| date:'dd/MM/yyyy'}}
UPDATE DATE :{{userdata[0].updateDate| date:'dd/MM/yyyy'}}
--> - \ No newline at end of file diff --git a/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 16-18-59.png b/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 16-18-59.png new file mode 100644 index 00000000..e004760a Binary files /dev/null and b/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 16-18-59.png differ diff --git a/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 17-41-13.png b/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 17-41-13.png new file mode 100644 index 00000000..e5d0d530 Binary files /dev/null and b/FrontEnd/Library/src/assets/BooksImage/item_pics/Screenshot from 2023-01-19 17-41-13.png differ