123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- package adm
- import (
- "gd_service/apis"
- "gd_service/consts"
- "gd_service/errors"
- )
- /*
- func A05(ctx context.Context, vin string, reply map[string]string, lReqs *[]apis.ThirdpartLogWrite, providerMap map[string]apis.MerchantProviderLimitInfo, rangeNo int) error {
- if CheckProviderApiIsAvaliable(dutils.ADMA05, providerMap, rangeNo) == nil {
- str, err := (&Adm{
- Ctx: ctx,
- Params: map[string]string{
- "vin": vin,
- },
- Code: consts.A05,
- LReqs: lReqs,
- Provider: providerMap[dutils.ADMA05+strconv.Itoa(rangeNo)],
- }).Request()
- if err != nil {
- return err
- }
- utils.Convertion(reply, str)
- } else {
- return errors.ProviderUnavailable
- }
- return nil
- }*/
- func A05(req *apis.ThirdpartRequest) (reply string, err error) {
- req.LReq.Search = req.Params["vin"]
- req.ProviderInfo.ThirdpartApiRouter = consts.A05
- str, err := AdmRequest(req)
- if err != nil {
- return "", err
- }
- if str == "" {
- return "", errors.VendorError
- }
- //respData := make(map[string]string)
- //utils.Convertion(respData, str)
- return str, nil
- }
|