Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
German Tugores
How to override LocalService to save / update expando values?
April 19, 2012 2:18 PM

German Tugores

Rank: Junior Member

Posts: 33

Join Date: March 1, 2012

Recent Posts

Hi again everyone,

Now I managed to create the expando attribute in the expandotable and expandocolumn with the code I shared in my previous post, however I can't figure out how to save / update values in the hook.

I added an aui:input field and wrapper to the jsp file where I want to show the expando value to edit it like this (rutaImagen is the name of expando column in database)

1<aui:input name="ExpandoAttributeName--rutaImagen--" type="hidden" value="rutaImagen" />
2        <aui:field-wrapper >
3            <aui:input label="rutaImagen" name="ExpandoAttributeName--rutaImagen--"  type="text" />
4        </aui:field-wrapper>

As I understand it the next step would be to override the AnnouncementsEntryLocalService service with my own implementation so I put it in the

1    <service>
2        <service-type>
3            com.liferay.portlet.announcements.service.AnnouncementsEntryLocalService
4        </service-type>
5        <service-impl>
7        </service-impl>
8    </service>

But I'm stuck at this point, I suppose next I have to create my AvisosAGLocalServiceImpl class and override the methods I need right? But do I have to implement AnnouncementsEntryLocalService in my class? Or extend the AnnouncementsEntryLocalServiceBaseImpl? Besides I've seen LR javados for 6.1 for the AnnouncementsEntryLocalService, do I have to override all methods for that? I think I'll only need the add / create, delete and update methods.

Sorry if the question is a bit messy but I still don't fully understand all the classes and interfaces LR persistence model creates.