Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.TShortUrl) predicate.TShortUrl
- func BizID(v int64) predicate.TShortUrl
- func BizIDEQ(v int64) predicate.TShortUrl
- func BizIDGT(v int64) predicate.TShortUrl
- func BizIDGTE(v int64) predicate.TShortUrl
- func BizIDIn(vs ...int64) predicate.TShortUrl
- func BizIDLT(v int64) predicate.TShortUrl
- func BizIDLTE(v int64) predicate.TShortUrl
- func BizIDNEQ(v int64) predicate.TShortUrl
- func BizIDNotIn(vs ...int64) predicate.TShortUrl
- func CreatedAt(v int64) predicate.TShortUrl
- func CreatedAtEQ(v int64) predicate.TShortUrl
- func CreatedAtGT(v int64) predicate.TShortUrl
- func CreatedAtGTE(v int64) predicate.TShortUrl
- func CreatedAtIn(vs ...int64) predicate.TShortUrl
- func CreatedAtLT(v int64) predicate.TShortUrl
- func CreatedAtLTE(v int64) predicate.TShortUrl
- func CreatedAtNEQ(v int64) predicate.TShortUrl
- func CreatedAtNotIn(vs ...int64) predicate.TShortUrl
- func ExpiredAt(v int64) predicate.TShortUrl
- func ExpiredAtEQ(v int64) predicate.TShortUrl
- func ExpiredAtGT(v int64) predicate.TShortUrl
- func ExpiredAtGTE(v int64) predicate.TShortUrl
- func ExpiredAtIn(vs ...int64) predicate.TShortUrl
- func ExpiredAtLT(v int64) predicate.TShortUrl
- func ExpiredAtLTE(v int64) predicate.TShortUrl
- func ExpiredAtNEQ(v int64) predicate.TShortUrl
- func ExpiredAtNotIn(vs ...int64) predicate.TShortUrl
- func ID(id int64) predicate.TShortUrl
- func IDEQ(id int64) predicate.TShortUrl
- func IDGT(id int64) predicate.TShortUrl
- func IDGTE(id int64) predicate.TShortUrl
- func IDIn(ids ...int64) predicate.TShortUrl
- func IDLT(id int64) predicate.TShortUrl
- func IDLTE(id int64) predicate.TShortUrl
- func IDNEQ(id int64) predicate.TShortUrl
- func IDNotIn(ids ...int64) predicate.TShortUrl
- func Not(p predicate.TShortUrl) predicate.TShortUrl
- func Or(predicates ...predicate.TShortUrl) predicate.TShortUrl
- func Origin(v string) predicate.TShortUrl
- func OriginContains(v string) predicate.TShortUrl
- func OriginContainsFold(v string) predicate.TShortUrl
- func OriginEQ(v string) predicate.TShortUrl
- func OriginEqualFold(v string) predicate.TShortUrl
- func OriginGT(v string) predicate.TShortUrl
- func OriginGTE(v string) predicate.TShortUrl
- func OriginHasPrefix(v string) predicate.TShortUrl
- func OriginHasSuffix(v string) predicate.TShortUrl
- func OriginIn(vs ...string) predicate.TShortUrl
- func OriginLT(v string) predicate.TShortUrl
- func OriginLTE(v string) predicate.TShortUrl
- func OriginNEQ(v string) predicate.TShortUrl
- func OriginNotIn(vs ...string) predicate.TShortUrl
- func Short(v int64) predicate.TShortUrl
- func ShortEQ(v int64) predicate.TShortUrl
- func ShortGT(v int64) predicate.TShortUrl
- func ShortGTE(v int64) predicate.TShortUrl
- func ShortIn(vs ...int64) predicate.TShortUrl
- func ShortLT(v int64) predicate.TShortUrl
- func ShortLTE(v int64) predicate.TShortUrl
- func ShortNEQ(v int64) predicate.TShortUrl
- func ShortNotIn(vs ...int64) predicate.TShortUrl
- func UpdatedAt(v int64) predicate.TShortUrl
- func UpdatedAtEQ(v int64) predicate.TShortUrl
- func UpdatedAtGT(v int64) predicate.TShortUrl
- func UpdatedAtGTE(v int64) predicate.TShortUrl
- func UpdatedAtIn(vs ...int64) predicate.TShortUrl
- func UpdatedAtLT(v int64) predicate.TShortUrl
- func UpdatedAtLTE(v int64) predicate.TShortUrl
- func UpdatedAtNEQ(v int64) predicate.TShortUrl
- func UpdatedAtNotIn(vs ...int64) predicate.TShortUrl
- func ValidColumn(column string) bool
- func Visit(v int64) predicate.TShortUrl
- func VisitEQ(v int64) predicate.TShortUrl
- func VisitGT(v int64) predicate.TShortUrl
- func VisitGTE(v int64) predicate.TShortUrl
- func VisitIn(vs ...int64) predicate.TShortUrl
- func VisitLT(v int64) predicate.TShortUrl
- func VisitLTE(v int64) predicate.TShortUrl
- func VisitNEQ(v int64) predicate.TShortUrl
- func VisitNotIn(vs ...int64) predicate.TShortUrl
- type OrderOption
- func ByBizID(opts ...sql.OrderTermOption) OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByExpiredAt(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByOrigin(opts ...sql.OrderTermOption) OrderOption
- func ByShort(opts ...sql.OrderTermOption) OrderOption
- func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByVisit(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the tshorturl type in the database. Label = "tshort_url" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldBizID holds the string denoting the biz_id field in the database. FieldBizID = "biz_id" // FieldOrigin holds the string denoting the origin field in the database. FieldOrigin = "origin" // FieldShort holds the string denoting the short field in the database. FieldShort = "short" // FieldVisit holds the string denoting the visit field in the database. FieldVisit = "visit" // FieldCreatedAt holds the string denoting the created_at field in the database. FieldCreatedAt = "created_at" // FieldUpdatedAt holds the string denoting the updated_at field in the database. FieldUpdatedAt = "updated_at" // FieldExpiredAt holds the string denoting the expired_at field in the database. FieldExpiredAt = "expired_at" // Table holds the table name of the tshorturl in the database. Table = "short_url" )
Variables ¶
var ( // OriginValidator is a validator for the "origin" field. It is called by the builders before save. OriginValidator func(string) error // DefaultVisit holds the default value on creation for the "visit" field. DefaultVisit int64 // DefaultExpiredAt holds the default value on creation for the "expired_at" field. DefaultExpiredAt int64 )
var Columns = []string{ FieldID, FieldBizID, FieldOrigin, FieldShort, FieldVisit, FieldCreatedAt, FieldUpdatedAt, FieldExpiredAt, }
Columns holds all SQL columns for tshorturl fields.
Functions ¶
func BizID ¶
BizID applies equality check predicate on the "biz_id" field. It's identical to BizIDEQ.
func BizIDNotIn ¶
BizIDNotIn applies the NotIn predicate on the "biz_id" field.
func CreatedAt ¶
CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAtEQ ¶
CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtGT ¶
CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGTE ¶
CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtIn ¶
CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtLT ¶
CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLTE ¶
CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtNEQ ¶
CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNotIn ¶
CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func ExpiredAt ¶
ExpiredAt applies equality check predicate on the "expired_at" field. It's identical to ExpiredAtEQ.
func ExpiredAtEQ ¶
ExpiredAtEQ applies the EQ predicate on the "expired_at" field.
func ExpiredAtGT ¶
ExpiredAtGT applies the GT predicate on the "expired_at" field.
func ExpiredAtGTE ¶
ExpiredAtGTE applies the GTE predicate on the "expired_at" field.
func ExpiredAtIn ¶
ExpiredAtIn applies the In predicate on the "expired_at" field.
func ExpiredAtLT ¶
ExpiredAtLT applies the LT predicate on the "expired_at" field.
func ExpiredAtLTE ¶
ExpiredAtLTE applies the LTE predicate on the "expired_at" field.
func ExpiredAtNEQ ¶
ExpiredAtNEQ applies the NEQ predicate on the "expired_at" field.
func ExpiredAtNotIn ¶
ExpiredAtNotIn applies the NotIn predicate on the "expired_at" field.
func Origin ¶
Origin applies equality check predicate on the "origin" field. It's identical to OriginEQ.
func OriginContains ¶
OriginContains applies the Contains predicate on the "origin" field.
func OriginContainsFold ¶
OriginContainsFold applies the ContainsFold predicate on the "origin" field.
func OriginEqualFold ¶
OriginEqualFold applies the EqualFold predicate on the "origin" field.
func OriginHasPrefix ¶
OriginHasPrefix applies the HasPrefix predicate on the "origin" field.
func OriginHasSuffix ¶
OriginHasSuffix applies the HasSuffix predicate on the "origin" field.
func OriginNotIn ¶
OriginNotIn applies the NotIn predicate on the "origin" field.
func Short ¶
Short applies equality check predicate on the "short" field. It's identical to ShortEQ.
func ShortNotIn ¶
ShortNotIn applies the NotIn predicate on the "short" field.
func UpdatedAt ¶
UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAtEQ ¶
UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtGT ¶
UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGTE ¶
UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtIn ¶
UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtLT ¶
UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLTE ¶
UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtNEQ ¶
UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNotIn ¶
UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
func Visit ¶
Visit applies equality check predicate on the "visit" field. It's identical to VisitEQ.
func VisitNotIn ¶
VisitNotIn applies the NotIn predicate on the "visit" field.
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the TShortUrl queries.
func ByBizID ¶
func ByBizID(opts ...sql.OrderTermOption) OrderOption
ByBizID orders the results by the biz_id field.
func ByCreatedAt ¶
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
ByCreatedAt orders the results by the created_at field.
func ByExpiredAt ¶
func ByExpiredAt(opts ...sql.OrderTermOption) OrderOption
ByExpiredAt orders the results by the expired_at field.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByOrigin ¶
func ByOrigin(opts ...sql.OrderTermOption) OrderOption
ByOrigin orders the results by the origin field.
func ByShort ¶
func ByShort(opts ...sql.OrderTermOption) OrderOption
ByShort orders the results by the short field.
func ByUpdatedAt ¶
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
ByUpdatedAt orders the results by the updated_at field.
func ByVisit ¶
func ByVisit(opts ...sql.OrderTermOption) OrderOption
ByVisit orders the results by the visit field.