<commit_before>Important changes from 1.4.3 => 1.5
============================================================
Passwords should be set with a project.ini->salt. Salt is now a required project setting!
The table gems__staff is split into gems__staff, gems__user_logins with generic login data and gems__users_passwords containing db stored password information.
GemsEscort->afterLogin(), ->afterLogout() and ->loadLoginInfo(0 are now all handled by Gems_User_UserDefinitionInterface objects.
The table gems__user_ids provides unique and non-sequential user ids accross gems__staff and gems__respondents.
The gems__respondent.grs_bsn has been renamed to grs_ssn, to make the code more international.
MailController is now called MailTemplateController.
EmailController is now called CronController (with stub for compatibility).
ModelAbstract now declares an protected _load instead of a public load abstract, for implementation of setOnLoad() functions, check your own Models for overloading load() or loadXX() functions.

Important changes from 1.4.2 => 1.4.3
============================================================
 * gtr_organisations renamed to gtr_organizations
 * table gems__countries is no longer in use

Important changes from 1.4.1 => 1.4.2
============================================================
 * To have an autosubmit form it is enough now to just use $form->setAutoSubmit($href, $targetId)
 * Introduced Gems_FormattedData, which takes a model and array of data and applies all formatting rules to the data
   (see export for more info)
 * The menu is reorganised and some items no longers have privileges assigned to them. Be careful with project menus!
 * Tooltip decorator now uses jQuery icon instead of an image
 * Print view of tab-forms now output the tab-titles for better readability, this introduced the class print-only

Important changes from 1.4 => 1.4.1
============================================================
 * Menu containers no longer have a privilege, this could have impact on custom menu's searching for a container.
 * Default layouts have changed to make displaying the project name optional. To display the project name
   add the following line to the project.ini:
       layoutPrepare.projectName = header


============================================================
Library changes for 1.3 => 1.4

- New track engine, all code from Gems_Source and Gems_Token to Gems_Tracker
- Moved snippets from MUtil_Controller to their own top level package MUtil_Snippets, this allows snippets to load snippets
- The backwards compatible Gems_Menu extensions Gems_Menu->getParameterSource() and Gems_Menu->getMenuList() are easier to use than their predecessors.

Some examples:

Checking for token completion:
Old:
    $tokenLibrary = Gems_Tokens::getLibrary($this->db);
    $tokenLibrary->checkAnswers($data['grs_id_user'], $this->session->user_id);
New:
    $this->loader->getTracker()->processCompletedTokens($data['grs_id_user'], $this->session->user_id);

Getting the survey questions:
Old:
    $source     = Gems_Sources::getBySurveyId($this->gsu_id);
    $this->data = $source->getSurveyQuestions($this->gsu_id, $this->locale);
New:
    $survey = $this->loader->getTracker()->getSurvey($this->gsu_id);
    $this->data = $survey->getQuestionInformation($this->locale->getLanguage());

Getting answers:
Old:
    Gems_Tokens::getAnswers($currentToken['gto_id_token'], $first));
New:
    $token = $this->loader->getTracker()->getToken($currentToken['gto_id_token']);
    $token->getRawAnswers();
or formatted:
    $model = $token->getSurveyAnswerModel($this->locale->getLanguage());
    $model->applyRequest($this->request);
    $model->loadFirst();
    etc...

getting a token model:
Old:
    $this->loader->getModels()->getTokenModel('T' == $this->trackType);
New for generic token model:
    $this->loader->getTracker()->getTokenModel();
Or for token specific detail show & edit:
    $this->loader->getToken('xxxx-xxxx')->getModel();

Getting a respondent model:
Old:
    $model = GemsEscort::getInstance()->getLoader()->getModels()->getTrackModel('TrackModel');
New:
    $model = $model = $this->loader->getTracker()->getTrackModel();

New changes directories:
    application/controllers/snippets => application/snippets
    library/Gems/controllers/snippets => library/Gems/snippets
    library/Gems/classes/MUtil/Controller/snippets => library/Gems/classes/MUtil/Snippets/Standard

Changes to snippet classes:
    MUtil_Controller_SnippetAbstract => MUtil_Snippets_SnippetAbstract
    MUtil_Controller_SnippetInterface => MUtil_Snippets_SnippetInterface
    MUtil_Controller_TabSnippetAbstract => MUtil_Snippets_TabSnippetAbstract
    etc...
    MUtil_Controller_*Snippet* => MUtil_Snippets_*Snippet*
But also:
    Gems_Controller_Snippets_* => Gems_Snippets_*

Replaced individual snippets
    SingleAnswerTableSnippet => AnswerModelSnippet
    AnswersTableSnippet => TrackAnswersModelSnippet

