add initial application structure with configuration, logging, and health check endpoints
This commit is contained in:
@@ -264,37 +264,37 @@ func (_u *EpicHeroInfoUpdate) SetNillableRawJSON(v *string) *EpicHeroInfoUpdate
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetSetContentJSON sets the "set_content_json" field.
|
||||
func (_u *EpicHeroInfoUpdate) SetSetContentJSON(v string) *EpicHeroInfoUpdate {
|
||||
_u.mutation.SetSetContentJSON(v)
|
||||
// SetContentJSONSet sets the "content_json_set" field.
|
||||
func (_u *EpicHeroInfoUpdate) SetContentJSONSet(v string) *EpicHeroInfoUpdate {
|
||||
_u.mutation.SetContentJSONSet(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableSetContentJSON sets the "set_content_json" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdate) SetNillableSetContentJSON(v *string) *EpicHeroInfoUpdate {
|
||||
// SetNillableContentJSONSet sets the "content_json_set" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdate) SetNillableContentJSONSet(v *string) *EpicHeroInfoUpdate {
|
||||
if v != nil {
|
||||
_u.SetSetContentJSON(*v)
|
||||
_u.SetContentJSONSet(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetSetUpdateTime sets the "set_update_time" field.
|
||||
func (_u *EpicHeroInfoUpdate) SetSetUpdateTime(v time.Time) *EpicHeroInfoUpdate {
|
||||
_u.mutation.SetSetUpdateTime(v)
|
||||
// SetUpdateTimeSet sets the "update_time_set" field.
|
||||
func (_u *EpicHeroInfoUpdate) SetUpdateTimeSet(v time.Time) *EpicHeroInfoUpdate {
|
||||
_u.mutation.SetUpdateTimeSet(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableSetUpdateTime sets the "set_update_time" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdate) SetNillableSetUpdateTime(v *time.Time) *EpicHeroInfoUpdate {
|
||||
// SetNillableUpdateTimeSet sets the "update_time_set" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdate) SetNillableUpdateTimeSet(v *time.Time) *EpicHeroInfoUpdate {
|
||||
if v != nil {
|
||||
_u.SetSetUpdateTime(*v)
|
||||
_u.SetUpdateTimeSet(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// ClearSetUpdateTime clears the value of the "set_update_time" field.
|
||||
func (_u *EpicHeroInfoUpdate) ClearSetUpdateTime() *EpicHeroInfoUpdate {
|
||||
_u.mutation.ClearSetUpdateTime()
|
||||
// ClearUpdateTimeSet clears the value of the "update_time_set" field.
|
||||
func (_u *EpicHeroInfoUpdate) ClearUpdateTimeSet() *EpicHeroInfoUpdate {
|
||||
_u.mutation.ClearUpdateTimeSet()
|
||||
return _u
|
||||
}
|
||||
|
||||
@@ -397,9 +397,9 @@ func (_u *EpicHeroInfoUpdate) check() error {
|
||||
return &ValidationError{Name: "raw_json", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.raw_json": %w`, err)}
|
||||
}
|
||||
}
|
||||
if v, ok := _u.mutation.SetContentJSON(); ok {
|
||||
if err := epicheroinfo.SetContentJSONValidator(v); err != nil {
|
||||
return &ValidationError{Name: "set_content_json", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.set_content_json": %w`, err)}
|
||||
if v, ok := _u.mutation.ContentJSONSet(); ok {
|
||||
if err := epicheroinfo.ContentJSONSetValidator(v); err != nil {
|
||||
return &ValidationError{Name: "content_json_set", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.content_json_set": %w`, err)}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
@@ -471,14 +471,14 @@ func (_u *EpicHeroInfoUpdate) sqlSave(ctx context.Context) (_node int, err error
|
||||
if value, ok := _u.mutation.RawJSON(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldRawJSON, field.TypeString, value)
|
||||
}
|
||||
if value, ok := _u.mutation.SetContentJSON(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldSetContentJSON, field.TypeString, value)
|
||||
if value, ok := _u.mutation.ContentJSONSet(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldContentJSONSet, field.TypeString, value)
|
||||
}
|
||||
if value, ok := _u.mutation.SetUpdateTime(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldSetUpdateTime, field.TypeTime, value)
|
||||
if value, ok := _u.mutation.UpdateTimeSet(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldUpdateTimeSet, field.TypeTime, value)
|
||||
}
|
||||
if _u.mutation.SetUpdateTimeCleared() {
|
||||
_spec.ClearField(epicheroinfo.FieldSetUpdateTime, field.TypeTime)
|
||||
if _u.mutation.UpdateTimeSetCleared() {
|
||||
_spec.ClearField(epicheroinfo.FieldUpdateTimeSet, field.TypeTime)
|
||||
}
|
||||
if _node, err = sqlgraph.UpdateNodes(ctx, _u.driver, _spec); err != nil {
|
||||
if _, ok := err.(*sqlgraph.NotFoundError); ok {
|
||||
@@ -736,37 +736,37 @@ func (_u *EpicHeroInfoUpdateOne) SetNillableRawJSON(v *string) *EpicHeroInfoUpda
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetSetContentJSON sets the "set_content_json" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetSetContentJSON(v string) *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.SetSetContentJSON(v)
|
||||
// SetContentJSONSet sets the "content_json_set" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetContentJSONSet(v string) *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.SetContentJSONSet(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableSetContentJSON sets the "set_content_json" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetNillableSetContentJSON(v *string) *EpicHeroInfoUpdateOne {
|
||||
// SetNillableContentJSONSet sets the "content_json_set" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetNillableContentJSONSet(v *string) *EpicHeroInfoUpdateOne {
|
||||
if v != nil {
|
||||
_u.SetSetContentJSON(*v)
|
||||
_u.SetContentJSONSet(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetSetUpdateTime sets the "set_update_time" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetSetUpdateTime(v time.Time) *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.SetSetUpdateTime(v)
|
||||
// SetUpdateTimeSet sets the "update_time_set" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetUpdateTimeSet(v time.Time) *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.SetUpdateTimeSet(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableSetUpdateTime sets the "set_update_time" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetNillableSetUpdateTime(v *time.Time) *EpicHeroInfoUpdateOne {
|
||||
// SetNillableUpdateTimeSet sets the "update_time_set" field if the given value is not nil.
|
||||
func (_u *EpicHeroInfoUpdateOne) SetNillableUpdateTimeSet(v *time.Time) *EpicHeroInfoUpdateOne {
|
||||
if v != nil {
|
||||
_u.SetSetUpdateTime(*v)
|
||||
_u.SetUpdateTimeSet(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// ClearSetUpdateTime clears the value of the "set_update_time" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) ClearSetUpdateTime() *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.ClearSetUpdateTime()
|
||||
// ClearUpdateTimeSet clears the value of the "update_time_set" field.
|
||||
func (_u *EpicHeroInfoUpdateOne) ClearUpdateTimeSet() *EpicHeroInfoUpdateOne {
|
||||
_u.mutation.ClearUpdateTimeSet()
|
||||
return _u
|
||||
}
|
||||
|
||||
@@ -882,9 +882,9 @@ func (_u *EpicHeroInfoUpdateOne) check() error {
|
||||
return &ValidationError{Name: "raw_json", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.raw_json": %w`, err)}
|
||||
}
|
||||
}
|
||||
if v, ok := _u.mutation.SetContentJSON(); ok {
|
||||
if err := epicheroinfo.SetContentJSONValidator(v); err != nil {
|
||||
return &ValidationError{Name: "set_content_json", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.set_content_json": %w`, err)}
|
||||
if v, ok := _u.mutation.ContentJSONSet(); ok {
|
||||
if err := epicheroinfo.ContentJSONSetValidator(v); err != nil {
|
||||
return &ValidationError{Name: "content_json_set", err: fmt.Errorf(`ent: validator failed for field "EpicHeroInfo.content_json_set": %w`, err)}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
@@ -973,14 +973,14 @@ func (_u *EpicHeroInfoUpdateOne) sqlSave(ctx context.Context) (_node *EpicHeroIn
|
||||
if value, ok := _u.mutation.RawJSON(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldRawJSON, field.TypeString, value)
|
||||
}
|
||||
if value, ok := _u.mutation.SetContentJSON(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldSetContentJSON, field.TypeString, value)
|
||||
if value, ok := _u.mutation.ContentJSONSet(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldContentJSONSet, field.TypeString, value)
|
||||
}
|
||||
if value, ok := _u.mutation.SetUpdateTime(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldSetUpdateTime, field.TypeTime, value)
|
||||
if value, ok := _u.mutation.UpdateTimeSet(); ok {
|
||||
_spec.SetField(epicheroinfo.FieldUpdateTimeSet, field.TypeTime, value)
|
||||
}
|
||||
if _u.mutation.SetUpdateTimeCleared() {
|
||||
_spec.ClearField(epicheroinfo.FieldSetUpdateTime, field.TypeTime)
|
||||
if _u.mutation.UpdateTimeSetCleared() {
|
||||
_spec.ClearField(epicheroinfo.FieldUpdateTimeSet, field.TypeTime)
|
||||
}
|
||||
_node = &EpicHeroInfo{config: _u.config}
|
||||
_spec.Assign = _node.assignValues
|
||||
|
||||
Reference in New Issue
Block a user