Repository: eagle
Updated Branches:
  refs/heads/master 3af9ac480 -> 2a2b07cb9


[EAGLE-852] Application start button should be disabled when it's running, and 
the same for stop button.

EAGLE-852 Application start button should be disabled when it's running, and 
the same for stop button.
- Add disabled judgment logic.

executable | status  | start button | stop button
---|--- | --- | ---
Y | INITIALIZED | Y | N
Y | STARTING | N | N
Y | RUNNING | N | Y
Y | STOPPING | N | N
Y | STOPPED | N | N
N | INITIALIZED | N | N

https://issues.apache.org/jira/browse/EAGLE-852

Author: chitin <[email protected]>

Closes #767 from chitin/EAGLE-852-startbutton.


Project: http://git-wip-us.apache.org/repos/asf/eagle/repo
Commit: http://git-wip-us.apache.org/repos/asf/eagle/commit/2a2b07cb
Tree: http://git-wip-us.apache.org/repos/asf/eagle/tree/2a2b07cb
Diff: http://git-wip-us.apache.org/repos/asf/eagle/diff/2a2b07cb

Branch: refs/heads/master
Commit: 2a2b07cb960032ec17b48968b02af030d0954c7a
Parents: 3af9ac4
Author: chitin <[email protected]>
Authored: Fri Jan 13 16:52:11 2017 +0800
Committer: Hao Chen <[email protected]>
Committed: Fri Jan 13 16:52:11 2017 +0800

----------------------------------------------------------------------
 .../main/webapp/app/dev/partials/integration/site.html    | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/eagle/blob/2a2b07cb/eagle-server/src/main/webapp/app/dev/partials/integration/site.html
----------------------------------------------------------------------
diff --git 
a/eagle-server/src/main/webapp/app/dev/partials/integration/site.html 
b/eagle-server/src/main/webapp/app/dev/partials/integration/site.html
index a13599d..57a9b8d 100644
--- a/eagle-server/src/main/webapp/app/dev/partials/integration/site.html
+++ b/eagle-server/src/main/webapp/app/dev/partials/integration/site.html
@@ -62,10 +62,16 @@
                                <td class="text-center">
                                        <div class="btn-group btn-group-xs" 
ng-if="app.installed">
                                                <!--button class="btn 
btn-default btn-sm">Monitor</button-->
-                                               <button class="btn btn-default 
btn-sm" ng-click="startApp(app)" ng-if="app.descriptor.executable">
+                                               <button class="btn btn-default 
btn-sm" ng-click="startApp(app)" ng-if="app.descriptor.executable && app.status 
=== 'INITIALIZED'">
                                                        <span class="fa 
fa-play"></span>
                                                </button>
-                                               <button class="btn btn-default 
btn-sm" ng-click="stopApp(app)" ng-if="app.descriptor.executable">
+                                               <button class="btn btn-default 
btn-sm" disabled="disabled" ng-if="app.descriptor.executable && app.status !== 
'INITIALIZED'">
+                                                       <span class="fa 
fa-play"></span>
+                                               </button>
+                                               <button class="btn btn-default 
btn-sm" ng-click="stopApp(app)" ng-if="app.descriptor.executable && app.status 
=== 'RUNNING'">
+                                                       <span class="fa 
fa-stop"></span>
+                                               </button>
+                                               <button class="btn btn-default 
btn-sm" disabled="disabled" ng-if="app.descriptor.executable && app.status !== 
'RUNNING'">
                                                        <span class="fa 
fa-stop"></span>
                                                </button>
                                                <button class="btn btn-default 
btn-sm" disabled="disabled" ng-if="!app.descriptor.executable">

Reply via email to