|
@ -296,8 +296,6 @@ import { |
|
|
NOTIFY_GIFTED_DETAILS_DELETE_IMAGE_CONFIRM, |
|
|
NOTIFY_GIFTED_DETAILS_DELETE_IMAGE_CONFIRM, |
|
|
NOTIFY_GIFTED_DETAILS_DELETE_IMAGE_ERROR, |
|
|
NOTIFY_GIFTED_DETAILS_DELETE_IMAGE_ERROR, |
|
|
NOTIFY_GIFTED_DETAILS_NO_IDENTIFIER, |
|
|
NOTIFY_GIFTED_DETAILS_NO_IDENTIFIER, |
|
|
NOTIFY_GIFTED_DETAILS_PROJECT_PROVIDER_INFO, |
|
|
|
|
|
NOTIFY_GIFTED_DETAILS_BOTH_PROVIDER_SELECTED, |
|
|
|
|
|
NOTIFY_GIFTED_DETAILS_RECORDING_GIVE, |
|
|
NOTIFY_GIFTED_DETAILS_RECORDING_GIVE, |
|
|
NOTIFY_GIFTED_DETAILS_CREATE_GIVE_ERROR, |
|
|
NOTIFY_GIFTED_DETAILS_CREATE_GIVE_ERROR, |
|
|
NOTIFY_GIFTED_DETAILS_GIFT_RECORDED, |
|
|
NOTIFY_GIFTED_DETAILS_GIFT_RECORDED, |
|
@ -635,29 +633,32 @@ export default class GiftedDetails extends Vue { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
notifyUserOfGiver() { |
|
|
notifyUserOfGiver() { |
|
|
|
|
|
// there's no individual giver or there's a provider project |
|
|
if (!this.giverDid) { |
|
|
if (!this.giverDid) { |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_NO_IDENTIFIER.message, |
|
|
"To assign a giver, you must choose a person in a previous step.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} else { |
|
|
} else { |
|
|
|
|
|
// must be because providedByProject is true |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_BOTH_PROVIDER_SELECTED.message, |
|
|
"You cannot assign both a giver and a project.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
notifyUserOfRecipient() { |
|
|
notifyUserOfRecipient() { |
|
|
|
|
|
// there's no individual recipient or there's a fulfills project |
|
|
if (!this.recipientDid) { |
|
|
if (!this.recipientDid) { |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_NO_IDENTIFIER.message, |
|
|
"To assign a recipient, you must choose a person in a previous step.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} else { |
|
|
} else { |
|
|
// must be because givenToProject is true |
|
|
// must be because givenToProject is true |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_BOTH_PROVIDER_SELECTED.message, |
|
|
"You cannot assign both to a recipient and to a project.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} |
|
|
} |
|
@ -667,13 +668,13 @@ export default class GiftedDetails extends Vue { |
|
|
// we're here because they clicked and either there is no provider project or there is a giver chosen |
|
|
// we're here because they clicked and either there is no provider project or there is a giver chosen |
|
|
if (!this.providerProjectId) { |
|
|
if (!this.providerProjectId) { |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_PROJECT_PROVIDER_INFO.message, |
|
|
"To select a project as a provider, you must choose a project in a previous step.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} else { |
|
|
} else { |
|
|
// no providing project was chosen |
|
|
// no providing project was chosen, so there must be an individual giver |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_BOTH_PROVIDER_SELECTED.message, |
|
|
"You cannot select both a giving project and person.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} |
|
|
} |
|
@ -683,13 +684,13 @@ export default class GiftedDetails extends Vue { |
|
|
// we're here because they clicked and either there is no fulfills project or there is a recipient chosen |
|
|
// we're here because they clicked and either there is no fulfills project or there is a recipient chosen |
|
|
if (!this.fulfillsProjectId) { |
|
|
if (!this.fulfillsProjectId) { |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_PROJECT_PROVIDER_INFO.message, |
|
|
"To assign a project as a recipient, you must choose a project in a previous step.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} else { |
|
|
} else { |
|
|
// no fulfills project was chosen |
|
|
// no fulfills project was chosen, so there must be an individual recipient |
|
|
this.notify.warning( |
|
|
this.notify.warning( |
|
|
NOTIFY_GIFTED_DETAILS_BOTH_PROVIDER_SELECTED.message, |
|
|
"You cannot select both a receiving project and person.", |
|
|
TIMEOUTS.SHORT, |
|
|
TIMEOUTS.SHORT, |
|
|
); |
|
|
); |
|
|
} |
|
|
} |
|
|