OnePlace release v0.5.2: beneficiary whitelist, excluded tags

in #utopian-io6 years ago

oneplace.jpg

Github repository: https://github.com/OnePlace-media/oneplace

Project description

OnePlace is a web-application built on Steem and Golos blockchains. As a basis we took Vue.js with SSR module for frontend and LoopBack for backend. Our project is fully open-source under MIT license.
Technology stack: Node.js, Vue.js, Loopback, Redis, MySQL
Website: https://oneplace.media
Latest release on GithubInstallation guide

Added features

Beneficiary whitelist

This feature allows us to drop beneficiary fees for chosen accounts. The accounts are selected by two principles:

  • Accounts that are whitelisted in the database.
  • Accounts that have voted our app @oneplace as a witness.

Relevant code added to publish extensions:

const extensions = []
if(!account.inWhiteList && !~account.witness_votes.indexOf('oneplace'))
extensions.push([0, {beneficiaries: [{account: this.beneficiarie, weight: 500}]}]) 

Full commit



Excluded tags

Sometimes there is a need to prevent some tags from publication in our client whether it's due to content restrictions or to avoid content conflict with other dApps. We have added a blacklist for tags that should be avoided. When trying to add such tag, a notice that the tag is not allowed for publication will be displayed.

Tag input validation was modified by checking for notExcludeTag condition:

<input 
   type="text" 
   class="publish__tags-input input" 
   :placeholder="$t('publish.typeTagsHere')" 
   v-validate="'firstIsLetter|lastIsLetterOrDigit|validTag|notExcludeTag|max:64'"
   name="tag" 
   v-show="tags.length < 5"
   @keydown.enter.prevent="addTag($event.target)"
 >

...
 
let excludeTags = []
Validator.extend('notExcludeTag', {
  getMessage: field => 'Use only letters, digits and one dash',
  validate: value => !~excludeTags.indexOf(value)
})

...

// set for check validation
excludeTags = this.$store.state.publish.tags.blackList.map(tag => tag.text) 

Full commit

Sort:  

Thank you for your contribution. Please try to post it within 14 days of committing on the repository. And also in this commit, you have 1,212 additions and 850 deletions, if you can break down that in smaller commits then it would be better.

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]

Hey @oneplace.dev
Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Contributing on Utopian
Learn how to contribute on our website or by watching this tutorial on Youtube.

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

Congratulations @oneplace.dev! You received a personal award!

1 Year on Steemit

Click here to view your Board

Do not miss the last post from @steemitboard:

Christmas Challenge - Send a gift to to your friends

Support SteemitBoard's project! Vote for its witness and get one more award!

Congratulations @oneplace.dev! You received a personal award!

Happy Birthday! - You are on the Steem blockchain for 2 years!

You can view your badges on your Steem Board and compare to others on the Steem Ranking

Vote for @Steemitboard as a witness to get one more award and increased upvotes!

Coin Marketplace

STEEM 0.20
TRX 0.20
JST 0.034
BTC 90227.69
ETH 3079.14
USDT 1.00
SBD 2.93