Commit cacb0b22 authored by Arnaud Pauget's avatar Arnaud Pauget
Browse files

Merge branch 'Support/2.7.X' into 'master'

Support/2.7.x

See merge request !669
parents 630b4feb 992b5ee8
Pipeline #12337 failed with stages
in 42 seconds
# CHANGELOG
## Version 2.7.4
- `Fixed` Mauvaise ventilation par profil d'archive et service producteur dans l'onglet statistique
- `Fixed` Impossibilité de sauvegarder des métadonnées de type datetime via l'écran
- `Fixed` Champs obligatoires n'apparaissent plus lors de l'ajout/modification des métadonnées
- `Fixed` Mauvais retour lors de la recherche sur les champs description
- `Changed` Modification de l'utilisateur attribué lors de la création du schéma medona
## Version 2.7.3
- `Fixed` Actualisation lors du changement d'organisation après connexion.
- `Added` Prise en compte de l'ajout d'une référence à une archive parente lors du versement d'un bordereau MADES.
......@@ -25,7 +32,7 @@
- `Fixed` Calcul de la prochaine exécution mêmeen cas d'erreur dans le planificateur de tâches.
- `Fixed` Affichage du compte de service en charge d'exécuter la tâche dans le planificateur de tâches.
- `Fixed` Restauration du fichier permettant la génération de la doc OPENAPI.
- `Fixed` Correction du bug de déconnexion intempestive lors du changement d'organisation d'appartenance.
- `Fixed` Correction du bug de déconnexion intempestive lors du changement d'organisation d'appartenance.
- `Fixed` Amélioration de la détection de l'algorithme de hash sur les bordereaux externes.
- `Fixed` Correction du bug lors de la modification des paramètres d'un cluster de stockage.
- `Fixed` Correction de l'affichage de la prévisualisation de certains PDF.
......
2.7.3
\ No newline at end of file
2.7.4
......@@ -280,11 +280,11 @@ class Document extends \dependency\xml\Document
$this->addScript("/public/js/datePicker/bootstrap-datepicker.js"); //min version does not exists
// monment
// $this->addScript("/public/js/moment_2.14.1/moment.js");
$this->addScript("/public/js/moment_2.14.1/moment.min.js");
$this->addScript("/public/js/moment_2.14.1/moment.js");
//$this->addScript("/public/js/moment_2.14.1/moment.min.js");
// $this->addScript("/public/js/dateTimePicker/bootstrap-datetimepicker.js");
$this->addScript("/public/js/dateTimePicker/bootstrap-datetimepicker.min.js");
$this->addScript("/public/js/dateTimePicker/bootstrap-datetimepicker.js");
// $this->addScript("/public/js/dateTimePicker/bootstrap-datetimepicker.min.js");
$this->addScript("/public/js/csrf/csrfprotector.js");//min version does not exists
......@@ -346,7 +346,7 @@ class Document extends \dependency\xml\Document
public function addContent($content, $container = false)
{
$contentFragment = $this->addFragment($content);
if (!$container) {
$container = $this->getContainer();
}
......
......@@ -196,7 +196,7 @@ class Statistics
foreach ($directStats as $groupBy => $result) {
$groupByFound = false;
for ($i = 0; $i < count($stats); $i++) {
if ($stats[$i][$filter] == $groupby) {
if ($stats[$i][$filter] == $groupBy) {
if ($resultType == 'sum') {
$result1 = floatval(str_replace(" ", "", $stats[$i][$resultType]));
$result2 = floatval(str_replace(" ", "", $result));
......@@ -716,7 +716,7 @@ EOT;
? ' LEFT JOIN "recordsManagement"."archivalProfile" "archivalProfile"
ON "archivalProfile"."reference" = "event"."eventInfo"::json->>10'
: ' INNER JOIN "organization"."organization" "organization"
ON "organization"."registrationNumber" = "event"."eventInfo"::json->>6';
ON "organization"."registrationNumber" = "event"."eventInfo"::json->>4';
}
$query = 'SELECT '.($groupBy ? $selectCondition . ' AS "'.$groupBy.'", ' : '').'SUM(CAST(COALESCE(NULLIF("event"."eventInfo"::json->>'.$jsonSizeColumnNumber.', \'\'), \'0\') AS INTEGER))
......@@ -766,7 +766,7 @@ EOT;
? ' LEFT JOIN "recordsManagement"."archivalProfile" "archivalProfile"
ON "archivalProfile"."reference" = "event"."eventInfo"::json->>10'
: ' INNER JOIN "organization"."organization" "organization"
ON "organization"."registrationNumber" = "event"."eventInfo"::json->>6';
ON "organization"."registrationNumber" = "event"."eventInfo"::json->>4';
}
$query = 'SELECT '.($groupBy ? $selectCondition . ' AS "'.$groupBy.'", ' : '').'COUNT("event"."eventId")
......
DROP SCHEMA IF EXISTS "medona" CASCADE;
CREATE SCHEMA "medona"
AUTHORIZATION postgres;
CREATE SCHEMA "medona";
-- Table: "medona"."archivalAgreement"
......
......@@ -222,12 +222,21 @@ class log implements archiveDescriptionInterface
}
}
if (!is_null($description)) {
$queryString .= $description;
}
$archiveController = \laabs::newController('recordsManagement/archive');
$archives = [];
$sortBy = ">fromDate";
$logs = $this->sdoFactory->find("recordsManagement/log", $queryString, [], $sortBy, 0, $maxResults);
try {
$logs = $this->sdoFactory->find("recordsManagement/log", $queryString, [], $sortBy, 0, $maxResults);
} catch (\Exception $e) {
return [];
}
foreach ($logs as $log) {
try {
......
......@@ -115,7 +115,8 @@ class welcome
$archiveDescriptions = \laabs::callService('recordsManagement/archivalProfile/readByreference_reference_', $archivalProfile->reference)->archiveDescription;
$archivalProfiles[$key]->archiveDescription = $archiveDescriptions;
$archivalProfiles[$key]->searchFields = [];
foreach ($archivalProfile->archiveDescription as $archiveDescription) {
foreach ($archivalProfile->archiveDescription as $k => $archiveDescription) {
$archivalProfiles[$key]->archiveDescription[$k]->readonly = $archiveDescription->isImmutable;
switch ($archiveDescription->descriptionField->type) {
case 'text':
case 'name':
......
......@@ -238,6 +238,8 @@ input:invalid {
addArchiveDescription : function(archiveDescription) {
var descriptionField = archiveDescription.descriptionField;
descriptionField.required = archiveDescription.required;
descriptionField.readonly = archiveDescription.readonly;
var target = $("#archivalProfileFields");
var formGroup = Metadata.getFormGroup(descriptionField);
target.append(formGroup);
......@@ -370,7 +372,6 @@ input:invalid {
field.attr('placeholder', $('#date_text').text());
parent.append(field);
if (descriptionField.format == 'datetime') {
field.data('format', 'datetime');
field.datetimepicker(dateTimePickerParams);
......@@ -932,8 +933,8 @@ input:invalid {
field = target.find("input");
if (field.data('format') == 'datetime') {
data = data.replace('T', ' ');
field.data('DateTimePicker').format('YYYY-MM-DD HH:mm:ss');
field.data('DateTimePicker').date(data)
field.data('DateTimePicker').format('YYYY-MM-DD HH:mm:ss');
} else {
data = new Date(data).toLocaleDateString("[?merge locale ?]").replace(/\//g, "-");
field.datepicker('setDate', data);
......
......@@ -452,7 +452,6 @@
NewArchive = {
loadImportForm: function(e, profileMetadata) {
console.trace();
$('#folderContents').addClass('hide');
trigger('newArchiveForm.recordsManagement', [profileMetadata, ArchiveFolderList.orgRegNumber, ArchiveFolderList.folderId, e.data('parent-archive-id'), e.data('parent-archive-name')]);
}
......
......@@ -328,7 +328,7 @@
getTemplate = function () {
var template = $('<div>').addClass('bootstrap-datetimepicker-widget dropdown-menu'),
dateView = $('<div>').addClass('datepicker').append(getDatePickerTemplate()),
dateView = $('<div>').addClass('datepicker2').append(getDatePickerTemplate()),
timeView = $('<div>').addClass('timepicker').append(getTimePickerTemplate()),
content = $('<ul>').addClass('list-unstyled'),
toolbar = $('<li>').addClass('picker-switch' + (options.collapse ? ' accordion-toggle' : '')).append(getToolbar());
......@@ -497,7 +497,7 @@
if (dir) {
currentViewMode = Math.max(minViewModeNumber, Math.min(3, currentViewMode + dir));
}
widget.find('.datepicker > div').hide().filter('.datepicker-' + datePickerModes[currentViewMode].clsName).show();
widget.find('.datepicker2 > div').hide().filter('.datepicker-' + datePickerModes[currentViewMode].clsName).show();
},
fillDow = function () {
......@@ -2523,7 +2523,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().subtract(7, 'd'));
} else {
this.date(d.clone().add(this.stepping(), 'm'));
......@@ -2535,7 +2535,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().add(7, 'd'));
} else {
this.date(d.clone().subtract(this.stepping(), 'm'));
......@@ -2546,7 +2546,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().subtract(1, 'y'));
} else {
this.date(d.clone().add(1, 'h'));
......@@ -2557,7 +2557,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().add(1, 'y'));
} else {
this.date(d.clone().subtract(1, 'h'));
......@@ -2568,7 +2568,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().subtract(1, 'd'));
}
},
......@@ -2577,7 +2577,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().add(1, 'd'));
}
},
......@@ -2586,7 +2586,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().subtract(1, 'M'));
}
},
......@@ -2595,7 +2595,7 @@
return;
}
var d = this.date() || this.getMoment();
if (widget.find('.datepicker').is(':visible')) {
if (widget.find('.datepicker2').is(':visible')) {
this.date(d.clone().add(1, 'M'));
}
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment