gobl 0.17.0 → 0.19.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (101) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -1
  3. data/data/regimes/ca.json +77 -0
  4. data/data/regimes/co.json +2850 -2777
  5. data/data/regimes/de.json +182 -0
  6. data/data/regimes/es.json +1241 -1218
  7. data/data/regimes/fr.json +125 -10
  8. data/data/regimes/gb.json +71 -1
  9. data/data/regimes/it.json +1772 -1701
  10. data/data/regimes/mx.json +128 -10
  11. data/data/regimes/nl.json +71 -1
  12. data/data/regimes/pl.json +398 -0
  13. data/data/regimes/pt.json +245 -185
  14. data/data/regimes/us.json +55 -2
  15. data/lib/generated/gobl/bill/charge.rb +1 -1
  16. data/lib/generated/gobl/bill/correction_options.rb +11 -20
  17. data/lib/generated/gobl/bill/delivery.rb +6 -1
  18. data/lib/generated/gobl/bill/discount.rb +1 -1
  19. data/lib/generated/gobl/bill/document_reference.rb +1 -1
  20. data/lib/generated/gobl/bill/invoice.rb +1 -1
  21. data/lib/generated/gobl/bill/line.rb +1 -1
  22. data/lib/generated/gobl/bill/line_charge.rb +1 -1
  23. data/lib/generated/gobl/bill/line_discount.rb +1 -1
  24. data/lib/generated/gobl/bill/ordering.rb +6 -1
  25. data/lib/generated/gobl/bill/outlay.rb +4 -4
  26. data/lib/generated/gobl/bill/payment.rb +1 -1
  27. data/lib/generated/gobl/bill/preceding.rb +11 -11
  28. data/lib/generated/gobl/bill/tax.rb +1 -1
  29. data/lib/generated/gobl/bill/totals.rb +6 -1
  30. data/lib/generated/gobl/cal/date.rb +1 -1
  31. data/lib/generated/gobl/cal/date_time.rb +1 -1
  32. data/lib/generated/gobl/cal/period.rb +1 -1
  33. data/lib/generated/gobl/cbc/code.rb +1 -1
  34. data/lib/generated/gobl/cbc/code_map.rb +1 -1
  35. data/lib/generated/gobl/cbc/key.rb +1 -1
  36. data/lib/generated/gobl/cbc/meta.rb +1 -1
  37. data/lib/generated/gobl/cbc/note.rb +1 -1
  38. data/lib/generated/gobl/currency/code.rb +1 -1
  39. data/lib/generated/gobl/currency/exchange_rate.rb +1 -1
  40. data/lib/generated/gobl/dsig/digest.rb +1 -1
  41. data/lib/generated/gobl/dsig/signature.rb +1 -1
  42. data/lib/generated/gobl/envelope.rb +1 -1
  43. data/lib/generated/gobl/head/header.rb +1 -1
  44. data/lib/generated/gobl/head/stamp.rb +1 -1
  45. data/lib/generated/gobl/i18n/string.rb +1 -1
  46. data/lib/generated/gobl/l10n/code.rb +1 -1
  47. data/lib/generated/gobl/l10n/country_code.rb +1 -1
  48. data/lib/generated/gobl/note/message.rb +1 -1
  49. data/lib/generated/gobl/org/address.rb +1 -1
  50. data/lib/generated/gobl/org/coordinates.rb +1 -1
  51. data/lib/generated/gobl/org/email.rb +1 -1
  52. data/lib/generated/gobl/org/identity.rb +6 -1
  53. data/lib/generated/gobl/org/image.rb +6 -1
  54. data/lib/generated/gobl/org/inbox.rb +1 -1
  55. data/lib/generated/gobl/org/item.rb +6 -6
  56. data/lib/generated/gobl/org/name.rb +1 -1
  57. data/lib/generated/gobl/org/party.rb +3 -3
  58. data/lib/generated/gobl/org/person.rb +1 -1
  59. data/lib/generated/gobl/org/registration.rb +1 -1
  60. data/lib/generated/gobl/org/telephone.rb +1 -1
  61. data/lib/generated/gobl/org/unit.rb +26 -10
  62. data/lib/generated/gobl/org/website.rb +1 -1
  63. data/lib/generated/gobl/pay/advance.rb +19 -4
  64. data/lib/generated/gobl/pay/card.rb +1 -1
  65. data/lib/generated/gobl/pay/credit_transfer.rb +1 -1
  66. data/lib/generated/gobl/pay/direct_debit.rb +1 -1
  67. data/lib/generated/gobl/pay/due_date.rb +1 -1
  68. data/lib/generated/gobl/pay/instructions.rb +1 -1
  69. data/lib/generated/gobl/pay/online.rb +1 -1
  70. data/lib/generated/gobl/pay/terms.rb +1 -1
  71. data/lib/generated/gobl/regimes/mx/food_vouchers.rb +41 -0
  72. data/lib/generated/gobl/regimes/mx/food_vouchers_employee.rb +42 -0
  73. data/lib/generated/gobl/regimes/mx/food_vouchers_line.rb +42 -0
  74. data/lib/generated/gobl/regimes/mx/fuel_account_balance.rb +41 -0
  75. data/lib/generated/gobl/regimes/mx/fuel_account_item.rb +42 -0
  76. data/lib/generated/gobl/regimes/mx/fuel_account_line.rb +73 -0
  77. data/lib/generated/gobl/regimes/mx/fuel_account_tax.rb +37 -0
  78. data/lib/generated/gobl/schema/object.rb +1 -1
  79. data/lib/generated/gobl/tax/category.rb +11 -3
  80. data/lib/generated/gobl/tax/category_total.rb +1 -1
  81. data/lib/generated/gobl/tax/code_definition.rb +1 -1
  82. data/lib/generated/gobl/tax/combo.rb +3 -3
  83. data/lib/generated/gobl/tax/correction_definition.rb +43 -0
  84. data/lib/generated/gobl/tax/ext_map.rb +15 -0
  85. data/lib/generated/gobl/tax/identity.rb +1 -1
  86. data/lib/generated/gobl/tax/key_definition.rb +8 -2
  87. data/lib/generated/gobl/tax/rate.rb +1 -1
  88. data/lib/generated/gobl/tax/rate_total.rb +3 -3
  89. data/lib/generated/gobl/tax/rate_total_surcharge.rb +1 -1
  90. data/lib/generated/gobl/tax/rate_value.rb +1 -1
  91. data/lib/generated/gobl/tax/regime.rb +18 -14
  92. data/lib/generated/gobl/tax/scenario.rb +1 -1
  93. data/lib/generated/gobl/tax/scenario_set.rb +1 -1
  94. data/lib/generated/gobl/tax/set.rb +1 -1
  95. data/lib/generated/gobl/tax/source.rb +1 -1
  96. data/lib/generated/gobl/tax/total.rb +1 -1
  97. data/lib/generated/gobl/tax/zone.rb +1 -1
  98. data/lib/generated/gobl/uuid/uuid.rb +1 -1
  99. data/lib/gobl/version.rb +1 -1
  100. metadata +15 -4
  101. data/lib/generated/gobl/tax/preceding_definitions.rb +0 -37
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -18,6 +18,11 @@ module GOBL
18
18
  # @return [String]
