diff --git a/addon/components/link-building-modal.hbs b/addon/components/link-building-modal.hbs
new file mode 100644
index 00000000..f903cabf
--- /dev/null
+++ b/addon/components/link-building-modal.hbs
@@ -0,0 +1,44 @@
+
+
+
+ {{t "ember-gwr.components.linkBuildingModal.linkBuilding"}}
+
+
+
+ {{#let
+ (component
+ "project-form/field"
+ project=this.buildingWork
+ translationBase="ember-gwr.buildingWork"
+ ) as |Field|
+ }}
+
+
+
+
+
+
+
+
+
+
+ {{/let}}
+
+
+
+ {{t "ember-gwr.components.linkBuildingModal.cancel"}}
+
+
+ {{t "ember-gwr.components.linkBuildingModal.linkBuilding"}}
+
+
+
diff --git a/addon/components/link-building-modal.js b/addon/components/link-building-modal.js
new file mode 100644
index 00000000..231b4eaa
--- /dev/null
+++ b/addon/components/link-building-modal.js
@@ -0,0 +1,19 @@
+import Component from "@glimmer/component";
+import { tracked } from "@glimmer/tracking";
+import { kindOfWorkOptions } from "ember-ebau-gwr/models/options";
+
+export default class LinkBuildingModalComponent extends Component {
+ @tracked buildingWork = {
+ constructionWorkDone: kindOfWorkOptions[0],
+ energeticRestauration: false,
+ renovationHeatingsystem: false,
+ innerConversionRenovation: false,
+ conversion: false,
+ extensionHeighteningHeated: false,
+ extensionHeighteningNotHeated: false,
+ thermicSolarFacility: false,
+ photovoltaicSolarFacility: false,
+ otherWorks: false,
+ };
+ kindOfWorkOptions = kindOfWorkOptions;
+}
diff --git a/addon/components/linked-models.hbs b/addon/components/linked-models.hbs
new file mode 100644
index 00000000..e478e416
--- /dev/null
+++ b/addon/components/linked-models.hbs
@@ -0,0 +1,82 @@
+{{#let (t (concat "ember-gwr.models." @modelName)) as |modelName|}}
+
+
+
+
+ {{t
+ "ember-gwr.components.linkedModels.linkedEntries"
+ modelName=modelName
+ }}
+ |
+
+
+
+ {{#each @models as |model|}}
+
+ {{#if hasBlock}}
+ {{yield model}}
+ {{else}}
+
+
+ {{get model @idAttr}}
+
+ |
+
+ {{get model @descriptionAttr}}
+ |
+ {{/if}}
+ {{#unless @noDeleteButton}}
+
+
+ |
+ {{/unless}}
+
+ {{else}}
+
+
+ {{t
+ "ember-gwr.components.linkedModels.noLinkedEntries"
+ modelName=modelName
+ }}
+ |
+
+ {{/each}}
+
+
+
+
+
+ {{t
+ "ember-gwr.components.linkedModels.linkEntry"
+ modelName=modelName
+ }}
+
+ {{t "ember-gwr.components.linkedModels.or"}}
+
+ {{t
+ "ember-gwr.components.linkedModels.createEntry"
+ modelName=modelName
+ }}
+
+ |
+
+
+
+{{/let}}
diff --git a/addon/components/linked-projects-table.hbs b/addon/components/linked-projects-table.hbs
deleted file mode 100644
index 4968dd7a..00000000
--- a/addon/components/linked-projects-table.hbs
+++ /dev/null
@@ -1,60 +0,0 @@
-
-
-
-
- {{t "ember-gwr.components.linkedProjectsTable.linkedProjects"}}
- |
-
-
-
- {{#each @projects as |project|}}
-
-
-
- {{project.EPROID}}
-
- |
-
- {{project.constructionProjectDescription}}
- |
-
- {{#if (eq @activeProject project.EPROID)}}
-
- {{/if}}
- |
-
- {{else}}
-
-
- {{t "ember-gwr.components.linkedProjectsTable.noLinkedProjects"}}
- |
-
- {{/each}}
-
-
-
-
-
- {{t "ember-gwr.components.linkedProjectsTable.linkProject"}}
-
- {{t "ember-gwr.components.linkedProjectsTable.or"}}
-
- {{t "ember-gwr.components.linkedProjectsTable.createProject"}}
-
- |
-
-
-
diff --git a/addon/components/linked-projects.hbs b/addon/components/linked-projects.hbs
new file mode 100644
index 00000000..3b2236e2
--- /dev/null
+++ b/addon/components/linked-projects.hbs
@@ -0,0 +1,33 @@
+
+
+
+ {{project.EPROID}}
+
+ |
+
+ {{project.constructionProjectDescription}}
+ |
+
+ {{#if (eq @activeProject project.EPROID)}}
+
+ {{/if}}
+ |
+
diff --git a/addon/components/project-form/checkbox.hbs b/addon/components/project-form/checkbox.hbs
new file mode 100644
index 00000000..f604f82e
--- /dev/null
+++ b/addon/components/project-form/checkbox.hbs
@@ -0,0 +1,11 @@
+
+
+
diff --git a/addon/components/project-form/checkbox.js b/addon/components/project-form/checkbox.js
new file mode 100644
index 00000000..cd14fc64
--- /dev/null
+++ b/addon/components/project-form/checkbox.js
@@ -0,0 +1,9 @@
+import { action } from "@ember/object";
+import Component from "@glimmer/component";
+
+export default class ProjectFormCheckboxComponent extends Component {
+ @action
+ update(event) {
+ this.args.update(event.target.checked);
+ }
+}
diff --git a/addon/components/project-form/field.hbs b/addon/components/project-form/field.hbs
index e8c16315..1b77f3da 100644
--- a/addon/components/project-form/field.hbs
+++ b/addon/components/project-form/field.hbs
@@ -17,6 +17,7 @@
@required={{@required}}
@value={{get @project @attr}}
@options={{@options}}
+ @noPlaceholder={{@noPlaceholder}}
@update={{fn (or @update this.updateProjectField) @attr}}
@translationBase={{@translationBase}}
disabled={{this.disableInput}}
diff --git a/addon/components/project-form/select.hbs b/addon/components/project-form/select.hbs
index df06e07f..2c91c6fc 100644
--- a/addon/components/project-form/select.hbs
+++ b/addon/components/project-form/select.hbs
@@ -4,9 +4,11 @@
required={{@required}}
...attributes
>
-
+ {{#unless @noPlaceholder}}
+
+ {{/unless}}
{{#each @options as |optionValue|}}