cancel
Showing results for 
Search instead for 
Did you mean: 

File Picker with Staging Sandbox search in Forms

sbzoom
Champ in-the-making
Champ in-the-making
Hello.
I love the File Picker UI element that is generated when I put "xs:anyUri" into an xsd.  But, if I have lots and lots of file that aren't in a very good directory structure, it makes them difficult to find.  So I would love to be able to use the search that is available in my sandbox within this widget.  So, when you click on "Select" it shows a search box.  The search results are returned with the elements on the left and the "Select" button on the right, just like the File Picker.  I am assuming I would have to write my own widget for this.

1) Does it seem possible?
2) How do I access the search within a sandbox/staging/Web Project from
    a) outside Alfresco (for testing)
    b) inside the form

Thanks again.


Charlie
3 REPLIES 3

pmonks
Star Contributor
Star Contributor
This was added in v2.2, and is documented at http://wiki.alfresco.com/wiki/Configuring_XForms_Widgets#FilePicker_configuration_.28Web_Forms_only.....  I don't believe the last 2.9 Labs build (dated April 18th) includes this functionality, although the functionality should have been merged forward into the Alfresco Labs branch since then.

Cheers,
Peter

sbzoom
Champ in-the-making
Champ in-the-making
I looked into this before and from a second reading it still seems all wrong.

1) It is based on a previous search, not on entering a search term on the form.
2) It has to be a Saved Search, saved in the Data Dictionary/Saved Searches space.
3) Saved Searches are Open Searches.  Open Searches are not the same search that is used to search a Web Project.
4) I need to be able to search a Web Project, which (I have been told) can only be done with a Web Service.

What I am looking for is a search box to show up in the form and I can type into it something like "autos" and it will
return a list of files in my sandbox with "autos" in the URI name or "autos" somewhere in the text.

If anyone knows how this can be done please let me know.  Thanks.


Charlie

pmonks
Star Contributor
Star Contributor
If you have requirements that go beyond what the OOTB file picker widget can provide, I'd suggest you investigate implementing a custom Web Form widget.  This has been possible since v2.1 and is described at http://wiki.alfresco.com/wiki/Creating_XForms_Widgets.

While there is some learning curve (primarily around getting up to speed with the DOJO framework - http://dojotoolkit.org/), custom widgets can do just about anything that DHTML / AJAX can do.

Cheers,
Peter