Commit c9a51baa authored by zhenghongbin's avatar zhenghongbin

Merge branch 'dev' of https://git.yidian-inc.com:8021/bp/ShenghuoquanBusiness into dev

* 'dev' of https://git.yidian-inc.com:8021/bp/ShenghuoquanBusiness:
  add 创建生活号页面
  update:企业认证成功页面资源统一
  add:企业认证成功页面
  update 友盟依赖
  update release包域名
  update 通过Uri获取filePath
  add umeng统计SDK app key添加注释
  add 营业执照OCR
  add umeng统计SDK app key添加
  update
parents fd712ce7 32d72954
......@@ -64,4 +64,5 @@ dependencies {
api "com.yidian.xarc:xevent:0.0.3"
// api project(':flutter')
api "com.yidian.xpage:xpagenative:0.0.1"
implementation files('libs/openDefault-10.10.0.aar')
}
\ No newline at end of file
......@@ -6,6 +6,7 @@ class AppConfig {
const val KUANGSHI_ALIVE_API_KEY = "32f9XIsReV4S15Ck_Sa3ky43XgAHUB9v"
const val KUANGSHI_SECRET = "usZbQYdI4PQeXhMftsRfHK2msj0DmSIl"
const val appid = "merchant-b"
......@@ -27,7 +28,7 @@ class AppConfig {
const val privacyPolicyStatement = "http://www.yidianzixun.com/landing_privacy?yidian_fs=2"
const val userProtocol = "http://www.yidianzixun.com/landing_agreement?yidian_fs=2"
const val UMAppKey = "60acaec453b67264990ecdc2"
const val UMAppKey = "60acaec453b67264990ecdc2"//umeng统计key注释
const val UMChannel = "ANDROID_CHANNEL"
const val UMType = "metro"
const val UMSecret = "8bb06c17a90d727c26bdd95b0e27a436"
......@@ -36,6 +37,7 @@ class AppConfig {
const val PUSH_GETUI_SUPPORT_MASK = 0x10000000
const val PUSH_PASS_THROGH_UNIQUE_MASK = 0x00000001
const val ZIXUN_PUSH_LEVEL = PUSH_XIAOMI_SUPPORT_MASK
const val PUSH_LEVEL = (PUSH_XIAOMI_SUPPORT_MASK or PUSH_UMENG_SUPPORT_MASK
or PUSH_GETUI_SUPPORT_MASK or PUSH_PASS_THROGH_UNIQUE_MASK)
}
......
......@@ -32,5 +32,6 @@ class XRouterPathConstants {
const val LIFE_ACCOUNT_IDENTITY = "/lifeAccountIdentity"
const val LIFE_ACCOUNT_AUTH = "/lifeAccountAuth"
const val ID_CARD_TEST = "/idCardTest"
const val LIFE_ACCOUNT_ENTERPRISE_CERTIFICATION = "/lifeAccountEnterpriseCertification"
}
}
\ No newline at end of file
......@@ -7,7 +7,7 @@ class URLs {
val BASE_URL: String
private const val BASE_URL_DEBUG = "http://bp-test.go2yd.com"
private const val BASE_URL_PRO = "http://metro.go2yd.com"
private const val BASE_URL_PRO = "http://bp-test.go2yd.com"
init {
BASE_URL = if (BuildConfig.ENV_DEBUG){
......
package com.yidian.common.wxapi
import com.umeng.socialize.weixin.view.WXCallbackActivity
//import com.umeng.socialize.weixin.view.WXCallbackActivity
//class WXEntryActivity: WXCallbackActivity()
\ No newline at end of file
class WXEntryActivity: WXCallbackActivity()
\ No newline at end of file
......@@ -4,4 +4,5 @@
<external-files-path name="opensdk_external" path="Images/tmp"/>
<root-path name="opensdk_root" path=""/>
<external-cache-path name="video_cache" path="video_cache/"/>
<external-cache-path name="ocr" path="ocr" />
</paths>
\ No newline at end of file
......@@ -82,6 +82,9 @@
<activity
android:name=".ui.TempListActivity"
android:theme="@style/Transparent" />
<activity
android:name=".ui.EnterpriseCertificationActivity"
android:theme="@style/Transparent" />
<activity
android:name=".ui.idcard.IDCardResultActivity"
......@@ -111,6 +114,9 @@
android:name=".ui.LifeAccountAuthActivity"
android:theme="@style/Transparent" />
<activity android:name=".ui.LifeAccountEnterpriseCertificationActivity"
android:theme="@style/Transparent" />
</application>
</manifest>
\ No newline at end of file
......@@ -20,6 +20,7 @@ import com.yidian.common.XRouterPathConstants.Companion.GALLERY
import com.yidian.common.XRouterPathConstants.Companion.HOME
import com.yidian.common.XRouterPathConstants.Companion.ID_CARD_TEST
import com.yidian.common.XRouterPathConstants.Companion.LIFE_ACCOUNT_AUTH
import com.yidian.common.XRouterPathConstants.Companion.LIFE_ACCOUNT_ENTERPRISE_CERTIFICATION
import com.yidian.common.XRouterPathConstants.Companion.LIFE_ACCOUNT_IDENTITY
import com.yidian.common.XRouterPathConstants.Companion.LOGIN_LIFE_CIRCLE
import com.yidian.common.XRouterPathConstants.Companion.NEWS_CONTENT
......@@ -157,6 +158,18 @@ class NewsContentApplication : YdBaseApplication() {
}
}),
XPageNode(LIFE_ACCOUNT_ENTERPRISE_CERTIFICATION, XPageNodePageType.NATIVE, object : XPageHandler {
override fun handler(params: Map<String, Any?>?) {
val intent = Intent()
if (params != null) {
intent.putExtra(XRouterPathConstants.ParamsKey, params as HashMap)
}
intent.setClass(context, LifeAccountEnterpriseCertificationActivity::class.java)
intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK
context.startActivity(intent)
}
}),
XPageNode(NEWS_CONTENT, XPageNodePageType.NATIVE, object : XPageHandler {
override fun handler(params: Map<String, Any?>?) {
val intent = Intent()
......
package com.yidian.shenghuoquan.newscontent.ui
import com.yidian.common.base.BaseActivity
import com.yidian.shenghuoquan.newscontent.databinding.ActivityCreateAccountBinding
class CreateAccountActivity :BaseActivity<ActivityCreateAccountBinding>(){
override fun createViewBinding(): ActivityCreateAccountBinding {
return ActivityCreateAccountBinding.inflate(layoutInflater)
}
override fun getXPageName(): String {
return "create_account"
}
}
\ No newline at end of file
package com.yidian.shenghuoquan.newscontent.ui
import android.os.Bundle
import com.yidian.common.base.BaseActivity
import com.yidian.shenghuoquan.newscontent.R
import com.yidian.shenghuoquan.newscontent.databinding.ActivityEnterpriseCertificationBinding
import kotlinx.android.synthetic.main.top_bar.view.*
/**
* Author: houzhenpu
* Date: 2021/5/26 10:44 AM
* Describe: activity_enterprise_certification 企业认证成功页面
*/
class EnterpriseCertificationActivity : BaseActivity<ActivityEnterpriseCertificationBinding>() {
override fun createViewBinding(): ActivityEnterpriseCertificationBinding {
return ActivityEnterpriseCertificationBinding.inflate(layoutInflater)
}
override fun getXPageName(): String {
return ""
}
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
viewBind.root.title.text = resources.getString(R.string.enterprise_certification)
}
}
\ No newline at end of file
package com.yidian.shenghuoquan.newscontent.ui
import android.app.Activity
import android.content.ContentResolver
import android.content.Intent
import android.graphics.Bitmap
import android.graphics.BitmapFactory
import android.net.Uri
import android.os.Build
import android.os.Bundle
import android.os.FileUtils
import android.provider.MediaStore
import android.util.Log
import androidx.core.content.FileProvider
import com.yidian.common.XRouterPathConstants
import com.yidian.common.base.BaseActivity
import com.yidian.common.utils.YdFileUtils
import com.yidian.shenghuoquan.newscontent.databinding.ActivityLifeAccountEnterpriseCertificationBinding
import com.yidian.shenghuoquan.newscontent.http.ApiService
import com.yidian.shenghuoquan.newscontent.http.httpbean.BusinessLicenseOCRBean
import com.yidian.shenghuoquan.newscontent.http.httpbean.IBusinessLicenseOCRCallback
import com.yidian.shenghuoquan.newscontent.utils.KS3Core
import com.yidian.utils.ToastUtil
import java.io.File
import java.io.FileOutputStream
/**
* author: yinjiacheng
* date: 5/24/21 3:15 PM
* description: 企业生活号认证
*/
class LifeAccountEnterpriseCertificationActivity :
BaseActivity<ActivityLifeAccountEnterpriseCertificationBinding>() {
companion object {
private const val TAG = "BusinessLicenseOCR"
private const val REQUEST_CODE_PERMISSIONS = 1000 //权限
private const val REQUEST_CODE_ALBUM = 1001 //相册
private const val REQUEST_CODE_CAMERA = 1002 //相机
private const val FILE_PATH_BUSINESS_LICENSE_CAMERA = "/ocr/business_license_camera.jpg"
private const val FILE_PATH_BUSINESS_LICENSE = "/ocr/business_license.jpg"
}
/**
* 调用系统相机拍照,照片Uri
*/
private lateinit var photoUri: Uri
/**
* 营业执照文件路径
*/
private var filePath: String? = null
override fun createViewBinding(): ActivityLifeAccountEnterpriseCertificationBinding {
return ActivityLifeAccountEnterpriseCertificationBinding.inflate(layoutInflater)
}
override fun getXPageName(): String {
return XRouterPathConstants.LIFE_ACCOUNT_ENTERPRISE_CERTIFICATION
}
override fun init(savedInstanceState: Bundle?) {
super.init(savedInstanceState)
initListener()
}
private fun initListener() {
viewBind.btnOpenAlbum.setOnClickListener {
// 打开系统相册
val intent = Intent()
intent.action = Intent.ACTION_PICK
intent.setDataAndType(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, "image/*")
startActivityForResult(intent, REQUEST_CODE_ALBUM)
}
viewBind.btnTakePhoto.setOnClickListener {
val file = File(externalCacheDir?.absolutePath + FILE_PATH_BUSINESS_LICENSE_CAMERA)
if (file.exists()) {
file.delete()
} else {
file.parentFile?.mkdirs()
file.createNewFile()
}
photoUri = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
//适配Android 7.0文件权限,通过FileProvider创建一个content类型的Uri
FileProvider.getUriForFile(this, "$packageName.provider", file)
} else {
Uri.fromFile(file)
}
val intent = Intent(MediaStore.ACTION_IMAGE_CAPTURE)
//android11以后强制分区存储,外部资源无法访问,所以添加一个输出保存位置,然后取值操作
intent.putExtra(MediaStore.EXTRA_OUTPUT, photoUri)
startActivityForResult(intent, REQUEST_CODE_CAMERA)
}
viewBind.btnOcr.setOnClickListener {
KS3Core.INSTANCE.uploadObject(
generateUploadFile(filePath),
KS3Core.ObjectType.IMAGE,
object : KS3Core.OnKS3TaskListener {
override fun onTaskStart() {
}
override fun onTaskProgress(progress: Double) {
}
override fun onTaskFinish() {
}
override fun onTaskCancel() {
}
override fun onTaskSuccess(bucket: String?, objectKey: String?) {
val request = BusinessLicenseOCRBean.Request(objectKey)
ApiService.businessLicenseOCR(object : IBusinessLicenseOCRCallback {
override fun businessLicenseOCRSuccess(result: BusinessLicenseOCRBean.Response?) {
Log.d(TAG, "name: ${result?.name}, code: ${result?.code}")
ToastUtil.showToast(this@LifeAccountEnterpriseCertificationActivity, "ocr result, name: ${result?.name}, code: ${result?.code}")
}
override fun businessLicenseOCRFailure(message: String?) {
}
}, request)
}
override fun onTaskFailure(statesCode: Int, message: String?) {
}
})
}
}
/**
* 通过Uri获取文件全路径
* 适配Android Q
*/
private fun getFilePathFromUri(uri: Uri?): String? {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
val file = File(externalCacheDir?.absolutePath + FILE_PATH_BUSINESS_LICENSE)
if (file.exists()) {
file.delete()
} else {
file.parentFile?.mkdirs()
file.createNewFile()
}
if (uri?.scheme == ContentResolver.SCHEME_CONTENT) {
val inputStream = contentResolver.openInputStream(uri)
val fileOutputStream = FileOutputStream(file)
inputStream?.let { FileUtils.copy(it, fileOutputStream) }
inputStream?.close()
fileOutputStream.close()
return file.absolutePath
}
return null
} else {
return YdFileUtils.getImageAbsolutePath(this, uri)
}
}
/**
* 生成金山云上传文件
*/
private fun generateUploadFile(filePath: String?): File {
BitmapFactory.decodeFile(filePath)
.compress(Bitmap.CompressFormat.JPEG, 10, FileOutputStream(filePath))
return File(filePath)
}
/**
* 根据容器大小生成Bitmap
*
* @param filePath 本地文件路径
*/
private fun generateBitmap(filePath: String?): Bitmap? {
val options = BitmapFactory.Options()
options.inJustDecodeBounds = true
BitmapFactory.decodeFile(filePath, options)
options.inSampleSize =
calculateInSampleSize(options, viewBind.ivImage.width, viewBind.ivImage.height)
options.inJustDecodeBounds = false
return BitmapFactory.decodeFile(filePath, options)
}
/**
* 计算Bitmap inSampleSize
*
* @param targetWidth 容器宽
* @param targetHeight 容器高
*/
private fun calculateInSampleSize(
options: BitmapFactory.Options,
targetWidth: Int,
targetHeight: Int
): Int {
val sourceWidth = options.outWidth
val sourceHeight = options.outHeight
var inSampleSize = 1
if (sourceWidth > targetWidth || sourceHeight > targetHeight) {
val halfWidth = sourceWidth / 2
val halfHeight = sourceHeight / 2
// 压缩后的尺寸与所需的尺寸进行比较
while (halfWidth / inSampleSize >= targetWidth && halfHeight / inSampleSize >= targetHeight) {
inSampleSize *= 2
}
}
return inSampleSize
}
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
super.onActivityResult(requestCode, resultCode, data)
if (resultCode == Activity.RESULT_OK) {
when (requestCode) {
REQUEST_CODE_ALBUM -> {
filePath = getFilePathFromUri(data?.data)
viewBind.ivImage.setImageBitmap(generateBitmap(filePath))
}
REQUEST_CODE_CAMERA -> {
filePath = getFilePathFromUri(photoUri)
viewBind.ivImage.setImageBitmap(generateBitmap(filePath))
}
}
}
}
}
\ No newline at end of file
......@@ -32,7 +32,10 @@ class TempListActivity : BaseActivity<ActivityTempListBinding>() {
}
viewBind.btBusinessLicense.setOnClickListener {
startActivity(Intent(this@TempListActivity, AliveTestActivity::class.java))
startActivity(Intent(this@TempListActivity, LifeAccountEnterpriseCertificationActivity::class.java))
}
viewBind.btCreateAccount.setOnClickListener {
startActivity(Intent(this@TempListActivity, CreateAccountActivity::class.java))
}
}
}
\ No newline at end of file
......@@ -20,6 +20,7 @@ import com.yidian.shenghuoquan.newscontent.http.ApiService
import com.yidian.shenghuoquan.newscontent.http.httpbean.GetIDCardOCRBean
import com.yidian.shenghuoquan.newscontent.http.httpbean.IGetIDCardOCRCallback
import com.yidian.shenghuoquan.newscontent.utils.KS3Core
import com.yidian.utils.ToastUtil
import java.io.File
import java.io.FileOutputStream
......@@ -55,10 +56,20 @@ class IDCardTestActivity : BaseActivity<ActivityIdcardBinding>() {
startGetLicense()
}
viewBind.btnOcr.setOnClickListener {
val frontFile = File(externalCacheDir?.absolutePath + "/front.jpg")
if (frontFile.exists()) frontFile.delete() else frontFile.createNewFile()
val backFile = File(externalCacheDir?.absolutePath + "/back.jpg")
if (backFile.exists()) backFile.delete() else backFile.createNewFile()
val frontFile = File(externalCacheDir?.absolutePath + "/ocr/idCardFront.jpg")
if (frontFile.exists()) {
frontFile.delete()
} else {
frontFile.parentFile?.mkdirs()
frontFile.createNewFile()
}
val backFile = File(externalCacheDir?.absolutePath + "/ocr/idCardBack.jpg")
if (backFile.exists()) {
backFile.delete()
} else {
backFile.parentFile?.mkdirs()
backFile.createNewFile()
}
idCardFront.compress(Bitmap.CompressFormat.JPEG, 100, FileOutputStream(frontFile))
idCardBack.compress(Bitmap.CompressFormat.JPEG, 100, FileOutputStream(backFile))
KS3Core.INSTANCE.uploadObject(frontFile, object : KS3Core.OnKS3TaskListener {
......@@ -107,6 +118,7 @@ class IDCardTestActivity : BaseActivity<ActivityIdcardBinding>() {
ApiService.getIDCardOCR(object : IGetIDCardOCRCallback {
override fun getIDCardOCRSuccess(result: GetIDCardOCRBean.Response?) {
Log.d(KS3Core.TAG, "name: ${result?.posit?.name}, id num: ${result?.posit?.idcard_number}")
ToastUtil.showToast(this@IDCardTestActivity, "ocr result, name: ${result?.posit?.name}, number: ${result?.posit?.idcard_number}")
}
override fun getIDCardOCRFailure(message: String?) {
......
<?xml version="1.0" encoding="utf-8"?>
<shape android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android">
<gradient android:type="linear" android:startColor="#FF1751F1"
android:endColor="#FF3693FF" android:angle="0"/>
<corners android:radius="22dp" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<corners android:radius="12dp" />
<solid android:color="#FFF3EE" />
</shape>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<corners android:radius="18dp" />
<stroke
android:color="#1852F1"
android:width="2px"/>
<solid
android:color="@color/transparent"/>
</shape>
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/white"
android:fitsSystemWindows="true">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<FrameLayout
android:layout_width="match_parent"
android:layout_height="44dp"
android:fitsSystemWindows="true">
<ImageView
android:id="@+id/iv_back"
android:layout_width="28dp"
android:layout_height="28dp"
android:layout_gravity="center_vertical"
android:layout_marginStart="20dp"
android:scaleType="centerCrop"
android:src="@drawable/big_back"/>
<TextView
android:id="@+id/tv_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="@string/account_title"
android:textColor="@color/gray_333"
android:textSize="18sp"
android:textStyle="bold" />
</FrameLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_vertical"
android:paddingStart="20dp"
android:text="@string/account_name"
android:textColor="@color/gray_333"
android:textSize="16sp"
tools:ignore="RtlSymmetry" />
<androidx.appcompat.widget.AppCompatEditText
android:id="@+id/et_account"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_marginEnd="20dp"
android:layout_marginStart="20dp"
android:gravity="center_vertical"
android:hint="@string/account_create_tips" />
<View
android:id="@+id/v_divider"
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_marginEnd="20dp"
android:layout_marginStart="20dp"
android:background="@color/divider_white" />
<TextView
android:id="@+id/tv_error_tips"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:paddingBottom="6dp"
android:paddingTop="6dp"
android:text="@string/account_error_tips"
android:textColor="#FF3A3A"
android:textSize="12sp"
android:visibility="gone"
tools:visibility="visible" />
<TextView
android:id="@+id/tv_post_name"
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_vertical"
android:paddingStart="20dp"
android:text="@string/account_manager"
android:textColor="@color/gray_333"
android:textSize="16sp"
tools:ignore="RtlSymmetry" />
<TextView
android:id="@+id/tv_user_name"
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_vertical"
android:paddingStart="20dp"
android:text="@string/account_manager"
android:textColor="@color/gray_333"
android:textSize="16sp"
android:textStyle="bold"
tools:ignore="RtlSymmetry" />
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:layout_marginEnd="20dp"
android:layout_marginStart="20dp"
android:background="@color/divider_white" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:gravity="center_vertical"
android:paddingEnd="20dp"
android:paddingStart="20dp"
android:text="@string/account_create_desc"
android:textColor="@color/content_other_text"
android:textSize="12sp"
tools:ignore="RtlSymmetry" />
</LinearLayout>
<androidx.appcompat.widget.AppCompatButton
android:id="@+id/btn_create_account"
android:layout_marginBottom="34dp"
android:textSize="18sp"
android:gravity="center"
android:alpha="0.68"
android:textColor="@color/white"
android:text="@string/create_account"
android:layout_gravity="center_horizontal|bottom"
android:background="@drawable/account_btn_gradient_bg"
android:layout_width="315dp"
android:layout_height="44dp"/>
</FrameLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:fitsSystemWindows="true"
android:background="@color/white"
android:orientation="vertical">
<include layout="@layout/top_bar" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="38dp"
android:gravity="center"
android:text="@string/submitted_successfully"
android:drawablePadding="6dp"
android:drawableStart="@mipmap/success_icon"
android:textColor="#FFF26E3D"
android:textSize="24sp" />
<TextView
android:layout_width="240dp"
android:layout_height="wrap_content"
android:text="@string/mobile_phone_number_notification_information"
android:textSize="16sp"
android:textColor="#FF999999"
android:layout_marginTop="4dp"
android:gravity="center" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="25dp"
android:layout_marginEnd="25dp"
android:layout_marginStart="25dp"
android:paddingStart="30dp"
android:paddingBottom="30dp"
android:background="@mipmap/enterprise_certification_bg"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="40dp"
android:gravity="center_vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/enterprise_certification"
android:textSize="24sp"
android:textColor="#FF333333"
android:layout_marginRight="10dp"
android:gravity="left" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/pending_review"
android:textSize="14sp"
android:paddingLeft="6dp"
android:paddingRight="6dp"
android:paddingTop="2dp"
android:paddingBottom="2dp"
android:textColor="#FFF26E3D"
android:background="@drawable/shape_solid_radius9_da3838"
android:gravity="center" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/company_name"
android:textSize="16sp"
android:layout_marginTop="20dp"
android:textColor="#FF999999"
android:gravity="left" />
<TextView
android:id="@+id/company_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="北京一点网聚科技有限公司"
android:layout_marginTop="6dp"
android:textSize="16sp"
android:textColor="#FF333333"
android:gravity="left" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/credit_code"
android:textSize="16sp"
android:layout_marginTop="20dp"
android:textColor="#FF999999"
android:gravity="left" />
<TextView
android:id="@+id/credit_code"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="WD1212312223331"
android:layout_marginTop="6dp"
android:textSize="16sp"
android:textColor="#FF333333"
android:gravity="left" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/operator_information"
android:textSize="16sp"
android:layout_marginTop="20dp"
android:textColor="#FF999999"
android:gravity="left" />
<TextView
android:id="@+id/operator_information"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="兰花花 120803********0660"
android:layout_marginTop="6dp"
android:textSize="16sp"
android:textColor="#FF333333"
android:gravity="left" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/create_a_life_number"
android:textSize="16sp"
android:paddingLeft="20dp"
android:paddingRight="20dp"
android:paddingTop="7dp"
android:paddingBottom="7dp"
android:layout_marginTop="30dp"
android:textColor="#1852F1"
android:background="@drawable/shape_stroke2_radius18_skin_primary_1852f1"
android:gravity="center" />
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<com.yidian.nightmode.widget.YdConstraintLayout 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">
<com.yidian.nightmode.widget.YdButton
android:id="@+id/btn_open_album"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="100dp"
android:text="打开系统相册"
app:layout_constraintTop_toTopOf="parent" />
<com.yidian.nightmode.widget.YdButton
android:id="@+id/btn_take_photo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:text="拍照"
app:layout_constraintTop_toBottomOf="@id/btn_open_album" />
<com.yidian.nightmode.widget.YdImageView
android:id="@+id/iv_image"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_marginTop="20dp"
app:layout_constraintTop_toBottomOf="@id/btn_take_photo" />
<com.yidian.nightmode.widget.YdButton
android:id="@+id/btn_ocr"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:text="营业执照OCR"
app:layout_constraintTop_toBottomOf="@id/iv_image" />
</com.yidian.nightmode.widget.YdConstraintLayout>
\ No newline at end of file
......@@ -34,6 +34,14 @@
android:text="执照采集"
android:textColor="@android:color/black"
android:textSize="20sp" />
<Button
android:id="@+id/bt_create_account"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginTop="50dp"
android:text="创建生活号"
android:textColor="@android:color/black"
android:textSize="20sp" />
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/addressBar"
android:layout_width="match_parent"
android:layout_height="44dp"
android:background="@color/white">
<ImageButton
android:id="@+id/back"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_centerVertical="true"
android:background="@null"
android:onClick="onBackClicked"
android:paddingLeft="@dimen/back_button_padding_left"
android:paddingRight="@dimen/back_button_padding_right"
android:scaleType="fitCenter"
android:src="@drawable/selector_big_back_black_button" />
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_marginStart="5dp"
android:text="title"
android:textColor="#333333"
android:textSize="18sp" />
</RelativeLayout>
\ No newline at end of file
......@@ -32,4 +32,6 @@
<color name="subscribed_gray">#A8ABB1</color>
<color name="thumb_up_gray">#8C8F96</color>
<color name="progress_d8d8d8_transparent">#bfd8d8d8</color>
<color name="gray_333">#333333</color>
<color name="divider_white">#FFF2F2F2</color>
</resources>
\ No newline at end of file
<resources>
<?xml version="1.0" encoding="utf-8"?>
<resources xmlns:tools ="http://schemas.android.com/tools" tools:ignore="MissingTranslation">
<string name="app_name">Yac</string>
<string name="action_settings">Settings</string>
<!-- Strings used for fragments for navigation -->
......@@ -48,5 +49,22 @@
<!--生活圈B端-->
<string name="life_account_identity_select">生活号身份选择</string>
<string name="enter_life_account">进入生活号</string>
<string name="create_account">确认创建</string>
<string name="account_create_tips">同企业下生活号名称不可复用</string>
<string name="account_create_desc">生活号作为企业服务管理载体,请正确使用生活号权益,新申请生活号默认当前申请人作为默认管理员,申请成功 后可在销售APP内进行更改</string>
<string name="account_error_tips">名称超限,最多40个字符</string>
<string name="account_manager">管理员</string>
<string name="account_name">生活号名称</string>
<string name="account_title">创建生活号</string>
<string name="submitted_successfully">提交成功</string>
<string name="mobile_phone_number_notification_information">已成功提交企业号审核,请留意注册手机号通知信息</string>
<string name="enterprise_certification">企业认证</string>
<string name="pending_review">待审核</string>
<string name="company_name">公司名称</string>
<string name="credit_code">统一社会信用代码</string>
<string name="operator_information">经营者信息</string>
<string name="create_a_life_number">创建生活号</string>
</resources>
\ No newline at end of file
# yac-android Android 组件化工程模板
## 工程规范
## 使用方法
\ No newline at end of file
## 使用方法
## git 提交
\ No newline at end of file
......@@ -34,12 +34,14 @@
<!-- 以下为友盟分享基本配置信息 start-->
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="com.yidian.subway.provider"
android:authorities="com.shenghuoquan.business.provider"
android:exported="false"
android:grantUriPermissions="true">
android:grantUriPermissions="true"
tools:replace="android:authorities">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/file_paths" />
android:resource="@xml/file_paths"
tools:replace="android:resource" />
</provider>
<uses-library
......
......@@ -9,8 +9,8 @@ buildscript {
jcenter()
mavenCentral()
maven { url "https://jitpack.io" }
maven { url "https://dl.bintray.com/thelasterstar/maven/" }
maven { url 'https://repo1.maven.org/maven2/' }
maven { url "https://dl.bintray.com/thelasterstar/maven/" }
}
dependencies {
classpath deps.gradle.plugin
......@@ -28,9 +28,9 @@ allprojects {
jcenter()
mavenCentral()
maven { url "https://jitpack.io" }
maven { url 'https://repo1.maven.org/maven2/' }
maven { url "https://dl.bintray.com/thelasterstar/maven/" }
maven { url "http://dailybuild2.yidian-inc.com:8088/repository/maven-public/" }
maven { url 'https://repo1.maven.org/maven2/' }
}
addRepos(repositories)
}
......
......@@ -40,8 +40,8 @@ ext.dependencies = [
'com.umeng.umsdk:share-board:7.1.4',
'com.umeng.umsdk:share-qq:7.1.4',
'com.umeng.umsdk:share-wx:7.1.4',
'com.tencent.mm.opensdk:wechat-sdk-android-without-mta:6.6.5',
'com.umeng.umsdk:share-sina:7.1.4',
// 'com.sina.weibo.sdk:core:10.10.0:openDefaultRelease@aar',
'com.umeng.umsdk:push:6.3.3',
'com.umeng.umsdk:utdid:1.5.2.1',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment