Is it possible to implement advanced search form in a dashlet which takes place on the site dashboard - landing page? What would be the best way to do that?
Solved! Go to Solution.
There is share side service available for retrieving the form in alfresco.
http://hostort/share/service/components/form?itemKind=type&itemId=[type of document]&formId=[form_id]&mode=edit&showSubmitButton=true&showCancelButton=true&htmlid=args1
Using this service you can get the content and and display it inside any html element.
You may need to add other things like , setting the submition URL etc..
Other option is to design everything by your self.Meaning you need to define all fields in dashlet and use javascript to submit that value of element.Search form is ultimately submitting values on below URL.
http://hostort/share/page/dp/ws/faceted-search#searchTerm=&query={"prop_cm_name":"asd","datatype":"cm:content"}&scope=all_sites
So you can take values from fields and than create above url using values and hit that URL pragmatically.
There is share side service available for retrieving the form in alfresco.
http://hostort/share/service/components/form?itemKind=type&itemId=[type of document]&formId=[form_id]&mode=edit&showSubmitButton=true&showCancelButton=true&htmlid=args1
Using this service you can get the content and and display it inside any html element.
You may need to add other things like , setting the submition URL etc..
Other option is to design everything by your self.Meaning you need to define all fields in dashlet and use javascript to submit that value of element.Search form is ultimately submitting values on below URL.
http://hostort/share/page/dp/ws/faceted-search#searchTerm=&query={"prop_cm_name":"asd","datatype":"cm:content"}&scope=all_sites
So you can take values from fields and than create above url using values and hit that URL pragmatically.
If you refer to the out-of-the-box advanced search and if you can "easily" change that to be available in the site dashboard (i.e. via limited configuration / customisation), then no. But of course it would be possible to do a substrantial dashlet implementation to add "similar" functionality as a dashlet to any dashboard.
The "best way" to do this likely involves reusing the existing advanced search form configurations, and re-implementing (or adapting) the client-side rendering + logic of the advanced search page to fit within a dashlet. Since dashlets may have less space available for the search form than in the advanced search page, you may want to think about limiting the layouting options and potentially forcing a top-down layout rule instead of allowing multi-columned set layouts.
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.