You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@submarine.apache.org by GitBox <gi...@apache.org> on 2021/12/16 14:48:43 UTC

[GitHub] [submarine] KUAN-HSUN-LI commented on a change in pull request #832: SUBMARINE-1132. Upgrade model UI and complete fetching functionality

KUAN-HSUN-LI commented on a change in pull request #832:
URL: https://github.com/apache/submarine/pull/832#discussion_r770317655



##########
File path: submarine-workbench/workbench-web/src/app/pages/workbench/model/model-info/model-info.component.scss
##########
@@ -0,0 +1,79 @@
+// /*!
+//  * Licensed to the Apache Software Foundation (ASF) under one
+//  * or more contributor license agreements.  See the NOTICE file
+//  * distributed with this work for additional information
+//  * regarding copyright ownership.  The ASF licenses this file
+//  * to you under the Apache License, Version 2.0 (the
+//  * "License"); you may not use this file except in compliance
+//  * with the License.  You may obtain a copy of the License at
+//  *
+//  *   http://www.apache.org/licenses/LICENSE-2.0
+//  *
+//  * Unless required by applicable law or agreed to in writing,
+//  * software distributed under the License is distributed on an
+//  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+//  * KIND, either express or implied.  See the License for the
+//  * specific language governing permissions and limitations
+//  * under the License.
+//  */
+// .basic-box {

Review comment:
       Please remove the unused code.

##########
File path: submarine-workbench/workbench-web/src/app/pages/workbench/model/model-info/model-info.component.html
##########
@@ -0,0 +1,80 @@
+<!--
+  ~ Licensed to tde Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See tde NOTICE file
+  ~ distributed witd tdis work for additional information
+  ~ regarding copyright ownership.  tde ASF licenses tdis file
+  ~ to you under tde Apache License, Version 2.0 (tde
+  ~ "License"); you may not use tdis file except in compliance
+  ~ witd tde License.  You may obtain a copy of tde License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under tde License is distributed on an
+  ~ "AS IS" BASIS, WItdOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, eitder express or implied.  See tde License for tde
+  ~ specific language governing permissions and limitations
+  ~ under tde License.
+  -->
+<div style="margin: 15px; padding: 15px; background-color: white">
+  <nz-spin [nzSpinning]="isModelInfoLoading">
+    <article nz-typography>
+      <h3 nz-typography>{{modelName}}</h3>
+      <p nz-typography>
+        <span><strong>Description: </strong></span>
+        {{ isModelInfoLoading ? null : selectedModelInfo.description }}
+      </p>
+      <p nz-typography>
+        <span><strong>Tags: </strong></span>
+        <span *ngIf="!isModelInfoLoading">
+          <submarine-model-tag *ngFor="let tag of selectedModelInfo.tags" [tag]="tag" [cssType]="'default'"></submarine-model-tag>
+        </span>
+      </p>

Review comment:
       Is it better to move the tags and description to the last two rows?

##########
File path: submarine-workbench/workbench-web/src/app/pages/workbench/model/model-version/model-version.component.html
##########
@@ -16,20 +16,56 @@
   ~ specific language governing permissions and limitations
   ~ under the License.
   -->
-
 <div style="margin: 15px; padding: 15px; background-color: white">
-  <p>Version: {{ modelVersion }}</p>
-  <p>Description: {{ modelVersionInfo.description }}</p>
-  <p>Tags: {{ modelVersionInfo.tags }}</p>
-  <p>Stage: {{ modelVersionInfo.currentStage }}</p>
-  <h3>Model version info</h3>
-  <p>User id: {{ modelVersionInfo.userId }}</p>
-  <p>
-    Experiment id:
-    <a href="/workbench/experiment/info/{{modelVersionInfo.experimentId}}">{{ modelVersionInfo.experimentId }}</a>
-  </p>
-  <p>Dataset: {{ modelVersionInfo.dataset }}</p>
-  <p>Created: {{ modelVersionInfo.creationTime }}</p>
-  <p>Updated: {{ modelVersionInfo.lastUpdatedTime }}</p>
-  <p>Source: {{ modelVersionInfo.source }}</p>
-</div>
+  <nz-spin [nzSpinning]="isLoading">
+    <article nz-typography>
+      <h3 nz-typography>Version {{ modelVersion }}</h3>
+      <p nz-typography>
+        <span><strong>Description: </strong></span>
+        {{ isLoading ? null : modelVersionInfo.description }}
+      </p>
+      <p nz-typography>
+        <span><strong>Tags: </strong></span>
+        <span  *ngIf="!isLoading">
+          <submarine-model-tag *ngFor="let tag of modelVersionInfo.tags" [tag]="tag" [cssType]="'default'"></submarine-model-tag>
+        </span>
+      </p>

Review comment:
       Same as above.

##########
File path: submarine-workbench/workbench-web/src/app/pages/workbench/model/model-version/model-version.component.html
##########
@@ -16,20 +16,56 @@
   ~ specific language governing permissions and limitations
   ~ under the License.
   -->
-
 <div style="margin: 15px; padding: 15px; background-color: white">
