var dialog = new auiDialog();
function openDialog(type){
switch (type) {
case "text":
dialog.alert({
title:"信息",
msg:neirong,
buttons:['取消','确定']
},function(ret){
console.log(ret)
})
break;
case "input":
dialog.prompt({
title:"交易密码",
text:'默认内容',
inputType : 'password',
type:'number',
buttons:['取消','提交']
},function(ret){
//alert(JSON.stringify(ret['text']));

$.ajax({
url:'http://192.168.0.35/jsz/wx.php/fbmasj/apply',
dataType :'json',
type :'post',
async: false,
data :'&jymm='+ret['text']+'&id='+dataID+'&uid='+uid,
success:function(ms){
//alert(JSON.stringify(ms.data.pw));
if(ms.data.pw == "密码错误"){
alert("交易密码错误!!");
return false;
}else{

cn=1;
}
}
});//ajax结束
if(cn==1){
dialog.prompt({
title:'评价',
text:'请输入评价',
type:'text',
buttons:['确定']
},function(ret){

// alert(cn);
if(reward <= 0){
$("#caina_confirm").html('您确定满意TA的提供吗?');
}
$.ajax({
url:'http://192.168.0.35/jsz/wx.php/fbmasj/caina1',
dataType:'json',
type:'POST',
data:'&id='+dataID+'&uid='+uid,
success: function(msg) {
// alert(JSON.stringify(msg.data));
if(msg.data==1){
if(reward > 0){
alert('操作成功');
}else{
alert('谢谢您的评价!');
}

setTimeout(function () {

window.location.href = "fbdmasj_win.html";
}, 1500);
}else if(msg.data == 2){
$('#loading').html('数据异常,请稍后重试...');// layer.msg("数据异常,请稍后重试");

setTimeout(function () {
$('#loading').dialog('close');
}, 1500);
}else if(msg.data == 3){
$('#loading').html('您访问的页面不存在...');//layer.msg("您访问的页面不存在!");

setTimeout(function () {
}, 1500);
}
}
});//ajax结束

});//采纳
};