| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- @{;
- ViewBag.Title = "表单页面";
- Layout = "~/Views/Shared/_Form.cshtml";
- }
- <script>
- var keyValue = request('keyValue');
- $(function () {
- initControl();
- });
- //初始化控件
- function initControl() {
- //获取表单
- if (!!keyValue) {
- $.SetForm({
- url: "../../BaseManage/Base_Module/GetFormJson",
- param: { keyValue: keyValue },
- success: function (data) {
- $("#form1").SetWebControls(data);
- }
- })
- }
- }
- //保存表单;
- function AcceptClick() {
- if (!$('#form1').Validform()) {
- return false;
- }
- var postData = $("#form1").GetWebControls(keyValue);
- $.SaveForm({
- url: "../../BaseManage/Base_Module/SaveForm?keyValue=" + keyValue,
- param: postData,
- loading: "正在保存数据...",
- success: function () {
- $.currentIframe().$("#gridTable").trigger("reloadGrid");
- }
- })
- }
- </script>
- <div style="margin-top: 20px; margin-right: 30px;">
- <table class="form">
- <tr>
- <td class="formTitle">名称</td>
- <td class="formValue">
- <input id="FullName" type="text" class="form-control" />
- </td>
- <td class="formTitle">导航目标</td>
- <td class="formValue">
- <input id="Target" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <td class="formTitle">允许展开</td>
- <td class="formValue">
- <input id="AllowExpand" type="text" class="form-control" />
- </td>
- <td class="formTitle">备注</td>
- <td class="formValue">
- <input id="Description" type="text" class="form-control" />
- </td>
- </tr>
-
- </table>
- </div>
|