-  <p>Version: {{ modelVersion }}</p>
-  <p>Description: {{ modelVersionInfo.description }}</p>
-  <p>Tags: {{ modelVersionInfo.tags }}</p>
-  <p>Stage: {{ modelVersionInfo.currentStage }}</p>
-  <h3>Model version info</h3>
-  <p>User id: {{ modelVersionInfo.userId }}</p>
-  <p>
-    Experiment id:
-    <a href="/workbench/experiment/info/{{modelVersionInfo.experimentId}}">{{ modelVersionInfo.experimentId }}</a>
-  </p>
-  <p>Dataset: {{ modelVersionInfo.dataset }}</p>
-  <p>Created: {{ modelVersionInfo.creationTime }}</p>
-  <p>Updated: {{ modelVersionInfo.lastUpdatedTime }}</p>
-  <p>Source: {{ modelVersionInfo.source }}</p>
-</div>
+  <nz-spin [nzSpinning]="isLoading">
+    <article nz-typography>
+      <h3 nz-typography>Version {{ modelVersion }}</h3>
+      <p nz-typography>
+        <span><strong>Description: </strong></span>
+        {{ isLoading ? null : modelVersionInfo.description }}
+      </p>
+      <p nz-typography>
+        <span><strong>Tags: </strong></span>
+        <span  *ngIf="!isLoading">
+          <submarine-model-tag *ngFor="let tag of modelVersionInfo.tags" [tag]="tag" [cssType]="'default'"></submarine-model-tag>
+        </span>
+      </p>
+      <p nz-typography>
+        <span><strong>Stage: </strong></span>
+        {{ isLoading ? null : modelVersionInfo.currentStage }}
+      </p>
+      <nz-divider [nzText]="text" nzOrientation="left">
+        <ng-template #text>
+          Model Version Info
+          <i nz-icon nzType="info-circle"></i>
+        </ng-template>

Review comment:
       Can you explain why adding this line?
   I think all of the metadata is model version info.

##########
File path: submarine-workbench/workbench-web/src/app/pages/workbench/model/model-info/model-info.component.html
##########
@@ -0,0 +1,80 @@
+<!--
+  ~ Licensed to tde Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See tde NOTICE file
+  ~ distributed witd tdis work for additional information
+  ~ regarding copyright ownership.  tde ASF licenses tdis file
+  ~ to you under tde Apache License, Version 2.0 (tde
+  ~ "License"); you may not use tdis file except in compliance
+  ~ witd tde License.  You may obtain a copy of tde License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under tde License is distributed on an
+  ~ "AS IS" BASIS, WItdOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, eitder express or implied.  See tde License for tde
+  ~ specific language governing permissions and limitations
+  ~ under tde License.
+  -->
+<div style="margin: 15px; padding: 15px; background-color: white">
+  <nz-spin [nzSpinning]="isModelInfoLoading">
+    <article nz-typography>
+      <h3 nz-typography>{{modelName}}</h3>
+      <p nz-typography>
+        <span><strong>Description: </strong></span>
+        {{ isModelInfoLoading ? null : selectedModelInfo.description }}
+      </p>
+      <p nz-typography>
+        <span><strong>Tags: </strong></span>
+        <span *ngIf="!isModelInfoLoading">
+          <submarine-model-tag *ngFor="let tag of selectedModelInfo.tags" [tag]="tag" [cssType]="'default'"></submarine-model-tag>
+        </span>
+      </p>
+      <p nz-typography>
+        <span><strong>Creation Time: </strong></span>
+        {{ isModelInfoLoading ? null : selectedModelInfo.creationTime }}
+      </p>
+      <p nz-typography>
+        <span><strong>Last Updated Time: </strong></span>
+        {{ isModelInfoLoading ? null : selectedModelInfo.lastUpdatedTime }}
+      </p>
+    </article>
+  </nz-spin>
+  <nz-divider [nzText]="text" nzOrientation="left">
+    <ng-template #text>
+      Model Versions
+      <i nz-icon nzType="form"></i>
+    </ng-template>
+  </nz-divider>
+  <nz-table
+    id="modelVersionsTable"
+    nzBordered
+    #basicTable
+    [nzData]="modelVersions"
+    [nzNoResult]="'No data'"
+    [nzLoading]="isModelVersionsLoading"
+  >
+    <thead>
+      <tr>
+        <th>Version</th>
+        <th>Stage</th>
+        <th>Tags</th>
+        <th>Description</th>
+        <th>Created</th>
+        <th>Updated</th>
+      </tr>
+    </thead>
+    <tbody>
+      <tr *ngFor="let data of basicTable.data; let i = index">
+        <td><a [routerLink]="data.version">{{ data.version }}</a></td>
+        <td>{{ data.currentStage }}</td>
+        <td>
+          <submarine-model-tag *ngFor="let tag of data.tags" [tag]="tag" [cssType]="'default'"></submarine-model-tag>
+        </td>
+        <td>{{ data.description }}</td>

Review comment:
       Is it better to move the tags and description to the last two columns?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@submarine.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org