Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat:Android端添加“自动授权应用”指令,前端UI #260

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/components/StepShow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,10 @@ const getNotes = (text, type) => {
<el-tag size="small" style="margin-right: 10px">清空应用缓存内存</el-tag>
清空应用 {{ step.text }} 缓存内存
</span>
<span v-if="step.stepType === 'appAutoGrantPermissions'">
<el-tag size="small" style="margin-right: 10px">自动授权应用</el-tag>
ZhouYixun marked this conversation as resolved.
Show resolved Hide resolved
授权应用 {{ step.text }} 所声明的权限
</span>
<span v-if="step.stepType === 'toWebView'">
<el-tag size="small" style="margin-right: 10px">切换WebView</el-tag>
WebView名称:{{ step.content }}
Expand Down
28 changes: 28 additions & 0 deletions src/components/StepUpdate.vue
Original file line number Diff line number Diff line change
Expand Up @@ -491,6 +491,10 @@ const androidOptions = ref([
value: 'appReset',
label: '清空App内存缓存',
},
{
value: 'appAutoGrantPermissions',
label: '自动授权App权限',
},
],
},
{
Expand Down Expand Up @@ -1720,6 +1724,30 @@ onMounted(() => {
</el-form-item>
</div>

<div v-if="step.stepType === 'appAutoGrantPermissions'">
<el-alert
show-icon
style="margin-bottom: 10px"
close-text="Get!"
type="info"
title="TIPS: 传递Android应用的App包名,该步骤可实现自动授权被测App所需要的所有权限,作用等价于Appium启动参数中的autoGrantPermissions"
ZhouYixun marked this conversation as resolved.
Show resolved Hide resolved
/>
<el-form-item
prop="text"
label="授权应用"
:rules="{
required: true,
message: '包名不能为空',
trigger: 'blur',
}"
>
<el-input
v-model="step.text"
placeholder="请输入自动授权应用的App包名"
ZhouYixun marked this conversation as resolved.
Show resolved Hide resolved
></el-input>
</el-form-item>
</div>

<div v-if="step.stepType === 'swipeByDefinedDirection'">
<el-form-item
label="方向"
Expand Down