Skip to content

Commit

Permalink
feat: 构建资源锁定支持使用只读变量 TencentBlueKing#11425
Browse files Browse the repository at this point in the history
# Reviewed, transaction id: 29933
  • Loading branch information
vhwweng committed Feb 8, 2025
1 parent 48c6f49 commit 48e1053
Showing 1 changed file with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,15 @@
class="env-alias-area-item"
:label="(isAgentEnv && !isReuseJob) ? $t('editPage.environment') : ''"
>
<selector
<select-input
v-if="isReuseJob"
name="value"
:disabled="disabled"
:value="getReuseJobNameByValue(value)"
:options="reuseJobList"
:handle-change="handleSelect"
:list="reuseJobList"
:value="value"
:toggle-visible="toggleAgentList"
>
</selector>
</select-input>
<devops-select
v-else
name="value"
Expand Down Expand Up @@ -114,6 +113,7 @@
import EnumInput from '@/components/atomFormField/EnumInput'
import Selector from '@/components/atomFormField/Selector'
import VuexInput from '@/components/atomFormField/VuexInput'
import SelectInput from '@/components/AtomFormComponent/SelectInput'
import { mapActions } from 'vuex'
export default {
Expand All @@ -123,6 +123,7 @@
FormField,
VuexInput,
Selector,
SelectInput,
DevopsSelect
},
props: {
Expand Down Expand Up @@ -326,6 +327,9 @@
} finally {
this.isLoading = false
}
},
getReuseJobNameByValue (value) {
return this.reuseJobList.find(i => i.id === value)?.name || value
}
}
}
Expand Down

0 comments on commit 48e1053

Please sign in to comment.