Maintenance - Mise à jour mensuelle Lundi 6 Avril 2020 entre 7h00 et 9h00

Commit d6928bee authored by Romain Therville's avatar Romain Therville 🐭

Update for issue #151

Same branch as the old issue151, and same commit as
c5f5c618 .
I have deleted the branch and commits earlier this week, I thought the
merge was already done.

Also, this time I pushed the (much needed) updated ng6_database.sql
file.

(Once again, when this update goes live, an update to the DB structure
will be needed. See the related issue.)

Issue #151
parent 80d1d407
......@@ -1213,25 +1213,25 @@ INSERT INTO `tx_nG6_project` (`uid`, `pid`, `tstamp`, `crdate`, `cruser_id`, `de
--
-- Structure de la vue `tx_nG6_view_project_analyze`
--
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_analyze` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_analyze`.`uid` AS `analyze_id`,`tx_nG6_analyze`.`storage_size` AS `storage_size`,`tx_nG6_analyze`.`purged_size` AS `purged_size`,`tx_nG6_analyze`.`data_state` AS `state`,`tx_nG6_analyze`.`retention_date` AS `retention_date`,`tx_nG6_analyze`.`purge_demand_id` AS `purge_demand_id`, `tx_nG6_analyze`.`hidden` AS `hidden` from ((`tx_nG6_project` join `tx_nG6_project_analyze` on((`tx_nG6_project_analyze`.`project_id` = `tx_nG6_project`.`uid`))) join `tx_nG6_analyze` on((`tx_nG6_project_analyze`.`analyze_id` = `tx_nG6_analyze`.`uid`)));
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_analyze` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_project`.`space_id` AS `space_id`,`tx_nG6_analyze`.`uid` AS `analyze_id`,`tx_nG6_analyze`.`storage_size` AS `storage_size`,`tx_nG6_analyze`.`purged_size` AS `purged_size`,`tx_nG6_analyze`.`data_state` AS `state`,`tx_nG6_analyze`.`retention_date` AS `retention_date`,`tx_nG6_analyze`.`purge_demand_id` AS `purge_demand_id`,`tx_nG6_analyze`.`hidden` AS `hidden` from ((`tx_nG6_project` join `tx_nG6_project_analyze` on((`tx_nG6_project_analyze`.`project_id` = `tx_nG6_project`.`uid`))) join `tx_nG6_analyze` on((`tx_nG6_project_analyze`.`analyze_id` = `tx_nG6_analyze`.`uid`)));
--
-- Structure de la vue `tx_nG6_view_project_run`
--
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_run` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_run`.`uid` AS `run_id`,`tx_nG6_run`.`storage_size` AS `storage_size`,`tx_nG6_run`.`purged_size` AS `purged_size`,`tx_nG6_run`.`data_state` AS `state`,`tx_nG6_run`.`retention_date` AS `retention_date`,`tx_nG6_run`.`purge_demand_id` AS `purge_demand_id`, `tx_nG6_run`.`hidden` AS `hidden` from ((`tx_nG6_run` join `tx_nG6_project_run` on((`tx_nG6_project_run`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_project` on((`tx_nG6_project`.`uid` = `tx_nG6_project_run`.`project_id`)));
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_run` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_project`.`space_id` AS `space_id`,`tx_nG6_run`.`uid` AS `run_id`,`tx_nG6_run`.`storage_size` AS `storage_size`,`tx_nG6_run`.`purged_size` AS `purged_size`,`tx_nG6_run`.`data_state` AS `state`,`tx_nG6_run`.`retention_date` AS `retention_date`,`tx_nG6_run`.`purge_demand_id` AS `purge_demand_id`,`tx_nG6_run`.`hidden` AS `hidden` from ((`tx_nG6_run` join `tx_nG6_project_run` on((`tx_nG6_project_run`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_project` on((`tx_nG6_project`.`uid` = `tx_nG6_project_run`.`project_id`)));
--
-- Structure de la vue `tx_nG6_view_project_run_analyze`
--
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_run_analyze` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_analyze`.`uid` AS `analyze_id`,`tx_nG6_analyze`.`storage_size` AS `storage_size`,`tx_nG6_analyze`.`purged_size` AS `purged_size`,`tx_nG6_analyze`.`data_state` AS `state`,`tx_nG6_analyze`.`retention_date` AS `retention_date`,`tx_nG6_analyze`.`purge_demand_id` AS `purge_demand_id`, `tx_nG6_analyze`.`hidden` AS `hidden` from ((((`tx_nG6_run` join `tx_nG6_project_run` on((`tx_nG6_project_run`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_project` on((`tx_nG6_project`.`uid` = `tx_nG6_project_run`.`project_id`))) join `tx_nG6_run_analyze` on((`tx_nG6_run_analyze`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_analyze` on((`tx_nG6_run_analyze`.`analyze_id` = `tx_nG6_analyze`.`uid`)));
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_run_analyze` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`name` AS `project_name`,`tx_nG6_project`.`space_id` AS `space_id`,`tx_nG6_analyze`.`uid` AS `analyze_id`,`tx_nG6_analyze`.`storage_size` AS `storage_size`,`tx_nG6_analyze`.`purged_size` AS `purged_size`,`tx_nG6_analyze`.`data_state` AS `state`,`tx_nG6_analyze`.`retention_date` AS `retention_date`,`tx_nG6_analyze`.`purge_demand_id` AS `purge_demand_id`,`tx_nG6_analyze`.`hidden` AS `hidden` from ((((`tx_nG6_run` join `tx_nG6_project_run` on((`tx_nG6_project_run`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_project` on((`tx_nG6_project`.`uid` = `tx_nG6_project_run`.`project_id`))) join `tx_nG6_run_analyze` on((`tx_nG6_run_analyze`.`run_id` = `tx_nG6_run`.`uid`))) join `tx_nG6_analyze` on((`tx_nG6_run_analyze`.`analyze_id` = `tx_nG6_analyze`.`uid`)));
--
-- Structure de la vue `tx_nG6_view_project_user`
--
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_user` AS select `tx_nG6_project`.`uid` AS `project_id`,`fe_users`.`uid` AS `user_id`, `fe_users`.`username` AS `user_name`,`fe_users`.`email` AS `email`,`fe_users`.`usergroup` AS `user_group`,`fe_rights_levels`.`right_level_label` AS `right_level_label`,`fe_groups`.`title` AS `user_group_title` from ((((`tx_nG6_project` join `fe_rights` on((`fe_rights`.`project_id` = `tx_nG6_project`.`uid`))) join `fe_users` on((`fe_rights`.`fe_user_id` = `fe_users`.`uid`))) join `fe_groups` on((`fe_users`.`usergroup` = `fe_groups`.`uid`))) join `fe_rights_levels` on((`fe_rights_levels`.`right_level_id` = `fe_rights`.`right_id`)));
CREATE ALGORITHM=UNDEFINED DEFINER=`ng6`@`localhost` SQL SECURITY DEFINER VIEW `tx_nG6_view_project_user` AS select `tx_nG6_project`.`uid` AS `project_id`,`tx_nG6_project`.`space_id` AS `space_id`,`fe_users`.`uid` AS `user_id`, `fe_users`.`username` AS `user_name`,`fe_users`.`email` AS `email`,`fe_users`.`usergroup` AS `user_group`,`fe_rights_levels`.`right_level_label` AS `right_level_label`,`fe_groups`.`title` AS `user_group_title` from ((((`tx_nG6_project` join `fe_rights` on((`fe_rights`.`project_id` = `tx_nG6_project`.`uid`))) join `fe_users` on((`fe_rights`.`fe_user_id` = `fe_users`.`uid`))) join `fe_groups` on((`fe_users`.`usergroup` = `fe_groups`.`uid`))) join `fe_rights_levels` on((`fe_rights_levels`.`right_level_id` = `fe_rights`.`right_id`)));
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
......
......@@ -871,7 +871,7 @@ class tx_nG6_eid {
print json_encode(tx_nG6_db::get_purge_demand_list($purge_delay));
} elseif ($type == 'refresh_purge_list') {
$max_retention_date = trim(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('max_retention_date'));
$filter_space = trim(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('filter_space'));
$filter_space = trim(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('filter_space') );
$without_laboratories_id = trim(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('without_lab'));
$with_laboratories_id = trim(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('with_lab'));
......
......@@ -169,7 +169,7 @@ class tx_nG6_db {
# OBSOLETE / PURGE management
################################
//Get list of obsolete run/analyses per project
static function filter_list_retention_data_info($filter_space, $max_retention_date, $create_user_id, $without_user_group_id,$with_user_group_id) {
static function filter_list_retention_data_info($filter_space, $max_retention_date, $create_user_id, $without_user_group_id, $with_user_group_id) {
$conditions=Array();
//filter by date
......
......@@ -329,7 +329,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
</div>
<div class="col-sm-6">
<fieldset class="col-sm-12">
<fieldset class="col-sm-12">
<h4>1. Filter on space</h4>
<div class="text">
......@@ -339,11 +339,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<option value="{$space_name}">{$space_name}</option>
{/foreach}
</select>
<!-- <input type="text" name="size" id="filter_size" > bytes -->
</div>
</fieldset>
</fieldset>
</div>
<div class="col-sm-6">
......
......@@ -100,7 +100,7 @@ class tx_nG6_pi6 extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin {
$smarty->assign('ng6_superadmin_users', tx_nG6_db::get_ng6_superadmin_users() );
$smarty->assign('is_current_user_superadmin', tx_nG6_db::is_user_ng6_superadmin($GLOBALS['TSFE']->fe_user->user['uid']) );
$smarty->assign('available_space_ids', tx_nG6_utils::get_available_space_ids() );
$smarty->assign('available_space_ids', tx_nG6_utils::get_available_space_ids());
$smarty->assign('ng6_purge_delay',$this->conf['delay_purge']);
return $smarty->fetch('administration_view.tpl');
......
......@@ -864,7 +864,6 @@ $(function () {
$('#data_table_obsolete_wait').show();
$('#obsolete_list').hide();
//var filter_size = $("#filter_size").val(),
filter_space = $("#filter_space").val(),
max_retention_date = $("#max_retention_date").val(),
without_lab=[],
......@@ -883,8 +882,7 @@ $(function () {
with_laboratories = with_lab.join(',');
create_users_string = create_users.join(',');
$.ajax({
//url: "index.php?eID=tx_nG6&type=refresh_purge_list&max_retention_date="+max_retention_date+"&filter_size="+filter_size+"&create_users="+create_users_string+"&without_lab="+without_laboratories+"&with_lab="+with_laboratories,
url: "index.php?eID=tx_nG6&type=refresh_purge_list&max_retention_date="+max_retention_date+"&filter_space="+filter_space+"&create_users="+create_users_string+"&without_lab="+without_laboratories+"&with_lab="+with_laboratories,
url: "index.php?eID=tx_nG6&type=refresh_purge_list&max_retention_date="+max_retention_date+"&filter_space="+filter_space+"&create_users="+create_users_string+"&without_lab="+without_laboratories+"&with_lab="+with_laboratories,
dataType: 'json',
success: function(val, status, xhr) {
var nb_purgeable_project=0,
......
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