18034727885
2026-09-18 1328a7b0b90825b1fd63bca8f7675e52df8b151d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
package com.igo.user.utils
 
import android.content.Context
import com.igo.user.R
import com.igo.user.extension.extClearInvalidZero
 
fun Double?.showMoney(context: Context): String {
    return context.getString(R.string.money_is, this).replace(",", ".").extClearInvalidZero()
}
 
fun Double.showMoney(context: Context): String {
    return context.getString(R.string.money_is, this).replace(",", ".").extClearInvalidZero()
}
 
fun String?.showMoney(context: Context): String {
    return context.getString(R.string.money_is, (this?.toDoubleOrNull()) ?: 0.0).replace(",", ".")
        .extClearInvalidZero()
}