Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
浙江兰德纵横网络技术股份有限公司
o2oa-android
提交
05274d90
o2oa-android
项目概览
浙江兰德纵横网络技术股份有限公司
/
o2oa-android
通知
5
Star
6
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
o2oa-android
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
05274d90
编写于
2月 01, 2023
作者:
F
fancy
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
工作查询重复数据的bug修复
上级
63837f97
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
21 addition
and
9 deletion
+21
-9
app/src/main/java/net/zoneland/x/bpm/mobile/v1/zoneXBPM/app/o2/process/TaskCompletedSearchActivity.kt
...v1/zoneXBPM/app/o2/process/TaskCompletedSearchActivity.kt
+19
-9
app/src/main/res/layout/activity_task_complete_search.xml
app/src/main/res/layout/activity_task_complete_search.xml
+2
-0
未找到文件。
app/src/main/java/net/zoneland/x/bpm/mobile/v1/zoneXBPM/app/o2/process/TaskCompletedSearchActivity.kt
浏览文件 @
05274d90
...
...
@@ -9,6 +9,7 @@ import android.text.Editable
import
android.text.TextUtils
import
android.text.TextWatcher
import
android.view.View
import
android.view.inputmethod.EditorInfo
import
kotlinx.android.synthetic.main.activity_task_complete_search.*
import
net.zoneland.x.bpm.mobile.v1.zoneXBPM.O2
import
net.zoneland.x.bpm.mobile.v1.zoneXBPM.R
...
...
@@ -76,13 +77,25 @@ class TaskCompletedSearchActivity : BaseMVPActivity<TaskCompletedSearchContract.
setSupportActionBar
(
toolBar
)
toolBar
?.
setNavigationIcon
(
R
.
mipmap
.
ic_back_mtrl_white_alpha
)
toolBar
?.
setNavigationOnClickListener
{
finish
()
}
edit_task_completed_search_key
.
setOnEditorActionListener
{
_
,
actionId
,
_
->
if
(
actionId
==
EditorInfo
.
IME_ACTION_SEARCH
)
{
searchKey
=
edit_task_completed_search_key
.
text
.
toString
()
if
(
searchKey
.
isEmpty
())
{
cleanResultList
()
}
else
{
searchTaskCompletedOnLine
(
searchKey
)
}
return
@setOnEditorActionListener
true
}
return
@setOnEditorActionListener
false
}
edit_task_completed_search_key
.
addTextChangedListener
(
object
:
TextWatcher
{
override
fun
afterTextChanged
(
s
:
Editable
?)
{
if
(
s
?.
length
==
0
)
{
searchKey
=
""
cleanResultList
()
}
else
{
searchTaskCompletedOnLine
(
s
)
searchTaskCompletedOnLine
(
s
?.
toString
()
?:
""
)
}
}
...
...
@@ -100,13 +113,9 @@ class TaskCompletedSearchActivity : BaseMVPActivity<TaskCompletedSearchContract.
}
}
refresh_task_completed_layout
.
setOnLoadMoreListener
{
if
(!
isLoading
&&
!
isRefresh
)
{
if
(!
isLoading
&&
!
isRefresh
&&
!
TextUtils
.
isEmpty
(
lastId
)
)
{
isLoading
=
true
if
(
TextUtils
.
isEmpty
(
lastId
))
{
searchTaskCompleted
(
true
)
}
else
{
searchTaskCompleted
(
false
)
}
searchTaskCompleted
(
false
)
}
}
...
...
@@ -163,6 +172,7 @@ class TaskCompletedSearchActivity : BaseMVPActivity<TaskCompletedSearchContract.
}
private
fun
searchTaskCompleted
(
flag
:
Boolean
)
{
XLog
.
debug
(
"查询开始 flag:$flag searchKey: $searchKey"
)
if
(
flag
)
{
mPresenter
.
search
(
O2
.
FIRST_PAGE_TAG
,
searchKey
,
searchType
)
}
else
{
...
...
@@ -174,8 +184,7 @@ class TaskCompletedSearchActivity : BaseMVPActivity<TaskCompletedSearchContract.
* 查询已办
* @param s
*/
private
fun
searchTaskCompletedOnLine
(
s
:
Editable
?)
{
val
key
=
s
.
toString
()
private
fun
searchTaskCompletedOnLine
(
key
:
String
)
{
if
(
TextUtils
.
isEmpty
(
key
))
{
searchKey
=
""
cleanResultList
()
...
...
@@ -183,6 +192,7 @@ class TaskCompletedSearchActivity : BaseMVPActivity<TaskCompletedSearchContract.
}
else
{
XLog
.
debug
(
"查询已办 key:$key"
)
searchKey
=
key
isRefresh
=
true
searchTaskCompleted
(
true
)
}
}
...
...
app/src/main/res/layout/activity_task_complete_search.xml
浏览文件 @
05274d90
...
...
@@ -24,6 +24,8 @@
android:id=
"@+id/edit_task_completed_search_key"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:imeOptions=
"actionSearch"
android:inputType=
"text"
android:hint=
"@string/activity_task_completed_search_hint"
/>
</androidx.appcompat.widget.Toolbar>
</com.google.android.material.appbar.AppBarLayout>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录