vm

<script type="text/javascript">
KISSY.use(['bops/js/forced-closure', 'common/js/tip-util'],function(S, forcedClosure, TipUitl){
//保存
S.one('#btnReason').on('click', function(){
TipUitl.confirm('', '确定提交吗?', function(){
var opinion = S.one('input[name=opinion]:checked').val();
new S.IO({
url: '/stationQuit/forcedAudit.json',
data: {
orgId: S.one("#orgId").val(),
stationApplyId: S.one("#stationApplyId").val(),
remarks: S.one("#remarks").val(),
opinion: opinion
},
success: function(res, textStatus, io){
if (!res.hasError) {
if (res.content.success) {
TipUitl.success('审核成功!');
}
else {
TipUitl.error(res.content.exceptionDesc);
}
}
}
});
});
});
});
</script>

KISSY:

KISSY.add('bops/js/forced-closure',function(S, TipUitl){
//停业原因
S.one('#reason').on('change',function(){
if(S.one(this).val() == 'OTHER'){
S.one('.js-reason-other').show();
} else {
S.one('.js-reason-other').hide();
}
}); //保存
S.one('#btnReason').on('click', function(){
TipUitl.confirm('', '确定提交吗?', function(){
if(S.one('#reason').val() == 'OTHER'){
if(S.trim(S.one('#reason-other').val()) === ""){
TipUitl.error('请填写原因!');
return false;
}
} new S.IO({
url: '/stationQuit/forcedClosure.json',
data: {
orgId: S.one("#orgId").val(),
stationApplyId: S.one("#stationApplyId").val(),
reason: S.one('#reason').val(),
remarks: S.one('#reason-other').val()
},
success: function(res, textStatus, io){
if (!res.hasError) {
if (res.content.success) {
TipUitl.success('发送成功!');
}
else {
TipUitl.error(res.content.exceptionDesc);
}
}
}
});
});
});
}, {
requires: ['common/js/tip-util']
});

vm

<script type="text/javascript">
KISSY.use(['bops/js/forced-closure', 'common/js/tip-util'],function(S, forcedClosure, TipUitl){
//保存
S.one('#btnReason').on('click', function(){
TipUitl.confirm('', '确定提交吗?', function(){
var opinion = S.one('input[name=opinion]:checked').val();
new S.IO({
url: '/stationQuit/forcedAudit.json',
data: {
orgId: S.one("#orgId").val(),
stationApplyId: S.one("#stationApplyId").val(),
remarks: S.one("#remarks").val(),
opinion: opinion
},
success: function(res, textStatus, io){
if (!res.hasError) {
if (res.content.success) {
TipUitl.success('审核成功!');
}
else {
TipUitl.error(res.content.exceptionDesc);
}
}
}
});
});
});
});
</script>

KISSY

KISSY.add('bops/js/forced-audit',function(S, TipUitl){
//保存
S.one('#btnReason').on('click', function(){
TipUitl.confirm('', '确定提交吗?', function(){
var opinion = S.one('input[name=opinion]:checked').val();
new S.IO({
url: '/stationQuit/forcedAudit.json',
data: {
orgId: S.one("#orgId").val(),
stationApplyId: S.one("#stationApplyId").val(),
remarks: S.one("#remarks").val(),
opinion: opinion
},
success: function(res, textStatus, io){
if (!res.hasError) {
if (res.content.success) {
TipUitl.success('审核成功!');
}
else {
TipUitl.error(res.content.exceptionDesc);
}
}
}
});
});
});
}, {
requires: ['common/js/tip-util']
});

