中建365
parent
d253ed4c83
commit
9d31c548f3
@ -0,0 +1,86 @@
|
|||||||
|
package com.zj365.dc.activity
|
||||||
|
|
||||||
|
import android.view.LayoutInflater
|
||||||
|
import android.widget.TextView
|
||||||
|
import com.alibaba.android.arouter.facade.annotation.Route
|
||||||
|
import com.google.android.material.bottomsheet.BottomSheetDialog
|
||||||
|
import com.luck.picture.lib.config.PictureMimeType
|
||||||
|
import com.xty.base.act.BaseVmAct
|
||||||
|
import com.xty.base.vm.BaseVm
|
||||||
|
import com.xty.common.arouter.ARouterUrl
|
||||||
|
import com.xty.common.picture.PictureUtils
|
||||||
|
import com.zj365.dc.databinding.ActCalorieAnalyzeBinding
|
||||||
|
import com.zj365.health.R
|
||||||
|
|
||||||
|
@Route(path = ARouterUrl.CALORIE_ANALYZE)
|
||||||
|
class CalorieAnalyzeAct : BaseVmAct<BaseVm>() {
|
||||||
|
|
||||||
|
val binding by lazy { ActCalorieAnalyzeBinding.inflate(layoutInflater) }
|
||||||
|
|
||||||
|
var bottomSheetDialog: BottomSheetDialog? = null
|
||||||
|
override fun liveObserver() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initView() {
|
||||||
|
super.initView()
|
||||||
|
statusBar(binding.title.mView)
|
||||||
|
binding.title.mTvTitle.text = "热卡分析"
|
||||||
|
binding.title.mIvBack.setOnClickListener {
|
||||||
|
finish()
|
||||||
|
}
|
||||||
|
|
||||||
|
binding.tvContent.text = "1.注意事项、操作指南文案。平台能通过照片分析出大部分食物、水果蔬菜、菜品。上传更清晰完整的照片,分析结果更准确。" +
|
||||||
|
"\n2.平台能通过照片分析出大部分食物、水果蔬菜、菜品。\n" +
|
||||||
|
"3.上传更清晰完整的招聘,分析结果更准确。平台能通过照片分析出大部分食物。\n" +
|
||||||
|
"4.上传更清晰完整的照片,分析结果更准确。平台能通过照片分析出大部分食物、水果蔬菜、菜品。\n" +
|
||||||
|
"5.上传更清晰完整的招聘,分析结果更准确。平台能通过照片分析出大部分食物、水果蔬菜、菜品。上传更清晰完整的招聘,分析结果更准确。\n"
|
||||||
|
|
||||||
|
binding.tvDishes.setOnClickListener {
|
||||||
|
bottomSheetDialog?.show()
|
||||||
|
}
|
||||||
|
|
||||||
|
binding.tvFruitVegetable.setOnClickListener {
|
||||||
|
bottomSheetDialog?.show()
|
||||||
|
|
||||||
|
}
|
||||||
|
binding.tvSnack.setOnClickListener {
|
||||||
|
bottomSheetDialog?.show()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
initBottomDialog()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun setLayout() = binding.root
|
||||||
|
|
||||||
|
fun initBottomDialog() {
|
||||||
|
if (bottomSheetDialog == null) {
|
||||||
|
bottomSheetDialog = BottomSheetDialog(this, R.style.Theme_ChartDialogManager)
|
||||||
|
bottomSheetDialog?.let { dialog ->
|
||||||
|
val view = LayoutInflater.from(this).inflate(R.layout.dialog_choose_pic, null)
|
||||||
|
dialog.setContentView(view)
|
||||||
|
|
||||||
|
val tvTakePhoto = view.findViewById<TextView>(R.id.tv_take_photo)
|
||||||
|
val tvChoosePhotoAlbum = view.findViewById<TextView>(R.id.tv_choose_photo_album)
|
||||||
|
val tvCancel = view.findViewById<TextView>(R.id.tv_cancel)
|
||||||
|
tvCancel.setOnClickListener {
|
||||||
|
dialog.dismiss()
|
||||||
|
}
|
||||||
|
|
||||||
|
tvTakePhoto.setOnClickListener {
|
||||||
|
PictureUtils.openTheCamera(this, PictureMimeType.ofImage())
|
||||||
|
dialog.dismiss()
|
||||||
|
}
|
||||||
|
|
||||||
|
tvChoosePhotoAlbum.setOnClickListener {
|
||||||
|
PictureUtils.openCamera(this, PictureMimeType.ofImage(),9)
|
||||||
|
dialog.dismiss()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,59 @@
|
|||||||
|
package com.zj365.dc.activity
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.alibaba.android.arouter.facade.annotation.Route
|
||||||
|
import com.xty.base.act.BaseVmAct
|
||||||
|
import com.xty.base.vm.BaseVm
|
||||||
|
import com.xty.common.arouter.ARouterUrl
|
||||||
|
import com.xty.common.arouter.RouteManager
|
||||||
|
import com.zj365.dc.R
|
||||||
|
import com.zj365.dc.databinding.ActDietManagementBinding
|
||||||
|
|
||||||
|
@Route(path = ARouterUrl.DIET_MANAGEMENT)
|
||||||
|
class DietManagementAct : BaseVmAct<BaseVm>(){
|
||||||
|
|
||||||
|
val binding by lazy{ ActDietManagementBinding.inflate(layoutInflater)}
|
||||||
|
override fun liveObserver() {
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initView() {
|
||||||
|
super.initView()
|
||||||
|
statusBar(binding.title.mView)
|
||||||
|
binding.title.mTvTitle.text ="膳食管理"
|
||||||
|
binding.title.mIvBack.setOnClickListener {
|
||||||
|
finish()
|
||||||
|
}
|
||||||
|
|
||||||
|
binding.rxCalorie.setOnClickListener(setOnClickListener)
|
||||||
|
binding.rxHealthyDiet.setOnClickListener(setOnClickListener)
|
||||||
|
binding.rxMedicineFood.setOnClickListener(setOnClickListener)
|
||||||
|
binding.rxFoodDiary.setOnClickListener(setOnClickListener)
|
||||||
|
binding.rxMore.setOnClickListener(setOnClickListener)
|
||||||
|
}
|
||||||
|
|
||||||
|
var setOnClickListener = View.OnClickListener {
|
||||||
|
when(it.id){
|
||||||
|
R.id.rx_calorie ->{
|
||||||
|
RouteManager.goAct(ARouterUrl.CALORIE_ANALYZE)
|
||||||
|
}
|
||||||
|
|
||||||
|
R.id.rx_healthy_diet ->{
|
||||||
|
|
||||||
|
}
|
||||||
|
R.id.rx_medicine_food ->{
|
||||||
|
|
||||||
|
}
|
||||||
|
R.id.rx_food_diary ->{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
R.id.rx_more ->{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun setLayout() = binding.root
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,95 @@
|
|||||||
|
package com.zj365.dc.activity
|
||||||
|
|
||||||
|
import android.view.LayoutInflater
|
||||||
|
import android.view.View
|
||||||
|
import android.widget.ImageView
|
||||||
|
import android.widget.LinearLayout
|
||||||
|
import android.widget.TextView
|
||||||
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
import com.alibaba.android.arouter.facade.annotation.Route
|
||||||
|
import com.google.android.material.bottomsheet.BottomSheetDialog
|
||||||
|
import com.luck.picture.lib.config.PictureMimeType
|
||||||
|
import com.xty.base.act.BaseVmAct
|
||||||
|
import com.xty.base.vm.BaseVm
|
||||||
|
import com.xty.common.arouter.ARouterUrl
|
||||||
|
import com.xty.common.picture.PictureUtils
|
||||||
|
import com.xty.common.util.SpannableUtils
|
||||||
|
import com.zj365.dc.adapter.RecognizeResultAdapter
|
||||||
|
import com.zj365.dc.databinding.ActRecognizeResultBinding
|
||||||
|
import com.zj365.health.R
|
||||||
|
|
||||||
|
@Route(path = ARouterUrl.RECOGNIZE_RESULT)
|
||||||
|
class RecognizeResultAct : BaseVmAct<BaseVm>() {
|
||||||
|
|
||||||
|
val binding by lazy{ ActRecognizeResultBinding.inflate(layoutInflater)}
|
||||||
|
|
||||||
|
val adapter by lazy { RecognizeResultAdapter() }
|
||||||
|
|
||||||
|
var bottomSheetDialog: BottomSheetDialog? = null
|
||||||
|
override fun liveObserver() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initView() {
|
||||||
|
super.initView()
|
||||||
|
statusBar(binding.title.mView)
|
||||||
|
binding.title.mTvTitle.text = "识别结果"
|
||||||
|
binding.title.mIvBack.setOnClickListener {
|
||||||
|
finish()
|
||||||
|
}
|
||||||
|
initAdapter()
|
||||||
|
binding.tvPhotographAgain.setOnClickListener {
|
||||||
|
|
||||||
|
}
|
||||||
|
binding.tvDetail.setOnClickListener {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
initBottomDialog()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
fun initAdapter(){
|
||||||
|
binding.recycler.layoutManager = LinearLayoutManager(this,LinearLayoutManager.HORIZONTAL,false)
|
||||||
|
binding.recycler.adapter = adapter
|
||||||
|
adapter.setOnItemChildClickListener { adapter, view, position ->
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initData() {
|
||||||
|
super.initData()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun setLayout() = binding.root
|
||||||
|
|
||||||
|
fun initBottomDialog() {
|
||||||
|
if (bottomSheetDialog == null) {
|
||||||
|
bottomSheetDialog = BottomSheetDialog(this, R.style.Theme_ChartDialogManager)
|
||||||
|
bottomSheetDialog?.let { dialog ->
|
||||||
|
val view = LayoutInflater.from(this).inflate(R.layout.dialog_choose_pic, null)
|
||||||
|
dialog.setContentView(view)
|
||||||
|
|
||||||
|
val tvTakePhoto = view.findViewById<TextView>(R.id.tv_take_photo)
|
||||||
|
val tvChoosePhotoAlbum = view.findViewById<TextView>(R.id.tv_choose_photo_album)
|
||||||
|
val tvCancel = view.findViewById<TextView>(R.id.tv_cancel)
|
||||||
|
tvCancel.setOnClickListener {
|
||||||
|
dialog.dismiss()
|
||||||
|
}
|
||||||
|
|
||||||
|
tvTakePhoto.setOnClickListener {
|
||||||
|
PictureUtils.openTheCamera(this, PictureMimeType.ofImage())
|
||||||
|
dialog.dismiss()
|
||||||
|
}
|
||||||
|
|
||||||
|
tvChoosePhotoAlbum.setOnClickListener {
|
||||||
|
PictureUtils.openCamera(this, PictureMimeType.ofImage(),9)
|
||||||
|
dialog.dismiss()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,13 @@
|
|||||||
|
package com.zj365.dc.adapter
|
||||||
|
|
||||||
|
import com.chad.library.adapter.base.viewholder.BaseViewHolder
|
||||||
|
import com.xty.base.adapter.BaseAdapter
|
||||||
|
import com.xty.network.model.HomeLayoutBean
|
||||||
|
import com.zj365.dc.R
|
||||||
|
|
||||||
|
class RecognizeResultAdapter : BaseAdapter<HomeLayoutBean.HomeChildBean>(R.layout.item_recognize_result){
|
||||||
|
override fun convert(holder: BaseViewHolder, item: HomeLayoutBean.HomeChildBean) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,106 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout 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:orientation="vertical"
|
||||||
|
android:background="@color/col_6f7">
|
||||||
|
|
||||||
|
<include layout="@layout/title_white_bar"
|
||||||
|
android:id="@+id/title"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_margin="@dimen/dp_14"
|
||||||
|
android:paddingTop="@dimen/dp_22"
|
||||||
|
android:paddingLeft="@dimen/dp_16"
|
||||||
|
android:paddingRight="@dimen/dp_23"
|
||||||
|
android:paddingBottom="@dimen/dp_26"
|
||||||
|
android:background="@drawable/shape_8round_white">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
>
|
||||||
|
<com.ruffian.library.widget.RView
|
||||||
|
android:layout_width="@dimen/dp_4"
|
||||||
|
android:layout_height="@dimen/dp_18"
|
||||||
|
app:background_normal="@color/col_02c"
|
||||||
|
app:corner_radius="2dp"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:text="提示文案标题"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="@dimen/sp_17"
|
||||||
|
android:paddingHorizontal="@dimen/dp_10"
|
||||||
|
/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_content"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="@dimen/dp_21"
|
||||||
|
android:textSize="@dimen/sp_14"
|
||||||
|
android:textColor="@color/col_313"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_marginLeft="@dimen/dp_15"
|
||||||
|
android:layout_marginRight="@dimen/dp_15"
|
||||||
|
android:layout_marginTop="@dimen/dp_46">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_dishes"
|
||||||
|
android:layout_width="@dimen/dp_0"
|
||||||
|
android:layout_height="@dimen/dp_46"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_r25_02c"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="菜品"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_fruit_vegetable"
|
||||||
|
android:layout_width="@dimen/dp_0"
|
||||||
|
android:layout_height="@dimen/dp_46"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_marginLeft="@dimen/dp_17"
|
||||||
|
android:layout_marginRight="@dimen/dp_17"
|
||||||
|
android:background="@drawable/shape_r25_02c"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="果蔬"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_snack"
|
||||||
|
android:layout_width="@dimen/dp_0"
|
||||||
|
android:layout_height="@dimen/dp_46"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_r25_02c"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="零食"/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,144 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="@color/col_6f7"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<include layout="@layout/title_white_bar"
|
||||||
|
android:id="@+id/title"/>
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="@dimen/dp_14"
|
||||||
|
android:layout_marginLeft="@dimen/dp_14"
|
||||||
|
android:layout_below="@+id/title"
|
||||||
|
android:id="@+id/recycler"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_below="@+id/recycler"
|
||||||
|
android:layout_marginLeft="@dimen/dp_27"
|
||||||
|
android:layout_marginTop="@dimen/dp_12"
|
||||||
|
android:id="@+id/ll_analyze">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@mipmap/icon_analyze_arrow"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="@dimen/sp_15"
|
||||||
|
android:textColor="@color/col_c7c"
|
||||||
|
android:layout_marginLeft="@dimen/dp_5"
|
||||||
|
android:text="相似解析"/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
<androidx.core.widget.NestedScrollView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_below="@+id/ll_analyze"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_marginLeft="@dimen/dp_14"
|
||||||
|
android:layout_marginRight="@dimen/dp_14"
|
||||||
|
android:layout_marginBottom="@dimen/dp_42"
|
||||||
|
android:layout_marginTop="@dimen/dp_12"
|
||||||
|
android:fitsSystemWindows="true"
|
||||||
|
>
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:paddingTop="@dimen/dp_22"
|
||||||
|
android:paddingLeft="@dimen/dp_16"
|
||||||
|
android:paddingRight="@dimen/dp_16"
|
||||||
|
android:paddingBottom="@dimen/dp_25"
|
||||||
|
android:background="@drawable/shape_8round_white">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
>
|
||||||
|
<com.ruffian.library.widget.RView
|
||||||
|
android:layout_width="@dimen/dp_4"
|
||||||
|
android:layout_height="@dimen/dp_18"
|
||||||
|
app:background_normal="@color/col_02c"
|
||||||
|
app:corner_radius="2dp"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:text="识别结果"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="@dimen/sp_17"
|
||||||
|
android:paddingHorizontal="@dimen/dp_10"
|
||||||
|
/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:id="@+id/tv_analyze_title"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:layout_marginTop="@dimen/dp_21"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
tools:text="剁椒鱼头"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:id="@+id/tv_analyze_content"
|
||||||
|
android:textSize="@dimen/sp_14"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:layout_marginTop="@dimen/dp_14"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_margin="@dimen/dp_25"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="@dimen/dp_50"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_r25_stroke_02c"
|
||||||
|
android:text="重新拍照"
|
||||||
|
android:id="@+id/tv_photograph_again"
|
||||||
|
android:textColor="@color/col_02c"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_detail"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="@dimen/dp_50"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_r25_02c"
|
||||||
|
android:layout_marginLeft="@dimen/dp_19"
|
||||||
|
android:text="查看详情"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -0,0 +1,20 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="@dimen/dp_132"
|
||||||
|
android:layout_height="@dimen/dp_104">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:background="@drawable/shape_r8_02c_stroke_1_5"/>
|
||||||
|
|
||||||
|
<com.ruffian.library.widget.RImageView
|
||||||
|
android:id="@+id/img_pic"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
app:is_circle="false"
|
||||||
|
android:layout_margin="@dimen/dp_1"
|
||||||
|
app:corner_radius="@dimen/dp_8"/>
|
||||||
|
|
||||||
|
</FrameLayout>
|
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
@ -1,3 +1,3 @@
|
|||||||
<resources>
|
<resources>
|
||||||
<string name="app_name">zhongjian</string>
|
<string name="app_name">中健365</string>
|
||||||
</resources>
|
</resources>
|
@ -0,0 +1,8 @@
|
|||||||
|
package com.xty.common.listener
|
||||||
|
|
||||||
|
interface OnChoosePicListener {
|
||||||
|
|
||||||
|
fun onChooseTakePhoto()
|
||||||
|
|
||||||
|
fun onChoosePhotoAlbum()
|
||||||
|
}
|
@ -0,0 +1,7 @@
|
|||||||
|
package com.xty.common.util
|
||||||
|
|
||||||
|
import android.app.Dialog
|
||||||
|
import android.content.Context
|
||||||
|
|
||||||
|
class TakePhotoDialog(context: Context) : Dialog(context) {
|
||||||
|
}
|
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<stroke
|
||||||
|
android:color="@color/col_02c" android:width="@dimen/dp_1"/>
|
||||||
|
<solid android:color="@color/white"/>
|
||||||
|
<corners
|
||||||
|
android:radius="@dimen/dp_25"/>
|
||||||
|
</shape>
|
@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<stroke android:color="@color/col_02c" android:width="@dimen/dp_1_5"/>
|
||||||
|
<corners android:radius="@dimen/dp_8"/>
|
||||||
|
</shape>
|
@ -0,0 +1,58 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@drawable/shape_lt15_rt15_white"
|
||||||
|
android:paddingBottom="@dimen/dp_25"
|
||||||
|
android:orientation="vertical">
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/dp_56"
|
||||||
|
android:text="拍 摄"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:id="@+id/tv_take_photo"/>
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/dp_0_5"
|
||||||
|
android:layout_marginLeft="@dimen/dp_19"
|
||||||
|
android:layout_marginRight="@dimen/dp_19"
|
||||||
|
android:background="@color/col_0F2"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/dp_56"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:text="从手机相册选择"
|
||||||
|
android:id="@+id/tv_choose_photo_album"/>
|
||||||
|
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/dp_0_5"
|
||||||
|
android:layout_marginLeft="@dimen/dp_19"
|
||||||
|
android:layout_marginRight="@dimen/dp_19"
|
||||||
|
android:background="@color/col_0F2"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="@dimen/dp_56"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:textColor="@color/col_C7C"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:id="@+id/tv_cancel"
|
||||||
|
android:text="取 消"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,128 @@
|
|||||||
|
<?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="@dimen/dp_270"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:background="@drawable/shape_lt15_rt15_white"
|
||||||
|
android:paddingBottom="@dimen/dp_27"
|
||||||
|
>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="@dimen/dp_30"
|
||||||
|
android:layout_marginRight="@dimen/dp_30"
|
||||||
|
android:layout_marginTop="@dimen/dp_30"
|
||||||
|
android:layout_marginBottom="@dimen/dp_24">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_cancel"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="取消"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="@dimen/sp_17"
|
||||||
|
android:textColor="@color/col_C7C"/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="选择年龄"
|
||||||
|
android:textColor="@color/col_313"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:textSize="@dimen/sp_17"
|
||||||
|
android:textStyle="bold"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_confirm"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="确认"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="@dimen/sp_17"
|
||||||
|
android:textColor="@color/col_02c"/>
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/check_brithday"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_marginLeft="@dimen/dp_31"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@drawable/selector_check_birthday"
|
||||||
|
android:button="@null"
|
||||||
|
android:checked="false" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/timepicker"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:background="@android:color/white"
|
||||||
|
android:gravity="center"
|
||||||
|
android:minHeight="150dp"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
android:id="@+id/year"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="年"
|
||||||
|
android:textSize="@dimen/sp_15"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textColor="@color/col_C7C"/>
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
|
||||||
|
android:id="@+id/month"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1.1" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="月"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_15"
|
||||||
|
android:textColor="@color/col_C7C"/>
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
android:id="@+id/day"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1.1" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="日"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_15"
|
||||||
|
android:textColor="@color/col_C7C"/>
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
android:id="@+id/hour"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1.1" />
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
android:id="@+id/min"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1.1" />
|
||||||
|
|
||||||
|
<com.contrarywind.view.WheelView
|
||||||
|
android:id="@+id/second"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1.1" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,16 @@
|
|||||||
|
package com.zj365.health.act.skin
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.xty.base.act.BaseVmAct
|
||||||
|
import com.zj365.health.databinding.ActAiSkinMeasurementBinding
|
||||||
|
import com.zj365.health.vm.TongueDiagnosisVm
|
||||||
|
|
||||||
|
class SkinMeasurementMainAct : BaseVmAct<TongueDiagnosisVm>() {
|
||||||
|
|
||||||
|
val binding by lazy { ActAiSkinMeasurementBinding.inflate(layoutInflater)}
|
||||||
|
|
||||||
|
override fun liveObserver() {
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun setLayout() = binding.root
|
||||||
|
}
|
@ -0,0 +1,50 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
tools:ignore="MissingDefaultResource">
|
||||||
|
|
||||||
|
<include
|
||||||
|
android:id="@+id/title"
|
||||||
|
layout="@layout/title_white_bar"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<androidx.core.widget.NestedScrollView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/title"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/ivBg"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:scaleType="matrix"
|
||||||
|
android:paddingBottom="100dp"
|
||||||
|
/>
|
||||||
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tvSubmit"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="@dimen/dp_50"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
android:layout_marginHorizontal="@dimen/dp_24"
|
||||||
|
android:layout_marginBottom="@dimen/dp_26"
|
||||||
|
android:background="@drawable/shape_button_bg"
|
||||||
|
android:gravity="center"
|
||||||
|
android:textSize="@dimen/sp_18"
|
||||||
|
android:text="立即购买"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
/>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
Loading…
Reference in New Issue