优化
This commit is contained in:
@@ -62,3 +62,16 @@ export function queryQuickPay(params) {
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 叫号
|
||||
* @param {*} params
|
||||
* @returns
|
||||
*/
|
||||
export function sendMessage(params) {
|
||||
return request({
|
||||
method: "get",
|
||||
url: "/order/sendMessage",
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
@@ -98,13 +98,19 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="orderbox_right_button">
|
||||
<el-button style="width: 100%;"
|
||||
v-if="orderDetaildata.orderType != 'return' && (orderDetaildata.status == 'refund' || orderDetaildata.status == 'closed')"
|
||||
type="primary" @click="recharge = true">退单</el-button>
|
||||
<div class="orderbox_right_buttonbutton">
|
||||
<!-- // -->
|
||||
<el-button @click="print('normal')" style="width: 45%;" type="">重打收银打票</el-button>
|
||||
<el-button @click="print('label')" style="width: 45%;" type="">重打标签小票</el-button>
|
||||
<el-button style="width: 100%;" type="warning" :loading="callLoading" @click="callNumberHandle">
|
||||
叫号
|
||||
</el-button>
|
||||
</div>
|
||||
<div class="orderbox_right_buttonbutton">
|
||||
<el-button style="width: 100%;"
|
||||
v-if="orderDetaildata.orderType != 'return' && (orderDetaildata.status == 'refund' || orderDetaildata.status == 'closed')"
|
||||
type="primary" @click="recharge = true">退单</el-button>
|
||||
</div>
|
||||
<div class="orderbox_right_buttonbutton">
|
||||
<el-button @click="print('normal')" style="flex: 1;">重打收银打票</el-button>
|
||||
<el-button @click="print('label')" style="flex: 1;">重打标签小票</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -234,7 +240,7 @@ import { ref, onMounted, reactive } from 'vue'
|
||||
import { ElMessage, dayjs } from 'element-plus'
|
||||
import { useUser } from "@/store/user.js"
|
||||
import lodash from 'lodash'
|
||||
import { orderfindOrder, orderorderDetail, payreturnOrder, cloudPrinterprint } from '@/api/order/index.js'
|
||||
import { orderfindOrder, orderorderDetail, payreturnOrder, cloudPrinterprint, sendMessage } from '@/api/order/index.js'
|
||||
import add from '@/views/order/components/add.vue'
|
||||
import cashTable from '@/views/order/components/cashTable.vue'
|
||||
import { clearNoNum } from '@/utils'
|
||||
@@ -427,6 +433,23 @@ const handleCurrentChange = (val) => { //页码
|
||||
const inputChange = lodash.debounce(function () { //搜索手机号
|
||||
asyncorderfindOrder()
|
||||
}, 500)
|
||||
|
||||
// 叫号
|
||||
const callLoading = ref(false)
|
||||
const callNumberHandle = async () => {
|
||||
try {
|
||||
callLoading.value = true
|
||||
const res = await sendMessage({
|
||||
orderId: orderDetaildata.value.id
|
||||
})
|
||||
callLoading.value = false
|
||||
ElMessage.success('叫号成功')
|
||||
} catch (error) {
|
||||
callLoading.value = false
|
||||
console.log(error);
|
||||
}
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
// resetMembrform.value = { ...membrform.value }
|
||||
asyncorderfindOrder()
|
||||
|
||||
Reference in New Issue
Block a user