juntagrico / juntagrico-billing

GNU Lesser General Public License v3.0
3 stars 2 forks source link

Setting to disable user bills view #3

Closed motu55 closed 4 years ago

motu55 commented 4 years ago

it should be possible to toggle the user bill view so that one can use the bookkeeping toll wihtout exposing the bills to the user

samuel-iseli commented 4 years ago

Implemented by linking the already existing "BILLING" setting (see juntagrico.config) to the billing_user_menu template.

motu55 commented 4 years ago

move the billing setting into this extension since it is dead code there. Also the setting should be more meaningfull since the billing setting was an all or nothing setting

samuel-iseli commented 4 years ago

Would you extend the config template-tag in juntagrico to support per app registered config classes? Or should I implement a specific billing-config template-tag for use in the menu template? this would be possible without changes in juntagrico

samuel-iseli commented 4 years ago

Decided to extend the config template-tag and add the possibility for addon apps to register their own Config classes (see juntagrico/juntagrico#272 ). Changed the existing properties on the juntagrico_billing Config class to use the mechanisms provided by juntagrico.config. The new setting is now called bills_usermenu ##(BILLS_USERMENU).