19
19
  property :code, String
20
20
 
21
+ # @!attribute [r] identities
22
+ # Any additional Codes, IDs, SKUs, or other regional or custom identifiers that may be used to identify the order.
23
+ # @return [Array<GOBL::Org::Identity>]
24
+ property :identities, [GOBL::Org::Identity]
25
+
21
26
  # @!attribute [r] period
22
27
  # Period of time that the invoice document refers to often used in addition to the details provided in the individual line items.
23
28
  # @return [GOBL::Cal::Period]
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -38,11 +38,11 @@ module GOBL
38
38
  # @return [String]
39
39
  property :series, String
40
40
 
41
- # @!attribute [r] desc
41
+ # @!attribute [r] description
42
42
  # Details on what the outlay was.
43
43
  # @return [String]
44
- property :desc, String
45
- validates_presence_of :desc
44
+ property :description, String
45
+ validates_presence_of :description
46
46
 
47
47
  # @!attribute [r] supplier
48
48
  # Who was the supplier of the outlay
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -18,6 +18,11 @@ module GOBL
18
18
  # @return [GOBL::UUID::UUID]
19
19
  property :uuid, GOBL::UUID::UUID
20
20
 
21
+ # @!attribute [r] type
22
+ # Type of the preceding document
23
+ # @return [GOBL::CBC::Key]
24
+ property :type, GOBL::CBC::Key
25
+
21
26
  # @!attribute [r] series
22
27
  # Series identification code
23
28
  # @return [String]
@@ -44,21 +49,16 @@ module GOBL
44
49
  # @return [Array<GOBL::Head::Stamp>]
45
50
  property :stamps, [GOBL::Head::Stamp]
46
51
 
47
- # @!attribute [r] corrections
48
- # Tax regime specific keys reflecting why the preceding invoice is being replaced.
49
- # @return [Array<GOBL::CBC::Key>]
50
- property :corrections, [GOBL::CBC::Key]
51
-
52
- # @!attribute [r] correction_method
53
- # Tax regime specific keys reflecting the method used to correct the preceding invoice.
54
- # @return [GOBL::CBC::Key]
55
- property :correction_method, GOBL::CBC::Key
56
-
57
52
  # @!attribute [r] period
58
53
  # Tax period in which the previous invoice had an effect required by some tax regimes and formats.
59
54
  # @return [GOBL::Cal::Period]
60
55
  property :period, GOBL::Cal::Period
61
56
 
57
+ # @!attribute [r] ext
58
+ # Extensions for region specific requirements.
59
+ # @return [GOBL::Tax::ExtMap]
60
+ property :ext, GOBL::Tax::ExtMap
61
+
62
62
  # @!attribute [r] meta
63
63
  # Additional semi-structured data that may be useful in specific regions
64
64
  # @return [GOBL::CBC::Meta]
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -56,6 +56,11 @@ module GOBL
56
56
  property :total_with_tax, GOBL::Num::Amount
57
57
  validates_presence_of :total_with_tax
58
58
 
59
+ # @!attribute [r] rounding
60
+ # Rounding amount to apply to the invoice in case the total and payable amounts don't quite match.
61
+ # @return [GOBL::Num::Amount]
62
+ property :rounding, GOBL::Num::Amount
63
+
59
64
  # @!attribute [r] outlays
60
65
  # Total paid in outlays that need to be reimbursed
61
66
  # @return [GOBL::Num::Amount]
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -23,6 +23,11 @@ module GOBL
23
23
  # @return [String]
24
24
  property :label, String
25
25
 
26
+ # @!attribute [r] key
27
+ # Uniquely classify this identity using a key instead of a code.
28
+ # @return [GOBL::CBC::Key]
29
+ property :key, GOBL::CBC::Key
30
+
26
31
  # @!attribute [r] type
27
32
  # The type of Code being represented and usually specific for a particular context, country, or tax regime, and cannot be used alongside the key.
28
33
  # @return [GOBL::CBC::Code]
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -62,6 +62,11 @@ module GOBL
62
62
  # Digest can be used to ensure the image contained at the URL is the same one as originally intended.
63
63
  # @return [GOBL::DSig::Digest]
64
64
  property :digest, GOBL::DSig::Digest
65
+
66
+ # @!attribute [r] meta
67
+ # Meta contains additional information about the image.
68
+ # @return [GOBL::CBC::Meta]
69
+ property :meta, GOBL::CBC::Meta
65
70
  end
66
71
  end
67
72
  end
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -39,10 +39,10 @@ module GOBL
39
39
  # @return [Array<GOBL::Org::Identity>]
40
40
  property :identities, [GOBL::Org::Identity]
41
41
 
