Commit e24d5cdd 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 !645
parents 5379d5bf 01a33c78
Pipeline #11725 failed with stages
in 44 seconds
# CHANGELOG
## Version 2.7.2
- `Added` Tri des dossiers virtuels par ordre alphabétique.
- `Added` Affichage des champs de référence externe dans la liste des données descriptives.
- `Fixed` Tri des résultats de recherche par date quand le nombre de résultats dépasse le nombre de résultats maximal.
- `Fixed` Mauvaise interprétation HTML quand un symbole '&' était saisi dans un champ de type textarea.
- `Fixed` Possibilité d'envoi de fichier profil rng sans extension.
- `Fixed` Possibilité de création des relations récursives parents/enfants dans les profils d'archive.
- `Fixed` Traductions.
- `Fixed` Problème chargement plugin datePicker sur l'écran principal lors de l'affichage avec de nombreux dossiers virtuels.
- `Fixed` Affichage d'erreur sur la page de création d'un nouveau compte de service.
- `Fixed` Résultats du service précédent affiché lors de la sélection d'un nouveau service dans la barre de menu.
- `Fixed` Amélioration de la vue mobile de la barre de navigation.
- `Fixed` Amélioration des performances lors de l'affichage/masquage des dossiers virtuels.
## Version 2.7.1
- `Fixed` Activation et désactivation des tâches dans le planificateur de tâches.
- `Fixed` Calcul de la prochaine exécution mêmeen cas d'erreur dans le planificateur de tâches.
......
2.7.1
\ No newline at end of file
2.7.2
\ No newline at end of file
......@@ -7,7 +7,7 @@ namespace core\Reflection;
/**
* Class Laabs service path
*
*
* @extends \core\Reflection\Method
*/
class Path
......@@ -77,16 +77,16 @@ class Path
$this->returnType = null;
$this->parameters = null;
$this->tags = null;
parent::__construct($class, $name);
$this->domain = $domain;
$this->interface = substr($class, strrpos($class, LAABS_NS_SEPARATOR)+1, -9);
$parts = preg_split("#([a-z]+|[A-Z][a-z0-9]+|_[A-Za-z][A-Za-z0-9]*_)#", $this->name, -1, PREG_SPLIT_DELIM_CAPTURE + PREG_SPLIT_NO_EMPTY);
$this->method = array_shift($parts);
$patterns = array();
if (isset($this->tags['var'])) {
//if (preg_match_all("#@var (?<type>\w+)\s*(?<name>\w+).*#", $docComment, $patternMatches, PREG_SET_ORDER)) {
......@@ -132,7 +132,7 @@ class Path
* Match a path with method and uri
* @param string $method
* @param string $uri
*
*
* @return object The path with variables
*/
public function match($method='read', $uri='')
......@@ -147,7 +147,7 @@ class Path
// Check empty uri
if (!isset($this->path) && !empty($uri)) {
return;
}
}
// Check uri VS path pattern
if (isset($this->path) && !@preg_match("#^" . str_replace("/", "\\/", $this->pattern) . "$#i", $uri, $args)) {
......@@ -161,7 +161,7 @@ class Path
array_shift($args);
foreach ($args as $name => $value) {
if (ctype_alpha($name[0])) {
if (!empty($name) && ctype_alpha($name)) {
$matched->variables[$name] = $value;
}
}
......@@ -172,18 +172,18 @@ class Path
/**
* Get path
*
*
* @return string
*/
public function getName()
{
return $this->domain . LAABS_URI_SEPARATOR . $this->interface . LAABS_URI_SEPARATOR . $this->name;
}
}
/**
* Reroute
* @param \core\Reflection\Path $newPath
*
*
* @return Path
*/
public function reroute($newPath)
......
......@@ -437,7 +437,8 @@ trait TemplateTrait
// Textareas
case 'textarea':
$element->nodeValue = $value;
$element->nodeValue = '';
$element->appendChild($this->createTextNode($value));
break;
}
}
......
......@@ -159,8 +159,8 @@ class serviceAccount
*/
public function newService()
{
$account = \laabs::newInstance('auth/account');
$account->accountType = 'service';
$serviceAccount = \laabs::newInstance('auth/account');
$serviceAccount->accountType = 'service';
$servicePrivilegesTmp= \laabs::configuration('auth')['servicePrivileges'];
foreach ($servicePrivilegesTmp as $value) {
......
......@@ -57,7 +57,9 @@ class filePlan
$folders = $this->sdoFactory->find(
'filePlan/folder',
"ownerOrgRegNumber=['".\laabs\implode("', '", $orgRegNumbers)."']"
"ownerOrgRegNumber=['".\laabs\implode("', '", $orgRegNumbers)."']",
[],
"name"
);
$folderTree = \laabs::buildTree($folders, 'filePlan/folder');
......
......@@ -1135,7 +1135,7 @@ class ArchiveTransfer extends abstractMessage
'medona/message',
implode(' and ', $queryParts),
null,
false,
">receptionDate",
false,
$maxResults
);
......
......@@ -212,7 +212,7 @@ class message
);
$maxResults = \laabs::configuration('presentation.maarchRM')['maxResults'];
return $this->sdoFactory->find('medona/message', $queryString, $queryParams, false, false, $maxResults);
return $this->sdoFactory->find('medona/message', $queryString, $queryParams, ">receptionDate", false, $maxResults);
}
/**
......
......@@ -395,6 +395,14 @@ class archivalProfile
}
$archivalProfileContents = \laabs::newInstance('recordsManagement/archivalProfileContents');
$contentProfiles = $this->getContentsProfiles($containedProfileId);
if (!empty($contentProfiles)) {
foreach ($contentProfiles as $contentProfile) {
if ($contentProfile->archivalProfileId == $archivalProfile->archivalProfileId) {
throw new \core\Exception\BadRequestException("%s cannot be recursively called.", 404, null, [$contentProfile->name]);
}
}
}
$archivalProfileContents->parentProfileId = $archivalProfile->archivalProfileId;
$archivalProfileContents->containedProfileId = $containedProfileId;
......@@ -425,6 +433,10 @@ class archivalProfile
*/
public function uploadArchivalProfile($profileReference, $archivalProfile, $content, $format = 'rng')
{
if (empty($format)) {
$format = 'rng';
}
$profilesDirectory = $this->profilesDirectory;
$profilesDirectory .= DIRECTORY_SEPARATOR.$profileReference.'.'.$format ;
$content = base64_decode($content);
......
......@@ -98,11 +98,18 @@ class archivalProfile
$profilesDirectory = \laabs::configuration('recordsManagement')['profilesDirectory'];
$profileList = \laabs::callService('recordsManagement/archivalProfile/readIndex');
foreach ($profileList as $key => $profile) {
if (!empty($profile->containedProfiles)) {
foreach ($profile->containedProfiles as $containedProfile) {
if ($containedProfile->archivalProfileId == $archivalProfile->archivalProfileId) {
unset($profileList[$key]);
}
}
}
if ($profile->archivalProfileId == $archivalProfile->archivalProfileId) {
unset($profileList[$key]);
break;
}
}
}
$archivalProfile->containedProfiles = json_encode($archivalProfile->containedProfiles);
......
......@@ -61,7 +61,16 @@ class descriptionField
*/
public function index()
{
$descriptionFields = \laabs::callService('recordsManagement/descriptionField/readIndex');
$baseDescriptionFields = \laabs::callService('recordsManagement/descriptionField/readIndex');
$extendedDescriptionFields = \laabs::callService('recordsManagement/descriptionScheme/read_name_descriptionFields');
$descriptionFields = array_map(
function ($field) use ($baseDescriptionFields) {
$field->extended = !isset($baseDescriptionFields[$field->name]);
return $field;
},
$extendedDescriptionFields
);
$this->view->addContentFile('recordsManagement/descriptionField/index.html');
......
......@@ -98,6 +98,9 @@ msgstr "Demandes de communication reçues"
msgid "Delivery request history"
msgstr "Historique de communication"
msgid "Delivery process list"
msgstr "Communications à finaliser"
msgid "Communication authorization"
msgstr "Autorisation de communication"
......
......@@ -274,3 +274,6 @@ msgstr "Lecture seule"
msgid "View in the list"
msgstr "Voir dans la liste"
msgid "cannot be recursively called"
msgstr "ne peut pas être appelé récursivement"
\ No newline at end of file
......@@ -32,6 +32,12 @@ msgstr "Date"
msgid "With time"
msgstr "Avec heure"
msgid "array"
msgstr "Tableau"
msgid "object"
msgstr "Objet"
msgid "Today's date by default"
msgstr "Date du jour par défaut"
......@@ -139,3 +145,6 @@ msgstr "Non"
msgid "Yes"
msgstr "Oui"
msgid "This field is defined on an extension and can not be managed in this panel. Contact the system operator to know more."
msgstr "Ce champ est défini dans une configuration d'extension et ne peut être géré à partir de cet écran. Contactez l'opérateur du système pour en savoir plus."
......@@ -1129,7 +1129,7 @@ msgid "First Name"
msgstr "Prénom"
msgid "Birth Name"
msgstr "Nom de jeune fille"
msgstr "Nom de naissance"
msgid "Given Name"
msgstr "Nom usuel"
......
<div id="contain" >
<div class="container-fluid" data-translate-catalog="auth/messages">
<div class="page-header">
<?merge serviceAccount.accountId.bool() ?>
<h1>
<i class="fa fa-laptop"></i>
Edit service account
</h1>
<?merge serviceAccount.accountId.bool().not() ?>
<h1>
<i class="fa fa-laptop"></i>
Add a service account
</h1>
</div>
</div>
<div class="container-fluid" data-translate-catalog="auth/messages">
......
......@@ -261,7 +261,9 @@
|| selectedProfile.retentionStartDate == ''
|| selectedProfile.retentionStartDate == null) {
var retentionStartDate = $("#managementMetadataForm").find("[name=retentionStartDate]");
retentionStartDate.data("datepicker").setDate(new Date());
if (retentionStartDate.data("datepicker")) {
retentionStartDate.data("datepicker").setDate(new Date());
}
retentionStartDate.closest(".form-group").removeClass("hide");
} else {
......
<nav class="navbar navbar-default navbar-fixed-top" role="navigation" data-translate-catalog translate="no" data-translate-context="layout">
<div class="container-fluid">
<div class="navbar-header col-sm-4 col-md-4">
<div class="navbar-header col-md-1">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#leMenu">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
......@@ -9,7 +9,6 @@
</button>
<a class="navbar-brand" style="cursor: pointer; padding: 10px" onclick="load('/', 'HTML_NO_LAYOUT')">
<img class="img-responsive pull-left" style="max-height:32px;" src="[?merge .logo ?]"/>
<span style=''>&nbsp;</span>
<span style='font-family:electrolize;'>
<?merge .navbarTitle ?>
<span style='[?merge .["style"] ?]'><?merge .["value"] ?></span>
......@@ -62,30 +61,6 @@
</li>
</ul>
</li>
<!--<?merge ['submenu'] ?>
<li class="collapse-container" style="width: 100%;">
<?merge ['submenu'].count().bool().not() ?>
<a data-href="[?merge ['href'] ?]" onclick="load('[?merge ['href'] ?]');" translate="yes">
<i class="[?merge ['class'] ?]"></i>
<?merge ['label'] ?>
</a>
<?merge ['submenu'].count().bool() ?>
<a class="collpaseonhover" translate="yes" data-toggle="collapse" role="button" aria-expanded="false">
<i class="[?merge ['class'] ?]"></i>
<?merge ['label'] ?>
</a>
<?merge ['submenu'].count().bool() ?>
<ul class="collapse collapse-menu" style="list-style: none;">
<?merge ['submenu'] ?>
<li class="dropdown-item">
<a data-href="[?merge ['href'] ?]" class="text-muted" onclick="load('[?merge ['href'] ?]');" translate="yes">
<?merge ['label'] ?>
</a>
</li>
</ul>
</li>-->
</ul>
</li>
<?merge .positions.count().ifgt(0) ?>
......@@ -414,12 +389,13 @@
$.ajax({
type: "PUT",
url: "/currentPosition/"+ orgId,
async: false
async: false,
success : function() {
var location = window.location.pathname.split('/');
location.splice(0, 1);
load("/"+location.join("/"));
}
});
var location = window.location.pathname.split('/');
location.splice(0, 1);
load("/"+location.join("/"));
});
$('[data-currentuserid]').on('click', function () {
......
......@@ -21,47 +21,50 @@
<div class="col-xs-12">
<h4 id="orgInfo_displayName"></h4>
<br/>
<div class="col-xs-12">
<dl class="dl-horizontal">
<dt>Organization name</dt>
<dd id="orgInfo_orgName"></dd>
<div class="row">
<div class="col-xs-12">
<dl class="dl-horizontal">
<dt>Organization name</dt>
<dd id="orgInfo_orgName"></dd>
<dt>Other name</dt>
<dd id="orgInfo_otherOrgName"></dd>
<dt>Other name</dt>
<dd id="orgInfo_otherOrgName"></dd>
<dt>Registration number</dt>
<dd id="orgInfo_registrationNumber"></dd>
<dt>Registration number</dt>
<dd id="orgInfo_registrationNumber"></dd>
<dt>Organization role</dt>
<dd id="orgInfo_orgRoles"></dd>
<dt>Organization role</dt>
<dd id="orgInfo_orgRoles"></dd>
<dt>Organization type</dt>
<dd id="orgInfo_organizationType"></dd>
<dt>Organization type</dt>
<dd id="orgInfo_organizationType"></dd>
<dt>Begin date</dt>
<dd id="orgInfo_beginDate"></dd>
<dt>Begin date</dt>
<dd id="orgInfo_beginDate"></dd>
<dt>End date</dt>
<dd id="orgInfo_endDate"></dd>
<dt>End date</dt>
<dd id="orgInfo_endDate"></dd>
<dt>Description</dt>
<dd id="orgInfo_description"></dd>
<dt>Description</dt>
<dd id="orgInfo_description"></dd>
<dt>Legal classification</dt>
<dd id="orgInfo_legalClassification"></dd>
<dt>Legal classification</dt>
<dd id="orgInfo_legalClassification"></dd>
<dt>Business type</dt>
<dd id="orgInfo_businessType"></dd>
<dt>Business type</dt>
<dd id="orgInfo_businessType"></dd>
<dt>Tax identifier</dt>
<dd id="orgInfo_taxIdentifier"></dd>
<dt>Tax identifier</dt>
<dd id="orgInfo_taxIdentifier"></dd>
<dt>History</dt>
<dd id="orgInfo_history"></dd>
<dt>History</dt>
<dd id="orgInfo_history"></dd>
<dt>Enabled</dt>
<dd id="orgInfo_enabled"></dd>
</dl>
</div>
<dt>Enabled</dt>
<dd id="orgInfo_enabled"></dd>
</dl>
</div>
<?merge adminOrg.not().then('hide') @class ?>
<button title="Modify" class="btn btn-warning pull-right" id="modifyOrganization"><i class="fa fa-edit">&nbsp;</i>Modify</button>
......
......@@ -132,8 +132,7 @@
var icon = $('<i/>').addClass('fa fa-spinner fa-spin');
var submitButton = $('#messageImport_submit');
var reference = $('#archivalProfile_form').find('input[name="reference"]').val();
var format = $('#archivalProfile_filesBrowser').val().split('.').pop();
var format = $('#archivalProfile_fileName').val().split('.').pop();
submitButton.find('i').removeClass('fa-level-down').addClass('fa-spin fa-spinner');
if (!reference) {
......@@ -214,9 +213,10 @@
$('#archivalProfile_fileFormat').html(format);
$('#archivalProfile_fileName').html(file.name);
$('#archivalProfile_fileName').val(file.name);
$('#archivalProfile_fileDate').addClass('hide');
$('#archivalProfile_XMLDropZone').addClass('hide');
$('#archivalProfile_fileInfo').removeClass('hide');
......
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