Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feedback title truncation (connects #3936) #4066

Merged
merged 13 commits into from
Sep 30, 2019
Prev Previous commit
Next Next commit
Fix codeclimate and display params
  • Loading branch information
Liew211 authored and paulbert committed Sep 30, 2019
commit a454cf250ffbc97e17974d31b6556f23096b1652
2 changes: 1 addition & 1 deletion src/app/feedback/feedback-view.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
</mat-toolbar-row>
</mat-toolbar>
<div class="view-container view-full-height">
<div class="feedback-params">{{feedback.params}}</div>
<div class="feedback-params" *ngFor="let prop of feedback.params | keyvalue">{{prop.key}}: {{prop.value}}</div>
<div class="chat-list" #chatList>
<div class="chat-list-item" *ngFor="let message of feedback.messages; trackBy: feedbackTrackByFn">
<div class="chat-list-user">
Expand Down
4 changes: 2 additions & 2 deletions src/app/feedback/feedback.directive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export class Feedback {
source: string;
url: string;
messages: Array<Message>;
params: string;
params: Object;
}

const dialogFieldOptions = [
Expand Down Expand Up @@ -90,13 +90,13 @@ export class FeedbackDirective {
status: 'Open',
messages: [ startingMessage ],
url: this.router.url,
params: parseToObject(this.router.url),
source: this.stateService.configuration.code,
parentCode: this.stateService.configuration.parentCode,
...this.feedbackOf
};
this.couchService.updateDocument('feedback', {
...newFeedback,
params: JSON.stringify(parseToObject(newFeedback.url)),
title: newFeedback.type + ' regarding ' + newFeedback.url.substring(0, newFeedback.url.indexOf(';')) })
.subscribe((data) => {
this.feedbackService.setfeedback();
Expand Down