// Code generated by ent, DO NOT EDIT. package agvvehiclestate import ( "entgo.io/ent/dialect/sql" ) const ( // Label holds the string label denoting the agvvehiclestate type in the database. Label = "agv_vehicle_state" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldAgvCode holds the string denoting the agv_code field in the database. FieldAgvCode = "agv_code" // FieldHasPallet holds the string denoting the has_pallet field in the database. FieldHasPallet = "has_pallet" // FieldSource holds the string denoting the source field in the database. FieldSource = "source" // FieldUpdatedBy holds the string denoting the updated_by field in the database. FieldUpdatedBy = "updated_by" // FieldUpdatedAt holds the string denoting the updated_at field in the database. FieldUpdatedAt = "updated_at" // FieldRemark holds the string denoting the remark field in the database. FieldRemark = "remark" // Table holds the table name of the agvvehiclestate in the database. Table = "agv_vehicle_state" ) // Columns holds all SQL columns for agvvehiclestate fields. var Columns = []string{ FieldID, FieldAgvCode, FieldHasPallet, FieldSource, FieldUpdatedBy, FieldUpdatedAt, FieldRemark, } // ValidColumn reports if the column name is valid (part of the table columns). func ValidColumn(column string) bool { for i := range Columns { if column == Columns[i] { return true } } return false } var ( // AgvCodeValidator is a validator for the "agv_code" field. It is called by the builders before save. AgvCodeValidator func(string) error // DefaultHasPallet holds the default value on creation for the "has_pallet" field. DefaultHasPallet bool // DefaultSource holds the default value on creation for the "source" field. DefaultSource string // SourceValidator is a validator for the "source" field. It is called by the builders before save. SourceValidator func(string) error // DefaultUpdatedBy holds the default value on creation for the "updated_by" field. DefaultUpdatedBy string // UpdatedByValidator is a validator for the "updated_by" field. It is called by the builders before save. UpdatedByValidator func(string) error // DefaultUpdatedAt holds the default value on creation for the "updated_at" field. DefaultUpdatedAt int64 // DefaultRemark holds the default value on creation for the "remark" field. DefaultRemark string // RemarkValidator is a validator for the "remark" field. It is called by the builders before save. RemarkValidator func(string) error ) // OrderOption defines the ordering options for the AgvVehicleState queries. type OrderOption func(*sql.Selector) // ByID orders the results by the id field. func ByID(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldID, opts...).ToFunc() } // ByAgvCode orders the results by the agv_code field. func ByAgvCode(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldAgvCode, opts...).ToFunc() } // ByHasPallet orders the results by the has_pallet field. func ByHasPallet(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldHasPallet, opts...).ToFunc() } // BySource orders the results by the source field. func BySource(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldSource, opts...).ToFunc() } // ByUpdatedBy orders the results by the updated_by field. func ByUpdatedBy(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldUpdatedBy, opts...).ToFunc() } // ByUpdatedAt orders the results by the updated_at field. func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldUpdatedAt, opts...).ToFunc() } // ByRemark orders the results by the remark field. func ByRemark(opts ...sql.OrderTermOption) OrderOption { return sql.OrderByField(FieldRemark, opts...).ToFunc() }