How to use pagination for the asset publisher custom application display template in Liferay? - liferay-6

I have created one ADT for asset publisher and here im fetching all the documents from a specific folder ,here my problem is that we want to use existing pagination,we have configured the simple pagination, but still the result not coming properly.so is there any alternate way to use the existing pagination with our custom ADT.
Thanks & Regards,
P.v.B.Raju.

As far as I know, there is no way to paginate in Freemarker by default. For custom pagination, you have to override Liferay's core JSP here, which is very unfortunate. If you've found another solution, please share it here.

Related

Create a Block with data from database in Sulu

I need to build a block with data from (Symfony) Entity.
For example a carousel with last 3 item/record from database.
This block can appear in more than just a page.
I know that I can use a custom controller but is that the best technical choice ?
Do i need "Smart content" ? Read the doc but it's not clear
How i can do that ?
Thanks in advance.
Using a twig extension or a controller would definitely be the easiest way, because no sulu knowledge is required for that.
But the sulu way of solving that problem would be a custom SmartContentDataProvider. There are two main advantages of this method:
The content editor can further filter the result (in your case probably sorting and limiting)
The result is also displayed in the admin interface (Otherwise it would just be shown in the preview)
Our community is usually using our Slack channel or GitHub Discussions for support questions. Your questions will probably be answered a lot faster there, because there we can better track them.

How to update value of a field for all page in AEM?

I create a site with AEM (Adobe Experience Manager). I have a page type as property-page. The property-page have a field type "Number of event in a page". I want to modify the number of event for all property page.
How to do that?
Thank you & kind regards,
There is no mass-update feature in AEM. Ask your developers for support. They either write you a little tool. Or they could generate a lot of curl-requests based on a query. Another option would be the AEM Groovy Console (https://github.com/OlsonDigital/aem-groovy-console). There you or your developers could write a script.
Finally you can do it one by one manually. Take a look into crx/de, which might be a little bit faster.
If you want to bulk update the page property you may use OTB Bulk Editor feature. Here is a video explaining how to use this.
There is a similar ACS tool for updating sling:resourceType property. You can extend and customize this tool if not happy with OTB feature.

Word API Custom Properties

I need some help on word add-ins
I will be programmatically creating a document and as part of that I need to add custom property (Pub_Doc_ID) to the document, as in the picture below.
I am using Word Java APIs now and could not find a way to do this job. The work flow I am targeting is very simple. Create a Document, get the Pub_Doc_Id from DB which is primary Key and assign to the document. Now primary key is attached to the document, so it will be lived with document.
Some more background :
As I mentioned earlier I am using Word APIs. I am adding text, sections, images etch. Now I need to have one connector (Pub_Doc_ID) between Doc and DB. So wanted to use custom properties. If there is any better way to do it. Then let me know.
I know how to do this in VSTO. I am looking for Word Java API.
This pub_doc_id ID then I will be using to call API's and to load task pane.
Thanks, really appreciate any help on this.
*Pub_Doc_Id : Publishing Document ID.
R/W access to custom properties is something my team is working on and would be delivered towards the end of the year.
Seems that for your scenarios you don't necessarily need to store that information as a custom property and you have a couple of alternatives in the meantime:
You can add your own customXmlPart to the doc to store this information. Here is a great example on how to use this: https://github.com/OfficeDev/Word-Add-in-Work-with-custom-XML-parts/tree/master/C%23/CustomXMLAppWeb/App
You could also store it a setting of your add in. Check out the settings object and how to store and retrieve settings: https://dev.office.com/reference/add-ins/shared/document.settings
Hope this helps!!
Thanks
You cannot presently access custom properties via the JavaScript API. They are currently working on it and have put information about proposed APIs on GitHub

TYPO3 Calendar plugin/extension. Which one to choose?

I have no clue about where to get started with my calendar plugin. Can you please suggest me if it's easy to create one from the scratch or use an existing one and modify it. If it's the later, which plugin would be better. The following are some key functionalities of my calendar:
The created events should be approved by someone (maybe an authorized group or something).
The events should be customized to be displayed only on specific pages or all the pages.
Add media library
Now, which one would be a better idea...to start a new one..or build on an existing one ? . I'm using TYPO3 6.1.0. and extension builder for creating an extension/plugin.
Thanks
The most popular calendar TYPO3 extension is cal. I think, it's the most complete one.
http://typo3.org/extensions/repository/view/cal
Currently on TER You could find versions which are compatible with TYPO3 CMS up to 6.2.99. You could or participate in its developement, or You could fork it, or You could be inspired by it's functionalities and make Your own.

Forms / structured data feature in Plone 4

We are trying to make a document-managemnet / knowledge management portal using Plone 4. We would like a forms / structured data feature in our webapp with posibility of defining forms through the web, having workflows using these forms and being able to create reports from them (preferably in some format that facilitates simple and nice looking or skinnable printouts).
Any pointers to modules, documentation and/or literature would be great. Thanks.
Dexterity in combination with collections for reporting should get you what you need.
http://plone.org/products/dexterity
PloneFormGen is a good solution for through the web creation of standalone forms but as soon as you need your form to be workflowed, reviewed inside plone or later edited and updated then a "Content Type" is normally the most appropriate way to model this inside an CMS. Dexterity is the recommended way to build content types going forward. It has the ability to create and edit content types through the web.
For more indepth information of developing a Dexterity based solution see http://plone.org/products/dexterity/documentation/manual/developer-manual
Archetypes would be an alternative way to create content types.
Collections can be used for basic through the web reports. To make this work on the new fields in your content types you'd need to make the fields usable inside collections which I'll leave out of this explanation. For more advanced reports I'd suggest a simple BrowserView which lets you use any python you want to compose your report.
The add-on http://plone.org/products/uwosh.pfg.d2c product with PloneFormGen, is going to be the best fit for your situation.
uwosh.pfg.d2c creates content objects from your PloneFormGen form submissions. You can then use it with placeful workflows to give you a custom workflow on the submission.
If you'd rather not use placeful workflows, it also allows you to specify the content type it'll save the form to so you can have a different content type, with a different workflow on every form.
Dexterity would work too, but the TTW tool is not nearly where PloneFormGen is.
Simply: http://plone.org/products/ploneformgen