Roland Häder [Thu, 11 Aug 2016 10:48:48 +0000 (12:48 +0200)]
Continued with lock/unlock user: (cherry-pick)
- fired event after user account is locked/unlocked
- the fired event can later be observed for updating user lists
Roland Häder [Thu, 11 Aug 2016 09:44:12 +0000 (11:44 +0200)]
Continued with error messages: (please cherry-pick)
- added ADMIN_ prefix
- added message for locking a locked user and unlocking a already unlocked (confirmed) account
- added parameters
Roland Häder [Thu, 11 Aug 2016 09:33:51 +0000 (11:33 +0200)]
Fixed: (please cherry-pick)
- rendered should not be used on command buttons or any form tags (such as input tags) as it makes it impossible that the data is being transfered to the backing bean.
Roland Häder [Wed, 10 Aug 2016 15:40:26 +0000 (17:40 +0200)]
Continued with cell phone unlink: (please cherry-pick)
- added error container for cell phone data template
- fixed call of unlinkCellphoneDataFromContact() as a checked exception is thrown and 2nd parameter added
Roland Häder [Wed, 10 Aug 2016 14:51:46 +0000 (16:51 +0200)]
Continued with cell phone unlink: (please cherry-pick)
- added new controller for contact-cellphone administrative things
- added new controller method unlinkCellphoneContactData() which unlinks cell phone instance from a contact
- added navigation rule admin_contact_cellphone_unlink.xhtml -> admin_show_contact
- added template admin_contact_data_mini.tpl
- removed phoneBean from controller as it is not being used there
- removed duplicated interface "constant"
- added missing i18n strings
- added CSS class unlink_button
- fixed "bean (controller)" to "controller (bean)"
Roland Häder [Wed, 10 Aug 2016 12:58:13 +0000 (14:58 +0200)]
Continued with cell phone: (please cherry-pick)
- add template parameter showAdminLinks which hides all administrative links in admin_cellphone_data.tpl template
- added missing i18n string
- removed CSS property from data_label as it caused deformation (better fix it with an additional div/span tag)
Roland Häder [Wed, 10 Aug 2016 10:32:41 +0000 (12:32 +0200)]
Continued a bit: (please cherry-pick)
- implemented controller (bean) method deleteCellphoneData() with event being fired after the cell phone has been deleted. This can be used for later event logging or what ever.
- implemented form for deleting cell phone data
- fixed id for commandButton (is edit_cellphone)
- added missing i18n strings
Roland Häder [Tue, 9 Aug 2016 15:36:29 +0000 (17:36 +0200)]
Continued with some rewrites: (please cherry-pick)
- moved cellPhoneNumber to beanHelper as this is the right place
- introduced copyCellphoneNumberToController() and called it in edit template for having all editable data being set in backing bean
Roland Häder [Tue, 9 Aug 2016 15:06:06 +0000 (17:06 +0200)]
Continued with cellphone number edit: (please cherry-pick)
- no, the data cannot be set in the object, it needs to be set in controller (backing bean, don't forget this)
- made both fields required
- if nothing has changed, nothing needs to be updated (check both, mobile provider and number)
- added missing i18n strings
- renamed form id form_edit_phone -> form_edit_cellphone
Roland Häder [Tue, 9 Aug 2016 14:04:04 +0000 (16:04 +0200)]
Continued with cellphone data: (please cherry-pick)
- added form template for editing cellphone data (yes, generic)
- renamed cellPhone -> cellPhoneNumber
- CSS class table_medium needs to be a bit bigger
- implemented method editCellphoneData()
- including fireing new event
- fixed i18n strings
Roland Häder [Tue, 9 Aug 2016 10:51:04 +0000 (12:51 +0200)]
Continued with cell phone: (please cherry-pick)
- completed listing of all cellphone number data
- renamed method to allCellphoneNumbers() to have it nicer named
- renamed admin_contact_cellphone_list.xhtml to admin_cellphone_list.xhtml as this is generic
- removed _contact from cellphone navigation rules
- introduced new general phone controller (not administrative) with application-scope to have all cellphone, land-line and fax numbers being cached
- moved proper attributes (fields) and methods to that new controller
- added missing navigation case for admin_cellphone_list.xhtml
- added missing i18n strings
Roland Häder [Tue, 9 Aug 2016 08:34:22 +0000 (10:34 +0200)]
Continued with phone numbers: (please cherry-pick)
- introduced updateContactPhoneNumbers() which updates all cellphone, land-line fax number entries in this controller's list
- added missing lists for land-line and fax numbers
- added uniqueAddFooNumber() for uniqly adding cellphone, land-line and fax numbers
Roland Häder [Mon, 8 Aug 2016 15:43:11 +0000 (17:43 +0200)]
Continued with splitting/cleanup: (please cherry-pick)
- removed all boolean hasFoos() methods as isEmpty() works the same way
- got rid of many Collections.unmodifiableList() calls as they may confuse the developer, please watch out!
- splitted contact's special phone stuff out to own controller (bean)
Roland Häder [Mon, 8 Aug 2016 14:51:58 +0000 (16:51 +0200)]
Continued with rewrite: (please cherry-pick)
- renamed some admin_contact_cellphone_???.xhtml to admin_cellphone_???.xhtml as they are generic enough (not depending on contact)
- moved phone-contact stuff to adminContactController
- renamed i18n strings properly
- no need to have contact in adminPhoneController, better is the obvious one: beanHelper
- started with listing all cell phone numbers (similar JSF will follow for land-line and fax numbers)
- the contact stuff in adminPhoneHelper was deprecated anyway
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Mon, 8 Aug 2016 13:22:38 +0000 (15:22 +0200)]
Please rename:
- this is no longer a contact's land-line/cellphone number controller, it only handles the number data itself
- unlink/link with contact or employees or anything must be done in that specific controller
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Fri, 10 Jun 2016 12:55:14 +0000 (14:55 +0200)]
Rewrites: (please cherry-pick also)
- rewrote templateType to baseTemplatePathName which allows more "complex" paths than just simple
- imprint, terms and privacy can now make usage of that new variable and don't need to be shown in new browser window
Roland Häder [Mon, 6 Jun 2016 14:02:42 +0000 (16:02 +0200)]
Continued with rewrites:
- moved selectableContacts to contact controller, makes more sense
- fixed template for above
- introduced isGenderRequired() to make difference between general and administrative contact controller
- added new context parameter for above method
- fired event when a new user account has been linked with existing contact data
- the other event (added user) is being fired now on else path
- No more need for afterAdminAddedContact() in general user controller
Roland Häder [Mon, 11 Jul 2016 16:03:32 +0000 (18:03 +0200)]
Closed internal TODO: (please cherry-pick this)
- house numbers may have extensions like 'a', so the full number can be
e.g. '123a' which should be better splitted into number and extension
- expanded templates for above stuff
- expanded controllers for this
- added missing i18n strings
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Fri, 10 Jun 2016 10:03:45 +0000 (12:03 +0200)]
New "feature" controller introduced: (please cherry-pick this)
- no more tons of separate and same-looking methods, just one central and very flexible method isFeatureEnabled()
- renamed all context parameters
- added features "imprint", "terms" and "privacy"
Roland Häder [Sat, 6 Aug 2016 10:26:59 +0000 (12:26 +0200)]
Continued with rewrites: (please cherry-pick)
- the contact phone controller becomes a generic phone controller (see jcontacts-business-core)
- marked contact-related stuff in it as deprecated
- renamed it's JSF name to adminPhoneController
- all phone instances are being set by beanHelper's copyUserToController() method
- private method setPhoneInstances() introduced
- rewrote all parameters that cannot be auto-completed by IDE to beanHelper and phone controller
- added missing i18n string(s)
Roland Häder [Sat, 6 Aug 2016 08:45:35 +0000 (10:45 +0200)]
Fixed house number extension: (please cherry-pick)
- the contact's house number extension was not exposed in template
- and also not cleared in clear() method
Roland Häder [Sat, 6 Aug 2016 08:15:05 +0000 (10:15 +0200)]
Please cherry-pick:
- Well, ui:fragment is according to my trainer not right. What I want here is a navigation to edit/delete/lock/unlock pages depending on the user's account status.
- If the account status is UNCONFIRMED, currently only show edit and delete
- If it is CONFIRMED, add a link to "lock" page.
- If it is LOCKED, add a link to "unlock" page.
- Currently I do this with ui:fragment because it seems to be the only JSF tag that is NOT rendering it's body when the rendered attribute resolves to false.
- If you can find a drop-in replacement, please notify me at roland[AT]mxchange[DOT]org
- And please keep in mind that c:if or anything like that is JSP which is being executed on an other life-cycle step than JSFs.
Roland Häder [Sat, 6 Aug 2016 07:55:12 +0000 (09:55 +0200)]
Continued a bit: (please cherry-pick)
- don't wrap command buttons in rendered="" conditions and not with ui:fragment (please name me a full replacement for all the other cases where I'm using it)
- this makes it impossible for the button's action (controller method) being executed as this depends on the life-cycle of the JSF
- it may work in viewing the JSF page but not when you submit it.
- rewrote parameter 'user' to beanHelper.user as this was already being used
- show proper lock/unlock link depending on user's account status
- added navigation rule for new user lock JSF page
Roland Häder [Fri, 5 Aug 2016 15:42:16 +0000 (17:42 +0200)]
Continued with cleanup: (please cherry-pick)
- enumerations cannot be compared in JSF until JSF 3.0, so compare only the string, thanks to BalusC@stackoverflow
- a lot CSS cleanups, such as correct padding and sizes
- replaced table_row -> para
- removed table_left/right_25/75 (was not working somewhy correctly)
Roland Häder [Fri, 5 Aug 2016 13:02:55 +0000 (15:02 +0200)]
Continued with locking user accounts: (please cherry-pick)
- added user to (by JSF) called methods as he this user needs to be locked
- implemented lockUserAccount() including calling EJB (which still needs implementing)
- this method redirects back to the user's admin-profile page
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Thu, 4 Aug 2016 16:10:38 +0000 (18:10 +0200)]
Continued with user locking: (please cherry-pick)
- added form for un-/locking users
+ it shows buttons depending on if the user is lock/unlocked or unconfirmed
+ if the user is unconfirmed, a text is shown (maybe not wanted, easy to rewrite to a "feature")
+ if the user is locked, the reason is shown
- added lock reason to controller (bean)
- added missing 18n strings
Roland Häder [Wed, 3 Aug 2016 14:39:23 +0000 (16:39 +0200)]
Continued: (please cherry-pick)
- rewrote fetching context parameter with protected methods to have this code encapsulated
- used this for feature controller
- added new user password-change controller (+ interface) to change user's password
- used it in template to avoid monolithic super controllers ...
- added missing i18n strings
- used password-change event for updating user's password history
- added new context parameter for "change_user_password" feature
- added new context parameter for maximum checked passwords
- fixed redirect outcomes
Roland Häder [Wed, 3 Aug 2016 09:54:23 +0000 (11:54 +0200)]
Please cherry-pick and later rewrite:
- having the current user in his own visuble users list makes no sense
- maybe make a new application-scoped controller which maintains such lists
Roland Häder [Tue, 2 Aug 2016 17:00:04 +0000 (19:00 +0200)]
Continued with fixing: (please cherry-pick)
- introduced uniqueAddContact() which uniquely adds contact to controller's list(s) which prevents double-listing
- also added missing call of above method after user registration
- introduced uniqueAddUser() which uniquely adds user to controlleräs list(s)
- used above method heavily
Roland Häder [Tue, 2 Aug 2016 14:07:45 +0000 (16:07 +0200)]
Continued a bit: (please cherry-pick)
- variable was not fully renamed, fixed
- renamed countryI18nkey -> countryI18nKey
- fixed name of context property (was shortended)
Roland Häder [Tue, 2 Aug 2016 09:25:04 +0000 (11:25 +0200)]
Continued a bit: (please cherry-pick)
- that the user must change password enforced by administrator may be not wanted everywhere, so better make it as a feature that can be disabled per project
- ignored some strings for i18n
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Tue, 2 Aug 2016 08:42:08 +0000 (10:42 +0200)]
Continued a bit: (please cherry-pick)
- sorted members
- cleared also new flag in clear() method
- set flag before the user instance is being submitted to EJB
Roland Häder [Wed, 1 Jun 2016 08:38:54 +0000 (10:38 +0200)]
Continued a bit:
- added resend_done.xhtml with using message_box.tpl
- added navigation rule for above
- used more h:outputText (remember that this is a WUI)
- removed old-lost index.xhtml (user login area)
- added i18n strings