Versions in this module Expand all Collapse all v1 v1.0.1 Jul 22, 2017 Changes in this version + func APITorrentsToJSON(t []models.Torrent) []models.TorrentJSON + func Create(user *models.User, uploadForm *torrentValidator.TorrentRequest) (*models.Torrent, error) + func ExistOrDelete(hash string, user *models.User) error + func Find(parameters structs.WhereParams, limit int, offset int) ([]models.Torrent, int, error) + func FindAll(limit int, offset int) ([]models.Torrent, int, error) + func FindAllOrderBy(orderBy string, limit int, offset int) ([]models.Torrent, int, error) + func FindByID(id uint) (*models.Torrent, error) + func FindDB(parameters structs.WhereParams) ([]models.Torrent, int, error) + func FindDeleted(parameters *structs.WhereParams, orderBy string, limit int, offset int) (torrents []models.Torrent, count int, err error) + func FindOrderBy(parameters *structs.WhereParams, orderBy string, limit int, offset int) (torrents []models.Torrent, count int, err error) + func FindOrderByNoCount(parameters *structs.WhereParams, orderBy string, limit int, offset int) (torrents []models.Torrent, err error) + func FindRawByHash(hash string) (torrent models.Torrent, err error) + func FindRawByID(id uint) (torrent models.Torrent, err error) + func FindUnscopeByID(id uint) (torrent models.Torrent, err error) + func FindWithUserOrderBy(parameters *structs.WhereParams, orderBy string, limit int, offset int) (torrents []models.Torrent, count int, err error) + func GetAllInDB() ([]models.Torrent, int, error) + func HideUser(uploaderID uint, uploaderName string, torrentHidden bool) (uint, string) + func NewTorrentEvent(user *models.User, torrent *models.Torrent) error + func ToggleBlock(id uint) (models.Torrent, int, error) + func TorrentsToAPI(t []models.Torrent) []models.TorrentJSON