var ajax = function () {
mui.ajax(projectPath+'/goods/goodsprice.do', {
dataType: 'json',
type: 'post',//HTTP请求类型
success: function (data) {
//获得服务器响应
// var last = JSON.stringify(data);
// alert(data.goodslist[0].name);
var htmlStr = "";
var list = data.goodslist;
for (var i = 0; i < list.length; i++) {
htmlStr += "<tr id='tr" + i + "'>" +
"<td>" + list[i].name + "</td>" +
"<td>" + list[i].now_price + "¥" + "</td>" +
"<td>" + list[i].difference + "¥" + "</td>";
"</tr>";
}
respnoseEl.innerHTML = htmlStr;
}
});
};