Skip to content

Commit

Permalink
feat:svn/git/代码库变量,默认值应该在代码库设置之后 --story=118994917
Browse files Browse the repository at this point in the history
# Reviewed, transaction id: 14604
  • Loading branch information
terlinhe committed Aug 8, 2024
1 parent 983284e commit c84b690
Showing 1 changed file with 56 additions and 59 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,61 @@
<template>
<section class="bk-form-item">
<form-field
:hide-colon="true"
v-if="isCodelibParam(param.type)"
:label="$t('editPage.codelibParams')"
:is-error="errors.has(`scmType`)"
:error-msg="errors.first(`pipelineParam.scmType`)"
>
<selector
:disabled="disabled"
:list="codeTypeList"
:handle-change="(name, value) => handleCodeTypeChange(name, value)"
name="scmType"
placeholder=""
:value="param.scmType"
></selector>
</form-field>
<form-field
:hide-colon="true"
v-if="isGitParam(param.type)"
:label="$t('editPage.gitRepo')"
:is-error="errors.has(`repoHashId`)"
:error-msg="errors.first(`pipelineParam.repoHashId`)"
>
<request-selector
v-bind="getRepoOption('CODE_GIT,CODE_GITLAB,GITHUB,CODE_TGIT')"
:disabled="disabled"
name="repoHashId"
:value="param.repoHashId"
:handle-change="handleChange"
v-validate="'required'"
:data-vv-scope="'pipelineParam'"
replace-key="{keyword}"
:search-url="getSearchUrl()"
>
</request-selector>
</form-field>
<form-field
:hide-colon="true"
v-if="isSvnParam(param.type)"
:label="$t('editPage.svnParams')"
:is-error="errors.has(`repoHashId`)"
:error-msg="errors.first(`pipelineParam.repoHashId`)"
>
<request-selector
v-bind="getRepoOption('CODE_SVN')"
:disabled="disabled"
name="repoHashId"
:value="param.repoHashId"
:handle-change="handleChange"
v-validate="'required'"
:data-vv-scope="'pipelineParam'"
:replace-key="param.replaceKey"
:search-url="param.searchUrl"
>
</request-selector>
</form-field>
<select-type-param
v-if="isSelectorParam(param.type)"
:param="param"
Expand Down Expand Up @@ -130,27 +186,6 @@
</request-selector>
</form-field>

<form-field
:hide-colon="true"
v-if="isSvnParam(param.type)"
:label="$t('editPage.svnParams')"
:is-error="errors.has(`repoHashId`)"
:error-msg="errors.first(`pipelineParam.repoHashId`)"
>
<request-selector
v-bind="getRepoOption('CODE_SVN')"
:disabled="disabled"
name="repoHashId"
:value="param.repoHashId"
:handle-change="handleChange"
v-validate="'required'"
:data-vv-scope="'pipelineParam'"
:replace-key="param.replaceKey"
:search-url="param.searchUrl"
>
</request-selector>
</form-field>

<form-field
:hide-colon="true"
v-if="isSvnParam(param.type)"
Expand All @@ -167,44 +202,6 @@
></vuex-input>
</form-field>

<form-field
:hide-colon="true"
v-if="isGitParam(param.type)"
:label="$t('editPage.gitRepo')"
:is-error="errors.has(`repoHashId`)"
:error-msg="errors.first(`pipelineParam.repoHashId`)"
>
<request-selector
v-bind="getRepoOption('CODE_GIT,CODE_GITLAB,GITHUB,CODE_TGIT')"
:disabled="disabled"
name="repoHashId"
:value="param.repoHashId"
:handle-change="handleChange"
v-validate="'required'"
:data-vv-scope="'pipelineParam'"
replace-key="{keyword}"
:search-url="getSearchUrl()"
>
</request-selector>
</form-field>

<form-field
:hide-colon="true"
v-if="isCodelibParam(param.type)"
:label="$t('editPage.codelibParams')"
:is-error="errors.has(`scmType`)"
:error-msg="errors.first(`pipelineParam.scmType`)"
>
<selector
:disabled="disabled"
:list="codeTypeList"
:handle-change="(name, value) => handleCodeTypeChange(name, value)"
name="scmType"
placeholder=""
:value="param.scmType"
></selector>
</form-field>

<template v-if="isBuildResourceParam(param.type)">
<form-field
:hide-colon="true"
Expand Down

0 comments on commit c84b690

Please sign in to comment.