Skip to content

Commit

Permalink
WEBUI-1067: fix compare versions show data for multivalued fields
Browse files Browse the repository at this point in the history
  • Loading branch information
swarnadipa-dev committed Apr 5, 2023
1 parent e66a870 commit 8746e00
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions elements/diff/elements/nuxeo-directory-arr-diff.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,49 @@
</div>
</template>
<div class="value simple">
<!-- no changes -->
<template is="dom-if" if="[[_hasNoChanges(delta, originalValue)]]">
<!-- simple value-->
<template is="dom-if" if="[[_isNotObjectNorArray(originalValue)]]">
<span>[[originalValue]]</span>
</template>
<!-- array -->
<template is="dom-if" if="[[_isArray(originalValue)]]">
<div class$="array [[_computeArrayClass(delta, originalValue, newValue, hideAdditions, hideDeletions)]]">
<template is="dom-repeat" items="[[originalValue]]" as="value">
<div class="item">
<nuxeo-object-diff
original-value="[[value]]"
schema="[[_getPropertySchema(schema, property)]]"
type="[[_arrayItemType(type)]]"
level="[[level]]"
unified="[[unified]]"
show-all="[[showAll]]"
label="[[index]]:"
is-array-item
display-label
></nuxeo-object-diff>
</div>
</template>
</div>
</template>
<!-- object -->
<template is="dom-if" if="[[_isObject(originalValue)]]">
<div class="object">
<template is="dom-repeat" items="[[_getKeys(originalValue)]]" as="subproperty">
<nuxeo-object-diff
property="[[subproperty]]"
original-value="[[_getValue(originalValue, subproperty)]]"
schema="[[_getPropertySchema(schema, property)]]"
level="[[_incLevel(level)]]"
unified="[[unified]]"
show-all="[[showAll]]"
display-label
></nuxeo-object-diff>
</template>
</div>
</template>
</template>
<!-- arrays with inner changes -->
<template is="dom-if" if="[[_hasArrayInnerChanges(delta)]]">
<div class="array diff simple">
Expand Down

0 comments on commit 8746e00

Please sign in to comment.