Skip to content

Commit

Permalink
Merge pull request #331 from CruGlobal/toolOrdering
Browse files Browse the repository at this point in the history
GT-1157 Add support for setting the tool order in the details UI
  • Loading branch information
frett authored Apr 23, 2021
2 parents b303a25 + b0a6099 commit e14df6a
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 3 deletions.
28 changes: 25 additions & 3 deletions src/app/components/edit-resource/edit-resource.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@
</div>
<div class="col">
<input
class="form-control"
placeholder="Youtube Video Id"
[(ngModel)]="resource.aboutOverviewVideoYoutube"
/>
Expand All @@ -94,7 +95,11 @@
<label>Banner</label>
</div>
<div class="col">
<input placeholder="Attachment Id" [(ngModel)]="resource.banner" />
<input
class="form-control"
placeholder="Attachment Id"
[(ngModel)]="resource.banner"
/>
</div>
</div>

Expand All @@ -103,13 +108,30 @@
<label>Banner (About)</label>
</div>
<div class="col">
<input placeholder="Attachment Id" [(ngModel)]="resource.bannerAbout" />
<input
class="form-control"
placeholder="Attachment Id"
[(ngModel)]="resource.bannerAbout"
/>
</div>
</div>

<div class="row">
<div class="col">
<label>Order</label>
</div>
<div class="col">
<input
class="form-control"
placeholder="Order"
[(ngModel)]="resource['attr-default-order']"
/>
</div>
</div>

<div class="row">
<div class="col">
<label>Manifest</label>
<label>Manifest XML</label>
</div>
</div>
<div class="row">
Expand Down
1 change: 1 addition & 0 deletions src/app/models/resource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export class Resource {
aboutOverviewVideoYoutube?: string;
bannerAbout?: number;
banner?: number;
'attr-default-order'?: number;

static getResourceTypeId(resource: Resource): number {
return resource.resourceType ? resource.resourceType.id : null;
Expand Down
1 change: 1 addition & 0 deletions src/app/service/resource/resource.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ export class ResourceService extends AbstractService {
'attr-banner-about': resource.bannerAbout || null,
'attr-about-overview-video-youtube':
resource.aboutOverviewVideoYoutube || null,
'attr-default-order': resource['attr-default-order'] || null,
},
},
};
Expand Down

0 comments on commit e14df6a

Please sign in to comment.