addressed:
title: Addressed
type: boolean
+ nullable: true
CommentUpdate:
type: object
properties:
addressed:
title: Addressed
type: boolean
+ nullable: true
CoverList:
type: object
properties:
addressed:
title: Addressed
type: boolean
+ nullable: true
CommentUpdate:
type: object
properties:
addressed:
title: Addressed
type: boolean
+ nullable: true
{% endif %}
CoverList:
type: object
addressed:
title: Addressed
type: boolean
+ nullable: true
CommentUpdate:
type: object
properties:
addressed:
title: Addressed
type: boolean
+ nullable: true
CoverList:
type: object
properties:
};
updateProperty(url, data, updateMessage).then(isSuccess => {
if (isSuccess) {
- $("div[class^='comment-status-bar-'][data-comment-id='"+commentId+"']").toggleClass("hidden");
+ // The API won't accept anything but true or false, so we
+ // always hide the -action-required element
+ $("div[class='comment-status-bar-action-required'][data-comment-id='"+commentId+"']").addClass("hidden");
+
+ if (event.target.value === "true") {
+ $("div[class^='comment-status-bar-addressed'][data-comment-id='"+commentId+"']").removeClass("hidden");
+ $("div[class^='comment-status-bar-unaddressed'][data-comment-id='"+commentId+"']").addClass("hidden");
+ } else if (event.target.value === "false") {
+ $("div[class^='comment-status-bar-addressed'][data-comment-id='"+commentId+"']").addClass("hidden");
+ $("div[class^='comment-status-bar-unaddressed'][data-comment-id='"+commentId+"']").removeClass("hidden");
+ }
}
})
});
toggleDiv("toggle-related-outside", "related-outside", "show from other projects");
});
}
-});
\ No newline at end of file
+});
migrations.AddField(
model_name='covercomment',
name='addressed',
- field=models.BooleanField(default=False),
+ field=models.BooleanField(null=True),
),
migrations.AddField(
model_name='patchcomment',
name='addressed',
- field=models.BooleanField(default=False),
+ field=models.BooleanField(null=True),
),
]
related_query_name='comment',
on_delete=models.CASCADE,
)
- addressed = models.BooleanField(default=False)
+ addressed = models.BooleanField(null=True)
@property
def list_archive_url(self):
related_query_name='comment',
on_delete=models.CASCADE,
)
- addressed = models.BooleanField(default=False)
+ addressed = models.BooleanField(null=True)
@property
def list_archive_url(self):
<span class="message-date">{{ item.date }} UTC |
<a href="{% url 'comment-redirect' comment_id=item.id %}">#{{ forloop.counter }}</a>
</span>
- {% if item.addressed %}
+ {% if item.addressed == None %}
+ <div class="comment-status-bar-action-required" data-comment-id={{item.id}}>
+ {% else %}
+ <div class="comment-status-bar-action-required hidden" data-comment-id={{item.id}}>
+ {% endif %}
+ {% if editable or comment_is_editable %}
+ <button class="comment-action-unaddressed text-warning" value="false">
+ <span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>
+ Mark Action Required
+ </button>
+ {% endif %}
+ </div>
+ {% if item.addressed == True %}
<div class="comment-status-bar-addressed" data-comment-id={{item.id}}>
{% else %}
<div class="comment-status-bar-addressed hidden" data-comment-id={{item.id}}>
</button>
{% endif %}
</div>
- {% if item.addressed %}
- <div class="comment-status-bar-unaddressed hidden" data-comment-id={{item.id}}>
- {% else %}
+ {% if item.addressed == False %}
<div class="comment-status-bar-unaddressed" data-comment-id={{item.id}}>
+ {% else %}
+ <div class="comment-status-bar-unaddressed hidden" data-comment-id={{item.id}}>
{% endif %}
<div class="comment-status-label text-warning mx-3">
<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span>