summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@users.noreply.github.com>2017-11-01 16:56:03 +0100
committerGitHub <noreply@github.com>2017-11-01 16:56:03 +0100
commit71b5f850bf4d0bfbf8dae445ac38513aadd6c7dc (patch)
treed4720f4ee1209566b8a85db908ec8c26a5a0b210 /templates
parent7100d4bcc5c7cfc44c61a0ac6aee1c1d245ad28c (diff)
parent7bc5e2c40cafc8fce9da68e51c4646ed15e69b7f (diff)
Merge pull request #419 from nextcloud/propertyGroups
Property groups
Diffstat (limited to 'templates')
-rw-r--r--templates/contactDetails.html6
-rw-r--r--templates/propertyGroup.html6
2 files changed, 8 insertions, 4 deletions
diff --git a/templates/contactDetails.html b/templates/contactDetails.html
index 92131b92..58a2f2d2 100644
--- a/templates/contactDetails.html
+++ b/templates/contactDetails.html
@@ -42,10 +42,8 @@
</div>
</header>
<section>
- <div ng-repeat="prop in ctrl.contact.props | toArray | orderDetailItems:'$key'">
- <detailsItem ng-repeat="propData in prop" name="prop.$key" data="propData" model="ctrl" index="$index"
- class="details-item-{{prop.$key}}" ng-class="{ 'failed': ctrl.contact.failedProps.indexOf(prop.$key) !== -1 }"></detailsItem>
- </div>
+ <propertyGroup ng-repeat="prop in ctrl.contact.props | toArray | orderDetailItems:'$key'" model="ctrl.contact" data="prop" name="prop.$key"></propertyGroup>
+
<div class="select-addressbook" ng-if="ctrl.addressBooks.length > 1 && !ctrl.addressBook.readOnly">
<label for="details-addressbook">{{ctrl.t.addressBook}}</label>
<select ng-model="ctrl.addressBook" ng-change="ctrl.changeAddressBook(ctrl.addressBook)" id="details-addressbook"
diff --git a/templates/propertyGroup.html b/templates/propertyGroup.html
new file mode 100644
index 00000000..e25ba091
--- /dev/null
+++ b/templates/propertyGroup.html
@@ -0,0 +1,6 @@
+<h3 class="propertyGroup__title">
+ <i ng-class="ctrl.getIconClass()"></i>
+ {{ctrl.getReadableName()}}
+</h3>
+<detailsItem ng-repeat="property in ctrl.properties" name="ctrl.name" data="property" model="ctrl.contact" index="$index"
+ class="details-item-{{ctrl.name}}" ng-class="{ 'failed': ctrl.contact.failedProps.indexOf(ctrl.name) !== -1 }"></detailsItem>