<commit_msg>Changelog for ticket #43: Flexible user password constraints:<commit_after>Important changes from 1.4.3 => 1.5
============================================================
Passwords should be set with a project.ini->salt. Salt is now a required project setting!
Setting rules for user passwords has changed and has become more powerfull, unless you do not set them.
The table gems__staff is split into gems__staff, gems__user_logins with generic login data and gems__users_passwords containing db stored password information.
GemsEscort->afterLogin(), ->afterLogout() and ->loadLoginInfo(0 are now all handled by Gems_User_UserDefinitionInterface objects.
The table gems__user_ids provides unique and non-sequential user ids accross gems__staff and gems__respondents.
The gems__respondent.grs_bsn has been renamed to grs_ssn, to make the code more international.
MailController is now called MailTemplateController.
EmailController is now called CronController (with stub for compatibility).
ModelAbstract now declares an protected _load instead of a public load abstract, for implementation of setOnLoad() functions, check your own Models for overloading load() or loadXX() functions.

Important changes from 1.4.2 => 1.4.3
============================================================
 * gtr_organisations renamed to gtr_organizations
 * table gems__countries is no longer in use

Important changes from 1.4.1 => 1.4.2
============================================================
 * To have an autosubmit form it is enough now to just use $form->setAutoSubmit($href, $targetId)
 * Introduced Gems_FormattedData, which takes a model and array of data and applies all formatting rules to the data
   (see export for more info)
 * The menu is reorganised and some items no longers have privileges assigned to them. Be careful with project menus!
 * Tooltip decorator now uses jQuery icon instead of an image
 * Print view of tab-forms now output the tab-titles for better readability, this introduced the class print-only

Important changes from 1.4 => 1.4.1
============================================================
 * Menu containers no longer have a privilege, this could have impact on custom menu's searching for a container.
 * Default layouts have changed to make displaying the project name optional. To display the project name
   add the following line to the project.ini:
       layoutPrepare.projectName = header


============================================================
Library changes for 1.3 => 1.4

- New track engine, all code from Gems_Source and Gems_Token to Gems_Tracker
- Moved snippets from MUtil_Controller to their own top level package MUtil_Snippets, this allows snippets to load snippets
- The backwards compatible Gems_Menu extensions Gems_Menu->getParameterSource() and Gems_Menu->getMenuList() are easier to use than their predecessors.

Some examples:

Checking for token completion:
Old:
    $tokenLibrary = Gems_Tokens::getLibrary($this->db);
    $tokenLibrary->checkAnswers($data['grs_id_user'], $this->session->user_id);
New:
    $this->loader->getTracker()->processCompletedTokens($data['grs_id_user'], $this->session->user_id);

Getting the survey questions:
Old:
    $source     = Gems_Sources::getBySurveyId($this->gsu_id);
    $this->data = $source->getSurveyQuestions($this->gsu_id, $this->locale);
New:
    $survey = $this->loader->getTracker()->getSurvey($this->gsu_id);
    $this->data = $survey->getQuestionInformation($this->locale->getLanguage());

Getting answers:
Old:
    Gems_Tokens::getAnswers($currentToken['gto_id_token'], $first));
New:
    $token = $this->loader->getTracker()->getToken($currentToken['gto_id_token']);
    $token->getRawAnswers();
or formatted:
    $model = $token->getSurveyAnswerModel($this->locale->getLanguage());
    $model->applyRequest($this->request);
    $model->loadFirst();
    etc...

getting a token model:
Old:
    $this->loader->getModels()->getTokenModel('T' == $this->trackType);
New for generic token model:
    $this->loader->getTracker()->getTokenModel();
Or for token specific detail show & edit:
    $this->loader->getToken('xxxx-xxxx')->getModel();

Getting a respondent model:
Old:
    $model = GemsEscort::getInstance()->getLoader()->getModels()->getTrackModel('TrackModel');
New:
    $model = $model = $this->loader->getTracker()->getTrackModel();

New changes directories:
    application/controllers/snippets => application/snippets
    library/Gems/controllers/snippets => library/Gems/snippets
    library/Gems/classes/MUtil/Controller/snippets => library/Gems/classes/MUtil/Snippets/Standard

Changes to snippet classes:
    MUtil_Controller_SnippetAbstract => MUtil_Snippets_SnippetAbstract
    MUtil_Controller_SnippetInterface => MUtil_Snippets_SnippetInterface
    MUtil_Controller_TabSnippetAbstract => MUtil_Snippets_TabSnippetAbstract
    etc...
    MUtil_Controller_*Snippet* => MUtil_Snippets_*Snippet*
But also:
    Gems_Controller_Snippets_* => Gems_Snippets_*

Replaced individual snippets
    SingleAnswerTableSnippet => AnswerModelSnippet
    AnswersTableSnippet => TrackAnswersModelSnippet


{'fraction_non_alphanumeric': 0.1461351482741857, 'fraction_numerical': 0.005444822557122022, 'mean_word_length': 4.938799076212471, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 143, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '708679', 'n_tokens_mistral': 2931, 'n_tokens_neox': 2725, 'n_words': 875}