image-cropper component, drag & drop bilder
This commit is contained in:
@@ -24,6 +24,7 @@ import { MessageService } from 'primeng/api';
|
||||
import { SharedModule } from '../../../shared/shared/shared.module';
|
||||
import { GalleriaModule } from 'primeng/galleria';
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
|
||||
@Component({
|
||||
selector: 'app-details-listing',
|
||||
standalone: true,
|
||||
@@ -59,13 +60,15 @@ export class DetailsListingComponent {
|
||||
propertyImages: ImageProperty[] = []
|
||||
environment = environment;
|
||||
user:User
|
||||
description:SafeHtml;
|
||||
constructor(private activatedRoute: ActivatedRoute,
|
||||
private listingsService: ListingsService,
|
||||
private router: Router,
|
||||
private userService: UserService,
|
||||
public selectOptions: SelectOptionsService,
|
||||
private mailService: MailService,
|
||||
private messageService: MessageService) {
|
||||
private messageService: MessageService,
|
||||
private sanitizer: DomSanitizer) {
|
||||
this.userService.getUserObservable().subscribe(user => {
|
||||
this.user = user
|
||||
});
|
||||
@@ -76,6 +79,7 @@ export class DetailsListingComponent {
|
||||
async ngOnInit() {
|
||||
this.listing = await lastValueFrom(this.listingsService.getListingById(this.id, this.type));
|
||||
this.propertyImages = await this.listingsService.getPropertyImages(this.listing.id)
|
||||
this.description=this.sanitizer.bypassSecurityTrustHtml(this.listing.description);
|
||||
}
|
||||
back() {
|
||||
this.router.navigate(['listings', this.criteria.listingsCategory])
|
||||
|
||||
Reference in New Issue
Block a user