|  |  |  | 
|---|
|  |  |  | * @param type            1:买多2:卖空 | 
|---|
|  |  |  | * @return | 
|---|
|  |  |  | */ | 
|---|
|  |  |  | public static BigDecimal getForceSetPrice(BigDecimal bondAmount, BigDecimal openPrice, BigDecimal symbolSkuNumber, BigDecimal lotNumber, | 
|---|
|  |  |  | public static BigDecimal getForceSetPrice(BigDecimal bondAmount, BigDecimal openPrice, int symbolSkuNumber, BigDecimal lotNumber, | 
|---|
|  |  |  | int type, MemberEntity member) { | 
|---|
|  |  |  | CacheSettingUtils cacheSettingUtils = SpringContextHolder.getBean(CacheSettingUtils.class); | 
|---|
|  |  |  | PlatformTradeSettingEntity tradeSetting = cacheSettingUtils.getTradeSetting(); | 
|---|
|  |  |  | BigDecimal forcePrice = BigDecimal.ZERO; | 
|---|
|  |  |  | BigDecimal money = bondAmount.divide(symbolSkuNumber.multiply(lotNumber), 8, BigDecimal.ROUND_DOWN); | 
|---|
|  |  |  | BigDecimal money = bondAmount.divide(new BigDecimal(symbolSkuNumber).multiply(lotNumber), 8, BigDecimal.ROUND_DOWN); | 
|---|
|  |  |  | //卖空 | 
|---|
|  |  |  | if (type == 2) { | 
|---|
|  |  |  | forcePrice = money.add(openPrice); | 
|---|