Skip to content

Conversation

@dupe-codes
Copy link
Contributor

Previously on the send email page of the instructor dashboard, instructors could only view task information about emails they've sent for their course in the past.
In addition to this, I've now added the ability to see the content of all previously sent emails. A "show email content history" button has been added to the page. When clicked, a table displaying the subject line, number of emails sent, and date/time of submission for each previously sent email is created. An instructor can then click on any subject line to see the content of that email, displayed in a modal window that appears on the page. The window is also equipped with a "copy email body to editor" button, which copies the emails contents to the tinyMCE editor, so that an instructor can easily resend an email that they've sent in the past.

This PR addresses some aspects of this ticket: https://openedx.atlassian.net/browse/LMS-10345

@dupe-codes
Copy link
Contributor Author

@jinpa @jrbl @sarina
Here are some screenshots of the different UI components:
Content History Table: https://flic.kr/p/o4X65y
Email Content Modal: https://flic.kr/p/ooczPr
Content pasted into editor: https://flic.kr/p/o4XYtK

@jinpa
Copy link
Contributor

jinpa commented Jul 16, 2014

These screenshots LGTM!

On Wed, Jul 16, 2014 at 11:53 AM, Nicholas Dupoux notifications@github.com
wrote:

@jinpa https://github.com/jinpa @jrbl https://github.com/jrbl @sarina
https://github.com/sarina
Here are some screenshots of the different UI components:
Content History Table: https://flic.kr/p/o4X65y
Email Content Modal: https://flic.kr/p/ooczPr
Content pasted into editor: https://flic.kr/p/o4XYtK


Reply to this email directly or view it on GitHub
https://github.com/edx/edx-platform/pull/4451#issuecomment-49210132.

@sarina
Copy link
Contributor

sarina commented Jul 16, 2014

Hi @njdup - right now we're sprinting towards a few commitments that are very time-sensitive. I hope to take a first pass at this PR over the coming weekend (perhaps evenings if I can manage it!) because I really do want to get this feature in. Once I take a first pass, I'll be able to have a good estimate of what type of UX and doc support we'll need to get this merged in. Thanks for your patience!

@dupe-codes
Copy link
Contributor Author

@sarina Thanks for the heads up and its no problem at all, take all the time you need!

@jrbl
Copy link
Contributor

jrbl commented Jul 16, 2014

Has @caesar2164 looked it over to confirm it meets our usual standards?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you probably should remove this line… :P

@jrbl
Copy link
Contributor

jrbl commented Jul 16, 2014

You can catch a lot of nitpicky cosmetic things by running:
for FILE in git diff --name-only HEAD~1 | grep '.py$'; do pep8 $FILE; done on your branch inside your devstack box. A lot (most? all?) of these aren't introduced by your changes, but cleaning them up would be good citizenship. You can comment on those lines of diff here in github that that's what you were doing, so reviewers know which bits they can just skim past.

@jrbl
Copy link
Contributor

jrbl commented Jul 16, 2014

The cells in your Content History Table screenshot look really big. Couldn't those be made less tall?

@jrbl
Copy link
Contributor

jrbl commented Jul 16, 2014

I like the email content modal.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can cut this line altogether

@caesar2164
Copy link
Contributor

@njdup - remember to add padding to cells, make email title more visible as links, and move button in modal to top right.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not wild about mixing strings and numbers or hardcoding strings. Would it work to set this to None if it breaks, and have whatever consumes email_feature_dict know that for number_sent None means unknown? It sort of looks like you're already doing this in the coffeescript anyway...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh great point joe, setting it to None works since I check for it in my coffeescript table rendering anyway :)

@dupe-codes
Copy link
Contributor Author

Added styling feedback from @caesar2164.
Here are updated screens
Table: https://flic.kr/p/ojz3o3
Modal window: https://flic.kr/p/omAVsH

I'll work on incorporating your feedback next @jrbl. Thanks guys :)

@dupe-codes
Copy link
Contributor Author

@sjang92

@jrbl
Copy link
Contributor

jrbl commented Jul 17, 2014

Those screenshots are pretty pretty.

On Wed, Jul 16, 2014 at 5:16 PM, Nicholas Dupoux notifications@github.com
wrote:

Added styling feedback from @caesar2164 https://github.com/caesar2164.
Here are updated screens
Table: https://flic.kr/p/ojz3o3
Modal window: https://flic.kr/p/omAVsH

I'll work on incorporating your feedback next @jrbl
https://github.com/jrbl. Thanks guys :)


Reply to this email directly or view it on GitHub
https://github.com/edx/edx-platform/pull/4451#issuecomment-49244801.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use <p>, not <h1>

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Click on an email's subject line to see the message content."

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually let's do this it looks great: <p><em>"Click on an email's subject line to see the message content."</em></p> <br />
screen shot 2014-07-30 at 4 34 12 pm

At this point it would be easier, and better, to just do this in the template. Add a new

class region with the appropriate stylings and then populate it with text.

@sarina
Copy link
Contributor

sarina commented Jul 30, 2014

@jinpa sure - actually I think if my num. 2 recommendation is implemented, it obviates the confusing workflow that we were seeing. So yeah, let's not clear on send - but do clear before loading in something from history.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UX would like a different layout here. I mocked out what they want (easier than drawing), but implementing it will require a bit of changes to your Coffeescript since there are new divs with new names. Note too the addition of new text and a change to the text value of the button.

https://gist.github.com/sarina/e13de1346bddaa014e1e

@sarina
Copy link
Contributor

sarina commented Jul 30, 2014

