ENDRPrint_12CRelease/.svn/pristine/6f/6fe825591bfa048273676a6deba22486820aec9b.svn-base
2024-08-14 10:58:03 +07:00

43 lines
1.1 KiB
Plaintext

scotchApp.factory('mainPostFactory', function($modal,$http, $templateCache) {
var factory = {};
factory.doCheckLogin = function () {
return $.ajax(doGetPath('/json/doCheckLogin.json'),
{
ajax: true,
dataType: 'json',
type: "POST"
});
};
factory.doAjaxPost = function (url,param) {
return $.ajax(doGetPath(url),
{
ajax: true,
dataType: 'json',
type: "POST",
data:param
});
};
// factory.doHttpPost = function (url,param) {
// return $http({
// url: doGetPath(url),
// method: "POST",
// data: param,
// cache :$templateCache
// });
// }
//
// factory.doHttpJsonP = function (url,param) {
// return $.post(doGetPath(url),
// {
// ajax: true,
// dataType: 'json',
// type: "POST",
// data:param
// });
// }
return factory;
});