<!DOCTYPE html>
<html> <head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta charset="utf-8" />
<link href="/static/css/metro.css" rel="stylesheet">
<link href="/static/css/metro-icons.css" rel="stylesheet">
<link href="/static/css/metro-responsive.css" rel="stylesheet">
<link href="/static/css/datatables/autoFill.dataTables.min.css" rel="stylesheet">
<link href="/static/css/datatables/buttons.dataTables.min.css" rel="stylesheet">
<link href="/static/css/datatables/select.dataTables.min.css" rel="stylesheet">
<script src="/static/css/site.css"></script> <script src="/static/js/jquery.min.js"></script>
<script src="/static/js/metro.js"></script>
<script src="/static/js/datatables/jquery.dataTables.min.js"></script>
<script src="/static/js/datatables/dataTables.buttons.min.js"></script>
<script src="/static/js/datatables/buttons.flash.min.js"></script>
<script src="/static/js/datatables/jszip.min.js"></script>
<script src="/static/js/datatables/pdfmake.min.js"></script>
<script src="/static/js/datatables/vfs_fonts.js"></script>
<script src="/static/js/datatables/buttons.html5.min.js"></script>
<script src="/static/js/datatables/buttons.print.min.js"></script>
<script src="/static/js/datatables/dataTables.select.min.js"></script>
<script src="/static/js/knockout.js"></script>
<script src="/static/js/jquery.tmpl.min.js"></script>
<script src="/static/js/select2.min.js"></script>
<script src="/static/js/site.js"></script>
<script src="/static/js/usp.js"></script>
</head> <body> <h2>corpAdd <button id="btnBack" data-bind="click: usp.admin.corp.add.goBack" class="button place-right primary"><span class="mif-keyboard-return "></span></button></h2>
<hr class="thin bg-grayLighter">
<form data-role="validator" data-hint-mode="hint" data-on-submit="return usp.admin.corp.add.save()">
<div class="grid">
<div class="row cells2">
<div class="cell">
<label>公司名称</label>
<div class="input-control text full-size">
<input type="text" data-bind="value:Name" data-validate-func="required" data-validate-hint-position="top" data-validate-hint="不能为空!" />
<span class="input-state-error mif-warning"></span>
<span class="input-state-success mif-checkmark"></span>
</div>
</div>
<div class="cell">
<label>Parent</label>
<div class="input-control text full-size">
<input type="text" data-bind="value:Type" data-validate-func="required" data-validate-hint-position="top" data-validate-hint="不能为空!" />
<span class="input-state-error mif-warning"></span>
<span class="input-state-success mif-checkmark"></span>
</div>
</div>
</div> </div>
<button data-bind='click:usp.admin.corp.add.save' class="button place-right primary">保存</button>
</form>
<script src="/static/js/usp.admin.corp.add.js"></script>
<script>
$(function() {
usp.init()
usp.admin.corp.add.init()
})
</script> </body>
</html>

html

(function() {
usp.namespace("usp.admin.corp.add");
usp.admin.corp.add.viewModel = {
Name: ko.observable(""),
Type: ko.observable(""),
adminLoginName: ko.observable(""),
adminPassWord: ko.observable(""),
};
usp.admin.corp.add.init = function() {
ko.applyBindings(usp.admin.corp.add.viewModel);
};
usp.admin.corp.add.goBack = function() {
window.location.href = "/admin/Corp/List"
};
usp.admin.corp.add.save = function() {
$.ajax({
url: "Add",
data: ko.toJS(usp.admin.corp.add.viewModel),
async: false,
success: function(data) {
if (data.status) {
usp.Notify('系统信息', '保存成功', 'success')
usp.admin.corp.add.goBack()
} else {
usp.Notify('系统信息', data.info, 'alert')
}
}
})
return false;
}
})(this);

usp.admin.corp.add.js

