add is over

This commit is contained in:
ScorpioMiku
2018-09-08 21:52:16 +08:00
parent 0d8214d19b
commit ec41925d18
4 changed files with 175 additions and 7 deletions

View File

@@ -1,3 +1,4 @@
## 营养大师
一款基于数据分析的智能饮食推荐APP

View File

@@ -3,6 +3,7 @@ package com.example.ninefourone.nutritionmaster.modules.addinformation;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.CardView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
@@ -13,15 +14,11 @@ import android.widget.Button;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.TextView;
import android.widget.Toast;
import com.example.ninefourone.nutritionmaster.R;
import com.example.ninefourone.nutritionmaster.utils.ConstantUtils;
import com.example.ninefourone.nutritionmaster.utils.MessageUtils;
import com.github.czy1121.view.TurnCardListView;
import com.orhanobut.logger.Logger;
import java.util.ArrayList;
import butterknife.BindView;
import butterknife.ButterKnife;
@@ -35,6 +32,8 @@ public class AddActivity extends AppCompatActivity {
RelativeLayout bottomContent;
@BindView(R.id.back_button)
ImageView backButton;
@BindView(R.id.result_layout)
CardView resultLayout;
// private int[] colors = {0xff3F51B5, 0xff673AB7, 0xff006064, 0xffC51162, 0xffFFEB3B, 0xff795548, 0xff9E9E9E};
@@ -117,7 +116,7 @@ public class AddActivity extends AppCompatActivity {
firstButtons[position].setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
MessageUtils.MakeToast("结果");
resultLayout.setVisibility(View.VISIBLE);
}
});
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 171 KiB

View File

@@ -5,7 +5,7 @@
android:id="@+id/bottom_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#e2eced"
android:background="#b0ce93"
tools:context="com.example.ninefourone.nutritionmaster.modules.addinformation.AddActivity">
@@ -25,15 +25,183 @@
android:src="@drawable/ic_back_button" />
<android.support.v7.widget.CardView
android:id="@+id/result_layout"
android:layout_width="300dp"
android:layout_height="450dp"
android:layout_centerInParent="true"
android:visibility="gone"
app:cardCornerRadius="20dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#31afc2">
android:background="@drawable/result_bg"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="15dp"
android:layout_marginLeft="30dp"
android:layout_marginRight="30dp"
android:layout_marginTop="30dp"
android:gravity="center"
android:orientation="horizontal">
<com.github.siyamed.shapeimageview.CircularImageView
android:layout_width="100dp"
android:layout_height="100dp"
tools:src="@drawable/test_avatar" />
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="15dp"
android:textStyle="bold"
tools:text="淤血质" />
</LinearLayout>
<android.support.v7.widget.CardView
android:layout_width="250dp"
android:layout_height="250dp"
android:layout_gravity="center"
app:cardBackgroundColor="#95def4">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="3dp"
android:layout_marginLeft="10dp"
android:layout_marginTop="10dp"
android:text="常见表现"
android:textSize="10sp" />
<TextView
android:layout_width="match_parent"
android:layout_height="0.5dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:background="@color/place_holder" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:textSize="8sp"
tools:text="平素面色晦暗,皮肤偏暗或色素沉着,容易出现瘀斑,易患疼痛,口唇暗淡或紫,舌质暗有点、片状瘀斑,舌下静脉曲张。眼眶暗黑,鼻部暗滞,发易脱落,皮肤发干,或有出血倾向、吐血,女性多见痛经、闭经、或经血中多有血块,或经色紫黑有块。" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="3dp"
android:layout_marginLeft="10dp"
android:layout_marginTop="10dp"
android:text="特点"
android:textSize="10sp" />
<TextView
android:layout_width="match_parent"
android:layout_height="0.5dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:background="@color/place_holder" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:textSize="8sp"
tools:text="瘀血质的人,血行不畅,临床常呈现肤色晦暗、色素沉着、瘀斑、性格抑郁、健忘,舌质紫黯或有瘀点、舌下络脉紫黯或增粗,脉涩。易患痛证、血证、症瘕等。" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="3dp"
android:layout_marginLeft="10dp"
android:layout_marginTop="10dp"
android:text="心理特征"
android:textSize="10sp" />
<TextView
android:layout_width="match_parent"
android:layout_height="0.5dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:background="@color/place_holder" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:textSize="8sp"
tools:text="性情急躁,心情易烦,健忘。" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="3dp"
android:layout_marginLeft="10dp"
android:layout_marginTop="10dp"
android:text="注意事项"
android:textSize="10sp" />
<TextView
android:layout_width="match_parent"
android:layout_height="0.5dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:background="@color/place_holder" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:textSize="8sp"
tools:text="瘀血质气机失调,血行不畅,应慎食雪糕、冰淇淋、冰冻饮料等寒凉之品,以免影响气血运行。保持心情舒畅,是淤血质调理的重要环节" />
</LinearLayout>
</LinearLayout>
</android.support.v7.widget.CardView>
</LinearLayout>