diff --git a/src/components/Common/CommonBillEvent.js b/src/components/Common/CommonBillEvent.js index ded9044..13fc159 100644 --- a/src/components/Common/CommonBillEvent.js +++ b/src/components/Common/CommonBillEvent.js @@ -2837,20 +2837,18 @@ export default (ChildComponent) => { this.handleSearchData1(handleType); return; } + const tipLast = commonFunc.showLocalMessage(this.props, 'tipLast', '当前已经是最后一条'); + const tipFirst = commonFunc.showLocalMessage(this.props, 'tipFirst', '当前已经是第一条'); const { currentPane, token } = app; const { pages, sFilterOrderBy, bFilter, sListFormmasterId, currentIndex, } = currentPane; + console.log('22page2222s2', pages); let currentPosition = currentIndexFlag ? currentPageNo : commonUtils.isEmptyObject(pages) ? 1 : (((pages.current - 1) * commonConfig.pageSize) + Number.parseInt(currentIndex, 10)) + 1; if (currentIndex === undefined) { currentPosition = 1; } - // if (handleType === 'first') { - // currentPosition = 1; - // } else if (handleType === 'end') { - // currentPosition = pages.total; - // } if (!commonUtils.isNum(currentPosition)) { // 如果是列表直接点增加,就跳到第一条去 currentPosition = 1; } @@ -2862,12 +2860,12 @@ export default (ChildComponent) => { if ("next".includes(handleType)) { currentPosition = index + 1; if(currentPosition > sBillIdsArray.length - 1 ){ - message.warn('当前已经是最后一条'); + message.warn(tipLast); return ; } } else if ("up".includes(handleType)) { if(index === 0){ - message.warn('当前已经是第一条!'); + message.warn(tipFirst); return ; } currentPosition = index - 1; @@ -2885,8 +2883,18 @@ export default (ChildComponent) => { } /* 如果是第一次请求 */ if(!bExist) { + const bFromList = commonUtils.isEmptyObject(pages) ? true: false; + if(bFromList) { + if(handleType ==='next' || handleType ==='end') { + message.warn(tipLast); + return ; + }else { + message.warn(tipFirst); + return ; + } + } const value = { - sClientType: '1', sFilterOrderBy, bFilter, sListFormmasterId, currentPosition, handleType, iCountSum: pages.total, + sClientType: '1', sFilterOrderBy, bFilter, sListFormmasterId, currentPosition, handleType, iCountSum: pages?.total, sUpId: masterData?.sId, sParentModelId :sSrcModelsId, }; const url = `${commonConfig.server_host}business/getBusinessDataByIndex?sModelsId=${sModelsId}`; diff --git a/src/components/Common/CommonElementEvent.js b/src/components/Common/CommonElementEvent.js index c020dd9..b97d0c8 100644 --- a/src/components/Common/CommonElementEvent.js +++ b/src/components/Common/CommonElementEvent.js @@ -3020,14 +3020,15 @@ export default (ChildComponent) => { const { pages, sFilterOrderBy, bFilter, sListFormmasterId, currentIndex, } = currentPane; - + const tipLast = commonFunc.showLocalMessage(this.props, 'tipLast', '当前已经是最后一条'); + const tipFirst = commonFunc.showLocalMessage(this.props, 'tipFirst', '当前已经是第一条'); let currentPosition = currentIndexFlag ? currentPageNo : commonUtils.isEmptyObject(pages) ? 1 : (((pages.current - 1) * commonConfig.pageSize) + Number.parseInt(currentIndex, 10)) + 1; if (commonUtils.isEmptyObject(pages) || commonUtils.isEmptyNumber(pages.total)) { if (handleType === 'next' || handleType === 'end') { - message.warning('当前已是最后一条数据'); + message.warn(tipLast); return; } else { - message.warning('当前已是第一条数据'); + message.warn(tipFirst); return; } } diff --git a/src/components/Common/CommonNewBillEvent.js b/src/components/Common/CommonNewBillEvent.js index 11da830..31495da 100644 --- a/src/components/Common/CommonNewBillEvent.js +++ b/src/components/Common/CommonNewBillEvent.js @@ -1941,6 +1941,8 @@ export default (ChildComponent) => { let { sBillIdsArray = []} = this.props; let { currentId } = this.props; const { currentPane, token } = app; + const tipLast = commonFunc.showLocalMessage(this.props, 'tipLast', '当前已经是最后一条'); + const tipFirst = commonFunc.showLocalMessage(this.props, 'tipFirst', '当前已经是第一条'); let { pages, sFilterOrderBy, bFilter, sListFormmasterId, currentIndex, fromKey, } = currentPane; @@ -1968,12 +1970,12 @@ export default (ChildComponent) => { if ("next".includes(handleType)) { currentPosition = index + 1; if(currentPosition > sBillIdsArray.length - 1 ){ - message.warn('当前已经是最后一条'); + message.warn(tipLast); return ; } } else if ("up".includes(handleType)) { if(index === 0){ - message.warn('当前已经是第一条!'); + message.warn(tipFirst); return ; } currentPosition = index - 1; @@ -1991,6 +1993,16 @@ export default (ChildComponent) => { } /* 如果是第一次请求 */ if(!bExist) { + const bFromList = commonUtils.isEmptyObject(pages) ? true: false; + if(bFromList) { + if(handleType ==='next' || handleType ==='end') { + message.warn(tipLast); + return ; + }else { + message.warn(tipFirst); + return ; + } + } const value = { sClientType: '1', sFilterOrderBy, bFilter, sListFormmasterId, currentPosition, handleType, iCountSum: pages.total, sUpId: masterData?.sId, sParentModelId :sSrcModelsId, diff --git a/src/components/Common/CommonSubBillEvent.js b/src/components/Common/CommonSubBillEvent.js index 4844dc1..7e93d12 100644 --- a/src/components/Common/CommonSubBillEvent.js +++ b/src/components/Common/CommonSubBillEvent.js @@ -2820,6 +2820,8 @@ export default (ChildComponent) => { let { sBillIdsArray = []} = this.props; let { currentId } = this.props; const { currentPane, token } = app; + const tipLast = commonFunc.showLocalMessage(this.props, 'tipLast', '当前已经是最后一条'); + const tipFirst = commonFunc.showLocalMessage(this.props, 'tipFirst', '当前已经是第一条'); const { pages, sFilterOrderBy, bFilter, sListFormmasterId, currentIndex, } = currentPane; @@ -2843,12 +2845,12 @@ export default (ChildComponent) => { if ("next".includes(handleType)) { currentPosition = index + 1; if(currentPosition > sBillIdsArray.length - 1 ){ - message.warn('当前已经是最后一条'); + message.warn(tipLast); return ; } } else if ("up".includes(handleType)) { if(index === 0){ - message.warn('当前已经是第一条!'); + message.warn(tipFirst); return ; } currentPosition = index - 1; @@ -2866,6 +2868,16 @@ export default (ChildComponent) => { } /* 如果是第一次请求 */ if(!bExist) { + const bFromList = commonUtils.isEmptyObject(pages) ? true: false; + if(bFromList) { + if(handleType ==='next' || handleType ==='end') { + message.warn(tipLast); + return ; + }else { + message.warn(tipFirst); + return ; + } + } const value = { sClientType: '1', sFilterOrderBy, bFilter, sListFormmasterId, currentPosition, handleType, iCountSum: pages.total, sUpId: masterData?.sId, sParentModelId :sSrcModelsId, diff --git a/src/components/QuickQuote/index.less b/src/components/QuickQuote/index.less index 1ce5cae..79d6e5b 100644 --- a/src/components/QuickQuote/index.less +++ b/src/components/QuickQuote/index.less @@ -17,6 +17,11 @@ .ant-col-23 { display: flex !important; } + + .ant-divider { + margin: 0 0 5px 0; + height: 26px; + } } .back { @@ -62,10 +67,6 @@ font-size: 16px; } - .ant-divider { - margin: 0 0 5px 0; - height: 26px; - } } } @@ -332,7 +333,7 @@ .btns { position: absolute; - top: -50px; + top: -40px; right: 10px; height: 40px; min-width: 40px; @@ -366,6 +367,7 @@ .viewStyle { margin-top: 0 !important; } + .ant-col-4 .ant-col-7 { flex-basis: 50px !important; }