Documentation ¶
Index ¶
- func CreateGroup(param Group) error
- func CreateSchema(param Schema) error
- func DelGroup(tangentId, id, userId string) error
- func DelSchema(tangentId, id, userId string) error
- func Destroy()
- func Init(baseUrl string, timeoutSec time.Duration)
- func Migrate() error
- func UptGroup(param Group) error
- func UptSchema(param Schema) error
- type ClockInMode
- type ConflictDetail
- type DeptUser
- type GetGroupParam
- type GetRecordParam
- type GetSchemaParam
- type Group
- type GroupInfo
- type GroupSchema
- type MiniGroup
- type MiniSchema
- type Must
- type MustInfo
- type PlaceClockInSetting
- type RecordInfo
- type Resp
- type Result
- type Schema
- type Slot
- type User
- type WorkSys
- type WorkSysInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateGroup ¶
func CreateSchema ¶
Types ¶
type ClockInMode ¶
type ClockInMode struct { Id string `json:"id"` Mode uint8 `json:"mode"` // Setting 打卡方式配置明细 Setting []any `json:"setting"` }
ClockInMode 打卡方式
type ConflictDetail ¶
type DeptUser ¶
type DeptUser struct { DeptId string `json:"deptId"` Num int `json:"num"` UserIds []string `json:"userIds"` AutoJoin bool `json:"autoJoin"` }
DeptUser 部门考勤人员信息
type GetGroupParam ¶
type GetRecordParam ¶ added in v0.15.80
type GetRecordParam struct { TangentId string `validate:"required,len=32" form:"tangentId"` UserId string `validate:"required,len=32" form:"userId"` Start string `form:"start"` End string `form:"end"` CheckInDate string `form:"checkIndDate"` RecordType uint8 `form:"recordType"` PageNo int `form:"pageNo"` PageSize int `form:"pageSize"` }
type GetSchemaParam ¶
type Group ¶
type Group struct { Id string `form:"id" json:"id"` Name string `form:"name" json:"name"` TangentId string `form:"tangentId" json:"tangentId"` Modes []ClockInMode `form:"modes" json:"modes"` AllowOut bool `form:"allowOut" json:"allowOut"` UserId string `form:"userId" json:"userId"` Charge string `form:"charge" json:"charge"` User `json:"user"` WorkSys `json:"workSys"` }
Group 考勤组
type GroupInfo ¶
type GroupInfo struct { Id string `json:"id"` Name string `json:"name"` TangentId string `json:"tangentId"` Modes []ClockInMode `json:"modes"` AllowOut bool `json:"allowOut"` Charge string `json:"charge"` CreateBy string `json:"createBy"` User `json:"user"` WorkSysInfo `json:"workSys"` }
func GroupDetail ¶
type GroupSchema ¶
type MiniGroup ¶
type MiniGroup struct { Id string `json:"id"` Name string `json:"name"` SchemaId string `json:"schemaId"` SchemaName string `json:"schemaName"` UserNum int `json:"userNum"` TangentId string `json:"tangentId"` CreateBy string `json:"createBy"` Charge string `json:"charge"` CreatedAt string `json:"createdAt"` ClockModes []uint8 `json:"clockModes"` AllowOut bool `json:"allowOut"` }
type MiniSchema ¶
type MustInfo ¶
type MustInfo struct { Id string `json:"id"` Date string `json:"date"` GroupSchema `json:"schema"` }
type PlaceClockInSetting ¶
type PlaceClockInSetting struct { Id string `json:"id"` Lat float64 `json:"lat"` Lng float64 `json:"lng"` ShortName string `json:"shortName"` Addr string `json:"addr"` Range int `json:"range"` }
PlaceClockInSetting 地点打卡配置
type RecordInfo ¶ added in v0.15.80
type RecordInfo struct { Id string `json:"id"` TangentId string `json:"tangentId"` UserId string `json:"userId"` CheckInTime string `json:"checkInTime"` Img string `json:"img"` Lat float64 `json:"lat"` Lng float64 `json:"lng"` Addr string `json:"addr"` Type uint8 `json:"type"` Status uint8 `json:"status"` SchemaId string `json:"schemaId"` SlotId string `json:"slotId"` GroupId string `json:"groupId"` TimeOffset float64 `json:"timeOffset"` Way uint8 `json:"way"` Remark string `json:"remark"` }
type Result ¶
type Result[T any] struct { Info []T `json:"info"` TotalCount int `json:"totalCount"` PageNo int `json:"pageNo"` }
func GetBigDataRecords ¶ added in v0.15.81
func GetBigDataRecords(param GetRecordParam) (Result[RecordInfo], error)
func GetRecords ¶ added in v0.15.80
func GetRecords(param GetRecordParam) (Result[RecordInfo], error)
func GetSchema ¶
func GetSchema(param GetSchemaParam) (Result[MiniSchema], error)
type Schema ¶
type Schema struct { Id string `json:"id" form:"id"` Name string `json:"name" form:"name"` TangentId string `json:"tangentId" form:"tangentId"` LunchRestStart string `json:"lunchRestStart" form:"lunchRestStart"` LunchRestEnd string `json:"lunchRestEnd" form:"lunchRestEnd"` Slots []Slot `json:"slots" form:"slots"` Charge string `json:"charge" form:"charge"` Start string `json:"start" form:"start"` End string `json:"end" form:"end"` CreateBy string `json:"createBy" form:"createBy"` CreatedAt string `json:"createdAt" form:"createdAt"` }
func SchemaDetail ¶
type Slot ¶
type Slot struct { Id string `json:"id"` GoWorkTime string `json:"goWorkTime"` GoWorkTimeOffsetStart string `json:"goWorkTimeOffsetStart"` GoWorkTimeOffsetEnd string `json:"goWorkTimeOffsetEnd"` OffWorkTime string `json:"offWorkTime"` OffWorkTimeOffsetStart string `json:"offWorkTimeOffsetStart"` OffWorkTimeOffsetEnd string `json:"offWorkTimeOffsetEnd"` }
type User ¶
type User struct { JoinUser []string `json:"joinUser"` Ignore []string `json:"ignore"` Dept []DeptUser `json:"dept"` }
User 考勤人员配置
type WorkSys ¶
type WorkSys struct { DefSchemaId string `json:"defSchemaId"` Monday string `json:"monday"` Tuesday string `json:"tuesday"` Wednesday string `json:"wednesday"` Thursday string `json:"thursday"` Friday string `json:"friday"` Saturday string `json:"saturday"` Sunday string `json:"sunday"` Rest []string `json:"rest"` Holidays bool `json:"holidays"` Musts []Must `json:"musts"` Skips []string `json:"skips"` }
WorkSys 班制
type WorkSysInfo ¶
type WorkSysInfo struct { Id string `json:"id"` Name string `json:"name"` DefSchema GroupSchema `json:"defSchema"` WorkDayInfo []GroupSchema `json:"workDayInfo"` Rest []string `json:"rest"` Holidays bool `json:"holidays"` Musts []MustInfo `json:"musts"` Skips []string `json:"skips"` }
Click to show internal directories.
Click to hide internal directories.