akc: showcase someone elses folder

Create a link for someone elses folder on your home page. That folder will then be displayed in the context of this owner, all views of that folder and also the views of individual items within that folder.


folder id
folder owner

it is in /news/news.properties

Make sure the primary loop is qualified

Create CopyIfNotAvailable part

Probably not because, that part works this way


decodekey=key1
default=ddddd
translate.abc=xxxx
translate.xyz=www
resultname=key2

Explanation: if key1 is abc return key2 as xxxx. if key1 is xyz then return key2 as www, etc. if key1 is not there then return key2 as ddddd.

we have to use copyparameters part instead


must be logged in
folder owner must be the logged in user

use javascript to get the owner name among the urls

whether we copy ui or not at least make the data access common. there may too much complexity in keeping the ui same. Try reusing first and see what happens.

Dec 5th, Build 27

Created a conditionalsubstitution part

This class is used to ignore the result from a pipeline when returned. Same effect if you were to return a null as well.


upgrade the data query
make sure the current site works
Create links to see two accounts
test it from there

Here is an example of using if like expressions using "ifpart"

delete backup-news.properties once it is tested


request.NUFH.GetFolderOwner.classname=\
com.ai.parts.CopyParametersIfNotAvailablePart
request.NUFH.GetFolderOwner.originalNames=ownerUserId
request.NUFH.GetFolderOwner.newNames=folderOwner

request.NUFH.GetFolderQualifier.classname=\
com.ai.parts.ConditionalSubstitutionPart

request.NUFH.GetFolderQualifier.expression=exists(folderid)
request.NUFH.GetFolderQualifier.if=\
f.folder_id = {folderid}
request.NUFH.GetFolderQualifier.else=\
f.folder_name = {folderName.quote}
request.NUFH.GetFolderQualifier.resultname=FolderQualifier

if not available. This will let you share the content for internal urls.


public - not logged in
logged in - but different owner
logged in - same owner

logged in, folder owner, 
but content displayed under a diff owner

logged in user
folder owner
domain owner

are all the same

reports/folder-views/notes-imp-titles.html

Read SimpleBEEvaluator1 to understand boolean evaluations

debug summary view


titles
summaries
sort by date
sorty by name

Example would be android folder on my site when I am not logged in. Try the same when I am logged in on the same folder

or you can possibly use a folder id with out the owner as the id uniquely identifies that folder


dont use owneruserid
use downeruserid instead
specify folderowner

If a domain is defined it will present a proper background. If the domain is not defined it will go to the default owners background. Use owneruserid if the content is limited to one account for sure.

If you have a proper domain always use downeruserid

You can force a domain by explicitly specifying the owneruserid

In your documents, if you want your document to be shown in different domains avoid owneruserid


properties/user_login.properties

There is a problem with blindly replacing the owneruserid based on the incoming domain. If a url is restricted and requires a login then dont replace the owneruserid.

How can I get an authentication object?


IAuthentication authObject =
(IAuthentication)
(AppObjects.getIFactory().getObject
    (AspireConstants.AUTHENTICATION_OBJECT,null));