Skip to content

Commit

Permalink
Merge branch 'master' into kevin/phantom_funding
Browse files Browse the repository at this point in the history
  • Loading branch information
octavioamu authored Sep 11, 2019
2 parents 09320f8 + 8218fa1 commit 2f51e7f
Show file tree
Hide file tree
Showing 14 changed files with 100 additions and 14 deletions.
7 changes: 5 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
---
name: 🐛 Bug report
name: "\U0001F41B Bug report"
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

Expand All @@ -25,7 +28,7 @@ Provide a general summary of the issue in the title above and use relevant field
<!-- A clear and concise description of what you expected to happen. -->

**Screenshots**
<!-- If applicable, add screenshots to help explain your problem.)
<!-- If applicable, add screenshots to help explain your problem.) -->

**Desktop (please complete the following information):**

Expand Down
5 changes: 4 additions & 1 deletion .github/ISSUE_TEMPLATE/custom.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
---
name: 🤔 Custom
name: "\U0001F914 Custom"
about: Want to report an issue that doesn't fall under any other category? Use this
template.
title: ''
labels: ''
assignees: ''

---

Expand Down
6 changes: 5 additions & 1 deletion .github/ISSUE_TEMPLATE/discussion.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
---
name: ❓Discussion
name: "❓Discussion"
about: Want to start a discussion? Use this template.
title: ''
labels: ''
assignees: ''

---

<!--
Hello Gitcoiner!
Expand Down
5 changes: 4 additions & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
---
name: ✋ Feature request
name: "✋ Feature request"
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''

---

Expand Down
11 changes: 8 additions & 3 deletions .github/ISSUE_TEMPLATE/thank_you.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
---
name: ❤️ Say thank you
about: Tell us how you use Gitcoin & support our efforts towards our mission (Grow/Sustain Open Source)
name: "❤️ Say thank you"
about: Tell us how you use Gitcoin & support our efforts towards our mission (Grow/Sustain
Open Source)
title: ''
labels: ''
assignees: ''

---

