You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
660 B
Go
33 lines
660 B
Go
package main
|
|
|
|
import (
|
|
"database/sql"
|
|
"errors"
|
|
)
|
|
|
|
|
|
type product struct {
|
|
ID int `json:"id"`
|
|
Name string `json:"name"`
|
|
Price float64 `json:"price"`
|
|
}
|
|
|
|
func getProducts(db *sql.DB, start, count int) ([]product, error) {
|
|
return nil, errors.New("Not implemented")
|
|
}
|
|
|
|
func (p *product) getProduct(db *sql.DB) error {
|
|
return errors.New("Not implemented")
|
|
}
|
|
|
|
func (p *product) updateProduct(db *sql.DB) error {
|
|
return errors.New("Not implemented")
|
|
}
|
|
|
|
func (p *product) deleteProduct(db *sql.DB) error {
|
|
return errors.New("Not implemented")
|
|
}
|
|
|
|
func (p *product) createProduct(db *sql.DB) error {
|
|
return errors.New("Not implemented")
|
|
} |