Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
W
WoolTrace
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hywang
WoolTrace
Commits
a0fddb86
Commit
a0fddb86
authored
May 11, 2022
by
hywang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.修改每次上传数量20
parent
a3365a7f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
12 deletions
+14
-12
build.gradle
app/build.gradle
+2
-2
RetrofitClient.java
app/src/main/java/com/phlx/wool/net/RetrofitClient.java
+2
-2
UploadVM.java
app/src/main/java/com/phlx/wool/ui/sync/vm/UploadVM.java
+8
-6
strings.xml
app/src/main/res/values/strings.xml
+2
-2
No files found.
app/build.gradle
View file @
a0fddb86
...
...
@@ -8,8 +8,8 @@ android {
applicationId
"com.phlx.wool"
minSdkVersion
21
targetSdkVersion
29
versionCode
2
0
versionName
"2.0.
0
"
versionCode
2
1
versionName
"2.0.
1
"
testInstrumentationRunner
"androidx.test.runner.AndroidJUnitRunner"
}
...
...
app/src/main/java/com/phlx/wool/net/RetrofitClient.java
View file @
a0fddb86
...
...
@@ -48,11 +48,11 @@ public class RetrofitClient {
private
static
final
int
CACHE_TIMEOUT
=
10
*
1024
*
1024
;
//服务端根路径
public
static
String
baseUrl
=
//
"58.18.92.126"//阿拉善正式
"58.18.92.126"
//阿拉善正式
// "39.101.170.186"//锡盟正式
// "192.168.12.105"//锡盟张敏测试
// "192.168.8.189"//张敏
"192.168.8.135"
//董昭阳
//
"192.168.8.135"//董昭阳
;
public
static
String
port
=
"899"
//阿拉善正式
...
...
app/src/main/java/com/phlx/wool/ui/sync/vm/UploadVM.java
View file @
a0fddb86
...
...
@@ -83,6 +83,8 @@ public class UploadVM extends BackBarVM<Repository> {
private
long
succCount
,
totalCount
;
//上传结束提示成功数量、总数量
private
int
uploadPageSize
=
20
;
//每次上传数量
private
boolean
isMarkingUpload
,
isHarmlessUpload
,
isQuarantineUpload
,
isVillusBuyUpload
,
isVillusGaugeUpload
,
isSlaughterEntryUpload
;
public
UploadVM
(
@NonNull
Application
application
,
Repository
repository
)
{
...
...
@@ -251,7 +253,7 @@ public class UploadVM extends BackBarVM<Repository> {
QueryBuilder
<
Marking
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
Marking
.
class
)
.
where
(
MarkingDao
.
Properties
.
Status
.
eq
(
1
))
.
limit
(
100
)
.
limit
(
uploadPageSize
)
;
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
Marking
>()
{
@Override
...
...
@@ -339,7 +341,7 @@ public class UploadVM extends BackBarVM<Repository> {
private
void
uploadQuarantine
()
{
QueryBuilder
<
Quarantine
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
Quarantine
.
class
).
where
(
QuarantineDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
20
);
where
(
QuarantineDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
uploadPageSize
);
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
Quarantine
>()
{
@Override
public
void
onSuccess
(
List
<
Quarantine
>
result
)
{
...
...
@@ -418,7 +420,7 @@ public class UploadVM extends BackBarVM<Repository> {
private
void
uploadHarmless
()
{
QueryBuilder
<
Harmless
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
Harmless
.
class
).
where
(
HarmlessDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
20
);
where
(
HarmlessDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
uploadPageSize
);
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
Harmless
>()
{
@Override
public
void
onSuccess
(
List
<
Harmless
>
result
)
{
...
...
@@ -499,7 +501,7 @@ public class UploadVM extends BackBarVM<Repository> {
QueryBuilder
<
VillusBuyEntity
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
VillusBuyEntity
.
class
).
where
(
VillusBuyEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
100
);
where
(
VillusBuyEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
uploadPageSize
);
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
VillusBuyEntity
>()
{
@Override
public
void
onSuccess
(
List
<
VillusBuyEntity
>
result
)
{
...
...
@@ -564,7 +566,7 @@ public class UploadVM extends BackBarVM<Repository> {
private
void
uploadVillusGauge
()
{
QueryBuilder
<
VillusGaugeEntity
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
VillusGaugeEntity
.
class
).
where
(
VillusGaugeEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
100
);
where
(
VillusGaugeEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
uploadPageSize
);
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
VillusGaugeEntity
>()
{
@Override
public
void
onSuccess
(
List
<
VillusGaugeEntity
>
result
)
{
...
...
@@ -629,7 +631,7 @@ public class UploadVM extends BackBarVM<Repository> {
private
void
uploadSlaughterEntry
()
{
QueryBuilder
<
EntryRegistrationEntity
>
builder
=
DbUtil
.
getInstance
().
getQueryBuilder
(
EntryRegistrationEntity
.
class
).
where
(
EntryRegistrationEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
100
);
where
(
EntryRegistrationEntityDao
.
Properties
.
Status
.
eq
(
1
)).
limit
(
uploadPageSize
);
DbUtil
.
getInstance
().
setDbQueryCallBack
(
new
DbQueryCallBack
<
EntryRegistrationEntity
>()
{
@Override
public
void
onSuccess
(
List
<
EntryRegistrationEntity
>
result
)
{
...
...
app/src/main/res/values/strings.xml
View file @
a0fddb86
<resources>
<!-- <string name="app_name">追溯系统</string>--
>
<string
name=
"app_name"
>
基础信息录入
</string
>
<string
name=
"app_name"
>
追溯系统
</string
>
<!-- <string name="app_name">基础信息录入</string>--
>
<string
name=
"setting"
>
设置
</string>
<string
name=
"jobNum"
>
工号:
</string>
<string
name=
"pleaseInputUserName"
>
请输入用户名
</string>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment