Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Core Register reconfigurability #665

Open
allan-on opened this issue Oct 13, 2020 · 0 comments · Fixed by #654 · May be fixed by #646 or #648
Open

Add Core Register reconfigurability #665

allan-on opened this issue Oct 13, 2020 · 0 comments · Fixed by #654 · May be fixed by #646 or #648
Assignees

Comments

@allan-on
Copy link
Contributor

allan-on commented Oct 13, 2020

Current register implementation requires extending BaseRegister Views (i.e.Activity & Fragment classes), Models and Presenter methods.

  • This results in copying over implementations in whichever module a register is being introduced in.
  • Overriding a specific register layout requires more effort in changing the base implementation because things like the ViewHolders are coupled as inner classes in a RegisterProvider

To allow building registers even faster, we should provide a generic implementation (with basic defaults) and have elements of the register configurable.
To allow for this the following are to be configurable:

  • Common functionality in all the different register implementations e.g. Family/Child be defined in an Activity/Register contract. This would be things like startFormActivity or saveForm
  • Support the following as configurations:
    • Register/ Module Metadata
    • Row options - Allow custom row layouts and columns population
    • ViewHolder - Not having it as an inner class and also provide a default
    • RegisterProvider - use row options to provide the row functionality
    • RegisterQueryProvider - Providing count, filter & sort queries etc
      These configs will be specified in a builder pattern and with defaults provided to render a generic register.
  • Have a ModuleConfiguration class which will also include:
    • Register title
    • Enabling/disabling the bottom nav
    • Module form processor
    • ConfigurableViewsLibrary
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment