ialog, API) {
$scope.user = user;
// 登录操作
$scope.login = function (customer) {
if (!customer || !customer.mobile) {
Dialog.open({
status: 'error',
content: '账号不能为空'
});
return;
}
if (!customer || !customer.pwd) {
Dialog.open({
status: 'error',
content: '密码不能为空'
});
return;
}
$http.post(API.login + '?rnd='+new Date().getTime(), customer)
.success(function (data) {
if (data.error_no !== 0) {
if (data.error_info) {
Dialog.open({
content: data.error_info
});
}
} else {
window.location.href = 'http://mq.zritc.com:80/check/';
}
});
}
});