Synopsis

The Domain Theme Switch module has the setting to set the different theme against each domain.

Module Dependencies
Domain

How to use "Domain Theme switch"

  • Config path is "Configuration > Domain theme switch"
  • Select the theme against the domain name and save the configuration. clear the cache.

The "Domain Theme Switch" module is currently used in the following domain.
https://www.familyeducation.com/
https://www.teachervision.com/

git clone --branch 8.x-1.x-dev https://git.drupal.org/sandbox/aloknarwaria/2691703.git domain_theme_switch
cd domain_theme_switch

Link to sandbox project https://www.drupal.org/sandbox/aloknarwaria/2691703

Manual Review done for other Projects:
https://www.drupal.org/node/2851052#comment-11928535
https://www.drupal.org/node/2839903#comment-11930427
https://www.drupal.org/node/2847279#comment-11935291
https://www.drupal.org/node/2847141#comment-11930962
https://www.drupal.org/node/2850757#comment-11930570
https://www.drupal.org/node/2851740#comment-11933787
https://www.drupal.org/node/2828016#comment-11782701

Comments

aloknarwaria created an issue. See original summary.

PA robot’s picture

Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://www.drupal.org/node/2826944

Project 2: https://www.drupal.org/node/2826872

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

PA robot’s picture

We are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)

Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).

I'm a robot and this is an automated message from Project Applications Scraper.

aloknarwaria’s picture

Issue summary: View changes
PA robot’s picture

Issue summary: View changes

Fixed the git clone URL in the issue summary for non-maintainer users.

I'm a robot and this is an automated message from Project Applications Scraper.

sarthak drupal’s picture

Works for me great job :)

Please add more steps in README file so that easy to setup the domains and test the themes against the individual domain.

sarthak drupal’s picture

Priority: Normal » Major
ashish-deynap’s picture

soaratul’s picture

Status: Needs review » Needs work

Got following error after enable the module.

Fatal error: Call to a member function id() on null in modules/contrib/domain_theme_switch/src/Theme/ThemeSwitchNegotiator.php on line 42

aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Status: Needs work » Needs review

@soaratul
Reported issue regard Fatal error is fixed please review again.

soaratul’s picture

Status: Needs review » Needs work
StatusFileSize
new59.62 KB
new46.46 KB

Great @aloknarwaria,
Now I can access pages, without interruption.

Next I go through the process to setup theme by domain and will suggest following to improve user experience.
1. Please change path for "admin/config/domain_theme_switch/configuration" to "admin/config/domain/theme", and also add this menu as tab beside "Domain settings"(Please see attached screen short 1.png), and correct breadcrumb accordingly, I would suggest to have breadcrumb as "Home -> Administration -> Configuration -> Domains -> Theme".
2. Add a description on domain theme page so that user can know more about.(Please see attached screen short 2.png)
3. I would suggest to change message, that is displayed if no domain added. That is change from "Unable to find the domain record please click here to create the domain first." to something like "To add theme at-least one domain record is required, click here tot add domain."

aloknarwaria’s picture

Status: Needs work » Needs review

Thanks @soaratu suggested changes are done please review again.

soaratul’s picture

Awesome @aloknarwaria,

I go further and found following, please have a look into these.

1. Routing name domain_theme_switch.domain_theme_switch_config_form can be changed to domain_theme_switch.settings?
2. Configure link is missing in .info.yml, it generate a link on module list page interface.
3. There should be at-least one permission, that will help to people to assign to any role.
4. Use single quote instead double e.g change t("Select Theme for @domain_name",array('@domain_name'=>$value)) to t('Select Theme for @domain_name', array('@domain_name' => $value)).
5. One line should have a maximum of 80 character.

soaratul’s picture

Status: Needs review » Needs work
aloknarwaria’s picture

Status: Needs work » Needs review

Dear @soaratu suggested changes are fixed. Thanks for your valuable comments and efforts.

aloknarwaria’s picture

Issue summary: View changes
harsh.behl’s picture

StatusFileSize
new1.23 KB

Hi,
@aloknarawaria please the patch for some minor tweeks.

aloknarwaria’s picture

Hi @pen thanks for reviewing my module very closely and appreciate for your patch.

aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Status: Needs review » Active
aloknarwaria’s picture

Issue summary: View changes
PA robot’s picture

Issue summary: View changes

Fixed the git clone URL in the issue summary for non-maintainer users.

I'm a robot and this is an automated message from Project Applications Scraper.

aloknarwaria’s picture

I tested my module on https://pareview.sh please find the output below:

Review of the 8.x-1.x branch (commit 22ef6e7):

  • No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.

This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.

sarthak drupal’s picture

Status: Active » Reviewed & tested by the community

Hi @alok

This module works for me as per my requirements.
I didnt find any warning or errors.
Code is written with Drupal 8 standards.

Great work.
Thanks

aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Status: Reviewed & tested by the community » Fixed
yogeshmpawar’s picture

Status: Fixed » Needs review

@aloknarwaria - you can not change to status to "Fixed" of your project. one of the "Project Application Git Review Administrator" have to do this. so please don't change your project status to "Fixed".
please see the link for Review Process.

aloknarwaria’s picture

Hi Yogesh Pawar,

Thanks for your prompt response, I will take care of this.

b n pandey’s picture

Status: Needs review » Reviewed & tested by the community

Hi @alok

This module works for me. I review this module manually and did not find any error.
Finally I tested this module on pareview.sh and did not find any error or warning.
https://pareview.sh/node/355

Thanks

aloknarwaria’s picture

Hi B N Pandey,

Thanks for reviewing my piece of code and your kind feedback.

aloknarwaria’s picture

Issue summary: View changes
Issue tags: -domain +PAreview: review bonus
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

Issue summary: View changes
aloknarwaria’s picture

visabhishek’s picture

Status: Reviewed & tested by the community » Fixed

Review of the 8.x-1.x branch (commit 22ef6e7):

No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.

This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.

Otherwise all looks good for me.

Thanks for your contribution, aloknarwaria!

I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.

Here are some recommended readings to help with excellent maintainership:

You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!

Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.

Thanks to the dedicated reviewer(s) as well.

visabhishek’s picture

Assigning Credits.

Status: Fixed » Closed (fixed)

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