mozilla/zamboni — pull request #1234 by ngokevin (2013-10-09 18:54:27+00:00)
Title: migrate activity log to commbadge notes (bug 920743)

As a command.

Might be notable to look at the mapping ActivityLog actions to Commbadge actions, check if I missed or mis-mapped anything.

+def _action_map(activity_action):
+ """Maps ActivityLog action ids to Commbadge note types."""
+ return {
+ amo.LOG.APPROVE_VERSION.id: 'approve',
+ amo.LOG.APPROVE_VERSION_WAITING.id: 'approve',
+ amo.LOG.REJECT_VERSION.id: 'reject',
+ amo.LOG.APP_DISABLED.id: 'disable',
+ amo.LOG.REQUEST_INFORMATION.id: 'info',
+ amo.LOG.ESCALATE_VERSION.id: 'escalate',
+ amo.LOG.ESCALATION_CLEARED.id: 'escalate',
+ amo.LOG.ESCALATED_HIGH_ABUSE.id: 'escalate',
+ amo.LOG.ESCALATED_HIGH_REFUNDS.id: 'escalate',
+ amo.LOG.COMMENT_VERSION.id: 'comment',
+ amo.LOG.WEBAPP_RESUBMIT.id: 'resubmit',
+ }.get(activity_action, 'no_action')

**Some migrated notes**

The ```modified``` is from when I ran the command. The ```created``` is from when the original ```ActivityLog``` was created.

![screen shot 2013-10-09 at 11 52 30 am](https://f.cloud.github.com/assets/674727/1300568/0f6a7cb2-3114-11e3-8ffc-67b454326f0a.png)