first commit
This commit is contained in:
324
WebRoot/jsp/whp/plan/WhpSamplingPlanTaskView.jsp
Normal file
324
WebRoot/jsp/whp/plan/WhpSamplingPlanTaskView.jsp
Normal file
@ -0,0 +1,324 @@
|
||||
<!DOCTYPE html
|
||||
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<%@ page language="java" pageEncoding="utf-8" %>
|
||||
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
|
||||
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
|
||||
<style type="text/css">
|
||||
.select2-container .select2-selection--single {
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
}
|
||||
|
||||
.select2-selection__arrow {
|
||||
margin-top: 3px;
|
||||
}
|
||||
|
||||
.foot {
|
||||
display: flex;
|
||||
padding-left: 50px;
|
||||
}
|
||||
|
||||
/*.layout{*/
|
||||
/* display: flex;*/
|
||||
/* padding-left: 15px;*/
|
||||
/*}*/
|
||||
.form-horizontal {
|
||||
padding-top: 20px;
|
||||
|
||||
}
|
||||
|
||||
.select2-container--default .select2-selection--single {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.select2-container--default .select2-selection--single, .select2-selection .select2-selection--single {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.select2-container--default .select2-selection--single .select2-selection__arrow b {
|
||||
border: none;
|
||||
border-style: unset
|
||||
}
|
||||
|
||||
.select2-container--default.select2-container--disabled .select2-selection--single {
|
||||
background-color: #FFFFFF;
|
||||
}
|
||||
|
||||
.right {
|
||||
margin-left: 50px;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
|
||||
samplingEnvConditionDropDownList()
|
||||
sampleAppearanceConditionDropDownList()
|
||||
sampleSupernatantDropDownlist();
|
||||
sampleNatureDropDownList();
|
||||
conditionDropDowntype()
|
||||
});
|
||||
//样品状态
|
||||
function conditionDropDowntype() {
|
||||
var selelct_1Data = jQuery.parseJSON('${sampleStateDropDown}');
|
||||
var selelct_1 = $("#sampleState").select2({
|
||||
data: selelct_1Data,
|
||||
cache: false,
|
||||
placeholder: '全部',//默认文字提示
|
||||
allowClear: true,//允许清空
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // 自定义格式化防止xss注入
|
||||
language: "zh-CN",
|
||||
minimumInputLength: 0,
|
||||
minimumResultsForSearch: 10,//数据超过十个启用搜索框
|
||||
formatResult: function formatRepo(repo) {
|
||||
return repo.text;
|
||||
}, // 函数用来渲染结果
|
||||
formatSelection: function formatRepoSelection(repo) {
|
||||
return repo.text;
|
||||
} // 函数用于呈现当前的选择
|
||||
});
|
||||
|
||||
$(".select2-selection--single").css({'height': '30px', 'paddingTop': '4px'});
|
||||
selelct_1.val('${bean.sampleState}').trigger("change");
|
||||
selelct_1.on("change", function (e) {
|
||||
deptChange();
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
//样品数量刷新
|
||||
function deptChange() {
|
||||
var type = $("#sampleState").val();
|
||||
if (type==1){
|
||||
$("#sampleAmountunit").text('ml')
|
||||
} else {
|
||||
$("#sampleAmountunit").text('g')
|
||||
}
|
||||
}
|
||||
//现场采样情况
|
||||
function samplingEnvConditionDropDownList() {
|
||||
var select_Data = jQuery.parseJSON('${samplingPlanTaskEnvDropDown}');
|
||||
console.log(select_Data);
|
||||
var select_3 = $("#samplingEnv").select2({
|
||||
data: select_Data,
|
||||
cache: false,
|
||||
placeholder: '请选择',//默认文字提示
|
||||
// allowClear: true,//允许清空
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // 自定义格式化防止xss注入
|
||||
language: "zh-CN",
|
||||
minimumInputLength: 0,
|
||||
minimumResultsForSearch: 10,//数据超过十个启用搜索框
|
||||
formatResult: function formatRepo(repo) {
|
||||
return repo.text;
|
||||
}, // 函数用来渲染结果
|
||||
formatSelection: function formatRepoSelection(repo) {
|
||||
return repo.text;
|
||||
} // 函数用于呈现当前的选择
|
||||
});
|
||||
$(".select2-selection--single").css({'height': '30px', 'paddingTop': '4px'});
|
||||
//单选赋值
|
||||
select_3.val('${bean.samplingEnv}').trigger("change");
|
||||
|
||||
}
|
||||
//样品外观
|
||||
function sampleAppearanceConditionDropDownList() {
|
||||
var select_Data = jQuery.parseJSON('${sampleAppearanceDropDown}');
|
||||
console.log(select_Data);
|
||||
var select_3 = $("#sampleAppearance").select2({
|
||||
data: select_Data,
|
||||
cache: false,
|
||||
placeholder: '请选择',//默认文字提示
|
||||
// allowClear: true,//允许清空
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // 自定义格式化防止xss注入
|
||||
language: "zh-CN",
|
||||
minimumInputLength: 0,
|
||||
minimumResultsForSearch: 10,//数据超过十个启用搜索框
|
||||
formatResult: function formatRepo(repo) {
|
||||
return repo.text;
|
||||
}, // 函数用来渲染结果
|
||||
formatSelection: function formatRepoSelection(repo) {
|
||||
return repo.text;
|
||||
} // 函数用于呈现当前的选择
|
||||
});
|
||||
$(".select2-selection--single").css({'height': '30px', 'paddingTop': '4px'});
|
||||
//单选赋值
|
||||
|
||||
select_3.val('${bean.sampleAppearance}').trigger("change");
|
||||
|
||||
}
|
||||
|
||||
//上清液
|
||||
function sampleSupernatantDropDownlist() {
|
||||
var select_Data = jQuery.parseJSON('${sampleSupernatantDropDown}');
|
||||
|
||||
var select_3 = $("#sampleSupernatant").select2({
|
||||
data: select_Data,
|
||||
cache: false,
|
||||
placeholder: '请选择',//默认文字提示
|
||||
// allowClear: true,//允许清空
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // 自定义格式化防止xss注入
|
||||
language: "zh-CN",
|
||||
minimumInputLength: 0,
|
||||
minimumResultsForSearch: 10,//数据超过十个启用搜索框
|
||||
formatResult: function formatRepo(repo) {
|
||||
return repo.text;
|
||||
}, // 函数用来渲染结果
|
||||
formatSelection: function formatRepoSelection(repo) {
|
||||
return repo.text;
|
||||
} // 函数用于呈现当前的选择
|
||||
});
|
||||
$(".select2-selection--single").css({'height': '30px', 'paddingTop': '4px'});
|
||||
//单选赋值
|
||||
if('${bean.sampleSupernatant}'=='')
|
||||
{
|
||||
select_3.val('').trigger("change");
|
||||
}else{
|
||||
|
||||
select_3.val('${bean.sampleSupernatant}').trigger("change");
|
||||
}
|
||||
|
||||
|
||||
} //性质
|
||||
function sampleNatureDropDownList() {
|
||||
var select_Data = jQuery.parseJSON('${sampleNatureDropDown}');
|
||||
|
||||
var select_3 = $("#sampleNature").select2({
|
||||
data: select_Data,
|
||||
cache: false,
|
||||
placeholder: '请选择',//默认文字提示
|
||||
// allowClear: true,//允许清空
|
||||
escapeMarkup: function (markup) {
|
||||
return markup;
|
||||
}, // 自定义格式化防止xss注入
|
||||
language: "zh-CN",
|
||||
minimumInputLength: 0,
|
||||
minimumResultsForSearch: 10,//数据超过十个启用搜索框
|
||||
formatResult: function formatRepo(repo) {
|
||||
return repo.text;
|
||||
}, // 函数用来渲染结果
|
||||
formatSelection: function formatRepoSelection(repo) {
|
||||
return repo.text;
|
||||
} // 函数用于呈现当前的选择
|
||||
});
|
||||
$(".select2-selection--single").css({'height': '30px', 'paddingTop': '4px'});
|
||||
//单选赋值
|
||||
if('${bean.sampleNature}'=='')
|
||||
{
|
||||
select_3.val('').trigger("change");
|
||||
}else{
|
||||
|
||||
select_3.val('${bean.sampleNature}').trigger("change");
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<div class="modal fade" id="subModal">
|
||||
<div class="modal-dialog " style="width: 65%">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">采样详情</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-xs-13">
|
||||
<!-- 新增界面formid强制为editForm -->
|
||||
<form class="form-horizontal" id="editForm" enctype="multipart/form-data">
|
||||
<div id="alertDiv"></div>
|
||||
<%-- <input type="hidden" name="id" value="${user.id }" />--%>
|
||||
<!-- 界面提醒div强制id为alertdiv -->
|
||||
|
||||
<input type="hidden" name="id" id="id" class="form-control" value="${bean.id}">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">* 样品编号:</label>
|
||||
<div class="col-sm-4">
|
||||
<p class="form-control-static">${bean.sampleCode}</p>
|
||||
</div>
|
||||
|
||||
<label class="col-sm-2 control-label">* 地点:</label>
|
||||
<div class="col-sm-4">
|
||||
<p class="form-control-static">${bean.sampleAddress}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">* 现场采样情况:</label>
|
||||
<div class="col-sm-4">
|
||||
|
||||
<select class="form-control" name="samplingEnv" id="samplingEnv"
|
||||
disabled="true" style="width: 100%;height: 34px">
|
||||
</select>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">* 样品外观:</label>
|
||||
<div class="col-sm-4">
|
||||
<select class="form-control" name="sampleAppearance" id="sampleAppearance"
|
||||
disabled="true" style="width: 100%;height: 34px">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
|
||||
<label class="col-sm-2 control-label">* 上清液:</label>
|
||||
<div class="col-sm-4">
|
||||
<select class="form-control" name="sampleSupernatant" id="sampleSupernatant"
|
||||
disabled="true" style="width: 100%;height: 34px">
|
||||
</select>
|
||||
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">* 性质:</label>
|
||||
<div class="col-sm-4">
|
||||
<select class="form-control" name="sampleNature" id="sampleNature"
|
||||
disabled="true" style="width: 100%;height: 34px">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">* 样品状态:</label>
|
||||
<div class="col-sm-4">
|
||||
<select class="form-control" name="sampleState" id="sampleState"
|
||||
disabled="true" style="width: 100%;height: 34px">
|
||||
</select>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">* 样品数量:</label>
|
||||
<div class="col-sm-4">
|
||||
<p class="form-control-static" style="width: 13%; float: left;">${bean.sampleAmount}</p>
|
||||
|
||||
<label name="sampleAmountunit" id="sampleAmountunit"
|
||||
style="padding-top: 7px;">${bean.unit} </label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">* 采样人:</label>
|
||||
<div class="col-sm-4">
|
||||
<p class="form-control-static">${bean.samplingUserName}</p>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">* 采样时间:</label>
|
||||
<div class="col-sm-4">
|
||||
<p class="form-control-static">${bean.samplingTime.substring(0,10)}</p>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default " data-dismiss="modal">关闭
|
||||
</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user