Merge branch 'mark' of e.coding.net:rosydev/jx-callback into mark
This commit is contained in:
@@ -13,7 +13,7 @@ import (
|
||||
|
||||
func IDCULDFilterMapByStructObject(mapData map[string]interface{}, obj interface{}, isCheckValue bool) (valid map[string]interface{}, invalid map[string]interface{}) {
|
||||
// 这里必须用首字母小写,因为是用于访问map,是需要完全匹配的
|
||||
return refutil.FilterMapByStructObject(mapData, obj, []string{"id", "createdAt", "updatedAt", "finishedAt", "deletedAt", "syncStatus", "lastOperator"}, isCheckValue)
|
||||
return refutil.FilterMapByStructObject(mapData, obj, nil, []string{"id", "createdAt", "updatedAt", "finishedAt", "deletedAt", "syncStatus", "lastOperator"}, isCheckValue)
|
||||
}
|
||||
|
||||
func NormalMakeMapByStructObject(mapData map[string]interface{}, obj interface{}, userName string) (retVal map[string]interface{}) {
|
||||
@@ -26,6 +26,16 @@ func StrictMakeMapByStructObject(mapData map[string]interface{}, obj interface{}
|
||||
return retVal
|
||||
}
|
||||
|
||||
func IDCULDFilterMapByStructObject2(mapData map[string]interface{}, obj interface{}, objPtr interface{}, isCheckValue bool) (valid map[string]interface{}, invalid map[string]interface{}) {
|
||||
return refutil.FilterMapByStructObject(mapData, obj, objPtr, []string{"id", "createdAt", "updatedAt", "finishedAt", "deletedAt", "syncStatus", "lastOperator"}, isCheckValue)
|
||||
}
|
||||
|
||||
//根据传进来的objPtr去修改它的值
|
||||
func StrictMakeMapByStructObject2(mapData map[string]interface{}, obj interface{}, objPtr interface{}, userName string) (retVal map[string]interface{}) {
|
||||
retVal, _ = IDCULDFilterMapByStructObject2(mapData, obj, objPtr, true)
|
||||
return retVal
|
||||
}
|
||||
|
||||
func NormalMakeMapByFieldList(mapData map[string]interface{}, fields []string, userName string) (retVal map[string]interface{}) {
|
||||
retVal, _ = refutil.FilterMapByFieldList(mapData, fields)
|
||||
return retVal
|
||||
|
||||
@@ -252,14 +252,14 @@ type Store struct {
|
||||
Address string `orm:"size(255)" json:"address"`
|
||||
Tel1 string `orm:"size(32);index" json:"tel1"`
|
||||
Tel2 string `orm:"size(32);index" json:"tel2"`
|
||||
OpenTime1 int16 `json:"openTime1"` // 930就表示9点半,用两个的原因是为了支持中午休息,1与2的时间段不能交叉,为0表示没有
|
||||
CloseTime1 int16 `json:"closeTime1"` // 格式同上
|
||||
OpenTime2 int16 `json:"openTime2"` // 格式同上
|
||||
CloseTime2 int16 `json:"closeTime2"` // 格式同上
|
||||
Lng int `json:"-"` // 乘了10的6次方
|
||||
Lat int `json:"-"` // 乘了10的6次方
|
||||
DeliveryRangeType int8 `json:"deliveryRangeType"` // 参见相关常量定义
|
||||
DeliveryRange string `orm:"type(text)" json:"deliveryRange"` // 如果DeliveryRangeType为DeliveryRangeTypePolygon,则为逗号分隔坐标,分号分隔的坐标点(坐标与Lng和Lat一样,都是整数),比如 121361504,31189308;121420555,31150238。否则为半径,单位为米
|
||||
OpenTime1 int16 `json:"openTime1" validate:"max=2359,min=1,ltfield=CloseTime1"` // 930就表示9点半,用两个的原因是为了支持中午休息,1与2的时间段不能交叉,为0表示没有
|
||||
CloseTime1 int16 `json:"closeTime1" validate:"max=2359,min=1` // 格式同上
|
||||
OpenTime2 int16 `json:"openTime2" validate:"max=2359,min=1,ltfield=CloseTime2"` // 格式同上
|
||||
CloseTime2 int16 `json:"closeTime2" validate:"max=2359,min=1` // 格式同上
|
||||
Lng int `json:"-"` // 乘了10的6次方
|
||||
Lat int `json:"-"` // 乘了10的6次方
|
||||
DeliveryRangeType int8 `json:"deliveryRangeType"` // 参见相关常量定义
|
||||
DeliveryRange string `orm:"type(text)" json:"deliveryRange"` // 如果DeliveryRangeType为DeliveryRangeTypePolygon,则为逗号分隔坐标,分号分隔的坐标点(坐标与Lng和Lat一样,都是整数),比如 121361504,31189308;121420555,31150238。否则为半径,单位为米
|
||||
Status int `json:"status"`
|
||||
AutoEnableAt *time.Time `orm:"type(datetime);null" json:"autoEnableAt"` // 自动营业时间(临时休息用)
|
||||
ChangePriceType int8 `json:"changePriceType"` // 修改价格类型,即是否需要审核
|
||||
|
||||
Reference in New Issue
Block a user