Problem/Motivation

The module only allow to set a single Google Place ID and we need to be able to set different place id's for each of our locations.

Proposed resolution

Add place ID field for the `Google Reviews Rating` and `Google Reviews List` blocks.

Remaining tasks

Review

CommentFileSizeAuthor
#2 3362535-1.patch9.18 KBgtr18
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

GTR18 created an issue. See original summary.

gtr18’s picture

StatusFileSize
new9.18 KB
ptitb’s picture

Hi @GTR18, Looks like a good feature! It might be a good idea to remove the place id from the settings altogether, and only use a place id in the blocks. I'll take a look at this!

christian deloach’s picture

Thank you ptitb for this module. It works great!

My client has several location, and each location has their own set of ratings and reviews. It would be great to provide support for multiple Google Place ID's in the same block, combining the reviews and averaging out the rating.

ptitb’s picture

Hi Christian,

This is a very specific use case which won't be supported.
Though it might be possible to add multiple blocks for multiple locations in the future.

Maybe you can alter this module or use it as a starting point to build the functionality you need!

frogdog_tech’s picture

Status: Active » Reviewed & tested by the community
Issue tags: -

Tested and confirmed #2 works great. Was also able to pass in the google_place_id via twig tweak drupal_block() params very nicely.

drupaldope’s picture

would this patch also work as a dynamic block in the manner of a view block, using a token or a node's place ID?

eric heydrich’s picture

Status: Reviewed & tested by the community » Needs review

Hi, I tested the patch. The following problem is coming up:

If no reviews exist at the configured location, the block produces an error. The page shows an error (WSOD). Even editing the page afterwards isn't possible any more.

sleitner made their first commit to this issue’s fork.

sleitner’s picture

Version: 1.1.2 » 1.1.x-dev
Issue tags: -New feature

Rerolled as a MR. Added schema and place url in rating template. Please review

  • sleitner committed e7ca38d5 on 1.1.x
    [#3362535] feat: Support for multiple Google Place ID's
    
sleitner’s picture

Status: Needs review » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.