Skip to content

Commit

Permalink
Merge branch 'analysis-packages' into development
Browse files Browse the repository at this point in the history
  • Loading branch information
René Reitmann committed Dec 8, 2021
2 parents 1d948e4 + f9c9f0d commit 65a76ce
Show file tree
Hide file tree
Showing 17 changed files with 158 additions and 19 deletions.
4 changes: 4 additions & 0 deletions src/main/scss/fdz-theme/abstract/utility.scss
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@
margin-top: 0!important;
}

.mt4 {
margin-top: 4px!important;
}

.mt8 {
margin-top: 8px!important;
}
Expand Down
16 changes: 13 additions & 3 deletions src/main/scss/fdz-theme/components/fdz/start-theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,22 @@ $card-border-radius: 2px !default;

.fdz-link {
display: flex;
justify-content: space-evenly;
font-size: 20px;
flex-direction: column;
justify-content: center;
font-size: 14px;
padding: 16px;
@include rwd(600) {
a {
padding: 8px;
}
@include rwd(700) {
flex-direction: row;
justify-content: space-evenly;
font-size: 16px;
padding: 24px;
}
@include rwd(860) {
font-size: 20px;
}
}

.fdz-search {
Expand Down
18 changes: 15 additions & 3 deletions src/main/webapp/assets/styles/fdz.css
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,9 @@
.fdz-theme .mt0 {
margin-top: 0 !important; }

.fdz-theme .mt4 {
margin-top: 4px !important; }

.fdz-theme .mt8 {
margin-top: 8px !important; }

Expand Down Expand Up @@ -1587,12 +1590,21 @@ md-slider-container[disabled] > *:last-child:not(md-slider) {
box-shadow: none; }
.fdz-theme .fdz-start .fdz-link {
display: flex;
justify-content: space-evenly;
font-size: 20px;
flex-direction: column;
justify-content: center;
font-size: 14px;
padding: 16px; }
@media (min-width: 600px) {
.fdz-theme .fdz-start .fdz-link a {
padding: 8px; }
@media (min-width: 700px) {
.fdz-theme .fdz-start .fdz-link {
flex-direction: row;
justify-content: space-evenly;
font-size: 16px;
padding: 24px; } }
@media (min-width: 860px) {
.fdz-theme .fdz-start .fdz-link {
font-size: 20px; } }
.fdz-theme .fdz-start .fdz-search {
margin-bottom: 8px; }
@media (min-width: 600px) {
Expand Down
1 change: 1 addition & 0 deletions src/main/webapp/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,7 @@
<script src="/scripts/searchmanagement/components/searchfilter.controller.js"></script>
<script src="/scripts/searchmanagement/components/menu-toggle.component.js"></script>
<script src="/scripts/searchmanagement/components/menu-toggle.controller.js"></script>
<script src="/scripts/searchmanagement/components/package-info.controller.js"></script>

<script src="/scripts/ordermanagement/configuration/shoppingCart.js"></script>
<script src="/scripts/ordermanagement/configuration/translations-de.js"></script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@
</md-button>
</md-card-header>
<div ng-if="!$ctrl.collapsed">
<md-card-content>
<p class="fdz-text-block" markdown-to-html="$ctrl.options"></p>
<md-card-content ng-text-truncate="$ctrl.options"
ng-tt-chars-threshold="512"
ng-tt-less-label="{{'global.less' | translate}}"
ng-tt-more-label="{{'global.more' | translate}}">
</md-card-content>
</div>
</md-card>
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,8 @@ angular.module('metadatamanagementApp').config(
'open-export-tooltip': 'Klicken, um die Metadaten dieses Datenpakets zu exportieren.',
'beta-hint': 'Alle Formate generiert via da|ra (beta-Status)',
'close-tooltip': 'Klicken, um die Produktauswahl zu verlassen.',
'data-package-tooltip': 'Klicken, um weitere Informationen zu Datenpaketen zu erhalten.',
'analysis-package-tooltip': 'Klicken, um weitere Informationen zu Analysepaketen zu erhalten.',
'data-package-version-tooltip': 'Klicken, um weitere Informationen zur Version von Datenpaketen zu erhalten.',
'analysis-package-version-tooltip': 'Klicken, um weitere Informationen zur Version von Analysepaketen zu erhalten.',
'data-package-access-way-tooltip': 'Klicken, um weitere Informationen zu Zugangswegen zu erhalten.'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,8 @@ angular.module('metadatamanagementApp').config(
'open-export-tooltip': 'Click to export the metadata of this data package.',
'close-tooltip': 'Click to close the package selection.',
'data-package-version-tooltip': 'Click to get more information about versions of data packages',
'data-package-tooltip': 'Click to get more information about data packages',
'analysis-package-tooltip': 'Click to get more information about analysis packages',
'analysis-package-version-tooltip': 'Click to get more information about versions of analysis packages',
'data-package-access-way-tooltip': 'Click to get more information about access ways'
},
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<md-dialog aria-label="{{'analysis-package-management.detail.label.analysisPackages' | translate}}" layout="column" class="ms-flex" flex="50">
<md-toolbar>
<div class="md-toolbar-tools" layout="row" layout-align="space-between center">
<h2 class="fdz-truncate-string">
<span>{{'analysis-package-management.detail.label.analysisPackages' | translate}}</span>
</h2>
<md-button class="md-icon-button" ng-click="closeDialog()">
<md-icon md-font-set="material-icons">clear</md-icon>
<md-tooltip md-direction="top" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 1000001">
{{'shopping-cart.version-info.close-tooltip' | translate }}
</md-tooltip>
</md-button>
</div>
</md-toolbar>
<md-divider></md-divider>
<md-dialog-content layout-padding flex layout="column" class="ms-flex">
<p>{{'search-management.detail.analysis-packages-info' | translate }}</p>
</md-dialog-content>

</md-dialog-content>
<md-dialog-actions layout="row">
<md-button class="md-primary" ng-click="closeDialog()">
<span>{{'global.entity.action.ok' | translate}}</span>
<md-tooltip md-direction="left" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 1000001">
{{'shopping-cart.version-info.close-tooltip' | translate }}
</md-tooltip>
</md-button>
</md-dialog-actions>
</md-dialog>
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<md-dialog aria-label="{{'data-package-management.detail.label.dataPackages' | translate}}" layout="column" class="ms-flex" flex="50">
<md-toolbar>
<div class="md-toolbar-tools" layout="row" layout-align="space-between center">
<h2 class="fdz-truncate-string">
<span>{{'data-package-management.detail.label.dataPackages' | translate}}</span>
</h2>
<md-button class="md-icon-button" ng-click="closeDialog()">
<md-icon md-font-set="material-icons">clear</md-icon>
<md-tooltip md-direction="top" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 1000001">
{{'shopping-cart.version-info.close-tooltip' | translate }}
</md-tooltip>
</md-button>
</div>
</md-toolbar>
<md-divider></md-divider>
<md-dialog-content layout-padding flex layout="column" class="ms-flex">
<p>{{'search-management.detail.data-packages-info' | translate }}</p>
</md-dialog-content>

</md-dialog-content>
<md-dialog-actions layout="row">
<md-button class="md-primary" ng-click="closeDialog()">
<span>{{'global.entity.action.ok' | translate}}</span>
<md-tooltip md-direction="left" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 1000001">
{{'shopping-cart.version-info.close-tooltip' | translate }}
</md-tooltip>
</md-button>
</md-dialog-actions>
</md-dialog>
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/* global bowser */
'use strict';

angular.module('metadatamanagementApp')
.controller('dataPackageInfoController',
function($scope, $mdDialog) {
$scope.bowser = bowser;

$scope.closeDialog = function() {
$mdDialog.cancel();
};
});
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
(function() {
'use strict';

function SearchFilterController($scope, $location, MessageBus, $timeout) {
function SearchFilterController(
$scope, $location, MessageBus, $timeout, $mdDialog
) {
var filterValueObject = {
analysis_packages: [
{
Expand Down Expand Up @@ -195,6 +197,21 @@
]);
}

$ctrl.infoModal = function(type, $event) {
var url = {
data: 'data-package-info.html.tmpl',
analysis: 'analysis-package-info.html.tmpl'
};
$mdDialog.show({
controller: 'dataPackageInfoController',
templateUrl: 'scripts/searchmanagement/components/' + url[type],
clickOutsideToClose: true,
escapeToClose: true,
fullscreen: true,
targetEvent: $event
});
};

$scope.$watch('$ctrl.searchParams.type', function(newValue, oldValue) {
if (newValue !== oldValue) {
clearFilter();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,25 @@
<md-card class="fdz-package-filter">
<md-card-content>
<label for="searchPackageSwitch">{{'search-management.packages.label' | translate}}</label>
<md-radio-group layout="column" id="searchPackageSwitch" ng-model="$ctrl.dataPackageSearchFilter" ng-change="$ctrl.changePackageFilter()" aria-labelledby="{{'search-management.packages.label' | translate}}">
<div layout="row">
<md-radio-group class="mt8" layout="column" id="searchPackageSwitch" ng-model="$ctrl.dataPackageSearchFilter" ng-change="$ctrl.changePackageFilter()" aria-labelledby="{{'search-management.packages.label' | translate}}">
<md-radio-button value="data_packages" class="md-primary">{{'search-management.packages.data-packages' | translate}} ({{ $ctrl.totalHits.data_packages ? $ctrl.totalHits.data_packages : 0 }})</md-radio-button>
<md-radio-button value="analysis_packages" class="md-primary">{{'search-management.packages.analysis-packages' | translate}} ({{ $ctrl.totalHits.analysis_packages ? $ctrl.totalHits.analysis_packages : 0 }})</md-radio-button>
<md-radio-button value="analysis_packages" class="md-primary mt4">{{'search-management.packages.analysis-packages' | translate}} ({{ $ctrl.totalHits.analysis_packages ? $ctrl.totalHits.analysis_packages : 0 }})</md-radio-button>
</md-radio-group>
<div layout="column">
<md-button class="md-icon-button md-primary" ng-click="$ctrl.infoModal('data', $event)">
<md-icon>info</md-icon>
<md-tooltip md-direction="top" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 100001">
{{'shopping-cart.buttons.data-package-tooltip' | translate}}
</md-tooltip>
</md-button>
<md-button class="md-icon-button md-primary" ng-click="$ctrl.infoModal('analysis', $event)">
<md-icon>info</md-icon>
<md-tooltip md-direction="top" md-autohide="true" md-z-index="bowser.mobile || bowser.tablet ? -100 : 100001">
{{'shopping-cart.buttons.analysis-package-tooltip' | translate}}
</md-tooltip>
</md-button>
</div></div>
</md-card-content>
</md-card>
<md-card class="fdz-search-filter">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ angular.module('metadatamanagementApp').config(
'noresult': 'Keine Suchergebnisse gefunden.',
'version': 'Version',
'access-way': 'Zugangsweg',
'cart': 'In den Warenkorb legen'
'cart': 'In den Warenkorb legen',
'data-packages-info': 'Datenpakete enthalten Scientific Use Files und/oder Campus Use Files, die für eine breite Nutzung in Wissenschaft bzw. Lehre vorgesehen sind.',
'analysis-packages-info': 'Analysepakete enthalten Analyseskripte und Analysedaten, die zur Erstellung einer spezifischen Pubilkation verwendet wurden und ermöglichen damit deren Replikation.'
},
'buttons': {
'refresh-tooltip': 'Klicken, um die Suche zu aktualisieren',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ angular.module('metadatamanagementApp').config(
'noresult': 'No search results found.',
'version': 'Version',
'access-way': 'Access Way',
'cart': 'Add to shopping cart'
'cart': 'Add to shopping cart',
'data-packages-info': 'Data packages contain Scientific Use Files and/or Campus Use Files that are intended for broad use in science or teaching.',
'analysis-packages-info': 'Analysis packages contain analysis scripts and analysis data that were used to create a specific publication and thus enable its replication.'
},
'buttons': {
'refresh-tooltip': 'Click to refresh the search results',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ angular.module('metadatamanagementApp').config(
'data-search': 'Forschungsdaten aus der Hochschul- und Wissenschaftsforschung finden',
'pinned-data-package-title': 'Datenpaket im Fokus',
'fdz-text': 'Das FDZ-DZHW stellt Datenpakete der Hochschul- und Wissenschaftsforschung zur Verfügung. Mit der Datensuche können Sie die Metadaten der beim FDZ-DZHW hinterlegten Datenpakete schnell und einfach durchsuchen. So finden Sie alle Informationen, die Sie brauchen, und können die entsprechenden Datenpakete direkt bestellen.',
'show-all': 'Alle Datenpakete anzeigen',
'show-all-analysis-packages': 'Alle Analysepakete anzeigen'
'show-all': 'Alle Datenpakete anzeigen (SUF, CUF)',
'show-all-analysis-packages': 'Alle Analysepakete anzeigen (Skripte)'
}
//jscs:enable
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ angular.module('metadatamanagementApp').config(
'data-search': 'Find Higher Education and Science Research Data Packages',
'pinned-data-package-title': 'Featured Data Package',
'fdz-text': 'With the data search you can quickly and easily search the metadata of the data packages stored at the FDZ-DZHW. This way you will find all the information you need and can order the corresponding data packages directly.',
'show-all': 'Show all Data Packages',
'show-all-analysis-packages': 'Show all Analysis Packages'
'show-all': 'Show all Data Packages (SUF, CUF)',
'show-all-analysis-packages': 'Show all Analysis Packages (Scripts)'
}
//jscs:enable
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Add institutions
Input Text name=institutionEn_1 DZHW 2 ${BROWSER}
Move element input institutionDe_1 //button[@id = 'move-institution-up-button']
Move element input institutionDe_0 //button[@id = 'move-institution-down-button']
click element through tooltips //div[2]/button[@aria-label='Klicken, um die Institution aus diesem Analysepaket zu entfernen.']
click element through tooltips //div[2]/div/button[@aria-label='Klicken, um die Institution aus diesem Analysepaket zu entfernen.']

Add sponsors
Click Element Through Tooltips //button[contains(@aria-label,'Klicken, um eine weitere Geldgeber:in diesem Analysepaket hinzuzufügen.')]
Expand All @@ -75,7 +75,7 @@ Add sponsors
Input Text name=sponsorEn_1 DZHW 2 ${BROWSER}
Move element input sponsorDe_1 //button[@id = 'move-sponsor-up-button']
Move element input sponsorDe_0 //button[@id = 'move-sponsor-down-button']
Click Element Through Tooltips //div[2]/button[@aria-label='Klicken, um die Geldgeber:in aus diesem Analysepaket zu entfernen.']
Click Element Through Tooltips //div[2]/div/button[@aria-label='Klicken, um die Geldgeber:in aus diesem Analysepaket zu entfernen.']

Add license
Input Text name=license This is free and unencumbered software released into the public domain...
Expand Down

0 comments on commit 65a76ce

Please sign in to comment.