diff --git a/app/src/main/java/com/example/bpa/view/from/wlgl_activity.java b/app/src/main/java/com/example/bpa/view/from/wlgl_activity.java index 5ee55da..f5f2855 100644 --- a/app/src/main/java/com/example/bpa/view/from/wlgl_activity.java +++ b/app/src/main/java/com/example/bpa/view/from/wlgl_activity.java @@ -122,15 +122,15 @@ public class wlgl_activity extends AppCompatActivity implements View.OnClickList String name= edittext.getText().toString(); if(name.isEmpty()){ T.show(this, "物料名称不能为空!"); + return; } if(QueryDB.GetMaterialIs(name)){ T.show(this, "物料名称重复,请重新输入后重试!"); + return; } - BPA_MATERIAL bpa_material=new BPA_MATERIAL(); bpa_material.name=name; bpa_material.imgUrl=""; - bpa_material.deviceID= ConfigName.getInstance().DeviceId; bpa_material.userID=ConfigName.getInstance().user.userID; QueryDB.AddMaterial(bpa_material); diff --git a/app/src/main/res/layout/datatab/layout/wl_item.xml b/app/src/main/res/layout/datatab/layout/wl_item.xml index 71396e2..f178c30 100644 --- a/app/src/main/res/layout/datatab/layout/wl_item.xml +++ b/app/src/main/res/layout/datatab/layout/wl_item.xml @@ -3,10 +3,10 @@ xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" - android:layout_marginTop="10dp" - android:layout_marginBottom="10dp"> + android:background="@mipmap/dpbj" + android:orientation="horizontal"> diff --git a/app/src/main/res/layout/from/layout/activity_wlgl.xml b/app/src/main/res/layout/from/layout/activity_wlgl.xml index 8dcd6d8..de9c501 100644 --- a/app/src/main/res/layout/from/layout/activity_wlgl.xml +++ b/app/src/main/res/layout/from/layout/activity_wlgl.xml @@ -114,7 +114,7 @@ android:text="新增" android:background="@drawable/btn_button" android:textSize="@dimen/textSize" - android:textColor="@color/white" + android:textColor="@color/foreground" android:layout_marginLeft="5dp" android:layout_gravity="center" android:layout_width="60dp" @@ -146,6 +146,7 @@ android:layout_alignParentBottom="true" android:background="#FF03668F" /> + android:layout_height="match_parent" + android:divider="#00000000" + android:dividerHeight="14dp" + android:paddingLeft="10dp" + android:paddingRight="10dp" + android:paddingTop="10dp"/>