projects

package
v0.0.0-...-de96b0e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 16, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateSingleProject

func CreateSingleProject(c *fiber.Ctx) error

It will create a project with incremented id.

func DeleteProject

func DeleteProject(c *fiber.Ctx) error

func GetProjects

func GetProjects(c *fiber.Ctx) error

Function to return all Projects

func GetSingleProject

func GetSingleProject(c *fiber.Ctx) error

func UpdateSingleProject

func UpdateSingleProject(c *fiber.Ctx) error

Types

type Projects

type Projects struct {
	gorm.Model
	Projects datatypes.JSON `json:"projects" gorm:"foreignKey:ID"`
}

type SerialProject

type SerialProject struct {
	Projects []SingleProject `json:"projects" gorm:"foreignKey:ID"`
}

all projects serializer

type SingleProject

type SingleProject struct {
	gorm.Model
	ID                  int32  `gorm:"primaryKey;autoIncrement:True;" json:"id"`
	Title               string `json:"title"`
	Desciption          string `json:"desc"`
	ProgrammingLanguage string `json:"programming_language"`
	Stars               int32  `gorm:"default:null" json:"stars"`
	Forks               int32  `gorm:"default:null" json:"forks"`
	LastUpdated         string `json:"last_updated"`
	Link                string `json:"link"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL