refactor platform menus and entity statuses
This commit is contained in:
@@ -84,7 +84,7 @@ func createResource(ctx *gin.Context, model any, allowedFields []string, relatio
|
||||
infra.Response.Error(ctx, errcode.ErrInvalidArgument)
|
||||
return
|
||||
}
|
||||
data.Elem().FieldByName("Entity").Set(reflect.ValueOf(NewEntity("draft")))
|
||||
data.Elem().FieldByName("Entity").Set(reflect.ValueOf(NewEntity(StatusDraft)))
|
||||
if err := impl.DBService.Create(data.Interface()).Error; err != nil {
|
||||
infra.Response.Error(ctx, err)
|
||||
return
|
||||
@@ -347,7 +347,6 @@ var relationIdentityModels = map[string]any{
|
||||
"gasorder_basic_id": &models.GasorderBasic{},
|
||||
"gasorder_track_id": &models.GasorderTrack{},
|
||||
"platform_role_id": &models.PlatformRole{},
|
||||
"platform_menu_id": &models.PlatformMenu{},
|
||||
"wallet_basic_id": &models.WalletBasic{},
|
||||
"wallet_payment_id": &models.WalletPayment{},
|
||||
"wallet_bank_id": &models.WalletBank{},
|
||||
|
||||
Reference in New Issue
Block a user