|
|
@@ -57,18 +57,23 @@ class SwapsBusinessBuyHallViewHolder(private val activity : AppCompatActivity, p
|
|
|
if (it?.pricemode == "3"){
|
|
|
if (viewModel.quoteDayData.value?.getPrice() == 0.0){
|
|
|
text = NumberUtils.roundNum(it.orderprice?.toDouble()?.plus(it.marketmaxsub?.toDouble() ?: 0.0) ?: 0.0,2)
|
|
|
+ tag = it?.pricemode
|
|
|
}else{
|
|
|
text = NumberUtils.roundNum(viewModel.quoteDayData.value?.getPrice()?.plus(it?.marketmaxsub?.toDouble() ?: 0.0) ?: 0.0,2)
|
|
|
+ tag = it?.pricemode
|
|
|
}
|
|
|
}else{
|
|
|
text = NumberUtils.roundNum(it?.orderprice,2)
|
|
|
+ tag = it?.pricemode
|
|
|
}
|
|
|
|
|
|
|
|
|
}
|
|
|
viewModel.quoteDayData.bindOptional(context){
|
|
|
val accordingText = it?.getPrice()?.plus(data.value?.marketmaxsub?.toDouble() ?: 0.0) ?: 0.0
|
|
|
- text = NumberUtils.roundNum(accordingText,2)
|
|
|
+ if (tag == 3) {
|
|
|
+ text = NumberUtils.roundNum(accordingText, 2)
|
|
|
+ }
|
|
|
if (accordingText.minus(it?.presettle ?: 0.0) > 0.0){
|
|
|
textColorInt = R.color.rma_red_color
|
|
|
}else if (accordingText.minus(it?.presettle ?: 0.0) < 0.0){
|