-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.js
101 lines (88 loc) · 4.61 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/**
* AngularJS
* @author vinu <[email protected]>
*/
/**
* Main App Creation
*/
<<<<<<< HEAD
var editviewapp = angular.module('KaakateeyaEmpEdit', ['ui.router', 'ngAnimate', 'ngSanitize', 'ui.bootstrap', 'angular-loading-bar', 'ngAnimate', 'ngIdle', 'ngMaterial',
'ngMessages', 'ngAria', 'ngPassword', 'jcs-autoValidate', 'angularPromiseButtons', 'KaakateeyaRegistration', 'oc.lazyLoad'
]);
editviewapp.apipath = 'http://183.82.0.58:8025/Api/';
// editviewapp.apipath = 'http://183.82.0.58:8010/Api/';
editviewapp.env = 'dev';
=======
var regapp = angular.module('KaakateeyaEmpReg', ['ui.router', 'ngAnimate', 'ngSanitize', 'ui.bootstrap', 'angular-loading-bar', 'ngAnimate', 'ngIdle', 'ngMaterial',
'ngMessages', 'ngAria', 'ngPassword', 'jcs-autoValidate', 'angularPromiseButtons', 'KaakateeyaRegistration', 'oc.lazyLoad'
]);
regapp.apipath = 'http://183.82.0.58:8025/Api/';
// regapp.apipath = 'http://183.82.0.58:8010/Api/';
regapp.env = 'dev';
>>>>>>> d43c54e4e3d91d181712ba9e4a4e2f94ead83678
regapp.GlobalImgPath = 'http://d16o2fcjgzj2wp.cloudfront.net/';
regapp.GlobalImgPathforimage = 'https://s3.ap-south-1.amazonaws.com/kaakateeyaprod/';
regapp.prefixPath = 'Images/ProfilePics/';
regapp.S3PhotoPath = '';
regapp.Mnoimage = regapp.GlobalImgPath + "Images/customernoimages/Mnoimage.jpg";
regapp.Fnoimage = regapp.GlobalImgPath + "Images/customernoimages/Fnoimage.jpg";
regapp.accesspathdots = regapp.GlobalImgPathforimage + regapp.prefixPath;
regapp.BucketName = 'kaakateeyaprod';
regapp.editName = 'edit/:custId/';
regapp.config(['$stateProvider', '$urlRouterProvider', '$locationProvider', '$ocLazyLoadProvider', function($stateProvider, $urlRouterProvider, $locationProvider, $ocLazyLoadProvider) {
var states = [
{ name: 'reg', url: '', subname: [], abstract: true },
{ name: 'reg.basicRegistration', url: '/Education', subname: ['common/directives/datePickerDirective.js'] },
{ name: 'reg.secondaryRegistration', url: '/secondaryRegistrationurl', subname: ['common/directives/datePickerDirective.js'] }
];
$ocLazyLoadProvider.config({
debug: true
});
$urlRouterProvider.otherwise('/Education');
_.each(states, function(item) {
var innerView = {};
var regitem = item.name.slice(4);
innerView = {
"topbar@": {
templateUrl: "templates/topheader.html"
},
"lazyLoadView@": {
templateUrl: 'app/' + regitem + '/index.html',
controller: regitem + 'Ctrl as page'
},
"bottompanel@": {
templateUrl: "templates/footer.html"
}
};
$stateProvider.state(item.name, {
url: item.url,
<<<<<<< HEAD
views: innerView
// resolve: { // Any property in resolve should return a promise and is executed before the view is loaded
// loadMyCtrl: ['$ocLazyLoad', function($ocLazyLoad) {
// // you can lazy load files for an existing module
// var edit = item.name.slice(9);
// if (editviewapp.env === 'dev') {
// return $ocLazyLoad.load(['app/' + edit + '/controller/' + edit + 'ctrl.js', 'app/' + edit + '/model/' + edit + 'Mdl.js', 'app/' + edit + '/service/' + edit + 'service.js', item.subname]);
// } else {
// return $ocLazyLoad.load(['app/' + edit + '/src/script.min.js', item.subname]);
// }
=======
views: innerView,
resolve: { // Any property in resolve should return a promise and is executed before the view is loaded
loadMyCtrl: ['$ocLazyLoad', function($ocLazyLoad) {
// you can lazy load files for an existing module
// var edit = item.name.slice(9);
if (regapp.env === 'dev') {
return $ocLazyLoad.load(['app/' + regitem + '/controller/' + regitem + 'ctrl.js', 'app/' + regitem + '/model/' + regitem + 'Mdl.js', 'app/' + regitem + '/service/' + regitem + 'service.js', item.subname]);
} else {
return $ocLazyLoad.load(['app/' + regitem + '/src/script.min.js', item.subname]);
}
>>>>>>> d43c54e4e3d91d181712ba9e4a4e2f94ead83678
// // return $ocLazyLoad.load(['app/' + edit + '/controller/' + edit + 'ctrl.js', 'app/' + edit + '/model/' + edit + 'Mdl.js', 'app/' + edit + '/service/' + edit + 'service.js', item.subname]);
// }]
// }
});
$locationProvider.html5Mode(true);
});
}]);