Migrate OfferDetailsView.vue to PlatformServiceMixin, notification constants, and template streamlining

- Replaced all databaseUtil and direct PlatformServiceFactory usage with PlatformServiceMixin methods
- Abstracted all notification messages to src/constants/notifications.ts and migrated to notify helper
- Added computed properties for assignment labels to streamline template logic
- Removed unused imports and resolved all linter errors
- Updated migration documentation and ensured security audit compliance
- All changes validated with lint-fix and ready for human testing
This commit is contained in:
Matthew Raymer
2025-07-08 11:54:50 +00:00
parent 0b3b7dbb4d
commit 8f5c174097
4 changed files with 419 additions and 164 deletions

View File

@@ -200,6 +200,92 @@ export const NOTIFY_REGISTER_NOT_AVAILABLE = {
message: "You must get registered before you can create invites.",
};
// OfferDetailsView.vue specific constants
// Used in: OfferDetailsView.vue (mounted method - error loading offer details)
export const NOTIFY_OFFER_ERROR_LOADING = {
title: "Error",
message: "There was an error loading the offer details.",
};
// Used in: OfferDetailsView.vue (loadPreviousOffer method - previous record error)
export const NOTIFY_OFFER_ERROR_PREVIOUS_RECORD = {
title: "Retrieval Error",
message:
"The previous record isn't available for editing. If you submit, you'll create a new record.",
};
// Used in: OfferDetailsView.vue (confirm method - no identifier error)
export const NOTIFY_OFFER_ERROR_NO_IDENTIFIER = {
title: "Error",
message: "You must select an identifier before you can record a offer.",
};
// Used in: OfferDetailsView.vue (confirm method - negative amount error)
export const NOTIFY_OFFER_ERROR_NEGATIVE_AMOUNT = {
title: "",
message: "You may not send a negative number.",
};
// Used in: OfferDetailsView.vue (confirm method - no description error)
export const NOTIFY_OFFER_ERROR_NO_DESCRIPTION = {
title: "Error",
message: "You must enter a description or some number of {unit}.",
};
// Used in: OfferDetailsView.vue (confirm method - processing status)
export const NOTIFY_OFFER_PROCESSING = {
title: "",
message: "Recording the offer...",
};
// Used in: OfferDetailsView.vue (notifyUserOfProject method - no project error)
export const NOTIFY_OFFER_ERROR_PROJECT_ASSIGNMENT = {
title: "Error",
message: "To assign to a project, you must open this page through a project.",
};
// Used in: OfferDetailsView.vue (notifyUserOfProject method - conflict error)
export const NOTIFY_OFFER_ERROR_PROJECT_RECIPIENT_CONFLICT = {
title: "Error",
message: "You cannot assign both to a project and to a recipient.",
};
// Used in: OfferDetailsView.vue (notifyUserOfRecipient method - no recipient error)
export const NOTIFY_OFFER_ERROR_RECIPIENT_ASSIGNMENT = {
title: "Error",
message: "To assign to a recipient, you must open this page from a contact.",
};
// Used in: OfferDetailsView.vue (notifyUserOfRecipient method - conflict error)
export const NOTIFY_OFFER_ERROR_RECIPIENT_PROJECT_CONFLICT = {
title: "Error",
message: "You cannot assign both to a recipient and to a project.",
};
// Used in: OfferDetailsView.vue (recordOffer method - creation error)
export const NOTIFY_OFFER_ERROR_CREATION = {
title: "Error",
message: "There was an error creating the offer.",
};
// Used in: OfferDetailsView.vue (recordOffer method - success)
export const NOTIFY_OFFER_SUCCESS_RECORDED = {
title: "Success",
message: "That offer was recorded.",
};
// Used in: OfferDetailsView.vue (recordOffer method - recordation error)
export const NOTIFY_OFFER_ERROR_RECORDATION = {
title: "Error",
message: "There was an error recording the offer.",
};
// Used in: OfferDetailsView.vue (explainData method - privacy info)
export const NOTIFY_OFFER_PRIVACY_INFO = {
title: "Data Sharing",
message: "Your data is shared with the world when you sign and send.",
};
// Used in: [Component usage not yet documented]
export const NOTIFY_REGISTER_PROCESSING = {
title: "Processing",