Currently, if you add a field to the 'Userpoints node access denied' view mode, there is no way to specify its position relative to the "need more points" message of the "Get access" button. Can the "need more points" message or "Get access" button be included on the 'Manage display' page of the Fields UI?

Perhaps they could both be listed as one "field" named "Access message" or something like that. This way, the relative position of this message/button could be specified.

--Ben

Comments

chx’s picture

Category: feature » bug
Priority: Normal » Critical
Status: Active » Needs review
StatusFileSize
new2.23 KB

This is broken without this feautre. It might be that it's only broken together with display suite. I had no time to check for that. Note the attached patch is meow-heavy as it fixes a bunch o' other issues and misses doxygen on userpoints_nodeaccess_entity_delete. Too. bad! it's a nice bunch of badly needed fix.

chx’s picture

StatusFileSize
new3.1 KB

That reminds me to contribute back a Views fix as well.

chx’s picture

StatusFileSize
new3.1 KB

Minus a notice.

berdir’s picture

Status: Needs review » Needs work

Nice fixes, just this one thing I'm not sure about:

+++ b/userpoints_nodeaccess.moduleundefined
@@ -465,3 +465,46 @@ function userpoints_nodeaccess_description_callback($operation, $entity) {
+  foreach (node_type_get_types() as $type) {
+    if (variable_get('userpoints_nodeaccess_enabled_' . $type->type, variable_get('userpoints_nodeaccess_enabled', TRUE))) {

Could we run into a caching problem with this? AFAIK, extra fields are now cached. So if you change the enabled setting, the field won't show up. Or am I wrong..?

It's also crap that there is no way to only show those fields on our view modes...

Powered by Dreditor.

berdir’s picture

Status: Needs work » Fixed

Thanks, added a few comments and committed this.

Status: Fixed » Closed (fixed)

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

diwant’s picture

I don't understand how to show the userpoints_nodeaccess button in the manage display section (using display suite). I'm not reopening the issue but it's where I looked for this answer, I figure others will find this as well.

diwant’s picture

StatusFileSize
new85.33 KB

Hahaa, flushing caches randomly should be a cron thing. Here's what the fields look like in Display Suite (see attached screenshot). If you don't see them, flush your cache. Twice.

Screen shot with userpoints nodeaccess extra fields in display suite ui

That's what's up.