Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
ShenghuoquanBusiness
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bp
ShenghuoquanBusiness
Commits
02814fc0
Commit
02814fc0
authored
Jun 15, 2021
by
yinjiacheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add 商户基本信息-生活号企业认证信息
parent
3aa39181
Changes
12
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
311 additions
and
30 deletions
+311
-30
dimens.xml
CommonLib/Common/src/main/res/values/dimens.xml
+1
-0
GetLifeAccountInfoByIdBean.kt
...n/newscontent/http/httpbean/GetLifeAccountInfoByIdBean.kt
+12
-5
MerchantAuthInfoActivity.kt
...huoquan/newscontent/ui/center/MerchantAuthInfoActivity.kt
+51
-18
MerchantInfoActivity.kt
...henghuoquan/newscontent/ui/center/MerchantInfoActivity.kt
+1
-1
LifeAccountEnterpriseAuthInfoView.kt
...n/newscontent/widget/LifeAccountEnterpriseAuthInfoView.kt
+109
-0
LifeAccountLabelView.kt
...n/shenghuoquan/newscontent/widget/LifeAccountLabelView.kt
+1
-1
LifeAccountPersonalAuthInfoView.kt
...uan/newscontent/widget/LifeAccountPersonalAuthInfoView.kt
+1
-1
shape_life_account_status_open.xml
.../src/main/res/drawable/shape_life_account_status_open.xml
+9
-0
activity_merchant_auth_info.xml
...ntent/src/main/res/layout/activity_merchant_auth_info.xml
+11
-2
view_life_account_enterprise_auth_info.xml
...ain/res/layout/view_life_account_enterprise_auth_info.xml
+109
-0
colors.xml
Components/newscontent/src/main/res/values/colors.xml
+2
-0
strings.xml
Components/newscontent/src/main/res/values/strings.xml
+4
-2
No files found.
CommonLib/Common/src/main/res/values/dimens.xml
View file @
02814fc0
...
...
@@ -12,6 +12,7 @@
<dimen
name=
"sp16"
>
16sp
</dimen>
<dimen
name=
"sp18"
>
18sp
</dimen>
<dimen
name=
"sp20"
>
20sp
</dimen>
<dimen
name=
"sp23"
>
23sp
</dimen>
<dimen
name=
"sp24"
>
24sp
</dimen>
<dimen
name=
"sp40"
>
40sp
</dimen>
...
...
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/http/httpbean/GetLifeAccountInfoByIdBean.kt
View file @
02814fc0
...
...
@@ -14,19 +14,26 @@ class GetLifeAccountInfoByIdBean {
data class
Response
(
val
code
:
String
,
val
create_time
:
String
,
val
create_user_mobile
:
String
,
val
create_user_nick_name
:
String
,
val
full_name
:
String
,
val
id_card
:
String
,
val
enterprise_auth_record_id
:
Int
,
val
enterprise_auth_record_status
:
Int
,
val
id_type
:
Int
,
val
legal_id_card
:
String
,
val
legal_person
:
String
,
val
life_account_admin_id
:
Long
,
val
life_account_auth_status
:
Int
,
val
life_account_id
:
Long
,
val
life_account_name
:
String
,
val
life_account_origin
:
String
,
val
life_account_status
:
Int
,
val
life_account_type
:
Int
,
val
merchant_id
:
Int
,
val
name
:
String
,
val
shop_auditing_count
:
Int
,
val
shop_count
:
Int
,
val
shop_totel_count
:
Int
,
val
update_time
:
String
,
val
occupation
:
String
,
val
legal_person
:
String
val
mobile
:
String
)
:
Serializable
}
\ No newline at end of file
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/ui/center/MerchantAuthInfoActivity.kt
View file @
02814fc0
package
com.yidian.shenghuoquan.newscontent.ui.center
import
android.os.Bundle
import
androidx.core.view.isVisible
import
com.orhanobut.hawk.Hawk
import
com.yidian.common.HawkConfig
import
com.yidian.common.XRouterPathConstants
import
com.yidian.common.base.BaseActivity
import
com.yidian.shenghuoquan.newscontent.constant.Constant
import
com.yidian.shenghuoquan.newscontent.databinding.ActivityMerchantAuthInfoBinding
import
com.yidian.shenghuoquan.newscontent.http.httpbean.GetLifeAccountInfoByIdBean
...
...
@@ -13,11 +17,20 @@ import com.yidian.shenghuoquan.newscontent.http.httpbean.GetLifeAccountInfoByIdB
*/
class
MerchantAuthInfoActivity
:
BaseActivity
<
ActivityMerchantAuthInfoBinding
>()
{
companion
object
{
const
val
EXTRA_LIFE_ACCOUNT_INFO
=
"life_account_info"
}
/**
* 生活号详情
*/
private
val
lifeAccountInfo
by
lazy
{
intent
.
getSerializableExtra
(
XRouterPathConstants
.
ParamsKey
)
?.
let
{
intent
.
getSerializableExtra
(
XRouterPathConstants
.
ParamsKey
)
?.
let
{
params
->
(
params
as
HashMap
<*,
*>)[
EXTRA_LIFE_ACCOUNT_INFO
]
?.
let
{
it
as
GetLifeAccountInfoByIdBean
.
Response
}
}
}
override
fun
createViewBinding
():
ActivityMerchantAuthInfoBinding
{
return
ActivityMerchantAuthInfoBinding
.
inflate
(
layoutInflater
)
...
...
@@ -29,25 +42,45 @@ class MerchantAuthInfoActivity : BaseActivity<ActivityMerchantAuthInfoBinding>()
override
fun
init
(
savedInstanceState
:
Bundle
?)
{
super
.
init
(
savedInstanceState
)
initView
()
initListener
()
initData
()
}
private
fun
initView
()
{
}
private
fun
initListener
()
{
}
private
fun
initData
()
{
when
(
lifeAccountInfo
?.
id_type
)
{
Constant
.
TYPE_AUTH_PERSONAL
->
{
// 个人认证
viewBind
.
ivPersonAuthInfo
.
isVisible
=
true
viewBind
.
ivPersonAuthInfo
.
fillAuthInfo
(
lifeAccountInfo
?.
occupation
,
lifeAccountInfo
?.
legal_person
,
lifeAccountInfo
?.
id_card
,
lifeAccountInfo
?.
create_user_mobile
lifeAccountInfo
?.
legal_
id_card
,
Hawk
.
get
(
HawkConfig
.
Mobile
)
)
}
Constant
.
TYPE_AUTH_INDIVIDUAL_BUSINESS
->
{
// 个人工商户认证
viewBind
.
ivEnterpriseAuthInfo
.
isVisible
=
true
viewBind
.
ivEnterpriseAuthInfo
.
fillAuthInfo
(
lifeAccountInfo
?.
id_type
,
lifeAccountInfo
?.
enterprise_auth_record_status
,
lifeAccountInfo
?.
name
,
lifeAccountInfo
?.
code
,
lifeAccountInfo
?.
legal_person
,
lifeAccountInfo
?.
legal_id_card
)
}
Constant
.
TYPE_AUTH_COMMON_ENTERPRISE
->
{
// 普通企业认证
viewBind
.
ivEnterpriseAuthInfo
.
isVisible
=
true
viewBind
.
ivEnterpriseAuthInfo
.
fillAuthInfo
(
lifeAccountInfo
?.
id_type
,
lifeAccountInfo
?.
enterprise_auth_record_status
,
lifeAccountInfo
?.
name
,
lifeAccountInfo
?.
code
,
lifeAccountInfo
?.
legal_person
,
lifeAccountInfo
?.
legal_id_card
)
}
}
}
}
\ No newline at end of file
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/ui/center/MerchantInfoActivity.kt
View file @
02814fc0
...
...
@@ -196,7 +196,7 @@ class MerchantInfoActivity : BaseActivity<ActivityMerchantInfoBinding>(), View.O
// 跳转认证详情页
XPageManager
.
push
(
XRouterPathConstants
.
MERCHANT_AUTH_INFO
,
hashMapOf
(
Pair
(
XRouterPathConstants
.
ParamsKey
,
result
))
hashMapOf
(
Pair
(
MerchantAuthInfoActivity
.
EXTRA_LIFE_ACCOUNT_INFO
,
result
))
)
}
...
...
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/widget/LifeAccountEnterpriseAuthInfoView.kt
0 → 100644
View file @
02814fc0
package
com.yidian.shenghuoquan.newscontent.widget
import
android.content.Context
import
android.util.AttributeSet
import
android.view.View
import
androidx.constraintlayout.widget.ConstraintLayout
import
androidx.core.content.ContextCompat
import
com.yidian.shenghuoquan.newscontent.R
import
com.yidian.shenghuoquan.newscontent.constant.Constant
import
com.yidian.shenghuoquan.newscontent.databinding.ViewLifeAccountEnterpriseAuthInfoBinding
import
com.yidian.shenghuoquan.newscontent.utils.SensitiveInfoUtil
/**
* author: yinjiacheng
* date: 6/15/21 4:43 PM
* description: 商户管理中心-基本信息-生活号企业认证信息
*/
class
LifeAccountEnterpriseAuthInfoView
@JvmOverloads
constructor
(
context
:
Context
,
attrs
:
AttributeSet
?
=
null
,
defStyle
:
Int
=
0
)
:
ConstraintLayout
(
context
,
attrs
,
defStyle
)
{
private
val
viewBinding
by
lazy
{
ViewLifeAccountEnterpriseAuthInfoBinding
.
bind
(
View
.
inflate
(
getContext
(),
R
.
layout
.
view_life_account_enterprise_auth_info
,
this
)
)
}
/**
* 填充认证信息
* @param authType 认证类型
* @param auditStatus 审核状态
* @param registrationName 公司名称
* @param registrationCode 统一社会信用代码
* @param realName 经营者姓名或法人姓名
* @param idCardNo 经营者身份证号或法人身份证号
*/
fun
fillAuthInfo
(
authType
:
Int
?,
auditStatus
:
Int
?,
registrationName
:
String
?,
registrationCode
:
String
?,
realName
:
String
?,
idCardNo
:
String
?
)
{
viewBinding
.
tvContentRegistrationName
.
text
=
registrationName
viewBinding
.
tvContentRegistrationCode
.
text
=
registrationCode
viewBinding
.
tvContentManagerInfo
.
text
=
String
.
format
(
"%s %s"
,
realName
,
SensitiveInfoUtil
.
idCardNumEncrypt
(
idCardNo
.
toString
())
)
when
(
authType
)
{
Constant
.
TYPE_AUTH_INDIVIDUAL_BUSINESS
->
{
// 个体工商户
viewBinding
.
tvAuthType
.
text
=
resources
.
getText
(
R
.
string
.
enterprise_auth
)
viewBinding
.
tvTitleManagerInfo
.
text
=
resources
.
getText
(
R
.
string
.
operator_information
)
}
Constant
.
TYPE_AUTH_COMMON_ENTERPRISE
->
{
// 普通企业
viewBinding
.
tvAuthType
.
text
=
resources
.
getText
(
R
.
string
.
individual_business
)
viewBinding
.
tvTitleManagerInfo
.
text
=
resources
.
getText
(
R
.
string
.
legal_person_info
)
}
}
when
(
auditStatus
)
{
Constant
.
STATUS_AUDIT_UNDER
->
{
// 审核中
viewBinding
.
tvAuditStatus
.
text
=
resources
.
getText
(
R
.
string
.
under_audit
)
viewBinding
.
tvAuditStatus
.
setBackgroundResource
(
R
.
drawable
.
shape_life_account_status_audit
)
viewBinding
.
tvAuditStatus
.
setTextColor
(
ContextCompat
.
getColor
(
context
,
R
.
color
.
color_FFF26E3D
)
)
}
Constant
.
STATUS_AUDIT_PASS
->
{
// 审核通过(已开通)
viewBinding
.
tvAuditStatus
.
text
=
resources
.
getText
(
R
.
string
.
audit_pass
)
viewBinding
.
tvAuditStatus
.
setBackgroundResource
(
R
.
drawable
.
shape_life_account_status_open
)
viewBinding
.
tvAuditStatus
.
setTextColor
(
ContextCompat
.
getColor
(
context
,
R
.
color
.
color_FF6BB81F
)
)
}
Constant
.
STATUS_AUDIT_REJECT
->
{
// 审核驳回
viewBinding
.
tvAuditStatus
.
text
=
resources
.
getText
(
R
.
string
.
audit_reject
)
viewBinding
.
tvAuditStatus
.
setBackgroundResource
(
R
.
drawable
.
shape_life_account_status_reject
)
viewBinding
.
tvAuditStatus
.
setTextColor
(
ContextCompat
.
getColor
(
context
,
R
.
color
.
color_FFFF3A3A
)
)
}
}
}
}
\ No newline at end of file
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/widget/LifeAccountLabelView.kt
View file @
02814fc0
...
...
@@ -96,7 +96,7 @@ class LifeAccountLabelView @JvmOverloads constructor(
// 审核中
setBackgroundResource
(
R
.
drawable
.
shape_life_account_status_audit
)
setTextColor
(
ContextCompat
.
getColor
(
context
,
R
.
color
.
color_FFF26E3D
))
text
=
resources
.
getString
(
R
.
string
.
auth
_audit
)
text
=
resources
.
getString
(
R
.
string
.
under
_audit
)
}
STATUS_LIFE_ACCOUNT_REJECT
->
{
// 审核驳回
...
...
Components/newscontent/src/main/java/com/yidian/shenghuoquan/newscontent/widget/LifeAccountPersonalAuthInfoView.kt
View file @
02814fc0
...
...
@@ -10,7 +10,7 @@ import com.yidian.shenghuoquan.newscontent.databinding.ViewLifeAccountPersonalAu
/**
* author: yinjiacheng
* date: 6/15/21 10:48 AM
* description: 生活号个人认证信息
* description:
商户管理中心-基本信息-
生活号个人认证信息
*/
class
LifeAccountPersonalAuthInfoView
@JvmOverloads
constructor
(
context
:
Context
,
...
...
Components/newscontent/src/main/res/drawable/shape_life_account_status_open.xml
0 → 100644
View file @
02814fc0
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:shape=
"rectangle"
>
<solid
android:color=
"@color/color_FFE8F9D8"
/>
<corners
android:radius=
"21dp"
/>
</shape>
\ No newline at end of file
Components/newscontent/src/main/res/layout/activity_merchant_auth_info.xml
View file @
02814fc0
...
...
@@ -2,7 +2,8 @@
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
>
android:layout_height=
"match_parent"
android:background=
"@color/color_FFFFFFFF"
>
<com.yidian.shenghuoquan.newscontent.widget.CommonTopBarView
android:id=
"@+id/bv_top_bar"
...
...
@@ -11,14 +12,22 @@
app:CommonTopBarView_title_text=
"@string/life_account_auth_info"
app:layout_constraintTop_toTopOf=
"parent"
/>
<com.yidian.shenghuoquan.newscontent.widget.LifeAccountPersonalAuthInfoView
android:id=
"@+id/iv_person_auth_info"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp29"
android:visibility=
"gone"
app:layout_constraintEnd_toEndOf=
"parent"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/bv_top_bar"
/>
<com.yidian.shenghuoquan.newscontent.widget.LifeAccountEnterpriseAuthInfoView
android:id=
"@+id/iv_enterprise_auth_info"
android:layout_width=
"@dimen/dp302"
android:layout_height=
"@dimen/dp284"
android:visibility=
"gone"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/bv_top_bar"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
\ No newline at end of file
Components/newscontent/src/main/res/layout/view_life_account_enterprise_auth_info.xml
0 → 100644
View file @
02814fc0
<?xml version="1.0" encoding="utf-8"?>
<androidx.cardview.widget.CardView
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
>
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
android:padding=
"@dimen/dp19"
>
<TextView
android:id=
"@+id/tv_auth_type"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:includeFontPadding=
"false"
android:textColor=
"@color/color_333333"
android:textSize=
"@dimen/sp23"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toTopOf=
"parent"
/>
<TextView
android:id=
"@+id/tv_audit_status"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"@dimen/dp10"
android:includeFontPadding=
"false"
android:paddingStart=
"@dimen/dp6"
android:paddingTop=
"@dimen/dp1"
android:paddingEnd=
"@dimen/dp6"
android:paddingBottom=
"@dimen/dp1"
android:textColor=
"@color/color_333333"
android:textSize=
"@dimen/sp13"
app:layout_constraintBottom_toBottomOf=
"@id/tv_auth_type"
app:layout_constraintStart_toEndOf=
"@id/tv_auth_type"
app:layout_constraintTop_toTopOf=
"@id/tv_auth_type"
/>
<TextView
android:id=
"@+id/tv_title_registration_name"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp19"
android:includeFontPadding=
"false"
android:text=
"@string/company_name"
android:textColor=
"@color/color_999999"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_auth_type"
/>
<TextView
android:id=
"@+id/tv_content_registration_name"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp6"
android:includeFontPadding=
"false"
android:textColor=
"@color/color_333333"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_title_registration_name"
/>
<TextView
android:id=
"@+id/tv_title_registration_code"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp19"
android:includeFontPadding=
"false"
android:text=
"@string/credit_code"
android:textColor=
"@color/color_999999"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_content_registration_name"
/>
<TextView
android:id=
"@+id/tv_content_registration_code"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp6"
android:includeFontPadding=
"false"
android:textColor=
"@color/color_333333"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_title_registration_code"
/>
<TextView
android:id=
"@+id/tv_title_manager_info"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp19"
android:includeFontPadding=
"false"
android:text=
"@string/operator_information"
android:textColor=
"@color/color_999999"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_content_registration_code"
/>
<TextView
android:id=
"@+id/tv_content_manager_info"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginTop=
"@dimen/dp6"
android:includeFontPadding=
"false"
android:textColor=
"@color/color_333333"
android:textSize=
"@dimen/sp15"
app:layout_constraintStart_toStartOf=
"parent"
app:layout_constraintTop_toBottomOf=
"@id/tv_title_manager_info"
/>
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
\ No newline at end of file
Components/newscontent/src/main/res/values/colors.xml
View file @
02814fc0
...
...
@@ -58,4 +58,6 @@
<color
name=
"color_FFEBECEF"
>
#FFEBECEF
</color>
<color
name=
"color_FFE9EFFF"
>
#FFE9EFFF
</color>
<color
name=
"color_FFFFF3EE"
>
#FFFFF3EE
</color>
<color
name=
"color_FFE8F9D8"
>
#FFE8F9D8
</color>
<color
name=
"color_FF6BB81F"
>
#FF6BB81F
</color>
</resources>
\ No newline at end of file
Components/newscontent/src/main/res/values/strings.xml
View file @
02814fc0
...
...
@@ -129,7 +129,7 @@
<string
name=
"switch_life_account"
>
切换主体
</string>
<string
name=
"not_auth"
>
未认证
</string>
<string
name=
"auth_reject"
>
认证驳回
</string>
<string
name=
"
auth
_audit"
>
审核中
</string>
<string
name=
"
under
_audit"
>
审核中
</string>
<string
name=
"my_asset"
>
我的资产
</string>
<string
name=
"monthly_income"
>
当月收入
</string>
<string
name=
"wallet_balance"
>
钱包余额
</string>
...
...
@@ -143,7 +143,6 @@
<string
name=
"auth_apply_reject"
>
您的认证申请被驳回
</string>
<string
name=
"apply_auth_merchant_description"
>
通过即享更多曝光 · 权威认证 · 服务能力
</string>
<string
name=
"modify_auth"
>
修改认证
</string>
<string
name=
"my_staff"
>
我的员工
</string>
<string
name=
"manager_account_change_tips"
>
管理员账号替换后,原账户将无法操作生活号所有功能,同时将自动退出当前登录状态,新账号将继承原账号所有权益。
</string>
<string
name=
"manager_register_tips"
>
未注册生活圈的手机号,登录时将自动注册,且代表你已经同意《用户协议》《隐私政策》。
</string>
...
...
@@ -158,5 +157,8 @@
<string
name=
"modify_life_account_name"
>
修改名称
</string>
<string
name=
"save_life_account_name"
>
保存
</string>
<string
name=
"life_account_name_already_exist"
>
该名称已存在
</string>
<string
name=
"audit_reject"
>
审核驳回
</string>
<string
name=
"audit_pass"
>
已开通
</string>
<string
name=
"legal_person_info"
>
法人信息
</string>
</resources>
\ No newline at end of file
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