djeck1432 / spotnet

1 stars 19 forks source link

Create new table in DB, Add crud methods and write test cases #104

Open djeck1432 opened 2 hours ago

djeck1432 commented 2 hours ago
  1. Read guideline here
  2. Create new db model AirDrop here with next fields:
    • user_id - ForeingKey
    • created_at - DateTime (add autopopulating by now)
    • amount - Decimal( null=True)
    • is_claimed - Boolean (default =False)
    • claimed_at - DateTime(null =True) 3.1. In DBConnector add new method:
    • create_empty_claim which will have one parameter: user_id and will create new airdrop instance 3.2 Create new AirDropDBConnector here which is inherited from DBConnector and add next methods:
    • save_claim_data which will save info about claim: amount, is_claime=True, and claimed_at = datetime.now()
    • get_all_unclaimed - which will return all records, where is_claimed = False
  3. Update this method open_position with creating new AirDrop instance (user this method create_empty_claim). user_id you can fetch from position.user_id
  4. Write test cases (positive and negative scenarios) for new class AirDropDBConnector in tests folder
  5. Update DBConnector test cases for new method create_empty_claim write positive and negative scenarios.

When you create PR, make sure you don't have any pylint issues and running tests didn't fail

ikemHood commented 2 hours ago

Hey @djeck1432, Can I work on this, please? I Like Orange

I will create the Airdrop model with the values provided write the CRUD methods and add test cases for the crud methods

ETA: 24hrs

tosoham commented 2 hours ago

I am a returning contributor here. I would be glad to tackle this issue as I have already worked with the db adding new field to Position. I like orange.

Jemiiah commented 2 hours ago

Hey @djeck1432 can I work on this issue my first time on this repo and would love to work on this issue I like Orange

BrunoAmbricca commented 2 hours ago

I like orange. I would like to contribute to this project doing this task.

I would follow the guideline in the repo for fork, clone & pull request. I would clone the project on my local machine. I would study the code base to understand how AirDrop interacts with it. After the implementation I would test to make sure everything works as expected

binayak9932 commented 2 hours ago

Let me try this one!I am a returning contributor i am sure i can carry this out.I like oranges

ShantelPeters commented 2 hours ago

Hi @djeck1432 please can I be assigned to this issue. This would be my first time contributing to this ecosystem I like oranges

djeck1432 commented 2 hours ago

This task is complex, so only old contributors can apply for it