Commit 7209c814217b96361c42b0fc80e8bb37cd1d7307

Authored by Min
1 parent cba441d0

1.处理MES班组产量上报,手填报工数量,超过五位数,点击页面会自动将五位数变成四位

src/components/Common/CommonComponent/index.js
... ... @@ -1516,7 +1516,8 @@ export default class CommonComponent extends Component {
1516 1516 this.handleSelectOptionEvent(value);
1517 1517 }, /* 数据改变回带到父组件 */
1518 1518 parser: (oldValue) => {
1519   - return oldValue;
  1519 + const value = this.handleCheckNumberInnerInput(oldValue);
  1520 + return value?.replace(/\$\s?|(,*)/g, '');
1520 1521 },
1521 1522 formatter: (value) => {
1522 1523 if (value === '' || value === undefined || value === null || location.pathname.includes("indexPad")) {
... ... @@ -2070,7 +2071,7 @@ export default class CommonComponent extends Component {
2070 2071 const { sDateFormat, sFieldValidation } = this.props.showConfig;
2071 2072 if (sDateFormat !== 'decimalPoint' || sFieldValidation === undefined) return value;
2072 2073  
2073   - const [length1, length2] = sFieldValidation.split(',');
  2074 + const [length1, length2] = sFieldValidation?.split(',');
2074 2075  
2075 2076 let newValue = value;
2076 2077 if (length2 !== undefined) {
... ...