42
- # @!attribute [r] desc
43
- # Detailed description
42
+ # @!attribute [r] description
43
+ # Detailed description of the item.
44
44
  # @return [String]
45
- property :desc, String
45
+ property :description, String
46
46
 
47
47
  # @!attribute [r] currency
48
48
  # Currency used for the item's price.
@@ -67,8 +67,8 @@ module GOBL
67
67
 
68
68
  # @!attribute [r] ext
69
69
  # Extension code map for any additional regime specific codes that may be required.
70
- # @return [GOBL::CBC::CodeMap]
71
- property :ext, GOBL::CBC::CodeMap
70
+ # @return [GOBL::Tax::ExtMap]
71
+ property :ext, GOBL::Tax::ExtMap
72
72
 
73
73
  # @!attribute [r] meta
74
74
  # Additional meta information that may be useful
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -81,8 +81,8 @@ module GOBL
81
81
 
82
82
  # @!attribute [r] ext
83
83
  # Extension code map for any additional regime specific codes that may be required.
84
- # @return [GOBL::CBC::CodeMap]
85
- property :ext, GOBL::CBC::CodeMap
84
+ # @return [GOBL::Tax::ExtMap]
85
+ property :ext, GOBL::Tax::ExtMap
86
86
 
87
87
  # @!attribute [r] meta
88
88
  # Any additional semi-structured information that does not fit into the rest of the party.
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,12 +3,12 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
10
10
  module Org
11
- # Unit describes how the quantity of the product should be interpreted.
11
+ # Unit describes how the quantity of the product should be interpreted either using a GOBL key, or UN/ECE code.
12
12
  class Unit < String
13
13
  # The Schema ID of the GOBL Unit structure
14
14
  SCHEMA_ID = 'https://gobl.org/draft-0/org/unit'
@@ -16,6 +16,7 @@ module GOBL
16
16
  include GOBL::Enum
17
17
 