# ❤️ I'm using Gitcoin
Expand All @@ -18,4 +23,4 @@ If you would like to help Gitcoin - any of the following is greatly appreciated.
- [ ] Support us on [Gitcoin Grants](https://gitcoin.co/grants/86/gitcoin-sustainability-fund)

Thank you!
The Gitcoin team
The Gitcoin team
1 change: 0 additions & 1 deletion app/app/templates/shared/sentry.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@
Raven.config('{{ raven_js_dsn }}', ravenOptions).install()
{% if github_handle %}
Raven.setUserContext({
email: '{{ user.email|default_if_none:"anonymous" }}',
id: '{{ user.id|default_if_none:"0" }}',
handle: '{{ github_handle }}',
profile_id: '{{ profile_id|default_if_none:"0" }}'
Expand Down
39 changes: 39 additions & 0 deletions app/dashboard/management/commands/setup_grants_clr_3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
'''
Copyright (C) 2018 Gitcoin Core
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
'''
from django.contrib.auth.models import Group, Permission, User
from django.core.management.base import BaseCommand
from django.db.models import Q


class Command(BaseCommand):
help = "Setup CLR Round 3"

def handle(self, *args, **options):
clr_r3_group_name = "Grants-CLR-Round-3"
clr_group_r3 = Group.objects.get_or_create(name=clr_r3_group_name)[0]
add_clr_match = Permission.objects.get(codename="add_clrmatch")
clr_group_r3.permissions.add(add_clr_match)

print('Fetching Valid Grant CLR Round 3 Users')
valid_users = User.objects.filter(~Q(groups__name__in=[clr_r3_group_name]),
profile__data__created_at__lte="2019-02-15") | User.objects.filter(
~Q(groups__name__in=[clr_r3_group_name]), profile__trust_profile=True)
for user in valid_users:
user.groups.add(clr_group_r3)

print('Grant CLR Round 3 Setup Finished')
2 changes: 1 addition & 1 deletion app/dashboard/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -2373,7 +2373,7 @@ def success_rate(self):
idx_status__in=Bounty.TERMINAL_STATUSES, network=network).count()
if terminal_state_bounties == 0:
return 1.0
return num_completed_bounties * 1.0 / (terminal_state_bounties + num_completed_bounties)
return num_completed_bounties * 1.0 / terminal_state_bounties

@property
def get_quarterly_stats(self):
Expand Down
10 changes: 10 additions & 0 deletions app/dashboard/templates/board/contributor.html
Original file line number Diff line number Diff line change
Expand Up @@ -186,4 +186,14 @@ <h4 class="h5 font-weight-semibold my-3">
</div>
</div>
</section>
<section class="container">
<div class="row text-center py-5">
<div class="col-12">
<p>
If you also want to check your finished bounties, you can find them here:
</p>
<a class="btn btn-gc-blue" href="/explorer?bounty_filter=startedByMe&network=mainnet&order_by=-web3_created">Check my bounties in the explorer</a>
</div>
</div>
</section>
</div>
6 changes: 3 additions & 3 deletions app/dashboard/templates/board/funder.html
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@
<li class="text-center my-5" :class="{'d-none': (isLoading.open || bounties.open && bounties.open.length > 0) }">
<img src="{% static 'v2/images/zero-bounties.svg' %}" alt="" width="197" height="169">
<h4 class="h5 font-weight-semibold my-3">
You haven’t funded any issues yet.
You don't have any open issues right now!
</h4>
<p class="text-black-70"><a title="Fund an issue" href="{% url 'new_funding' %}">Fund an Issue</a> or check out our <a href="{% url 'quickstart' %}">Funders Guide</a> to start getting contributors for your project! </p>
<p class="text-black-70">Have any question? Chat with us on <a href="{% url 'slack' %}">Slack</a>!</p>
Expand Down Expand Up @@ -292,7 +292,7 @@ <h4 class="h5 font-weight-semibold my-3">
</div>
</li>
<li class="text-center my-5" :class="{'d-none': isLoading.submitted ||bounties.submitted && bounties.submitted.length > 0}" v-cloak>
<p>[[ error.submitted || 'You have no bounties with submittions.' ]]</p>
<p>[[ error.submitted || 'You have no bounties with submissions.' ]]</p>
</li>
</ul>
<loading-screen v-if="isLoading.submitted"></loading-screen>
Expand Down Expand Up @@ -352,7 +352,7 @@ <h4 class="h5 font-weight-semibold my-3">
<div class="row text-center py-5">
<div class="col-12">
<p>
If you want to check also your finished and cancel bounties you can find them here:
If you also want to check your finished and cancelled bounties, you can find them here:
</p>
<a class="btn btn-gc-blue" href="/explorer?bounty_filter=createdByMe&network=mainnet&order_by=-web3_created">Check my bounties in the explorer</a>
</div>
Expand Down
1 change: 1 addition & 0 deletions app/grants/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -718,6 +718,7 @@ def psave_grant(sender, instance, **kwargs):
value_usdt = subscription.get_converted_amount()
for contrib in subscription.subscription_contribution.filter(success=True):
if value_usdt:
#print(f"adding contribution of {round(subscription.amount_per_period,2)} {subscription.token_symbol}, pk: {contrib.pk}, worth ${round(value_usdt,2)} to make total ${round(instance.amount_received,2)}. (txid: {contrib.tx_id} tx_cleared:{contrib.tx_cleared} )")
instance.amount_received += Decimal(value_usdt)

if subscription.num_tx_processed <= subscription.num_tx_approved and value_usdt:
Expand Down
2 changes: 1 addition & 1 deletion app/grants/templates/grants/detail/info.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ <h1 class="font-title-xl my-4 font-weight-bold">
<div class="font-body mb-2">
<i style="width: 14px;" class="fas fa-coins mr-2 text-center"></i>
<p class="d-inline-block mb-0" data-toggle="tooltip" data-placement="top" title="ERC20 Token">
Grants accepts {{ grant.token_symbol }}
Grant accepts {{ grant.token_symbol }}
</p>
</div>
{% endif %}
Expand Down
18 changes: 18 additions & 0 deletions app/retail/templates/emails/template.html
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,14 @@
padding: 30px 50px;
}

#preferred_payout{
background-color: #eee;
padding: 10px 50px;
text-align: center;
margin-bottom: 20px;

}

#footer p, #footer a {
color: #ccc;
}
Expand Down Expand Up @@ -260,6 +268,16 @@
{% endif %}
</a>
</div>
<div id="preferred_payout">
{% if subscriber.profile.preferred_payout_address %}
Your Gitcoin preferred payout address is <strong>{{subscriber.profile.preferred_payout_address}}</strong>. Payments will be auto-sent to this address.
<a href="https://gitcoin.co/settings/account">New Wallet? Click here to update Payout Address.</a>
{% else %}
You do not have a prefered payout address on file.
<a href="https://gitcoin.co/settings/account">Click here to set a Payout Address.</a>
{% endif %}

</div>
{% endif %}

<div class="primary-content text-center">
Expand Down
1 change: 1 addition & 0 deletions scripts/crontab
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,4 @@ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/us

## USERS
0 1 * * * cd gitcoin/coin; bash scripts/run_management_command_if_not_already_running.bash set_user_personas >> /var/log/gitcoin/set_user_personas.log 2>&1
30 0 * * * cd gitcoin/coin; bash scripts/run_management_command_if_not_already_running.bash setup_grants_clr_3 >> /var/log/gitcoin/setup_clr_round_3.log 2>&1

0 comments on commit 2f51e7f

Please sign in to comment.