Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
android
/
dayu
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
bd931238
authored
6 years ago
by
罗翻
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
部分功能优化,增加条形码扫描,处理工单提示,获取地址时间间隔改为5分钟
parent
88db9469
master
…
dev
dev_xx
dev_xx_241116
dev_xx_250108_toast
dev_xx_250224_report
dev_xx_web
test
v2.7.2
v2.7.1
v2.7.0
v2.6.9
v2.6.7
v2.6.6
v2.6.5
v2.6.4
v2.6.3
v2.6.2
v2.6.1
v2.6.0
v2.5.9
v2.5.7
v2.5.5
v2.5.4
v2.5.3
v2.5.2
v2.5.0
v2.4.6
v2.4.5
v2.4.0
v_2.4.0
v2.3.2
v2.3.1
dev20230405
Show whitespace changes
Inline
Side-by-side
Showing
25 changed files
with
180 additions
and
93 deletions
app/src/main/java/com/dayu/bigfish/presenter/main/MainContract.java
app/src/main/java/com/dayu/bigfish/ui/MainActivity.java
app/src/main/java/com/dayu/bigfish/ui/service/LocationService.java
baseSDK/src/main/java/com/dayu/base/ui/adapter/CoreAdapter.java
baseSDK/src/main/java/com/dayu/utils/SelectPicUtils.java
baseSDK/src/main/java/com/dayu/widgets/LRecyclerView.java
baseSDK/src/main/res/values/strings.xml
locationComponent/src/main/java/com/dayu/location/base/LocationUtils.java
orderCenter/src/main/java/com/dayu/order/presenter/worksRecord/OrderRecordPresenter.java
orderCenter/src/main/java/com/dayu/order/ui/activity/MultiProcessOrderActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/ProcessOrderActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/ServerInfoActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/ServerListActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/SopWebViewActivity.java
orderCenter/src/main/res/drawable-hdpi/icon_scan.png
orderCenter/src/main/res/drawable-xhdpi/icon_scan.png
orderCenter/src/main/res/drawable-xxhdpi/icon_scan.png
orderCenter/src/main/res/drawable-xxxhdpi/icon_scan.png
orderCenter/src/main/res/layout/activity_multi_process_order.xml
orderCenter/src/main/res/layout/activity_server_info.xml
orderCenter/src/main/res/layout/activity_server_list_recycle.xml
orderCenter/src/main/res/layout/fragment_order_datails.xml
orderCenter/src/main/res/layout/qr_code_layout.xml
userCenter/src/main/java/com/dayu/usercenter/presenter/pwlogin/PwLoginPresenter.java
userCenter/src/main/java/com/dayu/usercenter/presenter/smslogin/SmsLoginPresenter.java
app/src/main/java/com/dayu/bigfish/presenter/main/MainContract.java
View file @
bd931238
...
@@ -28,7 +28,7 @@ public interface MainContract {
...
@@ -28,7 +28,7 @@ public interface MainContract {
void
initNotification
();
void
initNotification
();
void
startLoca
it
onService
();
void
startLoca
ti
onService
();
}
}
abstract
class
Presenter
extends
BasePresenter
<
View
>
{
abstract
class
Presenter
extends
BasePresenter
<
View
>
{
...
...
This diff is collapsed.
Click to expand it.
app/src/main/java/com/dayu/bigfish/ui/MainActivity.java
View file @
bd931238
...
@@ -87,7 +87,7 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
...
@@ -87,7 +87,7 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
addFragment
();
addFragment
();
initListener
();
initListener
();
doAction
(
getIntent
());
doAction
(
getIntent
());
startLoca
it
onService
();
startLoca
ti
onService
();
EventBus
.
getDefault
().
register
(
this
);
EventBus
.
getDefault
().
register
(
this
);
}
}
...
@@ -113,11 +113,15 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
...
@@ -113,11 +113,15 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
mFragmentManger
=
getSupportFragmentManager
();
mFragmentManger
=
getSupportFragmentManager
();
FragmentTransaction
transaction
=
mFragmentManger
.
beginTransaction
()
FragmentTransaction
transaction
=
mFragmentManger
.
beginTransaction
()
.
setTransition
(
FragmentTransaction
.
TRANSIT_FRAGMENT_OPEN
);
.
setTransition
(
FragmentTransaction
.
TRANSIT_FRAGMENT_OPEN
);
for
(
Fragment
fragment
:
mFragments
)
{
for
(
int
i
=
0
;
i
<
mFragments
.
length
;
i
++)
{
Fragment
fragment
=
mFragments
[
i
];
transaction
.
add
(
R
.
id
.
fl_container
,
fragment
);
transaction
.
add
(
R
.
id
.
fl_container
,
fragment
);
if
(
i
==
mFirstPositon
)
{
transaction
.
show
(
fragment
);
}
else
{
transaction
.
hide
(
fragment
);
transaction
.
hide
(
fragment
);
}
}
transaction
.
show
(
mFragments
[
mFirstPositon
]);
}
transaction
.
commit
();
transaction
.
commit
();
resetSelected
(
mFirstPositon
);
resetSelected
(
mFirstPositon
);
}
}
...
@@ -131,8 +135,8 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
...
@@ -131,8 +135,8 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
private
void
showHideFragment
(
int
showPosition
,
int
hidePosition
)
{
private
void
showHideFragment
(
int
showPosition
,
int
hidePosition
)
{
if
(
showPosition
==
hidePosition
)
return
;
if
(
showPosition
==
hidePosition
)
return
;
mFragmentManger
.
beginTransaction
()
mFragmentManger
.
beginTransaction
()
.
show
(
mFragments
[
showPosition
])
.
hide
(
mFragments
[
hidePosition
])
.
hide
(
mFragments
[
hidePosition
])
.
show
(
mFragments
[
showPosition
])
.
commit
();
.
commit
();
resetSelected
(
showPosition
);
resetSelected
(
showPosition
);
mPosition
=
showPosition
;
mPosition
=
showPosition
;
...
@@ -234,7 +238,7 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
...
@@ -234,7 +238,7 @@ public class MainActivity extends BaseActivity<MainPresenter, ActivityMainBindin
}
}
@Override
@Override
public
void
startLoca
it
onService
()
{
public
void
startLoca
ti
onService
()
{
UserInfo
userInfo
=
UserManager
.
getInstance
().
getUser
();
UserInfo
userInfo
=
UserManager
.
getInstance
().
getUser
();
Intent
intent
=
new
Intent
(
mActivity
,
LocationService
.
class
);
Intent
intent
=
new
Intent
(
mActivity
,
LocationService
.
class
);
intent
.
putExtra
(
Constants
.
ACCOUNT_ID
,
userInfo
.
getAccountId
());
intent
.
putExtra
(
Constants
.
ACCOUNT_ID
,
userInfo
.
getAccountId
());
...
...
This diff is collapsed.
Click to expand it.
app/src/main/java/com/dayu/bigfish/ui/service/LocationService.java
View file @
bd931238
...
@@ -57,7 +57,6 @@ public class LocationService extends Service {
...
@@ -57,7 +57,6 @@ public class LocationService extends Service {
RequestBody
requestBody
=
RequestBody
.
create
(
MediaType
.
parse
(
"application/json"
),
jsonObject
.
toString
());
RequestBody
requestBody
=
RequestBody
.
create
(
MediaType
.
parse
(
"application/json"
),
jsonObject
.
toString
());
ApiFactory
.
commiteLocation
(
requestBody
).
subscribe
(
aBoolean
->
{
ApiFactory
.
commiteLocation
(
requestBody
).
subscribe
(
aBoolean
->
{
},
throwable
->
{
},
throwable
->
{
});
});
}
}
}));
}));
...
@@ -71,7 +70,7 @@ public class LocationService extends Service {
...
@@ -71,7 +70,7 @@ public class LocationService extends Service {
sendMessage
();
sendMessage
();
}
}
};
};
mTimer
.
schedule
(
mTask
,
2000
,
6
00000
);
mTimer
.
schedule
(
mTask
,
2000
,
3
00000
);
}
}
public
void
sendMessage
()
{
public
void
sendMessage
()
{
...
...
This diff is collapsed.
Click to expand it.
baseSDK/src/main/java/com/dayu/base/ui/adapter/CoreAdapter.java
View file @
bd931238
...
@@ -4,7 +4,6 @@ import android.animation.ObjectAnimator;
...
@@ -4,7 +4,6 @@ import android.animation.ObjectAnimator;
import
android.content.Context
;
import
android.content.Context
;
import
android.databinding.DataBindingUtil
;
import
android.databinding.DataBindingUtil
;
import
android.support.annotation.LayoutRes
;
import
android.support.annotation.LayoutRes
;
import
android.support.annotation.NonNull
;
import
android.support.v7.widget.RecyclerView
;
import
android.support.v7.widget.RecyclerView
;
import
android.view.LayoutInflater
;
import
android.view.LayoutInflater
;
import
android.view.View
;
import
android.view.View
;
...
@@ -237,13 +236,13 @@ public class CoreAdapter<M, B> extends RecyclerView.Adapter<BaseViewHolder> {
...
@@ -237,13 +236,13 @@ public class CoreAdapter<M, B> extends RecyclerView.Adapter<BaseViewHolder> {
}
}
}
}
@Override
//
@Override
public
void
onViewAttachedToWindow
(
@NonNull
BaseViewHolder
holder
)
{
//
public void onViewAttachedToWindow(@NonNull BaseViewHolder holder) {
if
(
holder
.
getLayoutPosition
()
>
oldPosition
)
{
//
if (holder.getLayoutPosition() > oldPosition) {
addItemAnimation
(
holder
.
itemView
);
//
addItemAnimation(holder.itemView);
oldPosition
=
holder
.
getLayoutPosition
();
//
oldPosition = holder.getLayoutPosition();
}
//
}
}
//
}
private
void
addItemAnimation
(
View
itemView
)
{
private
void
addItemAnimation
(
View
itemView
)
{
ObjectAnimator
.
ofFloat
(
itemView
,
"translationY"
,
500
f
,
0
f
).
setDuration
(
500
).
start
();
ObjectAnimator
.
ofFloat
(
itemView
,
"translationY"
,
500
f
,
0
f
).
setDuration
(
500
).
start
();
...
...
This diff is collapsed.
Click to expand it.
baseSDK/src/main/java/com/dayu/utils/SelectPicUtils.java
0 → 100644
View file @
bd931238
package
com
.
dayu
.
utils
;
import
android.app.Activity
;
import
android.os.Environment
;
import
com.luck.picture.lib.PictureSelectionModel
;
import
com.luck.picture.lib.PictureSelector
;
import
com.luck.picture.lib.config.PictureConfig
;
import
com.luck.picture.lib.config.PictureMimeType
;
import
java.io.File
;
/**
* Created by luofan
* on 2018/8/7.
*/
public
class
SelectPicUtils
{
public
static
void
selectPic
(
Activity
activity
,
int
size
)
{
PictureSelectionModel
selector
=
PictureSelector
.
create
(
activity
)
.
openGallery
(
PictureMimeType
.
ofImage
())
//全部.PictureMimeType.ofAll()、图片.ofImage()、视频.ofVideo()
.
maxSelectNum
(
size
)
// 最大图片选择数量 int
.
imageSpanCount
(
4
)
// 每行显示个数 int
.
selectionMode
(
PictureConfig
.
MULTIPLE
)
// 多选 or 单选 PictureConfig.MULTIPLE or PictureConfig.SINGLE
.
previewImage
(
true
)
// 是否可预览图片 true or false
.
isCamera
(
true
)
// 是否显示拍照按钮 true or false
.
isZoomAnim
(
true
)
// 图片列表点击 缩放效果 默认true
.
sizeMultiplier
(
0.1f
)
// glide 加载图片大小 0~1之间 如设置 .glideOverride()无效
.
setOutputCameraPath
(
"/CustomPath"
)
// 自定义拍、照保存路径,可不填
.
compress
(
true
)
// 是否压缩 true or false
.
glideOverride
(
300
,
500
)
// int glide 加载宽高,越小图片列表越流畅,但会影响列表图片浏览的清晰度
.
hideBottomControls
(
true
)
// 是否显示uCrop工具栏,默认不显示 true or false
.
compressSavePath
(
getPath
())
//压缩图片保存地址
.
previewEggs
(
true
)
// 预览图片时 是否增强左右滑动图片体验(图片滑动一半即可看到上一张是否选中) true or false
// .minimumCompressSize(100)// 小于100kb的图片不压缩
.
synOrAsy
(
true
);
//同步true或异步false 压缩 默认同步、
// .enableCrop(true)//是否裁剪
// .freeStyleCropEnabled(true)
selector
.
forResult
(
PictureConfig
.
CHOOSE_REQUEST
);
}
private
static
String
getPath
()
{
String
path
=
Environment
.
getExternalStorageDirectory
()
+
"/dayu/image/"
;
File
file
=
new
File
(
path
);
if
(
file
.
mkdirs
())
{
return
path
;
}
return
path
;
}
}
This diff is collapsed.
Click to expand it.
baseSDK/src/main/java/com/dayu/widgets/LRecyclerView.java
View file @
bd931238
...
@@ -85,7 +85,6 @@ public class LRecyclerView<M, B> extends FrameLayout {
...
@@ -85,7 +85,6 @@ public class LRecyclerView<M, B> extends FrameLayout {
public
LRecyclerView
(
@NonNull
Context
context
,
@Nullable
AttributeSet
attrs
,
int
defStyleAttr
)
{
public
LRecyclerView
(
@NonNull
Context
context
,
@Nullable
AttributeSet
attrs
,
int
defStyleAttr
)
{
super
(
context
,
attrs
,
defStyleAttr
);
super
(
context
,
attrs
,
defStyleAttr
);
init
(
context
,
attrs
);
init
(
context
,
attrs
);
}
}
private
void
init
(
Context
context
,
AttributeSet
attrs
)
{
private
void
init
(
Context
context
,
AttributeSet
attrs
)
{
...
...
This diff is collapsed.
Click to expand it.
baseSDK/src/main/res/values/strings.xml
View file @
bd931238
...
@@ -361,6 +361,8 @@
...
@@ -361,6 +361,8 @@
<string
name=
"signature_name"
>
请先签名!
</string>
<string
name=
"signature_name"
>
请先签名!
</string>
<string
name=
"click_and_signature"
>
点击此处让客户去签名
</string>
<string
name=
"click_and_signature"
>
点击此处让客户去签名
</string>
<string
name=
"download_gaode_notice"
>
您还未安装高德地图~
</string>
<string
name=
"download_gaode_notice"
>
您还未安装高德地图~
</string>
<string
name=
"sop_title"
>
标准操作规范SOP~
</string>
<string
name=
"process_notice"
>
温馨提示:点击屏幕底部“提交验收”按钮,申请费用。
</string>
<!--消息-->
<!--消息-->
<string
name=
"message_system"
>
系统通知
</string>
<string
name=
"message_system"
>
系统通知
</string>
...
...
This diff is collapsed.
Click to expand it.
locationComponent/src/main/java/com/dayu/location/base/LocationUtils.java
View file @
bd931238
package
com
.
dayu
.
location
.
base
;
package
com
.
dayu
.
location
.
base
;
import
android.annotation.SuppressLint
;
import
android.content.ActivityNotFoundException
;
import
android.content.ActivityNotFoundException
;
import
android.content.Context
;
import
android.content.Context
;
import
android.content.Intent
;
import
android.content.Intent
;
...
@@ -25,6 +24,7 @@ public class LocationUtils {
...
@@ -25,6 +24,7 @@ public class LocationUtils {
private
static
AMapLocationClient
mlocationClient
;
private
static
AMapLocationClient
mlocationClient
;
private
static
AMapLocation
sLocation
=
null
;
private
static
AMapLocation
sLocation
=
null
;
private
static
boolean
flag
=
true
;
private
static
boolean
flag
=
true
;
private
static
MyLocationListener
mListener
;
private
static
Handler
mHandler
;
private
static
Handler
mHandler
;
/**
/**
...
@@ -75,7 +75,8 @@ public class LocationUtils {
...
@@ -75,7 +75,8 @@ public class LocationUtils {
* @Title: getCurrentLocation
* @Title: getCurrentLocation
* @Description: 获取位置,重新发起获取位置请求
* @Description: 获取位置,重新发起获取位置请求
*/
*/
public
static
void
getCurrentLocation
(
final
MyLocationListener
listener
)
{
public
static
void
getCurrentLocation
(
MyLocationListener
listener
)
{
mListener
=
listener
;
if
(
mlocationClient
==
null
)
{
if
(
mlocationClient
==
null
)
{
return
;
return
;
}
}
...
@@ -86,7 +87,7 @@ public class LocationUtils {
...
@@ -86,7 +87,7 @@ public class LocationUtils {
@Override
@Override
public
void
run
()
{
public
void
run
()
{
if
(
flag
)
{
if
(
flag
)
{
l
istener
.
result
(
sLocation
);
mL
istener
.
result
(
sLocation
);
flag
=
false
;
flag
=
false
;
mlocationClient
.
stopLocation
();
mlocationClient
.
stopLocation
();
}
}
...
@@ -101,7 +102,7 @@ public class LocationUtils {
...
@@ -101,7 +102,7 @@ public class LocationUtils {
flag
=
false
;
flag
=
false
;
mlocationClient
.
stopLocation
();
mlocationClient
.
stopLocation
();
sLocation
=
location
;
sLocation
=
location
;
l
istener
.
result
(
location
);
mL
istener
.
result
(
location
);
mHandler
=
null
;
mHandler
=
null
;
}
}
}
}
...
@@ -119,6 +120,7 @@ public class LocationUtils {
...
@@ -119,6 +120,7 @@ public class LocationUtils {
if
(
mlocationClient
!=
null
)
{
if
(
mlocationClient
!=
null
)
{
mlocationClient
.
onDestroy
();
mlocationClient
.
onDestroy
();
}
}
mListener
=
null
;
}
}
/**
/**
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/presenter/worksRecord/OrderRecordPresenter.java
View file @
bd931238
...
@@ -22,8 +22,8 @@ import java.util.List;
...
@@ -22,8 +22,8 @@ import java.util.List;
* on 2017/11/8.
* on 2017/11/8.
*/
*/
public
class
OrderRecordPresenter
extends
OrderRecordContract
.
Presenter
{
public
class
OrderRecordPresenter
extends
OrderRecordContract
.
Presenter
{
p
ublic
ObservableField
datas
=
new
ObservableField
();
p
rivate
ObservableField
<
Object
>
datas
=
new
ObservableField
<>
();
public
ObservableField
<
String
>
serchStr
=
new
ObservableField
();
public
ObservableField
<
String
>
serchStr
=
new
ObservableField
<>
();
private
int
mPage
;
private
int
mPage
;
private
int
mUserId
;
private
int
mUserId
;
private
int
mSiteId
;
private
int
mSiteId
;
...
@@ -88,7 +88,7 @@ public class OrderRecordPresenter extends OrderRecordContract.Presenter {
...
@@ -88,7 +88,7 @@ public class OrderRecordPresenter extends OrderRecordContract.Presenter {
MobclickAgent
.
onEvent
(
BaseApplication
.
getContext
(),
"check_order_detail"
);
MobclickAgent
.
onEvent
(
BaseApplication
.
getContext
(),
"check_order_detail"
);
}
}
p
ublic
void
doSearch
(
String
str
)
{
p
rivate
void
doSearch
(
String
str
)
{
if
(
mList
==
null
||
TextUtils
.
isEmpty
(
str
))
{
if
(
mList
==
null
||
TextUtils
.
isEmpty
(
str
))
{
return
;
return
;
}
}
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/ui/activity/MultiProcessOrderActivity.java
View file @
bd931238
...
@@ -71,9 +71,8 @@ public class MultiProcessOrderActivity extends BaseActivity<MultiProcessOrderPre
...
@@ -71,9 +71,8 @@ public class MultiProcessOrderActivity extends BaseActivity<MultiProcessOrderPre
mBind
.
ivDelete
.
setVisibility
(
View
.
GONE
);
mBind
.
ivDelete
.
setVisibility
(
View
.
GONE
);
mSnImages
.
clear
();
mSnImages
.
clear
();
});
});
// mBind.scan.setOnClickListener(v -> {
mBind
.
scan
.
setOnClickListener
(
v
->
// new IntentIntegrator(this).setOrientationLocked(false).setCaptureActivity(CustomScannerActivity.class).initiateScan();
new
IntentIntegrator
(
this
).
setOrientationLocked
(
false
).
setCaptureActivity
(
CustomScannerActivity
.
class
).
initiateScan
());
// });
}
}
@Override
@Override
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/ui/activity/ProcessOrderActivity.java
View file @
bd931238
...
@@ -115,7 +115,10 @@ public class ProcessOrderActivity extends BaseActivity<ProcessOrderPresenter, Ac
...
@@ -115,7 +115,10 @@ public class ProcessOrderActivity extends BaseActivity<ProcessOrderPresenter, Ac
}
}
public
String
getSum
()
{
public
String
getSum
()
{
return
new
DecimalFormat
(
"0.00"
).
format
(
parseDb
(
mBind
.
etDoorPrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etServePrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etMaterialsPrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etOtherPrice
.
getText
().
toString
()));
return
new
DecimalFormat
(
"0.00"
).
format
(
parseDb
(
mBind
.
etDoorPrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etServePrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etMaterialsPrice
.
getText
().
toString
())
+
parseDb
(
mBind
.
etOtherPrice
.
getText
().
toString
()));
}
}
public
Double
parseDb
(
String
str
)
{
public
Double
parseDb
(
String
str
)
{
...
@@ -250,10 +253,8 @@ public class ProcessOrderActivity extends BaseActivity<ProcessOrderPresenter, Ac
...
@@ -250,10 +253,8 @@ public class ProcessOrderActivity extends BaseActivity<ProcessOrderPresenter, Ac
info
.
setProductModel
(
mBind
.
etVersion
.
getText
().
toString
());
info
.
setProductModel
(
mBind
.
etVersion
.
getText
().
toString
());
info
.
setSn
(
mBind
.
etSerialNum
.
getText
().
toString
());
info
.
setSn
(
mBind
.
etSerialNum
.
getText
().
toString
());
mPresenter
.
mOrderField
.
set
(
info
);
mPresenter
.
mOrderField
.
set
(
info
);
}
}
private
void
dumpPic
(
ArrayList
<
String
>
list
)
{
private
void
dumpPic
(
ArrayList
<
String
>
list
)
{
Intent
intent
=
new
Intent
(
this
,
PreviewActivty
.
class
);
Intent
intent
=
new
Intent
(
this
,
PreviewActivty
.
class
);
intent
.
putStringArrayListExtra
(
Constants
.
BUNDLE_KEY_ID
,
list
);
intent
.
putStringArrayListExtra
(
Constants
.
BUNDLE_KEY_ID
,
list
);
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/ui/activity/ServerInfoActivity.java
View file @
bd931238
...
@@ -2,6 +2,9 @@ package com.dayu.order.ui.activity;
...
@@ -2,6 +2,9 @@ package com.dayu.order.ui.activity;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.text.SpannableString
;
import
android.text.Spanned
;
import
android.text.style.ForegroundColorSpan
;
import
com.dayu.base.ui.activity.BaseActivity
;
import
com.dayu.base.ui.activity.BaseActivity
;
import
com.dayu.common.Constants
;
import
com.dayu.common.Constants
;
...
@@ -35,6 +38,9 @@ public class ServerInfoActivity extends BaseActivity<ServerInfoPresenter, Activi
...
@@ -35,6 +38,9 @@ public class ServerInfoActivity extends BaseActivity<ServerInfoPresenter, Activi
@Override
@Override
public
void
initView
()
{
public
void
initView
()
{
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
task_list
));
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
task_list
));
SpannableString
spannableString
=
new
SpannableString
(
getString
(
R
.
string
.
process_notice
));
spannableString
.
setSpan
(
new
ForegroundColorSpan
(
getResources
().
getColor
(
R
.
color
.
bg_button
)),
0
,
5
,
Spanned
.
SPAN_EXCLUSIVE_EXCLUSIVE
);
mBind
.
notice
.
setText
(
spannableString
);
ServerInfoAdapter
adapter
=
new
ServerInfoAdapter
(
false
);
ServerInfoAdapter
adapter
=
new
ServerInfoAdapter
(
false
);
mBind
.
recyclerView
.
setAdapter
(
adapter
);
mBind
.
recyclerView
.
setAdapter
(
adapter
);
mBind
.
tvProcess
.
setOnClickListener
(
v
->
{
mBind
.
tvProcess
.
setOnClickListener
(
v
->
{
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/ui/activity/ServerListActivity.java
View file @
bd931238
...
@@ -2,6 +2,9 @@ package com.dayu.order.ui.activity;
...
@@ -2,6 +2,9 @@ package com.dayu.order.ui.activity;
import
android.content.Intent
;
import
android.content.Intent
;
import
android.os.Bundle
;
import
android.os.Bundle
;
import
android.text.SpannableString
;
import
android.text.Spanned
;
import
android.text.style.ForegroundColorSpan
;
import
com.dayu.base.ui.activity.BaseActivity
;
import
com.dayu.base.ui.activity.BaseActivity
;
import
com.dayu.common.Constants
;
import
com.dayu.common.Constants
;
...
@@ -36,8 +39,9 @@ public class ServerListActivity extends BaseActivity<ServerListPresenter, Activi
...
@@ -36,8 +39,9 @@ public class ServerListActivity extends BaseActivity<ServerListPresenter, Activi
@Override
@Override
public
void
initView
()
{
public
void
initView
()
{
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
task_list
));
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
task_list
));
mBind
.
tvProcess
.
setOnClickListener
(
o
->
{
SpannableString
spannableString
=
new
SpannableString
(
getString
(
R
.
string
.
process_notice
));
});
spannableString
.
setSpan
(
new
ForegroundColorSpan
(
getResources
().
getColor
(
R
.
color
.
bg_button
)),
0
,
5
,
Spanned
.
SPAN_EXCLUSIVE_EXCLUSIVE
);
mBind
.
notice
.
setText
(
spannableString
);
mBind
.
recyclerView
.
setOnItemClickListener
(
new
OnItemClickListener
<
Spu
,
ActivityServerListBinding
>()
{
mBind
.
recyclerView
.
setOnItemClickListener
(
new
OnItemClickListener
<
Spu
,
ActivityServerListBinding
>()
{
@Override
@Override
public
void
OnItemClick
(
Spu
item
,
ActivityServerListBinding
bind
)
{
public
void
OnItemClick
(
Spu
item
,
ActivityServerListBinding
bind
)
{
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/java/com/dayu/order/ui/activity/SopWebViewActivity.java
View file @
bd931238
...
@@ -21,11 +21,15 @@ import com.dayu.order.api.protocol.Spu;
...
@@ -21,11 +21,15 @@ import com.dayu.order.api.protocol.Spu;
import
com.dayu.order.common.OrderConstant
;
import
com.dayu.order.common.OrderConstant
;
import
com.dayu.provider.event.OrderState
;
import
com.dayu.provider.event.OrderState
;
import
com.dayu.utils.ProgressUtil
;
import
com.dayu.utils.ProgressUtil
;
import
com.dayu.utils.SelectPicUtils
;
import
com.dayu.utils.ToastUtils
;
import
com.dayu.utils.ToastUtils
;
import
com.dayu.utils.UserManager
;
import
com.dayu.utils.UserManager
;
import
com.github.lzyzsd.jsbridge.BridgeHandler
;
import
com.github.lzyzsd.jsbridge.BridgeHandler
;
import
com.github.lzyzsd.jsbridge.BridgeWebView
;
import
com.github.lzyzsd.jsbridge.BridgeWebView
;
import
com.github.lzyzsd.jsbridge.CallBackFunction
;
import
com.github.lzyzsd.jsbridge.CallBackFunction
;
import
com.luck.picture.lib.PictureSelector
;
import
com.luck.picture.lib.config.PictureConfig
;
import
com.luck.picture.lib.entity.LocalMedia
;
import
org.greenrobot.eventbus.EventBus
;
import
org.greenrobot.eventbus.EventBus
;
import
org.json.JSONException
;
import
org.json.JSONException
;
...
@@ -33,6 +37,7 @@ import org.json.JSONObject;
...
@@ -33,6 +37,7 @@ import org.json.JSONObject;
import
java.io.File
;
import
java.io.File
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.List
;
import
static
com
.
dayu
.
order
.
common
.
OrderConstant
.
ORDER_SOP_FINISH
;
import
static
com
.
dayu
.
order
.
common
.
OrderConstant
.
ORDER_SOP_FINISH
;
...
@@ -77,7 +82,7 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
...
@@ -77,7 +82,7 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
mWebView
.
setLayoutParams
(
new
LinearLayout
.
LayoutParams
(
mWebView
.
setLayoutParams
(
new
LinearLayout
.
LayoutParams
(
LinearLayout
.
LayoutParams
.
MATCH_PARENT
,
LinearLayout
.
LayoutParams
.
MATCH_PARENT
));
LinearLayout
.
LayoutParams
.
MATCH_PARENT
,
LinearLayout
.
LayoutParams
.
MATCH_PARENT
));
mBind
.
llWeb
.
addView
(
mWebView
);
mBind
.
llWeb
.
addView
(
mWebView
);
mBind
.
tvTitle
.
setText
(
"SOP"
);
mBind
.
tvTitle
.
setText
(
getString
(
R
.
string
.
sop_title
)
);
initWebView
();
initWebView
();
}
}
...
@@ -128,12 +133,14 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
...
@@ -128,12 +133,14 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
}
}
public
void
openFileChooser
(
ValueCallback
<
Uri
>
uploadMsg
)
{
public
void
openFileChooser
(
ValueCallback
<
Uri
>
uploadMsg
)
{
openFileChooserImpl
(
uploadMsg
);
mUploadMessage
=
uploadMsg
;
SelectPicUtils
.
selectPic
(
mActivity
,
1
);
}
}
@Override
@Override
public
boolean
onShowFileChooser
(
WebView
webView
,
ValueCallback
<
Uri
[]>
uploadMsg
,
FileChooserParams
fileChooserParams
)
{
public
boolean
onShowFileChooser
(
WebView
webView
,
ValueCallback
<
Uri
[]>
uploadMsg
,
FileChooserParams
fileChooserParams
)
{
openFileChooserImplForAndroid5
(
uploadMsg
);
uploadMessageAboveL
=
uploadMsg
;
SelectPicUtils
.
selectPic
(
mActivity
,
1
);
return
true
;
return
true
;
}
}
...
@@ -153,12 +160,10 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
...
@@ -153,12 +160,10 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
}
else
{
}
else
{
mWebView
.
loadUrl
(
Constants
.
WEB_SOP_DETAIL
);
mWebView
.
loadUrl
(
Constants
.
WEB_SOP_DETAIL
);
}
}
}
else
{
}
else
{
mWebView
.
loadUrl
(
Constants
.
WEB_SOP
);
mWebView
.
loadUrl
(
Constants
.
WEB_SOP
);
}
}
JSONObject
jsonObject
=
new
JSONObject
();
JSONObject
jsonObject
=
new
JSONObject
();
try
{
try
{
jsonObject
.
put
(
"id"
,
mOrderId
);
jsonObject
.
put
(
"id"
,
mOrderId
);
...
@@ -240,16 +245,29 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
...
@@ -240,16 +245,29 @@ public class SopWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
*/
*/
@Override
@Override
protected
void
onActivityResult
(
int
requestCode
,
int
resultCode
,
Intent
intent
)
{
protected
void
onActivityResult
(
int
requestCode
,
int
resultCode
,
Intent
intent
)
{
if
(
requestCode
==
RESULT_CODE
)
{
// if (requestCode == RESULT_CODE) {
onActivityResultBelowL
(
intent
,
resultCode
);
// onActivityResultBelowL(intent, resultCode);
}
else
if
(
requestCode
==
RESULT_CODE_FOR_Lollipop
)
{
// } else if (requestCode == RESULT_CODE_FOR_Lollipop) {
onActivityResultAboveL
(
intent
,
resultCode
);
// onActivityResultAboveL(intent, resultCode);
// }
if
(
resultCode
==
RESULT_OK
&&
requestCode
==
PictureConfig
.
CHOOSE_REQUEST
)
{
List
<
LocalMedia
>
list
=
PictureSelector
.
obtainMultipleResult
(
intent
);
Uri
uri
=
null
;
if
(
list
!=
null
)
{
uri
=
Uri
.
fromFile
(
new
File
(
list
.
get
(
0
).
getCompressPath
()));
}
if
(
uploadMessageAboveL
!=
null
)
{
uploadMessageAboveL
.
onReceiveValue
(
new
Uri
[]{
uri
});
}
else
if
(
mUploadMessage
!=
null
)
{
mUploadMessage
.
onReceiveValue
(
uri
);
}
}
}
}
}
/**
/**
* 5.0 L 以下 上传图片成功后的回调
* 5.0 L 以下 上传图片成功后的回调
*/
*/
public
void
onActivityResultBelowL
(
Intent
intent
,
int
resultCode
)
{
public
void
onActivityResultBelowL
(
Intent
intent
,
int
resultCode
)
{
if
(
null
==
mUploadMessage
)
if
(
null
==
mUploadMessage
)
return
;
return
;
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/drawable-hdpi/icon_scan.png
0 → 100644
View file @
bd931238
638 Bytes
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/drawable-xhdpi/icon_scan.png
0 → 100644
View file @
bd931238
759 Bytes
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/drawable-xxhdpi/icon_scan.png
0 → 100644
View file @
bd931238
1.1 KB
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/drawable-xxxhdpi/icon_scan.png
0 → 100644
View file @
bd931238
1.49 KB
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/layout/activity_multi_process_order.xml
View file @
bd931238
...
@@ -145,8 +145,8 @@
...
@@ -145,8 +145,8 @@
android:layout_marginLeft=
"90dp"
android:layout_marginLeft=
"90dp"
android:layout_toRightOf=
"@id/text_two_text"
android:layout_toRightOf=
"@id/text_two_text"
android:background=
"@null"
android:background=
"@null"
android:maxEms=
"50"
android:hint=
"@string/order_brand_name"
android:hint=
"@string/order_brand_name"
android:maxEms=
"50"
android:text=
"@={presenter.mBrandName}"
android:text=
"@={presenter.mBrandName}"
android:textColor=
"@color/default_text_color"
android:textColor=
"@color/default_text_color"
android:textSize=
"@dimen/sp_15"
/>
android:textSize=
"@dimen/sp_15"
/>
...
@@ -192,18 +192,19 @@
...
@@ -192,18 +192,19 @@
style=
"@style/line"
style=
"@style/line"
android:layout_below=
"@id/rl_verion"
/>
android:layout_below=
"@id/rl_verion"
/>
<
Relative
Layout
<
Linear
Layout
android:id=
"@+id/rl_serial_num"
android:id=
"@+id/rl_serial_num"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"@dimen/dp_54"
android:layout_height=
"@dimen/dp_54"
android:layout_below=
"@id/line_version"
android:layout_below=
"@id/line_version"
android:background=
"@color/cl_white"
>
android:background=
"@color/cl_white"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
>
<TextView
<TextView
android:id=
"@+id/tv_serial_num"
android:id=
"@+id/tv_serial_num"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"@dimen/dp_13"
android:layout_marginLeft=
"@dimen/dp_13"
android:text=
"@string/order_serail"
android:text=
"@string/order_serail"
android:textColor=
"@color/cl_home_title_text_color"
android:textColor=
"@color/cl_home_title_text_color"
...
@@ -212,8 +213,6 @@
...
@@ -212,8 +213,6 @@
<TextView
<TextView
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_toRightOf=
"@id/tv_serial_num"
android:text=
"*"
android:text=
"*"
android:textColor=
"#F74848"
android:textColor=
"#F74848"
android:textSize=
"@dimen/sp_15"
android:textSize=
"@dimen/sp_15"
...
@@ -221,18 +220,24 @@
...
@@ -221,18 +220,24 @@
<EditText
<EditText
android:id=
"@+id/et_serial_num"
android:id=
"@+id/et_serial_num"
android:layout_width=
"
match_parent
"
android:layout_width=
"
0dp
"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"76dp"
android:layout_marginLeft=
"75dp"
android:layout_weight=
"1"
android:layout_toRightOf=
"@id/tv_serial_num"
android:background=
"@null"
android:background=
"@null"
android:maxEms=
"50"
android:hint=
"@string/order_serail_hint"
android:hint=
"@string/order_serail_hint"
android:maxEms=
"50"
android:text=
"@={presenter.mSn}"
android:text=
"@={presenter.mSn}"
android:textColor=
"@color/default_text_color"
android:textColor=
"@color/default_text_color"
android:textSize=
"@dimen/sp_15"
/>
android:textSize=
"@dimen/sp_15"
/>
</RelativeLayout>
<ImageView
android:id=
"@+id/scan"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginRight=
"15dp"
android:src=
"@drawable/icon_scan"
/>
</LinearLayout>
<ImageView
<ImageView
android:id=
"@+id/line_serial"
android:id=
"@+id/line_serial"
...
@@ -307,9 +312,9 @@
...
@@ -307,9 +312,9 @@
android:background=
"@drawable/subscribe_time_shape"
android:background=
"@drawable/subscribe_time_shape"
android:gravity=
"top"
android:gravity=
"top"
android:hint=
"@string/order_hint"
android:hint=
"@string/order_hint"
android:maxEms=
"200"
android:paddingLeft=
"@dimen/dp_13"
android:paddingLeft=
"@dimen/dp_13"
android:paddingTop=
"@dimen/dp_11"
android:paddingTop=
"@dimen/dp_11"
android:maxEms=
"200"
android:text=
"@={presenter.mInfo}"
android:text=
"@={presenter.mInfo}"
android:textColor=
"@color/cl_home_title_text_color"
android:textColor=
"@color/cl_home_title_text_color"
android:textColorHint=
"@color/cl_selector_hui"
android:textColorHint=
"@color/cl_selector_hui"
...
@@ -372,8 +377,8 @@
...
@@ -372,8 +377,8 @@
android:layout_width=
"60dp"
android:layout_width=
"60dp"
android:layout_height=
"60dp"
android:layout_height=
"60dp"
android:layout_alignParentRight=
"true"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"10dp"
android:layout_marginRight=
"10dp"
android:layout_marginTop=
"350dp"
android:background=
"@drawable/tab_blue_react"
android:background=
"@drawable/tab_blue_react"
android:gravity=
"center"
android:gravity=
"center"
android:onClick=
"@{()->presenter.dumpToServerInstruction()}"
android:onClick=
"@{()->presenter.dumpToServerInstruction()}"
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/layout/activity_server_info.xml
View file @
bd931238
...
@@ -43,12 +43,24 @@
...
@@ -43,12 +43,24 @@
style=
"@style/card_line"
style=
"@style/card_line"
android:layout_below=
"@+id/title_back"
/>
android:layout_below=
"@+id/title_back"
/>
<TextView
android:id=
"@+id/notice"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@+id/line"
android:layout_marginBottom=
"13dp"
android:layout_marginLeft=
"@dimen/dp_15"
android:layout_marginTop=
"13dp"
android:textColor=
"@color/default_text_color"
android:textSize=
"12sp"
android:visibility=
"@{presenter.mCanProcess==2?View.VISIBLE:View.GONE}"
/>
<com.dayu.widgets.LRecyclerView
<com.dayu.widgets.LRecyclerView
android:id=
"@+id/recyclerView"
android:id=
"@+id/recyclerView"
setPresenter=
"@{presenter}"
setPresenter=
"@{presenter}"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_height=
"match_parent"
android:layout_below=
"@+id/
lin
e"
android:layout_below=
"@+id/
notic
e"
android:layout_marginBottom=
"@dimen/dp_50"
android:layout_marginBottom=
"@dimen/dp_50"
app:headType=
"@layout/recycler_server_info_header"
app:headType=
"@layout/recycler_server_info_header"
app:itemType=
"@layout/item_server_info"
/>
app:itemType=
"@layout/item_server_info"
/>
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/layout/activity_server_list_recycle.xml
View file @
bd931238
...
@@ -39,21 +39,32 @@
...
@@ -39,21 +39,32 @@
android:onClick=
"@{()->presenter.callPhone()}"
android:onClick=
"@{()->presenter.callPhone()}"
android:text=
"@string/company_mobile"
android:text=
"@string/company_mobile"
android:textColor=
"#3faafc"
android:textColor=
"#3faafc"
android:
visibility=
"@{presenter.mIsShowPhone?View.VISIBLE:View.GONE}
"
android:
textSize=
"@dimen/dp_13.3
"
android:
textSize=
"@dimen/dp_13.3
"
/>
android:
visibility=
"@{presenter.mIsShowPhone?View.VISIBLE:View.GONE}
"
/>
</RelativeLayout>
</RelativeLayout>
<ImageView
style=
"@style/card_line"
/>
<ImageView
style=
"@style/card_line"
/>
<TextView
android:id=
"@+id/notice"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginBottom=
"13dp"
android:layout_marginLeft=
"@dimen/dp_15"
android:layout_marginTop=
"13dp"
android:textColor=
"@color/default_text_color"
android:textSize=
"12sp"
android:visibility=
'@{(presenter.mCanProcess && presenter.mIsShowProcess)?View.VISIBLE:View.GONE}'
/>
<com.dayu.widgets.LRecyclerView
<com.dayu.widgets.LRecyclerView
android:id=
"@+id/recyclerView"
android:id=
"@+id/recyclerView"
setPresenter=
"@{presenter}"
setPresenter=
"@{presenter}"
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:layout_height=
"match_parent"
android:layout_marginBottom=
"50dp"
android:background=
"#f5f5f5"
android:background=
"#f5f5f5"
app:itemType=
"@layout/activity_server_list"
app:itemType=
"@layout/activity_server_list"
app:needCoreAdapter=
"true"
app:needCoreAdapter=
"true"
android:layout_marginBottom=
"50dp"
app:needFoot=
"false"
/>
app:needFoot=
"false"
/>
</LinearLayout>
</LinearLayout>
...
@@ -64,8 +75,8 @@
...
@@ -64,8 +75,8 @@
android:layout_alignParentBottom=
"true"
android:layout_alignParentBottom=
"true"
android:background=
'@{presenter.mCanProcess?@color/bg_button:@color/cl_selector_hui}'
android:background=
'@{presenter.mCanProcess?@color/bg_button:@color/cl_selector_hui}'
android:clickable=
'@{presenter.mCanProcess?true:false}'
android:clickable=
'@{presenter.mCanProcess?true:false}'
android:onClick=
"@{()->presenter.dumpToProcess()}"
android:gravity=
"center"
android:gravity=
"center"
android:onClick=
"@{()->presenter.dumpToProcess()}"
android:text=
"@string/submit_order"
android:text=
"@string/submit_order"
android:textColor=
"@color/white"
android:textColor=
"@color/white"
android:visibility=
"@{presenter.mIsShowProcess?View.VISIBLE:View.GONE}"
/>
android:visibility=
"@{presenter.mIsShowProcess?View.VISIBLE:View.GONE}"
/>
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/layout/fragment_order_datails.xml
View file @
bd931238
...
@@ -493,36 +493,13 @@
...
@@ -493,36 +493,13 @@
android:textColor=
"@color/cl_home_title_text_color"
android:textColor=
"@color/cl_home_title_text_color"
android:textSize=
"@dimen/sp_13.3"
/>
android:textSize=
"@dimen/sp_13.3"
/>
<TextView
<TextView
android:id=
"@+id/t
hree_four_four
"
android:id=
"@+id/t
v_sn
"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@id/three_two_two"
android:layout_below=
"@id/three_two_two"
android:layout_marginLeft=
"@dimen/dp_13"
android:layout_marginLeft=
"@dimen/dp_13"
android:layout_marginTop=
"@dimen/dp_13"
android:layout_marginTop=
"@dimen/dp_13"
android:text=
"@string/quality_assurance_info"
android:textColor=
"@color/cl_order_text_one"
android:textSize=
"@dimen/sp_13.3"
/>
<TextView
android:id=
"@+id/tv_warranty_info"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@id/tv_model"
android:layout_marginLeft=
"@dimen/dp_10"
android:layout_marginTop=
"@dimen/dp_13"
android:layout_toRightOf=
"@id/three_four_four"
android:text=
"@{item.repairType == 1?@string/honai:@string/warranty}"
android:textColor=
"@color/cl_home_title_text_color"
android:textSize=
"@dimen/sp_13.3"
/>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@id/three_four_four"
android:layout_marginLeft=
"@dimen/dp_13"
android:layout_marginTop=
"@dimen/dp_13"
android:text=
"@string/sn_num"
android:text=
"@string/sn_num"
android:textColor=
"@color/cl_order_text_one"
android:textColor=
"@color/cl_order_text_one"
android:textSize=
"@dimen/sp_13.3"
/>
android:textSize=
"@dimen/sp_13.3"
/>
...
@@ -531,10 +508,10 @@
...
@@ -531,10 +508,10 @@
android:id=
"@+id/tv_sn_code"
android:id=
"@+id/tv_sn_code"
android:layout_width=
"wrap_content"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@id/three_
four_four
"
android:layout_below=
"@id/three_
two_two
"
android:layout_marginLeft=
"@dimen/dp_10"
android:layout_marginLeft=
"@dimen/dp_10"
android:layout_marginTop=
"@dimen/dp_13"
android:layout_marginTop=
"@dimen/dp_13"
android:layout_toRightOf=
"@id/t
hree_four_four
"
android:layout_toRightOf=
"@id/t
v_sn
"
android:text=
'@{!TextUtils.isEmpty(item.sn)?item.sn:@string/no_data}'
android:text=
'@{!TextUtils.isEmpty(item.sn)?item.sn:@string/no_data}'
android:textColor=
"@color/cl_home_title_text_color"
android:textColor=
"@color/cl_home_title_text_color"
android:textSize=
"@dimen/sp_13.3"
/>
android:textSize=
"@dimen/sp_13.3"
/>
...
...
This diff is collapsed.
Click to expand it.
orderCenter/src/main/res/layout/qr_code_layout.xml
View file @
bd931238
...
@@ -40,7 +40,7 @@
...
@@ -40,7 +40,7 @@
android:layout_gravity=
"center"
android:layout_gravity=
"center"
android:layout_marginTop=
"@dimen/dp_15"
android:layout_marginTop=
"@dimen/dp_15"
android:text=
"@string/scan_code_for_appointment"
android:text=
"@string/scan_code_for_appointment"
android:textSize=
"1
4
sp"
/>
android:textSize=
"1
5
sp"
/>
<TextView
<TextView
android:id=
"@+id/notice"
android:id=
"@+id/notice"
...
@@ -49,7 +49,7 @@
...
@@ -49,7 +49,7 @@
android:layout_gravity=
"center"
android:layout_gravity=
"center"
android:layout_marginTop=
"@dimen/dp_15"
android:layout_marginTop=
"@dimen/dp_15"
android:text=
"@string/scan_code_for_appointment_two"
android:text=
"@string/scan_code_for_appointment_two"
android:textSize=
"1
4
sp"
/>
android:textSize=
"1
5
sp"
/>
</LinearLayout>
</LinearLayout>
</LinearLayout>
</LinearLayout>
...
...
This diff is collapsed.
Click to expand it.
userCenter/src/main/java/com/dayu/usercenter/presenter/pwlogin/PwLoginPresenter.java
View file @
bd931238
...
@@ -26,15 +26,14 @@ import com.hyphenate.chat.EMClient;
...
@@ -26,15 +26,14 @@ import com.hyphenate.chat.EMClient;
* on 2017/11/8.
* on 2017/11/8.
*/
*/
public
class
PwLoginPresenter
extends
PwLoginContract
.
Presenter
{
public
class
PwLoginPresenter
extends
PwLoginContract
.
Presenter
{
private
String
mPhone
;
public
ObservableField
<
String
>
phoneNume
=
new
ObservableField
<>();
public
ObservableField
<
String
>
phoneNume
=
new
ObservableField
<>();
public
ObservableField
<
String
>
code
=
new
ObservableField
<>();
public
ObservableField
<
String
>
code
=
new
ObservableField
<>();
@Override
@Override
public
void
onAttached
()
{
public
void
onAttached
()
{
Bundle
bundle
=
mView
.
getBundle
();
Bundle
bundle
=
mView
.
getBundle
();
mP
hone
=
bundle
.
getString
(
UserConstant
.
PHONE
);
String
p
hone
=
bundle
.
getString
(
UserConstant
.
PHONE
);
phoneNume
.
set
(
mP
hone
);
phoneNume
.
set
(
p
hone
);
}
}
@Override
@Override
...
@@ -49,8 +48,8 @@ public class PwLoginPresenter extends PwLoginContract.Presenter {
...
@@ -49,8 +48,8 @@ public class PwLoginPresenter extends PwLoginContract.Presenter {
loginHx
(
userInfo
.
getHxAccount
(),
userInfo
.
getHxPwd
());
loginHx
(
userInfo
.
getHxAccount
(),
userInfo
.
getHxPwd
());
dumpAndSave
(
userInfo
);
dumpAndSave
(
userInfo
);
}
else
if
(
userInfo
.
getDetectStatus
()
==
2
||
userInfo
.
getDetectStatus
()
==
3
)
{
}
else
if
(
userInfo
.
getDetectStatus
()
==
2
||
userInfo
.
getDetectStatus
()
==
3
)
{
showLoginDialog
(
userInfo
);
UserManager
.
getInstance
().
saveUser
(
userInfo
);
UserManager
.
getInstance
().
saveUser
(
userInfo
);
showLoginDialog
(
userInfo
);
}
else
{
}
else
{
ToastUtils
.
showShortToast
(
UIUtils
.
getString
(
R
.
string
.
login_faile
));
ToastUtils
.
showShortToast
(
UIUtils
.
getString
(
R
.
string
.
login_faile
));
}
}
...
...
This diff is collapsed.
Click to expand it.
userCenter/src/main/java/com/dayu/usercenter/presenter/smslogin/SmsLoginPresenter.java
View file @
bd931238
...
@@ -59,8 +59,8 @@ public class SmsLoginPresenter extends SmsLoginContract.Presenter {
...
@@ -59,8 +59,8 @@ public class SmsLoginPresenter extends SmsLoginContract.Presenter {
loginHx
(
userInfo
.
getHxAccount
(),
userInfo
.
getHxPwd
());
loginHx
(
userInfo
.
getHxAccount
(),
userInfo
.
getHxPwd
());
dumpAndSave
(
userInfo
);
dumpAndSave
(
userInfo
);
}
else
if
(
userInfo
.
getDetectStatus
()
==
2
||
userInfo
.
getDetectStatus
()
==
3
)
{
}
else
if
(
userInfo
.
getDetectStatus
()
==
2
||
userInfo
.
getDetectStatus
()
==
3
)
{
showLoginDialog
(
userInfo
);
UserManager
.
getInstance
().
saveUser
(
userInfo
);
UserManager
.
getInstance
().
saveUser
(
userInfo
);
showLoginDialog
(
userInfo
);
}
else
{
}
else
{
ToastUtils
.
showShortToast
(
UIUtils
.
getString
(
R
.
string
.
login_faile
));
ToastUtils
.
showShortToast
(
UIUtils
.
getString
(
R
.
string
.
login_faile
));
}
}
...
...
This diff is collapsed.
Click to expand it.
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