FEATURE: show "edit message" button on message footer for staff

Show "Edit Message" button on personal message footer for staff if PM tagging is enabled.
This commit is contained in:
Arpit Jalan
2018-02-26 21:58:37 +05:30
parent 410b90dde0
commit 4010d8d9f9
7 changed files with 58 additions and 1 deletions

View File

@ -173,6 +173,14 @@ QUnit.test("Updating the topic title with emojis", assert => {
});
});
QUnit.test("does not show 'edit first post' button on topic/pm footer", assert => {
visit("/t/pm-for-testing/12");
andThen(() => {
assert.ok(!exists('.edit-message'), 'it does not show edit button');
});
});
acceptance("Topic featured links", {
loggedIn: true,
settings: {
@ -199,3 +207,19 @@ QUnit.test("remove featured link", assert => {
// assert.ok(!exists('.title-wrapper .topic-featured-link'), 'link is gone');
// });
});
acceptance("Personal message footer", {
loggedIn: true,
settings: {
allow_staff_to_tag_pms: true,
tagging_enabled: true
}
});
QUnit.test("shows edit 'first post button' on PM footer", assert => {
visit("/t/pm-for-testing/12");
andThen(() => {
assert.ok(exists('.edit-message'), 'it shows the edit button');
});
});