angularjs,$http(post)
阿新 • • 發佈:2018-07-25
art angular height fun ror his http back 請求 $http(post)
$http({
method: ‘post‘,
url: ‘/BSWQI/start_Cal‘,
dataType: "json",
contentType: "application/json",
data: { app_key: "111", lstData: $scope.relist },
}).then(function successCallback(res) {
// 請求成功執行代碼
var result = res.data;
if (result.status == 200) {
var map = new Map();
$http({
method: ‘post‘,
url: ‘/BSWQI/start_Cal‘,
dataType: "json",
contentType: "application/json",
data: { app_key: "111", lstData: $scope.relist },
}).then(function successCallback(res) {
// 請求成功執行代碼
var result = res.data;
if (result.status == 200) {
var map = new Map();
$("[classname]").each(function (i) { $(this).removeAttr("class"); if ($(this).attr("classname") == map.get(result.data)) { $(this).attr("class", map.get(result.data)); } }); $(document).scrollTop($(document).height());//滾動到最下方 toastr.success(‘評估成功!‘, ‘提示信息!‘); } else { toastr.error(result.msg, "出錯了!"); } })
angularjs,$http(post)