|
@@ -109,7 +109,6 @@ import {releaseOrder} from "@/static/js/request.js"
|
|
|
|
|
|
const userInfo = ref({})
|
|
|
const workStatus = ref('0')
|
|
|
-const searchVal = ref('')
|
|
|
const tabList = ref([
|
|
|
{title:"今日待完成", status: '0', leng:0},
|
|
|
{title:"历史处方", status: '1'},
|
|
@@ -138,6 +137,7 @@ const officeIndex = ref(0)
|
|
|
const typeArr = ref(['姓名:','处方号:'])
|
|
|
const typeIndex = ref(0)
|
|
|
|
|
|
+const searchVal = ref('')
|
|
|
const searchTime =ref([])
|
|
|
const searchDepartment = ref('')
|
|
|
const searchName = ref('')
|
|
@@ -204,6 +204,17 @@ onLoad(async () => {
|
|
|
}
|
|
|
})
|
|
|
|
|
|
+const reset = ()=>{
|
|
|
+ searchTime.value =[]
|
|
|
+ searchDepartment.value =''
|
|
|
+ searchName.value =''
|
|
|
+ searchPreNo.value =''
|
|
|
+ searchSex.value =''
|
|
|
+ searchPreMzZy.value =''
|
|
|
+ searchStatus.value =''
|
|
|
+ searchVal.value = ''
|
|
|
+}
|
|
|
+
|
|
|
// 子传父,更新userInfo
|
|
|
const updateUser = (v)=>{
|
|
|
console.log('updateUserStatus', v)
|
|
@@ -223,17 +234,14 @@ const emitSelect = (v)=>{
|
|
|
}
|
|
|
|
|
|
const handleSearch = async()=>{
|
|
|
- // const token = uni.getStorageSync('token')
|
|
|
- // console.log('handleSearch token',token)
|
|
|
- console.log('handleSearch searchVal', searchVal.value)
|
|
|
- console.log('currentStatus.value', currentStatus.value)
|
|
|
- searchVal.value = searchVal.value.trim()
|
|
|
+
|
|
|
+
|
|
|
if(tabActive.value ===0 && searchVal.value) {
|
|
|
const params = {
|
|
|
token: uni.getStorageSync('token'),
|
|
|
data: JSON.stringify({
|
|
|
currentUserId: parseInt(uni.getStorageSync('userId')) || 0,
|
|
|
- name: searchVal.value,
|
|
|
+ name: searchVal.value.trim(),
|
|
|
page: page.value,
|
|
|
pageSize: pageSize.value,
|
|
|
status: tabList.value[tabActive.value].status
|
|
@@ -245,14 +253,14 @@ const handleSearch = async()=>{
|
|
|
orderList.value = res.rows
|
|
|
}
|
|
|
}
|
|
|
- if(tabActive.value===1){
|
|
|
+ if(tabActive.value==1){
|
|
|
const params = {
|
|
|
token: uni.getStorageSync('token'),
|
|
|
data: JSON.stringify({
|
|
|
currentUserId: parseInt(uni.getStorageSync('userId')) || 0,
|
|
|
startTime: searchTime.value[0] || '',
|
|
|
endTime: searchTime.value[1] || '',
|
|
|
- name: searchVal.value || '',
|
|
|
+ name: searchName.value.trim() || '',
|
|
|
preNo: searchPreNo.value || '',
|
|
|
prescriptionStatus: searchStatus.value || '',
|
|
|
sex: searchSex.value || '',
|
|
@@ -304,6 +312,7 @@ const handleRefresh = async()=>{
|
|
|
console.log('orderList',orderList.value)
|
|
|
}
|
|
|
})
|
|
|
+ ids.value = []
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -412,6 +421,7 @@ const checkIndex = async(index) => {
|
|
|
page.value= 1
|
|
|
console.log('index',index)
|
|
|
ids.value = []
|
|
|
+ reset()
|
|
|
tabName.value = tabList.value[index].title
|
|
|
currentStatus.value = parseInt(tabList.value[index].status)
|
|
|
const token = uni.getStorageSync('token')
|