Update Latitude Longitude

This commit is contained in:
aditya.siregar 2024-08-15 23:01:25 +07:00
parent 203059918b
commit 8b4a89d3c7
5 changed files with 6 additions and 8 deletions

View File

@ -29,8 +29,6 @@ type Site struct {
Longitude *float64 `json:"longitude"` Longitude *float64 `json:"longitude"`
Region string `json:"region"` Region string `json:"region"`
Regency string `json:"regency"` Regency string `json:"regency"`
Lat float64 `json:"lat"`
Long float64 `json:"long"`
Distance float64 `gorm:"-"` Distance float64 `gorm:"-"`
} }

View File

@ -287,8 +287,8 @@ func (h *Handler) toSiteResponse(resp *entity.Site) response.Site {
CreatedAt: resp.CreatedAt.Format(time.RFC3339), CreatedAt: resp.CreatedAt.Format(time.RFC3339),
UpdatedAt: resp.UpdatedAt.Format(time.RFC3339), UpdatedAt: resp.UpdatedAt.Format(time.RFC3339),
Products: h.toProductResponseList(resp.Products), Products: h.toProductResponseList(resp.Products),
Lat: resp.Lat, Lat: *resp.Latitude,
Long: resp.Long, Long: *resp.Longitude,
} }
} }

View File

@ -62,8 +62,8 @@ func (r *Site) ToEntity(createdBy int64) *entity.Site {
Products: products, Products: products,
Region: r.Region, Region: r.Region,
Regency: r.Regency, Regency: r.Regency,
Lat: r.Lat, Latitude: &r.Lat,
Long: r.Long, Longitude: &r.Long,
} }
} }

View File

@ -16,7 +16,7 @@ spec:
serviceAccountName: custom-serviceaccount serviceAccountName: custom-serviceaccount
containers: containers:
- name: furtuna-backend - name: furtuna-backend
image: registry.gitlab.com/altru.id/furtuna/furtuna-backend:<VERSION> image: registry.gitlab.com/altru.id/furtuna/furtuna-backend:f2029ab5-dev
ports: ports:
- containerPort: 3300 - containerPort: 3300
volumeMounts: volumeMounts:

View File

@ -9,7 +9,7 @@ metadata:
nginx.ingress.kubernetes.io/ingress-class: "nginx" nginx.ingress.kubernetes.io/ingress-class: "nginx"
nginx.ingress.kubernetes.io/enable-cors: "true" nginx.ingress.kubernetes.io/enable-cors: "true"
nginx.ingress.kubernetes.io/cors-allow-origin: "*" nginx.ingress.kubernetes.io/cors-allow-origin: "*"
nginx.ingress.kubernetes.io/cors-allow-methods: "GET, POST, PUT, OPTIONS" nginx.ingress.kubernetes.io/cors-allow-methods: "GET, POST, PUT, DELETE, OPTIONS"
nginx.ingress.kubernetes.io/cors-allow-headers: "Content-Type, Authorization, x-access-token" nginx.ingress.kubernetes.io/cors-allow-headers: "Content-Type, Authorization, x-access-token"
nginx.ingress.kubernetes.io/cors-allow-credentials: "true" nginx.ingress.kubernetes.io/cors-allow-credentials: "true"
spec: spec: