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
3b9216cf
authored
Oct 14, 2020
by
mReturn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sop操作页添加小绿人辅助工具功能
parent
8394f1b2
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
57 additions
and
15 deletions
orderCenter/src/main/java/com/dayu/order/api/protocol/Order.java
orderCenter/src/main/java/com/dayu/order/common/OrderConstant.java
orderCenter/src/main/java/com/dayu/order/ui/activity/OrderDetailsActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/SopLocalActivity.java
orderCenter/src/main/java/com/dayu/order/ui/adapter/OrderAdapter.java
orderCenter/src/main/res/layout/activity_sop_local.xml
orderCenter/src/main/java/com/dayu/order/api/protocol/Order.java
View file @
3b9216cf
...
...
@@ -62,7 +62,15 @@ public class Order implements Serializable{
private
String
settlementDate
;
private
int
version
;
private
String
greenManStatus
;
private
int
createProviderId
;
public
int
getCreateProviderId
()
{
return
createProviderId
;
}
public
void
setCreateProviderId
(
int
createProviderId
)
{
this
.
createProviderId
=
createProviderId
;
}
public
String
getGreenManStatus
()
{
return
greenManStatus
;
...
...
orderCenter/src/main/java/com/dayu/order/common/OrderConstant.java
View file @
3b9216cf
...
...
@@ -205,4 +205,5 @@ public class OrderConstant {
public
static
final
String
COMMENT_URL
=
"/api-message/"
+
"leaveMessage"
;
public
static
List
<
SopListBean
>
sopListData
;
public
static
boolean
isXlrOrder
;
//是否是小绿人的工单
}
orderCenter/src/main/java/com/dayu/order/ui/activity/OrderDetailsActivity.java
View file @
3b9216cf
...
...
@@ -10,6 +10,7 @@ import com.dayu.base.ui.activity.BaseActivity;
import
com.dayu.common.Constants
;
import
com.dayu.order.R
;
import
com.dayu.order.api.protocol.OrderDetail
;
import
com.dayu.order.common.OrderConstant
;
import
com.dayu.order.databinding.ActivityOrderDetailsBinding
;
import
com.dayu.order.presenter.orderdetail.OrderDetailContract
;
import
com.dayu.order.presenter.orderdetail.OrderDetailPresenter
;
...
...
@@ -101,6 +102,7 @@ public class OrderDetailsActivity extends BaseActivity<OrderDetailPresenter, Act
initBtn
();
addFragment
();
OrderConstant
.
isXlrOrder
=
detail
.
getCreateProviderId
()
==
Constants
.
XLR_PID
;
mBind
.
llHelpTool
.
setVisibility
(
detail
.
getCreateProviderId
()
==
Constants
.
XLR_PID
?
View
.
VISIBLE
:
View
.
GONE
);
mBind
.
llHelpTool
.
setOnClickListener
(
v
->{
CommonUtils
.
launchProgram
(
this
,
"gh_476595064efb"
,
"pages/repair/repair"
);
...
...
orderCenter/src/main/java/com/dayu/order/ui/activity/SopLocalActivity.java
View file @
3b9216cf
...
...
@@ -97,6 +97,10 @@ public class SopLocalActivity extends BaseActivity<SImplePresenter, ActivitySopL
setInitStatus
();
// showToast("edit: "+canEdit);
// showToast("id: "+id);
mBind
.
llHelpTool
.
setVisibility
(
OrderConstant
.
isXlrOrder
?
View
.
VISIBLE
:
View
.
GONE
);
mBind
.
llHelpTool
.
setOnClickListener
(
v
->
{
CommonUtils
.
launchProgram
(
this
,
"gh_476595064efb"
,
"pages/repair/repair"
);
});
mBind
.
titleBack
.
setOnClickListener
(
view
->
{
EventBus
.
getDefault
().
post
(
new
FinishSopEvent
());
});
...
...
@@ -173,14 +177,14 @@ public class SopLocalActivity extends BaseActivity<SImplePresenter, ActivitySopL
//根据是否已设置sop判断布局显示
private
void
setAnswerStatuView
()
{
if
(
currentSop
.
getRadioOption
()
!=
2
)
{
if
(
currentSop
.
getRadioOption
()
!=
2
)
{
mBind
.
tvRadio
.
setVisibility
(
View
.
GONE
);
mBind
.
rgSop
.
setVisibility
(
View
.
GONE
);
}
else
{
}
else
{
mBind
.
tvRadio
.
setVisibility
(
View
.
VISIBLE
);
mBind
.
rgSop
.
setVisibility
(
View
.
VISIBLE
);
}
if
(
currentSop
.
getTextOption
()
!=
2
||
TextUtils
.
isEmpty
(
currentSop
.
getTextResult
())
&&
!
canEdit
)
{
if
(
currentSop
.
getTextOption
()
!=
2
||
TextUtils
.
isEmpty
(
currentSop
.
getTextResult
())
&&
!
canEdit
)
{
mBind
.
tvRemark
.
setVisibility
(
View
.
GONE
);
mBind
.
edtRemark
.
setVisibility
(
View
.
GONE
);
}
else
{
...
...
@@ -190,7 +194,7 @@ public class SopLocalActivity extends BaseActivity<SImplePresenter, ActivitySopL
}
mImages
=
(
ArrayList
<
String
>)
CommonUtils
.
string2ListUrl
(
currentSop
.
getPhotoResult
());
mVideos
=
(
ArrayList
<
String
>)
CommonUtils
.
string2ListUrl
(
currentSop
.
getVideoResult
());
if
(
currentSop
.
getPhotoOption
()
!=
2
||
mImages
.
size
()
==
0
&&
mVideos
.
size
()
==
0
&&
!
canEdit
)
{
if
(
currentSop
.
getPhotoOption
()
!=
2
||
mImages
.
size
()
==
0
&&
mVideos
.
size
()
==
0
&&
!
canEdit
)
{
mBind
.
llPhoto
.
setVisibility
(
View
.
GONE
);
mBind
.
photo
.
setVisibility
(
View
.
GONE
);
}
else
{
...
...
@@ -218,15 +222,15 @@ public class SopLocalActivity extends BaseActivity<SImplePresenter, ActivitySopL
mBind
.
jzVideo
.
setVisibility
(
View
.
GONE
);
mBind
.
ivExample
.
setVisibility
(
View
.
VISIBLE
);
GlideImageLoader
.
loadFit
(
this
,
mBind
.
ivExample
,
example
);
mBind
.
ivExample
.
setOnClickListener
(
v
->
{
ImgGalleryActivty
.
launch
(
this
,
example
);
mBind
.
ivExample
.
setOnClickListener
(
v
->
{
ImgGalleryActivty
.
launch
(
this
,
example
);
});
}
}
//保存数据
private
void
preSaveData
()
{
if
(!
canEdit
)
{
if
(!
canEdit
)
{
toNext
();
return
;
}
...
...
orderCenter/src/main/java/com/dayu/order/ui/adapter/OrderAdapter.java
View file @
3b9216cf
...
...
@@ -481,6 +481,7 @@ public class OrderAdapter extends CoreAdapter<Order, FragmentOrderdoingItemBindi
Spu
spu
=
order
.
getSpus
().
get
(
0
);
if
(
spu
.
getGoodNum
()
==
1
)
{
mPresenter
.
sopOrderVersion
=
order
.
getVersion
();
OrderConstant
.
isXlrOrder
=
order
.
getCreateProviderId
()
==
Constants
.
XLR_PID
;
if
(
order
.
getKaCompanyId
()
==
null
)
{
mPresenter
.
getServerList
(
spu
.
getId
(),
-
1
);
}
else
{
...
...
orderCenter/src/main/res/layout/activity_sop_local.xml
View file @
3b9216cf
...
...
@@ -23,6 +23,32 @@
/>
<LinearLayout
android:id=
"@+id/ll_help_tool"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginRight=
"15dp"
android:gravity=
"center_vertical"
android:orientation=
"horizontal"
android:visibility=
"gone"
>
<ImageView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:src=
"@drawable/ic_xiaolvren"
/>
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"3dp"
android:text=
"@string/help_tool"
android:textColor=
"@color/text_common_blue"
android:textSize=
"14sp"
/>
</LinearLayout>
</RelativeLayout>
<android.support.v4.widget.NestedScrollView
...
...
@@ -33,10 +59,10 @@
<LinearLayout
android:id=
"@+id/ll_content"
android:visibility=
"gone"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:orientation=
"vertical"
>
android:orientation=
"vertical"
android:visibility=
"gone"
>
<LinearLayout
...
...
@@ -53,6 +79,7 @@
android:layout_height=
"wrap_content"
android:text=
""
android:textSize=
"16sp"
/>
<TextView
style=
"@style/common_text_style"
android:layout_width=
"wrap_content"
...
...
@@ -152,22 +179,22 @@
android:layout_marginRight=
"15dp"
/>
<TextView
android:visibility=
"gone"
android:id=
"@+id/tv_example"
style=
"@style/common_text_style"
android:layout_marginLeft=
"15dp"
android:layout_marginTop=
"20dp"
android:text=
"示例:"
/>
android:text=
"示例:"
android:visibility=
"gone"
/>
<RelativeLayout
android:visibility=
"gone"
android:id=
"@+id/rl_example"
android:layout_width=
"match_parent"
android:layout_height=
"160dp"
android:layout_marginLeft=
"15dp"
android:layout_marginTop=
"10dp"
android:layout_marginRight=
"15dp"
android:layout_marginBottom=
"5dp"
>
android:layout_marginBottom=
"5dp"
android:visibility=
"gone"
>
<cn.jzvd.JzvdStd
android:id=
"@+id/jz_video"
...
...
@@ -179,9 +206,8 @@
android:id=
"@+id/iv_example"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:src=
"@drawable/icon_video_default"
android:background=
"@color/color_53"
/>
android:src=
"@drawable/icon_video_default"
/>
</RelativeLayout>
</LinearLayout>
...
...
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