...
|
...
|
@@ -23,6 +23,14 @@ |
|
|
var contextPath = '<%=basePath %>';
|
|
|
</script>
|
|
|
<title>添加工单</title>
|
|
|
<style>
|
|
|
.select2-selection.select2-selection--single {
|
|
|
min-height:40px;
|
|
|
}
|
|
|
.select2-container--default .select2-selection--single .select2-selection__rendered{
|
|
|
line-height:38px;
|
|
|
}
|
|
|
</style>
|
|
|
</head>
|
|
|
<body style="background-color: #444444;font-size: 14px">
|
|
|
|
...
|
...
|
@@ -118,10 +126,21 @@ |
|
|
</div>
|
|
|
|
|
|
<div class="form-group">
|
|
|
<label class="col-sm-1 control-label"><strong>Branch输入:</strong></label>
|
|
|
<div class="col-sm-8">
|
|
|
<input id="inputBranch" name="branch" type="text" value="master" class="form-control"
|
|
|
style="width: 300px"/>
|
|
|
<label class="col-sm-1 control-label"><strong>发布方式:</strong></label>
|
|
|
<div class="col-sm-1" style="width: 110px;" >
|
|
|
<select id="projectDeployType" name="projectDeployType" onchange="deployTypeOnchange(this.value)">
|
|
|
<c:forEach items="${projectDeployTypes }" var="projectDeployType" varStatus="projectDeloyTypeStatus">
|
|
|
<option value="${projectDeployType.key }">${projectDeployType.value }</option>
|
|
|
</c:forEach>
|
|
|
</select>
|
|
|
</div>
|
|
|
<div class="col-sm-7">
|
|
|
<div id="git_deploy_type_div" class="deploy_type_div_class">
|
|
|
<input id="inputBranch" name="branch" type="text" value="master" class="form-control"/>
|
|
|
</div>
|
|
|
<div id="image_deploy_type_div" class="deploy_type_div_class" style="display: none">
|
|
|
<div id="image_content_deploy_div"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
...
|
...
|
@@ -233,6 +252,36 @@ |
|
|
$("#verifier").select2({
|
|
|
});
|
|
|
|
|
|
$("#projectDeployType").select2({
|
|
|
width:"110px"
|
|
|
});
|
|
|
|
|
|
//发布方式选择
|
|
|
function deployTypeOnchange(val){
|
|
|
$(".deploy_type_div_class").hide();
|
|
|
$("#"+val+"_deploy_type_div").show();
|
|
|
if(val=="image"){
|
|
|
$("#image_content_deploy_div").html="";
|
|
|
//加载项目的镜像
|
|
|
var project = $("input[name='project']:checked").val();
|
|
|
var list=[];
|
|
|
if(project){
|
|
|
list=["image1","image2"];
|
|
|
}
|
|
|
var innerHTMLContext = "<select id='imagesList' data-placeholder='Choose One' style='width:400px;'>";
|
|
|
for (var i = 0; i < list.length; i++) {
|
|
|
innerHTMLContext += "<option value='" + list[i] + "'>" + list[i] + "</option>";
|
|
|
}
|
|
|
innerHTMLContext += "</select>";
|
|
|
console.log(innerHTMLContext);
|
|
|
document.getElementById("image_content_deploy_div").innerHTML = innerHTMLContext;
|
|
|
|
|
|
$('#imagesList').select2({
|
|
|
minimumResultsForSearch: -1
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
|
|
|
function toAddReleaseWork() {
|
|
|
$.ajax({
|
|
|
url: contextPath + 'workSystem/checkRole?type=release',
|
...
|
...
|
|