Improve the loop logs view 58/87958/1
authorxg353y <xg353y@intl.att.com>
Fri, 17 May 2019 08:18:34 +0000 (10:18 +0200)
committerxg353y <xg353y@intl.att.com>
Fri, 17 May 2019 08:18:34 +0000 (10:18 +0200)
Move the loop log table down; color the log level; adjust the proportion
of the log attributes; adjust the location of the Loop view and the log
table.

Issue-ID: CLAMP-388
Change-Id: Ifec6da8dfb330304c8adffbb3257d325e234aa17
Signed-off-by: xg353y <xg353y@intl.att.com>
src/main/java/org/onap/clamp/clds/util/drawing/Painter.java
src/main/resources/META-INF/resources/designer/modeler/dist/index.html
src/main/resources/META-INF/resources/designer/scripts/CldsModelService.js

index fe2d5cb..d88a17e 100755 (executable)
@@ -64,7 +64,7 @@ public class Painter {
 
         adjustGraphics2DProperties();
 
-        Point origin = new Point(0, rectHeight / 2);
+        Point origin = new Point(1, rectHeight / 2);
         ImageBuilder ib = new ImageBuilder(g2d, documentBuilder, origin, baseLength, rectHeight);
 
         doTheActualDrawing(collector, microServices, policy, ib);
index ead478a..ab337de 100644 (file)
   ===================================================================
   
   -->
+<style>
+.ERROR{color: red;}
+.WARNING{color: orange;}
+.INFO{color: green;}
+</style>
 
 <html>
 <head>
                        </div>
                </div>
 
-               <div class="canvas" id="js-canvas" style="margin-top: 100px">
+               <div class="canvas" id="js-canvas" style="margin-top: 100px; margin-left: 20px;">
+                       <div id="loop-content">
+                       </div>
+               
                        <label for="loop-log-div" class="col-sm-4 control-label">Loop Logs</label>
-                       <div id="loop-log-div" style="border: 2px solid gray;height: 20vh">
+                       <div id="loop-log-div" style="border: 2px solid gray;height: 20vh; margin-right: 40px;">
                                <div id="loop-log-table-scroll" style="width: 100%;height: 87%;overflow: auto;margin-top: 20px;">
                                        <table id="loop-log-table" style="width: 100%">
                                                <thead>
@@ -57,9 +65,9 @@
                                                </thead>
                                                <tbody>
                                                        <tr ng-repeat="log in loop_logs" ng-class="{reverse: reverse}">
-                                                               <td>{{log.logInstant}}</td>
-                                                               <td>{{log.logType}}</td>
-                                                               <td>{{log.message}}</td>
+                                                               <td width="20%">{{log.logInstant}}</td>
+                                                               <td width="10%" ng-class="log.logType">{{log.logType}}</td>
+                                                               <td width="70">{{log.message}}</td>
                                                        </tr>
                                                </tbody>
                                        </table>
@@ -67,6 +75,7 @@
                        </div>
                </div>
 
+
        </div>
 </body>
 
index a75326d..0cc5c38 100644 (file)
@@ -191,7 +191,7 @@ app
                        var svg = pars;
                            if ($("#svgContainer").length > 0)
                                    $("#svgContainer").remove();
-                           $("#js-canvas").append(
+                           $("#loop-content").append(
                            "<span id=\"svgContainer\">" + svg + "</span>");
                            $("#svgContainer svg").attr('width', '100%');
                            $("#svgContainer svg").attr('height', '100%');