Daniel Holbach has proposed merging lp:~dholbach/harvest/581719 into lp:harvest.
Requested reviews: harvest-dev (harvest-dev) Related bugs: #581719 Speed up "making opportunities go away" https://bugs.launchpad.net/bugs/581719 -- https://code.launchpad.net/~dholbach/harvest/581719/+merge/37597 Your team harvest-dev is requested to review the proposed merge of lp:~dholbach/harvest/581719 into lp:harvest.
=== modified file 'harvest/locale/harvest.pot' --- harvest/locale/harvest.pot 2010-09-03 13:23:33 +0000 +++ harvest/locale/harvest.pot 2010-10-05 13:33:45 +0000 @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-09-03 07:35-0500\n" +"POT-Creation-Date: 2010-10-05 08:30-0500\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <em...@address>\n" "Language-Team: LANGUAGE <[email protected]>\n" @@ -355,10 +355,26 @@ "\t" msgstr "" -#: templates/opportunities/include/opportunity.html:7 +#: templates/opportunities/include/opportunity.html:6 msgid "edit" msgstr "" +#: templates/opportunities/include/opportunity.html:7 +msgid "mark opportunity as applied" +msgstr "" + +#: templates/opportunities/include/opportunity.html:7 +msgid "applied" +msgstr "" + +#: templates/opportunities/include/opportunity.html:8 +msgid "mark opportunity as irrelevant" +msgstr "" + +#: templates/opportunities/include/opportunity.html:8 +msgid "irrelevant" +msgstr "" + #: templates/opportunities/include/opportunity_details_edit.html:45 msgid "Apply changes" msgstr "" === modified file 'harvest/media/css/style.css' --- harvest/media/css/style.css 2010-08-31 06:29:10 +0000 +++ harvest/media/css/style.css 2010-10-05 13:33:45 +0000 @@ -498,6 +498,9 @@ li.opportunity:hover > .opportunity-header > .actions { opacity:1; } +.opportunity-goaway-button { + font-size:10px; +} .opportunity-header > .opportunity-summary { margin-left:10px; color:rgb(180,180,180); === modified file 'harvest/opportunities/urls.py' --- harvest/opportunities/urls.py 2010-08-06 20:27:49 +0000 +++ harvest/opportunities/urls.py 2010-10-05 13:33:45 +0000 @@ -13,6 +13,13 @@ 'opportunities.views.opportunity_edit', name='opportunity_edit'), + url(r'^opportunity/(?P<opportunity_id>[\d]+)/applied/$', + 'opportunities.views.opportunity_applied', + name='opportunity_applied'), + + url(r'^opportunity/(?P<opportunity_id>[\d]+)/irrelevant/$', + 'opportunities.views.opportunity_irrelevant', + name='opportunity_irrelevant'), url(r'^xhr/results/$', 'opportunities.views.xhr_filter_results'), === modified file 'harvest/opportunities/views.py' --- harvest/opportunities/views.py 2010-08-31 08:21:04 +0000 +++ harvest/opportunities/views.py 2010-10-05 13:33:45 +0000 @@ -120,6 +120,21 @@ }, RequestContext(request)) +...@login_required +def opportunity_irrelevant(request, opportunity_id): + opportunity = get_object_or_404(models.Opportunity, id=opportunity_id) + opportunity.reviewed = (not opportunity.reviewed) + opportunity.save() + models.log_action(request.user, action="marked as irrelevant", opportunity=opportunity) + return filter(request) + +...@login_required +def opportunity_applied(request, opportunity_id): + opportunity = get_object_or_404(models.Opportunity, id=opportunity_id) + opportunity.applied = (not opportunity.applied) + opportunity.save() + models.log_action(request.user, action="marked as applied", opportunity=opportunity) + return filter(request) def xhr_filter_results(request): filters = HarvestFilters() === modified file 'harvest/templates/opportunities/include/opportunity.html' --- harvest/templates/opportunities/include/opportunity.html 2010-09-03 09:42:21 +0000 +++ harvest/templates/opportunities/include/opportunity.html 2010-10-05 13:33:45 +0000 @@ -2,11 +2,11 @@ <div class="opportunity-header"> <a href="{{opportunity.url}}" class="opportunity-description" target="_blank">{{ opportunity.description }}</a> - {% if user.is_authenticated %} <span class="actions"> <a href="{% url opportunity_edit opportunity.id %}?next={{request.get_full_path}}" target="_blank" class="opportunity-edit-button">{% trans 'edit' %}</a> + (<a href="{% url opportunity_applied opportunity.id %}?next={{request.get_full_path}}" class="opportunity-goaway-button" title="{% trans 'mark opportunity as applied' %}">{% trans 'applied' %}</a> + <a href="{% url opportunity_irrelevant opportunity.id %}?next={{request.get_full_path}}" class="opportunity-goaway-button" title="{% trans 'mark opportunity as irrelevant' %}">{% trans 'irrelevant' %}</a>) </span> - {% endif %} <span class="opportunity-summary"> {{ opportunity.summary|join:', ' }} </span>
_______________________________________________ Mailing list: https://launchpad.net/~harvest-dev Post to : [email protected] Unsubscribe : https://launchpad.net/~harvest-dev More help : https://help.launchpad.net/ListHelp

