gitpay icon indicating copy to clipboard operation
gitpay copied to clipboard

Create team.js

Open arpit9667 opened this issue 5 years ago • 9 comments

Description

Added model for the Team

Issue

Closes #547

Impacted Area

Main page

Steps to test

Steps needed to reproduce the scenario from this change to validate if the pull request solve this issue

  • Create a team containing the users.

arpit9667 avatar Apr 04 '20 15:04 arpit9667

Great @arpit9667, but we have an issue when run the migration: https://circleci.com/gh/worknenjoy/gitpay/1403?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-checks-link

Unhandled rejection SequelizeBaseError: column "TeamId" does not exist

alexanmtz avatar Apr 24 '20 10:04 alexanmtz

@alexanmtz How to run the migration? I have created the migration for Team but the table is not getting created in the database. migraion model

`

arpit9667 avatar May 06 '20 11:05 arpit9667

@arpit9667 you can run the migration with npm run migrate

alexanmtz avatar May 06 '20 11:05 alexanmtz

@alexanmtz The last two migration files are not running. == One for the Plans Table == One for the Teams Table I think this is the problem. Can you check please? Locally Also when I try to run the npm run migrate command. The two tables are not getting created in the database. Screenshot from 2020-05-06 18-03-36

arpit9667 avatar May 06 '20 12:05 arpit9667

@arpit9667 , if you run the migration already, you would need to drop the database and create again to run from scratch

alexanmtz avatar May 10 '20 16:05 alexanmtz

@arpit9667, there's changes on Plan model that should not be included.

Maybe you're not in sync with the upstream master.

alexanmtz avatar May 10 '20 17:05 alexanmtz

@alexanmtz Yes, that was the problem. Now I have pulled all the changes for the master. Also I have implemented the Team model with the migrations that are needed. But, why is there a change for package-lock.json? Please help me with that.

arpit9667 avatar May 10 '20 17:05 arpit9667

Thanks for the update @arpit9667, but it seems that makes sense the user be able to join many teams

alexanmtz avatar May 11 '20 10:05 alexanmtz

@arpit9667 yeah, the package-lock.json should not be included on the commit, because there's no new library installed, you should commit only the files required for this PR, otherwise, we may have conflict when merging.

You can maybe check the file from master (needs to be an updated master) with git checkout master -- package-lock.json (I think, please research about it).

alexanmtz avatar Jul 15 '20 19:07 alexanmtz