|
@@ -1,20 +1,31 @@
|
|
|
<template>
|
|
|
<view class="phone-list-page">
|
|
|
- <view class="icon-title-navBar-box">
|
|
|
+ <view class="phone-navBar-box">
|
|
|
<view @click="goUpPage" class="nav-bar-icon"></view>
|
|
|
<text class="nav-bar-title">成绩</text>
|
|
|
+ <view class="nav-bar-icon-box">
|
|
|
+ <uni-icons class="nav-bar-right-icon" type="search" size="18" color="#666"
|
|
|
+ @click="toggle('top')"></uni-icons>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
<!-- 查询职业 -->
|
|
|
- <view class="phone-search-box">
|
|
|
+ <!-- <view class="phone-search-box">
|
|
|
<input class="search-input" placeholder="请输入职业名称" v-model="data.zyName" />
|
|
|
<view class="search-icon" @click="handleSearch">
|
|
|
<uni-icons type="search" size="24" color="#fff"></uni-icons>
|
|
|
</view>
|
|
|
+ </view> -->
|
|
|
+
|
|
|
+ <view>
|
|
|
+ <search-dialog ref="searchDialogRef"
|
|
|
+ @search-btn="dialogSearchBtn"
|
|
|
+ @reset-search="dialogSearchReset"></search-dialog>
|
|
|
</view>
|
|
|
+
|
|
|
<!-- 课程列表 -->
|
|
|
- <scroll-view scroll-y="true" refresher-enabled="true" :refresher-triggered="data.loading"
|
|
|
+ <scroll-view scroll-y="true" refresher-enabled="true" :refresher-triggered="data.loading"
|
|
|
:refresher-threshold="50" refresher-background="transparent" @refresherrefresh="onRefresh"
|
|
|
- class="admin-phone-scroll-view">
|
|
|
+ class="jz-scroll-view">
|
|
|
<uni-list class="admin-list-box">
|
|
|
<uni-list-item v-for="item in data.list" class="admin-list-item-box">
|
|
|
<template v-slot:body>
|
|
@@ -79,6 +90,7 @@
|
|
|
import {
|
|
|
formatDuration
|
|
|
} from "@/utils/common.js"
|
|
|
+ import searchDialog from "@/pages/admin/jiazheng/common/search.vue";
|
|
|
|
|
|
|
|
|
const data = reactive({
|
|
@@ -92,8 +104,34 @@
|
|
|
contentdown: '查看更多',
|
|
|
contentrefresh: '加载中',
|
|
|
contentnomore: '没有更多'
|
|
|
- }
|
|
|
+ },
|
|
|
+ userName: '',
|
|
|
+ realName: '',
|
|
|
})
|
|
|
+
|
|
|
+ const searchDialogRef = ref(null);
|
|
|
+
|
|
|
+ function dialogSearchReset() {
|
|
|
+ data.userName = '';
|
|
|
+ data.realName = '';
|
|
|
+ }
|
|
|
+
|
|
|
+ function dialogSearchBtn(name, searchData) {
|
|
|
+ switch (name) {
|
|
|
+ case '姓名':
|
|
|
+ dialogSearchReset();
|
|
|
+ data.realName = searchData.value;
|
|
|
+ break;
|
|
|
+ case '手机号':
|
|
|
+ data.userName = searchData.value;
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ onRefresh();
|
|
|
+ }
|
|
|
+
|
|
|
+ const toggle = (data, index) => {
|
|
|
+ searchDialogRef.value.handleShow();
|
|
|
+ }
|
|
|
|
|
|
function goUpPage() {
|
|
|
uni.redirectTo({
|
|
@@ -123,7 +161,8 @@
|
|
|
const opt = {
|
|
|
page: 1,
|
|
|
size: 10, // 固定查询10条
|
|
|
- zyName: data.zyName
|
|
|
+ userName: data.userName,
|
|
|
+ realName: data.realName
|
|
|
}
|
|
|
data.list = [];
|
|
|
// 数学
|
|
@@ -152,7 +191,8 @@
|
|
|
const opt = {
|
|
|
page: 1,
|
|
|
size: 10, // 固定查询10条
|
|
|
- zyName: data.zyName
|
|
|
+ userName: data.userName,
|
|
|
+ realName: data.realName
|
|
|
}
|
|
|
if (data.state == 'no-more') return;
|
|
|
data.state = 'loading';
|