@model AdmAskcostDTO;
|
@using DTO;
|
@using zhengcaioa.Models;
|
@{
|
Layout = null;
|
|
//流程相关
|
string shifoubiaoji = ViewBag.shifoubiaoji as string;
|
string sifoudangqian = ViewBag.sifoudangqian as string;
|
string dangqianbuzhou = ViewBag.dangqianbuzhou as string;
|
|
List<WfHistoryDTO> lishiyijian = ViewData["lishiyijian"] as List<WfHistoryDTO>; //历史意见
|
}
|
|
<!DOCTYPE html>
|
<html>
|
<head>
|
<meta charset="utf-8">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
|
<meta name="description" content="">
|
<meta name="author" content="ThemeBucket">
|
<link href="~/css/bootstrap.min.css" rel="stylesheet">
|
<link href="~/css/font-awesome.min.css" rel="stylesheet">
|
<link href="~/css/animate.min.css" rel="stylesheet">
|
<link href="~/css/style.min.css" rel="stylesheet">
|
<link href="~/css/plugins/chosen/chosen.css" rel="stylesheet">
|
<link href="~/js/plugins/layer/skin/layer.css" rel="stylesheet">
|
<link href="~/css/style.min.css" rel="stylesheet">
|
<link href="~/css/plugins/toastr/toastr.min.css" rel="stylesheet" />
|
|
<!-- jqgrid-->
|
<script language="javascript" src="~/js/jquery.min.js" type="text/javascript"></script>
|
<script src="~/js/bootstrap.min.js"></script>
|
|
<!--容器-->
|
<script language="javascript" src="~/js/plugins/chosen/chosen.jquery.js" type="text/javascript"></script>
|
<script language="javascript" src="~/js/plugins/layer/layer.js" type="text/javascript"></script>
|
<script src="~/js/plugins/toastr/toastr.min.js" type="text/javascript"></script>
|
<script language="javascript" src="~/js/common-layout.js" type="text/javascript"></script>
|
<script src="~/js/plugins/layer/laydate/laydate.js" type="text/javascript"></script>
|
<script src="~/js/TUJS.js"></script>
|
|
<style type="text/css">
|
|
div.clearfix > label {
|
padding-top: 8px;
|
}
|
|
.col-md-1.control-label {
|
padding-right: 0px;
|
font-weight: 400;
|
}
|
</style>
|
|
|
</head>
|
|
<body class="gray-bg" style="overflow:auto">
|
<form id="fm" method="post">
|
<div class="wrapper wrapper-content" id="ibox-content" style="padding:15px;">
|
<div class="row">
|
<div class="col-sm-12">
|
<div class="ibox float-e-margins">
|
<div id="div_content" class="ibox-content" style="background-color:white;">
|
<div class="row">
|
<div class="clearfix layer-area" style="padding-bottom:15px;">
|
<label class="text-right col-sm-1 col-md-1 control-label">单据名称<i class="red">*</i></label>
|
<div class="col-sm-2 col-md-2">
|
<input type="text" class="form-control" value="@Model.Tittle" name="tittle" id="tittle" validate="RequiredField" autocomplete="off" readonly="readonly">
|
|
</div>
|
</div>
|
<div class="clearfix layer-area" style="padding-bottom:15px;">
|
<label class="text-right col-sm-1 col-md-1 control-label">申请人<i class="red">*</i></label>
|
<div class="col-sm-2 col-md-2">
|
<input type="text" class="form-control" value="@Model.CreaterName" name="createrName" id="createrName" validate="RequiredField" autocomplete="off" readonly="readonly">
|
|
</div>
|
</div>
|
|
|
<div class="clearfix layer-area" style="padding-bottom:15px;">
|
<label class="text-right col-sm-1 col-md-1 control-label">事由<i class="red">*</i></label>
|
<div class="col-sm-6 col-md-6">
|
<textarea class="form-control bt" id="Remark" name="Remark" maxlength="4000" length="long" style="resize:none;overflow-y:hidden; height:80px;">@Model.Remark</textarea>
|
</div>
|
</div>
|
<div class="clearfix layer-area" style="padding-bottom:15px;">
|
<label class="text-right col-sm-1 col-md-1 control-label">申请费用<i class="red">*</i></label>
|
<div class="col-sm-2 col-md-2">
|
<input class="form-control" id="Cost" name="Cost" type="text" value="@Model.CostName" oninput="if(value.length>10)value=value.slice(0,10)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">
|
</div>
|
</div>
|
|
<div class="clearfix layer-area" style="padding-bottom:15px;" id="shenpiyijian">
|
<label class="text-right col-sm-1 col-md-1 control-label">审批意见</label>
|
<div class="col-sm-6 col-md-6">
|
<textarea class="form-control data" id="Content" name="Content" style="resize:none;overflow-y:hidden; height:80px;" maxlength="500"></textarea>
|
</div>
|
</div>
|
<div class="clearfix layer-area" style="padding-bottom:15px;">
|
<label class="text-right col-sm-1 col-md-1 control-label">历史意见</label>
|
<div class="col-sm-6 col-md-6">
|
<table>
|
@if (lishiyijian.Count > 0)
|
{
|
<tr>
|
<td style="border:1px solid #ccc;width:150px;">步骤 </td>
|
<td style="border:1px solid #ccc;width:150px;"> 批复状态</td>
|
<td style="border:1px solid #ccc;width:150px;">批复时间</td>
|
<td style="border:1px solid #ccc;width:300px;"> 审批意见</td>
|
<td style="border:1px solid #ccc;width:100px;"> 批复人</td>
|
</tr>
|
}
|
|
@foreach (var wfHistory in lishiyijian)
|
{
|
<tr>
|
<td style="border:1px solid #ccc;width:150px;">@wfHistory.Step</td>
|
<td style="border:1px solid #ccc;width:150px;">@wfHistory.ChuliStatusName</td>
|
<td style="border:1px solid #ccc;width:150px;">@wfHistory.ModifytimeName</td>
|
<td style="border:1px solid #ccc;width:300px;">@wfHistory.Content</td>
|
<td style="border:1px solid #ccc;width:100px;">@wfHistory.DeelUserIdName</td>
|
</tr>
|
}
|
</table>
|
</div>
|
</div>
|
<div class="clearfix layer-area" style="padding-bottom:60px;">
|
|
</div>
|
</div>
|
</div>
|
</div>
|
</div>
|
</div>
|
</div>
|
<div class="ibox-content" id="top" style="z-index:100; position:fixed; height:50px; width:100%;bottom:0; text-align: right; padding-top:8px ">
|
<div class="" style="float:right;" data-bootstro-width="500px">
|
<a class="btn btn-success" href="javascript:void(0)" onclick="_pageAutoClose();" style="margin-left:4px; border-radius:4px;">
|
<i class="glyphicon glyphicon-remove"></i> <span class="bold">取消</span>
|
</a>
|
<a class="btn btn-success" id="tijiao" href="javascript:void(0)" onclick="saveSimCost('');" style="margin-left:4px; border-radius:4px;">
|
<i class="glyphicon glyphicon-ok"></i> <span class="bold">提交</span>
|
</a>
|
|
<a class="btn btn-success" id="tongyi" href="javascript:void(0)" onclick="saveSimCost('A');" style="margin-left:4px; border-radius:4px;">
|
<span class="bold">同意</span>
|
</a>
|
|
<a class="btn btn-success" id="jujue" href="javascript:void(0)" onclick="saveSimCost('D');" style="margin-left:4px; border-radius:4px;">
|
<span class="bold">拒绝</span>
|
</a>
|
<input type="hidden" id="id" name="id" value="@Model.Id" />
|
<input type="hidden" id="Tongguojujue" name="Tongguojujue" value="" />
|
<input type="hidden" id="Step" name="Step" value="@dangqianbuzhou" />
|
</div>
|
</div>
|
|
</form>
|
|
<script type="text/javascript">
|
|
var hh = document.body.clientHeight - $("#top").height() * 2 - 50;
|
$("#div_content").height(hh);
|
|
toastr.options = {
|
"closeButton": true,
|
"debug": false,
|
"progressBar": true,
|
"positionClass": "toast-bottom-right",
|
"onclick": null,
|
"showDuration": "300",
|
"hideDuration": "600",
|
"timeOut": "4500",
|
"extendedTimeOut": "600",
|
"showEasing": "swing",
|
"hideEasing": "linear",
|
"showMethod": "fadeIn",
|
"hideMethod": "fadeOut"
|
};
|
|
|
$(function () {
|
|
|
|
|
|
if ("@shifoubiaoji" != "A") {
|
$("input").attr('readonly', true);
|
$("textarea").attr('readonly', true);
|
$(':radio').attr('disabled', true);
|
$(':checkbox').attr('disabled', true);
|
$(':button').attr('disabled', true);
|
//$('a').removeAttr('onclick');
|
$('select').attr('disabled', true);
|
$("#fileUp").attr('disabled', true);
|
|
$('.fujianshanchu').removeAttr('onclick');
|
|
|
if ("@sifoudangqian" == "A") {
|
$("#Content").attr('readonly', false);
|
$('#tijiao').hide();
|
} else {
|
$('#tongyi').hide();
|
$('#jujue').hide();
|
$('#tijiao').hide();
|
$('#shenpiyijian').hide();
|
}
|
|
} else {
|
|
|
//审批相关
|
$('#shenpiyijian').hide();
|
if ("@sifoudangqian" == "A") {
|
$('#tongyi').hide();
|
$('#jujue').hide();
|
} else {
|
$('#tongyi').hide();
|
$('#jujue').hide();
|
$('#tijiao').hide();
|
}
|
|
|
}
|
|
})
|
|
|
// 保存
|
function saveSimCost(tongyi) {
|
|
|
if ($.trim($("#Remark").val()) == '') {
|
toastr.warning("事由不能为空");
|
return;
|
}
|
if ($.trim($("#Cost").val()) == '') {
|
toastr.warning("申请费用不能为空");
|
return;
|
}
|
|
$("#Tongguojujue").val(tongyi);
|
|
$.ajax({
|
type: "POST",
|
url: "/AdmAsk/SaveAskcost",
|
dataType: "json",
|
global: false,
|
data: $('#fm').serialize(),
|
success: function (data) {
|
|
if (data.Result) {
|
parent.layer.msg('提交成功', { icon: 6 });
|
try {
|
_pageAutoClose();//自动关闭页面方法
|
}
|
catch (err) {
|
var pathname = window.location.pathname;
|
var search = window.location.search;
|
parent._CloseTab1(pathname + search);
|
}
|
}
|
else {
|
parent.layer.msg(data.Message, { icon: 5 });
|
}
|
|
},
|
error: function () {
|
parent.layer.msg('失败', { icon: 5 });
|
}
|
});
|
}
|
|
|
function _pageAutoClose() {
|
parent.window._reloadPageData();
|
var index = parent.layer.getFrameIndex(window.name);
|
parent.layer.isRefresh = true;
|
parent.layer.closeAll('loading');
|
parent.layer.close(index);
|
return false;
|
}
|
</script>
|
</body>
|
</html>
|