Browse Source

关闭弹窗的时候失去焦点,隐藏软件盘 2024/8/9

pull/1/head
test 4 months ago
parent
commit
fe40054d40
  1. 1
      src/mycomponents/scan/winComScanBalance.vue
  2. 1
      src/mycomponents/scan/winComScanBalanceLocation.vue
  3. 3
      src/mycomponents/scan/winScanAsnNumber.vue
  4. 5
      src/mycomponents/scan/winScanContainer.vue
  5. 1
      src/mycomponents/scan/winScanItem.vue
  6. 3
      src/mycomponents/scan/winScanJobNumber.vue
  7. 1
      src/mycomponents/scan/winScanLocation.vue
  8. 1
      src/mycomponents/scan/winScanPack.vue
  9. 1
      src/mycomponents/scan/winScanPackAndCont.vue
  10. 1
      src/mycomponents/scan/winScanPackAndLocation.vue
  11. 1
      src/mycomponents/scan/winScanPackAndLocationNoBalance.vue
  12. 1
      src/mycomponents/scan/winScanPackAndPosition.vue
  13. 4
      src/mycomponents/scan/winScanPackLevel.vue
  14. 1
      src/mycomponents/scan/winScanPackage.vue
  15. 5
      src/pages/issue/coms/comScanIssuePack.vue
  16. 33
      src/pages/package/coms/comScanPackagePack.vue
  17. 6
      src/pages/package/record/overPackageRecord.vue
  18. 5
      src/pages/productionReturn/coms/comScanReturnPack.vue
  19. 5
      src/pages/repleinsh/coms/comScanReplishPack.vue
  20. 4
      src/pages/repleinsh/job/repleinshJob.vue
  21. 1
      src/pages/stockUp/coms/comScanStockUpPack.vue

1
src/mycomponents/scan/winComScanBalance.vue

@ -297,6 +297,7 @@ export default {
// this.closeScanPopup() // this.closeScanPopup()
}, },
closeScanPopup() { closeScanPopup() {
this.losefocus();
this.$refs.popup.close() this.$refs.popup.close()
}, },
getfocus() { getfocus() {

1
src/mycomponents/scan/winComScanBalanceLocation.vue

@ -239,6 +239,7 @@ export default {
// this.closeScanPopup() // this.closeScanPopup()
}, },
closeScanPopup() { closeScanPopup() {
this.packLoseFocus()
this.$refs.popup.close() this.$refs.popup.close()
this.$emit('onCloseScanPopup') this.$emit('onCloseScanPopup')
}, },

3
src/mycomponents/scan/winScanAsnNumber.vue

@ -44,6 +44,9 @@ const openScanPopup = () => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
if(scan.value){
scan.value.losefocus()
}
isShow.value = false isShow.value = false
} }
const getfocus = () => { const getfocus = () => {

5
src/mycomponents/scan/winScanContainer.vue

@ -44,6 +44,7 @@ const openScanPopup = () => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
} }
const scanClick = () => { const scanClick = () => {
@ -81,10 +82,14 @@ const callBack = () => {
emit('getContainer', containerInfo.value) emit('getContainer', containerInfo.value)
} }
const getfocus = () => { const getfocus = () => {
if(scan.value) {
scan.value.getfocus() scan.value.getfocus()
}
} }
const losefocus = () => { const losefocus = () => {
if (scan.value) {
scan.value.losefocus() scan.value.losefocus()
}
} }
const showErrorMessage = (message) => { const showErrorMessage = (message) => {
setTimeout((r) => { setTimeout((r) => {

1
src/mycomponents/scan/winScanItem.vue

@ -57,6 +57,7 @@ const openScanPopup = () => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
isShow.value = false isShow.value = false
} }

3
src/mycomponents/scan/winScanJobNumber.vue

@ -46,6 +46,9 @@ const openScanPopup = () => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
if(scan.value){
scan.value.losefocus()
}
isShow.value = false isShow.value = false
} }
const getfocus = () => { const getfocus = () => {

1
src/mycomponents/scan/winScanLocation.vue

@ -57,6 +57,7 @@ const openScanPopupSimulate = (location) => {
comscansimulate.value.clickScanMsg() comscansimulate.value.clickScanMsg()
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
} }
const scanClick = () => { const scanClick = () => {

1
src/mycomponents/scan/winScanPack.vue

@ -61,6 +61,7 @@ const openScanPopup = () => {
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('close', '') emit('close', '')
} }

1
src/mycomponents/scan/winScanPackAndCont.vue

@ -58,6 +58,7 @@ export default {
}, },
closeScanPopup() { closeScanPopup() {
this.losefocus()
this.$refs.popup.close() this.$refs.popup.close()
this.$emit('close', '') this.$emit('close', '')
}, },

1
src/mycomponents/scan/winScanPackAndLocation.vue

@ -178,6 +178,7 @@ const openScanPopupForJobSimulate = (fromLocationCodeParams, fromLocationListPar
}) })
} }
const closeScanPopup = (content) => { const closeScanPopup = (content) => {
packLoseFocus()
show.value = false show.value = false
emit('close', '') emit('close', '')
} }

