Update screenshots and minor fixes from demo creation

This commit is contained in:
Matthew Ross 2020-05-28 08:45:44 -04:00
parent f99d6fdf89
commit f476d3fb35
6 changed files with 22 additions and 15 deletions

BIN
.github/boards.png vendored

Binary file not shown.

Before

Width:  |  Height:  |  Size: 435 KiB

After

Width:  |  Height:  |  Size: 486 KiB

BIN
.github/settings.png vendored

Binary file not shown.

Before

Width:  |  Height:  |  Size: 728 KiB

After

Width:  |  Height:  |  Size: 727 KiB

BIN
.github/tasks.png vendored

Binary file not shown.

Before

Width:  |  Height:  |  Size: 522 KiB

After

Width:  |  Height:  |  Size: 674 KiB

View File

@ -56,7 +56,7 @@ export class BoardService {
retVal.html = callback(false, marked(markdown)); retVal.html = callback(false, marked(markdown));
if (doCount) { if (doCount) {
retVal.counts = this.checkCounts; retVal.counts = Object.assign({}, this.checkCounts);
} }
return retVal; return retVal;

View File

@ -669,8 +669,16 @@ export class ColumnDisplayComponent implements OnInit, OnDestroy {
private updateTaskActivity(id: number) { private updateTaskActivity(id: number) {
this.viewTaskActivities = []; this.viewTaskActivities = [];
if (this.activeUser.security_level > 2) {
return;
}
this.boardService.getTaskActivity(id) this.boardService.getTaskActivity(id)
.subscribe(response => { .subscribe(response => {
if (response.data.length === 0) {
return;
}
response.data[1].forEach((item: any) => { response.data[1].forEach((item: any) => {
this.viewTaskActivities.push( this.viewTaskActivities.push(
new ActivitySimple(item.text, item.timestamp)); new ActivitySimple(item.text, item.timestamp));
@ -691,23 +699,24 @@ export class ColumnDisplayComponent implements OnInit, OnDestroy {
updatedTask.ownAttachment, updatedTask.ownAttachment,
updatedTask.sharedUser, updatedTask.sharedUser,
updatedTask.sharedCategory); updatedTask.sharedCategory);
task.html = updatedTask.html;
task.comments.forEach(comment => {
this.boardService.convertMarkdown(comment.text, this.markedCallback)
.then(data => { comment.html = data.html; });
});
return task; return task;
} }
private replaceUpdatedTask(updatedTask: any) { private replaceUpdatedTask(updatedTask: any) {
this.activeBoard.columns.forEach(column => { const oldTask = this.activeBoard.columns
if (+column.id !== +updatedTask.column_id) { .find(column => +column.id === +updatedTask.column_id)
return; .tasks.find(task => +task.id === +updatedTask.id);
}
column.tasks.forEach(task => { updatedTask.html = oldTask.html;
if (+task.id !== +updatedTask.id) {
return;
}
this.updateTaskComments(task, updatedTask.ownComment); this.updateTaskComments(oldTask, updatedTask.ownComment);
});
});
} }
private updateTaskComments(task: Task, newComments: any[]) { private updateTaskComments(task: Task, newComments: any[]) {

View File

@ -6,7 +6,6 @@ import {
OnDestroy, OnDestroy,
OnInit, OnInit,
Output, Output,
ChangeDetectorRef,
} from '@angular/core'; } from '@angular/core';
import { DomSanitizer } from '@angular/platform-browser'; import { DomSanitizer } from '@angular/platform-browser';
@ -62,8 +61,7 @@ export class TaskDisplayComponent implements OnInit, OnDestroy {
public boardService: BoardService, public boardService: BoardService,
public modal: ModalService, public modal: ModalService,
private notes: NotificationsService, private notes: NotificationsService,
public stringsService: StringsService, public stringsService: StringsService) {
private cdref: ChangeDetectorRef) {
this.onUpdateBoards = new EventEmitter<any>(); this.onUpdateBoards = new EventEmitter<any>();
this.percentComplete = 0; this.percentComplete = 0;
this.subs = []; this.subs = [];