From 1c3962bf9dd0cb3cb5e582fd32e3cfc81dc3b014 Mon Sep 17 00:00:00 2001 From: wanghao Date: Thu, 14 Nov 2024 14:01:04 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=90=E8=97=8F=20=E5=B7=A1=E6=A3=80?= =?UTF-8?q?=E7=BA=BF=E8=B7=AF=E9=80=89=E6=8B=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../jingyuan_mes/device/DeviceRepairInfoActivity.java | 5 +++++ app/src/main/res/layout/activity_device_check.xml | 1 + 2 files changed, 6 insertions(+) diff --git a/app/src/main/java/com/example/jingyuan_mes/device/DeviceRepairInfoActivity.java b/app/src/main/java/com/example/jingyuan_mes/device/DeviceRepairInfoActivity.java index 2f5efe7..d1795da 100644 --- a/app/src/main/java/com/example/jingyuan_mes/device/DeviceRepairInfoActivity.java +++ b/app/src/main/java/com/example/jingyuan_mes/device/DeviceRepairInfoActivity.java @@ -112,6 +112,11 @@ public class DeviceRepairInfoActivity extends BaseActivity implements DisposalFi // 开始维修 public void startRepair(View view) { + if (submitBeen.getDeviceCode()==null){ + Toast.makeText(context, "数据异常", Toast.LENGTH_LONG).show(); + return; + } + if (!submitBeen.getDeviceCode().equals(deviceCode)) { Toast.makeText(context, "设备扫描错误", Toast.LENGTH_LONG).show(); return; diff --git a/app/src/main/res/layout/activity_device_check.xml b/app/src/main/res/layout/activity_device_check.xml index 3d4766f..3454f80 100644 --- a/app/src/main/res/layout/activity_device_check.xml +++ b/app/src/main/res/layout/activity_device_check.xml @@ -31,6 +31,7 @@ android:layout_height="44dp" android:layout_marginTop="8dp" android:layout_marginEnd="4dp" + android:visibility="gone" android:background="@drawable/text_bg">