KISSY对vm的抽取的更多相关文章

  1. 淘宝自己的前端框架KISSY(类似jquery) - 简易指南

    KISSY 是由阿里集团前端工程师们发起创建的一个开源 JS 框架. 具备模块化.高扩展性.组件齐全,接口一致.自主开发.适合多种应用场景等特性. 在以下方面具有一定优势: A.拥有大量的中文文档: ...

  2. GoldenGate抽取Informix数据库安装及配置

    GoldenGate抽取Informix数据库安装及配置 本次测试架构 l  在中间机上安装informix csdk4.10版本,并编译配置unixODBC; l  在中间机上安装ogg for I ...

  3. OGG到OGGAdapter配置详情-从Oracle直接抽取成csv文件

    Oracle Golden Gate是Oracle旗下一款支持异构平台之间高级复制技术,是Oracle力推一种HA高可用产品,简称“OGG”,可以实现Active-Active 双业务中心架构 1.1 ...

  4. Hyper-V2:向VM增加虚拟硬盘

    使用Hyper-V创建VM,在VM成功安装OS之后,发现VM只有一个逻辑盘C,用于存储VM的操作系统.在产品环境中,需要向VM增加虚拟硬盘,便于将数据单独存储在不同的逻辑盘符中.在Hyper-V中,分 ...

  5. 使用rowid抽取数据方法以及大数据量游标卡住的应对

    平时工作的时候,经常会遇到这种事情,从一个大表A中,抽取字段a在一个相对较小B的表的数据,比如,从一个详单表中,抽取几万个用户号码的话单出来.这种时候,一般来说, 做关联查询: create tabl ...

  6. TODO:从数据库中随机抽取一条记录

    TODO:从数据库中随机抽取一条记录 1.最直接,最粗暴的方法先计算记录的总数,然后选择一个从0到记录总数之间的随机数n,利用skip跳过n条记录,这是效率低下的的方法,首先的记录总数,在用skip会 ...

  7. 【NLP】Tika 文本预处理:抽取各种格式文件内容

    Tika常见格式文件抽取内容并做预处理 作者 白宁超 2016年3月30日18:57:08 摘要:本文主要针对自然语言处理(NLP)过程中,重要基础部分抽取文本内容的预处理.首先我们要意识到预处理的重 ...

  8. SQL Server 随机数,随机区间,随机抽取数据rand(),floor(),ceiling(),round(),newid()函数等

    在查询分析器中执行:select rand(),可以看到结果会是类似于这样的随机小数:0.36361513486289558,像这样的小数在实际应用中用得不多,一般要取随机数都会取随机整数.那就看下面 ...

  9. vm.max_map_count

    Virtual memoryedit Elasticsearch uses a hybrid mmapfs / niofs directory by default to store its indi ...

随机推荐

  1. _视图控制对象生命周期-init、viewDidLoad、viewWillAppear、viewDidAppear、viewWillDisappear等的区别及用途

    iOS视图控制对象生命周期-init.viewDidLoad.viewWillAppear.viewDidAppear.viewWillDisappear.viewDidDisappear的区别及用途 ...

  2. MySQL学习笔记(4)

    插入记录① INSERT [INTO] tbl_name [(col_name,-)] {VALUES | VALUE} ({expr | DEFAULT},-),(-),- 可以用表达式或者DEFA ...

  3. javascript how sort() work

    Array.prototype.sort() 方法一般用来对数组中的元素进行排序,既可以对数字排序,也可以对字符串进行排序.如果没有指定比较函数,会根据数组中字符的Unicode编码来进行排序.这对于 ...

  4. char *p 和char *p[]

    char *p 和char *p[]区别 char* p是一个指针,根本没分配内存,他指向的"abc123ABC" 是只读的,不能改变,在下面给他赋值是错的 而char p[]是一 ...

  5. PHP学习遇到的问题

    使用php ob_start()模板生成html 内容无法撑开 生成后主要的内容 <body><warp><main> 生成后这个几个节点总是固定大小,不能被内容撑 ...

  6. POJ1323-Game Prediction

    描述: Suppose there are M people, including you, playing a special card game. At the beginning, each p ...

  7. 常用ajax请求

    JQuery版本的ajax请求:(包括处理WebService中xml字符串) $.ajax({ type: "POST", async: true, url: "&qu ...

  8. 优秀的 Android Studio 插件

    转自:http://www.codeceo.com/article/8-android-studio-plugins.html Android Studio是目前Google官方设计的用于原生Andr ...

  9. Android 快速选择联系人

    Activity 代码如下: /* * Copyright (C) 2009 The Android Open Source Project * * Licensed under the Apache ...

  10. java.util.MissingResourceException解决策

    .properties文件放到当前目录下会报错: 需要放到src文件夹下: