This commit is contained in:
Lunny Xiao 2015-10-26 16:06:38 +08:00
parent 4578668362
commit 1da71e850a
1 changed files with 4 additions and 0 deletions

View File

@ -3332,10 +3332,14 @@ func (session *Session) innerInsert(bean interface{}) (int64, error) {
var v interface{} = id var v interface{} = id
switch aiValue.Type().Kind() { switch aiValue.Type().Kind() {
case reflect.Int16:
v = int16(id)
case reflect.Int32: case reflect.Int32:
v = int32(id) v = int32(id)
case reflect.Int: case reflect.Int:
v = int(id) v = int(id)
case reflect.Uint16:
v = uint16(id)
case reflect.Uint32: case reflect.Uint32:
v = uint32(id) v = uint32(id)
case reflect.Uint64: case reflect.Uint64: