github.com/NpoolPlatform/chain-middleware@v0.0.0-20240228100535-eb1bcf896eb9/pkg/db/ent/setting/setting.go (about)

     1  // Code generated by ent, DO NOT EDIT.
     2  
     3  package setting
     4  
     5  import (
     6  	"entgo.io/ent"
     7  	"github.com/google/uuid"
     8  	"github.com/shopspring/decimal"
     9  )
    10  
    11  const (
    12  	// Label holds the string label denoting the setting type in the database.
    13  	Label = "setting"
    14  	// FieldID holds the string denoting the id field in the database.
    15  	FieldID = "id"
    16  	// FieldCreatedAt holds the string denoting the created_at field in the database.
    17  	FieldCreatedAt = "created_at"
    18  	// FieldUpdatedAt holds the string denoting the updated_at field in the database.
    19  	FieldUpdatedAt = "updated_at"
    20  	// FieldDeletedAt holds the string denoting the deleted_at field in the database.
    21  	FieldDeletedAt = "deleted_at"
    22  	// FieldEntID holds the string denoting the ent_id field in the database.
    23  	FieldEntID = "ent_id"
    24  	// FieldCoinTypeID holds the string denoting the coin_type_id field in the database.
    25  	FieldCoinTypeID = "coin_type_id"
    26  	// FieldFeeCoinTypeID holds the string denoting the fee_coin_type_id field in the database.
    27  	FieldFeeCoinTypeID = "fee_coin_type_id"
    28  	// FieldWithdrawFeeByStableUsd holds the string denoting the withdraw_fee_by_stable_usd field in the database.
    29  	FieldWithdrawFeeByStableUsd = "withdraw_fee_by_stable_usd"
    30  	// FieldWithdrawFeeAmount holds the string denoting the withdraw_fee_amount field in the database.
    31  	FieldWithdrawFeeAmount = "withdraw_fee_amount"
    32  	// FieldCollectFeeAmount holds the string denoting the collect_fee_amount field in the database.
    33  	FieldCollectFeeAmount = "collect_fee_amount"
    34  	// FieldHotWalletFeeAmount holds the string denoting the hot_wallet_fee_amount field in the database.
    35  	FieldHotWalletFeeAmount = "hot_wallet_fee_amount"
    36  	// FieldLowFeeAmount holds the string denoting the low_fee_amount field in the database.
    37  	FieldLowFeeAmount = "low_fee_amount"
    38  	// FieldHotLowFeeAmount holds the string denoting the hot_low_fee_amount field in the database.
    39  	FieldHotLowFeeAmount = "hot_low_fee_amount"
    40  	// FieldHotWalletAccountAmount holds the string denoting the hot_wallet_account_amount field in the database.
    41  	FieldHotWalletAccountAmount = "hot_wallet_account_amount"
    42  	// FieldPaymentAccountCollectAmount holds the string denoting the payment_account_collect_amount field in the database.
    43  	FieldPaymentAccountCollectAmount = "payment_account_collect_amount"
    44  	// FieldLeastTransferAmount holds the string denoting the least_transfer_amount field in the database.
    45  	FieldLeastTransferAmount = "least_transfer_amount"
    46  	// FieldNeedMemo holds the string denoting the need_memo field in the database.
    47  	FieldNeedMemo = "need_memo"
    48  	// FieldRefreshCurrency holds the string denoting the refresh_currency field in the database.
    49  	FieldRefreshCurrency = "refresh_currency"
    50  	// FieldCheckNewAddressBalance holds the string denoting the check_new_address_balance field in the database.
    51  	FieldCheckNewAddressBalance = "check_new_address_balance"
    52  	// Table holds the table name of the setting in the database.
    53  	Table = "settings"
    54  )
    55  
    56  // Columns holds all SQL columns for setting fields.
    57  var Columns = []string{
    58  	FieldID,
    59  	FieldCreatedAt,
    60  	FieldUpdatedAt,
    61  	FieldDeletedAt,
    62  	FieldEntID,
    63  	FieldCoinTypeID,
    64  	FieldFeeCoinTypeID,
    65  	FieldWithdrawFeeByStableUsd,
    66  	FieldWithdrawFeeAmount,
    67  	FieldCollectFeeAmount,
    68  	FieldHotWalletFeeAmount,
    69  	FieldLowFeeAmount,
    70  	FieldHotLowFeeAmount,
    71  	FieldHotWalletAccountAmount,
    72  	FieldPaymentAccountCollectAmount,
    73  	FieldLeastTransferAmount,
    74  	FieldNeedMemo,
    75  	FieldRefreshCurrency,
    76  	FieldCheckNewAddressBalance,
    77  }
    78  
    79  // ValidColumn reports if the column name is valid (part of the table columns).
    80  func ValidColumn(column string) bool {
    81  	for i := range Columns {
    82  		if column == Columns[i] {
    83  			return true
    84  		}
    85  	}
    86  	return false
    87  }
    88  
    89  // Note that the variables below are initialized by the runtime
    90  // package on the initialization of the application. Therefore,
    91  // it should be imported in the main as follows:
    92  //
    93  //	import _ "github.com/NpoolPlatform/chain-middleware/pkg/db/ent/runtime"
    94  //
    95  var (
    96  	Hooks  [1]ent.Hook
    97  	Policy ent.Policy
    98  	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
    99  	DefaultCreatedAt func() uint32
   100  	// DefaultUpdatedAt holds the default value on creation for the "updated_at" field.
   101  	DefaultUpdatedAt func() uint32
   102  	// UpdateDefaultUpdatedAt holds the default value on update for the "updated_at" field.
   103  	UpdateDefaultUpdatedAt func() uint32
   104  	// DefaultDeletedAt holds the default value on creation for the "deleted_at" field.
   105  	DefaultDeletedAt func() uint32
   106  	// DefaultEntID holds the default value on creation for the "ent_id" field.
   107  	DefaultEntID func() uuid.UUID
   108  	// DefaultCoinTypeID holds the default value on creation for the "coin_type_id" field.
   109  	DefaultCoinTypeID func() uuid.UUID
   110  	// DefaultFeeCoinTypeID holds the default value on creation for the "fee_coin_type_id" field.
   111  	DefaultFeeCoinTypeID func() uuid.UUID
   112  	// DefaultWithdrawFeeByStableUsd holds the default value on creation for the "withdraw_fee_by_stable_usd" field.
   113  	DefaultWithdrawFeeByStableUsd bool
   114  	// DefaultWithdrawFeeAmount holds the default value on creation for the "withdraw_fee_amount" field.
   115  	DefaultWithdrawFeeAmount decimal.Decimal
   116  	// DefaultCollectFeeAmount holds the default value on creation for the "collect_fee_amount" field.
   117  	DefaultCollectFeeAmount decimal.Decimal
   118  	// DefaultHotWalletFeeAmount holds the default value on creation for the "hot_wallet_fee_amount" field.
   119  	DefaultHotWalletFeeAmount decimal.Decimal
   120  	// DefaultLowFeeAmount holds the default value on creation for the "low_fee_amount" field.
   121  	DefaultLowFeeAmount decimal.Decimal
   122  	// DefaultHotLowFeeAmount holds the default value on creation for the "hot_low_fee_amount" field.
   123  	DefaultHotLowFeeAmount decimal.Decimal
   124  	// DefaultHotWalletAccountAmount holds the default value on creation for the "hot_wallet_account_amount" field.
   125  	DefaultHotWalletAccountAmount decimal.Decimal
   126  	// DefaultPaymentAccountCollectAmount holds the default value on creation for the "payment_account_collect_amount" field.
   127  	DefaultPaymentAccountCollectAmount decimal.Decimal
   128  	// DefaultLeastTransferAmount holds the default value on creation for the "least_transfer_amount" field.
   129  	DefaultLeastTransferAmount decimal.Decimal
   130  	// DefaultNeedMemo holds the default value on creation for the "need_memo" field.
   131  	DefaultNeedMemo bool
   132  	// DefaultRefreshCurrency holds the default value on creation for the "refresh_currency" field.
   133  	DefaultRefreshCurrency bool
   134  	// DefaultCheckNewAddressBalance holds the default value on creation for the "check_new_address_balance" field.
   135  	DefaultCheckNewAddressBalance bool
   136  )