[ 
http://mifosforge.jira.com/browse/MIFOS-2866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=57544#action_57544
 ] 

Udai Gupta commented on MIFOS-2866:
-----------------------------------

Fixed localization for RankOfDay and WeekDay at r17232 in trunk.
- Using MessageLookupMessages.properties for key-value map

Now we have a pattern to replace non-customizable Entities with Enum.

> Replace WeekDaysEntity and RankOfDaysEntity with enums
> ------------------------------------------------------
>
>                 Key: MIFOS-2866
>                 URL: http://mifosforge.jira.com/browse/MIFOS-2866
>             Project: mifos
>          Issue Type: Improvement
>          Components: Misc
>    Affects Versions: Release 1.5
>            Reporter: Udai Gupta
>            Assignee: Udai Gupta
>             Fix For: Marie E
>
>
> WeekDaysEntity and RankOfDaysEntity can be replaced with enums as. 
> - No customization is allowed in these entities 
> - These entities represent concepts which is unchangeable. 
> - FiscalCalendarRules already has utility methods for replacing logic around 
> WeekDaysEntity like workingdays and startingday
> Why have table for the mapping of "weekdays" and "rank of day" when we are 
> indirectly doing it using enum.
> legacy Localization (using lookup tables) can replaced with new property 
> files based localization for these entities. Initially default localization 
> should be enough.
> This change will remove the need of expensive/unnecessary join operation with 
> weekDays and RankOfDays on retrieval of MeetingRecurrence and LoanAccount 
> from hibernate layer.
> It will simplify the code, mapping existing values for WeekDay an RankOfDay 
> in entities like MeetingRecurrence and LoanAcount, hence there will be change 
> at database level
> One database upgrade would be required to dropping week_of_day_master and 
> rank_of_days_master and FKs. This upgrade is completely independent of the 
> work that would be required to replace these entities with enums.
> Later in future we can replace values in table(related to MeetingRecurrence 
> and LoanAcount) like
> 1 to MONDAY
> 2 to TUESDAY
> MySQL varchar or Enum type to make database more readable.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://mifosforge.jira.com/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
_______________________________________________
Mifos-issues mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mifos-issues

Reply via email to