Add parents field to logEntry soy data for use in custom templates Adding this field will enable custom templates to render parent shas in the log template. Bug: Google b/291754461 Change-Id: Ie951cb4816920e3c75e8de28c583312f2b8e06a5
diff --git a/java/com/google/gitiles/LogSoyData.java b/java/com/google/gitiles/LogSoyData.java index 34b290f..9cffbb3 100644 --- a/java/com/google/gitiles/LogSoyData.java +++ b/java/com/google/gitiles/LogSoyData.java
@@ -47,7 +47,8 @@ Field.AUTHOR, Field.COMMITTER, Field.BRANCHES, - Field.TAGS); + Field.TAGS, + Field.PARENTS); private static final ImmutableSet<Field> VERBOSE_FIELDS = Field.setOf(FIELDS, Field.DIFF_TREE); /** Behavior for the footer link when rendering streaming log data. */
diff --git a/resources/com/google/gitiles/templates/LogDetail.soy b/resources/com/google/gitiles/templates/LogDetail.soy index 23ae8eb..095edbb 100644 --- a/resources/com/google/gitiles/templates/LogDetail.soy +++ b/resources/com/google/gitiles/templates/LogDetail.soy
@@ -108,6 +108,7 @@ {@param author: ?} /** author information with at least "name" and "relativeTime" keys. */ {@param committer: ?} /** committer information with at least "time" and "relativeTime" keys. */ {@param branches: ?} /** list of branches for this entry, with "name" and "url" keys. */ + {@param parents: ?} /** unused in this variant. */ {@param tags: ?} /** list of tags for this entry, with "name" and "url" keys. */ {@param diffTree: ?} /** unused in this variant. */ {@param rename: ?} /** if this entry was a rename or a copy of the path, an object containg: @@ -165,6 +166,7 @@ {@param author: ?} /** author information with at least "name" and "relativeTime" keys. */ {@param committer: ?} /** committer information with at least "time" and "relativeTime" keys. */ {@param branches: ?} /** list of branches for this entry, with "name" and "url" keys. */ + {@param parents: ?} /** unused in this variant. */ {@param tags: ?} /** list of tags for this entry, with "name" and "url" keys. */ {@param diffTree: ?} /** unused in this variant. */ {@param rename: ?} /** if this entry was a rename or a copy of the path, an object containg: @@ -192,6 +194,7 @@ {@param author: ?} /** author information with at least "name" and "relativeTime" keys. */ {@param committer: ?} /** committer information with at least "time" and "relativeTime" keys. */ {@param branches: ?} /** list of branches for this entry, with "name" and "url" keys. */ + {@param parents: ?} /** unused in this variant. */ {@param tags: ?} /** list of tags for this entry, with "name" and "url" keys. */ {@param diffTree: ?} /** unused in this variant. */ {@param rename: ?} /** if this entry was a rename or a copy of the path, an object containg: