Roland Häder [Fri, 13 May 2016 08:22:45 +0000 (10:22 +0200)]
Cleanup a bit + fix:
- removed not needed assertion
- renamed variables
- if multi-page is enabled, don't create contact instance, that will be done on 2nd page
Roland Häder [Thu, 12 May 2016 16:18:23 +0000 (18:18 +0200)]
Rewritten a lot:
- introduced isUserNameRequired() which should make it sure to have registrations with no user name and password. This also includes no login area (not possible)
- the user then will get a random user name with format "userXXXXX" and a random password. So it is still possible that the "feature" login area for users can come back.
- so no "recover password" is possible, too. Therefore such links can be removed from the menu.
- introduced isMultiplePageEnabled() which is used as a "switch" between single-page and multiple-page registration
- introduced isPublicUserProfileEnabled() which is used to disabled/enable the feature "public user profiles" which is sometimes not wanted ...
- introduced isResendConfirmationLinkEnabled() which disabled the corresponding feature
- showing a "choose profile-mode" while no public user profile is enabled makes no sense ... So better "hide" this option.
- introduced general (abstract) controller Base<project-name>Controller which currently holds a method for checking if for a named controller debug mode is enabled
- renamed doRegister() to doFinishRegistration()
- removed no longer used i18n strings (they may have come back by cherry-picking)
- registration page 1/2 should be "basicly finished" now, single is also available
- index page is now jlandingpage-specific as registration page is in index.xhtml (careful, cherry-picking this!)
- added controller method doRegisterMultiPage1()
- added a lot more language strings
- renamed variables
- added context parameters for above new methods
- added needed navigation cases (careful with cherry-picking again)
- sorted imports (minor)
- fixed i18n string (usage)
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Mon, 2 May 2016 13:52:12 +0000 (15:52 +0200)]
Continued with fixes/rewrites:
- moved+renamed generic/form_personal_data.tpl contact/form_contact_data.tpl
- renamed emailAddress1 -> emailAddress + emailAddress2 -> emailAddressRepeat
- clear bean after all, so no new object is needed
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Wed, 27 Apr 2016 14:25:53 +0000 (16:25 +0200)]
Some JSF fiyxes:
- id "cellphoneLinks" removed as it happens in a loop
- sometimes user is null, then user.userContact cannot be accessed and any attempts cause a NPE
- new error message ERROR_PARAMETER_CELLPHONE_NUMBER_USER_NOT_SET added (and used)
- added div tags for better showing error messages
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Wed, 11 May 2016 14:07:42 +0000 (16:07 +0200)]
Fixed country controller:
- renamed controller name to not have confusion to
- moved hasCountries/allCountries to session-scoped bean to have full caching
Signed-off-by: Roland Häder <roland@haeder.net> Signed-off-by: Roland Häder <roland@mxchange.org>
Roland Häder [Tue, 10 May 2016 13:13:08 +0000 (15:13 +0200)]
don't forget to clear helper contact instance. When a user/recruiter has been added with a selected contact instance, it got not removed from selectableContacts list.
Roland Häder [Tue, 10 May 2016 12:16:41 +0000 (14:16 +0200)]
Continued a bit:
- don't return full list as the JSF seems to modify it ???
- always use this.someList and not allFoos()
- moved allMobileProviders() and hasMobileProviders() to regular controller as this one holds the cached list anyway
- renamed mobileController -> mobileProviderController
- call bean again instead of getting same (!) list: this fixes a bug that a lot contacts has been removed from the list
- careful cherry-picking this: recruiter-related changes are included and contact EJB added!
Roland Häder [Tue, 10 May 2016 12:02:16 +0000 (14:02 +0200)]
Continued a bit:
- moved all contact data to one place (was a bit scattered)
- no need to update cellphone data here (contact controller does it)
- added check on parameter 'user'
- added noisy debug line (contact)
Roland Häder [Fri, 6 May 2016 11:08:37 +0000 (13:08 +0200)]
Moved a lot templates areound:
- moved user-related templates out of generic folder
- moved "login user" to login/user
- moved "login recruiter" to login/recruiter
- added missing templarte when recruiter is not logged-in
Roland Häder [Fri, 6 May 2016 10:27:44 +0000 (12:27 +0200)]
No, putting these methods into admin (request-scoped) controller is not good as no caching takes place. Better put them into session-scoped controllers to have caching possible. Please cherry-pick and keep recruiter-stuff out of other projects.
Roland Häder [Fri, 6 May 2016 08:29:53 +0000 (10:29 +0200)]
Continued a bit:
- added recruiter login (very lame design, I know)
- added navigation rule
- added i18n strings
- moved back from admin -> regular controller, urgs, it is cached there for a longer time and not just on request
Roland Haeder [Thu, 5 May 2016 14:04:57 +0000 (16:04 +0200)]
re-organized pages:
- moved /user/ -> /guest/user/ as these are pages for current guest but later users
- moved /login/ -> /user/ as these are pages for current (logged-in) users
Roland Haeder [Fri, 29 Apr 2016 20:16:04 +0000 (22:16 +0200)]
The customer is now differently created, first you need to get the contact-relevant data from the contact controller, then you need to generate a customer number and attach the contact instance to it.
Method addCustomer(customer) was no need for calling external as the event does the same job.
Roland Häder [Fri, 29 Apr 2016 13:43:26 +0000 (15:43 +0200)]
Continued a bit:
- renamed method changeUserData() to editUserData() (members sorted)
- surpressed some warnings that are not being fixed
- clear() needs to be called
Roland Häder [Fri, 29 Apr 2016 13:16:16 +0000 (15:16 +0200)]
Continued with customer:
- editing customer data is "basicly finished"
- removed i18n key as this was not following convention (and redundant)
- a user entry was not found (for users more clear)
Roland Häder [Fri, 29 Apr 2016 09:46:33 +0000 (11:46 +0200)]
Continued with contacts:
- showing contact data is "basicly finished"
- introduced template admin_contact_data.tpl"
- added missing navigation cases
- contact personal data is not user - fixed
- include always gender
- added new page for deleting contact data
- added CSS class for delete buttons
- added template for administrative contact links
- added missing i18n strings
Roland Häder [Thu, 28 Apr 2016 12:17:13 +0000 (14:17 +0200)]
Continued with customers and rewrite a bit:
- page show_customer "basicly finished"
- removed double redundant i18n strings (no need)
- added customer's i18n strings (admin)
- now always handle a contact to "cellhpone templates", this is much easier and users/customers don't have cellphones/land-line or fax numbers, only contacts
- added template for administrative links for customers (similar to users)
- added missing navigation rules
Roland Häder [Thu, 28 Apr 2016 09:15:29 +0000 (11:15 +0200)]
Continued with customer:
- added converter for customerId <-> Customer object
- used this in administrative customer pages
- added method copyCustomerToController()
- added getter/setter for customer in helper bean
- some messages fixed (copy-paste)
Roland Häder [Wed, 27 Apr 2016 15:40:49 +0000 (17:40 +0200)]
Continued:
- the email address is now optional (nullable), so updated all i18n strings
- moved data check to createContactInstance()
- added message about minimum data
Roland Häder [Wed, 27 Apr 2016 15:01:22 +0000 (17:01 +0200)]
Continued with contacts:
- added method addContact()
- introduced isSameContactFound() which checks if the given contact can be found in a list.
- this method can later be moved to ContactUtils to become generic.
- commented out noisy System.out messages
- removed no longer used logger messages
Roland Häder [Wed, 27 Apr 2016 14:25:53 +0000 (16:25 +0200)]
Some JSF fiyxes:
- id "cellphoneLinks" removed as it happens in a loop
- sometimes user is null, then user.userContact cannot be accessed and any attempts cause a NPE
- new error message ERROR_PARAMETER_CELLPHONE_NUMBER_USER_NOT_SET added (and used)
- added div tags for better showing error messages
Roland Häder [Wed, 27 Apr 2016 12:15:17 +0000 (14:15 +0200)]
Continued with observers:
- added afterAdminAddedCustomer() to add contact to list
- commented out noisy debug lines
- clear() is still needed for request-scoped to remove the form data
- no need for explicit clear() call as the observer does it
- removed some commented out log messages
Roland Häder [Wed, 27 Apr 2016 10:02:05 +0000 (12:02 +0200)]
Continued a bit:
- added additional check if the contact is really in the selectableContacts list
- need to call EJB business method linkCustomer() (like for users, linkUser())
- customers don't have user profiles: customer != user