remove unused comments
This commit is contained in:
parent
6b6721cccc
commit
ba71ae6665
|
@ -551,16 +551,11 @@ func (session *Session) row2Bean(rows *core.Rows, fields []string, fieldsCount i
|
||||||
// !nashtsai! convert to engine location
|
// !nashtsai! convert to engine location
|
||||||
t = t.In(tz)
|
t = t.In(tz)
|
||||||
fieldValue.Set(reflect.ValueOf(t).Convert(fieldType))
|
fieldValue.Set(reflect.ValueOf(t).Convert(fieldType))
|
||||||
|
|
||||||
// t = fieldValue.Interface().(time.Time)
|
|
||||||
// z, _ = t.Zone()
|
|
||||||
// session.Engine.LogDebug("fieldValue key[%v]: %v | zone: %v | location: %+v\n", key, t, z, *t.Location())
|
|
||||||
} else if rawValueType == core.IntType || rawValueType == core.Int64Type ||
|
} else if rawValueType == core.IntType || rawValueType == core.Int64Type ||
|
||||||
rawValueType == core.Int32Type {
|
rawValueType == core.Int32Type {
|
||||||
hasAssigned = true
|
hasAssigned = true
|
||||||
|
|
||||||
t := time.Unix(vv.Int(), 0).In(tz)
|
t := time.Unix(vv.Int(), 0).In(tz)
|
||||||
//vv = reflect.ValueOf(t)
|
|
||||||
fieldValue.Set(reflect.ValueOf(t).Convert(fieldType))
|
fieldValue.Set(reflect.ValueOf(t).Convert(fieldType))
|
||||||
} else {
|
} else {
|
||||||
if d, ok := vv.Interface().([]uint8); ok {
|
if d, ok := vv.Interface().([]uint8); ok {
|
||||||
|
@ -642,8 +637,6 @@ func (session *Session) row2Bean(rows *core.Rows, fields []string, fieldsCount i
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
if has {
|
if has {
|
||||||
//v := structInter.Elem().Interface()
|
|
||||||
//fieldValue.Set(reflect.ValueOf(v))
|
|
||||||
fieldValue.Set(structInter.Elem())
|
fieldValue.Set(structInter.Elem())
|
||||||
} else {
|
} else {
|
||||||
return nil, errors.New("cascade obj is not exist")
|
return nil, errors.New("cascade obj is not exist")
|
||||||
|
@ -652,7 +645,6 @@ func (session *Session) row2Bean(rows *core.Rows, fields []string, fieldsCount i
|
||||||
}
|
}
|
||||||
case reflect.Ptr:
|
case reflect.Ptr:
|
||||||
// !nashtsai! TODO merge duplicated codes above
|
// !nashtsai! TODO merge duplicated codes above
|
||||||
//typeStr := fieldType.String()
|
|
||||||
switch fieldType {
|
switch fieldType {
|
||||||
// following types case matching ptr's native type, therefore assign ptr directly
|
// following types case matching ptr's native type, therefore assign ptr directly
|
||||||
case core.PtrStringType:
|
case core.PtrStringType:
|
||||||
|
|
Loading…
Reference in New Issue