18
18
  ENUM = {
19
+ 'mg' => 'Milligrams',
19
20
  'g' => 'Metric grams',
20
21
  'kg' => 'Metric kilograms',
21
22
  't' => 'Metric tons',
@@ -27,19 +28,32 @@ module GOBL
27
28
  'ft' => 'Feet',
28
29
  'm2' => 'Square metres',
29
30
  'm3' => 'Cubic metres',
31
+ 'ml' => 'Millilitres',
30
32
  'cl' => 'Centilitres',
31
33
  'l' => 'Litres',
32
34
  'w' => 'Watts',
33
35
  'kw' => 'Kilowatts',
34
36
  'kwh' => 'Kilowatt Hours',
37
+ 'rate' => 'A unit of quantity expressed as a rate for usage of a facility or service.',
38
+ 'mon' => 'Unit of time equal to 1/12 of a year of 365,25 days.',
35
39
  'day' => 'Days',
36
40
  's' => 'Seconds',
37
41
  'h' => 'Hours',
38
42
  'min' => 'Minutes',
39
- 'piece' => 'Pieces',
40
- 'item' => 'Items',
41
- 'service' => 'Service Units',
42
- 'activity' => 'Activity',
43
+ 'piece' => 'A unit of count defining the number of pieces (piece: a single item, article or exemplar).',
44
+ 'item' => ' A unit of count defining the number of items regarded as separate units.',
45
+ 'pair' => 'A unit of count defining the number of pairs (pair: item described by twos).s).',
46
+ 'dozen' => 'A unit of count defining the number of units in multiples of 12.',
47
+ 'assortment' => 'A unit of count defining the number of assortments (assortment: a collection of items or components of a single product packaged together).',
48
+ 'service' => 'A unit of count defining the number of service units (service unit: defined period / property / facility / utility of supply).',
49
+ 'job' => 'A unit of count defining the number of jobs.',
50
+ 'activity' => 'A unit of count defining the number of activities (activity: a unit of work or action).',
51
+ 'trip' => 'A unit of count defining the number of trips (trip: a journey to a place and back again).',
52
+ 'group' => 'A unit of count defining the number of groups (group: set of items classified together).',
53
+ 'outfit' => 'A unit of count defining the number of outfits (outfit: a complete set of equipment / materials / objects used for a specific purpose).',
54
+ 'kit' => 'A unit of count defining the number of kits (kit: tub, barrel or pail).',
55
+ 'basebox' => 'A unit of area of 112 sheets of tin mil products (tin plate, tin free steel or black plate) 14 by 20 inches, or 31,360 square inches.',
56
+ 'pk' => 'A unit of count defining the number of items per bulk pack.',
43
57
  'bag' => 'Bags',
44
58
  'box' => 'Boxes',
45
59
  'bin' => 'Bins',
@@ -48,25 +62,27 @@ module GOBL
48
62
  'case' => 'Cases',
49
63
  'tray' => 'Trays',
50
64
  'portion' => 'Portions',
51
- 'dozen' => 'Dozens',
65
+ 'set' => 'A unit of count defining the number of sets (set: a number of objects grouped together).',
52
66
  'roll' => 'Rolls',
53
67
  'carton' => 'Cartons',
54
68
  'cylinder' => 'Cylinders',
55
69
  'barrel' => 'Barrels',
56
- 'jerrican' => 'Jerricans',
70
+ 'jerrican' => 'Jerrican, cylindrical',
57
71
  'carboy' => 'Carboys',
58
72
  'demijohn' => 'Demijohn',
59
73
  'bottle' => 'Bottles',
60
74
  '6pack' => 'Six Packs',
61
75
  'canister' => 'Canisters',
62
- 'pkg' => 'Packages',
76
+ 'pkg' => 'Standard packaging unit.',
63
77
  'bunch' => 'Bunches',
64
78
  'tetrabrik' => 'Tetra-Briks',
65
79
  'pallet' => 'Pallets',
66
80
  'reel' => 'Reels',
67
81
  'sack' => 'Sacks',
68
82
  'sheet' => 'Sheets',
69
- 'envelope' => 'Envelopes'
83
+ 'envelope' => 'Envelopes',
84
+ 'lot' => 'Lot',
85
+ 'unit' => 'A type of package composed of a single item or object, not otherwise specified as a unit of transport equipment.'
70
86
  }.freeze
71
87
 
72
88
  def strict_enum?
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -3,7 +3,7 @@
3
3
  ##
4
4
  ## DO NOT EDIT - This file was generated automatically.
5
5
  ##
6
- ## Generated with GOBL v0.55.0
6
+ ## Generated with GOBL v0.67.0
7
7
  ##
8
8
 
9
9
  module GOBL
@@ -54,11 +54,11 @@ module GOBL
54
54
  # @return [Boolean]
55
55
  property :grant, Boolean
56
56
 
57
- # @!attribute [r] desc
57
+ # @!attribute [r] description
58
58
  # Details about the advance.
59
59
  # @return [String]
60
- property :desc, String
61
- validates_presence_of :desc
60
+ property :description, String
61
+ validates_presence_of :description
62
62
 
63
63
  # @!attribute [r] percent
64
64
  # How much as a percentage of the total with tax was paid
@@ -75,6 +75,21 @@ module GOBL
75
75
  # If different from the parent document's base currency.
76
76
  # @return [GOBL::Currency::Code]
77
77
  property :currency, GOBL::Currency::Code
78
+
79
+ # @!attribute [r] card
80
+ # Details of the payment that was made via a credit or debit card.
81
+ # @return [Card]
82
+ property :card, Card
83
+
84
+ # @!attribute [r] credit_transfer
85
+ # Details about how the payment was made by credit (bank) transfer.
86
+ # @return [CreditTransfer]
87
+ property :credit_transfer, CreditTransfer
88
+
89
+ # @!attribute [r] meta
90
+ # Additional details useful for the parties involved.
91
+ # @return [GOBL::CBC::Meta]
92
+ property :meta, GOBL::CBC::Meta
78
93
  end
79
94
  end
80
95
  end