Skip to content

ebruddak/ToDo-GoAndVue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Golang and Vue 3 Poc: Todo List Project

It is a project written using Golang in the backend and Vue 3 in the frondend. MongoDb (Online MongoDbAtlas) has been used as database. JWT is used for authorization operations. Fiber was used for write Rest API. Visual studio code was used as an IDE.

##Database Connection (.env)

MONGOURI=mongodb+srv://ebrududak:ebru123456@cluster0.mvtbu.mongodb.net/?retryWrites=true&w=majority

##Client Port

http://localhost:8080

##Running Client

npm run serve

##Backend Port

http://localhost:3000

##Running Backend

go run main.go

##Test User

email: ebrududak@hotmail.com
password: 1

##Data Models

The project consists of three models. These; are user, group and todo. Collection contents are as follows.

type Group struct {
	Id     primitive.ObjectID `json:"id,omitempty" bson:"id"`
	Name   string             `json:"name,omitempty" bson:"name"`
	UserId primitive.ObjectID `json:"userid,omitempty" bson:"userid"`
}
type Todo struct {
	Id       primitive.ObjectID `json:"id,omitempty"`
	Title    string             `json:"title,omitempty"`
	State    bool               `json:"state,omitempty"`
	Content  string             `json:"content,omitempty"`
	Priority string             `json:"priority,omitempty"`
	UserId   primitive.ObjectID `json:"userId,omitempty"`
	GroupId  primitive.ObjectID `json:"groupId,omitempty"`
	DueDate  time.Time          `json:"dueDate,omitempty"`
}
type User struct {
	Id       primitive.ObjectID `json:"id,omitempty" bson:"id"`
	UserName string             `json:"userName,omitempty" bson:"username"`
	Email    string             `json:"eMail,omitempty" bson:"email"`
	Password []byte             `json:"password,omitempty" bson:"password"`
}

##User Case

The user can log in and create a new record.
User can add and remove groups.
User can add new todo.
Todos can be marked as complete.
Todos can be prioritized and group assigned.

ScreeenShots

1
2
3
4

Resources

https://www.youtube.com/watch?v=rx6CPDK_5mU&list=LL&index=5
https://www.youtube.com/watch?v=vDrSxxLXLcM&list=LL&index=4
https://www.udemy.com/course/working-with-vue-3-and-go/