|
|
@@ -880,7 +880,7 @@ class BusinessHallActivity : BaseActivity<BusinessHallViewModel>() {
|
|
|
maxpickNumber.postValue(buySelldata.orderqty?.toDouble())
|
|
|
if (buySelldata.buyorsell == "0") {//买单是摘卖-用卖方履约保证金比例
|
|
|
// 注意 这里的配置需要从当前市场获取
|
|
|
- marginValue = if (type == "2") {//有仓单的卖履约保证金
|
|
|
+ marginValue = if (type == "1") {//有仓单的卖履约保证金
|
|
|
if(!marketid.isNullOrEmpty() || GlobalDataCollection.instance?.marketConfigMap?.isNotEmpty() == true){
|
|
|
GlobalDataCollection.instance?.marketConfigMap?.get(marketid)?.sellmarginvalue?.toDouble() ?: 0.0
|
|
|
}else{
|
|
|
@@ -962,7 +962,14 @@ class BusinessHallActivity : BaseActivity<BusinessHallViewModel>() {
|
|
|
onThrottleFirstClick {
|
|
|
creatHnstSpotDetailSheetDialog(
|
|
|
"请选择现货仓单",
|
|
|
- viewModel.detailsWarehouseContentDataList.value ?: arrayListOf<HoldLBData>()
|
|
|
+ if (data.wrstandardid != null && data.warehouseid != null && data.wrgoodsname != null) {
|
|
|
+ (viewModel.detailsWarehouseContentDataList.value
|
|
|
+ ?: arrayListOf<HoldLBData>()).filter {
|
|
|
+ it.wrstandardid == data.wrstandardid && it.warehouseid == data.warehouseid && it.wrtypename == data.wrgoodsname
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ viewModel.detailsWarehouseContentDataList.value ?: arrayListOf()
|
|
|
+ }
|
|
|
) {
|
|
|
selectSpotDetailsData.postValue(this)
|
|
|
}
|
|
|
@@ -1257,7 +1264,7 @@ class BusinessHallActivity : BaseActivity<BusinessHallViewModel>() {
|
|
|
return@onThrottleFirstClick
|
|
|
}
|
|
|
}
|
|
|
- if (type == "2") {//仓单贸易
|
|
|
+ if (type == "1") {//仓单贸易
|
|
|
if (buySelldata.buyorsell == "0") {//买单所以是摘卖
|
|
|
viewModel.HdWRDealOrderReq(
|
|
|
marketid = (marketid ?: "0").toInt(),
|
|
|
@@ -1540,7 +1547,14 @@ class BusinessHallActivity : BaseActivity<BusinessHallViewModel>() {
|
|
|
onThrottleFirstClick {
|
|
|
creatHnstSpotDetailSheetDialog(
|
|
|
"请选择现货仓单",
|
|
|
- viewModel.detailsWarehouseContentDataList.value ?: arrayListOf<HoldLBData>()
|
|
|
+ if (data.wrstandardid != null && data.warehouseid != null && data.wrgoodsname != null) {
|
|
|
+ (viewModel.detailsWarehouseContentDataList.value
|
|
|
+ ?: arrayListOf<HoldLBData>()).filter {
|
|
|
+ it.wrstandardid == data.wrstandardid && it.warehouseid == data.warehouseid && it.wrtypename == data.wrgoodsname
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ viewModel.detailsWarehouseContentDataList.value ?: arrayListOf()
|
|
|
+ }
|
|
|
) {
|
|
|
selectSpotDetailsData.postValue(this)
|
|
|
}
|