<div class="main" id="main">
    <el-form label-position="left" label-width="100px" size="small">
        <el-form-item label-width="0px">
            <el-input v-model="content" type="textarea" rows="25" v-validate="{data:content,dataType:'*',nullMsg:'请输入sql命令！'}"></el-input>
            <span class="help-block validate-tips-box"><i class="el-icon-warning"></i> 请务必遵循sql脚本语法，多条命令用GO换行隔开</span>
        </el-form-item>
    </el-form>
    <div class="footer-submit-bar">
        <el-button type="primary" v-on:click="postSubmit">提交保存</el-button>
        <el-button onclick="closeSelf()">关闭</el-button>
    </div>
</div>
<script type="text/javascript">
    var vueData = { content: "" };
    var vue = new Vue({
        el: "#main",
        data: vueData ,
        methods: {
            postSubmit: function () {
                var validated = this.validateForm({ tipsStyle: 1 });//jquery表单验证
                if (validated)
                {
                    this.submit({ url: "@Url.ActionUrl()", data: vueData});
                }
            },
        },
    });
</script>
