Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge release branch '1.19.0' #603

Merged
merged 130 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
130 commits
Select commit Hold shift + click to select a range
16c7a1a
Merge pull request #496 from NUM-Forschungsdatenplattform/release/v1.…
richardbartha Nov 17, 2023
686bdc2
chore(NUM-2293): update package-log
axelsiebert Nov 24, 2023
34bd249
feat(NUM-2293): add data model and parsing for attachments
axelsiebert Dec 1, 2023
53bf27f
feat(NUM-2293): add unit tests for attachment model
axelsiebert Dec 1, 2023
e3008ed
feat(NUM-2293): add table for attachments
axelsiebert Dec 1, 2023
ef095e4
feat(NUM-2293): add unit tests for directive and table
axelsiebert Dec 29, 2023
e4409fd
test(NUM-2293): add tests for select column
axelsiebert Jan 5, 2024
b2034ec
test(NUM-2293): add test ids for ui tests
axelsiebert Jan 5, 2024
4c6aeea
chore(NUM-2293): clean up
axelsiebert Jan 5, 2024
67c8390
docs(NUM-2293): fix readthedocs config
axelsiebert Jan 5, 2024
7ff0b74
chore(NUM-2293): add missing license headers
axelsiebert Jan 5, 2024
269f3ce
Merge pull request #498 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 5, 2024
a1eb05d
chore(NUM-2306): remove package overrides
axelsiebert Jan 5, 2024
703c9c5
feat(NUM-2306): update @angular/core to 14
axelsiebert Jan 5, 2024
84ff06d
feat(NUM-2306): update @angular/material to 14
axelsiebert Jan 5, 2024
cf8a1d2
chore(NUM-2306): sort package.json dependencies
axelsiebert Jan 5, 2024
eedcce4
chore(NUM-2306): update jest to 28
axelsiebert Jan 5, 2024
4f703b9
chore(NUM-2306): add crypto polyfill and fix test warnings
axelsiebert Jan 5, 2024
ef85ca7
chore(NUM-2306) fix test warnings
axelsiebert Jan 5, 2024
7a6cc9e
test(NUM-2306): migrate jest to v28
axelsiebert Jan 12, 2024
e7faad6
chore(NUM-2306): remove .nvmrc
axelsiebert Jan 12, 2024
fc393ee
chore(NUM-2306): update to node 16.20.2
axelsiebert Jan 12, 2024
047ba57
chore(NUM-2306): update package-lock.json
axelsiebert Jan 12, 2024
0343e1e
chore(NUM-2306): use latest node orb in circleci
axelsiebert Jan 12, 2024
301ae7f
ci(NUM-2306): add fontawesome auth
axelsiebert Jan 12, 2024
a61e306
ci(NUM-2306): fix fontawesome token add
axelsiebert Jan 12, 2024
6c05cfd
ci(NUM-2306): add ci specific npm config
axelsiebert Jan 19, 2024
bee1cf7
chore(NUM-2306) fix linter and update minor dependencies
axelsiebert Jan 19, 2024
499b854
chore(NUM-2306): downgrade fontawesome back to v5 reference
axelsiebert Jan 19, 2024
62884c9
chore(NUM-2306): update ng-idle dependencies
axelsiebert Jan 19, 2024
862b74d
ci(NUM-2306): update sonar orb to latest version
axelsiebert Jan 19, 2024
76e01f0
chore(NUM-2306): udgrade ci orbs & clean up
axelsiebert Jan 19, 2024
6b4b3bf
chore(NUM-2306): update ngx-charts & fix theme
axelsiebert Jan 19, 2024
adee6ba
chore(NUM-2306): upgrade angular-oauth2-oidc & remove unused deps
axelsiebert Jan 19, 2024
db94815
chore(NUM-2306): update rxjs
axelsiebert Jan 19, 2024
c3a8bb5
chore(NUM-2306): update angular-playground
axelsiebert Jan 19, 2024
d0d2563
chore(NUM-2306): fix tests
axelsiebert Jan 19, 2024
7cd43b3
chore(NUM-2306): update dev packages
axelsiebert Jan 19, 2024
000fb34
chore(NUM-2306): fix linter errors
axelsiebert Jan 19, 2024
5716ba5
Merge pull request #499 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 22, 2024
aa81a75
chore(NUM-2306): increase image version for security check
axelsiebert Jan 22, 2024
cc580c8
chore(NUM-2306): update remote docker engine version
axelsiebert Jan 22, 2024
6ec7039
Merge pull request #500 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 22, 2024
7ddb3ed
chore(NUM-2306): add fontawesome token and upgrade nginx
axelsiebert Jan 22, 2024
bbcf748
chore(NUM-2306): Inject fontawesome token into docker build command
axelsiebert Jan 22, 2024
ba20a07
Merge pull request #501 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 22, 2024
9c7f49f
chore(NUM-2306): install gettext in docker for envsubst
axelsiebert Jan 22, 2024
5b7ae98
Merge pull request #502 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 22, 2024
24308db
chore(NUM-2306): add project to docker build and update owasp
axelsiebert Jan 22, 2024
c4d1e16
Merge pull request #503 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 22, 2024
0604b68
feat(NUM-2298): add button and service for download attachments
axelsiebert Jan 26, 2024
c028451
feat(NUM-1198): handle downloaded file happy path
axelsiebert Jan 26, 2024
ae400d5
chore(NUM-2298): fix tsconfig trailing commas
axelsiebert Jan 26, 2024
bd42868
chore(NUM-2298): fix linter issues with trailing commas
axelsiebert Jan 26, 2024
a7cba90
chore(NUM-2298): revert trailing commas & fix test
axelsiebert Jan 26, 2024
8d79b49
test(NUM-2298): test some edge cases in attachment download handling
axelsiebert Jan 26, 2024
ff8dd23
test(NUM-2298): add unit tests for pdf download util
axelsiebert Jan 26, 2024
f0f6ddf
feat(NUM-2298): add error handling for attachment download
axelsiebert Jan 27, 2024
0aba4ef
feat(NUM-2298): hide attachment download button in view mode
axelsiebert Jan 27, 2024
2ea5056
Merge pull request #504 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 29, 2024
379f722
Update conf.py
fwurzel Jan 31, 2024
192786d
Update conf.py
fwurzel Jan 31, 2024
e6161ad
Merge pull request #504 from NUM-Forschungsdatenplattform/feature/NUM…
crisdelta Jan 29, 2024
a761a07
Merge branch 'feature/NUM-2298#download_attachments_ux_improvement' o…
axelsiebert Feb 2, 2024
63b2624
chore(NUM-2298): fix unit test warnings
axelsiebert Feb 2, 2024
f4b5a08
Merge pull request #505 from NUM-Forschungsdatenplattform/URL-change-…
axelsiebert Feb 2, 2024
ce71e0f
Merge branch 'develop' into feature/NUM-2298#download_attachments_ux_…
axelsiebert Feb 2, 2024
938f93e
chore(NUM-2298): deactivate sonar analysis
axelsiebert Feb 2, 2024
2a6cf43
Merge pull request #506 from NUM-Forschungsdatenplattform/feature/NUM…
axelsiebert Feb 9, 2024
84f67ca
nightly build with github actions
ramueSVA Feb 19, 2024
8b7d6a8
nightly update package path
ramueSVA Feb 19, 2024
06bfd23
nightly update package path
ramueSVA Feb 19, 2024
d00fbc1
nightly update package path (v.3)
ramueSVA Feb 19, 2024
36dc0e0
nightly schedule for main
ramueSVA Feb 20, 2024
a73d6e5
remove sonar cloud step in pipeline
ramueSVA Feb 20, 2024
2a9a14f
remove sonar cloud step in pipeline
ramueSVA Feb 20, 2024
fcc10a8
Merge branch 'develop' into feature/new-pipeline-nightly
ramueSVA Feb 20, 2024
77956d8
Merge pull request #507 from NUM-Forschungsdatenplattform/feature/new…
ramueSVA Feb 20, 2024
bfacd47
Add dependabot and onpush pipeline (#508)
ramueSVA Feb 20, 2024
aeae0e4
Feature/new pipeline nightly (#520)
ramueSVA Feb 21, 2024
f0a4593
naming (#521)
ramueSVA Feb 21, 2024
ca6f9a6
Feature/naming (#523)
ramueSVA Feb 26, 2024
a89e6f8
Feature/naming (#524)
ramueSVA Feb 26, 2024
933a455
refactoring naming (#525)
ramueSVA Feb 28, 2024
34b9af3
Feature/file changes (#526)
ramueSVA Feb 28, 2024
7190e60
remove sonar cloud
ramueSVA Feb 29, 2024
339015f
Merge pull request #527 from NUM-Forschungsdatenplattform/feature/rem…
mafasva Feb 29, 2024
d2a7a9b
feat(NUM-2294): add button to upload attachments in draft status
axelsiebert Feb 16, 2024
f1ac7f2
chore(NUM-2294): fix unit tests
axelsiebert Feb 17, 2024
fb88273
feat(NUM-2294): add service method to upload attachments
axelsiebert Feb 23, 2024
de3de6f
feat(NUM-2294): add progress to upload
axelsiebert Mar 1, 2024
224efd2
feat(NUM-2294) reload attachments after upload succeeded
axelsiebert Mar 1, 2024
04b9921
feat(NUM-2294): limit file selection to pdf
axelsiebert Mar 1, 2024
41e84cb
Merge pull request #528 from NUM-Forschungsdatenplattform/feature/NUM…
axelsiebert Mar 12, 2024
26bdcd9
add release Pipelines and remove CircleCi (#535)
ramueSVA Mar 21, 2024
1d9a6db
add tagging pipeline (#537)
ramueSVA Apr 2, 2024
cc2b242
Change support from vitagroup.ag to sva.de (#538)
ramueSVA Apr 2, 2024
bd07e31
Feature/delete fontawesome token (#540)
ramueSVA Apr 2, 2024
f118096
NUM-2297: Delete attachments (#532)
axelsiebert Apr 8, 2024
93a8410
Feature/replace codex with rdp (#543)
ramueSVA Apr 11, 2024
00da376
Update pipeline trigger (#548)
mafasva Apr 17, 2024
9cbeed8
change local config (#552)
mafasva May 2, 2024
b73697d
Update Keycloak URL for password change (#547)
askask May 15, 2024
71107ea
chore(deps-dev): bump @typescript-eslint/eslint-plugin (#511)
dependabot[bot] May 28, 2024
023497f
update frontend open eh rsdk
mafasva May 29, 2024
fe8702a
update docker image
mafasva May 29, 2024
da1d8b2
aql editor - remove template restriction (#571)
mafasva Jun 3, 2024
b38f4a8
Update create-release-branch.yml
ramueSVA Jun 4, 2024
08703ae
Update release.yml
ramueSVA Jun 4, 2024
aea6652
Merge release branch '1.18.0' back to develop (#572)
github-actions[bot] Jun 4, 2024
8f46b46
Update release-new-tag.yml
ramueSVA Jun 5, 2024
a856036
Update release-new-tag.yml
ramueSVA Jun 5, 2024
e54a3d7
Feature/frontend chores (#575)
dirk-rossbach Jun 10, 2024
9727b5e
Update build-for-development.yml
ramueSVA Jun 18, 2024
664270f
Update release-new-tag.yml
ramueSVA Jun 18, 2024
f5ce24d
add link to public key for TEST on imprint page
Jul 4, 2024
1062fd1
Merge pull request #593 from NUM-Forschungsdatenplattform/featrure/NU…
ujanssen Jul 4, 2024
c8b575e
Feature/test new registry (#595)
ramueSVA Jul 15, 2024
08ff230
Redirect to the login page instead of the logout page, when the user …
askask Jul 15, 2024
c3c7706
Sort parameter on criteria page (#580)
askask Jul 15, 2024
ff6a852
Use correct class type for FROM clause on criteria page (#581)
askask Jul 15, 2024
a99725f
Use String as default type (#596)
fkaercher Jul 15, 2024
f6a8100
Do not initialise Idle twice (#583)
askask Jul 15, 2024
ec4ef87
Display useful input component for duration values on the search page…
askask Jul 15, 2024
b5341c6
Show units on search page (#584)
askask Jul 15, 2024
ddcd119
Feature/default convertrmtype (#599)
mafasva Jul 15, 2024
2b8806e
chore(deps): bump docker/build-push-action from 5 to 6 (#582)
dependabot[bot] Jul 17, 2024
6e2ac27
[skip ci] 1.19.0-SNAPSHOT
Jul 18, 2024
3606c3f
[skip ci] 1.19.0
web-flow Jul 18, 2024
6c4fade
Merge branch 'main' into release/1.19.0
mafasva Jul 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 7 additions & 10 deletions .github/workflows/build-for-development.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
with:
sarif_file: 'trivy-results.sarif'

docker:
registry:
needs: test_and_scan
if: github.event.pull_request.merged == true

Expand All @@ -60,17 +60,14 @@ jobs:
with:
node-version: '20'
cache: 'npm'
- name: Login to Docker Hub
- name: Log in to GitHub Container Registry
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
push: true
tags: numforschungsdatenplattform/num-portal-webapp:develop




tags: ghcr.io/num-forschungsdatenplattform/num-portal-webapp:develop
2 changes: 1 addition & 1 deletion .github/workflows/release-new-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push docker image
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
push: true
tags: numforschungsdatenplattform/num-portal-webapp:${{ github.ref_name }}
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "num-portal-webapp",
"version": "1.18.0",
"version": "1.19.0",
"scripts": {
"postinstall": "ngcc",
"ng": "ng",
Expand Down
2 changes: 1 addition & 1 deletion src/app/core/auth/auth.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ export class AuthService {
.toPromise()
.finally(() => {
if (!this.idle.isIdling()) {
this.initIdle()
this.resetIdle()
}
})
}
Expand Down
6 changes: 3 additions & 3 deletions src/app/core/interceptors/error.interceptor.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ describe('ErrorInterceptor', () => {
let errorInterceptor: ErrorInterceptor

const authService = {
logout: () => {},
login: () => {},
} as AuthService

const profileService = {
Expand Down Expand Up @@ -47,12 +47,12 @@ describe('ErrorInterceptor', () => {
const mockErrorResponse = { status: 401, statusText: 'Unauthorized' }
const data = 'Unauthorized'

jest.spyOn(injectedAuthService, 'logout')
jest.spyOn(injectedAuthService, 'login')

http.get('/data').subscribe()

httpMock.expectOne('/data').flush(data, mockErrorResponse)
expect(injectedAuthService.logout).toHaveBeenCalled()
expect(injectedAuthService.login).toHaveBeenCalled()
}
))
})
Expand Down
2 changes: 1 addition & 1 deletion src/app/core/interceptors/error.interceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export class ErrorInterceptor implements HttpInterceptor {
return next.handle(request).pipe(
catchError((err) => {
if (err.status === 401) {
this.authService.logout()
this.authService.login(window.location.href)
}
if (err.status === 403) {
this.profileService.setUnapproveUser(true)
Expand Down
10 changes: 5 additions & 5 deletions src/app/core/interceptors/oauth.interceptor.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ describe('OAuthInterceptor', () => {
} as OAuthStorage

const authService = {
logOut: () => {},
initCodeFlow: () => {},
} as OAuthService

beforeEach(() => {
Expand Down Expand Up @@ -75,12 +75,12 @@ describe('OAuthInterceptor', () => {
const mockErrorResponse = { status: 401, statusText: 'Unauthorized' }
const data = 'Unauthorized'

jest.spyOn(injectedAuthService, 'logOut')
jest.spyOn(injectedAuthService, 'initCodeFlow')

http.get('/data').subscribe()

httpMock.expectOne('/data').flush(data, mockErrorResponse)
expect(injectedAuthService.logOut).toHaveBeenCalled()
expect(injectedAuthService.initCodeFlow).toHaveBeenCalled()
}
))
})
Expand All @@ -92,12 +92,12 @@ describe('OAuthInterceptor', () => {
const mockErrorResponse = { status: 500, statusText: 'Internal Server Error' }
const data = 'Internal Server Error'

jest.spyOn(injectedAuthService, 'logOut')
jest.spyOn(injectedAuthService, 'initCodeFlow')

http.get('/data').subscribe()

httpMock.expectOne('/data').flush(data, mockErrorResponse)
expect(injectedAuthService.logOut).not.toHaveBeenCalled()
expect(injectedAuthService.initCodeFlow).not.toHaveBeenCalled()
}
))
})
Expand Down
2 changes: 1 addition & 1 deletion src/app/core/interceptors/oauth.interceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export class OAuthInterceptor implements HttpInterceptor {

private handleError(error: HttpErrorResponse): Observable<never> {
if (error.status === 401) {
this.oauthService.logOut()
this.oauthService.initCodeFlow(window.location.href)
} else if (error.status === 409 && error.url.includes('/admin/user/')) {
return of()
}
Expand Down
8 changes: 6 additions & 2 deletions src/app/core/services/aql-editor/aql-editor.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { IArchetypeQueryBuilderResponse } from 'src/app/shared/models/archetype-
import { IContainmentNode } from 'src/app/shared/models/archetype-query-builder/template/containment-node.interface'
import { IEhrbaseTemplate } from 'src/app/shared/models/archetype-query-builder/template/ehrbase-template.interface'
import { IDictionary } from 'src/app/shared/models/dictionary.interface'
import { compareLocaleStringValues } from '../../utils/sort.utils'

@Injectable({
providedIn: 'root',
Expand All @@ -34,8 +35,11 @@ export class AqlEditorService {
getTemplates(): Observable<IEhrbaseTemplate[]> {
return this.httpClient.get<IEhrbaseTemplate[]>(`${this.baseUrl}/template`).pipe(
tap((templates) => {
this.templates = templates
this.templatesSubject$.next(templates)
const tempSorted = templates.sort((a, b) =>
compareLocaleStringValues(a.description, b.description, a.templateId, b.templateId, true)
)
this.templates = tempSorted
this.templatesSubject$.next(tempSorted)
}),
catchError(this.handleError)
)
Expand Down
12 changes: 9 additions & 3 deletions src/app/core/utils/value-converter.utils.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { AqlParameterValueType } from 'src/app/shared/models/aql/aql-parameter-value-type.enum'
import { DateHelperService } from '../helper/date-helper.service'
import { Moment } from 'moment'
import { Duration, Moment } from 'moment'

export const convertParameterInputToType = (
type: AqlParameterValueType,
inputValue: string | number | boolean | Date | Moment,
inputValue: string | number | boolean | Date | Moment | Duration,
defaultToUndefined = false
): number | string | boolean => {
let outputValue: number | string | boolean
Expand All @@ -29,7 +29,13 @@ export const convertParameterInputToType = (
case AqlParameterValueType.Boolean:
outputValue = inputValue && inputValue !== 'false'
break

case AqlParameterValueType.Duration:
outputValue = inputValue
? (inputValue as Duration).toISOString()
: defaultToUndefined
? undefined
: ' '
break
default:
outputValue = inputValue ? inputValue.toString() : defaultToUndefined ? undefined : ' '
break
Expand Down
3 changes: 3 additions & 0 deletions src/app/layout/components/side-menu/side-menu.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ fa-icon {
display: flex;
justify-content: center;
align-items: center;
img {
padding: 10px 10px 10px 0;
}
}
.num-mat-list-item.highlighted {
color: #eb586a;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export class AqlConnectorItemComponent implements OnInit, OnDestroy {

this.prefillParameter(parameter, optionKeys)
this.setPossibleOperators(parameter, response.type)
parameter.unit = response.unit

this.checkParameterStatus()
parameter.isMetaFetched = true
Expand Down Expand Up @@ -159,6 +160,8 @@ export class AqlConnectorItemComponent implements OnInit, OnDestroy {
return AqlParameterValueType.DateTime
case ReferenceModelType.Dv_time:
return AqlParameterValueType.Time
case ReferenceModelType.Dv_duration:
return AqlParameterValueType.Duration

default:
return AqlParameterValueType.String
Expand Down
10 changes: 9 additions & 1 deletion src/app/modules/legal/components/imprint/imprint.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,14 @@ <h2>{{ 'IMPRINT.TEXTS.LINKS_TITLE' | translate }}</h2>
<h2>{{ 'IMPRINT.TEXTS.PUBLIC_KEYS_TITLE' | translate }}</h2>

<p>{{ 'IMPRINT.PUBLIC_KEY_LINKS.INTRO' | translate }}</p>
<p>
<a
[href]="'IMPRINT.PUBLIC_KEY_LINKS.LINK_TEST_HREF' | translate"
target="_blank"
rel="noopener"
>{{ 'IMPRINT.PUBLIC_KEY_LINKS.LINK_TEST_DESCRIPTION' | translate }}</a
>
</p>
<p>
<a
[href]="'IMPRINT.PUBLIC_KEY_LINKS.LINK_PRE_PROD_HREF' | translate"
Expand All @@ -77,5 +85,5 @@ <h2>{{ 'IMPRINT.TEXTS.PUBLIC_KEYS_TITLE' | translate }}</h2>
>{{ 'IMPRINT.PUBLIC_KEY_LINKS.LINK_PROD_DESCRIPTION' | translate }}</a
>
</p>
<p>Stand: 2023-04-26</p>
<p>Stand: 2025-07-04</p>
<div class="num-margin-b-40"></div>
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,15 @@ <h3 class="accordion" fxLayoutGap="8px">
</mat-form-field>
</section>

<!-- <section role="presentation" class="num-margin-b-10">
<num-attachments-table
[attachments]="attachments"
[isInPreview]="isInPreview"
[project]="project"
[showSelectColumn]="showAttachmentsSelect"
></num-attachments-table>
</section> -->

<section role="presentation" class="num-margin-b-10">
<num-attachments-table
[attachments]="attachments"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
type="text"
data-test="aql-parameter-inputs__value-input"
/>
<span *ngIf="item.unit" matSuffix>{{ item.unit }}</span>
</mat-form-field>

<mat-form-field
Expand Down Expand Up @@ -110,5 +111,34 @@
"
data-test="aql-parameter-inputs__time-value-input"
></num-time-input>

<mat-form-field
floatLabel="always"
appearance="outline"
class="input num-tiny-input value-input"
*ngIf="item.valueType === AqlParameterValueType.Duration"
>
<mat-label *ngIf="mode === 'cohortBuilder'" id="duration-label">{{ item.name }}</mat-label>
<mat-label *ngIf="mode === 'aqb' || !item.name" id="duration-label">{{
'FORM.VALUE' | translate
}}</mat-label>
<input
aria-labelledby="duration-label"
formControlName="value"
inputmode="numeric"
matInput
type="text"
data-test="aql-parameter-inputs__value-input"
(beforeinput)="numericValuesOnly($event)"
/>
<mat-select formControlName="unit" matSuffix>
<mat-option value="y">{{ 'UNITS.YEARS' | translate }}</mat-option>
<mat-option value="M">{{ 'UNITS.MONTHS' | translate }}</mat-option>
<mat-option value="d">{{ 'UNITS.DAYS' | translate }}</mat-option>
<mat-option value="h">{{ 'UNITS.HOURS' | translate }}</mat-option>
<mat-option value="m">{{ 'UNITS.MINUTES' | translate }}</mat-option>
<mat-option value="s">{{ 'UNITS.SECONDS' | translate }}</mat-option>
</mat-select>
</mat-form-field>
</ng-container>
</section>
Loading
Loading