Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for Unix (0.12 sec)

  1. schema/serializer.go

    	switch v := fieldValue.(type) {
    	case int64, int, uint, uint64, int32, uint32, int16, uint16:
    		result = time.Unix(reflect.Indirect(rv).Int(), 0).UTC()
    	case *int64, *int, *uint, *uint64, *int32, *uint32, *int16, *uint16:
    		if rv.IsZero() {
    			return nil, nil
    		}
    		result = time.Unix(reflect.Indirect(rv).Int(), 0).UTC()
    	default:
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Mar 18 08:28:46 GMT 2024
    - 4.6K bytes
    - Viewed (0)
  2. callbacks/create.go

    										assignment.Value = curTime.UnixNano()
    									case schema.UnixMillisecond:
    										assignment.Value = curTime.UnixMilli()
    									case schema.UnixSecond:
    										assignment.Value = curTime.Unix()
    									}
    
    									onConflict.DoUpdates = append(onConflict.DoUpdates, assignment)
    								} else {
    									columns = append(columns, column.Name)
    								}
    							}
    						}
    					}
    				}
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Apr 08 03:29:55 GMT 2024
    - 12.5K bytes
    - Viewed (0)
  3. callbacks/update.go

    						} else if field.AutoUpdateTime == schema.UnixSecond {
    							set = append(set, clause.Assignment{Column: clause.Column{Name: field.DBName}, Value: now.Unix()})
    						} else {
    							set = append(set, clause.Assignment{Column: clause.Column{Name: field.DBName}, Value: now})
    						}
    					}
    				}
    			}
    		}
    	default:
    		updatingSchema := stmt.Schema
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Mar 18 05:44:55 GMT 2024
    - 9.4K bytes
    - Viewed (1)
  4. schema/field.go

    				} else if field.AutoCreateTime == UnixMillisecond || field.AutoUpdateTime == UnixMillisecond {
    					field.ReflectValueOf(ctx, value).SetInt(data.UnixMilli())
    				} else {
    					field.ReflectValueOf(ctx, value).SetInt(data.Unix())
    				}
    			case *time.Time:
    				if data != nil {
    					if field.AutoCreateTime == UnixNanosecond || field.AutoUpdateTime == UnixNanosecond {
    						field.ReflectValueOf(ctx, value).SetInt(data.UnixNano())
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Apr 15 03:20:20 GMT 2024
    - 32K bytes
    - Viewed (1)
Back to top