<!DOCTYPE html>
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
<head>
|
<th:block th:include="include :: header('修改报告模板配置')" />
|
<th:block th:include="include :: bootstrap-fileinput-css"/>
|
</head>
|
<body class="white-bg">
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
<form class="form-horizontal m" id="form-template-edit" th:object="${tReportTemplate}">
|
<input name="id" th:field="*{id}" type="hidden">
|
<div class="form-group">
|
<label class="col-sm-3 control-label">[[#{jsp.exam.template.reporttype}]]:</label>
|
<div class="col-sm-8">
|
<select name="reportType" class="form-control m-b" th:with="type=${@dict.getType('report_type')}" required>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{reportType}"></option>
|
</select>
|
</div>
|
</div>
|
<div class="form-group">
|
<label class="col-sm-3 control-label">[[#{jsp.exam.template.templatetype}]]:</label>
|
<div class="col-sm-8">
|
<select name="templateType" class="form-control m-b" th:with="type=${@dict.getType('template_type')}" required>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{templateType}"></option>
|
</select>
|
</div>
|
</div>
|
<div class="form-group">
|
<label class="col-sm-3 control-label">[[#{jsp.exam.template.templatelan}]]:</label>
|
<div class="col-sm-8">
|
<select name="langType" class="form-control m-b" th:with="type=${@dict.getType('lang_type')}" required>
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{langType}"></option>
|
</select>
|
</div>
|
</div>
|
<div class="form-group">
|
<label class="col-sm-3 control-label">[[#{jsp.exam.template.templateaddress}]]:<a download th:if="${tReportTemplate.location != ''}" th:href="${tReportTemplate.location}">-download:</a></label>
|
<div class="col-sm-8">
|
<div class="file-loading">
|
<input id="locationFile" name="locationFile" type="file" multiple >
|
</div>
|
</div>
|
|
</div>
|
</form>
|
</div>
|
<div class="row">
|
<div class="col-sm-offset-5 col-sm-10">
|
<button type="button" class="btn btn-sm btn-primary" onclick="submitHandler()"><i class="fa fa-check"></i>save
|
</button>
|
<button type="button" class="btn btn-sm btn-danger" onclick="closeItem()"><i class="fa fa-reply-all"></i>close
|
</button>
|
</div>
|
</div>
|
<th:block th:include="include :: footer" />
|
<th:block th:include="include :: bootstrap-fileinput-js"/>
|
<script type="text/javascript">
|
var prefix = ctx + "exam/template";
|
$("#form-template-edit").validate({
|
focusCleanup: true
|
});
|
|
function submitHandler() {
|
if ($.validate.form()) {
|
// $.operate.save(prefix + "/edit", $('#form-template-edit').serialize());
|
$.operate.saveFileTab(prefix + "/edit", new FormData(document.forms.namedItem("form-template-edit")));
|
}
|
}
|
|
$(document).ready(function () {
|
$("#locationFile").fileinput({
|
'theme': 'explorer-fas',
|
overwriteInitial: false,
|
initialPreviewAsData: true,
|
showUpload:false,
|
showPreview:false,
|
showBrowse:true
|
});
|
});
|
</script>
|
</body>
|
</html>
|