From afbf9fbb9bfa2f20ebb309d6b0b13cdb4d8e162f Mon Sep 17 00:00:00 2001 From: "venbatechnologies@gmail.com" Date: Sun, 7 Oct 2018 09:32:13 +0530 Subject: [PATCH 01/11] master changes --- .../pd-triger/pd-service/pd-triger.service.ts | 4 +- .../branch-list/branch-list.component.html | 115 ++++-------- .../branch-list/branch-list.component.scss | 176 ++---------------- .../pd-team-list/pd-team-list.component.ts | 8 +- 4 files changed, 58 insertions(+), 245 deletions(-) diff --git a/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts b/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts index 62f166ac7..dc2cbe7bb 100644 --- a/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts +++ b/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts @@ -20,9 +20,9 @@ export interface Master { export class PdTrigerService { - private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; + //private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; //private apiUrl = "http://192.168.0.5:9999/AWSEC2/sparqapi/api/"; - //private apiUrl = "http://ssa.sineedge.com/sparqtest/api/"; + private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; constructor(private _http: HttpClient, private _aws:AwsService) { } diff --git a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html index c9e265933..07d63f9c1 100644 --- a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html @@ -1,54 +1,32 @@ - - - - - - - - - -
- + +
+
+ -
-
- -
-
--> - -
-
- - - -
-
- - -
- - - Sl - {{row.serialno}} - - - +
+ +
+
+ + + + + Sl + {{row.serialno}} + Branch Name - - {{row.name}} + {{row.name}} @@ -56,23 +34,12 @@ {{row.city_name}} - - - Actions - - - - + Actions + + + + @@ -93,19 +60,7 @@ (change)="isactiveBranch(row.branch_id,row.isactive)" onclick="return confirm('Are you sure?')"> - - - - + @@ -113,18 +68,12 @@ - - - + - + - - +
- - - \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.scss b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.scss index ed0fe77d4..dea0560d5 100644 --- a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.scss +++ b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.scss @@ -1,126 +1,14 @@ - -/* Structure -.example-container { - display: flex; - flex-direction: column; - min-width: 300px; -} - - -.example-header { - min-height: 56px; - max-height: 56px; - display: flex; - align-items: center; - padding: 8px 24px 0; - font-size: 20px; - justify-content: space-between; - border-bottom: 1px solid transparent; -} - -.mat-input-container { - font-size: 14px; - flex-grow: 1; - margin-left: 32px; - margin-top: 8px; -} - -.example-no-results { - display: flex; - justify-content: center; - padding: 24px; - font-size: 12px; - font-style: italic; -} - - Selection styles -.example-selection-header { - font-size: 18px; - background: rgba(255, 64, 129, 0.3); - border-bottom: 1px solid #d696ac; -} - -.mat-column-select { - max-width: 54px; -} - -.mat-row:hover, .example-selected-row { - background: #f5f5f5; -} - -.mat-row:active, .mat-row.example-selected-row { - background: #eaeaea; -} - -.mat-table { - overflow: auto; - max-height: 500px; -} -/*** Structure * -.example-container { - display: flex; - flex-direction: column; - min-width: 30px; - width : 80%; - margin : 20px auto; -} - -.example-header { - min-height: 64px; - padding: 8px 24px 0; -}****/ - - - -// .example-header { -// min-height: 56px; -// max-height: 56px; -// display: flex; -// align-items: center; -// padding: 8px 24px 0; -// font-size: 20px; -// justify-content: space-between; -// border-bottom: 1px solid transparent; -// } - - -// .active:hover{ -// color: green; -// font-size: 20px; -// } -// .deactive:hover{ -// color: red; -// font-size: 20px; -// } - -// mat-cell{ -// display:flex !important; -// justify-content:center!important; -// } - -// mat-header-cell { -// display:flex; -// justify-content:center; -// } - -// .example-h2 { -// margin: 10px; -// } - -// .example-section { -// display: flex; -// align-content: center; -// align-items: center; -// height: 60px; -// } - +/** Table SerialNo CSS */ .example-margin { margin: 10px; } + +/** Table CSS - Dislplay Data */ .mat-table { display: table; - - + width: 100%; + overflow: auto; + max-height: 500px; > .mat-header-row, > .mat-row { display: table-row; @@ -137,54 +25,26 @@ } } - -.mat-form-field { - font-size: 14px; - width: 100%; -} - +/** Table CSS -nocontent */ .nocontent { color: red; font-size: 16px; - //display:flex; - //justify-content:center; - // min-height: 56px; - // max-height: 56px; text-align: center; } -.example-container { - display: flex; - flex-direction: column; - min-width: 300px; -} - -.example-header { - min-height: 64px; - padding: 8px 24px 0; -} - - - -/** new ..** -.example-container { - display: flex; - flex-direction: column; - min-width: 300px; -} - -.example-header { - min-height: 64px; - padding: 8px 24px 0; -} - +/** Table CSS - Search(or)Filter Field */ .mat-form-field { font-size: 14px; width: 100%; } - -.mat-table { - overflow: auto; - max-height: 500px; + +.filter-container { + display: flex; + flex-direction: column; + min-width: 300px; } -*/ \ No newline at end of file + +.filter-header { + min-height: 64px; + padding: 8px 24px 0; +} \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts b/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts index e0440bf06..98a1e9063 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts +++ b/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts @@ -11,6 +11,7 @@ MatTableDataSource } from '@angular/material'; /** Service */ import { MastersService } from '../../../../service/masters/masters.service'; import { PdTeamService } from '../../../../service/masters/pd-team.service'; +import { NotifierService } from 'angular-notifier'; /** Dialog Component */ import { PdTeamDialogComponent } from '../pd-team-dialog/pd-team-dialog.component'; @@ -30,6 +31,7 @@ export class PdTeamListComponent implements OnInit { color = 'primary'; userData = null; noRecordFound: boolean = false; + private notifier: NotifierService; public dataLength: number; @@ -39,10 +41,11 @@ export class PdTeamListComponent implements OnInit { @ViewChild(MatPaginator) paginator: MatPaginator; @ViewChild(MatSort) sort: MatSort; - constructor(private dialog: MatDialog, + constructor(private dialog: MatDialog, notifier: NotifierService, private _MasterService: MastersService, private _PdTeamService: PdTeamService) { this.getPdTeam(); + this.notifier = notifier; } ngOnInit() {} @@ -130,7 +133,8 @@ export class PdTeamListComponent implements OnInit { this.getPdTeam(); } else{ - alert("SomeThing Wents Wrong Try Again !"); + //alert("SomeThing Wents Wrong Try Again !"); + this.notifier.notify('warning', 'SomeThing Wents Wrong Try Again !'); } }); } From 5781b18be64c77ab9e066a2d3030e64abcae5f97 Mon Sep 17 00:00:00 2001 From: venbaSriram Date: Tue, 9 Oct 2018 18:55:48 +0530 Subject: [PATCH 02/11] user Register new changes --- ng6-seed/src/app/AwsService/aws.service.ts | 43 ++- .../src/app/settings/service/user.service.ts | 61 ++-- .../users/register/register.component.html | 106 ++++--- .../users/register/register.component.ts | 292 +++++++++--------- 4 files changed, 268 insertions(+), 234 deletions(-) diff --git a/ng6-seed/src/app/AwsService/aws.service.ts b/ng6-seed/src/app/AwsService/aws.service.ts index 6cd0f2298..fb3c7a3a5 100755 --- a/ng6-seed/src/app/AwsService/aws.service.ts +++ b/ng6-seed/src/app/AwsService/aws.service.ts @@ -24,10 +24,10 @@ import { CognitoService } from './cognito.service'; -const sineedge_poolData = { - UserPoolId: "ap-south-1_y7dt3iEaX", //ap-south-1_qQ85yQZJO UserName :SPARQ_SINEEDGE_DEV - ClientId: "291qt4smn5pql6o8cc2hi201lj" // ClientName: SINEEDGE_DEV_WEB -}; +// const sineedge_poolData = { +// UserPoolId: "ap-south-1_y7dt3iEaX", //ap-south-1_qQ85yQZJO UserName :SPARQ_SINEEDGE_DEV +// ClientId: "291qt4smn5pql6o8cc2hi201lj" // ClientName: SINEEDGE_DEV_WEB +// }; const sineedgedev_poolData = { UserPoolId: "ap-south-1_qQ85yQZJO", // UserName :SPARQ_SINEEDGE_DEV ClientId: "2o5c3cs9k3als16nqhp3irh8rs" // ClientName: SINEEDGE_DEV_WEB @@ -37,10 +37,10 @@ const lender_poolData = { ClientId: "6egsdssf0i7h2o9mscqgqbn788" // ClientName:LENDER_DEV_WEB }; const vendor_poolData = { - UserPoolId: "", + UserPoolId: "ap-south-1_K57yPaWxV", ClientId: "" } -const sineedgeUserPool = new CognitoUserPool(sineedge_poolData); +// const sineedgeUserPool = new CognitoUserPool(sineedge_poolData); const lenderUserPool = new CognitoUserPool(lender_poolData); const sineedgedevUserpool = new CognitoUserPool(sineedgedev_poolData); @@ -48,8 +48,8 @@ const sineedgedevUserpool = new CognitoUserPool(sineedgedev_poolData); * Identity PoolID */ const sineedgeIdentity = "ap-south-1:9a551eab-97cf-4991-b677-2f9bcd058961";//"ap-south-1:9a551eab-97cf-4991-b677-2f9bcd058961"; -const lenderIdentity = "ap-south-1:ca22dabc-db59-4af5-9bb8-265f7ec95907"; -const vendorIdenttiy = ""; +const lenderIdentity = "ap-south-1:ca22dabc-db59-4af5-9bb8-265f7ec95907"; +const vendorIdenttiy = "ap-south-1:5ad3ce43-4260-4273-87b2-e6a377b8e874"; // serviceProvider const apiurl = "http://ssa.sineedge.com/sparqapi/api/"; //const apiurl = "http://localhost/sparqapi/api/"; @@ -355,6 +355,29 @@ export class AwsService { /* more items */ ] }; + }else if(userData.type.entity_type_id == 3){ + params = { + UserPoolId: vendor_poolData.UserPoolId /* required */, + Username: userData.email /* required */, + DesiredDeliveryMediums: [ + "EMAIL" + /* more items */ + ], + // ForceAliasCreation: true || false, + MessageAction: "SUPPRESS", + TemporaryPassword: "temp1234", + UserAttributes: [ + { + Name: "email" /* required */, + Value: userData.email + }, + { + Name: "phone_number" /* required */, + Value: "+91" + userData.phone + } + /* more items */ + ] + }; } console.log(params); return Observable.create(observe => { @@ -560,7 +583,7 @@ export class AwsService { )[0]; // (userGroup); if (userGroup == "ADMIN") { - if (userData.fk_entity_id == 1) { + if (userData.fk_entity_type_id == 1) { params = { UserPoolId: sineedgedev_poolData.UserPoolId /* required */, Username: userData.aws_name,//userData.email /* required */, @@ -579,7 +602,7 @@ export class AwsService { /* more items */ ] }; - } else if (userData.fk_entity_id == 2) { + } else if (userData.fk_entity_type_id == 2) { params = { UserPoolId: lender_poolData.UserPoolId /* required */, Username: userData.aws_name /* required */, diff --git a/ng6-seed/src/app/settings/service/user.service.ts b/ng6-seed/src/app/settings/service/user.service.ts index 0097bafe3..a3d4b5e40 100644 --- a/ng6-seed/src/app/settings/service/user.service.ts +++ b/ng6-seed/src/app/settings/service/user.service.ts @@ -4,6 +4,7 @@ import { Observable } from 'rxjs/internal/Observable'; import { AwsService } from '../../AwsService/aws.service'; import { environment } from 'environments/environment'; const apiurl = "http://ssa.sineedge.com/sparqapi/api/"; +// const apiurl = "http://localhost/sparqapi/api/"; const currentdate = new Date().toJSON().slice(0,19).replace('T',' '); @Injectable({ @@ -85,7 +86,15 @@ export class UserService { return this.http.post(apiurl+'getListOfMaster',master_name); } + roles(){ + let master_name = {'master_name':'ROLES'}; + return this.http.post(apiurl+'getListOfMaster',master_name); + } + entitiesDetails(){ + let master_name = {'master_name':'ENTITY'}; + return this.http.post(apiurl+'getListOfMaster',master_name); + } /** * */ @@ -124,59 +133,53 @@ export class UserService { console.log(users); - let roles:any=[]; - for(var role of users.role){ + // let roles:any=[]; + // for(var role of users.role){ - roles.push({ "user_role": role.GroupName }); - } + + - let designation:any; - if(users.type.entity_type_id ==2){ - let lenderhie:any =[]; - lenderhie.push(users.lenderHierarchy); - formData.append('lender_hierarchy',JSON.stringify(lenderhie)); - designation = ''; + let enities:any; + if(users.type.entity_type_id ==2 || users.type.entity_type_id == 3){ + enities = users.lenVenName.entity_id; }else if(users.type.entity_type_id ==1){ - designation =users.designation.designation_id; + enities =null; } let pdtypeid:any; - let productid:any; let pdteam:any; - let cust:any; - if(users.product != null && users.customer != null && users.pdteam !=null && users.pdtype !=null){ + + if(users.pdteam !=null && users.pdtype !=null){ pdtypeid = users.pdtype.pd_type_id; - productid = users.product.product_id; + pdteam = users.pdteam.pdteam_id; - cust = users.customer.customer_segment_id; + + } + let userid:any; + if(users.userid != null){ + userid = users.userid } let pdofficer = { 'fk_pd_type_id':pdtypeid, - 'fk_product_id':productid, - 'fk_customer_segment':cust, 'fk_team_id':pdteam, - 'fk_user_id':users.userid + 'fk_user_id':userid }; let records:any = { - "userid":users.userid, + "userid":userid, "aws_name": aws_name, "first_name": users.firstName, "last_name": users.lastName, "mobile_no": users.phone, "email": users.email, - "alt_email":users.altemail, - "alt_mobile_no":users.altphone, - "addressline1":users.address1, - "addressline2":users.address2, - "addressline3":users.address3, "isactive":users.isactive, - "fk_entity_id":users.type.entity_type_id, - "fk_designation":designation, + + "fk_entity_type_id":users.type.entity_type_id, + "fk_entity_id":enities, "fk_city":users.city.city_id, "fk_state":users.state.state_id, - "pincode":users.pincode, + "profilepic":profilepic, "fk_createdby":createdby, "fk_updatedby":updateby, @@ -185,7 +188,7 @@ export class UserService { }; //console.log(roles); formData.append('records',JSON.stringify(records)); - formData.append('roles',JSON.stringify(roles)); + formData.append('roles',JSON.stringify(({ "user_role": users.role.role_id}))); formData.append('profilepic',users.userpic); formData.append('pdofficer',JSON.stringify(pdofficer)); diff --git a/ng6-seed/src/app/settings/users/register/register.component.html b/ng6-seed/src/app/settings/users/register/register.component.html index 568fd7bc7..8eff3a4f4 100755 --- a/ng6-seed/src/app/settings/users/register/register.component.html +++ b/ng6-seed/src/app/settings/users/register/register.component.html @@ -11,11 +11,11 @@
- Personal

+ Personal
- + You must include a first name. Your first name must be at least 5 characters long. Your first name cannot exceed 10 characters. @@ -24,7 +24,7 @@ - + You must include a last name. + + + You must include phone number. + You must include a valid phone number. + +
- Contact Information

+ + +
- + -- {{s.name}} @@ -101,7 +106,7 @@ - + -- {{c.name}} @@ -113,7 +118,7 @@ Role Information

- -- @@ -125,13 +130,29 @@ - + + + -- + + {{ent.full_name}} + + + + + + -- + + {{ent.full_name}} + + + + - + - - {{role.GroupName}} + + {{role.role_name}}
@@ -139,33 +160,19 @@ Select User Role
- - - -- - - {{d.name}} - - - - - - -- - - {{l.lender_hierarchy}} - - - +
-
- +
- + -- {{pd.team_name}} @@ -188,7 +195,7 @@ - + -- {{PDT.type_name}} @@ -199,10 +206,17 @@
UserProfile - - - {{img}} - + +
+
+ +
+ + {{img}} +
diff --git a/ng6-seed/src/app/settings/users/register/register.component.ts b/ng6-seed/src/app/settings/users/register/register.component.ts index a2f1bf862..700b906df 100755 --- a/ng6-seed/src/app/settings/users/register/register.component.ts +++ b/ng6-seed/src/app/settings/users/register/register.component.ts @@ -9,7 +9,7 @@ import { FileUploader } from 'ng2-file-upload/ng2-file-upload'; import { MatOption } from '@angular/material'; import { UserService } from '../../service/user.service'; import { ifStmt } from '@angular/compiler/src/output/output_ast'; -const pdoff = "PDOFFICER"; +const pdoff = "PD Officer"; @Component({ selector: 'app-register', @@ -19,6 +19,10 @@ const pdoff = "PDOFFICER"; export class RegisterComponent implements OnInit { + Cities: any; + role: any; + imageaccess: boolean = false; + filename:any; roleload:boolean = false; pdTeam: any = []; customerSeg: any = []; @@ -48,6 +52,8 @@ export class RegisterComponent implements OnInit { @ViewChild('allSelected') private allSelected: MatOption; profileurl: any; profileaccess: boolean; + entitiesDetails:any; + entities:any; constructor( private router: Router, public fb: FormBuilder, public AWS: AwsService, private cd: ChangeDetectorRef ,private elementRef: ElementRef,public users:UserService) { } @@ -65,23 +71,14 @@ export class RegisterComponent implements OnInit { firstName: [null, Validators.compose([Validators.required, Validators.minLength(2)])], lastName: [null, Validators.compose([Validators.required])], phone: [null, Validators.compose([Validators.required, Validators.minLength(10), Validators.maxLength(12)])], - altphone: [null, Validators.compose([Validators.minLength(10), Validators.maxLength(12)])], email: [null, Validators.compose([Validators.required, CustomValidators.email])], - altemail: [null, Validators.compose([CustomValidators.email])], role: [null, Validators.compose([Validators.required])], type: [null, Validators.compose([Validators.required])], - address1: [null, ''], - address2: [null, ''], - address3: [null, ''], state: [null, Validators.compose([Validators.required])], city: [null, Validators.compose([Validators.required])], - designation: [null, Validators.compose([Validators.required])], + lenVenName: [null, Validators.compose([Validators.required])], userpic: [null], isactive: [true], - pincode: [null], - lenderHierarchy:[null,Validators.compose([Validators.required])], - customer:[null,Validators.compose([Validators.required])], - product:[null,Validators.compose([Validators.required])], pdteam:[null,Validators.compose([Validators.required])], pdtype:[null,Validators.compose([Validators.required])], @@ -104,12 +101,23 @@ export class RegisterComponent implements OnInit { if (this.types.status == 200) { this.types = this.types.records; //console.log(this.types); + this.regForm.controls['type'].setValue(this.types[0]); + this.users.roles().subscribe(res=>{ + console.log(res); + this.roleload = false; + //console.log(roleload); + this.role = res; + if(this.role.dataStatus == true){ + this.role = this.role.records; + this.checktype(this.types[0]); + } + }); } }); this.users.City().subscribe(res => { - this.City = res; - if (this.City.status == 200) { - this.City = this.City.records.filter(City=>City.isactive ==1); + this.Cities = res; + if (this.Cities.status == 200) { + this.Cities = this.Cities.records.filter(City=>City.isactive ==1); } }); this.users.State().subscribe(res => { @@ -118,25 +126,7 @@ export class RegisterComponent implements OnInit { this.State = this.State.records.filter(state=>state.isactive ==1); } }); - this.users.designation().subscribe(res => { - this.designation = res; - if (this.designation.status == 200) { - this.designation = this.designation.records.filter(des=>des.isactive ==1); - } - }); - this.users.lenderHierarchy().subscribe(res=>{ - this.lenderHierarchy = res; - if(this.lenderHierarchy.status ==200){ - this.lenderHierarchy = this.lenderHierarchy.records.filter(len=>len.isactive ==1); - } - }); - this.users.products().subscribe(res=>{ - this.product = res; - if(this.product.status == 200){ - this.product = this.product.records.filter(product=>product.isactive ==1); - - } - }); + this.users.pdTeam().subscribe(res=>{ this.pdTeam = res; @@ -150,26 +140,37 @@ export class RegisterComponent implements OnInit { this.pdType = this.pdType.records.filter(pdty=>pdty.isactive ==1); } }); - this.users.customerSegment().subscribe(res=>{ - this.customerSeg = res; - if(this.customerSeg.status == 200){ - this.customerSeg = this.customerSeg.records.filter(cus=>cus.isactive ==1); - console.log(this.customerSeg); + + + + this.users.entitiesDetails().subscribe(res=>{ + this.entitiesDetails = res; + if(this.entitiesDetails.dataStatus == true){ + this.entitiesDetails = this.entitiesDetails.records; } - }); - //console.log(this.State+''+this.types+''+this.City+''+this.designation); + }) } + + onFileChange($event) { //console.log($event.target.files[0]); - + this.imageaccess = true; + var reader = new FileReader(); //if($event.target.files[0] < 0 ){ this.files = $event.target.files[0]; - // console.log(this.files); - // let file = ; - console.log($event.target.result); + console.log(this.files); + + reader.onload = ($event: ProgressEvent) => { + // console.log(($event.target).result); + this.filename = ($event.target).result; + } + + reader.readAsDataURL($event.target.files[0]); //} //console.log(this.files); } + + register(userData) { // console.log(userData); let data:any; @@ -192,7 +193,9 @@ this.loader = true; this.AWS.register(userData).subscribe(res => { if (res.User.UserStatus != '' && res.User.UserStatus !== undefined && res.User.UserStatus != null) { + if(userData.role == 'System Administrator'){ this.AWS.UserGroup(res,userData).subscribe(res=>{ + });} this.users.saveRecords(res, userData).subscribe(res => { data = res; if (data.status == 200) { @@ -204,7 +207,7 @@ this.loader = true; }); } }) - }) + //}) } }); } else { @@ -221,42 +224,42 @@ this.loader = true; } } - toggleAllSelection(e) { - - if(e.source.selected){ + toggleAllSelection(e,enitiyid) { + console.log(enitiyid); + // if(e.value){ - if(e.source.value.GroupName == pdoff){ - + // if(e.value.role_name == pdoff && enitiyid.entity_type_id == 1){ + // console.log(e.value); + // this.roleAccess = true; + // }else{ + // this.roleAccess = false; + // } + // } + if (this.usersData != '' && this.usersData !==undefined || e.value.role_name == pdoff && enitiyid.entity_type_id == 1) { + console.log(e); + if(e.role_name == pdoff && enitiyid.entity_type_id == 1 || e.value.role_name == pdoff && enitiyid.entity_type_id == 1){ + this.roleAccess = true; - } - }else{ - if(e.source.value.GroupName == pdoff){ + }else{ this.roleAccess = false; } - } - - if (this.usersData != '' && this.usersData !==undefined) { - let users: any; - console.log(this.usersData); - //for (let role of this.usersData[0]) { - //this.AWS.adminremoveGroup(roles,this.usersData); - if(e.source.selected){ - this.AWS.UserGroup(e.source.value,this.usersData); - - }else{ - this.AWS.adminremoveGroup(e.source.value,this.usersData); - console.log("else"); - } - //this.AWS.adminremoveGroup() - // } + + + }else{ + this.roleAccess = false; } } getcity(e){ - // console.log(e) - // this.City =[]= this.City.filter(city=>city.fk_state == e.state_id)[0]; + console.log(e); + console.log(this.Cities); + + + this.City = this.Cities.filter(city=>city.fk_state_id == e.value.state_id); + + } userupdate() { @@ -266,70 +269,73 @@ this.loader = true; this.users.entityType().subscribe(res => { this.types = res; if (this.types.status == 200) { - let type = this.types.records; - this.types= type.filter(type => type.entity_type_id == this.usersData.fk_entity_id); - this.checktype(this.types[0]); + let type = this.types.records.filter(type=>type.isactive ==1); + this.types= type.filter(type => type.entity_type_id == this.usersData.fk_entity_type_id); + this.regForm.controls['type'].setValue(this.types[0]); + + this.users.entitiesDetails().subscribe(res=>{ + this.entitiesDetails = res; + if(this.entitiesDetails.dataStatus == true){ + this.entitiesDetails = this.entitiesDetails.records.filter(ent=>ent.isactive ==1); + let entitiy = this.entitiesDetails.filter(ent=>this.usersData.fk_entity_id == ent.entity_id)[0]; + this.regForm.controls['lenVenName'].setValue(entitiy); + this.users.roles().subscribe(res=>{ + + this.roleload = false; + //console.log(roleload); + this.role = res; + if(this.role.dataStatus == true){ + this.role = this.role.records; + this.checktype(this.types[0]); + + let role = this.role.filter(role=>role.role_type == this.usersData.fk_entity_type_id && role.role_id == this.usersData.user_role)[0]; + this.regForm.controls['role'].setValue(role); + console.log(role); + this.toggleAllSelection(role,this.types[0]); + // this.regForm.controls['role'].setValue(role); + + } + + }); + } + }) } }); - this.users.City().subscribe(res => { - this.City = res; - if (this.City.status == 200) { - this.City = this.City.records; - let citys = this.City.filter(city => city.city_id == this.usersData.fk_city)[0]; - this.regForm.controls['city'].setValue(citys); - // console.log(this.City); - } - }); + this.users.State().subscribe(res => { this.State = res; if (this.State.status == 200) { - this.State = this.State.records; + this.State = this.State.records.filter(ent=>ent.isactive ==1); let states = this.State.filter(state => state.state_id == this.usersData.fk_state)[0]; - // console.log(this.State); + console.log(states); this.regForm.controls['state'].setValue(states); + this.users.City().subscribe(res => { + this.Cities = res; + if (this.Cities.status == 200) { + //this.City = this.Cities.records; + this.Cities = this.Cities.records.filter(ent=>ent.isactive ==1); + let City = this.Cities.filter(city=>city.fk_state_id == states.state_id && city.city_id == this.usersData.fk_city)[0]; + let value = {'value':{'state_id':states.state_id}}; + this.getcity(value); + this.regForm.controls['city'].setValue(City); + // let citys = this.Cities.filter(city => city.city_id == this.usersData.fk_city)[0]; + // this.regForm.controls['city'].setValue(citys); + // console.log(this.City); + + } + }); } }); - this.users.designation().subscribe(res => { - this.designation = res; - if (this.designation.status == 200) { - this.designation = this.designation.records; - let des = this.designation.filter(des => des.designation_id == this.usersData.fk_designation)[0]; - this.regForm.controls['designation'].setValue(des); - } - }); - this.users.lenderHierarchy().subscribe(res=>{ - this.lenderHierarchy = res; - if(this.lenderHierarchy.status ==200){ - this.lenderHierarchy = this.lenderHierarchy.records; - let hie = this.lenderHierarchy.filter(hie => hie.lender_hierarchy_id == this.usersData.fk_hierarchy_id)[0]; - console.log(hie); - this.regForm.controls['lenderHierarchy'].setValue(hie); - - } - }) - - - this.users.products().subscribe(res=>{ - this.product = res; - if(this.product.status == 200){ - this.product = this.product.records; - //console.log(this.usersData.fk_product_id); - let pro = this.product.filter(pro=>pro.product_id == this.usersData.fk_product_id)[0]; - //console.log(pro); - this.regForm.controls['product'].setValue(pro); - - } - }); this.users.pdTeam().subscribe(res=>{ this.pdTeam = res; if(this.pdTeam.status == 200){ - this.pdTeam = this.pdTeam.records; + this.pdTeam = this.pdTeam.records.filter(ent=>ent.isactive ==1); let pdteam = this.pdTeam.filter(pd=>pd.pdteam_id == this.usersData.fk_team_id)[0]; this.regForm.controls['pdteam'].setValue(pdteam); } @@ -337,20 +343,12 @@ this.loader = true; this.users.pdType().subscribe(res=>{ this.pdType = res; if(this.pdType.status == 200){ - this.pdType = this.pdType.records; + this.pdType = this.pdType.records.filter(ent=>ent.isactive ==1); let pdtype = this.pdType.filter(pdt=>pdt.pd_type_id == this.usersData.fk_pd_type_id)[0]; this.regForm.controls['pdtype'].setValue(pdtype); } }); - this.users.customerSegment().subscribe(res=>{ - this.customerSeg = res; - if(this.customerSeg.status == 200){ - this.customerSeg = this.customerSeg.records; - let cust = this.customerSeg.filter(cus=>cus.customer_segment_id == this.usersData.fk_customer_segment)[0]; - this.regForm.controls['customer'].setValue(cust); - } - }); let users= { 'userid':this.usersData.userid, 'entityid':this.usersData.fk_entity_id, @@ -372,12 +370,8 @@ this.loader = true; this.regForm.controls['firstName'].setValue(this.usersData.user_first_name); this.regForm.controls['lastName'].setValue(this.usersData.user_last_name); this.regForm.controls['phone'].setValue(this.usersData.mobile_no); - this.regForm.controls['altphone'].setValue(this.usersData.alt_mobile_no); + this.regForm.controls['email'].setValue(this.usersData.email); - this.regForm.controls['altemail'].setValue(this.usersData.alt_email); - this.regForm.controls['address1'].setValue(this.usersData.addressline1); - this.regForm.controls['address2'].setValue(this.usersData.addressline2); - this.regForm.controls['address3'].setValue(this.usersData.addressline3); if (this.usersData.isactive == 1) { this.regForm.controls['isactive'].setValue(true); } else { @@ -385,31 +379,29 @@ this.loader = true; } // this.regForm.controls['userpic'].setValue(this.usersData.profilepic); - this.regForm.controls['pincode'].setValue(this.usersData.pincode); + this.img = this.usersData.profilepic; } } + + checktype(e){ - //console.log(e); - - let userRole:any = []; + console.log(e); + this.roleAccess= false; + let userRole:any; if(e !== undefined){ - this.roleload = true; + //console.log(roleload); - this.AWS.adminlistgroup(e.entity_type_id).subscribe(res=>{ - this.roleload = false; - //console.log(roleload); - this.roles = res; - if(this.usersData !==undefined){ - for (let role of this.usersData[0]) { - //console.log(role); - userRole.push(this.roles.filter(roles => roles.GroupName == role.user_role)[0]); - //console.log(userRole); - this.regForm.controls['role'].setValue(userRole); - } + + this.roles = this.role.filter(role=>role.role_type == e.entity_type_id); + console.log(this.roles); + // let role = this.roles.filter(role=>role.role_id == this.usersData.user_role_id); + // console.log(role); + // this.regForm.controls['role'].setValue(role); } + - }) + switch (e.entity_type_id) { case "1": this.typeValue =1; @@ -417,16 +409,18 @@ this.loader = true; break; case "2": this.typeValue =2; + this.entities = this.entitiesDetails.filter(entity=>entity.fk_entity_type_id == e.entity_type_id); break; case "3": this.typeValue =3; + this.entities = this.entitiesDetails.filter(entity=>entity.fk_entity_type_id == e.entity_type_id); break; default : this.typeValue = -1; break; } - } + } From b3602987c2981b9cf5b499d69990b757f462f6ec Mon Sep 17 00:00:00 2001 From: venbaSriram Date: Tue, 9 Oct 2018 19:38:55 +0530 Subject: [PATCH 03/11] users change by sriram --- ng6-seed/src/app/AwsService/aws.service.ts | 65 +++---------------- .../users/register/register.component.ts | 13 ++-- 2 files changed, 13 insertions(+), 65 deletions(-) diff --git a/ng6-seed/src/app/AwsService/aws.service.ts b/ng6-seed/src/app/AwsService/aws.service.ts index fb3c7a3a5..221bb775c 100755 --- a/ng6-seed/src/app/AwsService/aws.service.ts +++ b/ng6-seed/src/app/AwsService/aws.service.ts @@ -413,27 +413,19 @@ export class AwsService { this.getconfig(); //let cognitodata = "539bfefa-ae42-4bee-bf79-4b15d1a2af7f"; - if(userData.userid === null ){ - for(let role of userData.role){ + + let params: any; - if (userData.type.entity_type_id == 1) { + params = { - GroupName: role.GroupName /* required */, + GroupName: "ADMIN" /* required */, UserPoolId: sineedgedev_poolData.UserPoolId,//"ap-south-1_y7dt3iEaX" /* required */, Username: cognitodata.User.Username //'539bfefa-ae42-4bee-bf79-4b15d1a2af7f' /* required */ }; - } else if (userData.type.entity_type_id == 2) { - params = { - GroupName: role.GroupName /* required */, - UserPoolId: lender_poolData.UserPoolId,//"ap-south-1_y7dt3iEaX" /* required */, - Username: cognitodata.User.Username //'539bfefa-ae42-4bee-bf79-4b15d1a2af7f' /* required */ - }; - - - } + //(params); return Observable.create(observe=>{ let cognitoidentityserviceprovider = new AWS.CognitoIdentityServiceProvider(); @@ -454,50 +446,9 @@ export class AwsService { }) }); - } - }else{ - let params :any; - console.log(userData); - console.log(cognitodata); - if (userData.fk_entity_id == 1) { - - params = { - GroupName: cognitodata.GroupName /* required */, - UserPoolId: sineedgedev_poolData.UserPoolId,//"ap-south-1_y7dt3iEaX" /* required */, - Username: userData.aws_name //'539bfefa-ae42-4bee-bf79-4b15d1a2af7f' /* required */ - }; - - } else if (userData.fk_entity_id == 2) { - params = { - GroupName: cognitodata.GroupName /* required */, - UserPoolId: lender_poolData.UserPoolId,//"ap-south-1_y7dt3iEaX" /* required */, - Username: userData.aws_name //'539bfefa-ae42-4bee-bf79-4b15d1a2af7f' /* required */ - }; - - - } - //(params); - let cognitoidentityserviceprovider = new AWS.CognitoIdentityServiceProvider(); - - cognitoidentityserviceprovider.adminAddUserToGroup(params, function ( - err, - data - ) { - if (err) { - alert(err.message); - }//(err, err.stack); - // an error occurred - else {//(data); - - console.log(data); - - } - - - }); - } - - } + +} + /** diff --git a/ng6-seed/src/app/settings/users/register/register.component.ts b/ng6-seed/src/app/settings/users/register/register.component.ts index 700b906df..17e26be41 100755 --- a/ng6-seed/src/app/settings/users/register/register.component.ts +++ b/ng6-seed/src/app/settings/users/register/register.component.ts @@ -88,12 +88,6 @@ export class RegisterComponent implements OnInit { } - onSelect(e){ - // alert(); - // console.log(e) - // console.log(e.isUserInput); - // console.log(this.regForm.controls['role'].value); - } regdata() { this.users.entityType().subscribe(res => { @@ -172,7 +166,7 @@ export class RegisterComponent implements OnInit { register(userData) { - // console.log(userData); + console.log(userData); let data:any; // console.log(this.files); @@ -193,7 +187,7 @@ this.loader = true; this.AWS.register(userData).subscribe(res => { if (res.User.UserStatus != '' && res.User.UserStatus !== undefined && res.User.UserStatus != null) { - if(userData.role == 'System Administrator'){ + if(userData.role.role_id == 10){ this.AWS.UserGroup(res,userData).subscribe(res=>{ });} this.users.saveRecords(res, userData).subscribe(res => { @@ -212,6 +206,9 @@ this.loader = true; }); } else { this.AWS.adminchangeData(this.usersData,userData).subscribe(res=>{ + if(userData.role.role_id == 10){ + this.AWS.UserGroup(res,userData).subscribe(res=>{ + });} this.users.saveRecords(res,userData).subscribe(res=>{ this.loader = false; alert('Update User'); From 679e688bf4cd8020bd348baa935f0d06716229c1 Mon Sep 17 00:00:00 2001 From: dineshkumarkannan Date: Wed, 10 Oct 2018 08:58:31 +0530 Subject: [PATCH 04/11] template navigation design : kdk --- ng6-seed/src/app/template/template.routing.ts | 11 ++-- .../edit/templates.edit.component.html | 58 ++++++++++++++++++- .../edit/templates.edit.component.ts | 25 ++++++-- .../templates.list.component.html | 8 ++- .../templates.list.component.ts | 23 ++++++-- .../template/templates/templates.module.ts | 3 +- .../template/templates/templates.routing.ts | 8 ++- 7 files changed, 115 insertions(+), 21 deletions(-) diff --git a/ng6-seed/src/app/template/template.routing.ts b/ng6-seed/src/app/template/template.routing.ts index 0872de9b2..99211e44b 100644 --- a/ng6-seed/src/app/template/template.routing.ts +++ b/ng6-seed/src/app/template/template.routing.ts @@ -1,15 +1,14 @@ import { Routes } from '@angular/router'; import { QuestionsModule } from './questions/questions.module'; - +import { TemplatesModule } from './templates/templates.module'; export const TemplateRoutes: Routes = [{ path: '', children:[{ path:'questions', loadChildren:'./questions/questions.module#QuestionsModule' - }, - // { - // path:'templates', - // loadChildren:'./templates/templates.module#TemplatesModule' - // } + },{ + path:'templates', + loadChildren:'./templates/templates.module#TemplatesModule' + } ] }] diff --git a/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.html b/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.html index 57f5a2657..a2d2f3f4e 100644 --- a/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.html +++ b/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.html @@ -1,2 +1,56 @@ - -

Template Edit Component

+ +
+

{{pageTitle}}

+
+
+ +
+
+ + +
+ + + You must Include Pan Number. + +
+
+ + + + +
+ Fill out your name + + + +
+ +
+
+
+ +
+ Fill out your address + + + +
+ + +
+
+
+ + Done + You are now done. +
+ + +
+
+
+
diff --git a/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.ts b/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.ts index f9fbfe5b9..6881ca31f 100644 --- a/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.ts +++ b/ng6-seed/src/app/template/templates/templates-list/edit/templates.edit.component.ts @@ -1,9 +1,12 @@ -import { Component, ViewChild, OnInit } from '@angular/core'; +import { Component, ViewChild, OnInit, OnDestroy } from '@angular/core'; import { MatPaginator, MatSort, MatTableDataSource, MatDialog, PageEvent } from '@angular/material'; import { FormGroup, FormControl, FormBuilder } from '@angular/forms'; +import { ActivatedRoute, Router } from '@angular/router'; import { DataSource } from '@angular/cdk/table'; import { Observable } from 'rxjs/Observable'; +import { TemplateListComponent } from './../templates.list.component'; + /* * Template Edit component * : kdk @@ -12,13 +15,27 @@ import { Observable } from 'rxjs/Observable'; selector: 'app-list', templateUrl: './templates.edit.component.html' }) -export class TemplateEditComponent implements OnInit { +export class TemplateEditComponent implements OnInit, OnDestroy { + public pageTitle: string = "Edit Template"; - - constructor() { + constructor( private route: ActivatedRoute, + private router: Router, + private templateListComponent : TemplateListComponent) { } ngOnInit() { + this.templateListComponent.showListView(false); + } + + backToList(){ + this.templateListComponent.showListView(true); + this.router.navigate([ '../../' ], { relativeTo: this.route }); + } + + ngOnDestroy(): void { + //Called once, before the instance is destroyed. + //Add 'implements OnDestroy' to the class. + this.templateListComponent.showListView(true); } } diff --git a/ng6-seed/src/app/template/templates/templates-list/templates.list.component.html b/ng6-seed/src/app/template/templates/templates-list/templates.list.component.html index 44ad3e64f..efc3cdd58 100644 --- a/ng6-seed/src/app/template/templates/templates-list/templates.list.component.html +++ b/ng6-seed/src/app/template/templates/templates-list/templates.list.component.html @@ -1,7 +1,11 @@
-

Template List Component

+ + + + +
-
+
\ No newline at end of file diff --git a/ng6-seed/src/app/template/templates/templates-list/templates.list.component.ts b/ng6-seed/src/app/template/templates/templates-list/templates.list.component.ts index 0c9bdd767..6062bc415 100644 --- a/ng6-seed/src/app/template/templates/templates-list/templates.list.component.ts +++ b/ng6-seed/src/app/template/templates/templates-list/templates.list.component.ts @@ -1,5 +1,6 @@ -import { Component, ViewChild, OnInit } from '@angular/core'; +import { Component, ViewChild, OnInit, OnDestroy } from '@angular/core'; import { MatPaginator, MatSort, MatTableDataSource, MatDialog, PageEvent } from '@angular/material'; +import { ActivatedRoute, Router } from '@angular/router'; import { FormGroup, FormControl, FormBuilder } from '@angular/forms'; import { DataSource } from '@angular/cdk/table'; import { Observable } from 'rxjs/Observable'; @@ -12,21 +13,35 @@ import { Observable } from 'rxjs/Observable'; selector: 'app-list', templateUrl: './templates.list.component.html' }) -export class TemplateListComponent implements OnInit { +export class TemplateListComponent implements OnInit, OnDestroy { public listView: boolean = true; - constructor() { + public names: string; + constructor( + private route: ActivatedRoute, + private router: Router) { + // this.names = 'dinesh'; } ngOnInit() { // alert(1); + alert(); + this.listView = true; } goToEdit(){ + this.router.navigate([ '../list/edit', '1' ], { relativeTo: this.route }); this.listView = false; } - ngAfterViewInit(){ + showListView(status: boolean){ // alert(2); + this.listView = status; + } + + ngOnDestroy(): void { + //Called once, before the instance is destroyed. + //Add 'implements OnDestroy' to the class. + alert(); } } diff --git a/ng6-seed/src/app/template/templates/templates.module.ts b/ng6-seed/src/app/template/templates/templates.module.ts index 2da2ac707..f7ca24067 100644 --- a/ng6-seed/src/app/template/templates/templates.module.ts +++ b/ng6-seed/src/app/template/templates/templates.module.ts @@ -12,7 +12,7 @@ import { MatProgressBarModule,MatDialogModule, MatSortModule, MatToolbarModule,MatSelectModule, MatListModule, MatMenuModule, - MatCheckboxModule + MatCheckboxModule, MatStepperModule } from '@angular/material'; import {MatSlideToggleModule} from '@angular/material/slide-toggle'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; @@ -86,6 +86,7 @@ const customNotifierOptions: NotifierOptions = { MatButtonModule,MatTableModule,MatPaginatorModule, MatProgressBarModule,MatDialogModule, MatSortModule, MatToolbarModule,MatSelectModule,MatListModule, MatMenuModule, + MatStepperModule, MatSlideToggleModule, MatCheckboxModule, FormsModule, diff --git a/ng6-seed/src/app/template/templates/templates.routing.ts b/ng6-seed/src/app/template/templates/templates.routing.ts index 6afa2b2f0..2a3003665 100644 --- a/ng6-seed/src/app/template/templates/templates.routing.ts +++ b/ng6-seed/src/app/template/templates/templates.routing.ts @@ -13,11 +13,15 @@ const routes: Routes = [ path: 'templates', component: TemplatesComponent, children: [ - { + { + path: '', + pathMatch: 'full', + redirectTo: 'list' + },{ path: 'list', component: TemplateListComponent, children: [{ - path: 'edit', + path: 'edit/:question-id', component: TemplateEditComponent, }] } From 2ab01dcbed586004e1b1a1076030f9d331e67682 Mon Sep 17 00:00:00 2001 From: "venbatechnologies@gmail.com" Date: Wed, 10 Oct 2018 10:46:51 +0530 Subject: [PATCH 05/11] pd team master new menu creation : ps --- .../company-details.module.spec.ts | 13 ++ .../company-details/company-details.module.ts | 10 ++ .../company-details.routing.ts | 12 ++ .../branch-list/branch-list.component.html | 119 ++++++------- .../city/city-list/city-list.component.html | 11 +- .../comments-on-locality-list.component.html | 12 +- .../pd-notification-list.component.html | 2 +- .../pd-notification-list.component.ts | 14 +- .../pd-team-list/pd-team-list.component.html | 149 ----------------- .../pd-team-list/pd-team-list.component.ts | 156 ------------------ .../uom/uom-list/uom-list.component.html | 90 +--------- .../settings/masters/masters.component.html | 2 +- .../app/settings/masters/masters.module.ts | 7 +- .../pd-team-add/pd-team-add.component.html | 70 ++++++++ .../pd-team-add/pd-team-add.component.scss | 0 .../pd-team-add/pd-team-add.component.spec.ts | 25 +++ .../pd-team-add/pd-team-add.component.ts | 147 +++++++++++++++++ .../pd-team-dialog.component.html | 24 ++- .../pd-team-dialog.component.scss | 0 .../pd-team-dialog.component.spec.ts | 0 .../pd-team-dialog.component.ts | 28 +++- .../pd-team-edit/pd-team-edit.component.html | 3 + .../pd-team-edit/pd-team-edit.component.scss | 0 .../pd-team-edit.component.spec.ts | 25 +++ .../pd-team-edit/pd-team-edit.component.ts | 15 ++ .../pd-team-list/pd-team-list.component.html | 85 ++++++++++ .../pd-team-list/pd-team-list.component.scss | 36 +--- .../pd-team-list.component.spec.ts | 0 .../pd-team-list/pd-team-list.component.ts | 104 ++++++++++++ .../settings/pd-team/pd-team.module.spec.ts | 13 ++ .../app/settings/pd-team/pd-team.module.ts | 111 +++++++++++++ .../app/settings/pd-team/pd-team.routing.ts | 21 +++ .../service/masters/masters.service.ts | 1 + .../service/masters/pd-team.service.ts | 17 +- ng6-seed/src/app/settings/settings.module.ts | 7 +- ng6-seed/src/app/settings/settings.routing.ts | 9 +- .../src/app/shared/menu-items/menu-items.ts | 1 + 37 files changed, 800 insertions(+), 539 deletions(-) create mode 100644 ng6-seed/src/app/settings/company-details/company-details.module.spec.ts create mode 100644 ng6-seed/src/app/settings/company-details/company-details.module.ts create mode 100755 ng6-seed/src/app/settings/company-details/company-details.routing.ts delete mode 100644 ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.html delete mode 100644 ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.scss create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.spec.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-dialog/pd-team-dialog.component.html (92%) rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-dialog/pd-team-dialog.component.scss (100%) rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-dialog/pd-team-dialog.component.spec.ts (100%) rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-dialog/pd-team-dialog.component.ts (93%) create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.scss create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.spec.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.html rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-list/pd-team-list.component.scss (62%) rename ng6-seed/src/app/settings/{masters/component => }/pd-team/pd-team-list/pd-team-list.component.spec.ts (100%) create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team.module.spec.ts create mode 100644 ng6-seed/src/app/settings/pd-team/pd-team.module.ts create mode 100755 ng6-seed/src/app/settings/pd-team/pd-team.routing.ts diff --git a/ng6-seed/src/app/settings/company-details/company-details.module.spec.ts b/ng6-seed/src/app/settings/company-details/company-details.module.spec.ts new file mode 100644 index 000000000..db014c808 --- /dev/null +++ b/ng6-seed/src/app/settings/company-details/company-details.module.spec.ts @@ -0,0 +1,13 @@ +import { CompanyDetailsModule } from './company-details.module'; + +describe('CompanyDetailsModule', () => { + let companyDetailsModule: CompanyDetailsModule; + + beforeEach(() => { + companyDetailsModule = new CompanyDetailsModule(); + }); + + it('should create an instance', () => { + expect(companyDetailsModule).toBeTruthy(); + }); +}); diff --git a/ng6-seed/src/app/settings/company-details/company-details.module.ts b/ng6-seed/src/app/settings/company-details/company-details.module.ts new file mode 100644 index 000000000..1c7bfd8aa --- /dev/null +++ b/ng6-seed/src/app/settings/company-details/company-details.module.ts @@ -0,0 +1,10 @@ +import { NgModule } from '@angular/core'; +import { CommonModule } from '@angular/common'; + +@NgModule({ + imports: [ + CommonModule + ], + declarations: [] +}) +export class CompanyDetailsModule { } diff --git a/ng6-seed/src/app/settings/company-details/company-details.routing.ts b/ng6-seed/src/app/settings/company-details/company-details.routing.ts new file mode 100755 index 000000000..acac68aca --- /dev/null +++ b/ng6-seed/src/app/settings/company-details/company-details.routing.ts @@ -0,0 +1,12 @@ +import { Routes } from '@angular/router'; +//import { MastersComponent } from './masters.component'; + + +export const CompanyDetailsRoutes: Routes = [ +{ + + //path: '', + //component: PdTeamListComponent + //component: IndustryMasterListComponent + +}]; diff --git a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html index 07d63f9c1..41aef2ea3 100644 --- a/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/branch/branch-list/branch-list.component.html @@ -1,79 +1,80 @@ -
+
-
-
- - - -
-
- -
-
+
+
+ + + +
+ +
+ +
+
- - - - Sl - {{row.serialno}} - + + + + Sl + {{row.serialno}} + - - Branch Name - {{row.name}} - + + Branch Name + {{row.name}} + - - City Name - {{row.city_name}} - + + City Name + {{row.city_name}} + - - Actions - - - - - + + Actions + + + + + - - Is Active - - - - - - + + Is Active + + + + + + - - + + - - - - - - + + + + + +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/city/city-list/city-list.component.html b/ng6-seed/src/app/settings/masters/component/city/city-list/city-list.component.html index 1653f558a..3d4975b76 100644 --- a/ng6-seed/src/app/settings/masters/component/city/city-list/city-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/city/city-list/city-list.component.html @@ -69,7 +69,7 @@
--> -
+
-
+
+
@@ -91,7 +92,7 @@ - + Sl @@ -160,11 +161,11 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/comments-on-locality/comments-on-locality-list/comments-on-locality-list.component.html b/ng6-seed/src/app/settings/masters/component/comments-on-locality/comments-on-locality-list/comments-on-locality-list.component.html index 55a916d08..2b024c19c 100644 --- a/ng6-seed/src/app/settings/masters/component/comments-on-locality/comments-on-locality-list/comments-on-locality-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/comments-on-locality/comments-on-locality-list/comments-on-locality-list.component.html @@ -63,18 +63,19 @@
--> -
+
-
+
+
@@ -85,7 +86,7 @@ - + Sl @@ -139,9 +140,8 @@ - +
- - + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.html b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.html index b30935485..0f5bbdbe5 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.html @@ -27,7 +27,7 @@ Sl - {{i+1}} + {{row.serialno}} diff --git a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts index 5cca5ffec..11be83104 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts +++ b/ng6-seed/src/app/settings/masters/component/pd-notification/pd-notification-list.component.ts @@ -128,12 +128,12 @@ export class PdNotificationListComponent implements OnInit { }); //console.log(this.notificationData); this.dataLength = data.records.length; - // if(data.records.length >= 1){ - // this.notificationData = this.notificationData.map((val, i)=>{ - // val['serialno'] = i + 1; - // return val; - // }) - // } + if(data.records.length >= 1){ + this.notificationData = this.notificationData.map((val, i)=>{ + val['serialno'] = i + 1; + return val; + }) + } this.dataSource.data = this.notificationData; }else{ this.noRecordFound = true; @@ -193,7 +193,7 @@ SaveData(dataSource){ dataresult => { if(dataresult.dataStatus == true){ //alert('Updated Successfully !'); - this.getPdNotification(); + //this.getPdNotification(); this.notifier.notify('success', 'Record Updated Successfully.!'); }else{ diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.html b/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.html deleted file mode 100644 index cbef78bdc..000000000 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.html +++ /dev/null @@ -1,149 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- - - -
-
- -
-
- - - - - - - Sl - {{row.serialno}} - - - - PD Team Name - {{row.team_name}} - - - - - - Is Active - - - - - - - - - - - - Actions - - - - - - - - - - - - - -
- - -
- \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts b/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts deleted file mode 100644 index 98a1e9063..000000000 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.ts +++ /dev/null @@ -1,156 +0,0 @@ -import { Component, - OnInit, - ViewChild } from '@angular/core'; - -import { MatDialog, - MatDialogRef, - MatDialogConfig, - MatPaginator, - MatSort, -MatTableDataSource } from '@angular/material'; -/** Service */ -import { MastersService } from '../../../../service/masters/masters.service'; -import { PdTeamService } from '../../../../service/masters/pd-team.service'; -import { NotifierService } from 'angular-notifier'; - -/** Dialog Component */ -import { PdTeamDialogComponent } from '../pd-team-dialog/pd-team-dialog.component'; - - -@Component({ - selector: 'app-pd-team-list', - templateUrl: './pd-team-list.component.html', - styleUrls: ['./pd-team-list.component.scss'] -}) -export class PdTeamListComponent implements OnInit { - - //Variable Declaration part - isPopupOpened: boolean = true; - loader: boolean = false; - PdTeamList: any = []; - color = 'primary'; - userData = null; - noRecordFound: boolean = false; - private notifier: NotifierService; - - - public dataLength: number; - public dataSource = new MatTableDataSource(); - displayedColumns = ['serialno','team_name','actions', 'isactive']; - - @ViewChild(MatPaginator) paginator: MatPaginator; - @ViewChild(MatSort) sort: MatSort; - - constructor(private dialog: MatDialog, notifier: NotifierService, - private _MasterService: MastersService, - private _PdTeamService: PdTeamService) { - this.getPdTeam(); - this.notifier = notifier; - } - - ngOnInit() {} - - //To open dialog for add the data - addPdTeam() { - this.isPopupOpened = true; - const dialogRef = this.dialog.open(PdTeamDialogComponent, { - data: {} - }); - - dialogRef.afterClosed().subscribe(result => { - this.getPdTeam(); - this.isPopupOpened = false; - }); - } - - //To open dialog for edit the data - editPdTeam(arr: any[]) { - // let a:any; - // if(arr.length !=0){ - // a = arr; - // }else{ - // a =''; - // } - // console.log(a); - this.isPopupOpened = true; - const dialogRef = this.dialog.open(PdTeamDialogComponent, { - - data: arr - }); - - dialogRef.afterClosed().subscribe(result => { - this.getPdTeam(); - this.isPopupOpened = false; - }); - } - - //To get data for listing - getPdTeam() { - - //this.loader = true; - this._PdTeamService.getAllPdTeamList().subscribe( - //this._MasterService.getAllMasterData('PDTEAM').subscribe( - data => { - if(data.dataStatus == true){ - //this.loader = false; - this.noRecordFound = false; - this.userData = data.records; - this.dataLength = data.records.length; - if(data.records.length >= 1){ - this.userData = this.userData.map((val, i)=>{ - val['serialno'] = i + 1; - return val; - }) - } - this.dataSource.data = this.userData; - }else{ - this.noRecordFound = true; - this.dataLength = 0 - } - }) -} - - //To inactive the data - deletePdTeam(id: number) { - var PrimaryKeyWithValue ={'pdteam_id':id}; - this._MasterService.deleteMasterDetails(PrimaryKeyWithValue,'PDTEAM') - .subscribe( data => { }); - this.getPdTeam(); - - } - - /** For Changing Active States., which means both Changing Active And Inactive alternatively */ - isactivePdTeam(id: number,isactive : number) { - - let ActiveDatas = isactive == 0 - ? { 'pdteam_id':id,'isactive': '1'} - : { 'pdteam_id':id,'isactive': '0'} - - this._MasterService.editMasterDetails(ActiveDatas,'PDTEAM') - .subscribe(dataresult=>{ - if (dataresult.dataStatus == true){ - //alert("my check"); - this.getPdTeam(); - } - else{ - //alert("SomeThing Wents Wrong Try Again !"); - this.notifier.notify('warning', 'SomeThing Wents Wrong Try Again !'); - } - }); -} - -/** For Display Tables Pagination And Sorting */ -ngAfterViewInit() { - this.dataSource.paginator = this.paginator; - this.dataSource.sort = this.sort; -} - -/** For Display Tables Filtering */ -applyFilter(filterValue: string) { - filterValue = filterValue.trim(); // Remove whitespace - filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches - this.dataSource.filter = filterValue; -} - -} -/** End of ListComponent */ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/uom/uom-list/uom-list.component.html b/ng6-seed/src/app/settings/masters/component/uom/uom-list/uom-list.component.html index e51108937..7846b4bba 100644 --- a/ng6-seed/src/app/settings/masters/component/uom/uom-list/uom-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/uom/uom-list/uom-list.component.html @@ -1,94 +1,18 @@ - - - - - - -
+ +
-
+
+
@@ -97,7 +21,7 @@ - + Sl @@ -146,9 +70,9 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/masters.component.html b/ng6-seed/src/app/settings/masters/masters.component.html index 633362bec..d4432748c 100644 --- a/ng6-seed/src/app/settings/masters/masters.component.html +++ b/ng6-seed/src/app/settings/masters/masters.component.html @@ -93,7 +93,7 @@ - +
diff --git a/ng6-seed/src/app/settings/masters/masters.module.ts b/ng6-seed/src/app/settings/masters/masters.module.ts index b4ae6b935..3690e9add 100644 --- a/ng6-seed/src/app/settings/masters/masters.module.ts +++ b/ng6-seed/src/app/settings/masters/masters.module.ts @@ -55,7 +55,7 @@ import { PdLocationApproachListComponent } from './component/pd-location-approac import { PdTypeListComponent } from './component/pd-type/pd-type-list/pd-type-list.component'; import { LenderHierarchyListComponent } from './component/lender-hierarchy/lender-hierarchy-list/lender-hierarchy-list.component'; import { QuestionCategoryListComponent } from './component/question-category/question-category-list/question-category-list.component'; -import { PdTeamDialogComponent } from './component/pd-team/pd-team-dialog/pd-team-dialog.component'; +//import { PdTeamDialogComponent } from './component/pd-team/pd-team-dialog/pd-team-dialog.component'; /** Master Child Component - For Dialogboxes*/ @@ -82,7 +82,7 @@ import { CityDialogComponent } from './component/city/city-dialog/city-dialog.co import { RegionsDialogComponent } from './component/regions/regions-dialog/regions-dialog.component'; import { QuestionCategoryDialogComponent } from './component/question-category/question-category-dialog/question-category-dialog.component'; import { PdNotificationListComponent } from './component/pd-notification/pd-notification-list.component'; -import { PdTeamListComponent } from './component/pd-team/pd-team-list/pd-team-list.component'; +//import { PdTeamListComponent } from './component/pd-team/pd-team-list/pd-team-list.component'; /** Master Routes */ @@ -208,8 +208,6 @@ const customNotifierOptions: NotifierOptions = { CompanyDialogComponent, CityDialogComponent, RegionsDialogComponent, - PdTeamDialogComponent, - PdTeamListComponent, QuestionCategoryDialogComponent, QuestionCategoryListComponent ], @@ -238,7 +236,6 @@ const customNotifierOptions: NotifierOptions = { CompanyDialogComponent, CityDialogComponent, RegionsDialogComponent, - PdTeamDialogComponent, QuestionCategoryDialogComponent ], diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html new file mode 100644 index 000000000..7d3a80b2c --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html @@ -0,0 +1,70 @@ +
+
+ +
+

PD TEAM

+
+
+ +
+
+ +
Team Details


+
+ + + You must Include Team Name. + + + + + {{ ld.short_name }} {{ ld.full_name }} + + You must Select Lender Name. + +
+ +
Cities Coverd


+
+ + + {{ cd.name }} + + You must Select Cities. + + + +
+ +
Products


+
+ + + {{ pd.name }} + + You must Select Product. + +
+ +
Customers Segment


+
+ + + + {{csd.name}} + + You must Select Customer Segment. + +
+ +
+ + +
+
+
+
+ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.scss b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.scss new file mode 100644 index 000000000..e69de29bb diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.spec.ts b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.spec.ts new file mode 100644 index 000000000..782f6d074 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.spec.ts @@ -0,0 +1,25 @@ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { PdTeamAddComponent } from './pd-team-add.component'; + +describe('PdTeamAddComponent', () => { + let component: PdTeamAddComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ PdTeamAddComponent ] + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(PdTeamAddComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts new file mode 100644 index 000000000..c2f3c43fc --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts @@ -0,0 +1,147 @@ +import { Component, OnInit, Inject } from '@angular/core'; +import { FormBuilder, + FormGroup, + Validators, + FormControl } from '@angular/forms'; + import { MatDialog, + MatDialogRef, + MAT_DIALOG_DATA } from '@angular/material'; + /** Service */ + import { MastersService } from '../../service/masters/masters.service'; + import { PdTeamService } from '../../service/masters/pd-team.service'; + import { NotifierService } from 'angular-notifier'; +import { PdTeamDialogComponent } from '../pd-team-dialog/pd-team-dialog.component'; +import { Router } from '@angular/router'; + +@Component({ + selector: 'app-pd-team-add', + templateUrl: './pd-team-add.component.html', + styleUrls: ['./pd-team-add.component.scss'] +}) +export class PdTeamAddComponent implements OnInit { + +public _pdTeamForm: FormGroup; +public submitted = false; + +citydatas: any[]; +lenderdatas: any[]; +productdatas: any[]; +customerSegmentdatas: any[]; + +pdTeamCityArray: Array<{teamid: number, cityid: number}> = []; +pdTeamProductArray: Array<{teamid: number, productid: number}> = []; +pdTeamCustomerSegmentArray: Array<{teamid: number, customerid: number}> = []; + +color = 'primary'; +errorMessage:string; + +constructor(private _formBuilder: FormBuilder, + private _notifier: NotifierService, + private _pdTeamService: PdTeamService, + private _router: Router, + private _masterService: MastersService) + { + this._notifier = _notifier; + } + + +ngOnInit() { +this.PdTeamFormDatas(); + +/** To Display The City Data For City DropDown */ +this._masterService.getAllMasterData('CITY').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.citydatas = dataresult.records; + this.citydatas = this.citydatas.filter(city=>city.isactive == 1 ); + } + + }, error => this.errorMessage = error); + +/** To Display The Entities Data For Entities DropDown */ +this._masterService.getAllMasterData('ENTITY').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.lenderdatas = dataresult.records; + this.lenderdatas = this.lenderdatas.filter(entity=>entity.isactive == 1 ); + } + }, error => this.errorMessage = error); + +/** To Display The Entities Data For Entities DropDown */ +this._masterService.getAllMasterData('PRODUCTS').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.productdatas = dataresult.records; + this.productdatas = this.productdatas.filter(product=>product.isactive == 1 ); + } + }, error => this.errorMessage = error); + +/** To Display The Entities Data For Entities DropDown */ +this._masterService.getAllMasterData('CUSTOMERSEGMENT').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.customerSegmentdatas = dataresult.records; + this.customerSegmentdatas = this.customerSegmentdatas.filter(segment=>segment.isactive == 1 ); + } + }, error => this.errorMessage = error); +} + +/** Pd Team Form Datas */ +PdTeamFormDatas(){ +this._pdTeamForm = this._formBuilder.group({ + pdteam_id: [null, Validators.compose([Validators.required])], + team_name: [null, Validators.compose([Validators.required])], + fk_lender: [null, Validators.compose([Validators.required])], + fk_city: [null, Validators.compose([Validators.required])], + fk_customer_segment: [null, Validators.compose([Validators.required])], + fk_product:[null, Validators.compose([Validators.required])], + +}); + +} + +/** convenience getter for easy access to form fields */ +get f() { return this._pdTeamForm.controls; } + +/** For Popup Close Button */ +onNoClick(): void { + this._router.navigate(['/setting/pdteam/pdteamlist']); +} + +/** To Save/Edited Popup Data */ +onSubmit() { + this.submitted = true; + alert("onsubmit function"); + console.log(this._pdTeamForm.value); + + var pdTeamFormValues = this._pdTeamForm.value; + + Object.keys(pdTeamFormValues).forEach( + (key) => ( pdTeamFormValues[key] == null) && delete pdTeamFormValues[key]); + + this._pdTeamService.addPdTeamDetail(this._pdTeamForm.value).subscribe( + dataresult=>{ + + if(dataresult.dataStatus == true){ + alert('Saved'); + } + else{ + alert('Not Saved'); + } + + }); + +} + +/** To Reset Popup Data For Add*/ + +onResetForAdd(){ +alert("reset function"); +} +toggleAllSelection($event){ + console.log($event); + let srcarray = $event['source'] + console.log(srcarray._mostRecentViewValue); +} +} +/** End Of Pd Dialog Component */ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.html similarity index 92% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.html rename to ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.html index 5ffd4161b..b1a63ac70 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.html +++ b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.html @@ -36,14 +36,13 @@ You must Pick Up the City Name.
- -
+ - + - + @@ -53,26 +52,22 @@ + - + - - + + -
S.noS.no Lender Name City NameActionAction
{{i+PDTeamMaplen+1}}{{PM.lenderid.full_name}} {{PM.cityid.name}}
- - -
- -
+

