我是JHipster和AngularJS的新手。我正在使用JHipster默认登录页面如下:
(function() {
'use strict';
angular
.module('test')
.factory('LoginService', LoginService);
LoginService.$inject = ['$uibModal'];
function LoginService ($uibModal) {
var service = {
open: open
};
var modalInstance = null;
var resetModal = function () {
modalInstance = null;
};
return service;
function open () {
if (modalInstance !== null) return;
modalInstance = $uibModal.open({
animation: true,
templateUrl: 'app/components/login/login.html',
controller: 'LoginController',
controllerAs: 'vm',
resolve: {
translatePartialLoader: ['$translate', '$translatePartialLoader', function ($translate, $translatePartialLoader) {
$translatePartialLoader.addPart('login');
return $translate.refresh();
}]
}
});
modalInstance.result.then(
resetModal,
resetModal
);
}
}
})();
我知道这可能很简单,但如果有人会给我一个资源来阅读或文件。