File tree Expand file tree Collapse file tree 3 files changed +15
-0
lines changed
contrib/storage-http/src/main/resources/storage_logos
java/org/apache/drill/exec/server/rest Expand file tree Collapse file tree 3 files changed +15
-0
lines changed File renamed without changes.
Original file line number Diff line number Diff line change @@ -490,6 +490,20 @@ public String getPassword() {
490490 }
491491 }
492492
493+ /**
494+ * Returns the path for the image used in the list view.
495+ * @return
496+ */
497+ public String getImagePath () {
498+ if (getCleanType ().contentEquals ("FileSystem" )) {
499+ return "/static/img/storage_logos/FileSystem.png" ;
500+ }
501+
502+ // If the plugin is in contrib, get the full path
503+ String path = plugin .getConfig ().getClass ().getResource ("/storage_logos/" + getCleanType () + ".png" ).getPath ();
504+ return path ;
505+ }
506+
493507 public String getCleanType () {
494508 String pluginName = type .replace ("Config" , "" );
495509 pluginName = pluginName .replace ("Plugin" , "" );
Original file line number Diff line number Diff line change 6161 <tr >
6262 <td style =" border :none ;" >
6363 <img src =" /static/img/storage_logos/${pluginModel.getCleanType()}.png" alt =" ${pluginModel.getCleanType()}" height =40 width =40 />
64+ ${pluginModel.getImagePath()}
6465 </td >
6566 <td style =" border :none ; max-width : 200px ; overflow : hidden ; text-overflow : ellipsis ;" >
6667 ${pluginModel.getPlugin().getName()}
You can’t perform that action at this time.
0 commit comments