优化打印标签逻辑
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<template>
|
||||
<el-dialog :title="props.title" width="600" v-model="dialogVisible" @open="opne">
|
||||
<!-- <el-input v-model="number" :placeholder="props.placeholder" readonly></el-input> -->
|
||||
<el-input ref="inputRef" v-model="number" :placeholder="props.placeholder" clearable
|
||||
<el-input ref="inputRef" v-model="number" :placeholder="props.placeholder" :readonly="loading" clearable
|
||||
@change="inputChange"></el-input>
|
||||
<div class="tips">注意:扫码请确保输入口获得焦点</div>
|
||||
<!-- <div class="keybord_wrap">
|
||||
@@ -119,7 +119,7 @@ function delHandle() {
|
||||
const inputChange = _.debounce(function (e) {
|
||||
// console.log(e);
|
||||
confirmHandle();
|
||||
}, 500);
|
||||
}, 100);
|
||||
|
||||
// 页码改变
|
||||
function handleCurrentChange() {
|
||||
@@ -151,6 +151,7 @@ const confirmHandle = _.throttle(async function () {
|
||||
try {
|
||||
if (!number.value) return
|
||||
loading.value = true
|
||||
|
||||
const res = await scanSendMessage({
|
||||
outNumber: number.value,
|
||||
shopId: store.userInfo.shopId,
|
||||
@@ -167,6 +168,7 @@ const confirmHandle = _.throttle(async function () {
|
||||
} catch (error) {
|
||||
getsendMessageAjax()
|
||||
loading.value = false
|
||||
number.value = ''
|
||||
console.log(error);
|
||||
setTimeout(() => {
|
||||
inputRef.value.focus();
|
||||
|
||||
Reference in New Issue
Block a user