生成二维码

This commit is contained in:
2026-05-25 16:51:53 +08:00
parent fd84f18e4d
commit 95e2d9a3bf
18 changed files with 647 additions and 40 deletions

View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@color/white" />
<stroke
android:width="1dp"
android:color="@color/green" />
<corners android:radius="8dp" />
</shape>

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@color/green" />
<corners android:radius="8dp" />
</shape>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

@@ -116,6 +116,28 @@
android:layout_gravity="center"
android:src="@mipmap/loge" />
</FrameLayout>
<!-- 使用智能文字和图标 -->
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="16dp"
android:gravity="center_vertical">
<ImageView
android:layout_width="20dp"
android:layout_height="20dp"
android:src="@drawable/syis" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:text="@string/use_smart_defense_app"
android:textColor="@color/black"
android:textSize="14sp" />
</LinearLayout>
<!-- 说明文字 -->
<TextView
android:id="@+id/tvTips"
@@ -125,7 +147,9 @@
android:text="@string/invite_code_tips"
android:textColor="@color/gray"
android:textSize="12sp"
android:lineSpacingMultiplier="1.2" />
android:lineSpacingMultiplier="1.2"
android:padding="12dp" />
</LinearLayout>
<!-- 其他邀请方式 -->
@@ -169,4 +193,38 @@
android:src="@drawable/right_back" />
</LinearLayout>
<!-- 底部按钮区域 -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="16dp"
android:layout_marginTop="42dp"
android:layout_marginBottom="10dp"
android:orientation="horizontal"
android:gravity="bottom">
<android.widget.Button
android:id="@+id/btnCancelInvite"
android:layout_width="0dp"
android:layout_height="48dp"
android:layout_weight="1"
android:layout_marginEnd="12dp"
android:text="@string/cancel_invite"
android:textColor="@color/green"
android:textSize="16sp"
android:background="@drawable/bg_blue_border_round"
android:textAllCaps="false" />
<android.widget.Button
android:id="@+id/btnRegenerate"
android:layout_width="0dp"
android:layout_height="48dp"
android:layout_weight="1"
android:text="@string/regenerate"
android:textColor="@color/white"
android:textSize="16sp"
android:background="@drawable/bg_blue_round"
android:textAllCaps="false" />
</LinearLayout>
</LinearLayout>

View File

@@ -418,18 +418,23 @@
<string name="mac_address">MAC地址</string>
<string name="invite_code">邀请码</string>
<string name="invite_code_expire_time">邀请码有效期</string>
<string name="qr_code_invite">二维码邀请</string>
<string name="qr_code_invite">二维码扫码邀请</string>
<string name="invite_code_tips">邀请二维码24小时内有效仅可接受一次手动撤销或重新生成将使原邀请二维码失效</string>
<string name="other_invite_methods">其他邀请方式</string>
<string name="wechat_friend">微信好友</string>
<string name="expire_24h">24小时</string>
<string name="expire_7d">7天</string>
<string name="qr_code_expired">二维码已过期,请重新生成</string>
<string name="generate_failed">生成失败</string>
<string name="revoke_failed">撤销失败</string>
<string name="share_failed">分享失败</string>
<string name="share_poster_tips">邀请二维码有效期%1$s内有效分享只能被接受1次</string>
<string name="invite_friend">快来加入我扫码下载APP</string>
<string name="share_to">分享至</string>
<string name="no_share_app">暂无可用分享应用</string>
<string name="use_smart_defense_app">使用智能防御机管理APP扫码加入</string>
<string name="cancel_invite">撤销邀请</string>
<string name="regenerate">重新生成</string>
<string name="device_no">设备编号</string>
<string name="fw_version">固件版本</string>

View File

@@ -229,6 +229,9 @@
<string name="device_connect_network">Device connecting to the network</string>
<string name="device_connect_near_router">Please move the device closer to the router while connecting to the network</string>
<string name="keep_device_near_router">Please move the device closer to the router</string>
<string name="use_smart_defense_app">Scan code to join via smart defense management APP</string>
<string name="cancel_invite">Cancel Invitation</string>
<string name="regenerate">Regenerate</string>
<!-- Dialog -->
<string name="tip">Tip</string>
@@ -425,13 +428,15 @@
<string name="mac_address">MAC Address</string>
<string name="invite_code">Invite Code</string>
<string name="invite_code_expire_time">Invite Code Expiry</string>
<string name="qr_code_invite">QR Code Scan Invite</string>
<string name="qr_code_invite">Scan QR Code to Invite</string>
<string name="invite_code_tips">Invite QR code is valid for 24 hours; can only be accepted once; manual revocation or regenerating will invalidate the previous invite QR code</string>
<string name="other_invite_methods">Other Invite Methods</string>
<string name="wechat_friend">WeChat Friend</string>
<string name="expire_24h">24h</string>
<string name="expire_7d">7d</string>
<string name="qr_code_expired">QR code has expired, please regenerate</string>
<string name="generate_failed">Generate failed</string>
<string name="revoke_failed">Revoke failed</string>
<string name="share_failed">Share failed</string>
<string name="share_poster_tips">The invitation QR code is valid within %1$s and can only be accepted once</string>
<string name="invite_friend">Come and join me! Scan the QR code to download the app</string>