27 lines
468 B
Go
27 lines
468 B
Go
package models
|
|
|
|
import (
|
|
"github.com/jinzhu/gorm"
|
|
"github.com/lib/pq"
|
|
)
|
|
|
|
type Contract struct {
|
|
gorm.Model
|
|
Name string
|
|
DeviceIDs pq.Int64Array `gorm:"type:integer[]"`
|
|
BuyerID uint
|
|
Status string
|
|
BlockchainID string
|
|
ContractInfos []ContractInfo
|
|
}
|
|
|
|
func (Contract) Update() (bool, error) {
|
|
return false, nil
|
|
}
|
|
func (Contract) Create() (bool, error) {
|
|
return false, nil
|
|
}
|
|
func (Contract) Delete() (bool, error) {
|
|
return false, nil
|
|
}
|