|
@@ -1,7 +1,6 @@
|
|
|
package qiyuesuosdk
|
|
package qiyuesuosdk
|
|
|
|
|
|
|
|
import (
|
|
import (
|
|
|
- "strconv"
|
|
|
|
|
"time"
|
|
"time"
|
|
|
|
|
|
|
|
v2auth_request "git.sxidc.com/student-physical-examination/contract_lock_sdk/model/v2auth/request"
|
|
v2auth_request "git.sxidc.com/student-physical-examination/contract_lock_sdk/model/v2auth/request"
|
|
@@ -26,7 +25,27 @@ type companySealAuthURLResp struct {
|
|
|
|
|
|
|
|
type companyAuthRecordResp struct {
|
|
type companyAuthRecordResp struct {
|
|
|
apiResponse
|
|
apiResponse
|
|
|
- Result []common.AuthorizedSealRecordBean `json:"result"`
|
|
|
|
|
|
|
+ Result []authorizedSealRecordItem `json:"result"`
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+type authorizedSealRecordItem struct {
|
|
|
|
|
+ AuthorizedSealRecord *authorizedSealRecord `json:"authorizedSealRecord"`
|
|
|
|
|
+ SealBean *authorizedSealBean `json:"sealBean"`
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+type authorizedSealRecord struct {
|
|
|
|
|
+ SealId string `json:"sealId"`
|
|
|
|
|
+ StartTime string `json:"startTime"`
|
|
|
|
|
+ EndTime string `json:"endTime"`
|
|
|
|
|
+ AuthScope string `json:"authScope"`
|
|
|
|
|
+ Status string `json:"status"`
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+type authorizedSealBean struct {
|
|
|
|
|
+ ID flexStringID `json:"id"`
|
|
|
|
|
+ Name string `json:"name"`
|
|
|
|
|
+ Type string `json:"type"`
|
|
|
|
|
+ SealAttribute string `json:"sealAttribute"`
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// CompanyCertificationURL 获取法人单位在线认证页 URL。
|
|
// CompanyCertificationURL 获取法人单位在线认证页 URL。
|
|
@@ -201,17 +220,17 @@ func (c *Client) ListAuthorizedCompanySeals(company CompanyLocateParams, status
|
|
|
return out, nil
|
|
return out, nil
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-func authorizedSealFromRecord(item common.AuthorizedSealRecordBean) AuthorizedCompanySeal {
|
|
|
|
|
|
|
+func authorizedSealFromRecord(item authorizedSealRecordItem) AuthorizedCompanySeal {
|
|
|
seal := AuthorizedCompanySeal{}
|
|
seal := AuthorizedCompanySeal{}
|
|
|
if item.AuthorizedSealRecord != nil {
|
|
if item.AuthorizedSealRecord != nil {
|
|
|
seal.ID = item.AuthorizedSealRecord.SealId
|
|
seal.ID = item.AuthorizedSealRecord.SealId
|
|
|
}
|
|
}
|
|
|
if item.SealBean != nil {
|
|
if item.SealBean != nil {
|
|
|
- if seal.ID == "" && item.SealBean.Id != nil {
|
|
|
|
|
- seal.ID = strconv.FormatInt(*item.SealBean.Id, 10)
|
|
|
|
|
|
|
+ if seal.ID == "" {
|
|
|
|
|
+ seal.ID = item.SealBean.ID.String()
|
|
|
}
|
|
}
|
|
|
seal.Name = item.SealBean.Name
|
|
seal.Name = item.SealBean.Name
|
|
|
- seal.Type = item.SealBean.Type_
|
|
|
|
|
|
|
+ seal.Type = item.SealBean.Type
|
|
|
seal.SealAttribute = item.SealBean.SealAttribute
|
|
seal.SealAttribute = item.SealBean.SealAttribute
|
|
|
}
|
|
}
|
|
|
return seal
|
|
return seal
|