docs: bypass creating work profile restriction (#242)

Fix CI build pushing
This commit is contained in:
BinTianqi
2026-02-17 15:44:11 +08:00
parent 2cd2ce4449
commit 9cc465f2d6
6 changed files with 39 additions and 14 deletions

View File

@@ -51,11 +51,7 @@ java.lang.IllegalStateException: Not allowed to set the device owner because the
java.lang.IllegalStateException: Not allowed to set the device owner because there are already several users on the device
```
解决办法:
- 删除次级用户。
> [!NOTE]
> 一些系统有应用克隆、儿童空间等功能,它们通常是用户。
解决办法:删除其他用户,包括工作资料、私密空间和应用分身。
### Device owner 已存在
@@ -89,6 +85,19 @@ user limit reached
三星限制了多用户功能,暂无解决办法。
### 创建工作资料
在大部分设备上设置device owner后不能创建工作资料因为系统在设置device owner时会添加`no_add_managed_profile`等用户限制。
Device owner不能修改系统设置的用户限制但如果你有root权限你可以在adb shell中执行以下命令以关闭这个限制。
```shell
pm set-user-restriction no_add_user 0
pm set-user-restriction no_add_managed_profile 0
pm set-user-restriction no_add_private_profile 0
pm set-user-restriction no_add_clone_profile 0
```
## API
OwnDroid提供了一个基于Intent的API。你需要在设置中设置密钥并启用API。括号中的数字是最小的安卓版本。