diff --git a/model/location_request.go b/model/location_request.go index 0d55d1d..4533db7 100644 --- a/model/location_request.go +++ b/model/location_request.go @@ -9,15 +9,15 @@ type LocationRequestPayload struct { // ProvinceRequestPayload ... type ProvinceRequestPayload struct { - Codes []int `json:"Codes"` + Codes []int `json:"codes"` } // DistrictRequestPayload ... type DistrictRequestPayload struct { - Codes []int `json:"Codes"` + Codes []int `json:"codes"` } // WardRequestPayload ... type WardRequestPayload struct { - Codes []int `json:"Codes"` + Codes []int `json:"codes"` } diff --git a/model/location_response.go b/model/location_response.go index 49e3cbd..484d89e 100644 --- a/model/location_response.go +++ b/model/location_response.go @@ -29,15 +29,15 @@ type LocationWard struct { // LocationProvinceResponse ... type LocationProvinceResponse struct { - Province []LocationProvince `json:"province"` + Provinces []LocationProvince `json:"provinces"` } // LocationDistrictResponse ... type LocationDistrictResponse struct { - District []LocationDistrict `json:"district"` + Districts []LocationDistrict `json:"districts"` } // LocationWardResponse ... type LocationWardResponse struct { - Ward []LocationWard `json:"ward"` + Wards []LocationWard `json:"wards"` } diff --git a/subject/location.go b/subject/location.go index 22141ad..b19a59b 100644 --- a/subject/location.go +++ b/subject/location.go @@ -13,7 +13,7 @@ var Location = struct { GetWardsByCodes string }{ GetLocationByCode: getLocationValue("get_location_warehouse"), - GetProvincesByCodes: getLocationValue("get_provinces_warehouse"), - GetDistrictsByCodes: getLocationValue("get_districts_warehouse"), - GetWardsByCodes: getLocationValue("get_wards_warehouse"), + GetProvincesByCodes: getLocationValue("get_provinces_by_codes"), + GetDistrictsByCodes: getLocationValue("get_districts_by_codes"), + GetWardsByCodes: getLocationValue("get_wards_by_codes"), }