Files
ent/entc/integration/migrate/entv2/media/media.go

41 lines
1.1 KiB
Go

// Copyright 2019-present Facebook Inc. All rights reserved.
// This source code is licensed under the Apache 2.0 license found
// in the LICENSE file in the root directory of this source tree.
// Code generated by ent, DO NOT EDIT.
package media
const (
// Label holds the string label denoting the media type in the database.
Label = "media"
// FieldID holds the string denoting the id field in the database.
FieldID = "id"
// FieldSource holds the string denoting the source field in the database.
FieldSource = "source"
// FieldSourceURI holds the string denoting the source_uri field in the database.
FieldSourceURI = "source_uri"
// FieldText holds the string denoting the text field in the database.
FieldText = "text"
// Table holds the table name of the media in the database.
Table = "media"
)
// Columns holds all SQL columns for media fields.
var Columns = []string{
FieldID,
FieldSource,
FieldSourceURI,
FieldText,
}
// 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
}