1
src/mycomponents/scan/winScanPackAndLocationNoBalance.vue

@ -131,6 +131,7 @@ const openScanPopupForJob = (fromLocationCodeParms, fromLocationListParms, jobCo
fromLocationTypeArray.value = getDirectoryItemArray(jobContent.fromLocationTypes) // fromLocationTypeArray.value = getDirectoryItemArray(jobContent.fromLocationTypes) //
} }
const closeScanPopup = (content) => { const closeScanPopup = (content) => {
packLoseFocus()
show.value = false show.value = false
emit('close', '') emit('close', '')
} }

1
src/mycomponents/scan/winScanPackAndPosition.vue

@ -102,6 +102,7 @@ const initData = () => {
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
isShow.value = false isShow.value = false
emit('close', '') emit('close', '')
} }

4
src/mycomponents/scan/winScanPackLevel.vue

@ -25,7 +25,7 @@
</view> </view>
</view> </view>
</view> </view>
</-popup> </u-popup>
<com-message ref="comMessageRef" /> <com-message ref="comMessageRef" />
</view> </view>
</template> </template>
@ -50,6 +50,7 @@
default: 'HPQ' default: 'HPQ'
} }
}) })
const emit = defineEmits(['close'])
const show = ref(false) const show = ref(false)
const priorityList = ref([ const priorityList = ref([
{ {
@ -82,6 +83,7 @@
}, 200) }, 200)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('close', '') emit('close', '')
} }

1
src/mycomponents/scan/winScanPackage.vue

@ -57,6 +57,7 @@ const openScanPopup = () => {
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('close', '') emit('close', '')
} }

5
src/pages/issue/coms/comScanIssuePack.vue

