Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: cross-chain improvs #6472

Merged
merged 3 commits into from
Apr 22, 2020
Merged

chore: cross-chain improvs #6472

merged 3 commits into from
Apr 22, 2020

Conversation

thelostone-mc
Copy link
Member

@thelostone-mc thelostone-mc commented Apr 19, 2020

Description
  • remove unused admin methods
  • add activity on close bounty
  • fixed broken fa icons
  • updated tooltip design
  • added icon for expired fulfillment to inform user
  • set txn/address link based on token
  • made qr code generate based on token

@codecov
Copy link

codecov bot commented Apr 19, 2020

Codecov Report

Merging #6472 into master will increase coverage by 0.06%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6472      +/-   ##
==========================================
+ Coverage   27.18%   27.24%   +0.06%     
==========================================
  Files         289      289              
  Lines       26464    26380      -84     
  Branches     3923     3909      -14     
==========================================
- Hits         7194     7188       -6     
+ Misses      19003    18925      -78     
  Partials      267      267              
Impacted Files Coverage Δ
app/dashboard/views.py 11.26% <0.00%> (+0.01%) ⬆️
app/app/urls.py 86.44% <0.00%> (ø)
app/kudos/views.py 14.46% <0.00%> (ø)
app/quests/views.py 16.29% <0.00%> (ø)
app/dashboard/export.py 60.36% <0.00%> (ø)
app/dashboard/context/hackathon.py 0.00% <0.00%> (ø)
app/grants/views.py 15.99% <0.00%> (+0.02%) ⬆️
app/dashboard/helpers.py 14.19% <0.00%> (+0.03%) ⬆️
app/retail/views.py 21.56% <0.00%> (+0.04%) ⬆️
... and 6 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b6b38df...5dda373. Read the comment docs.

@thelostone-mc thelostone-mc force-pushed the cross branch 2 times, most recently from 78bf123 to 9cda2bc Compare April 20, 2020 12:31
- remove unused admin methods
- add activity on close bounty
- fixed broken fa icons
- updated tooltip design
- added icon for expired fulfillment to inform user
- set txn/address link based on token
@thelostone-mc thelostone-mc marked this pull request as ready for review April 20, 2020 12:42
Comment on lines 257 to 283
contactFunder: function() {
let vm = this;
let text = window.prompt('What would you like to say to the funder?', '');

if (text === null) {
return;
}
document.location.href = `${vm.bounty.url}?admin_contact_funder=${text}`;
},
snoozeeGitbot: function() {
let vm = this;
let text = window.prompt('How many days do you want to snooze?', '');

if (text === null) {
return;
}
document.location.href = `${vm.bounty.url}?snooze=${text}`;
},
overrideStatus: function() {
let vm = this;
let text = window.prompt('What new status (valid choices: "open", "started", "submitted", "done", "expired", "cancelled", "" to remove override )?', '');

if (text === null) {
return;
}
document.location.href = `${vm.bounty.url}?admin_override_satatus=${text}`;
},
Copy link
Contributor

Choose a reason for hiding this comment

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

why are we removing these actions? that will be undefined in the html vue click

Copy link
Member Author

Choose a reason for hiding this comment

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

@octavioamu so those buttons don't work for ETH bounties as well!
Hence I made sure only the buttons which worked were being ported over

Copy link
Member Author

@thelostone-mc thelostone-mc Apr 22, 2020

Choose a reason for hiding this comment

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

I assumed those actions don't work in live !
https://gitcoin.co/issue/gitcoinco/web/6486/4252

So removed them out from the JS and the html for cross-chain

Copy link
Member Author

Choose a reason for hiding this comment

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

I'll re-add the contactFunder and snooze bot but the override status -> let's not do that ?

Copy link
Contributor

Choose a reason for hiding this comment

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

but eth bounties are not using this code

Copy link
Contributor

Choose a reason for hiding this comment

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

the override status is something they use to manage hackathon bounties sometimes I believe

Copy link
Member Author

Choose a reason for hiding this comment

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

lol that doesn't work :P cause that updates idx_status and not bounty_state

we'll fix this up if they ever bring it up 📦

Comment on lines -373 to -379
// ETH
activity.metadata.new_bounty['token_value'] = activity.metadata.new_bounty.value_in_token / 10 ** decimals;
if (activity.metadata.old_bounty) {
activity.metadata.old_bounty['token_value'] = activity.metadata.old_bounty.value_in_token / 10 ** decimals;
}
} else {
// cross-chain
Copy link
Contributor

@octavioamu octavioamu Apr 21, 2020

Choose a reason for hiding this comment

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

are not going to jump and use this file in eth bounties in near future?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'd want to do it via the backend where we streamline the response and then pass it to the frontend !
Activity will be in common format when it comes to frontend (irrespective of if it's ETH or cross-chain)

Copy link
Contributor

@octavioamu octavioamu left a comment

Choose a reason for hiding this comment

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

left some comments about removals I believe we need but lets talk about it in a few hours

@@ -36,9 +36,6 @@
Admin Actions
</span>
<a v-for="link in quickLinks" class="btn btn-outline-gc-blue px-2 mx-2 font-smaller-4" :href="[[link.href]]" :title="[[ link.title ]]">[[ link.label ]]</a>
<button class="btn btn-outline-gc-blue px-2 mx-2 font-smaller-4" @click="contactFunder()">Contact Funder</button>
Copy link
Contributor

Choose a reason for hiding this comment

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

these removed are not part of quickLinks since are not links, are prompts and I fixed them to not send the actions if are empty (today that is broken in normal bounties if you click that prompts then the action is sent even without nothing

Copy link
Member Author

Choose a reason for hiding this comment

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

Added this back !

Copy link
Contributor

@octavioamu octavioamu left a comment

Choose a reason for hiding this comment

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

approving not sure about the team need on overrideStatus

@octavioamu octavioamu merged commit eecadfb into gitcoinco:master Apr 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants