增加了新版本uploadify,由于api与旧版不同,不能直接覆盖旧版,修改了dataservice获取时ajax状态的判断
This commit is contained in:
parent
3f896af13f
commit
1353d1753c
|
@ -1,9 +1,13 @@
|
|||
var westdc = {};
|
||||
westdc.dataservice = {
|
||||
//wsn 选择数据
|
||||
choiceData : function(uuid)
|
||||
choiceData : function(uuid,btn)
|
||||
{
|
||||
this.uuid = uuid;
|
||||
_btn = {
|
||||
html : $(btn).html(),
|
||||
onclick : $(btn).attr('onclick')
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
'type':"POST",
|
||||
|
@ -30,6 +34,16 @@ westdc.dataservice = {
|
|||
|
||||
},
|
||||
'timeout': 30000,
|
||||
'beforeSend': function(){
|
||||
$(btn).attr('onclick','');
|
||||
$(btn).html("加载中...");
|
||||
$(btn).addClass('disabled');
|
||||
},
|
||||
'complete': function(){
|
||||
$(btn).attr('onclick', _btn.onclick);
|
||||
$(btn).html(_btn.html);
|
||||
$(btn).removeClass('disabled');
|
||||
},
|
||||
'error': function(){
|
||||
alert('出现错误,请刷新后重试');
|
||||
}
|
||||
|
@ -113,6 +127,7 @@ westdc.dataservice.wsn = {
|
|||
this.input = new Array();
|
||||
for(i in data.data)
|
||||
{
|
||||
for(i in data.data)
|
||||
this.li = '<label class="checkbox">'
|
||||
+ '<input type="checkbox" value="' + data.data[i].varid + '" name="siteid[]" checked="checked" /> '
|
||||
+ data.data[i].nameview
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Binary file not shown.
After Width: | Height: | Size: 2.9 KiB |
|
@ -0,0 +1,92 @@
|
|||
/*
|
||||
Uploadify
|
||||
Copyright (c) 2012 Reactive Apps, Ronnie Garcia
|
||||
Released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
|
||||
*/
|
||||
|
||||
.uploadify {
|
||||
position: relative;
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
.uploadify-button {
|
||||
background-color: #505050;
|
||||
background-image: linear-gradient(bottom, #505050 0%, #707070 100%);
|
||||
background-image: -o-linear-gradient(bottom, #505050 0%, #707070 100%);
|
||||
background-image: -moz-linear-gradient(bottom, #505050 0%, #707070 100%);
|
||||
background-image: -webkit-linear-gradient(bottom, #505050 0%, #707070 100%);
|
||||
background-image: -ms-linear-gradient(bottom, #505050 0%, #707070 100%);
|
||||
background-image: -webkit-gradient(
|
||||
linear,
|
||||
left bottom,
|
||||
left top,
|
||||
color-stop(0, #505050),
|
||||
color-stop(1, #707070)
|
||||
);
|
||||
background-position: center top;
|
||||
background-repeat: no-repeat;
|
||||
-webkit-border-radius: 30px;
|
||||
-moz-border-radius: 30px;
|
||||
border-radius: 30px;
|
||||
border: 2px solid #808080;
|
||||
color: #FFF;
|
||||
font: bold 12px Arial, Helvetica, sans-serif;
|
||||
text-align: center;
|
||||
text-shadow: 0 -1px 0 rgba(0,0,0,0.25);
|
||||
width: 100%;
|
||||
}
|
||||
.uploadify:hover .uploadify-button {
|
||||
background-color: #606060;
|
||||
background-image: linear-gradient(top, #606060 0%, #808080 100%);
|
||||
background-image: -o-linear-gradient(top, #606060 0%, #808080 100%);
|
||||
background-image: -moz-linear-gradient(top, #606060 0%, #808080 100%);
|
||||
background-image: -webkit-linear-gradient(top, #606060 0%, #808080 100%);
|
||||
background-image: -ms-linear-gradient(top, #606060 0%, #808080 100%);
|
||||
background-image: -webkit-gradient(
|
||||
linear,
|
||||
left bottom,
|
||||
left top,
|
||||
color-stop(0, #606060),
|
||||
color-stop(1, #808080)
|
||||
);
|
||||
background-position: center bottom;
|
||||
}
|
||||
.uploadify-button.disabled {
|
||||
background-color: #D0D0D0;
|
||||
color: #808080;
|
||||
}
|
||||
.uploadify-queue {
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
.uploadify-queue-item {
|
||||
background-color: #F5F5F5;
|
||||
-webkit-border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
font: 11px Verdana, Geneva, sans-serif;
|
||||
margin-top: 5px;
|
||||
max-width: 350px;
|
||||
padding: 10px;
|
||||
}
|
||||
.uploadify-error {
|
||||
background-color: #FDE5DD !important;
|
||||
}
|
||||
.uploadify-queue-item .cancel a {
|
||||
background: url('uploadify-cancel.png') 0 0 no-repeat;
|
||||
float: right;
|
||||
height: 16px;
|
||||
text-indent: -9999px;
|
||||
width: 16px;
|
||||
}
|
||||
.uploadify-queue-item.completed {
|
||||
background-color: #E5E5E5;
|
||||
}
|
||||
.uploadify-progress {
|
||||
background-color: #E5E5E5;
|
||||
margin-top: 10px;
|
||||
width: 100%;
|
||||
}
|
||||
.uploadify-progress-bar {
|
||||
background-color: #0099FF;
|
||||
height: 3px;
|
||||
width: 1px;
|
||||
}
|
Binary file not shown.
Loading…
Reference in New Issue