@@ -87,4 +82,5 @@
- \ No newline at end of file + + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.scss b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.scss similarity index 100% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.scss rename to ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.scss diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.spec.ts b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.spec.ts similarity index 100% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.spec.ts rename to ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.spec.ts diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.ts similarity index 93% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.ts rename to ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.ts index ab11dd8a8..6a01db192 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-dialog/pd-team-dialog.component.ts +++ b/ng6-seed/src/app/settings/pd-team/pd-team-dialog/pd-team-dialog.component.ts @@ -9,8 +9,8 @@ import { MatDialog, MatDialogRef, MAT_DIALOG_DATA } from '@angular/material'; /** Service */ -import { MastersService } from '../../../../service/masters/masters.service'; -import { PdTeamService } from '../../../../service/masters/pd-team.service'; +import { MastersService } from '../../service/masters/masters.service'; +import { PdTeamService } from '../../service/masters/pd-team.service'; import { NotifierService } from 'angular-notifier'; @Component({ @@ -115,10 +115,13 @@ isactivePDTeamChild(id: number,isactive : number) { this._masterService.editMasterDetails(ActiveDatas,'PDTEAMMAP') .subscribe(dataresult=>{ if (dataresult.dataStatus == true){ - alert("Successfully InActive !"); + //alert("Successfully InActive !"); + this.notifier.notify('success', 'Record Successfully InActive.!'); } else{ - alert("SomeThing Wents Wrong Try Again !"); + + //alert("SomeThing Wents Wrong Try Again !"); + this.notifier.notify('warning', 'Sorry Try Again !'); } }); } @@ -171,7 +174,8 @@ if((this._pdTeamForm.controls['fk_city_id'].value.city_id != '') (item.lenderid['entity_id'] == this._pdTeamForm.controls['fk_lender_id'].value.entity_id)) { check++; - alert('Already Exists'); + //alert(''); + this.notifier.notify('info', 'Already Exists.!'); } }); @@ -183,7 +187,9 @@ if((this._pdTeamForm.controls['fk_city_id'].value.city_id != '') (item.fk_lender_id == this._pdTeamForm.controls['fk_lender_id'].value.entity_id)) { check++; - alert('Already Exists on Other Team "'+item.team_name+'"'); + //this.notifier.notify('success', 'Already Exists.!'); + //alert('Already Exists on Other Team "'+item.team_name+'"'); + this.notifier.notify( 'info', 'Already Exists on Other Team'+item.team_name ); } } }); @@ -198,7 +204,9 @@ if((this._pdTeamForm.controls['fk_city_id'].value.city_id != '') (item.fk_lender_id == this._pdTeamForm.controls['fk_lender_id'].value.entity_id)) { check++; - alert('Already Exists'); + //alert('Already Exists'); + this.notifier.notify( 'info', 'Already Exists'); + } }); } @@ -256,6 +264,7 @@ if(isNaN(this.data.pdteam_id)) { //console.log(pdTeamFormValues); //To Remove The "Null" With Key Object.keys(pdTeamFormValues).forEach( + //getAllPdTeam(); (key) => ( pdTeamFormValues[key] == null) && delete pdTeamFormValues[key] && delete pdTeamFormValues['fk_lender_id'] && delete pdTeamFormValues['fk_city_id']); @@ -272,10 +281,11 @@ if (dataresult.dataStatus == true){ this.dialogRef.close(); //Need To Dispaly saving Datas // alert("Data Saved Successfully"); - this.notifier.notify('success', 'Record Saved Successfully.!'); + this.notifier.notify('success', 'Record Saved Successfully.!'); } else{ - alert("SomeThing Wents Wrong Try Again !"); + //alert(""); + this.notifier.notify('warning', 'SomeThing Wents Wrong Try Again !'); } }); diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html new file mode 100644 index 000000000..5c2225a56 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html @@ -0,0 +1,3 @@ +

+ pd-team-edit works! +

diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.scss b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.scss new file mode 100644 index 000000000..e69de29bb diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.spec.ts b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.spec.ts new file mode 100644 index 000000000..7bd983178 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.spec.ts @@ -0,0 +1,25 @@ +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; + +import { PdTeamEditComponent } from './pd-team-edit.component'; + +describe('PdTeamEditComponent', () => { + let component: PdTeamEditComponent; + let fixture: ComponentFixture; + + beforeEach(async(() => { + TestBed.configureTestingModule({ + declarations: [ PdTeamEditComponent ] + }) + .compileComponents(); + })); + + beforeEach(() => { + fixture = TestBed.createComponent(PdTeamEditComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts new file mode 100644 index 000000000..5dae7698b --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts @@ -0,0 +1,15 @@ +import { Component, OnInit } from '@angular/core'; + +@Component({ + selector: 'app-pd-team-edit', + templateUrl: './pd-team-edit.component.html', + styleUrls: ['./pd-team-edit.component.scss'] +}) +export class PdTeamEditComponent implements OnInit { + + constructor() { } + + ngOnInit() { + } + +} diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.html new file mode 100644 index 000000000..80bb14541 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.html @@ -0,0 +1,85 @@ + +
+
+ PD Team Masters +
+
+ + + +
+
+
+ + + +
+ +
+ +
+
+ + + + + + + Sl + {{row.serialno}} + + + + PD Team Name + {{row.team_name}} + + + + Lender Name + {{row.lender_name}} + + + + Is Active + + + + + + + + + + + + Actions + + + + + + + + + + + + + +
+ + +
+ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.scss b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.scss similarity index 62% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.scss rename to ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.scss index dcc8578ca..723622401 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.scss +++ b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.scss @@ -1,35 +1,7 @@ - -// .example-container { -// display: flex; -// flex-direction: column; -// min-width: 300px; -// } - -// .example-header { -// min-height: 64px; -// padding: 8px 24px 0; -// } - -// .mat-form-field { -// font-size: 14px; -// width: 100%; -// } - -// .mat-table { -// overflow: auto; -// max-height: 500px; -// } - -// .nocontent { -// color: red; -// font-size: 16px; -// text-align: center; -// } - -// .example-margin { -// margin: 10px; -// } - +/** Card title */ +.mat-card-title{ + font-size: 25px !important; +} /** Table SerialNo CSS */ .example-margin { diff --git a/ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.spec.ts b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.spec.ts similarity index 100% rename from ng6-seed/src/app/settings/masters/component/pd-team/pd-team-list/pd-team-list.component.spec.ts rename to ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.spec.ts diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.ts new file mode 100644 index 000000000..892b0e2f7 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team-list/pd-team-list.component.ts @@ -0,0 +1,104 @@ +import { Component, + OnInit, + ViewChild } from '@angular/core'; +import { Router } from '@angular/router'; +import { MatSort, + MatPaginator, +MatTableDataSource } from '@angular/material'; +/** Service */ +import { MastersService } from '../../service/masters/masters.service'; +import { PdTeamService } from '../../service/masters/pd-team.service'; + +import { NotifierService } from 'angular-notifier'; + +/** Dialog Component */ +import { PdTeamDialogComponent } from '../pd-team-dialog/pd-team-dialog.component'; +/** Add Component */ +//import { } from '../pd-team-add/pd-team-add.component; +/** Edit Component */ +//import { } from '../pd-team-add/pd-team-add.component; + + +@Component({ + selector: 'app-pd-team-list', + templateUrl: './pd-team-list.component.html', + styleUrls: ['./pd-team-list.component.scss'] +}) +export class PdTeamListComponent implements OnInit { + + //Variable Declaration part + isPopupOpened: boolean = true; + loader: boolean = false; + PdTeamList: any = []; + color = 'primary'; + userData = null; + noRecordFound: boolean = false; + private notifier: NotifierService; + + public dataLength: number; + public dataSource = new MatTableDataSource(); + displayedColumns = ['serialno','team_name','lender_name','actions','isactive']; + + @ViewChild(MatPaginator) paginator: MatPaginator; + @ViewChild(MatSort) sort: MatSort; + + constructor(notifier: NotifierService, + private router: Router, + private _MasterService: MastersService, + private _PdTeamService: PdTeamService) { + this.getPdTeam(); + this.notifier = notifier; + } + + ngOnInit() {} + + /** To add data */ + addPdTeam() { + this.router.navigate(['/setting/pdteam/addpdteam']); + } + + /** To edit data */ + editPdTeam() { + this.router.navigate(['/setting/pdteam/editpdteam']); + } + + /** To get data for listing */ + getPdTeam() { + + this._PdTeamService.getAllPdTeam().subscribe( + data => { + //console.log('data',data); + if(data.dataStatus == true){ + + this.noRecordFound = false; + this.userData = data.records; + this.dataLength = data.records.length; + if(data.records.length >= 1){ + this.userData = this.userData.map((val, i)=>{ + val['serialno'] = i + 1; + return val; + }) + } + this.dataSource.data = this.userData; + }else{ + this.noRecordFound = true; + this.dataLength = 0 + } + }) +} + + /** For Display Tables Pagination And Sorting */ + ngAfterViewInit() { + this.dataSource.paginator = this.paginator; + this.dataSource.sort = this.sort; + } + + /** For Display Tables Filtering */ + applyFilter(filterValue: string) { + filterValue = filterValue.trim(); // Remove whitespace + filterValue = filterValue.toLowerCase(); // Datasource defaults to lowercase matches + this.dataSource.filter = filterValue; + } + +} +/** End of ListComponent */ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/pd-team/pd-team.module.spec.ts b/ng6-seed/src/app/settings/pd-team/pd-team.module.spec.ts new file mode 100644 index 000000000..9bb68af94 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team.module.spec.ts @@ -0,0 +1,13 @@ +import { PdTeamModule } from './pd-team.module'; + +describe('PdTeamModule', () => { + let pdTeamModule: PdTeamModule; + + beforeEach(() => { + pdTeamModule = new PdTeamModule(); + }); + + it('should create an instance', () => { + expect(pdTeamModule).toBeTruthy(); + }); +}); diff --git a/ng6-seed/src/app/settings/pd-team/pd-team.module.ts b/ng6-seed/src/app/settings/pd-team/pd-team.module.ts new file mode 100644 index 000000000..c17d54794 --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team.module.ts @@ -0,0 +1,111 @@ +import { NgModule } from '@angular/core'; +import { RouterModule } from '@angular/router'; +import { CommonModule } from '@angular/common'; +import { + MatCardModule, + MatIconModule, + MatInputModule, + MatRadioModule, + MatButtonModule, + MatSelectModule, + MatDialogModule, + MatProgressBarModule,MatToolbarModule,MatCheckboxModule, + MatTableModule,MatPaginatorModule,MatSortModule} from '@angular/material'; + import {MatSlideToggleModule} from '@angular/material/slide-toggle'; + +import { MatTooltipModule } from '@angular/material/tooltip'; +import { FormsModule, ReactiveFormsModule } from '@angular/forms'; +import { NgxMatSelectSearchModule } from 'ngx-mat-select-search'; +import { NgxDatatableModule } from '@swimlane/ngx-datatable'; +import { NotifierModule, NotifierOptions } from 'angular-notifier'; +import { FlexLayoutModule } from '@angular/flex-layout'; + +import { PdTeamDialogComponent } from './pd-team-dialog/pd-team-dialog.component'; +import { PdTeamListComponent } from './pd-team-list/pd-team-list.component'; + +/** Route */ +import { PdTeamRoutes } from './pd-team.routing'; + +/** Service */ +import { PdTeamService } from '../service/masters/pd-team.service'; +import { PdTeamAddComponent } from './pd-team-add/pd-team-add.component'; +import { PdTeamEditComponent } from './pd-team-edit/pd-team-edit.component'; + +/** + * Custom angular notifier options + */ +const customNotifierOptions: NotifierOptions = { + position: { + horizontal: { + position: 'right', + distance: 12 + }, + vertical: { + position: 'top', + distance: 32, + gap: 10 + } + }, + theme: 'material', + behaviour: { + autoHide: 5000, + onClick: 'hide', + onMouseover: 'pauseAutoHide', + showDismissButton: true, + stacking: 4 + }, + animations: { + enabled: true, + show: { + preset: 'slide', + speed: 300, + easing: 'ease' + }, + hide: { + preset: 'fade', + speed: 300, + easing: 'ease', + offset: 50 + }, + shift: { + speed: 300, + easing: 'ease' + }, + overlap: 150 + } +}; + +@NgModule({ + imports: [ + CommonModule, + FormsModule, ReactiveFormsModule, + RouterModule.forChild(PdTeamRoutes), + MatCardModule, + MatIconModule, + MatInputModule, + MatRadioModule, + MatButtonModule, + MatTableModule, + MatPaginatorModule, + MatProgressBarModule, + MatDialogModule, + MatSortModule, + MatToolbarModule, + MatSelectModule, + FlexLayoutModule, + NgxMatSelectSearchModule, + NgxDatatableModule, + MatSortModule, + MatSlideToggleModule, + MatTooltipModule, + NotifierModule.withConfig(customNotifierOptions), + ], + declarations: [PdTeamDialogComponent, + PdTeamListComponent, + PdTeamAddComponent, + PdTeamEditComponent], + + providers: [PdTeamService ], + entryComponents: [PdTeamDialogComponent] +}) +export class PdTeamModule { } diff --git a/ng6-seed/src/app/settings/pd-team/pd-team.routing.ts b/ng6-seed/src/app/settings/pd-team/pd-team.routing.ts new file mode 100755 index 000000000..e792e720a --- /dev/null +++ b/ng6-seed/src/app/settings/pd-team/pd-team.routing.ts @@ -0,0 +1,21 @@ +import { Routes } from '@angular/router'; +import { PdTeamAddComponent } from '../pd-team/pd-team-add/pd-team-add.component'; +import { PdTeamEditComponent } from '../pd-team/pd-team-edit/pd-team-edit.component'; +import { PdTeamListComponent } from '../pd-team/pd-team-list/pd-team-list.component'; + + +export const PdTeamRoutes: Routes = [{ + + path: '', + children: [{ + path: 'pdteamlist', + component: PdTeamListComponent + },{ + path: 'addpdteam', + component: PdTeamAddComponent + },{ + path:'editpdteam', + component:PdTeamEditComponent + }] +}]; + diff --git a/ng6-seed/src/app/settings/service/masters/masters.service.ts b/ng6-seed/src/app/settings/service/masters/masters.service.ts index e8a381e1e..3015d8376 100644 --- a/ng6-seed/src/app/settings/service/masters/masters.service.ts +++ b/ng6-seed/src/app/settings/service/masters/masters.service.ts @@ -299,6 +299,7 @@ editPDAllocationType(Records: any,MasterName:string): Observable { item.fk_updatedby = this._aws.getlocale();//to get user id for who is update the record item.updatedon = currentdate;//to get Current date and Time for when the Record is updated delete item.pd_status_name; // to delete the pd_status_name + delete item.serialno; }); //console.log('Service Data',Records); diff --git a/ng6-seed/src/app/settings/service/masters/pd-team.service.ts b/ng6-seed/src/app/settings/service/masters/pd-team.service.ts index 3fdf1d120..d2a4dbc68 100644 --- a/ng6-seed/src/app/settings/service/masters/pd-team.service.ts +++ b/ng6-seed/src/app/settings/service/masters/pd-team.service.ts @@ -23,8 +23,8 @@ export interface Master { export class PdTeamService { -private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; -//private apiUrl = "http://localhost/sparqapi/api/"; +//private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; +private apiUrl = "http://localhost/sparqapi/api/"; constructor(private _http: HttpClient, @@ -37,7 +37,7 @@ private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; * 1st argument is "Records": any - Set of Data To Adding to database */ addPdTeamDetail(Records: any): Observable { - + console.log('From Service Data',Records); Records.fk_createdby = this._aws.getlocale();//to get user id for who is created the Record Records.createdon = currentdate;//to get Current date and Time for when the Record is created // Records.fk_updatedby = this._aws.getlocale();//to get user id for who is update the record @@ -189,4 +189,15 @@ return this._http.post(this.apiUrl+"savePDTeam", ArrayData) }; } + /** + * + */ +getAllPdTeam(): Observable { + return this._http.get(this.apiUrl+'getListOfPDTeam') + .pipe( + catchError(this.handleError('role', [])) + ) + +} + } \ No newline at end of file diff --git a/ng6-seed/src/app/settings/settings.module.ts b/ng6-seed/src/app/settings/settings.module.ts index 14ffb9cdc..1278c61a9 100644 --- a/ng6-seed/src/app/settings/settings.module.ts +++ b/ng6-seed/src/app/settings/settings.module.ts @@ -26,11 +26,9 @@ import { RouterModule } from '@angular/router'; import { SettingsRoutes } from './settings.routing'; import { RegisterComponent } from '../session/register/register.component'; import { UserService } from './service/user.service'; + import { MastersModule } from './masters/masters.module'; -// import { EntityModule } from './entity/entity.module'; -// import { AddEntityComponent } from './entity/add-entity/add-entity.component'; -// import { EditEntityComponent } from './entity/edit-entity/edit-entity.component'; -// import { EntityListComponent } from './entity/entity-list/entity-list.component'; +import { PdTeamModule } from './pd-team/pd-team.module'; import { EntityModule } from './entity/entity.module'; // import { HttpClientModule } from '@angular/common/http'; @@ -39,6 +37,7 @@ import { EntityModule } from './entity/entity.module'; CommonModule, RouterModule.forChild(SettingsRoutes),MatCardModule, MastersModule, + PdTeamModule, EntityModule, MatIconModule, MatInputModule, diff --git a/ng6-seed/src/app/settings/settings.routing.ts b/ng6-seed/src/app/settings/settings.routing.ts index eb410c394..4ec51d0ea 100644 --- a/ng6-seed/src/app/settings/settings.routing.ts +++ b/ng6-seed/src/app/settings/settings.routing.ts @@ -1,6 +1,6 @@ import { Routes } from '@angular/router'; import { MastersModule } from './masters/masters.module'; - +import { PdTeamModule } from './pd-team/pd-team.module'; import { EntityModule } from './entity/entity.module'; //import { EntityModule } from './entity/entity.module'; @@ -16,10 +16,9 @@ export const SettingsRoutes: Routes = [{ },{ path:'entity', loadChildren:'./entity/entity.module#EntityModule' + },{ + path:'pdteam', + loadChildren:'./pd-team/pd-team.module#PdTeamModule' } - // { - // path:'entitymodule', - // loadChildren:'./entity/entity.module#EntityModule' - // } ] }] \ No newline at end of file diff --git a/ng6-seed/src/app/shared/menu-items/menu-items.ts b/ng6-seed/src/app/shared/menu-items/menu-items.ts index 8ab9b85f3..55f03f401 100644 --- a/ng6-seed/src/app/shared/menu-items/menu-items.ts +++ b/ng6-seed/src/app/shared/menu-items/menu-items.ts @@ -53,6 +53,7 @@ const MENUITEMS : Menu[] = [ {state:'users',name:'Users'}, {state:'mastermodule',name:'Master Details'}, {state:'entity',name:'Entities'}, + {state:'pdteamlist',name:'PD Team'}, ], From c155ddb133d1382e246b5ae6fb3b504a88a93c63 Mon Sep 17 00:00:00 2001 From: "venbatechnologies@gmail.com" Date: Wed, 10 Oct 2018 16:22:38 +0530 Subject: [PATCH 06/11] master cahnges and pd Team changes : ps --- .../customer-behaviour-list.component.html | 14 +- .../customer-segment-list.component.html | 10 +- .../designation-list.component.html | 11 +- .../frequency-list.component.html | 11 +- ...ndustry_classification-list.component.html | 11 +- .../lender-hierarchy-list.component.html | 11 +- .../members-occupation-list.component.html | 11 +- .../pd-location-approach-list.component.html | 11 +- .../pd-type-list/pd-type-list.component.html | 11 +- .../product-list/product-list.component.html | 12 +- .../question-category-list.component.html | 9 +- .../regions-list/regions-list.component.html | 107 ++------- .../relation-ship-list.component.html | 11 +- .../states-list/states-list.component.html | 11 +- .../sub-product-list.component.html | 18 +- .../title-list/title-list.component.html | 11 +- .../activity-list.component.html | 11 +- .../pd-team-add/pd-team-add.component.html | 30 ++- .../pd-team-add/pd-team-add.component.ts | 112 +++++++--- .../pd-team-edit/pd-team-edit.component.html | 89 +++++++- .../pd-team-edit/pd-team-edit.component.ts | 204 +++++++++++++++++- 21 files changed, 501 insertions(+), 225 deletions(-) diff --git a/ng6-seed/src/app/settings/masters/component/customer-behaviour/customer-behaviour-list/customer-behaviour-list.component.html b/ng6-seed/src/app/settings/masters/component/customer-behaviour/customer-behaviour-list/customer-behaviour-list.component.html index 94659c65d..136c52c61 100644 --- a/ng6-seed/src/app/settings/masters/component/customer-behaviour/customer-behaviour-list/customer-behaviour-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/customer-behaviour/customer-behaviour-list/customer-behaviour-list.component.html @@ -63,7 +63,7 @@

--> -
+
-
+
+
- - +
- + Sl @@ -140,9 +140,9 @@ - +
- + diff --git a/ng6-seed/src/app/settings/masters/component/customer-segment/customer-segment-list/customer-segment-list.component.html b/ng6-seed/src/app/settings/masters/component/customer-segment/customer-segment-list/customer-segment-list.component.html index 3e3666663..00a5fbb45 100644 --- a/ng6-seed/src/app/settings/masters/component/customer-segment/customer-segment-list/customer-segment-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/customer-segment/customer-segment-list/customer-segment-list.component.html @@ -67,25 +67,26 @@
--> -
+
-
+
+
- + Sl @@ -136,9 +137,8 @@ - +
- \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/designation/designation-list/designation-list.component.html b/ng6-seed/src/app/settings/masters/component/designation/designation-list/designation-list.component.html index f92d574fc..ff86fe450 100644 --- a/ng6-seed/src/app/settings/masters/component/designation/designation-list/designation-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/designation/designation-list/designation-list.component.html @@ -67,18 +67,19 @@

--> -
+
-
+
+
@@ -87,7 +88,7 @@ - + Sl @@ -135,11 +136,9 @@ - +
- - diff --git a/ng6-seed/src/app/settings/masters/component/frequency/frequency-list/frequency-list.component.html b/ng6-seed/src/app/settings/masters/component/frequency/frequency-list/frequency-list.component.html index daf5161f5..2fae291cd 100644 --- a/ng6-seed/src/app/settings/masters/component/frequency/frequency-list/frequency-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/frequency/frequency-list/frequency-list.component.html @@ -76,18 +76,19 @@

--> -
+
-
+
+
@@ -96,7 +97,7 @@ - + Sl @@ -142,9 +143,9 @@ - +
- + diff --git a/ng6-seed/src/app/settings/masters/component/industry_classification/industry_classification-list/industry_classification-list.component.html b/ng6-seed/src/app/settings/masters/component/industry_classification/industry_classification-list/industry_classification-list.component.html index c97c287c6..13476f697 100644 --- a/ng6-seed/src/app/settings/masters/component/industry_classification/industry_classification-list/industry_classification-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/industry_classification/industry_classification-list/industry_classification-list.component.html @@ -7,7 +7,7 @@ -
+
-
+
+
- + Sl @@ -72,12 +73,12 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/lender-hierarchy/lender-hierarchy-list/lender-hierarchy-list.component.html b/ng6-seed/src/app/settings/masters/component/lender-hierarchy/lender-hierarchy-list/lender-hierarchy-list.component.html index 26e1142b1..20748da3f 100644 --- a/ng6-seed/src/app/settings/masters/component/lender-hierarchy/lender-hierarchy-list/lender-hierarchy-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/lender-hierarchy/lender-hierarchy-list/lender-hierarchy-list.component.html @@ -62,18 +62,19 @@
--> -
+
-
+
+
@@ -81,7 +82,7 @@
- + Sl @@ -132,10 +133,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/members-occupation/members-occupation-list/members-occupation-list.component.html b/ng6-seed/src/app/settings/masters/component/members-occupation/members-occupation-list/members-occupation-list.component.html index 99937af69..cb51c0c42 100644 --- a/ng6-seed/src/app/settings/masters/component/members-occupation/members-occupation-list/members-occupation-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/members-occupation/members-occupation-list/members-occupation-list.component.html @@ -80,18 +80,19 @@

--> -
+
-
+
+
@@ -100,7 +101,7 @@ - + Sl @@ -150,9 +151,9 @@ - +
- + diff --git a/ng6-seed/src/app/settings/masters/component/pd-location-approach/pd-location-approach-list/pd-location-approach-list.component.html b/ng6-seed/src/app/settings/masters/component/pd-location-approach/pd-location-approach-list/pd-location-approach-list.component.html index b942c7527..dde60b4af 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-location-approach/pd-location-approach-list/pd-location-approach-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/pd-location-approach/pd-location-approach-list/pd-location-approach-list.component.html @@ -63,25 +63,26 @@

--> -
+
-
+
+
- + Sl @@ -129,9 +130,9 @@ - +
- + diff --git a/ng6-seed/src/app/settings/masters/component/pd-type/pd-type-list/pd-type-list.component.html b/ng6-seed/src/app/settings/masters/component/pd-type/pd-type-list/pd-type-list.component.html index 2207eeb89..86299fe02 100644 --- a/ng6-seed/src/app/settings/masters/component/pd-type/pd-type-list/pd-type-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/pd-type/pd-type-list/pd-type-list.component.html @@ -61,18 +61,19 @@
-
+
-
+
+
@@ -81,7 +82,7 @@
- + Sl @@ -129,9 +130,9 @@ - +
- + diff --git a/ng6-seed/src/app/settings/masters/component/product/product-list/product-list.component.html b/ng6-seed/src/app/settings/masters/component/product/product-list/product-list.component.html index adf9da364..0ae762158 100644 --- a/ng6-seed/src/app/settings/masters/component/product/product-list/product-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/product/product-list/product-list.component.html @@ -8,7 +8,7 @@

--> -
+
-
+
-
+
- + Sl @@ -82,9 +82,9 @@ - +
- + -
+
-
+
+
- + Sl @@ -73,7 +74,7 @@ - +
diff --git a/ng6-seed/src/app/settings/masters/component/regions/regions-list/regions-list.component.html b/ng6-seed/src/app/settings/masters/component/regions/regions-list/regions-list.component.html index ac665e0a7..cd7239a84 100644 --- a/ng6-seed/src/app/settings/masters/component/regions/regions-list/regions-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/regions/regions-list/regions-list.component.html @@ -1,92 +1,19 @@ - - - - - - - -
- + +
-
+
-
-
- - -
+
+ +
+ +
- +
- - + Sl @@ -97,13 +24,10 @@ Region Name {{row.name}} - Is Active - Actions - + - - - -
- - - + +
\ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html b/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html index 7e67fd576..ffcc12601 100644 --- a/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html @@ -82,18 +82,19 @@

--> -
+
-
+
+
@@ -103,7 +104,7 @@ - + Sl @@ -152,10 +153,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/states/states-list/states-list.component.html b/ng6-seed/src/app/settings/masters/component/states/states-list/states-list.component.html index 8645bbeee..c252f5ba4 100644 --- a/ng6-seed/src/app/settings/masters/component/states/states-list/states-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/states/states-list/states-list.component.html @@ -102,18 +102,19 @@

--> -
+
-
+
+
@@ -122,7 +123,7 @@ - + Sl @@ -175,10 +176,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/sub-product/sub-product-list/sub-product-list.component.html b/ng6-seed/src/app/settings/masters/component/sub-product/sub-product-list/sub-product-list.component.html index c359ea303..e8a483667 100644 --- a/ng6-seed/src/app/settings/masters/component/sub-product/sub-product-list/sub-product-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/sub-product/sub-product-list/sub-product-list.component.html @@ -1,9 +1,9 @@ -
+ -
-
+
-
+
-
+
-
+
@@ -112,7 +112,7 @@ - + Sl @@ -165,10 +165,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/title/title-list/title-list.component.html b/ng6-seed/src/app/settings/masters/component/title/title-list/title-list.component.html index af8fbf74c..b40fde58c 100644 --- a/ng6-seed/src/app/settings/masters/component/title/title-list/title-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/title/title-list/title-list.component.html @@ -79,18 +79,19 @@
-->
-
+
-
+
+
@@ -100,7 +101,7 @@ - + Sl @@ -148,10 +149,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/masters/component/type-of-activity/activity-list/activity-list.component.html b/ng6-seed/src/app/settings/masters/component/type-of-activity/activity-list/activity-list.component.html index 351c2e113..ac386e22a 100644 --- a/ng6-seed/src/app/settings/masters/component/type-of-activity/activity-list/activity-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/type-of-activity/activity-list/activity-list.component.html @@ -75,18 +75,19 @@
--> -
+
-
+
+
@@ -94,7 +95,7 @@ - + Sl @@ -142,10 +143,10 @@ - +
- + \ No newline at end of file diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html index 7d3a80b2c..be23374a8 100644 --- a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html +++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.html @@ -28,14 +28,18 @@
- {{ cd.name }} + {{ cd.name }} You must Select Cities. - + +
The Selected Cities are.,
+
    +
  • {{data}}
  • +
+
+ +
@@ -43,10 +47,16 @@
- {{ pd.name }} + {{ pd.name }} You must Select Product. + +
The Selected Products are.,
+
    +
  • {{data}}
  • +
+
Customers Segment


@@ -54,10 +64,16 @@ - {{csd.name}} + {{csd.name}} You must Select Customer Segment. + +
The Selected Customer segment are.,
+
    +
  • {{data}}
  • +
+
diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts index c2f3c43fc..74b53b844 100644 --- a/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts +++ b/ng6-seed/src/app/settings/pd-team/pd-team-add/pd-team-add.component.ts @@ -4,8 +4,8 @@ import { FormBuilder, Validators, FormControl } from '@angular/forms'; import { MatDialog, - MatDialogRef, - MAT_DIALOG_DATA } from '@angular/material'; + MatDialogRef, + MAT_DIALOG_DATA } from '@angular/material'; /** Service */ import { MastersService } from '../../service/masters/masters.service'; import { PdTeamService } from '../../service/masters/pd-team.service'; @@ -22,18 +22,24 @@ export class PdTeamAddComponent implements OnInit { public _pdTeamForm: FormGroup; public submitted = false; +color = 'primary'; +errorMessage:string; +//This Type Of Array Declaration for select dropdown to list the datas citydatas: any[]; lenderdatas: any[]; productdatas: any[]; customerSegmentdatas: any[]; +//This Type Of Array Declaration pdTeamCityArray: Array<{teamid: number, cityid: number}> = []; pdTeamProductArray: Array<{teamid: number, productid: number}> = []; pdTeamCustomerSegmentArray: Array<{teamid: number, customerid: number}> = []; -color = 'primary'; -errorMessage:string; +//This Type Of Array Declaration for Local Purpose and List the data in html page +selectedCityDatas : any=[]; +selectedProductDatas : any=[]; +selectedSegmentDatas : any=[]; constructor(private _formBuilder: FormBuilder, private _notifier: NotifierService, @@ -111,37 +117,87 @@ onNoClick(): void { /** To Save/Edited Popup Data */ onSubmit() { this.submitted = true; - alert("onsubmit function"); - console.log(this._pdTeamForm.value); - - var pdTeamFormValues = this._pdTeamForm.value; - - Object.keys(pdTeamFormValues).forEach( - (key) => ( pdTeamFormValues[key] == null) && delete pdTeamFormValues[key]); - - this._pdTeamService.addPdTeamDetail(this._pdTeamForm.value).subscribe( - dataresult=>{ - - if(dataresult.dataStatus == true){ - alert('Saved'); - } - else{ - alert('Not Saved'); - } - - }); + // stop here if form is invalid + if (this._pdTeamForm.invalid) { + // this.errorMessage = "Please Fill All Mandate Fields."; + // return; + alert('Please Fill All Mandate Fields.'); + } else { + var pdTeamFormValues = this._pdTeamForm.value; + + //To Remove The "Null" With Key also + Object.keys(pdTeamFormValues).forEach( + (key) => ( pdTeamFormValues[key] == null) && delete pdTeamFormValues[key]); + + this._pdTeamService.addPdTeamDetail(this._pdTeamForm.value).subscribe( + dataresult => { + if (dataresult.status == 200) { + console.log(dataresult); + this._notifier.notify('success', 'Record Edited Successfully.!'); +// alert('Record Successfully.!'); + this._router.navigate(['/setting/pdteam/pdteamlist']); + this._pdTeamForm.reset(); + } + else { + this._notifier.notify('warning', 'Something Wents Wrong Try Again.!'); + //alert('Some Thing Wents Wrong Try Again !'); + //this.errorMessage = "Some Thing Wents Wrong Try Again !"; + } + }, error => { + this._notifier.notify('warning', 'Something Wents Wrong Try Again.!'); + // this.errorMessage = "Something Wents Wrong Try Again !"; + //alert('Some Thing Wents Wrong Try Again !'); + }); + } } + /** To Reset Popup Data For Add*/ onResetForAdd(){ alert("reset function"); } -toggleAllSelection($event){ - console.log($event); - let srcarray = $event['source'] - console.log(srcarray._mostRecentViewValue); + +/**on change function for customer segment to dispaly the as List in html page */ +onChangeCustomerSegmentDatas($event){ + let CustomerSegmentName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedSegmentDatas.push(CustomerSegmentName); + } + else if($event.source._selected === false ){ + let index = this.selectedSegmentDatas.indexOf(CustomerSegmentName); + this.selectedSegmentDatas.splice(index,1); + } } + +/**on change function for City to display the as List in html page */ +onChangeCityDatas($event){ + + let cityName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedCityDatas.push(cityName); + } + else if($event.source._selected === false ){ + let index = this.selectedCityDatas.indexOf(cityName); + this.selectedCityDatas.splice(index,1); + } + } -/** End Of Pd Dialog Component */ \ No newline at end of file + +/**on change function for Product to display the data as List in html page */ +onChangeProductDatas($event){ + + let productName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedProductDatas.push(productName); + } + else if($event.source._selected === false ){ + let index = this.selectedProductDatas.indexOf(productName); + this.selectedProductDatas.splice(index,1); + } + +} + +} +/** End Of PD TEAM ADD Component */ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html index 5c2225a56..be23374a8 100644 --- a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html +++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.html @@ -1,3 +1,86 @@ -

- pd-team-edit works! -

+
+
+ +
+

PD TEAM

+
+
+ +
+
+ +
Team Details


+
+ + + You must Include Team Name. + + + + + {{ ld.short_name }} {{ ld.full_name }} + + You must Select Lender Name. + +
+ +
Cities Coverd


+
+ + + {{ cd.name }} + + You must Select Cities. + + +
The Selected Cities are.,
+
    +
  • {{data}}
  • +
+
+ + + +
+ +
Products


+
+ + + {{ pd.name }} + + You must Select Product. + + +
The Selected Products are.,
+
    +
  • {{data}}
  • +
+
+
+ +
Customers Segment


+
+ + + + {{csd.name}} + + You must Select Customer Segment. + + +
The Selected Customer segment are.,
+
    +
  • {{data}}
  • +
+
+
+ +
+ + +
+
+
+
+ \ No newline at end of file diff --git a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts index 5dae7698b..2bb0fa976 100644 --- a/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts +++ b/ng6-seed/src/app/settings/pd-team/pd-team-edit/pd-team-edit.component.ts @@ -1,15 +1,207 @@ -import { Component, OnInit } from '@angular/core'; +import { Component, OnInit, Inject } from '@angular/core'; + +import { FormBuilder, + FormGroup, + Validators, + FormControl } from '@angular/forms'; +import { MatDialog, + MatDialogRef, + MAT_DIALOG_DATA } from '@angular/material'; + +/** Service */ +import { MastersService } from '../../service/masters/masters.service'; +import { PdTeamService } from '../../service/masters/pd-team.service'; +import { NotifierService } from 'angular-notifier'; +import { PdTeamDialogComponent } from '../pd-team-dialog/pd-team-dialog.component'; +import { Router } from '@angular/router'; + @Component({ selector: 'app-pd-team-edit', templateUrl: './pd-team-edit.component.html', styleUrls: ['./pd-team-edit.component.scss'] }) export class PdTeamEditComponent implements OnInit { - - constructor() { } - + + public _pdTeamForm: FormGroup; + public submitted = false; + color = 'primary'; + errorMessage:string; + + //This Type Of Array Declaration for select dropdown to list the datas + citydatas: any[]; + lenderdatas: any[]; + productdatas: any[]; + customerSegmentdatas: any[]; + + //This Type Of Array Declaration + pdTeamCityArray: Array<{teamid: number, cityid: number}> = []; + pdTeamProductArray: Array<{teamid: number, productid: number}> = []; + pdTeamCustomerSegmentArray: Array<{teamid: number, customerid: number}> = []; + + //This Type Of Array Declaration for Local Purpose and List the data in html page + selectedCityDatas : any=[]; + selectedProductDatas : any=[]; + selectedSegmentDatas : any=[]; + + constructor(private _formBuilder: FormBuilder, + private _notifier: NotifierService, + private _pdTeamService: PdTeamService, + private _router: Router, + private _masterService: MastersService) + { + this._notifier = _notifier; + } + + ngOnInit() { + this.PdTeamFormDatas(); + + /** To Display The City Data For City DropDown */ + this._masterService.getAllMasterData('CITY').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.citydatas = dataresult.records; + this.citydatas = this.citydatas.filter(city=>city.isactive == 1 ); + } + + }, error => this.errorMessage = error); + + /** To Display The Entities Data For Entities DropDown */ + this._masterService.getAllMasterData('ENTITY').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.lenderdatas = dataresult.records; + this.lenderdatas = this.lenderdatas.filter(entity=>entity.isactive == 1 ); + } + }, error => this.errorMessage = error); + + /** To Display The Entities Data For Entities DropDown */ + this._masterService.getAllMasterData('PRODUCTS').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.productdatas = dataresult.records; + this.productdatas = this.productdatas.filter(product=>product.isactive == 1 ); + } + }, error => this.errorMessage = error); + + /** To Display The Entities Data For Entities DropDown */ + this._masterService.getAllMasterData('CUSTOMERSEGMENT').subscribe( + dataresult => { + if (dataresult.status == 200) { + this.customerSegmentdatas = dataresult.records; + this.customerSegmentdatas = this.customerSegmentdatas.filter(segment=>segment.isactive == 1 ); + } + }, error => this.errorMessage = error); } - -} + + /** Pd Team Form Datas */ + PdTeamFormDatas(){ + this._pdTeamForm = this._formBuilder.group({ + pdteam_id: [null, Validators.compose([Validators.required])], + team_name: [null, Validators.compose([Validators.required])], + fk_lender: [null, Validators.compose([Validators.required])], + fk_city: [null, Validators.compose([Validators.required])], + fk_customer_segment: [null, Validators.compose([Validators.required])], + fk_product:[null, Validators.compose([Validators.required])], + + }); + + } + + /** convenience getter for easy access to form fields */ + get f() { return this._pdTeamForm.controls; } + + /** For Popup Close Button */ + onNoClick(): void { + this._router.navigate(['/setting/pdteam/pdteamlist']); + } + + /** To Save/Edited Popup Data */ + /** To Save/Edited Popup Data */ + onSubmit() { + this.submitted = true; + // stop here if form is invalid + if (this._pdTeamForm.invalid) { + // this.errorMessage = "Please Fill All Mandate Fields."; + // return; + alert('Please Fill All Mandate Fields.'); + } else { + + var pdTeamFormValues = this._pdTeamForm.value; + + //To Remove The "Null" With Key also + Object.keys(pdTeamFormValues).forEach( + (key) => ( pdTeamFormValues[key] == null) && delete pdTeamFormValues[key]); + + this._pdTeamService.addPdTeamDetail(this._pdTeamForm.value).subscribe( + dataresult => { + if (dataresult.status == 200) { + console.log(dataresult); + // this._notifier.notify('success', 'Record Saved Successfully.!'); + alert('Record Saved Successfully.!'); + this._router.navigate(['/setting/pdteam/pdteamlist']); + this._pdTeamForm.reset(); + } + else { + //this._notifier.notify('warning', 'Something Wents Wrong Try Again.!'); + alert('Some Thing Wents Wrong Try Again !'); + //this.errorMessage = "Some Thing Wents Wrong Try Again !"; + } + }, error => { + // this._notifier.notify('warning', 'Something Wents Wrong Try Again.!'); + // this.errorMessage = "Something Wents Wrong Try Again !"; + alert('Some Thing Wents Wrong Try Again !'); + }); + } + } + + + /** To Reset Popup Data For Add*/ + + onResetForAdd(){ + alert("reset function"); + } + + /**on change function for customer segment to dispaly the as List in html page */ + onChangeCustomerSegmentDatas($event){ + let CustomerSegmentName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedSegmentDatas.push(CustomerSegmentName); + } + else if($event.source._selected === false ){ + let index = this.selectedSegmentDatas.indexOf(CustomerSegmentName); + this.selectedSegmentDatas.splice(index,1); + } + } + + /**on change function for City to display the as List in html page */ + onChangeCityDatas($event){ + + let cityName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedCityDatas.push(cityName); + } + else if($event.source._selected === false ){ + let index = this.selectedCityDatas.indexOf(cityName); + this.selectedCityDatas.splice(index,1); + } + + } + + /**on change function for Product to display the data as List in html page */ + onChangeProductDatas($event){ + + let productName = $event.source.value.name; + if($event.source._selected === true ){ + this.selectedProductDatas.push(productName); + } + else if($event.source._selected === false ){ + let index = this.selectedProductDatas.indexOf(productName); + this.selectedProductDatas.splice(index,1); + } + + } + + } + /** End Of PD TEAM ADD Component */ \ No newline at end of file From afe65ee36ab33b6ed4d71ada6c54ef8739a0ecff Mon Sep 17 00:00:00 2001 From: saravana kumar kandasami Date: Wed, 10 Oct 2018 11:37:23 +0000 Subject: [PATCH 07/11] _main-sidebar.scss edited online with Bitbucket --- ng6-seed/src/assets/styles/scss/core/_main-sidebar.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ng6-seed/src/assets/styles/scss/core/_main-sidebar.scss b/ng6-seed/src/assets/styles/scss/core/_main-sidebar.scss index bed7bdf91..46d4e3064 100644 --- a/ng6-seed/src/assets/styles/scss/core/_main-sidebar.scss +++ b/ng6-seed/src/assets/styles/scss/core/_main-sidebar.scss @@ -480,7 +480,7 @@ .sidebar-red { .sidebar-panel { .bg-overlay { - background: rgba(244, 67, 54, 0.8)!important; + background: rgb(227, 31, 38)!important; } } } From b626b02e182465b522189dd6495c5639576a56d5 Mon Sep 17 00:00:00 2001 From: saravana kumar kandasami Date: Wed, 10 Oct 2018 11:38:15 +0000 Subject: [PATCH 08/11] admin-layout.component.ts edited online with Bitbucket --- ng6-seed/src/app/layouts/admin/admin-layout.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ng6-seed/src/app/layouts/admin/admin-layout.component.ts b/ng6-seed/src/app/layouts/admin/admin-layout.component.ts index 0cb4c1b9c..2dc3b1ea5 100644 --- a/ng6-seed/src/app/layouts/admin/admin-layout.component.ts +++ b/ng6-seed/src/app/layouts/admin/admin-layout.component.ts @@ -37,7 +37,7 @@ export class AdminLayoutComponent implements OnInit, OnDestroy { layoutDir = 'ltr'; menuLayout : any = 'vertical-menu'; selectedSidebarImage : any = 'bg-1'; - selectedSidebarColor : any = 'sidebar-blue'; + selectedSidebarColor : any = 'sidebar-red'; selectedHeaderColor : any = 'header-default'; collapsedClass : any = 'side-panel-opened'; From f93d385ff336a442c23960f5db1a7922f080b968 Mon Sep 17 00:00:00 2001 From: saravana kumar kandasami Date: Wed, 10 Oct 2018 11:39:43 +0000 Subject: [PATCH 09/11] index.html edited online with Bitbucket --- ng6-seed/src/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ng6-seed/src/index.html b/ng6-seed/src/index.html index 9ac4d4685..3a317457e 100644 --- a/ng6-seed/src/index.html +++ b/ng6-seed/src/index.html @@ -45,7 +45,7 @@ .sk-cube-grid .sk-cube { width: 33%; height: 33%; - background: #673ab7; + background: rgb(227, 31, 38); float: left; -webkit-animation: sk-cubeGridScaleDelay 1.3s infinite ease-in-out; animation: sk-cubeGridScaleDelay 1.3s infinite ease-in-out; From 522bbaa30d948f4d94e34f854d29e0e8592751e5 Mon Sep 17 00:00:00 2001 From: saravana kumar kandasami Date: Wed, 10 Oct 2018 11:52:30 +0000 Subject: [PATCH 10/11] relation-ship-list.component.html edited online with Bitbucket --- .../relation-ship-list/relation-ship-list.component.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html b/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html index ffcc12601..74b2b10e0 100644 --- a/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html +++ b/ng6-seed/src/app/settings/masters/component/relation-ship/relation-ship-list/relation-ship-list.component.html @@ -112,7 +112,7 @@ - Relation Ship Name + Relationship Name {{row.name}} From 1f26c532748badfc5883c47f2b99c0d186502b68 Mon Sep 17 00:00:00 2001 From: saravana kumar kandasami Date: Wed, 10 Oct 2018 12:02:01 +0000 Subject: [PATCH 11/11] admin-layout.component.html edited online with Bitbucket --- ng6-seed/src/app/layouts/admin/admin-layout.component.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ng6-seed/src/app/layouts/admin/admin-layout.component.html b/ng6-seed/src/app/layouts/admin/admin-layout.component.html index 9e0e227f6..e21724eaa 100644 --- a/ng6-seed/src/app/layouts/admin/admin-layout.component.html +++ b/ng6-seed/src/app/layouts/admin/admin-layout.component.html @@ -398,10 +398,10 @@ - -