Roland Häder [Tue, 24 May 2016 12:20:24 +0000 (14:20 +0200)]
again some more h:outputText for better encapsulation of messages. and it makes more sense, JSF is a WUI (web user interface) where you attach UI components to and not direct texts.
Roland Häder [Mon, 23 May 2016 13:30:19 +0000 (15:30 +0200)]
Continued with rewrite:
- introduced showFacesMessage()
- rewrote to FacesMessage and not ugly exception 500 error
- rewrote more messages + fixed form ids to naming convention
Roland Häder [Mon, 23 May 2016 09:59:19 +0000 (11:59 +0200)]
Continued:
- added Apache POI 3.4 for Excel export
- added missing i18n strings
- CSV support currently only use comma as "column" delimiter, better switch to Excel format
- these columns cannot have a double-dot on the end as the import may not work
- no need to have these JARs in WARs as you can place them on the server's proper lib path
Roland Häder [Fri, 20 May 2016 15:36:54 +0000 (17:36 +0200)]
Continued a bit:
- first @Oberserves, then final
- added simple birthday input field
- added i18n strings
- added birthday to export as well
- added observer method afterUserConfirmedAccount() to update lists for
- added javax.faces.DATETIMECONVERTER_DEFAULT_TIMEZONE_IS_SYSTEM_TIMEZONE to make sure time-zone problems are fixed
- fixed some messages, wrong stuff there
Roland Häder [Fri, 20 May 2016 10:32:12 +0000 (12:32 +0200)]
Continued with data export with PrimeFaces:
- added prime faces 5.3 to project
- added admin_contact_export.xhtml with navigation rule to export contact data (currently only CSV but e.g. Excel is easy to add)
- added missing contact i18n and export string
- added controller methods generatePhoneNumber() and generateCellphoneNumber(), if e.g. ui:fragment is used, an object id instead of the phone numbers is shown. Maybe a bug in PrimeFaces or wrong usage of ui:fragment? Sometimes a POJO property like contactFaxNumber can be null. Then this needs to be taken care of.
Roland Häder [Thu, 19 May 2016 11:42:54 +0000 (13:42 +0200)]
Continued:
- renamed adminHelper to beanHelp as this is a really generic bean helper
- renames same class/interface, too
- added JSF page for confirming accounts with optional parameter confirmKey. If this is not set, a message will be shown
- added i18n keys for above new page
- added controller bean for above page to handle the confirmation + calling proper EJB business method
Roland Häder [Fri, 13 May 2016 15:03:30 +0000 (17:03 +0200)]
Some fixes (careful with cherry-picking):
- resenEmailAddress is better, then the same validator can be used to look if the email address is registered
- set correct JNDI name for resend-link EJB
- ignored some strings for i18n
- added message for above email address field
- fixed condition check
Roland Häder [Fri, 13 May 2016 14:16:28 +0000 (16:16 +0200)]
Continued with resending confirmation links:
- added form for resending confirmation link, surely the user only knows the registered email address
- added controller (object and interface) for it
- added missing i18n strings
Roland Häder [Fri, 13 May 2016 10:03:34 +0000 (12:03 +0200)]
Continued with email address validator (cherry-pick/rename this)
- added email address validator with regex validation and checking if the contact EJB reports an exisiting account
- this validator can be used in JSF pages/templates like: validator="EmailAddressValidator"
- in addition you may want to use a simple regex validator in addition to this to prevent ugly messages being shown
- added message output for missing privacy/terms checkboxes
- added required-message for email address
Roland Häder [Fri, 13 May 2016 09:11:18 +0000 (11:11 +0200)]
Continued generally:
- moved email address (with repeat) to own templates, one for registration, one for login (change email address)
- added validator for above data
- some other fixes, e.g. wrong controller
Roland Häder [Fri, 13 May 2016 08:36:02 +0000 (10:36 +0200)]
Fix for multi-page registration:
- a contact instance is needed to check for email address as it is stored there
- so first create a "half" contact instance (no gender, ...) and then check email address
- user name can be only checked, if required
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