Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
superrain51
apollo
提交
c7a6f769
apollo
项目概览
superrain51
/
apollo
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
apollo
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
c7a6f769
编写于
3月 22, 2016
作者:
L
lepdou
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
增长loading bar和toast组件
上级
df1cfb76
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
48 addition
and
13 deletion
+48
-13
apollo-portal/src/main/resources/static/scripts/app.js
apollo-portal/src/main/resources/static/scripts/app.js
+2
-2
apollo-portal/src/main/resources/static/scripts/controller/CreateAppController.js
...esources/static/scripts/controller/CreateAppController.js
+7
-4
apollo-portal/src/main/resources/static/scripts/controller/app/AppInfoController.js
...ources/static/scripts/controller/app/AppInfoController.js
+3
-3
apollo-portal/src/main/resources/static/vendor/angular/angular-toastr-1.4.1.min.css
...ources/static/vendor/angular/angular-toastr-1.4.1.min.css
+1
-0
apollo-portal/src/main/resources/static/vendor/angular/angular-toastr-1.4.1.tpls.min.js
...es/static/vendor/angular/angular-toastr-1.4.1.tpls.min.js
+1
-0
apollo-portal/src/main/resources/static/vendor/angular/loading-bar.min.css
.../main/resources/static/vendor/angular/loading-bar.min.css
+1
-0
apollo-portal/src/main/resources/static/vendor/angular/loading-bar.min.js
...c/main/resources/static/vendor/angular/loading-bar.min.js
+7
-0
apollo-portal/src/main/resources/static/views/app/index.html
apollo-portal/src/main/resources/static/views/app/index.html
+13
-0
apollo-portal/src/main/resources/static/views/common/footer.html
...portal/src/main/resources/static/views/common/footer.html
+1
-4
apollo-portal/src/main/resources/static/views/create-app.html
...lo-portal/src/main/resources/static/views/create-app.html
+12
-0
未找到文件。
apollo-portal/src/main/resources/static/scripts/app.js
浏览文件 @
c7a6f769
...
...
@@ -3,9 +3,9 @@ var appService = angular.module('app.service', ['ngResource']);
/** page module 定义*/
//项目主页
var
application_module
=
angular
.
module
(
'
application
'
,
[
'
ngResource
'
,
'
ui.router
'
,
'
app.service
'
]);
var
application_module
=
angular
.
module
(
'
application
'
,
[
'
ngResource
'
,
'
ui.router
'
,
'
app.service
'
,
'
toastr
'
,
'
angular-loading-bar
'
]);
//创建项目页面
var
create_app_module
=
angular
.
module
(
'
create_app
'
,
[
'
ngResource
'
,
'
app.service
'
]);
var
create_app_module
=
angular
.
module
(
'
create_app
'
,
[
'
ngResource
'
,
'
toastr
'
,
'
app.service
'
,
'
angular-loading-bar
'
]);
/**router*/
...
...
apollo-portal/src/main/resources/static/scripts/controller/CreateAppController.js
浏览文件 @
c7a6f769
create_app_module
.
controller
(
'
CreateAppController
'
,
[
'
$scope
'
,
'
$window
'
,
'
AppService
'
,
function
(
$scope
,
$window
,
AppService
)
{
create_app_module
.
controller
(
'
CreateAppController
'
,
[
'
$scope
'
,
'
$window
'
,
'
toastr
'
,
'
AppService
'
,
function
(
$scope
,
$window
,
toastr
,
AppService
)
{
//todo 便于测试,后续删掉
$scope
.
app
=
{
...
...
@@ -11,10 +12,12 @@ create_app_module.controller('CreateAppController', ['$scope', '$window', 'AppSe
$scope
.
save
=
function
(){
AppService
.
add
(
$scope
.
app
).
then
(
function
(
result
){
$window
.
location
.
href
=
'
/views/app/index.html?#appid=
'
+
result
.
appId
;
toastr
.
success
(
'
添加成功!
'
);
setInterval
(
function
(){
$window
.
location
.
href
=
'
/views/app/index.html?#appid=
'
+
result
.
appId
;
},
1000
);
},
function
(
result
){
alert
(
'
添加失败!
'
);
toastr
.
error
(
'
添加失败!
'
);
});
};
...
...
apollo-portal/src/main/resources/static/scripts/controller/app/AppInfoController.js
浏览文件 @
c7a6f769
application_module
.
controller
(
"
AppInfoController
"
,
[
"
$scope
"
,
'
$state
'
,
'
$location
'
,
'
AppService
'
,
function
(
$scope
,
$state
,
$location
,
AppService
)
{
application_module
.
controller
(
"
AppInfoController
"
,
[
"
$scope
"
,
'
$state
'
,
'
$location
'
,
'
toastr
'
,
'
AppService
'
,
function
(
$scope
,
$state
,
$location
,
toastr
,
AppService
)
{
$scope
.
appId
=
$location
.
$$url
.
split
(
"
=
"
)[
1
];
AppService
.
load
(
$scope
.
appId
).
then
(
function
(
result
)
{
$scope
.
app
=
result
;
},
function
(
result
){
alert
(
"
加载出错
"
);
toastr
.
error
(
"
加载出错
"
);
});
}]);
apollo-portal/src/main/resources/static/vendor/angular/angular-toastr-1.4.1.min.css
0 → 100644
浏览文件 @
c7a6f769
.toast-title
{
font-weight
:
700
}
.toast-message
{
word-wrap
:
break-word
}
.toast-message
a
,
.toast-message
label
{
color
:
#fff
}
.toast-message
a
:hover
{
color
:
#ccc
;
text-decoration
:
none
}
.toast-close-button
{
position
:
relative
;
right
:
-.3em
;
top
:
-.3em
;
float
:
right
;
font-size
:
20px
;
font-weight
:
700
;
color
:
#fff
;
-webkit-text-shadow
:
0
1px
0
#fff
;
text-shadow
:
0
1px
0
#fff
;
opacity
:
.8
}
.toast-close-button
:focus
,
.toast-close-button
:hover
{
color
:
#000
;
text-decoration
:
none
;
cursor
:
pointer
;
opacity
:
.4
}
button
.toast-close-button
{
padding
:
0
;
cursor
:
pointer
;
background
:
0
0
;
border
:
0
;
-webkit-appearance
:
none
}
.toast-top-center
{
top
:
0
;
right
:
0
;
width
:
100%
}
.toast-bottom-center
{
bottom
:
0
;
right
:
0
;
width
:
100%
}
.toast-top-full-width
{
top
:
0
;
right
:
0
;
width
:
100%
}
.toast-bottom-full-width
{
bottom
:
0
;
right
:
0
;
width
:
100%
}
.toast-top-left
{
top
:
12px
;
left
:
12px
}
.toast-top-right
{
top
:
12px
;
right
:
12px
}
.toast-bottom-right
{
right
:
12px
;
bottom
:
12px
}
.toast-bottom-left
{
bottom
:
12px
;
left
:
12px
}
#toast-container
{
position
:
fixed
;
z-index
:
999999
}
#toast-container
*
{
-moz-box-sizing
:
border-box
;
-webkit-box-sizing
:
border-box
;
box-sizing
:
border-box
}
#toast-container
>
div
{
position
:
relative
;
overflow
:
hidden
;
margin
:
0
0
6px
;
padding
:
15px
15px
15px
50px
;
width
:
300px
;
-moz-border-radius
:
3px
;
-webkit-border-radius
:
3px
;
border-radius
:
3px
;
background-position
:
15px
center
;
background-repeat
:
no-repeat
;
-moz-box-shadow
:
0
0
12px
#999
;
-webkit-box-shadow
:
0
0
12px
#999
;
box-shadow
:
0
0
12px
#999
;
color
:
#fff
;
opacity
:
.8
}
#toast-container
>
:hover
{
-moz-box-shadow
:
0
0
12px
#000
;
-webkit-box-shadow
:
0
0
12px
#000
;
box-shadow
:
0
0
12px
#000
;
opacity
:
1
;
cursor
:
pointer
}
#toast-container
>
.toast-info
{
background-image
:
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=)
!important
}
#toast-container
>
.toast-error
{
background-image
:
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII=)
!important
}
#toast-container
>
.toast-success
{
background-image
:
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg==)
!important
}
#toast-container
>
.toast-warning
{
background-image
:
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=)
!important
}
#toast-container
.toast-bottom-center
>
div
,
#toast-container
.toast-top-center
>
div
{
width
:
300px
;
margin
:
auto
}
#toast-container
.toast-bottom-full-width
>
div
,
#toast-container
.toast-top-full-width
>
div
{
width
:
96%
;
margin
:
auto
}
.toast
{
background-color
:
#030303
}
.toast-success
{
background-color
:
#51a351
}
.toast-error
{
background-color
:
#bd362f
}
.toast-info
{
background-color
:
#2f96b4
}
.toast-warning
{
background-color
:
#f89406
}
.toast-progress
{
position
:
absolute
;
left
:
0
;
bottom
:
0
;
height
:
4px
;
background-color
:
#000
;
opacity
:
.4
}
.toast
{
opacity
:
1
!important
}
.toast.ng-enter
{
opacity
:
0
!important
;
transition
:
opacity
.3s
linear
}
.toast.ng-enter.ng-enter-active
{
opacity
:
1
!important
}
.toast.ng-leave
{
opacity
:
1
;
transition
:
opacity
.3s
linear
}
.toast.ng-leave.ng-leave-active
{
opacity
:
0
!important
}
@media
all
and
(
max-width
:
240px
){
#toast-container
>
div
{
padding
:
8px
8px
8px
50px
;
width
:
11em
}
#toast-container
.toast-close-button
{
right
:
-.2em
;
top
:
-.2em
}}
@media
all
and
(
min-width
:
241px
)
and
(
max-width
:
480px
){
#toast-container
>
div
{
padding
:
8px
8px
8px
50px
;
width
:
18em
}
#toast-container
.toast-close-button
{
right
:
-.2em
;
top
:
-.2em
}}
@media
all
and
(
min-width
:
481px
)
and
(
max-width
:
768px
){
#toast-container
>
div
{
padding
:
15px
15px
15px
50px
;
width
:
25em
}}
\ No newline at end of file
apollo-portal/src/main/resources/static/vendor/angular/angular-toastr-1.4.1.tpls.min.js
0 → 100644
浏览文件 @
c7a6f769
!
function
(){
"
use strict
"
;
function
t
(
t
,
e
,
s
,
n
,
o
,
r
,
a
){
function
i
(
t
){
if
(
t
)
d
(
t
.
toastId
);
else
for
(
var
e
=
0
;
e
<
O
.
length
;
e
++
)
d
(
O
[
e
].
toastId
)}
function
l
(
t
,
e
,
s
){
var
n
=
m
().
iconClasses
.
error
;
return
g
(
n
,
t
,
e
,
s
)}
function
c
(
t
,
e
,
s
){
var
n
=
m
().
iconClasses
.
info
;
return
g
(
n
,
t
,
e
,
s
)}
function
u
(
t
,
e
,
s
){
var
n
=
m
().
iconClasses
.
success
;
return
g
(
n
,
t
,
e
,
s
)}
function
p
(
t
,
e
,
s
){
var
n
=
m
().
iconClasses
.
warning
;
return
g
(
n
,
t
,
e
,
s
)}
function
d
(
e
,
s
){
function
n
(
t
){
for
(
var
e
=
0
;
e
<
O
.
length
;
e
++
)
if
(
O
[
e
].
toastId
===
t
)
return
O
[
e
]}
function
o
(){
return
!
O
.
length
}
var
i
=
n
(
e
);
i
&&!
i
.
deleting
&&
(
i
.
deleting
=!
0
,
i
.
isOpened
=!
1
,
t
.
leave
(
i
.
el
).
then
(
function
(){
i
.
scope
.
options
.
onHidden
&&
i
.
scope
.
options
.
onHidden
(
s
),
i
.
scope
.
$destroy
();
var
t
=
O
.
indexOf
(
i
);
delete
B
[
i
.
scope
.
message
],
O
.
splice
(
t
,
1
);
var
e
=
r
.
maxOpened
;
e
&&
O
.
length
>=
e
&&
O
[
e
-
1
].
open
.
resolve
(),
o
()
&&
(
h
.
remove
(),
h
=
null
,
T
=
a
.
defer
())}))}
function
g
(
t
,
e
,
s
,
n
){
return
angular
.
isObject
(
s
)
&&
(
n
=
s
,
s
=
null
),
v
({
iconClass
:
t
,
message
:
e
,
optionsOverride
:
n
,
title
:
s
})}
function
m
(){
return
angular
.
extend
({},
r
)}
function
f
(
e
){
if
(
h
)
return
T
.
promise
;
h
=
angular
.
element
(
"
<div></div>
"
),
h
.
attr
(
"
id
"
,
e
.
containerId
),
h
.
addClass
(
e
.
positionClass
),
h
.
css
({
"
pointer-events
"
:
"
auto
"
});
var
s
=
angular
.
element
(
document
.
querySelector
(
e
.
target
));
if
(
!
s
||!
s
.
length
)
throw
"
Target for toasts doesn't exist
"
;
return
t
.
enter
(
h
,
s
).
then
(
function
(){
T
.
resolve
()}),
T
.
promise
}
function
v
(
s
){
function
r
(
t
,
e
,
s
){
s
.
allowHtml
?(
t
.
scope
.
allowHtml
=!
0
,
t
.
scope
.
title
=
o
.
trustAsHtml
(
e
.
title
),
t
.
scope
.
message
=
o
.
trustAsHtml
(
e
.
message
)):(
t
.
scope
.
title
=
e
.
title
,
t
.
scope
.
message
=
e
.
message
),
t
.
scope
.
toastType
=
t
.
iconClass
,
t
.
scope
.
toastId
=
t
.
toastId
,
t
.
scope
.
options
=
{
extendedTimeOut
:
s
.
extendedTimeOut
,
messageClass
:
s
.
messageClass
,
onHidden
:
s
.
onHidden
,
onShown
:
s
.
onShown
,
progressBar
:
s
.
progressBar
,
tapToDismiss
:
s
.
tapToDismiss
,
timeOut
:
s
.
timeOut
,
titleClass
:
s
.
titleClass
,
toastClass
:
s
.
toastClass
},
s
.
closeButton
&&
(
t
.
scope
.
options
.
closeHtml
=
s
.
closeHtml
)}
function
i
(){
function
t
(
t
){
for
(
var
e
=
[
"
containerId
"
,
"
iconClasses
"
,
"
maxOpened
"
,
"
newestOnTop
"
,
"
positionClass
"
,
"
preventDuplicates
"
,
"
preventOpenDuplicates
"
,
"
templates
"
],
s
=
0
,
n
=
e
.
length
;
n
>
s
;
s
++
)
delete
t
[
e
[
s
]];
return
t
}
var
e
=
{
toastId
:
C
++
,
isOpened
:
!
1
,
scope
:
n
.
$new
(),
open
:
a
.
defer
()};
return
e
.
iconClass
=
s
.
iconClass
,
s
.
optionsOverride
&&
(
p
=
angular
.
extend
(
p
,
t
(
s
.
optionsOverride
)),
e
.
iconClass
=
s
.
optionsOverride
.
iconClass
||
e
.
iconClass
),
r
(
e
,
s
,
p
),
e
.
el
=
l
(
e
.
scope
),
e
}
function
l
(
t
){
var
s
=
angular
.
element
(
"
<div toast></div>
"
),
n
=
e
.
get
(
"
$compile
"
);
return
n
(
s
)(
t
)}
function
c
(){
return
p
.
maxOpened
&&
O
.
length
<=
p
.
maxOpened
||!
p
.
maxOpened
}
function
u
(){
var
t
=
p
.
preventDuplicates
&&
s
.
message
===
w
,
e
=
p
.
preventOpenDuplicates
&&
B
[
s
.
message
];
return
t
||
e
?
!
0
:(
w
=
s
.
message
,
B
[
s
.
message
]
=!
0
,
!
1
)}
var
p
=
m
();
if
(
!
u
()){
var
g
=
i
();
if
(
O
.
push
(
g
),
p
.
autoDismiss
&&
p
.
maxOpened
>
0
)
for
(
var
v
=
O
.
slice
(
0
,
O
.
length
-
p
.
maxOpened
),
T
=
0
,
$
=
v
.
length
;
$
>
T
;
T
++
)
d
(
v
[
T
].
toastId
);
return
c
()
&&
g
.
open
.
resolve
(),
g
.
open
.
promise
.
then
(
function
(){
f
(
p
).
then
(
function
(){
if
(
g
.
isOpened
=!
0
,
p
.
newestOnTop
)
t
.
enter
(
g
.
el
,
h
).
then
(
function
(){
g
.
scope
.
init
()});
else
{
var
e
=
h
[
0
].
lastChild
?
angular
.
element
(
h
[
0
].
lastChild
):
null
;
t
.
enter
(
g
.
el
,
h
,
e
).
then
(
function
(){
g
.
scope
.
init
()})}})}),
g
}}
var
h
,
C
=
0
,
O
=
[],
w
=
""
,
B
=
{},
T
=
a
.
defer
(),
$
=
{
clear
:
i
,
error
:
l
,
info
:
c
,
remove
:
d
,
success
:
u
,
warning
:
p
};
return
$
}
angular
.
module
(
"
toastr
"
,[]).
factory
(
"
toastr
"
,
t
),
t
.
$inject
=
[
"
$animate
"
,
"
$injector
"
,
"
$document
"
,
"
$rootScope
"
,
"
$sce
"
,
"
toastrConfig
"
,
"
$q
"
]}(),
function
(){
"
use strict
"
;
angular
.
module
(
"
toastr
"
).
constant
(
"
toastrConfig
"
,{
allowHtml
:
!
1
,
autoDismiss
:
!
1
,
closeButton
:
!
1
,
closeHtml
:
"
<button>×</button>
"
,
containerId
:
"
toast-container
"
,
extendedTimeOut
:
1
e3
,
iconClasses
:{
error
:
"
toast-error
"
,
info
:
"
toast-info
"
,
success
:
"
toast-success
"
,
warning
:
"
toast-warning
"
},
maxOpened
:
0
,
messageClass
:
"
toast-message
"
,
newestOnTop
:
!
0
,
onHidden
:
null
,
onShown
:
null
,
positionClass
:
"
toast-top-right
"
,
preventDuplicates
:
!
1
,
preventOpenDuplicates
:
!
1
,
progressBar
:
!
1
,
tapToDismiss
:
!
0
,
target
:
"
body
"
,
templates
:{
toast
:
"
directives/toast/toast.html
"
,
progressbar
:
"
directives/progressbar/progressbar.html
"
},
timeOut
:
5
e3
,
titleClass
:
"
toast-title
"
,
toastClass
:
"
toast
"
})}(),
function
(){
"
use strict
"
;
function
t
(
t
){
function
e
(
t
,
e
,
s
,
n
){
function
o
(){
var
t
=
(
i
-
(
new
Date
).
getTime
())
/
a
*
100
;
e
.
css
(
"
width
"
,
t
+
"
%
"
)}
var
r
,
a
,
i
;
n
.
progressBar
=
t
,
t
.
start
=
function
(
t
){
r
&&
clearInterval
(
r
),
a
=
parseFloat
(
t
),
i
=
(
new
Date
).
getTime
()
+
a
,
r
=
setInterval
(
o
,
10
)},
t
.
stop
=
function
(){
r
&&
clearInterval
(
r
)},
t
.
$on
(
"
$destroy
"
,
function
(){
clearInterval
(
r
)})}
return
{
replace
:
!
0
,
require
:
"
^toast
"
,
templateUrl
:
function
(){
return
t
.
templates
.
progressbar
},
link
:
e
}}
angular
.
module
(
"
toastr
"
).
directive
(
"
progressBar
"
,
t
),
t
.
$inject
=
[
"
toastrConfig
"
]}(),
function
(){
"
use strict
"
;
function
t
(){
this
.
progressBar
=
null
,
this
.
startProgressBar
=
function
(
t
){
this
.
progressBar
&&
this
.
progressBar
.
start
(
t
)},
this
.
stopProgressBar
=
function
(){
this
.
progressBar
&&
this
.
progressBar
.
stop
()}}
angular
.
module
(
"
toastr
"
).
controller
(
"
ToastController
"
,
t
)}(),
function
(){
"
use strict
"
;
function
t
(
t
,
e
,
s
,
n
){
function
o
(
s
,
o
,
r
,
a
){
function
i
(
t
){
return
a
.
startProgressBar
(
t
),
e
(
function
(){
a
.
stopProgressBar
(),
n
.
remove
(
s
.
toastId
)},
t
,
1
)}
function
l
(){
s
.
progressBar
=!
1
,
a
.
stopProgressBar
()}
function
c
(){
return
s
.
options
.
closeHtml
}
var
u
;
if
(
s
.
toastClass
=
s
.
options
.
toastClass
,
s
.
titleClass
=
s
.
options
.
titleClass
,
s
.
messageClass
=
s
.
options
.
messageClass
,
s
.
progressBar
=
s
.
options
.
progressBar
,
c
()){
var
p
=
angular
.
element
(
s
.
options
.
closeHtml
),
d
=
t
.
get
(
"
$compile
"
);
p
.
addClass
(
"
toast-close-button
"
),
p
.
attr
(
"
ng-click
"
,
"
close()
"
),
d
(
p
)(
s
),
o
.
prepend
(
p
)}
s
.
init
=
function
(){
s
.
options
.
timeOut
&&
(
u
=
i
(
s
.
options
.
timeOut
)),
s
.
options
.
onShown
&&
s
.
options
.
onShown
()},
o
.
on
(
"
mouseenter
"
,
function
(){
l
(),
u
&&
e
.
cancel
(
u
)}),
s
.
tapToast
=
function
(){
s
.
options
.
tapToDismiss
&&
s
.
close
(
!
0
)},
s
.
close
=
function
(
t
){
n
.
remove
(
s
.
toastId
,
t
)},
o
.
on
(
"
mouseleave
"
,
function
(){(
0
!==
s
.
options
.
timeOut
||
0
!==
s
.
options
.
extendedTimeOut
)
&&
(
s
.
$apply
(
function
(){
s
.
progressBar
=
s
.
options
.
progressBar
}),
u
=
i
(
s
.
options
.
extendedTimeOut
))})}
return
{
replace
:
!
0
,
templateUrl
:
function
(){
return
s
.
templates
.
toast
},
controller
:
"
ToastController
"
,
link
:
o
}}
angular
.
module
(
"
toastr
"
).
directive
(
"
toast
"
,
t
),
t
.
$inject
=
[
"
$injector
"
,
"
$interval
"
,
"
toastrConfig
"
,
"
toastr
"
]}(),
angular
.
module
(
"
toastr
"
).
run
([
"
$templateCache
"
,
function
(
t
){
t
.
put
(
"
directives/progressbar/progressbar.html
"
,
'
<div class="toast-progress"></div>
\n
'
),
t
.
put
(
"
directives/toast/toast.html
"
,
'
<div class="{{toastClass}} {{toastType}}" ng-click="tapToast()">
\n
<div ng-switch on="allowHtml">
\n
<div ng-switch-default ng-if="title" class="{{titleClass}}">{{title}}</div>
\n
<div ng-switch-default class="{{messageClass}}">{{message}}</div>
\n
<div ng-switch-when="true" ng-if="title" class="{{titleClass}}" ng-bind-html="title"></div>
\n
<div ng-switch-when="true" class="{{messageClass}}" ng-bind-html="message"></div>
\n
</div>
\n
<progress-bar ng-if="progressBar"></progress-bar>
\n
</div>
\n
'
)}]);
\ No newline at end of file
apollo-portal/src/main/resources/static/vendor/angular/loading-bar.min.css
0 → 100644
浏览文件 @
c7a6f769
#loading-bar
,
#loading-bar-spinner
{
pointer-events
:
none
;
-webkit-pointer-events
:
none
;
-webkit-transition
:
350ms
linear
all
;
-moz-transition
:
350ms
linear
all
;
-o-transition
:
350ms
linear
all
;
transition
:
350ms
linear
all
}
#loading-bar-spinner
.ng-enter
,
#loading-bar-spinner
.ng-leave.ng-leave-active
,
#loading-bar
.ng-enter
,
#loading-bar
.ng-leave.ng-leave-active
{
opacity
:
0
}
#loading-bar-spinner
.ng-enter.ng-enter-active
,
#loading-bar-spinner
.ng-leave
,
#loading-bar
.ng-enter.ng-enter-active
,
#loading-bar
.ng-leave
{
opacity
:
1
}
#loading-bar
.bar
{
-webkit-transition
:
width
350ms
;
-moz-transition
:
width
350ms
;
-o-transition
:
width
350ms
;
transition
:
width
350ms
;
background
:
#29d
;
position
:
fixed
;
z-index
:
10002
;
top
:
0
;
left
:
0
;
width
:
100%
;
height
:
2px
;
border-bottom-right-radius
:
1px
;
border-top-right-radius
:
1px
}
#loading-bar
.peg
{
position
:
absolute
;
width
:
70px
;
right
:
0
;
top
:
0
;
height
:
2px
;
opacity
:
.45
;
-moz-box-shadow
:
#29d
1px
0
6px
1px
;
-ms-box-shadow
:
#29d
1px
0
6px
1px
;
-webkit-box-shadow
:
#29d
1px
0
6px
1px
;
box-shadow
:
#29d
1px
0
6px
1px
;
-moz-border-radius
:
100%
;
-webkit-border-radius
:
100%
;
border-radius
:
100%
}
#loading-bar-spinner
{
display
:
block
;
position
:
fixed
;
z-index
:
10002
;
top
:
10px
;
left
:
10px
}
#loading-bar-spinner
.spinner-icon
{
width
:
14px
;
height
:
14px
;
border
:
2px
solid
transparent
;
border-top-color
:
#29d
;
border-left-color
:
#29d
;
border-radius
:
50%
;
-webkit-animation
:
loading-bar-spinner
400ms
linear
infinite
;
-moz-animation
:
loading-bar-spinner
400ms
linear
infinite
;
-ms-animation
:
loading-bar-spinner
400ms
linear
infinite
;
-o-animation
:
loading-bar-spinner
400ms
linear
infinite
;
animation
:
loading-bar-spinner
400ms
linear
infinite
}
@-webkit-keyframes
loading-bar-spinner
{
0
%
{
-webkit-transform
:
rotate
(
0
);
transform
:
rotate
(
0
)}
100
%
{
-webkit-transform
:
rotate
(
360deg
);
transform
:
rotate
(
360deg
)}}
@-moz-keyframes
loading-bar-spinner
{
0
%
{
-moz-transform
:
rotate
(
0
);
transform
:
rotate
(
0
)}
100
%
{
-moz-transform
:
rotate
(
360deg
);
transform
:
rotate
(
360deg
)}}
@-o-keyframes
loading-bar-spinner
{
0
%
{
-o-transform
:
rotate
(
0
);
transform
:
rotate
(
0
)}
100
%
{
-o-transform
:
rotate
(
360deg
);
transform
:
rotate
(
360deg
)}}
@-ms-keyframes
loading-bar-spinner
{
0
%
{
-ms-transform
:
rotate
(
0
);
transform
:
rotate
(
0
)}
100
%
{
-ms-transform
:
rotate
(
360deg
);
transform
:
rotate
(
360deg
)}}
@keyframes
loading-bar-spinner
{
0
%
{
transform
:
rotate
(
0
)}
100
%
{
transform
:
rotate
(
360deg
)}}
\ No newline at end of file
apollo-portal/src/main/resources/static/vendor/angular/loading-bar.min.js
0 → 100644
浏览文件 @
c7a6f769
/*!
* angular-loading-bar v0.8.0
* https://chieffancypants.github.io/angular-loading-bar
* Copyright (c) 2015 Wes Cruver
* License: MIT
*/
!
function
(){
"
use strict
"
;
angular
.
module
(
"
angular-loading-bar
"
,[
"
cfp.loadingBarInterceptor
"
]),
angular
.
module
(
"
chieffancypants.loadingBar
"
,[
"
cfp.loadingBarInterceptor
"
]),
angular
.
module
(
"
cfp.loadingBarInterceptor
"
,[
"
cfp.loadingBar
"
]).
config
([
"
$httpProvider
"
,
function
(
a
){
var
b
=
[
"
$q
"
,
"
$cacheFactory
"
,
"
$timeout
"
,
"
$rootScope
"
,
"
$log
"
,
"
cfpLoadingBar
"
,
function
(
b
,
c
,
d
,
e
,
f
,
g
){
function
h
(){
d
.
cancel
(
j
),
g
.
complete
(),
l
=
0
,
k
=
0
}
function
i
(
b
){
var
d
,
e
=
c
.
get
(
"
$http
"
),
f
=
a
.
defaults
;
!
b
.
cache
&&!
f
.
cache
||
b
.
cache
===!
1
||
"
GET
"
!==
b
.
method
&&
"
JSONP
"
!==
b
.
method
||
(
d
=
angular
.
isObject
(
b
.
cache
)?
b
.
cache
:
angular
.
isObject
(
f
.
cache
)?
f
.
cache
:
e
);
var
g
=
void
0
!==
d
?
void
0
!==
d
.
get
(
b
.
url
):
!
1
;
return
void
0
!==
b
.
cached
&&
g
!==
b
.
cached
?
b
.
cached
:(
b
.
cached
=
g
,
g
)}
var
j
,
k
=
0
,
l
=
0
,
m
=
g
.
latencyThreshold
;
return
{
request
:
function
(
a
){
return
a
.
ignoreLoadingBar
||
i
(
a
)
||
(
e
.
$broadcast
(
"
cfpLoadingBar:loading
"
,{
url
:
a
.
url
}),
0
===
k
&&
(
j
=
d
(
function
(){
g
.
start
()},
m
)),
k
++
,
g
.
set
(
l
/
k
)),
a
},
response
:
function
(
a
){
return
a
&&
a
.
config
?(
a
.
config
.
ignoreLoadingBar
||
i
(
a
.
config
)
||
(
l
++
,
e
.
$broadcast
(
"
cfpLoadingBar:loaded
"
,{
url
:
a
.
config
.
url
,
result
:
a
}),
l
>=
k
?
h
():
g
.
set
(
l
/
k
)),
a
):(
f
.
error
(
"
Broken interceptor detected: Config object not supplied in response:
\n
https://github.com/chieffancypants/angular-loading-bar/pull/50
"
),
a
)},
responseError
:
function
(
a
){
return
a
&&
a
.
config
?(
a
.
config
.
ignoreLoadingBar
||
i
(
a
.
config
)
||
(
l
++
,
e
.
$broadcast
(
"
cfpLoadingBar:loaded
"
,{
url
:
a
.
config
.
url
,
result
:
a
}),
l
>=
k
?
h
():
g
.
set
(
l
/
k
)),
b
.
reject
(
a
)):(
f
.
error
(
"
Broken interceptor detected: Config object not supplied in rejection:
\n
https://github.com/chieffancypants/angular-loading-bar/pull/50
"
),
b
.
reject
(
a
))}}}];
a
.
interceptors
.
push
(
b
)}]),
angular
.
module
(
"
cfp.loadingBar
"
,[]).
provider
(
"
cfpLoadingBar
"
,
function
(){
this
.
autoIncrement
=!
0
,
this
.
includeSpinner
=!
0
,
this
.
includeBar
=!
0
,
this
.
latencyThreshold
=
100
,
this
.
startSize
=
.
02
,
this
.
parentSelector
=
"
body
"
,
this
.
spinnerTemplate
=
'
<div id="loading-bar-spinner"><div class="spinner-icon"></div></div>
'
,
this
.
loadingBarTemplate
=
'
<div id="loading-bar"><div class="bar"><div class="peg"></div></div></div>
'
,
this
.
$get
=
[
"
$injector
"
,
"
$document
"
,
"
$timeout
"
,
"
$rootScope
"
,
function
(
a
,
b
,
c
,
d
){
function
e
(){
k
||
(
k
=
a
.
get
(
"
$animate
"
));
var
e
=
b
.
find
(
n
).
eq
(
0
);
c
.
cancel
(
m
),
r
||
(
d
.
$broadcast
(
"
cfpLoadingBar:started
"
),
r
=!
0
,
v
&&
k
.
enter
(
o
,
e
,
angular
.
element
(
e
[
0
].
lastChild
)),
u
&&
k
.
enter
(
q
,
e
,
angular
.
element
(
e
[
0
].
lastChild
)),
f
(
w
))}
function
f
(
a
){
if
(
r
){
var
b
=
100
*
a
+
"
%
"
;
p
.
css
(
"
width
"
,
b
),
s
=
a
,
t
&&
(
c
.
cancel
(
l
),
l
=
c
(
function
(){
g
()},
250
))}}
function
g
(){
if
(
!
(
h
()
>=
1
)){
var
a
=
0
,
b
=
h
();
a
=
b
>=
0
&&
.
25
>
b
?(
3
*
Math
.
random
()
+
3
)
/
100
:
b
>=
.
25
&&
.
65
>
b
?
3
*
Math
.
random
()
/
100
:
b
>=
.
65
&&
.
9
>
b
?
2
*
Math
.
random
()
/
100
:
b
>=
.
9
&&
.
99
>
b
?.
005
:
0
;
var
c
=
h
()
+
a
;
f
(
c
)}}
function
h
(){
return
s
}
function
i
(){
s
=
0
,
r
=!
1
}
function
j
(){
k
||
(
k
=
a
.
get
(
"
$animate
"
)),
d
.
$broadcast
(
"
cfpLoadingBar:completed
"
),
f
(
1
),
c
.
cancel
(
m
),
m
=
c
(
function
(){
var
a
=
k
.
leave
(
o
,
i
);
a
&&
a
.
then
&&
a
.
then
(
i
),
k
.
leave
(
q
)},
500
)}
var
k
,
l
,
m
,
n
=
this
.
parentSelector
,
o
=
angular
.
element
(
this
.
loadingBarTemplate
),
p
=
o
.
find
(
"
div
"
).
eq
(
0
),
q
=
angular
.
element
(
this
.
spinnerTemplate
),
r
=!
1
,
s
=
0
,
t
=
this
.
autoIncrement
,
u
=
this
.
includeSpinner
,
v
=
this
.
includeBar
,
w
=
this
.
startSize
;
return
{
start
:
e
,
set
:
f
,
status
:
h
,
inc
:
g
,
complete
:
j
,
autoIncrement
:
this
.
autoIncrement
,
includeSpinner
:
this
.
includeSpinner
,
latencyThreshold
:
this
.
latencyThreshold
,
parentSelector
:
this
.
parentSelector
,
startSize
:
this
.
startSize
}}]})}();
\ No newline at end of file
apollo-portal/src/main/resources/static/views/app/index.html
浏览文件 @
c7a6f769
...
...
@@ -5,6 +5,8 @@
<meta
charset=
"UTF-8"
>
<title>
apollo
</title>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../../vendor/bootstrap/css/bootstrap.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../../vendor/angular/angular-toastr-1.4.1.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
media=
'all'
href=
"../../vendor/angular/loading-bar.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../../styles/common-style.css"
>
</head>
...
...
@@ -40,9 +42,20 @@
<div
ng-include=
"'../common/footer.html'"
></div>
<!--angular-->
<script
src=
"../../vendor/angular/angular.min.js"
></script>
<script
src=
"../../vendor/angular/angular-ui-router.min.js"
></script>
<script
src=
"../../vendor/angular/angular-resource.min.js"
></script>
<script
src=
"../../vendor/angular/angular-toastr-1.4.1.tpls.min.js"
></script>
<script
src=
"../../vendor/angular/loading-bar.min.js"
></script>
<!-- jquery.js -->
<script
src=
"../../vendor/jquery.js"
type=
"text/javascript"
></script>
<!-- bootstrap.js -->
<script
src=
"../../vendor/bootstrap/js/bootstrap.min.js"
type=
"text/javascript"
></script>
<!--biz script-->
<script
type=
"application/javascript"
src=
"../../scripts/app.js"
></script>
<script
type=
"application/javascript"
src=
"../../scripts/services/AppService.js"
></script>
...
...
apollo-portal/src/main/resources/static/views/common/footer.html
浏览文件 @
c7a6f769
...
...
@@ -5,10 +5,7 @@
<a
href=
"http://www.ctrip.com"
target=
"_blank"
>
www.ctrip.com
</a>
</p>
</div>
<!-- jquery.js -->
<script
src=
"../../vendor/jquery.js"
type=
"text/javascript"
></script>
<!-- bootstrap.js -->
<script
src=
"../../vendor/bootstrap/js/bootstrap.min.js"
type=
"text/javascript"
></script>
apollo-portal/src/main/resources/static/views/create-app.html
浏览文件 @
c7a6f769
...
...
@@ -4,6 +4,8 @@
<meta
http-equiv=
"Content-Type"
content=
"text/html; charset=UTF-8"
>
<!-- styles -->
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../vendor/bootstrap/css/bootstrap.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../vendor/angular/angular-toastr-1.4.1.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
media=
'all'
href=
"../vendor/angular/loading-bar.min.css"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"../styles/common-style.css"
>
<title>
新建项目
</title>
</head>
...
...
@@ -72,9 +74,19 @@
<div
ng-include=
"'common/footer.html'"
></div>
<!--angular-->
<script
src=
"../vendor/angular/angular.min.js"
></script>
<script
src=
"../vendor/angular/angular-route.min.js"
></script>
<script
src=
"../vendor/angular/angular-resource.min.js"
></script>
<script
src=
"../vendor/angular/angular-toastr-1.4.1.tpls.min.js"
></script>
<script
src=
"../vendor/angular/loading-bar.min.js"
></script>
<!-- jquery.js -->
<script
src=
"../vendor/jquery.js"
type=
"text/javascript"
></script>
<!-- bootstrap.js -->
<script
src=
"../vendor/bootstrap/js/bootstrap.min.js"
type=
"text/javascript"
></script>
<script
type=
"application/javascript"
src=
"../scripts/app.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/services/AppService.js"
></script>
<script
type=
"application/javascript"
src=
"../scripts/controller/CreateAppController.js"
></script>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录