工单分配,维修人员,报修详情

This commit is contained in:
Zy
2026-05-21 10:55:27 +08:00
parent 5d0819183e
commit ac9379ab8a
14 changed files with 333 additions and 182 deletions

View File

@@ -4,6 +4,7 @@
<!-- 状态筛选标签 -->
<TabsComponents
:showBottomLine="false"
:activeValue="activeStatus"
:tabslist="statusTabs"
@update="switchStatus"
></TabsComponents>
@@ -125,9 +126,15 @@ function init() {
}
onShow(() => {
resetList()
})
function resetList() {
list.value = []
querySearch.value.pageNum = 1
querySearch.value.pageSize = 10
hasMore.value = true
init()
})
}
// actions
function handleComplaint(id: string) {

View File

@@ -66,12 +66,19 @@ function handleBlur(e) {
// 处理投诉 提交
function handleSelecthouse() {
putComplainProcess({
id: form.value.complaintId,
handleContent: form.value.handleContent
}).then(() => {
uni.navigateBack()
})
if (checkoutinfo.value.userId) {
putComplainProcess({
id: form.value.complaintId,
handleContent: form.value.handleContent
}).then(() => {
uni.navigateBack()
})
} else {
uni.showToast({
icon: 'error',
title: '选择处理人员'
})
}
}
</script>

View File

@@ -6,17 +6,19 @@
<view
@click="handleClick"
class="search_view flex-center"
v-if="!queryParmas.value.trim() && Searching"
v-if="!queryParmas.keyword.trim() && Searching"
>
<uni-icons type="search" size="34rpx" color="rgba(0,0,0,0.26)"></uni-icons>
<text>请输入关键字进行搜索</text>
</view>
<uni-easyinput
@blur="handleInput"
@change="handleSearch"
@confirm="handleSearch"
@clear="handleClear"
@input="handleClear"
:focus="true"
ref="inputRef"
v-model="queryParmas.value"
v-model="queryParmas.keyword"
v-else
/>
</view>
@@ -67,6 +69,7 @@
import { ref, onMounted, getCurrentInstance } from 'vue'
import { getSystemUsers_employee } from '@/api/common.js'
import navBar from '@/components/navbar/navbar.vue'
import { onShow } from '@dcloudio/uni-app'
let eventChannel = null
onMounted(() => {
@@ -81,11 +84,27 @@ function handleClick() {
}
/** 判断 失去焦点时 切换回 view */
function handleInput() {
if (queryParmas.value.value.trim()) {
if (queryParmas.value.keyword.trim()) {
Searching.value = true
resetList()
} else {
queryParmas.value.keyword = ''
Searching.value = false
resetList()
}
}
function handleSearch() {
if (queryParmas.value.keyword.trim()) {
resetList()
}
}
function handleClear() {
if (queryParmas.value.keyword.trim() === '') {
queryParmas.value.keyword = ''
Searching.value = true
resetList()
}
}
function handleSearch() {}
// -----------------------------------------
/* 选择列表 */
const searchlist = ref([])
@@ -93,19 +112,10 @@ const searchlist = ref([])
const queryParmas = ref({
pageNum: 1,
pageSize: 10,
value: ''
keyword: ''
})
const isLoading = ref(false) // 加载锁
const hasMore = ref(true) // 是否还有更多数据
const total = ref(21)
function scrolltolower() {
// 必须加这两个判断!
if (isLoading.value || !hasMore.value) {
return
}
queryParmas.value.pageNum += 1
getlist()
}
function getlist() {
// 2. 开启锁
if (isLoading.value) {
@@ -116,7 +126,7 @@ function getlist() {
title: '加载中',
mask: true
})
getSystemUsers_employee('complainUser', queryParmas.value.value)
getSystemUsers_employee('complainUser', queryParmas.value.keyword)
.then(res => {
searchlist.value = res.data
})
@@ -125,8 +135,15 @@ function getlist() {
uni.hideLoading()
})
}
getlist()
onShow(() => {
getlist()
})
function resetList() {
searchlist.value = []
queryParmas.value.pageNum = 1
getlist()
}
//=======================
// 选中的人员id
const checkoutUserid = ref(null)