metroui的更多相关文章

  1. 使用bootstrap和metroui设计的微网站或手机app界面

    今天使用bootstrap和metroui设计了一个metro风格的移动app或者微信微网站的界面 程序的源代码可以从此处获得:https://github.com/mz121star/weixin- ...

  2. Metro-UI系统-2-color和icon

    1.上图 Color icon 2. 怎么用 2.1 color使用 <!--1,设置背景和前景色--> <div class="tile bg-blue fg-white ...

  3. Metro-UI系统-1-tile标签

    一 效果图 二 各个效果的详解 1,简单磁贴 <div class="tile" data-role="title"> <!--定义一个磁贴- ...

  4. 优秀工具推荐:超实用的 CSS 库,样板和框架

    当启动一个新的项目,使用 CSS 框架或样板,可以帮助您节省大量的时间.在这篇文章中,我编译整理了我最喜欢的 CSS 样板,框架和库,帮助你在建立网站或应用程序时更加高效. 您可能感兴趣的相关文章 精 ...

  5. WPF 自定义Metro Style窗体

    为了使WPF程序在不同版本的操作系统上保持一致的显示效果,我们需要重写WPF控件样式.这篇博客将展示如何创建一个Metro Style的WPF窗体. 首先先看一下最终窗体的效果图, 通过截图我们可以看 ...

  6. 在ASP.NET 5中如何方便的添加前端库

    (此文章同时发表在本人微信公众号“dotNET每日精华文章”,欢迎右边二维码来关注.) 题记:ASP.NET 5和之前的ASP.NET版本有很大的不同,其中之一就是对前端库的管理不再使用Nuget,而 ...

  7. 使用SharePoint Designer定制开发员工工作日志系统实例!

    昨天已介绍了一篇<使用SharePoint Designer定制开发专家库系统实例!>,今天继续来介绍使用SharePoint Designer定制开发员工工作日志系统实例,主要功能包括填 ...

  8. 转--2014年最新810多套android源码2.46GB免费一次性打包下载

    转载自:http://www.eoeandroid.com/thread-497046-1-1.html 感谢该博客主人无私奉献~~ 下面的源码是从今年3月份开始不断整理源码区和其他网站上的安卓例子源 ...

  9. 10.12_win8风格,把专业书籍当小说看,SQLite

    (1)CSS:Metro UI CSS(Metroui) 是一套实现了 Windows 8 的 Metro 风格界面的 CSS 框架..官网.BootMetro . (2)[开源访谈]CecOS作者 ...

随机推荐

  1. [Beego模型] 一、ORM 使用方法

    [Beego模型] 一.ORM 使用方法 [Beego模型] 二.CRUD 操作 [Beego模型] 三.高级查询 [Beego模型] 四.使用SQL语句进行查询 [Beego模型] 五.构造查询 [ ...

  2. gson的简单使用方法

    gson和其他现有java json类库最大的不同时gson需要序列化得实体类不需要使用annotation来标识需要序列化得字段,同时gson又可以通过使用annotation来灵活配置需要序列化的 ...

  3. 【T07】不要低估tcp的性能

    1.tcp在ip的基础上增加了校验和.可靠性和流量控制的功能,而udp只增加了校验和的功能,看起来udp应该会比tcp快很多, 但事实不是这样,有时候tcp比udp的性能还要好. 2.思考,在什么情况 ...

  4. WIN10平板 如何修改网络IP地址为固定

    右击网络,属性,更改适配器设置,然后可以找到当前的无线网络   然后依次点开即可修改IP地址

  5. Load 和 DOMContentLoaded 区别

    Load 事件触发代表页面中的 DOM,CSS,JS,图片已经全部加载完毕. DOMContentLoaded 事件触发代表初始的 HTML 被完全加载和解析,不需要等待 CSS,JS,图片加载.

  6. Failed to execute goal org.mybatis.generator:mybatis-generator-maven-plugin:1.3.2:generate

    (1)将Maven项目先clean,接着install下 (2)运行mvn mybatis-generator:generate命令 注意修改generatorConfig.xml的location: ...

  7. 搭建 WordPress 个人博客

    系统要求:centos 6.8 64位 一. 准备 LNMP 环境 LNMP 是 Linux.Nginx.MySQL 和 PHP 的缩写,是 WordPress 博客系统依赖的基础运行环境.我们先来准 ...

  8. [Aaronyang] 写给自己的WPF4.5 笔记13[二维自定义控件技巧-可视化状态实战,自定义容器,注册类命令,用户控件补充]

     我的文章一定要做到对读者负责,否则就是失败的文章  ---------   www.ayjs.net    aaronyang技术分享 博文摘要:欢迎大家来支持我的<2013-2015 Aar ...

  9. ORA-214 signalled during: ALTER DATABASE MOUNT 问题

    数据库服务器移动了位置,后来再连其数据库发现提示无法连接,大致为“无法为所有新实例创建连接...”,查看alert日志发现有如下错误: starting up 1 dispatcher(s) for ...

  10. Resource interpreted as Stylesheet but transferred with MIME type text/plain

    今天碰到了Resource interpreted as Stylesheet but transferred with MIME type text/plain 这个错误. 原因:在web中配置了f ...