Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
How to hide replicant from some users?
syim
I would like to hide a replicant from some users; however, it does not work? Does anyone know if I can hide a replicant using followings in my DCT?
<item name="replicantitem">
<replicant>
<allowed><cred user="userid"/></allowed>
<item name="textinreplicant">
<text><allowed><cred user="userid"/></allowed></text>
<hidden/>
</item>
<hidden/>
</replicant>
</item>
The <allowed> element within replicant seems to cause problem. It works if I removed the <allowed> element. However, the replicant buttons are showing. Can I hide replicant buttons from users?
Find more posts tagged with
Comments
JonathonG
It looks like you need to move the second <hidden/> outside of the <replicant> tags. So, just swap around the <hidden/> and </replicant> tags and see if that works. If not, you might want to post more information about your environment (TS version, OS version) and what the error you're getting is.
Jonathon
Interwoven Architecture Consultant
syim
I made the change as you have seggested. I got following error, when I login as the user NOT specified in the allowed tag. I can only access the DCR if I login as the user specified in the allowed tag.
Templating Error Page
An exception was thrown: Error reading Data Content Record node90001: com.interwoven.templating100.dcr.TDCRComplexValue
FYI, the TS version is 5.5.2, on Windows 2000
Edited by syim on 07/22/03 12:00 PM (server time).
JonathonG
Oh, I think this makes sense now. You're trying to edit a DCR created by the allowed user as a non-allowed user, right? So, what's happening is that Templating is trying to read the contents of a replicant into a non-replicant (hidden) field. That's where your error is coming from. Sorry I didn't think of this sooner. Looks like you may have to go a different route. What exactly are you trying to accomplish (from a business use-case perspective)? Unfortunately, there isn't any level of FormAPI control of repllicants. Off the top of my head, all I can think of is some FormAPI code which counts the number of replicants at load time, does a compare at save time and if they are not the same, errors unless the user is allowed to add to the replicant. Not the cleanest of solutions, but until we get some events/handlers for replicant events, its about all I can think of.
Jonathon
Interwoven Architecture Consultant