dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #00752
Re: [Branch ~dhis2-devs-core/dhis2/trunk] Rev 193: Easy help implementation. This implementation will bring up popup with content related to particu...
> I have a few questions:
>
> - Where are the "localization lang properties files" supposed to be
> located?
> Those unde dhis-web-commons
>
OK. Could you add them? And add some "sample" help properties so that people
can see how it is done?
>
> - How are these properties supposed to be loaded in the HelpService object?
> <p>$i18n.getString( $helpService.getHeader() )</p>
> <p>$i18n.getString( $helpService.getContent() )</p>
>
Yes, but that is for displaying the content. I was wondering how the
properties are loaded from the properties file and into the HelpService /
HelpContent object...?
>
>
> - There is a typo in your reponseSuccess.vm file name.
> Yes, it is bare copy from Tri's work on GIS2 module, later I dicovered this
> too.
>
OK. Since we are renaming anyway, could it be called helpPopup.vm or
something more descriptive?
>
>
> - The view help action class defines a result for ERROR to be
> responseError.vm. This file does not exist and the action class does not
> have this result.
> Yes, it is missing as in Tri's module. Normally system provides its own
> error message in case. We can remove that from action declaration.
>
OK.
>
>
> - The HelpService looks to me more of a POJO as there is no logic in there.
> If it is we could rename it to HelpContent. If it is a service it should
> have an interface.
> Correct, it is simplest POJO passed as action result, but followed existing
> convention. HelpContnent is good name for it, even this class could exists
> next to Action itself or java.util.List of Strings could be used too.
>
OK. The location of the file is just fine. I suggest we instantiate this
object directly in the help action class, I think using dependency injection
is a little overkill...
Follow ups
References