Skip to content

Commit

Permalink
Add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefanos Papadakis committed Aug 28, 2022
1 parent 2c96e63 commit 362f5d9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/models/expense_classification.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ type InvoicesExpensesClassificationDetails struct {
ExpensesClassificationDetailData []ExpensesClassificationType `xml:"ExpensesClassificationDetailData"`
}

// MarshalXML transforms an ExpensesClassificationType to expensesClassificationType and serializes it in order to
// include the `ecls` namespace for every field.
func (classification ExpensesClassificationType) MarshalXML(enc *xml.Encoder, start xml.StartElement) error {
type expensesClassificationType struct {
ClassificationType string `xml:"ecls:classificationType"`
Expand Down
2 changes: 2 additions & 0 deletions pkg/models/income_classification.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ type InvoicesIncomeClassificationDetails struct {
IncomeClassificationDetailData []IncomeClassificationType `xml:"incomeClassificationDetailData"`
}

// MarshalXML transforms an IncomeClassificationType to incomeClassificationType and serializes it in order to include
// the `icls` namespace for every field.
func (classification IncomeClassificationType) MarshalXML(enc *xml.Encoder, start xml.StartElement) error {
type incomeClassificationType struct {
ClassificationType string `xml:"icls:classificationType"`
Expand Down

0 comments on commit 362f5d9

Please sign in to comment.