Skip to content

Commit

Permalink
chore(resource): hide file value in properties (DSP-1261) (#484)
Browse files Browse the repository at this point in the history
  • Loading branch information
kilchenmann committed Jul 13, 2021
1 parent 4d0703f commit 4ade17f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
Expand Up @@ -76,7 +76,13 @@ <h3 class="label mat-title">
<!-- list of properties -->
<div *ngFor="let prop of resource.resProps; let last = last">
<!-- show property; all in case of showAll === true or only the ones with prop.values -->
<div *ngIf="!prop.propDef['isLinkProperty'] && showAllProps || ( prop.values && prop.values.length > 0 )"
<div *ngIf="(showAllProps || ( prop.values && prop.values.length > 0 )) &&
(!prop.propDef['isLinkProperty'] &&
prop.guiDef.propertyIndex !== representationConstants.stillImage &&
prop.guiDef.propertyIndex !== representationConstants.movingImage &&
prop.guiDef.propertyIndex !== representationConstants.audio &&
prop.guiDef.propertyIndex !== representationConstants.document &&
prop.guiDef.propertyIndex !== representationConstants.text)"
[class.border-bottom]="prop.values && !last"
class="property">
<div class="property-label">
Expand Down
8 changes: 8 additions & 0 deletions src/app/workspace/resource/properties/properties.component.ts
Expand Up @@ -82,6 +82,14 @@ export class PropertiesComponent implements OnInit, OnChanges, OnDestroy {

valueOperationEventSubscriptions: Subscription[] = []; // array of ValueOperationEvent subscriptions

representationConstants = {
'stillImage': Constants.HasStillImageFileValue,
'movingImage': Constants.HasMovingImageFileValue,
'audio': Constants.HasAudioFileValue,
'document': Constants.HasDocumentFileValue,
'text': Constants.HasTextFileValue
};

project: ReadProject;
user: ReadUser;

Expand Down

0 comments on commit 4ade17f

Please sign in to comment.