Skip to content
Commits on Source (2)
......@@ -287,17 +287,19 @@
<div class="m-mediaModal__actionButtonsWrapper">
<div class="m-mediaModal__actionButtonsRow m-action-tabs">
<minds-button-thumbs-up
[object]="entity"
[object]="originalEntity"
></minds-button-thumbs-up>
<minds-button-thumbs-down
[object]="entity"
[object]="originalEntity"
></minds-button-thumbs-down>
<m-wire-button
*ngIf="session.getLoggedInUser().guid != entity.owner_guid"
[object]="entity"
(done)="wireSubmitted($event)"
></m-wire-button>
<minds-button-remind [object]="entity"></minds-button-remind>
<minds-button-remind
[object]="originalEntity"
></minds-button-remind>
</div>
</div>
......
......@@ -67,6 +67,7 @@ export class MediaModalComponent implements OnInit, OnDestroy {
minds = window.Minds;
entity: any = {};
originalEntity: any = null;
redirectUrl: string;
isLoading: boolean = true;
navigatedAway: boolean = false;
......@@ -109,6 +110,7 @@ export class MediaModalComponent implements OnInit, OnDestroy {
routerSubscription: Subscription;
@Input('entity') set data(params: MediaModalParams) {
this.originalEntity = params.entity;
this.entity = params.entity && JSON.parse(JSON.stringify(params.entity)); // deep clone
this.redirectUrl = params.redirectUrl || null;
}
......