make task suggestions relative to board
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -113,7 +113,7 @@ export function TaskSettingsModal(
|
||||
hidden
|
||||
id={categorySuggestionId}
|
||||
children:append={[
|
||||
taskViewModel.coreViewModel.taskCategorySuggestions,
|
||||
taskViewModel.containingViewModel.taskCategorySuggestions,
|
||||
StringToOption,
|
||||
]}
|
||||
></datalist>
|
||||
@@ -137,7 +137,7 @@ export function TaskSettingsModal(
|
||||
hidden
|
||||
id={statusSuggestionId}
|
||||
children:append={[
|
||||
taskViewModel.coreViewModel.taskStatusSuggestions,
|
||||
taskViewModel.containingViewModel.taskStatusSuggestions,
|
||||
StringToOption,
|
||||
]}
|
||||
></datalist>
|
||||
|
||||
Binary file not shown.
@@ -9,7 +9,7 @@ import ConnectionModel from "../../Model/Global/connectionModel";
|
||||
import ChatListModel from "../../Model/Chat/chatListModel";
|
||||
|
||||
export default class CoreViewModel {
|
||||
readonly BUILD = "Build 26.09.21.B";
|
||||
readonly BUILD = "Build 26.09.21.C";
|
||||
|
||||
translations: Translations;
|
||||
|
||||
@@ -81,11 +81,6 @@ export default class CoreViewModel {
|
||||
// DRAG & DROP
|
||||
draggedObject: React.State<any> = new React.State<any>(undefined);
|
||||
|
||||
// SUGGESTIONS
|
||||
// boards & tasks
|
||||
taskCategorySuggestions: React.ListState<string> = new React.ListState();
|
||||
taskStatusSuggestions: React.ListState<string> = new React.ListState();
|
||||
|
||||
// init
|
||||
constructor(
|
||||
public readonly storageModel: StorageModel,
|
||||
|
||||
Binary file not shown.
@@ -32,7 +32,7 @@ export default class BoardViewModel extends TaskContainingPageViewModel {
|
||||
filteredTaskViewModels: React.ListState<TaskViewModel> =
|
||||
new React.ListState();
|
||||
isFilterActive: React.State<boolean>;
|
||||
|
||||
|
||||
// paths
|
||||
getBasePath = (): string[] => {
|
||||
return [
|
||||
|
||||
@@ -17,6 +17,10 @@ export default class TaskContainingPageViewModel extends Context {
|
||||
new React.State<any>(undefined);
|
||||
|
||||
taskViewModels: React.MapState<TaskViewModel> = new React.MapState();
|
||||
|
||||
taskCategorySuggestions: React.ListState<string> = new React.ListState();
|
||||
taskStatusSuggestions: React.ListState<string> = new React.ListState();
|
||||
|
||||
|
||||
// methods
|
||||
createTaskFromBoardId = (boardId: string): void => {
|
||||
|
||||
@@ -104,19 +104,19 @@ export default class TaskViewModel extends Context {
|
||||
|
||||
updateSuggestions = (): void => {
|
||||
if (
|
||||
this.coreViewModel.taskCategorySuggestions.value.has(
|
||||
this.containingViewModel.taskCategorySuggestions.value.has(
|
||||
this.category.value,
|
||||
) == false
|
||||
) {
|
||||
this.coreViewModel.taskCategorySuggestions.add(this.category.value);
|
||||
this.containingViewModel.taskCategorySuggestions.add(this.category.value);
|
||||
}
|
||||
|
||||
if (
|
||||
this.coreViewModel.taskStatusSuggestions.value.has(
|
||||
this.containingViewModel.taskStatusSuggestions.value.has(
|
||||
this.status.value,
|
||||
) == false
|
||||
) {
|
||||
this.coreViewModel.taskStatusSuggestions.add(this.status.value);
|
||||
this.containingViewModel.taskStatusSuggestions.add(this.status.value);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user