Implemented phase 1 for the POC prototype in the Website service.
This commit is contained in:
1 parent
6d7ab4bcba
commit
ea89ea892a
37 files changed
+4173
-43
No files matched your search
@@ -0,0 +1,14 @@
|
||||
import Foundation
|
||||
|
||||
extension Int {
|
||||
|
||||
// MARK: Computed
|
||||
|
||||
/// The amount of euro cents as a price: whole euros bare (`€240`), anything else to the cent (`€12.50`).
|
||||
var euros: String {
|
||||
isMultiple(of: 100)
|
||||
? "€\(self / 100)"
|
||||
: String(format: "€%d.%02d", self / 100, self % 100)
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user