You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@skywalking.apache.org by wu...@apache.org on 2017/12/14 22:41:10 UTC

[incubator-skywalking-ui] branch feature/3.0.2 created (now 10406d8)

This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a change to branch feature/3.0.2
in repository https://gitbox.apache.org/repos/asf/incubator-skywalking-ui.git.


      at 10406d8  change pom version to 3.0.2

This branch includes the following new commits:

     new 9cf7931  1. format the date: startTime, endTime 2. format the log data, change \n\t to </br>
     new 10406d8  change pom version to 3.0.2

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


-- 
To stop receiving notification emails like this one, please contact
['"commits@skywalking.apache.org" <co...@skywalking.apache.org>'].

[incubator-skywalking-ui] 02/02: change pom version to 3.0.2

Posted by wu...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch feature/3.0.2
in repository https://gitbox.apache.org/repos/asf/incubator-skywalking-ui.git

commit 10406d8699451cfb99522dfed1480bf44bf6d95a
Author: pengys5 <80...@qq.com>
AuthorDate: Mon Jun 5 22:01:33 2017 +0800

    change pom version to 3.0.2
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 0fac6f1..b95f571 100644
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
 
     <groupId>com.a.eye</groupId>
     <artifactId>sky-walking-ui</artifactId>
-    <version>3.0.1-2017</version>
+    <version>3.0.2-2017</version>
     <packaging>jar</packaging>
 
     <properties>

-- 
To stop receiving notification emails like this one, please contact
"commits@skywalking.apache.org" <co...@skywalking.apache.org>.

[incubator-skywalking-ui] 01/02: 1. format the date: startTime, endTime 2. format the log data, change \n\t to

Posted by wu...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch feature/3.0.2
in repository https://gitbox.apache.org/repos/asf/incubator-skywalking-ui.git

commit 9cf7931bb5356c24aa5dfcbaeb763b0b43b03009
Author: pengys5 <80...@qq.com>
AuthorDate: Mon Jun 5 21:59:07 2017 +0800

    1. format the date: startTime, endTime
    2. format the log data, change \n\t to </br>
---
 src/main/resources/static/trace/span.html | 14 +++++++-------
 src/main/resources/static/trace/span.js   | 23 +++++++++++++++++++----
 2 files changed, 26 insertions(+), 11 deletions(-)

diff --git a/src/main/resources/static/trace/span.html b/src/main/resources/static/trace/span.html
index a793a24..f61c873 100644
--- a/src/main/resources/static/trace/span.html
+++ b/src/main/resources/static/trace/span.html
@@ -6,8 +6,8 @@
             <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span
                     class="sr-only">Close</span></button>
             <h4 class="modal-title">Span Info</h4>
-            <small class="font-bold">OperationName: {{:on}})</small><br/>
-            <small class="font-bold">{{:st}} - {{:et}}</small>
+            <small class="font-bold">OperationName: {{:operationName}})</small><br/>
+            <small class="font-bold">{{dateFormat:startTime}} - {{dateFormat:endTime}}</small>
         </div>
         <div class="modal-body" style="padding: 0">
             <div class="tabs-container">
@@ -15,7 +15,7 @@
                 <div class="tabs-left">
                     <ul class="nav nav-tabs">
                         <li class="active"><a data-toggle="tab" href="#tags">Tags</a></li>
-                        {{for lo}}
+                        {{for logs}}
                           <li class=""><a data-toggle="tab" href="#logData{{: #index+1}}">Log Data{{: #index+1}}</a></li>
                         {{/for}}
                     </ul>
@@ -33,12 +33,12 @@
                                 {{/props}}
                             </div>
                         </div>
-                        {{for lo}}
+                        {{for logs}}
                         <div id="logData{{: #index+1}}" class="tab-pane">
                             <div class="panel-body">
-                                <strong>time</strong><p>{{:tm}}</p>
-                                {{props fi}}
-                                    <strong>{{>key}}</strong><p>{{>prop}}</p>
+                                <strong>time</strong><p>{{dateFormat:time}}</p>
+                                {{props fields}}
+                                    <strong>{{>key}}</strong><p>{{tabCharacter:prop}}</p>
                                 {{/props}}
                             </div>
                         </div>
diff --git a/src/main/resources/static/trace/span.js b/src/main/resources/static/trace/span.js
index 43d9684..58789b4 100644
--- a/src/main/resources/static/trace/span.js
+++ b/src/main/resources/static/trace/span.js
@@ -5,11 +5,26 @@
 function showSpanModal(spanSegId) {
     $.getJSON("/spanDataLoad?spanSegId=" + spanSegId, function (data) {
         var spanModalTemplate = $.templates("#spanModalTemplate");
-
-        data.st = moment(data.st).format("YYYY/MM/DD HH:mm:ss SSS");
-        data.et = moment(data.et).format("YYYY/MM/DD HH:mm:ss SSS");
-
         spanModalTemplate.link("#spanModalDiv", data);
         $("#spanModalDiv").modal("toggle");
     });
+}
+
+$.views.converters({
+    dateFormat: function (val) {
+        return moment(val).format("YYYY/MM/DD HH:mm:ss SSS");
+    },
+
+    tabCharacter: function (val) {
+        console.log(val);
+        return replaceAll(val);
+    }
+});
+
+function replaceAll(str) {
+    if (str != null){
+        str = str.replace(/\\n\\t/ig, "<br />");
+        str = str.replace(/\\n/ig, "<br />");
+    }
+    return str;
 }
\ No newline at end of file

-- 
To stop receiving notification emails like this one, please contact
"commits@skywalking.apache.org" <co...@skywalking.apache.org>.