Overall UX was primarily concerned with the page layout as well as your Sass scoping rules and modal overrides (use the default inherited style wherever possible - may require changing your variable names so the right rules are picked up). Otherwise they were very impressed - they like the table and the modal, very clear and easy to use.

@sarina
Copy link
Contributor

sarina commented Jul 30, 2014

Also, you're going to need to rebase your PR before we can merge it, regrettably :(

@jinpa
Copy link
Contributor

jinpa commented Jul 30, 2014

@sarina that sounds sane to me.

On Wed, Jul 30, 2014 at 1:36 PM, Sarina Canelake notifications@github.com
wrote:

@jinpa https://github.com/jinpa sure - actually I think if my num. 2
recommendation is implemented, it obviates the confusing workflow that we
were seeing. So yeah, let's not clear on send - but do clear before loading
in something from history.


Reply to this email directly or view it on GitHub
https://github.com/edx/edx-platform/pull/4451#issuecomment-50675890.

@dupe-codes
Copy link
Contributor Author

@sarina Quick question with regards to design review comment #2: if we'll be clearing the subject line box when the "copy email body to editor" button is pressed, would it make sense for the old email subject line to be copied as well?

@sarina
Copy link
Contributor

sarina commented Jul 31, 2014

I think it makes sense to copy the subject as well. Although I'm interested
to know how @jinpa feels.
On Jul 31, 2014 5:51 PM, "Nicholas Dupoux" notifications@github.com wrote:

@sarina https://github.com/sarina Quick question with regards to design
review comment #2 edx#2: if we'll
be clearing the subject line box when the "copy email body to editor"
button is pressed, would it make sense for the old email subject line to be
copied as well?


Reply to this email directly or view it on GitHub
https://github.com/edx/edx-platform/pull/4451#issuecomment-50823854.

@dupe-codes
Copy link
Contributor Author

Just passed it by her and she agrees. Thanks :)

@dupe-codes
Copy link
Contributor Author

@sarina per the UI feedback from you and the design time, I've made the following changes:

  • The modal close button has been changed to match the modal close buttons everywhere else in lms
  • The page layout for send_email.html has been changed to match the layout suggested
  • The styles I've added in _email.scss have all been scoped under the "email-background" class
  • Clicking the button to copy an email no longer appends to the end of the editor contents, but instead replaces the contents. The subject line is also replaced. I've changed the text on the button now to "Copy Email to Editor," to reflect that its not just the message body that is copied.
  • Italics in an email are now shown properly in the modal window, and I've tested the other styling provided by tinyMCE, which all seem to be working and rendered properly :)
  • The "Click an email's subject line to see the message content ," message has been moved into the send_email.html template, with desired styling.

I've also rebased and squashed. I think that should be everything, let me know if I missed anything :)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@njdup, could you provide a screenshot of where this will appear? (Generally I'd suggest following the "problem first, solution second" style that (mostly) is used on the dashboard, but would like to see the context.)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"To see the content of all previously sent emails, click this button:"

(@sarina, I validated the problem first, action second" structure with @frrrances (UX).)

@sarina
Copy link
Contributor

sarina commented Aug 1, 2014

@lamagnifica I'm trying to spin up a sandbox w/ this on it so you can test and take screenshots that you need. However, it's not working - looks like another commit (not this one) has broken Javascript across a lot of pages. Until we can fix that issue we won't be able to merge this anyway. So let's sit tight.

@sarina
Copy link
Contributor

sarina commented Aug 1, 2014

@lamagnifica I've got this running now on a sandbox. Please visit http://njdup.m.sandbox.edx.org/ and test it out by visiting the Instructor Dashboard > Email tab ❗ 😄

@dupe-codes
Copy link
Contributor Author

Awesome, just let me know what decisions are made and I'm ready to revise as needed :)

@sarina
Copy link
Contributor

sarina commented Aug 4, 2014

@njdup please make the last two changes suggested by @lamagnifica and then we'll click the button!

Previously on the send email page of the instructor dashboard, instructors could only view
task information about emails they've sent for their course in the past.
In addition to this, I've now added the ability to see the content of all previously sent emails.

A "Sent Email History" button has been added to the page. When clicked, a table displaying the
subject line, number of emails sent, and date/time of submission for each previously sent email
is created. An instructor can then click on any subject line to see the content of that email,
displayed in a modal window that appears on the page.

The window is also equipped with a "copy email to editor" button, which copies the emails contents
to the tinyMCE editor, so that an instructor can easily resend an email that they've sent
in the past.
@dupe-codes
Copy link
Contributor Author

@lamagnifica Thanks for taking a look at this and for your suggestions! @sarina I've made the final changes and rebased, everything should be up to date and ready to go :)

@sarina
Copy link
Contributor

sarina commented Aug 4, 2014

@njdup thanks so much for this contribution. I'm so happy to have it and it's been a real pleasure working with you! I'll merge it once a build's been run on it!

@dupe-codes
Copy link
Contributor Author

Thanks @sarina, it's been a pleasure working with you too :)

@lamagnifica
Copy link

👍 The task to document this feature will be in the next documentation team sprint (starts tomorrow).

@sarina
Copy link
Contributor

sarina commented Aug 4, 2014

sarina added a commit that referenced this pull request Aug 4, 2014
…history

Instructors can view previously sent email content
@sarina sarina merged commit 3af43cd into openedx:master Aug 4, 2014
@dupe-codes dupe-codes deleted the njdupoux/email-content-history branch August 5, 2014 03:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

open-source-contribution PR author is not from Axim or 2U

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants