From 4c6c85983c6dcd123370f2a9bc7c99e1fdfcebaa Mon Sep 17 00:00:00 2001 From: Trent Larson Date: Sat, 22 Jun 2024 12:06:55 -0600 Subject: [PATCH] fix checkbox verbiage when no project is chosen for a give --- src/views/GiftedDetails.vue | 43 +++++++++++++++++++++++++++++++------ 1 file changed, 36 insertions(+), 7 deletions(-) diff --git a/src/views/GiftedDetails.vue b/src/views/GiftedDetails.vue index da6f516aa..c0f746f6e 100644 --- a/src/views/GiftedDetails.vue +++ b/src/views/GiftedDetails.vue @@ -78,7 +78,7 @@
- +
@@ -106,7 +110,7 @@ icon="square" class="bg-slate-500 text-slate-500 h-5 w-5 px-0.5 py-0.5 mr-2 rounded" @click=" - notifyUser('Cannot be both given to a project and also given to you.') + notifyUser('You cannot assign this both a project and also to you.') " /> @@ -114,7 +118,7 @@
- +

@@ -450,6 +454,31 @@ export default class GiftedDetails extends Vue { ); } + notifyUserOfProject() { + if (!this.projectId) { + this.$notify( + { + group: "alert", + type: "warning", + title: "Error", + text: "To assign to a project, you must open this dialog through a project.", + }, + 3000, + ); + } else { + // must be because givenToUser is true + this.$notify( + { + group: "alert", + type: "warning", + title: "Error", + text: "You cannot assign both to a project and to yourself.", + }, + 3000, + ); + } + } + /** * * @param giverDid may be null