Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
apollo
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
apollo
Commits
9e3b6bd2
Commit
9e3b6bd2
authored
May 19, 2016
by
lepdou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "."
This reverts commit
58d59c1f
.
parent
013ca304
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
108 deletions
+29
-108
apollo-portal/src/main/resources/static/config.html
apollo-portal/src/main/resources/static/config.html
+29
-93
apollo-portal/src/main/resources/static/scripts/controller/app/ConfigNamespaceController.js
...tatic/scripts/controller/app/ConfigNamespaceController.js
+0
-1
apollo-portal/src/main/resources/static/scripts/controller/app/ItemCreateController.js
...ces/static/scripts/controller/app/ItemCreateController.js
+0
-14
No files found.
apollo-portal/src/main/resources/static/config.html
View file @
9e3b6bd2
...
@@ -75,13 +75,13 @@
...
@@ -75,13 +75,13 @@
</div>
</div>
</a>
</a>
<!--<a class="list-group-item" target="_blank" href="/views/config.html?#/appid={{app.appId}}">-->
<!--<a class="list-group-item" target="_blank" href="/views/config.html?#/appid={{app.appId}}">-->
<!--<div class="row">-->
<!--<div class="row">-->
<!--<div class="col-md-2"><img src="../img/plus.png" class="i-20"></div>-->
<!--<div class="col-md-2"><img src="../img/plus.png" class="i-20"></div>-->
<!--<div class="col-md-7 hidden-xs">-->
<!--<div class="col-md-7 hidden-xs">-->
<!--<p class="apps-description">添加集群</p>-->
<!--<p class="apps-description">添加集群</p>-->
<!--</div>-->
<!--</div>-->
<!--</div>-->
<!--</div>-->
<!--</a>-->
<!--</a>-->
<a
class=
"list-group-item"
href=
"namespace.html?#/appid={{pageContext.appId}}&type=link"
>
<a
class=
"list-group-item"
href=
"namespace.html?#/appid={{pageContext.appId}}&type=link"
>
<div
class=
"row"
>
<div
class=
"row"
>
...
@@ -108,8 +108,7 @@
...
@@ -108,8 +108,7 @@
<div
class=
"checkbox"
ng-repeat=
"env in missEnvs"
>
<div
class=
"checkbox"
ng-repeat=
"env in missEnvs"
>
<label>
<label>
<input
type=
"checkbox"
name=
"selectedEnvs[]"
value=
"{{env}}"
<input
type=
"checkbox"
name=
"selectedEnvs[]"
value=
"{{env}}"
ng-checked=
"selectedEnvs.indexOf(env) > -1"
ng-checked=
"selectedEnvs.indexOf(env) > -1"
ng-click=
"toggleSelection(env)"
><span
ng-bind=
"env"
><span/>
ng-click=
"toggleSelection(env)"
><span
ng-bind=
"env"
></span>
</label>
</label>
</div>
</div>
</div>
</div>
...
@@ -117,8 +116,7 @@
...
@@ -117,8 +116,7 @@
</div>
</div>
<div
class=
"modal-footer"
>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
ng-click=
"createEnvs()"
>
添加
ng-click=
"createEnvs()"
>
添加
</button>
</button>
</div>
</div>
</div>
</div>
...
@@ -134,8 +132,7 @@
...
@@ -134,8 +132,7 @@
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-4"
>
<div
class=
"col-md-4"
>
<b
ng-bind=
"namespace.namespace.namespaceName"
></b>
<b
ng-bind=
"namespace.namespace.namespaceName"
></b>
<span
class=
"label label-primary"
<span
class=
"label label-primary"
ng-show=
"namespace.itemModifiedCnt > 0"
>
有修改
ng-show=
"namespace.itemModifiedCnt > 0"
>
有修改
<span
class=
"badge"
ng-bind=
"namespace.itemModifiedCnt"
></span></span>
<span
class=
"badge"
ng-bind=
"namespace.itemModifiedCnt"
></span></span>
</div>
</div>
<div
class=
"col-md-4"
>
<div
class=
"col-md-4"
>
...
@@ -147,14 +144,14 @@
...
@@ -147,14 +144,14 @@
ng-click=
"prepareReleaseNamespace(namespace)"
>
发布
ng-click=
"prepareReleaseNamespace(namespace)"
>
发布
</button>
</button>
<button
type=
"button"
<button
type=
"button"
class=
"btn btn-default btn-sm J_tableview_btn"
>
回滚
class=
"btn btn-default btn-sm J_tableview_btn"
>
回滚
</button>
</button>
<button
type=
"button"
<button
type=
"button"
class=
"btn btn-default btn-sm J_historyview_btn"
>
class=
"btn btn-default btn-sm J_historyview_btn"
>
查看历史版本
查看历史版本
</button>
</button>
<button
type=
"button"
<button
type=
"button"
class=
"btn btn-default btn-sm J_tableview_btn"
>
授权
class=
"btn btn-default btn-sm J_tableview_btn"
>
授权
</button>
</button>
<a
type=
"button"
target=
"_blank"
<a
type=
"button"
target=
"_blank"
href=
"config/sync.html?#/appid={{pageContext.appId}}&env={{pageContext.env}}&clusterName={{pageContext.clusterName}}&namespaceName={{namespace.namespace.namespaceName}}"
href=
"config/sync.html?#/appid={{pageContext.appId}}&env={{pageContext.env}}&clusterName={{pageContext.clusterName}}&namespaceName={{namespace.namespace.namespaceName}}"
...
@@ -176,9 +173,9 @@
...
@@ -176,9 +173,9 @@
ng-click=
"switchView(namespace, 'table')"
>
表格
ng-click=
"switchView(namespace, 'table')"
>
表格
</button>
</button>
<button
type=
"button"
<button
type=
"button"
class=
"btn btn-default btn-sm J_historyview_btn"
class=
"btn btn-default btn-sm J_historyview_btn"
ng-click=
"switchView(namespace, 'history')"
>
ng-click=
"switchView(namespace, 'history')"
>
更改历史
更改历史
</button>
</button>
</div>
</div>
</div>
</div>
...
@@ -199,12 +196,6 @@
...
@@ -199,12 +196,6 @@
ng-show=
"namespace.isTextEditing"
ng-click=
"saveDraft(namespace)"
>
ng-show=
"namespace.isTextEditing"
ng-click=
"saveDraft(namespace)"
>
<span
class=
"glyphicon glyphicon-ok"
aria-hidden=
"true"
></span>
<span
class=
"glyphicon glyphicon-ok"
aria-hidden=
"true"
></span>
</a>
</a>
<a
data-tooltip=
"tooltip"
data-placement=
"bottom"
title=
"添加配置"
ng-show=
"namespace.viewType == 'table'"
data-toggle=
"modal"
data-target=
"#createItem"
>
<span
class=
"glyphicon glyphicon-plus"
aria-hidden=
"true"
></span>
</a>
</div>
</div>
</div>
</div>
</header>
</header>
...
@@ -212,8 +203,7 @@
...
@@ -212,8 +203,7 @@
<!--text view-->
<!--text view-->
<textarea
class=
"form-control"
rows=
"{{namespace.itemCnt}}"
style=
"border-radius: 0px"
<textarea
class=
"form-control"
rows=
"{{namespace.itemCnt}}"
style=
"border-radius: 0px"
ng-show=
"namespace.viewType == 'text'"
ng-show=
"namespace.viewType == 'text'"
ng-disabled=
"!namespace.isTextEditing"
ng-model=
"namespace.text"
ng-disabled=
"!namespace.isTextEditing"
ng-model=
"namespace.text"
ng-bind=
"namespace.text"
>
ng-bind=
"namespace.text"
>
</textarea>
</textarea>
<!--table view-->
<!--table view-->
...
@@ -241,27 +231,25 @@
...
@@ -241,27 +231,25 @@
</thead>
</thead>
<tbody>
<tbody>
<tr
title=
"点击查看"
data-toggle=
"modal"
<tr
title=
"点击查看"
data-toggle=
"modal"
data-target=
"#oldValueModal"
data-target=
"#oldValueModal"
ng-repeat=
"config in namespace.items"
ng-class=
"{warning:config.modified}"
ng-repeat=
"config in namespace.items"
ng-class=
"{warning:config.modified}"
ng-if=
"config.item.key"
ng-if=
"config.item.key"
ng-click=
"watchItem(config.item.key, config.item.value, config.oldValue)"
>
ng-click=
"watchItem(config.item.key, config.item.value, config.oldValue)"
>
<td
width=
"25%"
>
<td
width=
"25%"
>
<span
ng-bind=
"config.item.key | limitTo: 20"
></span>
<span
ng-bind=
"config.item.key | limitTo: 20"
></span>
<span
ng-bind=
"config.item.key.length > 20 ? '...' :''"
></span>
<span
ng-bind=
"config.item.key.length > 20 ? '...' :''"
></span>
</td>
</td>
<td
width=
"30%"
>
<td
width=
"30%"
>
<span
ng-bind=
"config.item.value | limitTo: 20"
></span>
<span
ng-bind=
"config.item.value | limitTo: 20"
></span>
<span
ng-bind=
"config.item.value.length > 20 ? '...': ''"
></span>
<span
ng-bind=
"config.item.value.length > 20 ? '...': ''"
></span>
</td>
</td>
<td
width=
"20%"
>
<td
width=
"20%"
>
<span
ng-bind=
"config.item.comment | limitTo: 20"
></span>
<span
ng-bind=
"config.item.comment | limitTo: 20"
></span>
<span
ng-bind=
"config.item.comment.length > 20 ?'...' : ''"
></span>
<span
ng-bind=
"config.item.comment.length > 20 ?'...' : ''"
></span>
</td>
</td>
<td
width=
"10%"
ng-bind=
"config.item.lastModifiedBy"
>
<td
width=
"10%"
ng-bind=
"config.item.lastModifiedBy"
>
</td>
</td>
<td
width=
"15%"
<td
width=
"15%"
ng-bind=
"config.item.lastModifiedTime | date: 'yyyy-MM-dd HH:mm:ss'"
>
ng-bind=
"config.item.lastModifiedTime | date: 'yyyy-MM-dd HH:mm:ss'"
>
</td>
</td>
</tr>
</tr>
...
@@ -349,14 +337,12 @@
...
@@ -349,14 +337,12 @@
<h4
class=
"modal-title"
>
Commit changes
</h4>
<h4
class=
"modal-title"
>
Commit changes
</h4>
</div>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
>
<textarea
rows=
"4"
class=
"form-control"
style=
"width:570px;"
<textarea
rows=
"4"
class=
"form-control"
style=
"width:570px;"
placeholder=
"Add an optional extended description..."
placeholder=
"Add an optional extended description..."
ng-model=
"commitComment"
></textarea>
ng-model=
"commitComment"
></textarea>
</div>
</div>
<div
class=
"modal-footer"
>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
<button
type=
"button"
class=
"btn btn-primary"
data-dismiss=
"modal"
ng-click=
"commitChange()"
>
ng-click=
"commitChange()"
>
提交
提交
</button>
</button>
</div>
</div>
...
@@ -365,7 +351,7 @@
...
@@ -365,7 +351,7 @@
</div>
</div>
<!--create release modal-->
<!--create release modal-->
<
form
class=
"modal fade form-horizontal"
id=
"releaseModal"
tabindex=
"-1"
role=
"dialog"
ng-submit=
"release()
"
>
<
div
class=
"modal fade"
id=
"releaseModal"
tabindex=
"-1"
role=
"dialog
"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-content"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header panel-primary"
>
<div
class=
"modal-header panel-primary"
>
...
@@ -374,71 +360,22 @@
...
@@ -374,71 +360,22 @@
<h4
class=
"modal-title"
>
发布
</h4>
<h4
class=
"modal-title"
>
发布
</h4>
</div>
</div>
<div
class=
"modal-body"
>
<div
class=
"modal-body"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
Release Name:
</label>
<div
class=
"col-sm-10"
>
<input
type=
"text"
class=
"form-control"
ng-model=
"key"
ng-required=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
Key
</label>
<div
class=
"col-sm-10"
>
<input
type=
"text"
class=
"form-control"
ng-model=
"key"
ng-required=
"true"
>
</div>
</div>
<input
type=
"text"
class=
"form-control"
placeholder=
"input release title"
<input
type=
"text"
class=
"form-control"
placeholder=
"input release title"
ng-model=
"releaseTitle"
ng-required=
"true
"
>
ng-model=
"releaseTitle"
required=
"required
"
>
<textarea
rows=
"4"
class=
"form-control"
style=
"margin-top: 15px;"
ng-model=
"releaseComment"
<textarea
rows=
"4"
class=
"form-control"
style=
"margin-top: 15px;"
ng-model=
"releaseComment"
placeholder=
"Add an optional extended description..."
></textarea>
placeholder=
"Add an optional extended description..."
></textarea>
</div>
</div>
<div
class=
"modal-footer"
>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
关闭
</button>
<button
type=
"submit"
class=
"btn btn-primary"
>
提交
<button
type=
"submit"
class=
"btn btn-primary"
data-dismiss=
"modal"
ng-click=
"release()"
>
提交
</button>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
<form
class=
"modal fade form-horizontal"
id=
"createItem"
role=
"dialog"
ng-controller=
"ItemCreateController"
ng-submit=
"create()"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header panel-primary"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-label=
"Close"
><span
aria-hidden=
"true"
>
×
</span></button>
<h4
class=
"modal-title"
>
添加配置项
</h4>
</div>
<div
class=
"modal-body"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
Key
</label>
<div
class=
"col-sm-10"
>
<input
type=
"text"
class=
"form-control"
ng-model=
"key"
ng-required=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
Value
</label>
<div
class=
"col-sm-10"
>
<input
type=
"text"
class=
"form-control"
ng-model=
"value"
ng-required=
"true"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
>
Comment
</label>
<div
class=
"col-sm-10"
>
<textarea
class=
"form-control"
ng-model=
"comment"
rows=
"4"
></textarea>
</div>
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"submit"
class=
"btn btn-primary"
>
提交
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</
form
>
</
div
>
</div>
</div>
</div>
</div>
...
@@ -482,7 +419,6 @@
...
@@ -482,7 +419,6 @@
<!--controller-->
<!--controller-->
<script
type=
"application/javascript"
src=
"scripts/controller/app/ConfigNamespaceController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/app/ConfigNamespaceController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/app/ConfigBaseInfoController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/app/ConfigBaseInfoController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/controller/app/ItemCreateController.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/PageCommon.js"
></script>
<script
type=
"application/javascript"
src=
"scripts/PageCommon.js"
></script>
...
...
apollo-portal/src/main/resources/static/scripts/controller/app/ConfigNamespaceController.js
View file @
9e3b6bd2
...
@@ -141,7 +141,6 @@ application_module.controller("ConfigNamespaceController",
...
@@ -141,7 +141,6 @@ application_module.controller("ConfigNamespaceController",
releaseNamespace
.
namespace
.
namespaceName
,
$scope
.
releaseTitle
,
releaseNamespace
.
namespace
.
namespaceName
,
$scope
.
releaseTitle
,
$scope
.
releaseComment
).
then
(
$scope
.
releaseComment
).
then
(
function
(
result
)
{
function
(
result
)
{
$
(
'
#releaseModal
'
).
modal
(
'
hide
'
);
toastr
.
success
(
"
发布成功
"
);
toastr
.
success
(
"
发布成功
"
);
//refresh all namespace items
//refresh all namespace items
$rootScope
.
refreshNamespaces
();
$rootScope
.
refreshNamespaces
();
...
...
apollo-portal/src/main/resources/static/scripts/controller/app/ItemCreateController.js
deleted
100644 → 0
View file @
013ca304
application_module
.
controller
(
"
ItemCreateController
"
,
[
'
$rootScope
'
,
'
$scope
'
,
'
$location
'
,
'
toastr
'
,
'
AppService
'
,
'
AppUtil
'
,
function
(
$rootScope
,
$scope
,
$location
,
toastr
,
AppService
,
AppUtil
)
{
$scope
.
create
=
function
()
{
console
.
log
(
"
xx
"
);
};
$scope
.
key
=
'
xx
'
;
}]);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment