1. Goddard
  2. General
  3. Friday, March 14 2014, 01:59 AM
Is it possible to create a field that is only editable by a certain access group, but still visable on all profiles?
admin Accepted Answer
Admin
No sorry, not possible without changes to the code!

You can create 2 fields. with different access levels.

if you explain better what you want to do. I can help you find the best solution!
  1. more than a month ago
  2. General
  3. # 1
Goddard Accepted Answer
Content Protected
  1. more than a month ago
  2. General
  3. # 2
admin Accepted Answer
Admin
I need a user directory that is searchable, as an Admin I wanted to be able to set who is on what searchable list. I then want to link to that searchable list in my menu.

You can create many list of user with different Access setting, for each list you can set SQL Custom where you can choose which user are in the list. (see docs at http://www.easy-profile.com/docs/69-sql-custom-where-list-and-module.html)

I would like to be able to give my users different "titles"(images) and also assign them form fields that signify they belong to a special group which can be done now, but I want them to only be modifiable by a specific access level, or at the very least Admins only.

- You can create a field and set access level for the avaibility of fields
- You can disable view on edit profile, with this only the admin from backend can modify
- If you want a field available with certain access and editable for other access setting, this is not possible. But you can create 2 field with same name(different alias):
first available and editable for certain access
second only available for certain access (different by first)
I do not know if he can fit you

What file would I look at if I wanted to make changes to the code for this if there isn't a solution already? Do you have plugin hooks built into this component?

For hooks: Yes. see our documentation under Developer section.
You can edit the plugin jsn_users (plugin/user/jsn_users/jsn_users.php), this plugin manage everything about registration and editing profiles (I do not recommend it)
  1. more than a month ago
  2. General
  3. # 3
Goddard Accepted Answer
Thanks for the answers.

So I am trying to make a list of users that have a specific checkbox selected. I set a default value and am using the alias and the default value to select people.

so in the custom where area I put

my_field_alias != "false"

but it isn't working
  1. more than a month ago
  2. General
  3. # 4
admin Accepted Answer
Admin
Hi,
You have 2 problems:
- Default value is only for forms, in DB the value is empty
- Checkbox an select list (with multiple selection) can assign more values, so, the data stored in DB is in this format: ["value1","value2","value3"]

Solution:
if I want the list of user with value1 or empty value (because I set default=value1)
set in SQL_CUSTOM_WHERE:
my_field_alias LIKE '%"value1"%' OR my_field_alias IS NULL
  1. more than a month ago
  2. General
  3. # 5
Goddard Accepted Answer
That didn't work.

Maybe I didn't create field right?

my field

my_field_alias
----------------------
true|true
false|false


Custom SQL WHERE - this is on the menu item
----------------------
my_field_alias LIKE '%"true"%' OR my_field_alias IS NOT NULL


Is this not right?
  1. more than a month ago
  2. General
  3. # 6
admin Accepted Answer
Admin
please specify the type of your field and default value
  1. more than a month ago
  2. General
  3. # 7
Goddard Accepted Answer
The type is checkbox and the default value is "false"
  1. more than a month ago
  2. General
  3. # 8
admin Accepted Answer
Admin
if you want to see the user who have the only 'true' value set this

my-field-alias LIKE '["true"]'

if you want to see the user who have the 'true' value and maybe another value

my-field-alias LIKE '%"true"%'
  1. more than a month ago
  2. General
  3. # 9
admin Accepted Answer
Admin
ok, i found 2 problem:

1.
for field with '-' char in alias you must quote the field with ` . this is the right way:
`certified-ifs-therapist` LIKE '["true"]'


2.
The result is hidden by footer (see screenshot)
You can add this line to your css template:
#rt-footer-surround {clear: both;}
Attachments (1)
  1. more than a month ago
  2. General
  3. # 10
Goddard Accepted Answer
Awesome thanks. That works perfect now.

I did have one more question though. Is there any way I can display an image instead of text if the person selects the checkbox?
  1. more than a month ago
  2. General
  3. # 11
admin Accepted Answer
Admin
Yes,
you can use the delimeter to insert HTML (and image) in profile page.

With condition you can hide or show delimeter.
  1. more than a month ago
  2. General
  3. # 12
Goddard Accepted Answer
Can you elaborate a little more on this. I finally got to a point where I can figure this out, but I am not sure what you mean by delimiter. Like ";" ?
  1. more than a month ago
  2. General
  3. # 13
admin Accepted Answer
Admin
Hi,
sorry for late reply

I did not understand.

Yes, you can, follow this How To:
- in checkbox option set the options like this:
0|CHEBOXIMAGE1
1|CHEBOXIMAGE2
- Go on Extensions->Language Manager->Overrides(on left menu) and click on New button
- Set language constanct to CHEBOXIMAGE1
- Set text your substitution, for image img src="images/your_image1.jpg" / ***
- Set language constanct to CHEBOXIMAGE2
- Set text your substitution, for image img src="images/your_image2.jpg" / ***

if you have a multilanguage site you must create a overrides rules for each language

***I have removed the <> because not work on this forum
  1. more than a month ago
  2. General
  3. # 14
Goddard Accepted Answer
ahh cool trick.

Thanks a lot.
  1. more than a month ago
  2. General
  3. # 15
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.
Sorry, the discussion is currently locked. You will not be able to post a reply at the moment.