|
|
@ -252,17 +252,16 @@ public class MOStockINActivity extends AppCompatActivity { |
|
|
|
@Override |
|
|
|
public void onClick(View v) { |
|
|
|
try { |
|
|
|
if (et_quantity.getText() == null || et_quantity.getText().toString().trim().equals("")) { |
|
|
|
if (et_quantity.getText() == null || et_quantity.getText().toString().trim().equals("") || new BigDecimal(et_quantity.getText().toString().trim()).equals(BigDecimal.ZERO)) { |
|
|
|
HelpUtil.SetMsg(tvMsg, Color.RED, "请输入出库数量"); |
|
|
|
return; |
|
|
|
} |
|
|
|
new Thread(new Runnable() { |
|
|
|
@Override |
|
|
|
public void run() { |
|
|
|
confirmClick(); |
|
|
|
} |
|
|
|
}).start(); |
|
|
|
|
|
|
|
if (new BigDecimal(et_quantity.getText().toString().trim()).equals(BigDecimal.ONE)) { |
|
|
|
HelpUtil.SetMsg(tvMsg, Color.RED, "数量不能为1"); |
|
|
|
et_quantity.requestFocus(); |
|
|
|
return; |
|
|
|
} |
|
|
|
confirmClick(); |
|
|
|
|
|
|
|
} catch (NumberFormatException ex) { |
|
|
|
HelpUtil.SetMsg(tvMsg, Color.RED, ex.getMessage()); |
|
|
|