Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Goals and Implementation overview
Phase 3:
Option to email wishlist to others- This feature would enable users or wish list owners to share any wish list with other users or potential customers by emailing it to the respective user.
- The following email properties are defined in an appropriate hook_mail implementation:
- Email subject: Includes a brief synopsis of the wish list contents.
- Email recipients: Includes the email addresses of other users to whom the wishlist is concerned.
- Email message: A text area which includes any necessary message to be accompanied with the concerned wishlist.
- The Form API and Database API would be used for the creation, submission & validation of the wish list email and to provide a structured interface for the dynamic construction of queries to implement the above functionality.@naveenvalecha,
Fresh patch contains port of 'Add User wishlist settings' along with 'email wish list' and
'add user wishlist settings' screenshots.Please review.
- Conversion of D7 Hook functions to D8 APIs involving Routes, to define the path to Controllers (page callbacks in D7) or to create tabs and/or contextual links. Email address of an user is verified through the Data Common API.
- The Renderable Array System has to be applied to improve the grouping of form items. The email could be sent by using Mail Manager using public function MailManager::mail
Add User wish list settings- This feature is implemented by creating a table for the required wish list settings using the Form and Database API
- The mandatory fields, including User, Title, Expiration Date & Status are created using Field API and the Hook functions hook_field_settings_form & hook_field_widget_form. The Configuration API would be used to configure the fields.
- db_select is implemented with a Join to join/combine with another table containing relevant information.
- The Renderable Array system would be applied to improve the grouping of the contents. The Field Theme System would be configured.
Comment | File | Size | Author |
---|---|---|---|
#21 | interdiff-14-18.txt | 9.5 KB | chiranjeeb2410 |
#21 | wishisemailed.png | 127.57 KB | chiranjeeb2410 |
#21 | usersettings.png | 113.25 KB | chiranjeeb2410 |
#19 | wishisemailed.png | 127.57 KB | chiranjeeb2410 |
#18 | 2880444-18.patch | 12.02 KB | chiranjeeb2410 |
Comments
Comment #2
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedComment #3
naveenvalechaComment #4
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedComment #5
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedComment #6
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Uploaded fresh patch for final port. Includes features to 'Add user wish list settings'
and 'Email wish list to others'.
Please review.
Comment #7
naveenvalechaThis is the wrong patch. See how to create a patch https://www.drupal.org/node/707484
Comment #8
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Working on it.
Comment #9
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Uploaded new patch. Please review.
Comment #10
naveenvalechaThis is the wrong patch. See how to create a patch https://www.drupal.org/node/707484
Comment #11
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Is the patch not getting applied to your local?
Comment #12
naveenvalechaThe patch is getting applied but at the wrong place. Read this carefully https://www.drupal.org/node/707484
Comment #13
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedComment #14
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedFixed coding standards and made minor improvements.
Comment #15
naveenvalechaImprove the comment.
If this is User Wishlist Settings form then rename the class name which reflects its purpose.
inject it with DI
unrelated change
rename the tab_2 to wishlist_email or something more meaningful
Wrong permission name. Have you tested your code?
Comment #16
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Working on it.
Comment #17
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Added required changes.
Please review.
Comment #18
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedAdded corrections to route file.
Comment #19
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Screenshots attached of the latest ports. Seem to work as planned.
Comment #20
naveenvalechacould you provide Interdiff please https://www.drupal.org/documentation/git/interdiff
Comment #21
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedUploaded interdiff displaying latest changes. Also, attached screenshots of the attached ports.
Seem to work as planned.
Comment #22
naveenvalechaWrong inter diff attached in #21. It's not useful :( Re-read the attached d.org handbook page.
Remove @file from here.
is this uc_product settings. Could you rename this variable to reflect what it is
DI the current user service
Inject the current user service
This seems not to be the correct permission.
Comment #23
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Implementing DI seems to throw some exception errors and doesnt display the form.
What could be the problem?
Comment #24
naveenvalecha@chiranjeeb2410,
Share the error, How could I imagine which problem are you getting.
Read about the Dependency injection:
Comment #25
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commentedWorking on it.
Comment #26
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
This seems to be the error displayed on clearing caches.
However, working on it and will implement DI and post a fresh patch asap.
Comment #27
naveenvalecha#26,
Could you share the code so that I could reproduce it on my local?
I have reviewed the current 8.x-1.x and tested the functionality of the module on my local and the module is throwing the error. See the review points here #2904915: UC Wishlist review I have marked #2904915: UC Wishlist review as major because it's required for the alpha release of the module and the deliverables of phase 2 and phase 3.
Comment #28
chiranjeeb2410 CreditAttribution: chiranjeeb2410 at Google Summer of Code commented@naveenvalecha,
Working on it. Saw the review points. Would be posting a patch for the fixes mentioned in #2904915: UC Wishlist review.
Comment #29
naveenvalechaSetting to correct status.