@ -136,6 +136,7 @@ const openScanPopup = (content, jobcontentParams) => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('closeScan') emit('closeScan')
// //
@ -229,11 +230,11 @@ const onScanResult = (result) => {
result.balance = res.data[0] result.balance = res.data[0]
if (result.label.packingNumber != result.balance.packingNumber) { if (result.label.packingNumber != result.balance.packingNumber) {
result.balance.handleQty = Number(result.label.qty) result.balance.qty = Number(result.label.qty)
} }
else else
{ {
result.balance.handleQty = Number(result.balance.qty) result.balance.qty = Number(result.balance.qty)
} }
afterGetBalance(result.label, result.balance, result.package); afterGetBalance(result.label, result.balance, result.package);
} else { } else {

33
src/pages/package/coms/comScanPackagePack.vue

@ -50,6 +50,8 @@ const toLocationCombox = ref()
const comMessageRef = ref() const comMessageRef = ref()
const detailOptions = ref([]) const detailOptions = ref([])
const comscan = ref() const comscan = ref()
const scanPopup = ref(null)
const balanceSelect = ref(null)
onMounted(() => { onMounted(() => {
detailOptions.value = getDetailOption() detailOptions.value = getDetailOption()
scanOptions.value = getDetailEditRemoveOption() scanOptions.value = getDetailEditRemoveOption()
@ -62,6 +64,7 @@ const openScanPopup = (content, jobcontent) => {
scanPopup.value.openScanPopupForJob(fromLocationCode.value, fromLocationList.value, jobContent.value) scanPopup.value.openScanPopupForJob(fromLocationCode.value, fromLocationList.value, jobContent.value)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
packLoseFocus()
show.value = false show.value = false
emit('closeScan') emit('closeScan')
// //
@ -277,17 +280,17 @@ const addRecord = (batch, label, balance, packageInfo) => {
calcBatchHandleQty(batch) calcBatchHandleQty(batch)
getfocus() getfocus()
} }
const getfocus = () => { // const getfocus = () => {
if (scanPopup.value) { // if (scanPopup.value) {
scanPopup.value.getfocus() // scanPopup.value.getfocus()
} // }
} // }
//
const losefocus = () => { // const losefocus = () => {
if (scanPopup.value) { // if (scanPopup.value) {
scanPopup.value.losefocus() // scanPopup.value.losefocus()
} // }
} // }
const swipeClick = (params, item) => { const swipeClick = (params, item) => {
const { text } = scanOptions.value[params[1]] const { text } = scanOptions.value[params[1]]
@ -330,10 +333,14 @@ const remove = (record, index) => {
}) })
} }
const packGetFocus = () => { const packGetFocus = () => {
scanPopup.value.getfocus() if(scanOptions.value){
scanPopup.value.packGetFocus()
}
} }
const packLoseFocus = () => { const packLoseFocus = () => {
scanPopup.value.losefocus() if(scanPopup.value){
scanPopup.value.packLoseFocus()
}
} }
const showMessage = (message, callback) => { const showMessage = (message, callback) => {
setTimeout((r) => { setTimeout((r) => {

6
src/pages/package/record/overPackageRecord.vue

@ -258,6 +258,7 @@ const calcHandleQty1 = () => {
} }
const showErrorMessage = (message) => { const showErrorMessage = (message) => {
scanPopupLoseFocus()
comMessageRef.value.showErrorMessage(message, (res) => { comMessageRef.value.showErrorMessage(message, (res) => {
if (res) { if (res) {
scanPopupGetFocus() scanPopupGetFocus()
@ -296,6 +297,11 @@ const scanPopupGetFocus = () => {
scanPopup.value.getfocus() scanPopup.value.getfocus()
} }
} }
const scanPopupLoseFocus = ()=> {
if (scanPopup.value) {
scanPopup.value.losefocus();
}
}
const commit = () => { const commit = () => {
// if (!dataContent.value.printerUuid) { // if (!dataContent.value.printerUuid) {
// showErrorMessage('') // showErrorMessage('')

5
src/pages/productionReturn/coms/comScanReturnPack.vue

@ -113,6 +113,7 @@ const openScanPopup = (content, jobcontent) => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('closeScan') emit('closeScan')
// //
@ -369,13 +370,13 @@ const packLoseFocus = () => {
} }
const showMessage = (message, callback) => { const showMessage = (message, callback) => {
setTimeout((r) => { setTimeout((r) => {
packLoseFocus() losefocus()
comMessageRef.value.showMessage(message, callback) comMessageRef.value.showMessage(message, callback)
}) })
} }
const showErrorMessage = (message, callback) => { const showErrorMessage = (message, callback) => {
setTimeout((r) => { setTimeout((r) => {
packLoseFocus() losefocus()
comMessageRef.value.showErrorMessage(message, callback) comMessageRef.value.showErrorMessage(message, callback)
}) })
} }

5
src/pages/repleinsh/coms/comScanReplishPack.vue

@ -125,6 +125,7 @@ const openScanPopupForJobSimulate = (content, jobcontent, scanMessage) => {
}) })
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('closeScan') emit('closeScan')
// //
@ -251,9 +252,9 @@ const onScanResult = (result) => {
result.balance = res.data[0] result.balance = res.data[0]
if (result.label.packingNumber != result.balance.packingNumber) { if (result.label.packingNumber != result.balance.packingNumber) {
result.balance.handleQty = Number(result.label.qty) result.balance.qty = Number(result.label.qty)
} else { } else {
result.balance.handleQty = Number(result.balance.qty) result.balance.qty = Number(result.balance.qty)
} }
afterGetBalance(result.label, result.balance, result.package); afterGetBalance(result.label, result.balance, result.package);
} else { } else {

4
src/pages/repleinsh/job/repleinshJob.vue

@ -5,7 +5,7 @@
:productionline="productionlineList" ref="filter" otherTitle="" @switchChangeToday="switchChangeToday" :productionline="productionlineList" ref="filter" otherTitle="" @switchChangeToday="switchChangeToday"
@switchChangeWait="switchChangeWait" @onScanNumber="getScanNumber" :checkedToday="checkedToday" @switchChangeWait="switchChangeWait" @onScanNumber="getScanNumber" :checkedToday="checkedToday"
:checkedWaitTask="checkedWaitTask" :isShowItemCode="true" @productionLineCode="productionLineCode" :checkedWaitTask="checkedWaitTask" :isShowItemCode="true" @productionLineCode="productionLineCode"
@fromLocationCode="fromLocationCode" :isShowQurery='true' @onQuery="getListByFilter"> @fromLocationCode="fromLocationCodeQuery" :isShowQurery='true' @onQuery="getListByFilter">
</job-filter> </job-filter>
<view v-if="jobList.length > 0" class="u-m-20"> <view v-if="jobList.length > 0" class="u-m-20">
<u-swipe-action :show="item.show" :index="index" v-for="(item, index) in jobList" :key="index" :options="item.status == '2' ? detailGiveupOptions : item.status == '1' ? detailCloseOptions : detailOptions" bg-color="rgba(255,255,255,0)" class="u-m-b-20" @click="swipeClick"> <u-swipe-action :show="item.show" :index="index" v-for="(item, index) in jobList" :key="index" :options="item.status == '2' ? detailGiveupOptions : item.status == '1' ? detailCloseOptions : detailOptions" bg-color="rgba(255,255,255,0)" class="u-m-b-20" @click="swipeClick">
@ -196,7 +196,7 @@ const getList = (type, fromLocationCode = '', filterItemCode = '') => {
showErrorMessage(error) showErrorMessage(error)
}) })
} }
const fromLocationCode = (fromLocationCode) => { const fromLocationCodeQuery = (fromLocationCode) => {
console.log('fromLocationCode', fromLocationCode) console.log('fromLocationCode', fromLocationCode)
fromLocationCode.value = fromLocationCode fromLocationCode.value = fromLocationCode
getList('refresh', fromLocationCode.value, filterItemCode.value) getList('refresh', fromLocationCode.value, filterItemCode.value)

1
src/pages/stockUp/coms/comScanStockUpPack.vue

@ -141,6 +141,7 @@ const openScanPopup = (content, jobcontent) => {
}, 500) }, 500)
} }
const closeScanPopup = () => { const closeScanPopup = () => {
losefocus()
show.value = false show.value = false
emit('closeScan') emit('closeScan')
// //

Loading…
Cancel
Save