You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
258 lines
7.6 KiB
258 lines
7.6 KiB
package commonus
|
|
|
|
//获取Token类型设置
|
|
type getTokenType struct {
|
|
Type string `json:"type"`
|
|
}
|
|
|
|
//组织架构返回统类
|
|
type weChatCallBack struct {
|
|
Errcode int `json:"errcode"`
|
|
Errmsg string `json:"errmsg"`
|
|
Accesstoken string `json:"access_token"`
|
|
Expiresin int64 `json:"expires_in"`
|
|
}
|
|
|
|
//获取部门列表
|
|
type dePartMent struct {
|
|
Errcode int `json:"errcode"`
|
|
Errmsg string `json:"errmsg"`
|
|
DePartMent []DePartMentInfo `json:"department"`
|
|
}
|
|
type DePartMentInfo struct {
|
|
Id int64 `json:"id"`
|
|
Name string `json:"name"`
|
|
NameEN string `json:"name_en"`
|
|
Parentid int64 `json:"parentid"`
|
|
Order int64 `json:"order"`
|
|
}
|
|
|
|
type dePartMentInfoStr struct {
|
|
Id string `json:"id"`
|
|
Name string `json:"name"`
|
|
NameEN string `json:"name_en"`
|
|
Parentid string `json:"parentid"`
|
|
Order string `json:"order"`
|
|
}
|
|
|
|
//添加部门列表
|
|
type DePartMentCallBack struct {
|
|
Errcode int `json:"errcode"`
|
|
Errmsg string `json:"errmsg"`
|
|
Id int64 `json:"id"`
|
|
}
|
|
|
|
//健康上报使用统计
|
|
type HealthReportStat struct {
|
|
Errcode int `json:"errcode"` //返回码
|
|
Errmsg string `json:"errmsg"` //对返回码的文本描述内容
|
|
Pv int64 `json:"pv"` //应用使用次数
|
|
Uv int64 `json:"uv"` //应用使用成员数
|
|
}
|
|
|
|
//获取参数样式健康上报使用统计
|
|
type GetHealthReport struct {
|
|
Date string `json:"date"`
|
|
}
|
|
|
|
//正在运行的上报任务ID列表。
|
|
type GetHealthReportRun struct {
|
|
Offset int `json:"offset"`
|
|
Limit int64 `json:"limit"`
|
|
Page int `json:"page"`
|
|
PageSize int64 `json:"pagesize"`
|
|
}
|
|
|
|
//获取企业当前正在运行的上报任务ID列表。
|
|
type CallBackData struct {
|
|
Errcode int `json:"errcode"`
|
|
ErrMsg string `json:"errmsg"`
|
|
Ending int `json:"ending"`
|
|
Jobids []interface{} `json:"jobids"`
|
|
}
|
|
|
|
//获取指定的健康上报任务详情。
|
|
|
|
type GetReportJobInfoDate struct {
|
|
JobId string `json:"jobid"`
|
|
Date string `json:"date"`
|
|
}
|
|
|
|
type CallBackReportJobInfo struct {
|
|
Errcode int `json:"errcode"`
|
|
ErrMsg string `json:"errmsg"`
|
|
JobInfo ReportJobInfo `json:"job_info"`
|
|
}
|
|
|
|
type ReportJobInfo struct {
|
|
Title string `json:"title"`
|
|
Creator string `json:"creator"`
|
|
Type int `json:"type"`
|
|
ApplyRange ApplyRangeStruct `json:"apply_range"`
|
|
ReportTo ApplyRangeStruct `json:"report_to"`
|
|
// ReportTo ReportToStruct `json:"report_to"`
|
|
ReportType int `json:"report_type"`
|
|
SkipWeekend int `json:"skip_weekend"`
|
|
FinishCnt int `json:"finish_cnt"`
|
|
QuestionTemplates []QuestionTemplatesStruct `json:"question_templates"`
|
|
}
|
|
|
|
type ApplyRangeStruct struct {
|
|
UserIds []string `json:"userids"`
|
|
Partyids []int64 `json:"partyids"`
|
|
}
|
|
|
|
type ReportToStruct struct {
|
|
UserIds []string `json:"userids"`
|
|
}
|
|
|
|
type QuestionTemplatesStruct struct {
|
|
QuestionId int64 `json:"question_id"`
|
|
Title string `json:"title"`
|
|
QuestionType int `json:"question_type"`
|
|
IsRequired int `json:"is_required"`
|
|
OptionList []OptionListStruct `json:"option_list"`
|
|
}
|
|
|
|
type OptionListStruct struct {
|
|
OptionId int `json:"option_id"`
|
|
OptionText string `json:"option_text"`
|
|
}
|
|
|
|
//获取用户填写答案列表
|
|
type ReportAnswerStruct struct {
|
|
JobId string `json:"jobid"` //任务ID
|
|
Date string `json:"date"` //具体某天任务的填写答案
|
|
Offset int `json:"offset"` //数据偏移量
|
|
Limit int `json:"limit"` //拉取的数据量
|
|
Page int `json:"page"` //数据偏移量
|
|
PageSize int `json:"pagesize"` //拉取的数据量
|
|
}
|
|
|
|
//获取用户填写答案返回结果
|
|
type ReportAnswerResult struct {
|
|
Errcode int `json:"errcode"`
|
|
ErrMsg string `json:"errmsg"`
|
|
Answers []AnswersStruct `json:"answers"`
|
|
}
|
|
|
|
type AnswersStruct struct {
|
|
IdType int `json:"id_type"`
|
|
Userid string `json:"userid"`
|
|
StudentUserid string `json:"student_userid"`
|
|
ParentUserid string `json:"parent_userid"`
|
|
|
|
ReportValues []ReportValuesStruct `json:"report_values"`
|
|
}
|
|
|
|
type ReportValuesStruct struct {
|
|
QuestionId int `json:"question_id"`
|
|
SingleChoice int `json:"single_choice"`
|
|
Text string `json:"text"`
|
|
MultiChoice []int `json:"multi_choice"`
|
|
Fileid []string `json:"fileid"`
|
|
}
|
|
|
|
//行政区域
|
|
type AdministrativeDivision struct {
|
|
Userid string `json:"userid"`
|
|
Province string `json:"province"`
|
|
City string `json:"city"`
|
|
County string `json:"county"`
|
|
}
|
|
|
|
//围栏地址
|
|
type EnclosureAddress struct {
|
|
Province int64 `json:"province"` //'省',
|
|
ProvinceName string `json:"province_name"` // '省名称',
|
|
City int64 `json:"city"` // '市',
|
|
CityName string `json:"city_name"` // '市名称',
|
|
County int64 `county` // '县',
|
|
CountyName string `county_name` // '县名称',
|
|
}
|
|
|
|
//读取成员
|
|
type WechatUserInfo struct {
|
|
Errcode int `json:"errcode"`
|
|
ErrMsg string `json:"errmsg"`
|
|
UserListStruct
|
|
}
|
|
|
|
//扩展属性,代开发自建应用需要管理员授权才返回;第三方仅通讯录应用可获取;对于非第三方创建的成员,第三方通讯录应用也不可获取
|
|
type ExtattrStruct struct {
|
|
Attrs []AttrsStruct `json:"attrs"`
|
|
}
|
|
|
|
//扩展附属属性
|
|
type AttrsStruct struct {
|
|
Type int `json:"type"`
|
|
Name string `json:"name"`
|
|
text []TextStruct `json:"text"`
|
|
Web []WebStruct `json:"web"`
|
|
}
|
|
|
|
type TextStruct struct {
|
|
Value string `json:"value"`
|
|
}
|
|
type WebStruct struct {
|
|
Url string `json:"url"`
|
|
Title string `json:"title"`
|
|
}
|
|
|
|
type ExternalProfileStruct struct {
|
|
ExternalCorpName string `json:"external_corp_name"`
|
|
WechatChannels WechatChannelsStruct `json:"wechat_channels"`
|
|
ExternalAttr []ExternalAttrStruct `json:"external_attr"`
|
|
}
|
|
|
|
type WechatChannelsStruct struct {
|
|
Status int `json:"status"`
|
|
NickName string `json:"nickname"`
|
|
}
|
|
|
|
type ExternalAttrStruct struct {
|
|
Type int `json:"type"`
|
|
Name string `json:"name"`
|
|
text []TextStruct `json:"text"`
|
|
Web []WebStruct `json:"web"`
|
|
MiniproGram MiniproGramStruct `json:"miniprogram"`
|
|
}
|
|
type MiniproGramStruct struct {
|
|
Appid string `json:"appid"`
|
|
Pagepath string `json:"pagepath"`
|
|
Title string `json:"title"`
|
|
}
|
|
|
|
//获取部门成员信息
|
|
type WechatUserInfoDepartment struct {
|
|
Errcode int `json:"errcode"`
|
|
ErrMsg string `json:"errmsg"`
|
|
UserList []UserListStruct `json:"userlist"`
|
|
}
|
|
|
|
type UserListStruct struct {
|
|
UserId string `json:"userid"`
|
|
Name string `json:"name"`
|
|
Department []int `json:"department"`
|
|
Order []int `json:"order"`
|
|
Position string `json:"position"`
|
|
Mobile string `json:"mobile"`
|
|
Gender string `json:"gender"`
|
|
Email string `json:"email"`
|
|
IsLeaderInDept []int `json:"is_leader_in_dept"`
|
|
DirectLeader []string `json:"direct_leader"`
|
|
Avatar string `json:"avatar"`
|
|
ThumbAvatar string `json:"thumb_avatar"`
|
|
Telephone string `json:"telephone"`
|
|
Alias string `json:"alias"`
|
|
Address string `json:"address"`
|
|
OpenUserid string `json:"open_userid"`
|
|
MainDepartment int `json:"main_department"`
|
|
|
|
Extattr ExtattrStruct `json:"extattr"`
|
|
|
|
Status int `json:"status"`
|
|
QrCode string `json:"qr_code"`
|
|
ExternalPosition string `json:"external_position"`
|
|
ExternalProfile ExternalProfileStruct `json:"external_profile"`
|
|
}
|
|
|