简单登陆界面
对应的activity_main.xml代码
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/activity_main"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context="net.pay.hxb.com.testnet.MainActivity">
<EditText
android:id="@+id/et_data_uname"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="请输入用户名:" />
<EditText
android:id="@+id/et_data_upass"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="请输入密码:"
android:inputType="number" />
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:onClick="loginGET"
android:text="登录(GET)" />
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:onClick="loginPOST"
android:text="登录(POST)" /&