Skip to content

Commit

Permalink
Assigning postId and getSurvey method to posts in map view (#1509)
Browse files Browse the repository at this point in the history
  • Loading branch information
MMwandigha authored and tuxpiper committed Jan 23, 2025
1 parent 5cca9a6 commit 38629c9
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,15 @@ export class PostDetailsComponent extends BaseComponent implements OnChanges, On
this.postId = Number(params['id']);
}
});

//map View
if (this.postFromModal) {
this.post = this.postFromModal;
this.postChanged = false;

//assign post id and get survey
this.postId = this.post.id;
this.getSurvey();
} else {
this.dataSubscription = this.route.data.subscribe((data) => {
this.post = data['post'];
Expand Down

0 comments on commit 38629c9

Please sign in to comment.