@model string
<div class="main">
    <form class="form-horizontal form-group-sm form ui-validForm" method="post">
        <div class="control-group">
            <label class="control-label">文件名</label>
            <div class="controls">
                <input type="text" id="name" name="name" value="@ViewBag.Name" class="form-control" style="width:200px;" readonly/>
                <span class="help-block"></span>
            </div>
        </div>
        <div class="control-group top_menu_only">
            <label class="control-label" for="content">内容</label>
            <div class="controls">
                <textarea id="content" name="content" style="width:90%;height:80%" class="form-control">@Html.Raw(ViewBag.Content)</textarea>
                <span class="help-block"></span>
            </div>
        </div>
        <div class="control-group postarea">
            <div class="controls">
                <input type="hidden" id="path" name="path" value="@ViewBag.Path" class="form-control"/>
                <button type="button" class="btn btn-sm btn-primary ui-pagePost" data-custom-params="url:'@Url.Action()',callBack:'nothing'" style="display:none">提交</button>
                <button type="button" class="btn btn-sm btn-default ui-closeDialog">关闭</button>
                <span class="help-block"></span>
            </div>
        </div>
    </form>
</div>
<script type="text/javascript">
    var winHeight = $(window).height();
    $("#content").css("height", (winHeight-150) + "px");
    var notRead="@ViewBag.NotRead";
    if(notRead=="true")
    {
        $(".main").html("只能读取文本类型的文件！");
    }
</script>
