From 531f8e2bafc320c17b1021035c495f474b4bae6b Mon Sep 17 00:00:00 2001 From: "n.nakhostin" Date: Mon, 25 Aug 2025 13:23:47 +0330 Subject: [PATCH] Enhance TenderResponse Structure with TenderID Field - Added a new field 'TenderID' to the TenderResponse structure, improving the data model for tender management. - Updated the ToTenderResponse method to include the TenderID in the response, ensuring consistency in API outputs. - This enhancement aligns with the ongoing improvements to the tender management system's data handling capabilities. --- internal/tender/form.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/tender/form.go b/internal/tender/form.go index 14f7e77..476c2c6 100644 --- a/internal/tender/form.go +++ b/internal/tender/form.go @@ -47,6 +47,7 @@ type TenderResponse struct { CountryCode string `json:"country_code"` BuyerOrganization *OrganizationResponse `json:"buyer_organization"` Status TenderStatus `json:"status"` + TenderID string `json:"tender_id"` } type OrganizationResponse struct { @@ -70,10 +71,11 @@ func (t *Tender) ToTenderResponse() *TenderResponse { TenderDeadline: t.TenderDeadline, SubmissionDeadline: t.SubmissionDeadline, ApplicationDeadline: t.ApplicationDeadline, - SubmissionURL: t.SubmissionURL, CountryCode: t.CountryCode, + SubmissionURL: t.SubmissionURL, BuyerOrganization: &OrganizationResponse{Name: t.BuyerOrganization.Name}, Status: t.Status, + TenderID: t.TenderID, } return response