add: some user api and all api desc

This commit is contained in:
wwweww
2026-02-27 19:17:01 +08:00
parent a0c720eb2f
commit 5930fb0dde
156 changed files with 9457 additions and 1086 deletions
@@ -0,0 +1,113 @@
// Code generated by ent, DO NOT EDIT.
package userverifications
import (
"entgo.io/ent/dialect/sql"
)
const (
// Label holds the string label denoting the userverifications type in the database.
Label = "user_verifications"
// FieldID holds the string denoting the id field in the database.
FieldID = "id"
// FieldUserID holds the string denoting the user_id field in the database.
FieldUserID = "user_id"
// FieldRole holds the string denoting the role field in the database.
FieldRole = "role"
// FieldStatus holds the string denoting the status field in the database.
FieldStatus = "status"
// FieldMaterials holds the string denoting the materials field in the database.
FieldMaterials = "materials"
// FieldRejectReason holds the string denoting the reject_reason field in the database.
FieldRejectReason = "reject_reason"
// FieldReviewedBy holds the string denoting the reviewed_by field in the database.
FieldReviewedBy = "reviewed_by"
// FieldReviewedAt holds the string denoting the reviewed_at field in the database.
FieldReviewedAt = "reviewed_at"
// 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"
// Table holds the table name of the userverifications in the database.
Table = "user_verifications"
)
// Columns holds all SQL columns for userverifications fields.
var Columns = []string{
FieldID,
FieldUserID,
FieldRole,
FieldStatus,
FieldMaterials,
FieldRejectReason,
FieldReviewedBy,
FieldReviewedAt,
FieldCreatedAt,
FieldUpdatedAt,
}
// 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 (
// DefaultStatus holds the default value on creation for the "status" field.
DefaultStatus string
// DefaultRejectReason holds the default value on creation for the "reject_reason" field.
DefaultRejectReason string
)
// OrderOption defines the ordering options for the UserVerifications 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()
}
// ByUserID orders the results by the user_id field.
func ByUserID(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldUserID, opts...).ToFunc()
}
// ByRole orders the results by the role field.
func ByRole(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldRole, opts...).ToFunc()
}
// ByStatus orders the results by the status field.
func ByStatus(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldStatus, opts...).ToFunc()
}
// ByRejectReason orders the results by the reject_reason field.
func ByRejectReason(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldRejectReason, opts...).ToFunc()
}
// ByReviewedBy orders the results by the reviewed_by field.
func ByReviewedBy(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldReviewedBy, opts...).ToFunc()
}
// ByReviewedAt orders the results by the reviewed_at field.
func ByReviewedAt(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldReviewedAt, opts...).ToFunc()
}
// ByCreatedAt orders the results by the created_at field.
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldCreatedAt, opts...).ToFunc()
}
// ByUpdatedAt orders the results by the updated_at field.
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldUpdatedAt, opts...).ToFunc()
}