Url Setup
This commit is contained in:
parent
3404c8d538
commit
9791d6390c
@ -194,7 +194,13 @@ unavailability(action,obj) {
|
|||||||
console.log( this.practitionerdetails)
|
console.log( this.practitionerdetails)
|
||||||
this._con.getPractitionerInfo.next( this.usersList['practitionerInfos']);
|
this._con.getPractitionerInfo.next( this.usersList['practitionerInfos']);
|
||||||
console.log(this.practitionerdetails)
|
console.log(this.practitionerdetails)
|
||||||
this.endUserURL = this.end_User_Url+this.usersList['BusinessDetails'][0].randStr
|
|
||||||
|
if(this.userRole == 'PRACTITIONER'){
|
||||||
|
this.endUserURL = this.end_User_Url+'practitioner/'+this.usersList.randStr
|
||||||
|
} else if (this.userRole == 'BADMIN'){
|
||||||
|
this.endUserURL = this.end_User_Url+'business/'+this.usersList['BusinessDetails'][0].randStr
|
||||||
|
}
|
||||||
|
|
||||||
this.workinghours = JSON.parse(this.practitionerdetails.workingHours)
|
this.workinghours = JSON.parse(this.practitionerdetails.workingHours)
|
||||||
this.skills= JSON.parse(this.practitionerdetails.skills)
|
this.skills= JSON.parse(this.practitionerdetails.skills)
|
||||||
this.id=this.practitionerdetails.id
|
this.id=this.practitionerdetails.id
|
||||||
@ -356,7 +362,7 @@ unavailability(action,obj) {
|
|||||||
save(){
|
save(){
|
||||||
this.isEditable = false;
|
this.isEditable = false;
|
||||||
let userid = localStorage.getItem('user_id')
|
let userid = localStorage.getItem('user_id')
|
||||||
let param: any = { "exp": this.exp,
|
let param: any = { "exp": this.exp,
|
||||||
// "id": this.id,
|
// "id": this.id,
|
||||||
"qualification": this.qualification,
|
"qualification": this.qualification,
|
||||||
"fees": "800",
|
"fees": "800",
|
||||||
@ -366,7 +372,7 @@ unavailability(action,obj) {
|
|||||||
"gender": this.gender,
|
"gender": this.gender,
|
||||||
"workingHours": JSON.stringify([{"sunday":{"hours":[{"startTime":"09:30 am","endTime":"06:00 pm","day":"sunday","value":null}],"breaks":[]}},{"monday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"monday","value":null}],"breaks":[]}},{"tuesday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"tuesday","value":null}],"breaks":[]}},{"wednesday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"wednesday","value":null}],"breaks":[]}},{"thursday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"thursday","value":null}],"breaks":[]}},{"friday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"friday","value":null}],"breaks":[]}},{"saturday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"saturday","value":null}],"breaks":[]}}]),
|
"workingHours": JSON.stringify([{"sunday":{"hours":[{"startTime":"09:30 am","endTime":"06:00 pm","day":"sunday","value":null}],"breaks":[]}},{"monday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"monday","value":null}],"breaks":[]}},{"tuesday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"tuesday","value":null}],"breaks":[]}},{"wednesday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"wednesday","value":null}],"breaks":[]}},{"thursday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"thursday","value":null}],"breaks":[]}},{"friday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"friday","value":null}],"breaks":[]}},{"saturday":{"hours":[{"startTime":"09:00 am","endTime":"06:00 pm","day":"saturday","value":null}],"breaks":[]}}]),
|
||||||
"description": this.description,
|
"description": this.description,
|
||||||
"skills": this.skills,
|
"skills": JSON.stringify(this.skills),
|
||||||
"caption": this.caption,
|
"caption": this.caption,
|
||||||
"userName": this.userName,
|
"userName": this.userName,
|
||||||
"practitionerId":userid
|
"practitionerId":userid
|
||||||
|
|||||||
@ -43,6 +43,8 @@ ngOnInit() {
|
|||||||
description: new FormControl('',[Validators.required]),
|
description: new FormControl('',[Validators.required]),
|
||||||
fees:new FormControl('',[Validators.required])
|
fees:new FormControl('',[Validators.required])
|
||||||
});
|
});
|
||||||
|
console.log(this.local_data)
|
||||||
|
this.local_data.duration = JSON.stringify(this.local_data.duration)
|
||||||
this.form.patchValue(this.local_data)
|
this.form.patchValue(this.local_data)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -32,7 +32,7 @@
|
|||||||
<!-- Description Column -->
|
<!-- Description Column -->
|
||||||
<ng-container matColumnDef="duration">
|
<ng-container matColumnDef="duration">
|
||||||
<mat-header-cell *matHeaderCellDef mat-sort-header> Duration </mat-header-cell>
|
<mat-header-cell *matHeaderCellDef mat-sort-header> Duration </mat-header-cell>
|
||||||
<mat-cell *matCellDef="let row"> {{row.duration}} </mat-cell>
|
<mat-cell *matCellDef="let row"> {{row.duration}} Mins</mat-cell>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-container matColumnDef="fees">
|
<ng-container matColumnDef="fees">
|
||||||
<mat-header-cell *matHeaderCellDef mat-sort-header> Fees </mat-header-cell>
|
<mat-header-cell *matHeaderCellDef mat-sort-header> Fees </mat-header-cell>
|
||||||
|
|||||||
@ -76,24 +76,31 @@ export class UserListComponent implements OnInit {
|
|||||||
this.getBusinessList()
|
this.getBusinessList()
|
||||||
}
|
}
|
||||||
getUsersList() {
|
getUsersList() {
|
||||||
//this._pd.getTabStatusPdDetails(this.tabStatus)
|
let userRole = localStorage.getItem('user_role')
|
||||||
this._use.getUsersListDetails().subscribe(res => {
|
let param;
|
||||||
if (res.status == 200) {
|
if(userRole == 'BADMIN'){
|
||||||
this.isLoading = false
|
param ={"busId": localStorage.getItem('busId')}
|
||||||
let usersList = res.data
|
}else {
|
||||||
usersList.sort((a: any, b: any) => {
|
param = {}
|
||||||
return b.id - a.id;
|
}
|
||||||
});
|
this._use.getUsersListDetails(param).subscribe(res => {
|
||||||
this.usersList['data'] = usersList;
|
if (res.status == 200) {
|
||||||
this.usersListLength = res.data.length;
|
this.isLoading = false
|
||||||
this.recordStatus=false;
|
let usersList = res.data
|
||||||
}
|
usersList.sort((a: any, b: any) => {
|
||||||
else{
|
return b.id - a.id;
|
||||||
// this.usersList=[];
|
});
|
||||||
// this.dataSource = null;
|
this.usersList['data'] = usersList;
|
||||||
this.recordStatus=true;
|
this.usersListLength = res.data.length;
|
||||||
}
|
this.recordStatus=false;
|
||||||
},error => this.isLoading = false);
|
}
|
||||||
|
else{
|
||||||
|
// this.usersList=[];
|
||||||
|
// this.dataSource = null;
|
||||||
|
this.recordStatus=true;
|
||||||
|
}
|
||||||
|
},error => this.isLoading = false);
|
||||||
|
|
||||||
}
|
}
|
||||||
getBusinessList() {
|
getBusinessList() {
|
||||||
//this._pd.getTabStatusPdDetails(this.tabStatus)
|
//this._pd.getTabStatusPdDetails(this.tabStatus)
|
||||||
|
|||||||
@ -11,10 +11,17 @@ export class UserService {
|
|||||||
|
|
||||||
private apiUrl = environment.apiEndpoint;
|
private apiUrl = environment.apiEndpoint;
|
||||||
constructor(private _http: HttpClient) { }
|
constructor(private _http: HttpClient) { }
|
||||||
|
getUsersListDetails2(): Observable<any> {
|
||||||
getUsersListDetails(): Observable<any> {
|
|
||||||
console.log('IN')
|
console.log('IN')
|
||||||
return this._http.get<any[]>(this.apiUrl + "getusers")
|
return this._http.post<any[]>(this.apiUrl + "getusers",{})
|
||||||
|
// .pipe(
|
||||||
|
// catchError(this.handleError('role', []))
|
||||||
|
// )
|
||||||
|
}
|
||||||
|
|
||||||
|
getUsersListDetails(param): Observable<any> {
|
||||||
|
console.log('IN')
|
||||||
|
return this._http.post<any[]>(this.apiUrl + "getusers",param)
|
||||||
// .pipe(
|
// .pipe(
|
||||||
// catchError(this.handleError('role', []))
|
// catchError(this.handleError('role', []))
|
||||||
// )
|
// )
|
||||||
|
|||||||
@ -123,7 +123,7 @@ export class SearchCategoryComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else if(this.eventData == 'consultants'){
|
} else if(this.eventData == 'consultants'){
|
||||||
this._use.getUsersListDetails().subscribe(res => {
|
this._use.getUsersListDetails2().subscribe(res => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
console.log(res)
|
console.log(res)
|
||||||
// let data = res['data'].filter(val => val.role == 'PRACTITIONER')
|
// let data = res['data'].filter(val => val.role == 'PRACTITIONER')
|
||||||
|
|||||||
@ -81,7 +81,7 @@
|
|||||||
<p class="param"><img src="assets/images/Time-Icon.svg" alt="Avatar" class="img">Time : </p>
|
<p class="param"><img src="assets/images/Time-Icon.svg" alt="Avatar" class="img">Time : </p>
|
||||||
<span class="span-text">{{slotTime | date:'shortTime'}}</span>
|
<span class="span-text">{{slotTime | date:'shortTime'}}</span>
|
||||||
<p class="param"><img src="assets/images/Location.svg" alt="Avatar" class="img">Amount : </p>
|
<p class="param"><img src="assets/images/Location.svg" alt="Avatar" class="img">Amount : </p>
|
||||||
<span class="span-text"><span class="ex" style="font-size: 17px;padding-bottom: 10px;line-height: 17px;">₹</span> {{user.practitionerInfos[0].days}}</span>
|
<span class="span-text"><span class="ex" style="font-size: 17px;padding-bottom: 10px;line-height: 17px;">₹</span>{{durationArray.length>0 ? durationArray.fees : servicesName.fees}}</span>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -51,11 +51,15 @@ export class SlotBookingDetailsComponent implements OnInit {
|
|||||||
doctor: any=[];
|
doctor: any=[];
|
||||||
servicesName: any=[];
|
servicesName: any=[];
|
||||||
user: any=[];
|
user: any=[];
|
||||||
|
durationArray: any;
|
||||||
constructor(private router:Router,private datepipe:DatePipe,public end_user:EndUserService) {
|
constructor(private router:Router,private datepipe:DatePipe,public end_user:EndUserService) {
|
||||||
this.end_user.appointmentBooked_observable$.subscribe((res) => {
|
this.end_user.appointmentBooked_observable$.subscribe((res) => {
|
||||||
console.log('booked', res);
|
console.log('booked', res);
|
||||||
if(res.length>0){
|
if(res.length>0){
|
||||||
|
console.log(res[0])
|
||||||
|
this.durationArray = res[0]
|
||||||
this.servicesName = res[0].service[0]
|
this.servicesName = res[0].service[0]
|
||||||
|
console.log(this.servicesName)
|
||||||
this.user = res[0].user[0]
|
this.user = res[0].user[0]
|
||||||
this.doctor = res[0].user[0].userName
|
this.doctor = res[0].user[0].userName
|
||||||
this.getApiData()
|
this.getApiData()
|
||||||
|
|||||||
@ -10,11 +10,11 @@ export const environment = {
|
|||||||
// apiEndpoint:'http://192.168.1.20:8080/api/',
|
// apiEndpoint:'http://192.168.1.20:8080/api/',
|
||||||
// apiEndpoint:'https://api.venbait.in/api/',
|
// apiEndpoint:'https://api.venbait.in/api/',
|
||||||
// apiEndpoint:'http://venbainfotech.com:5000/api/',
|
// apiEndpoint:'http://venbainfotech.com:5000/api/',
|
||||||
apiEndpoint:'http://192.168.1.4:8080/api/',
|
apiEndpoint:'http://192.168.1.8:8080/api/',
|
||||||
// apiEndpoint:'https://api.venbait.in/api/',
|
// apiEndpoint:'https://api.venbait.in/api/',
|
||||||
|
|
||||||
//EndUser URL
|
//EndUser URL
|
||||||
endUserUrl:'https://venbainfotech.com/appointment/#/customer/business/',
|
endUserUrl:'https://venbainfotech.com/appointment/#/customer/',
|
||||||
|
|
||||||
firebase: {
|
firebase: {
|
||||||
apiKey: "AIzaSyCKbfDJ5Qf0rDP3WKppa94u9xuVaVabaDw",
|
apiKey: "AIzaSyCKbfDJ5Qf0rDP3WKppa94u9xuVaVabaDw",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user