From ad201609bd8dc2d9a939bf24f4eb3c1b0107e912 Mon Sep 17 00:00:00 2001 From: Smart Date: Sat, 18 Mar 2023 10:05:47 +0530 Subject: [PATCH] consultant --- .../appoinment/appoinment-routing.module.ts | 11 +- .../add-business-list.component.html | 64 ----- .../add-business-list.component.scss | 7 - .../add-business-list.component.spec.ts | 25 -- .../add-business-list.component.ts | 66 ----- .../add-business/add-business.component.html | 66 +++++ .../add-business.component.scss} | 0 .../add-business.component.spec.ts} | 12 +- .../add-business.component.ts} | 13 +- .../business-list/business-list.component.ts | 5 +- .../appoinment/business/business.module.ts | 6 +- .../dialog-box/dialog-box.component.html | 66 ----- .../consultant-setting.component.html | 31 +- .../consultant-setting.component.scss | 22 +- .../consultant-setting.component.ts | 21 +- .../edit-working-hours.component.html | 272 +++++++++++++++++- .../edit-working-hours.component.scss | 96 +++++++ .../edit-working-hours.component.ts | 28 +- .../add-customers.component.html} | 0 .../add-customers.component.scss} | 0 .../add-customers.component.spec.ts} | 12 +- .../add-customers.component.ts} | 13 +- .../customers-list.component.ts | 5 +- .../appoinment/customers/customers.module.ts | 4 +- .../add-service.component.html} | 0 .../add-service.component.scss} | 0 .../add-service.component.spec.ts} | 12 +- .../add-service.component.ts} | 13 +- .../service-list.module.ts | 4 +- .../service-list/service-list.component.ts | 4 +- .../add-user-list.component.html | 1 - .../add-user-list.component.scss | 0 .../add-user-list/add-user-list.component.ts | 66 ----- .../user/add-user/add-user.component.html | 67 +++++ .../add-user.component.scss} | 0 .../add-user/add-user.component.spec.ts} | 12 +- .../add-user.component.ts} | 14 +- .../user-dialog-box.component.html | 67 ----- .../user-dialog-box.component.spec.ts | 25 -- .../user/user-list/user-list.component.ts | 4 +- .../src/app/appoinment/user/user.module.ts | 6 +- 41 files changed, 667 insertions(+), 473 deletions(-) delete mode 100644 ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.html delete mode 100644 ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.scss delete mode 100644 ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.spec.ts delete mode 100644 ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.ts create mode 100644 ng-seed/src/app/appoinment/business/add-business/add-business.component.html rename ng-seed/src/app/appoinment/business/{dialog-box/dialog-box.component.scss => add-business/add-business.component.scss} (100%) rename ng-seed/src/app/appoinment/{service-list-details/dialog-box/dialog-box.component.spec.ts => business/add-business/add-business.component.spec.ts} (53%) rename ng-seed/src/app/appoinment/business/{dialog-box/dialog-box.component.ts => add-business/add-business.component.ts} (91%) delete mode 100644 ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.html rename ng-seed/src/app/appoinment/customers/{dialog-box/dialog-box.component.html => add-customers/add-customers.component.html} (100%) rename ng-seed/src/app/appoinment/customers/{dialog-box/dialog-box.component.scss => add-customers/add-customers.component.scss} (100%) rename ng-seed/src/app/appoinment/{user/add-user-list/add-user-list.component.spec.ts => customers/add-customers/add-customers.component.spec.ts} (53%) rename ng-seed/src/app/appoinment/customers/{dialog-box/dialog-box.component.ts => add-customers/add-customers.component.ts} (90%) rename ng-seed/src/app/appoinment/service-list-details/{dialog-box/dialog-box.component.html => add-service/add-service.component.html} (100%) rename ng-seed/src/app/appoinment/service-list-details/{dialog-box/dialog-box.component.scss => add-service/add-service.component.scss} (100%) rename ng-seed/src/app/appoinment/{customers/dialog-box/dialog-box.component.spec.ts => service-list-details/add-service/add-service.component.spec.ts} (54%) rename ng-seed/src/app/appoinment/service-list-details/{dialog-box/dialog-box.component.ts => add-service/add-service.component.ts} (85%) delete mode 100644 ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.html delete mode 100644 ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.scss delete mode 100644 ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.ts create mode 100644 ng-seed/src/app/appoinment/user/add-user/add-user.component.html rename ng-seed/src/app/appoinment/user/{user-dialog-box/user-dialog-box.component.scss => add-user/add-user.component.scss} (100%) rename ng-seed/src/app/appoinment/{business/dialog-box/dialog-box.component.spec.ts => user/add-user/add-user.component.spec.ts} (54%) rename ng-seed/src/app/appoinment/user/{user-dialog-box/user-dialog-box.component.ts => add-user/add-user.component.ts} (93%) delete mode 100644 ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.html delete mode 100644 ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.spec.ts diff --git a/ng-seed/src/app/appoinment/appoinment-routing.module.ts b/ng-seed/src/app/appoinment/appoinment-routing.module.ts index beb003e..e11458c 100644 --- a/ng-seed/src/app/appoinment/appoinment-routing.module.ts +++ b/ng-seed/src/app/appoinment/appoinment-routing.module.ts @@ -1,21 +1,20 @@ import { Component, NgModule } from '@angular/core'; import { RouterModule, Routes } from '@angular/router'; import { AppoinmentsListComponent } from './appoinments/appoinments-list/appoinments-list.component'; -import { AddBusinessListComponent } from './business/add-business-list/add-business-list.component'; import { BusinessListComponent } from './business/business-list/business-list.component'; import { CalendarListComponent } from './calendars/calendar-list/calendar-list.component'; import { CustomersListComponent } from './customers/customers-list/customers-list.component'; import { ServiceListComponent } from './service-list-details/service-list/service-list.component'; -import { AddUserListComponent } from './user/add-user-list/add-user-list.component'; import { UserListComponent } from './user/user-list/user-list.component'; import { } from './service-list-details/service-list/service-list.component' import { ConsultantsListComponent } from './consultants/consultants-list/consultants-list.component'; -const routes: Routes = [ { - path: 'add-business-list', - component: AddBusinessListComponent -}, +const routes: Routes = [ +// { +// path: 'add-business-list', +// component: AddBusinessListComponent +// }, { path: 'add-user-list', diff --git a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.html b/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.html deleted file mode 100644 index ef403b0..0000000 --- a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.html +++ /dev/null @@ -1,64 +0,0 @@ - -
-

Add Business

-
-
- - - - -- - - {{business.name}} - - - Please Business - Please choose any other - - - - Name is required - Limit exceed - - - - - Please enter a valid email address - - - Email is required - - - - - Contact No is required - Limit exceed - - - - Address is required - Limit exceed - - - - City is required - Limit exceed - - - - City is required - Limit exceed - - -
- -
- -
- -
-
-
\ No newline at end of file diff --git a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.scss b/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.scss deleted file mode 100644 index c4835fa..0000000 --- a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.scss +++ /dev/null @@ -1,7 +0,0 @@ -.vertical-center { - margin: 0; - // position: absolute; - // top: 50%; - // -ms-transform: translateY(-50%); - // transform: translateY(-50%); - } \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.spec.ts b/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.spec.ts deleted file mode 100644 index c19a956..0000000 --- a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { ComponentFixture, TestBed } from '@angular/core/testing'; - -import { AddBusinessListComponent } from './add-business-list.component'; - -describe('AddBusinessListComponent', () => { - let component: AddBusinessListComponent; - let fixture: ComponentFixture; - - beforeEach(async () => { - await TestBed.configureTestingModule({ - declarations: [ AddBusinessListComponent ] - }) - .compileComponents(); - }); - - beforeEach(() => { - fixture = TestBed.createComponent(AddBusinessListComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.ts b/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.ts deleted file mode 100644 index 66fe6b8..0000000 --- a/ng-seed/src/app/appoinment/business/add-business-list/add-business-list.component.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { Component, OnInit } from '@angular/core'; -import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms'; -import { Router } from '@angular/router'; - -@Component({ - selector: 'app-add-business-list', - templateUrl: './add-business-list.component.html', - styleUrls: ['./add-business-list.component.scss'] -}) -export class AddBusinessListComponent implements OnInit { - form: FormGroup; - fileToUpload: any; - imageUrl: any; - - businessselect = new FormControl('', [Validators.required]); - selects = [ - {name: 'A'}, - {name: 'B'}, - {name: 'C'}, - {name: 'D'}, - ]; - - constructor(private router: Router,private formBuilder: FormBuilder) { } - - get f(){ - return this.form.controls; - } - -ngOnInit() { - this.form = new FormGroup({ - businessselect: new FormControl('', [Validators.required]), - bus_name: new FormControl('', [Validators.required, Validators.maxLength(20)]), - address: new FormControl('', [Validators.required, Validators.maxLength(50)]), - city: new FormControl('', [Validators.required, Validators.maxLength(10)]), - state: new FormControl('', [Validators.required, Validators.maxLength(10)]), - email: new FormControl('', [Validators.required, Validators.email,Validators.pattern( - '[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+.[a-zA-Z]{2,63}$', - ),]), - contact_no: new FormControl('', [Validators.required, Validators.maxLength(10)]), - }); - } - - public myError = (controlName: string, errorName: string) =>{ - return this.form.controls[controlName].hasError(errorName); - } - - submit(){ - console.log(this.form.value); - } - register() { - this.router.navigate(['/']); - } - - handleFileInput(file: FileList) { - this.fileToUpload = file.item(0); - - //Show image preview - let reader = new FileReader(); - reader.onload = (event: any) => { - this.imageUrl = event.target.result; - } - reader.readAsDataURL(this.fileToUpload); - } - - -} diff --git a/ng-seed/src/app/appoinment/business/add-business/add-business.component.html b/ng-seed/src/app/appoinment/business/add-business/add-business.component.html new file mode 100644 index 0000000..cdfe5f3 --- /dev/null +++ b/ng-seed/src/app/appoinment/business/add-business/add-business.component.html @@ -0,0 +1,66 @@ + +
{{action}} Business +
+
+ +
+ + + + Name is required + Limit exceed + + + + + + Please enter a valid email address + + + Email is required + + + + + Contact No is required + Limit exceed + + + + Address is required + Limit exceed + + + + State is required + Limit exceed + + + + City is required + Limit exceed + + + + + + +
+
+ + Sure to delete {{local_data.name}}? + +
+ + +
+
+ + + + \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.scss b/ng-seed/src/app/appoinment/business/add-business/add-business.component.scss similarity index 100% rename from ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.scss rename to ng-seed/src/app/appoinment/business/add-business/add-business.component.scss diff --git a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.spec.ts b/ng-seed/src/app/appoinment/business/add-business/add-business.component.spec.ts similarity index 53% rename from ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.spec.ts rename to ng-seed/src/app/appoinment/business/add-business/add-business.component.spec.ts index ec05663..138402c 100644 --- a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.spec.ts +++ b/ng-seed/src/app/appoinment/business/add-business/add-business.component.spec.ts @@ -1,20 +1,20 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { DialogBoxComponent } from './dialog-box.component'; +import { AddBusinessComponent } from './add-business.component'; -describe('DialogBoxComponent', () => { - let component: DialogBoxComponent; - let fixture: ComponentFixture; +describe('AddBusinessComponent', () => { + let component: AddBusinessComponent; + let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [ DialogBoxComponent ] + declarations: [ AddBusinessComponent ] }) .compileComponents(); }); beforeEach(() => { - fixture = TestBed.createComponent(DialogBoxComponent); + fixture = TestBed.createComponent(AddBusinessComponent); component = fixture.componentInstance; fixture.detectChanges(); }); diff --git a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.ts b/ng-seed/src/app/appoinment/business/add-business/add-business.component.ts similarity index 91% rename from ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.ts rename to ng-seed/src/app/appoinment/business/add-business/add-business.component.ts index 41294c8..4ff2f3c 100644 --- a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.ts +++ b/ng-seed/src/app/appoinment/business/add-business/add-business.component.ts @@ -7,12 +7,14 @@ export interface UsersData { name: string; id: number; } + @Component({ - selector: 'app-dialog-box', - templateUrl: './dialog-box.component.html', - styleUrls: ['./dialog-box.component.scss'] + selector: 'app-add-business', + templateUrl: './add-business.component.html', + styleUrls: ['./add-business.component.scss'] }) -export class DialogBoxComponent implements OnInit { +export class AddBusinessComponent implements OnInit { + form: FormGroup; fileToUpload: any; imageUrl: any; @@ -20,7 +22,7 @@ export class DialogBoxComponent implements OnInit { local_data:any; url: string | ArrayBuffer; constructor(private router: Router,private formBuilder: FormBuilder, - public dialogRef: MatDialogRef, + public dialogRef: MatDialogRef, @Optional() @Inject(MAT_DIALOG_DATA) public data: UsersData) { console.log(data); this.local_data = {...data}; @@ -80,4 +82,5 @@ export class DialogBoxComponent implements OnInit { console.log(this.form.value); console.log(this.action,this.local_data) } + } diff --git a/ng-seed/src/app/appoinment/business/business-list/business-list.component.ts b/ng-seed/src/app/appoinment/business/business-list/business-list.component.ts index 4f5766e..b3af241 100644 --- a/ng-seed/src/app/appoinment/business/business-list/business-list.component.ts +++ b/ng-seed/src/app/appoinment/business/business-list/business-list.component.ts @@ -5,8 +5,9 @@ import { MatSort } from '@angular/material/sort'; import { MatTable, MatTableDataSource } from '@angular/material/table'; import { Router } from '@angular/router'; import Swal from 'sweetalert2/dist/sweetalert2.js'; +import { AddBusinessComponent } from '../add-business/add-business.component'; import { BusinessService } from '../business-service/business.service'; -import { DialogBoxComponent } from '../dialog-box/dialog-box.component'; + export interface UsersData { id: number; @@ -108,7 +109,7 @@ export class BusinessListComponent implements OnInit { } openDialog(action,obj) { obj.action = action; - const dialogRef = this.dialog.open(DialogBoxComponent, { + const dialogRef = this.dialog.open(AddBusinessComponent, { width: '39%', height: '100%', // maxWidth: '38vw', diff --git a/ng-seed/src/app/appoinment/business/business.module.ts b/ng-seed/src/app/appoinment/business/business.module.ts index cfbad6d..a14c122 100644 --- a/ng-seed/src/app/appoinment/business/business.module.ts +++ b/ng-seed/src/app/appoinment/business/business.module.ts @@ -3,21 +3,19 @@ import { CommonModule } from '@angular/common'; import { BusinessRoutingModule } from './business-routing.module'; import { BusinessListComponent } from './business-list/business-list.component'; -import { AddBusinessListComponent } from './add-business-list/add-business-list.component'; import { MatSidenavModule } from '@angular/material/sidenav'; import { MatFormFieldModule } from '@angular/material/form-field'; -import { DialogBoxComponent } from './dialog-box/dialog-box.component'; import { ScrollingModule } from '@angular/cdk/scrolling'; import { DemoMaterialModule } from 'app/shared/demo.module'; import { NgScrollbarModule } from 'ngx-scrollbar'; +import { AddBusinessComponent } from './add-business/add-business.component'; @NgModule({ declarations: [ BusinessListComponent, - AddBusinessListComponent, - DialogBoxComponent + AddBusinessComponent ], imports: [ diff --git a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.html b/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.html deleted file mode 100644 index 68fb9ae..0000000 --- a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.html +++ /dev/null @@ -1,66 +0,0 @@ - -
{{action}} Business -
-
- -
- - - - Name is required - Limit exceed - - - - - - Please enter a valid email address - - - Email is required - - - - - Contact No is required - Limit exceed - - - - Address is required - Limit exceed - - - - State is required - Limit exceed - - - - City is required - Limit exceed - - - - - - -
-
- - Sure to delete {{local_data.name}}? - -
- - -
-
- - - - \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.html b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.html index 6a76a68..9066ae0 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.html +++ b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.html @@ -1,10 +1,19 @@ + + -
- -
+ - Staff Information + + Staff Information
@@ -85,9 +94,9 @@
First Name is required
-
+
@@ -95,13 +104,14 @@ - Working Hours + + Working Hours
Working Hours - +
@@ -210,6 +220,7 @@
+ Staff Booking URL @@ -238,4 +249,6 @@ -
\ No newline at end of file + + + \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.scss b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.scss index a75b318..5793d5d 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.scss +++ b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.scss @@ -24,6 +24,7 @@ flex-direction: column; background-color: white; margin-left: 2rem; + // margin-top: -9rem; } mat-tab-body { @@ -324,4 +325,23 @@ margin-bottom: 10rem; } - +// .user-pro-wrap{ +// background-color: #fff; +// // height: 100%; +// width: 18%; +// } +// .userpic{ +// font-size: 17px; +// display: block; +// overflow: hidden; +// text-overflow: ellipsis; +// white-space: nowrap; +// color: #4C4C4C; +// text-align: center; +// } +// .admin{ +// display: inline-block; +// font-size: 12px; +// color: #4C4C4C; +// text-align: center; +// } diff --git a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.ts b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.ts index 2160ff1..0b397b8 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.ts +++ b/ng-seed/src/app/appoinment/consultant-setting/consultant-setting/consultant-setting.component.ts @@ -1,5 +1,7 @@ import { Component, OnInit } from '@angular/core'; import { FormBuilder, FormGroup, Validators } from '@angular/forms'; +import { MatDialog } from '@angular/material/dialog'; +import { EditWorkingHoursComponent } from '../edit-working-hours/edit-working-hours.component'; @Component({ selector: 'app-consultant-setting', @@ -19,7 +21,7 @@ export class ConsultantSettingComponent implements OnInit { status: 'Active', }, ]; - constructor(private formBuilder: FormBuilder) {} + constructor(private formBuilder: FormBuilder, public dialog: MatDialog) {} ngOnInit() { @@ -47,5 +49,22 @@ onSubmit() { } console.log(JSON.stringify(this.registerForm.value, null, 2)); } +openDialog(action,obj) { + obj.action = action; + const dialogRef = this.dialog.open(EditWorkingHoursComponent, { + width: '48%', + height: '100%', + // maxWidth: '38vw', + position: { right: '0' }, + data:obj + }); + // dialogRef.afterClosed().subscribe(result => { + // if(result != undefined){ + // console.log(result) + // this.formAddUpdateAndDelete(result,result.data) + // } + // }); +} + } diff --git a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.html b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.html index fbed12b..a2b9f0b 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.html +++ b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.html @@ -1 +1,271 @@ -

edit-working-hours works!

+
+ + + +
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+
+
+ + + + +
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ + +
+
Apply To All
+
+ + +
+ + + diff --git a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.scss b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.scss index e69de29..4d76379 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.scss +++ b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.scss @@ -0,0 +1,96 @@ +.edit-working{ + .popup-header { + background: #FFF; + padding: 5px 5px 5px 5px; + } + .button{ + // float: right; + margin-bottom: 1rem; + background-color: #ffff; + margin-top: -1rem; + // margin-left: 6rem; + float: right; + } + .label-container { + display: flex; + width: 100%; + border-bottom: 1px solid #F5F6F8; + box-sizing: border-box; + min-height: 40px; + padding: 13px 0; + } + .label-name{ + color: #666; + position: relative; + text-transform: capitalize; + width: 100px; + flex: none; + margin-right: 15px; + align-self: flex-start; + padding-top: 13px; + box-sizing: border-box; + line-height: 15px; + } + .labelname label { + color: #666; + font-size: 14px; + // padding: 10px 10px 10px 10px; + width: 150px; + } + .dis-flex { + display: flex!important; + } + .width-10px { + width: 10px!important; + } + .select-drop-box { + padding-right: 30px; + height: 40px; + background-color: #FFF; + font-size: 13px; + color: #111; + border-radius: 4px; + border-color: #666; + } + .addbreak{ + margin-top: 0.5rem; + margin-right: 2rem; + color: #FFF; + &:hover { + cursor: pointer; + color: #111; + } + } + // .scrollHV { + // height: calc(100vh - 190px); + // } + + .popup-button { + margin-top: 2rem; + width: 100%; + } + .cancel { + background: #F5F5F5; + color: #111; + float: left; + } + .buttons { + width: 50%; + background: #FFF; + color: #111; + font-size: 13px; + font-family: zohopuvi-medium; + text-align: center; + border-top: 1px solid #E2E2E2; + padding: 20px; + -webkit-transition: all .2s ease-in; + -moz-transition: all .2s ease-in; + transition: all .2s ease-in; + } + .add { + background: #52518F; + color: #FFF; + border-top: 1px solid #52518F; + float: left; + } +} diff --git a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.ts b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.ts index 59c16ba..5a3a0b1 100644 --- a/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.ts +++ b/ng-seed/src/app/appoinment/consultant-setting/edit-working-hours/edit-working-hours.component.ts @@ -1,4 +1,6 @@ import { Component, OnInit } from '@angular/core'; +import { FormBuilder, FormGroup } from '@angular/forms'; +import { MatDialogRef } from '@angular/material/dialog'; @Component({ selector: 'app-edit-working-hours', @@ -7,10 +9,30 @@ import { Component, OnInit } from '@angular/core'; }) export class EditWorkingHoursComponent implements OnInit { - - constructor() { } + datainputForm: FormGroup; + timing: any[] = ['09:00am','09:30am','10:00am','10:30am','11:00am','11:30am','12:00am','12:30am','01:00pm','01:00pm','01:30pm', '02:00pm', '02:30pm', '03:00pm', '03:30pm', '04:00pm', '04:30pm', '05:00pm', '05:30pm', '06:00pm', '06:30pm', '07:00pm', '07:30pm', '08:00pm','08:30pm', '09:00pm',] - ngOnInit(): void { + constructor(public dialogRef: MatDialogRef, private fb: FormBuilder) { } + + + close() { + this.dialogRef.close(); +} + +ngOnInit(): void { + this.datainputForm = this.fb.group({ + dropDownTest: '09:00am', + dropDownTest1:'' + }) +} +onSelectChange(){ + console.log(this.datainputForm.get('dropDownTest').value); + if( this.datainputForm.get('dropDownTest').value === 'vmnic3'){ + + this.datainputForm.get('dropDownTest1').disable(); + }else{ + this.datainputForm.get('dropDownTest1').enable(); + } } } diff --git a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.html b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.html similarity index 100% rename from ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.html rename to ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.html diff --git a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.scss b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.scss similarity index 100% rename from ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.scss rename to ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.scss diff --git a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.spec.ts b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.spec.ts similarity index 53% rename from ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.spec.ts rename to ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.spec.ts index 133b584..f81a8fe 100644 --- a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.spec.ts +++ b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.spec.ts @@ -1,20 +1,20 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { AddUserListComponent } from './add-user-list.component'; +import { AddCustomersComponent } from './add-customers.component'; -describe('AddUserListComponent', () => { - let component: AddUserListComponent; - let fixture: ComponentFixture; +describe('AddCustomersComponent', () => { + let component: AddCustomersComponent; + let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [ AddUserListComponent ] + declarations: [ AddCustomersComponent ] }) .compileComponents(); }); beforeEach(() => { - fixture = TestBed.createComponent(AddUserListComponent); + fixture = TestBed.createComponent(AddCustomersComponent); component = fixture.componentInstance; fixture.detectChanges(); }); diff --git a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.ts b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.ts similarity index 90% rename from ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.ts rename to ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.ts index c0c2445..34f3893 100644 --- a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.ts +++ b/ng-seed/src/app/appoinment/customers/add-customers/add-customers.component.ts @@ -6,12 +6,14 @@ export interface UsersData { cusName: string; id: number; } + @Component({ - selector: 'app-dialog-box', - templateUrl: './dialog-box.component.html', - styleUrls: ['./dialog-box.component.scss'] + selector: 'app-add-customers', + templateUrl: './add-customers.component.html', + styleUrls: ['./add-customers.component.scss'] }) -export class DialogBoxComponent implements OnInit { +export class AddCustomersComponent implements OnInit { + form: FormGroup; fileToUpload: any; imageUrl: any; @@ -19,7 +21,7 @@ export class DialogBoxComponent implements OnInit { local_data:any; url: string | ArrayBuffer; constructor(private router: Router,private formBuilder: FormBuilder, - public dialogRef: MatDialogRef, + public dialogRef: MatDialogRef, @Optional() @Inject(MAT_DIALOG_DATA) public data: UsersData) { console.log(data); this.local_data = {...data}; @@ -73,4 +75,5 @@ export class DialogBoxComponent implements OnInit { console.log(this.form.value); console.log(this.action,this.local_data) } + } diff --git a/ng-seed/src/app/appoinment/customers/customers-list/customers-list.component.ts b/ng-seed/src/app/appoinment/customers/customers-list/customers-list.component.ts index 3ad75fe..9d34fc5 100644 --- a/ng-seed/src/app/appoinment/customers/customers-list/customers-list.component.ts +++ b/ng-seed/src/app/appoinment/customers/customers-list/customers-list.component.ts @@ -3,8 +3,9 @@ import { MatDialog } from '@angular/material/dialog'; import { MatPaginator, PageEvent } from '@angular/material/paginator'; import { MatTable, MatTableDataSource } from '@angular/material/table'; import Swal from 'sweetalert2'; +import { AddCustomersComponent } from '../add-customers/add-customers.component'; import { CustomersService } from '../customers-service/customers.service'; -import { DialogBoxComponent } from '../dialog-box/dialog-box.component'; + export interface UsersData { id: number; @@ -128,7 +129,7 @@ export class CustomersListComponent implements OnInit { } openDialog(action,obj) { obj.action = action; - const dialogRef = this.dialog.open(DialogBoxComponent, { + const dialogRef = this.dialog.open(AddCustomersComponent, { width: '39%', height: '100%', // maxWidth: '38vw', diff --git a/ng-seed/src/app/appoinment/customers/customers.module.ts b/ng-seed/src/app/appoinment/customers/customers.module.ts index 08254f7..eb6ca3b 100644 --- a/ng-seed/src/app/appoinment/customers/customers.module.ts +++ b/ng-seed/src/app/appoinment/customers/customers.module.ts @@ -5,15 +5,15 @@ import { CustomersRoutingModule } from './customers-routing.module'; import { CustomersListComponent } from './customers-list/customers-list.component'; import { MatSidenavModule } from '@angular/material/sidenav'; import { MatFormFieldModule } from '@angular/material/form-field'; -import { DialogBoxComponent } from './dialog-box/dialog-box.component'; import { DemoMaterialModule } from 'app/shared/demo.module'; import { NgScrollbarModule } from 'ngx-scrollbar'; +import { AddCustomersComponent } from './add-customers/add-customers.component'; @NgModule({ declarations: [ CustomersListComponent, - DialogBoxComponent + AddCustomersComponent ], imports: [ DemoMaterialModule, diff --git a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.html b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.html similarity index 100% rename from ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.html rename to ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.html diff --git a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.scss b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.scss similarity index 100% rename from ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.scss rename to ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.scss diff --git a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.spec.ts b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.spec.ts similarity index 54% rename from ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.spec.ts rename to ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.spec.ts index ec05663..81cccee 100644 --- a/ng-seed/src/app/appoinment/customers/dialog-box/dialog-box.component.spec.ts +++ b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.spec.ts @@ -1,20 +1,20 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { DialogBoxComponent } from './dialog-box.component'; +import { AddServiceComponent } from './add-service.component'; -describe('DialogBoxComponent', () => { - let component: DialogBoxComponent; - let fixture: ComponentFixture; +describe('AddServiceComponent', () => { + let component: AddServiceComponent; + let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [ DialogBoxComponent ] + declarations: [ AddServiceComponent ] }) .compileComponents(); }); beforeEach(() => { - fixture = TestBed.createComponent(DialogBoxComponent); + fixture = TestBed.createComponent(AddServiceComponent); component = fixture.componentInstance; fixture.detectChanges(); }); diff --git a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.ts b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.ts similarity index 85% rename from ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.ts rename to ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.ts index deca586..ffbbd48 100644 --- a/ng-seed/src/app/appoinment/service-list-details/dialog-box/dialog-box.component.ts +++ b/ng-seed/src/app/appoinment/service-list-details/add-service/add-service.component.ts @@ -6,17 +6,19 @@ export interface UsersData { servicesName: string; id: number; } + @Component({ - selector: 'app-dialog-box', - templateUrl: './dialog-box.component.html', - styleUrls: ['./dialog-box.component.scss'] + selector: 'app-add-service', + templateUrl: './add-service.component.html', + styleUrls: ['./add-service.component.scss'] }) -export class DialogBoxComponent implements OnInit { +export class AddServiceComponent implements OnInit { + form: FormGroup; local_data:any; action:string; constructor(private router: Router,private formBuilder: FormBuilder, - public dialogRef: MatDialogRef, + public dialogRef: MatDialogRef, @Optional() @Inject(MAT_DIALOG_DATA) public data: UsersData) { console.log(data); this.local_data = {...data}; @@ -52,4 +54,5 @@ ngOnInit() { console.log(this.form.value); console.log(this.action,this.local_data) } + } diff --git a/ng-seed/src/app/appoinment/service-list-details/service-list.module.ts b/ng-seed/src/app/appoinment/service-list-details/service-list.module.ts index 9970edb..2f683d7 100644 --- a/ng-seed/src/app/appoinment/service-list-details/service-list.module.ts +++ b/ng-seed/src/app/appoinment/service-list-details/service-list.module.ts @@ -4,13 +4,13 @@ import { CommonModule } from '@angular/common'; import { ServiceListRoutingModule } from './service-list-routing.module'; import { ServiceListComponent } from './service-list/service-list.component'; import { DemoMaterialModule } from 'app/shared/demo.module'; -import { DialogBoxComponent } from './dialog-box/dialog-box.component'; +import { AddServiceComponent } from './add-service/add-service.component'; @NgModule({ declarations: [ ServiceListComponent, - DialogBoxComponent + AddServiceComponent ], imports: [ DemoMaterialModule, diff --git a/ng-seed/src/app/appoinment/service-list-details/service-list/service-list.component.ts b/ng-seed/src/app/appoinment/service-list-details/service-list/service-list.component.ts index d392580..a047760 100644 --- a/ng-seed/src/app/appoinment/service-list-details/service-list/service-list.component.ts +++ b/ng-seed/src/app/appoinment/service-list-details/service-list/service-list.component.ts @@ -2,7 +2,7 @@ import { Component, OnInit } from '@angular/core'; import { MatDialog } from '@angular/material/dialog'; import { MatTableDataSource } from '@angular/material/table'; import Swal from 'sweetalert2'; -import { DialogBoxComponent } from '../dialog-box/dialog-box.component'; +import { AddServiceComponent } from '../add-service/add-service.component'; import { ApiServiceService } from '../service-api-services/api-service.service'; @Component({ @@ -99,7 +99,7 @@ export class ServiceListComponent implements OnInit { openDialog(action,obj) { obj.action = action; - const dialogRef = this.dialog.open(DialogBoxComponent, { + const dialogRef = this.dialog.open(AddServiceComponent, { width: '39%', height: '100%', // maxWidth: '38vw', diff --git a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.html b/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.html deleted file mode 100644 index a963cb2..0000000 --- a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.html +++ /dev/null @@ -1 +0,0 @@ -

add-user-list works!

diff --git a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.scss b/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.scss deleted file mode 100644 index e69de29..0000000 diff --git a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.ts b/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.ts deleted file mode 100644 index f8c33e9..0000000 --- a/ng-seed/src/app/appoinment/user/add-user-list/add-user-list.component.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { Component, OnInit } from '@angular/core'; -import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms'; -import { Router } from '@angular/router'; - -@Component({ - selector: 'app-add-user-list', - templateUrl: './add-user-list.component.html', - styleUrls: ['./add-user-list.component.scss'] -}) -export class AddUserListComponent implements OnInit { - - form: FormGroup; - fileToUpload: any; - imageUrl: any; - - businessselect = new FormControl('', [Validators.required]); - selects = [ - {name: 'A'}, - {name: 'B'}, - {name: 'C'}, - {name: 'D'}, - ]; - - constructor(private router: Router,private formBuilder: FormBuilder) { } - - get f(){ - return this.form.controls; - } - -ngOnInit() { - this.form = new FormGroup({ - businessselect: new FormControl('', [Validators.required]), - bus_name: new FormControl('', [Validators.required, Validators.maxLength(20)]), - address: new FormControl('', [Validators.required, Validators.maxLength(50)]), - city: new FormControl('', [Validators.required, Validators.maxLength(10)]), - state: new FormControl('', [Validators.required, Validators.maxLength(10)]), - email: new FormControl('', [Validators.required, Validators.email,Validators.pattern( - '[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+.[a-zA-Z]{2,63}$', - ),]), - contact_no: new FormControl('', [Validators.required, Validators.maxLength(10)]), - }); - } - - public myError = (controlName: string, errorName: string) =>{ - return this.form.controls[controlName].hasError(errorName); - } - - submit(){ - console.log(this.form.value); - } - register() { - this.router.navigate(['/']); - } - - handleFileInput(file: FileList) { - this.fileToUpload = file.item(0); - - //Show image preview - let reader = new FileReader(); - reader.onload = (event: any) => { - this.imageUrl = event.target.result; - } - reader.readAsDataURL(this.fileToUpload); - } - -} diff --git a/ng-seed/src/app/appoinment/user/add-user/add-user.component.html b/ng-seed/src/app/appoinment/user/add-user/add-user.component.html new file mode 100644 index 0000000..e8c4089 --- /dev/null +++ b/ng-seed/src/app/appoinment/user/add-user/add-user.component.html @@ -0,0 +1,67 @@ + +
{{action}} Users +
+ +
+
+ + + -- + + {{business.busName}} + + + role is required + + + + + role is required + Limit exceed + + + + + Username is required + Limit exceed + + + + + Please enter a valid email address + + + Email is required + + + + + Contact No is required + Limit exceed + + + + Password is required + Limit exceed + + + +
+
+
+ + Sure to delete {{local_data.name}}? +
+
+ + +
+
+ + \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.scss b/ng-seed/src/app/appoinment/user/add-user/add-user.component.scss similarity index 100% rename from ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.scss rename to ng-seed/src/app/appoinment/user/add-user/add-user.component.scss diff --git a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.spec.ts b/ng-seed/src/app/appoinment/user/add-user/add-user.component.spec.ts similarity index 54% rename from ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.spec.ts rename to ng-seed/src/app/appoinment/user/add-user/add-user.component.spec.ts index ec05663..68d1642 100644 --- a/ng-seed/src/app/appoinment/business/dialog-box/dialog-box.component.spec.ts +++ b/ng-seed/src/app/appoinment/user/add-user/add-user.component.spec.ts @@ -1,20 +1,20 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { DialogBoxComponent } from './dialog-box.component'; +import { AddUserComponent } from './add-user.component'; -describe('DialogBoxComponent', () => { - let component: DialogBoxComponent; - let fixture: ComponentFixture; +describe('AddUserComponent', () => { + let component: AddUserComponent; + let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [ DialogBoxComponent ] + declarations: [ AddUserComponent ] }) .compileComponents(); }); beforeEach(() => { - fixture = TestBed.createComponent(DialogBoxComponent); + fixture = TestBed.createComponent(AddUserComponent); component = fixture.componentInstance; fixture.detectChanges(); }); diff --git a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.ts b/ng-seed/src/app/appoinment/user/add-user/add-user.component.ts similarity index 93% rename from ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.ts rename to ng-seed/src/app/appoinment/user/add-user/add-user.component.ts index ea882c0..a95a6f2 100644 --- a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.ts +++ b/ng-seed/src/app/appoinment/user/add-user/add-user.component.ts @@ -7,12 +7,14 @@ export interface UsersData { userName: string; id: number; } + @Component({ - selector: 'app-user-dialog-box', - templateUrl: './user-dialog-box.component.html', - styleUrls: ['./user-dialog-box.component.scss'] + selector: 'app-add-user', + templateUrl: './add-user.component.html', + styleUrls: ['./add-user.component.scss'] }) -export class UserDialogBoxComponent implements OnInit { +export class AddUserComponent implements OnInit { + hide: boolean; form: FormGroup; fileToUpload: any; @@ -22,7 +24,7 @@ export class UserDialogBoxComponent implements OnInit { url: string | ArrayBuffer; businessList: any; constructor(private router: Router,private formBuilder: FormBuilder, - public dialogRef: MatDialogRef, + public dialogRef: MatDialogRef, @Optional() @Inject(MAT_DIALOG_DATA) public data: UsersData,public _bus:BusinessService) { console.log(data); this.local_data = {...data}; @@ -98,5 +100,5 @@ export class UserDialogBoxComponent implements OnInit { submit(){ console.log(this.form.value); } - + } diff --git a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.html b/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.html deleted file mode 100644 index 929848b..0000000 --- a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.html +++ /dev/null @@ -1,67 +0,0 @@ - -
{{action}} Users -
- -
-
- - - -- - - {{business.busName}} - - - role is required - - - - - role is required - Limit exceed - - - - - Username is required - Limit exceed - - - - - Please enter a valid email address - - - Email is required - - - - - Contact No is required - Limit exceed - - - - Password is required - Limit exceed - - - -
-
-
- - Sure to delete {{local_data.name}}? -
-
- - -
-
- - \ No newline at end of file diff --git a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.spec.ts b/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.spec.ts deleted file mode 100644 index 9d4228a..0000000 --- a/ng-seed/src/app/appoinment/user/user-dialog-box/user-dialog-box.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { ComponentFixture, TestBed } from '@angular/core/testing'; - -import { UserDialogBoxComponent } from './user-dialog-box.component'; - -describe('UserDialogBoxComponent', () => { - let component: UserDialogBoxComponent; - let fixture: ComponentFixture; - - beforeEach(async () => { - await TestBed.configureTestingModule({ - declarations: [ UserDialogBoxComponent ] - }) - .compileComponents(); - }); - - beforeEach(() => { - fixture = TestBed.createComponent(UserDialogBoxComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/ng-seed/src/app/appoinment/user/user-list/user-list.component.ts b/ng-seed/src/app/appoinment/user/user-list/user-list.component.ts index 54aa691..05fa044 100644 --- a/ng-seed/src/app/appoinment/user/user-list/user-list.component.ts +++ b/ng-seed/src/app/appoinment/user/user-list/user-list.component.ts @@ -4,7 +4,7 @@ import { MatPaginator } from '@angular/material/paginator'; import { MatSort } from '@angular/material/sort'; import { MatTable, MatTableDataSource } from '@angular/material/table'; import Swal from 'sweetalert2/dist/sweetalert2.js'; -import { UserDialogBoxComponent } from '../user-dialog-box/user-dialog-box.component'; +import { AddUserComponent } from '../add-user/add-user.component'; import { UserService } from '../user-service/user.service'; export interface UsersData { @@ -127,7 +127,7 @@ export class UserListComponent implements OnInit { } openDialog(action,obj) { obj.action = action; - const dialogRef = this.dialog.open(UserDialogBoxComponent, { + const dialogRef = this.dialog.open(AddUserComponent, { // width: '30%', height: '100%', // maxWidth: '38vw', diff --git a/ng-seed/src/app/appoinment/user/user.module.ts b/ng-seed/src/app/appoinment/user/user.module.ts index 0baf597..ccd9bd3 100644 --- a/ng-seed/src/app/appoinment/user/user.module.ts +++ b/ng-seed/src/app/appoinment/user/user.module.ts @@ -1,21 +1,19 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { UserRoutingModule } from './user-routing.module'; -import { AddUserListComponent } from './add-user-list/add-user-list.component'; import { UserListComponent } from './user-list/user-list.component'; import { MatSidenavModule } from '@angular/material/sidenav'; import { MatFormFieldModule } from '@angular/material/form-field'; -import { UserDialogBoxComponent } from './user-dialog-box/user-dialog-box.component'; import { DemoMaterialModule } from 'app/shared/demo.module'; import { NgScrollbarModule } from 'ngx-scrollbar'; +import { AddUserComponent } from './add-user/add-user.component'; @NgModule({ declarations: [ - AddUserListComponent, UserListComponent, - UserDialogBoxComponent + AddUserComponent ], imports: [ DemoMaterialModule,