Closed (fixed)
Project:
Domain Views
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
2 Mar 2011 at 01:32 UTC
Updated:
3 Jan 2014 at 02:58 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
agentrickardThis looks pretty handy.
New features go in 7.x.
The plain $text return needs to be sanitized. How does it affect existing uses?
Comment #2
noahlively commentedOK here is a patch for 7.x-1.x-dev.
I sanitized $text through a call to check_plain().
This patch has built in backward compatibility with previous versions. The keys/values of the $options array are slightly different, but logic in the options_form() function will check for legacy values and re-save them in the new format.
Comment #3
agentrickardSuper-awesome.
Any independent reviewers out there?
Comment #4
agentrickardWorks very nicely in D7.
Comment #5
agentrickardI took another look at this. We already have domain fields that cover these options. What does this patch offer that isn't already covered?
Is there a benefit to this extra render element? Better queries?
Comment #6
noahlively commentedWithout the patch I created, if a node is mapped to more than one affiliate domains I get duplicate records showing up in my views output.
Example:
mysite.com
a.mysite.com
b.mysite.com
Node 321 is mapped to mysite.com and a.mysite.com, with a.mysite.com as the source domain. Using technique #3 above, I get duplicate records.
Does what I am saying make sense?
You can view the output (after patch was applied) at http://www.sacramentoinsights.com. The home page renders a list of subdomains with links to the subdomains.
Without the patch, there was no way I found to work around the duplicate record issue after spending hours looking.
Comment #7
agentrickardI think I get it. Domain Source (the module) uses the same domain_id handler as {domain}.domain_id.
I was testing {domain}.domain_id, not {domain_source}.domain_id.
Comment #8
mariusz.slonina commented+1, that patch saved my day today
Comment #9
agentrickardMarking for commit review.
Comment #10
agentrickardCommitted. Also fixed a bunch of minor code style issues in the module.