From cf10d3f49c608c73e70ac4cb78f57788d1306514 Mon Sep 17 00:00:00 2001 From: Massimiliano Assante Date: Tue, 17 Sep 2013 10:30:58 +0000 Subject: [PATCH] restyled git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/admin/service-endpoint-editor@81599 82a268e6-3cf1-43bd-a215-b396298e98cf --- .../RuntimeResourceCreatorServiceImpl.java | 57 ++-------- src/main/webapp/RuntimeResourceCreator.css | 2 + src/main/webapp/RuntimeResourceCreator.html | 2 +- src/main/webapp/d4scienceOrg.css | 107 ++++++++++++++++++ src/main/webapp/images/bg-pattern.png | Bin 0 -> 945 bytes src/main/webapp/images/bg_custom.png | Bin 0 -> 2848 bytes src/main/webapp/images/loader.gif | Bin 0 -> 3924 bytes 7 files changed, 117 insertions(+), 51 deletions(-) create mode 100644 src/main/webapp/d4scienceOrg.css create mode 100644 src/main/webapp/images/bg-pattern.png create mode 100644 src/main/webapp/images/bg_custom.png create mode 100644 src/main/webapp/images/loader.gif diff --git a/src/main/java/org/gcube/portlets/admin/sepeditor/server/RuntimeResourceCreatorServiceImpl.java b/src/main/java/org/gcube/portlets/admin/sepeditor/server/RuntimeResourceCreatorServiceImpl.java index 5c42f74..1a5d317 100644 --- a/src/main/java/org/gcube/portlets/admin/sepeditor/server/RuntimeResourceCreatorServiceImpl.java +++ b/src/main/java/org/gcube/portlets/admin/sepeditor/server/RuntimeResourceCreatorServiceImpl.java @@ -43,6 +43,7 @@ import org.gcube.portlets.admin.sepeditor.shared.FilledRuntimeResource; import org.gcube.portlets.admin.sepeditor.shared.InitInfo; import org.gcube.portlets.admin.sepeditor.shared.Property; import org.gcube.portlets.admin.sepeditor.shared.RRAccessPoint; +import org.gcube.resourcemanagement.support.server.managers.scope.ScopeManager; import org.gcube.resources.discovery.client.api.DiscoveryClient; import org.gcube.resources.discovery.client.queries.api.SimpleQuery; import org.apache.log4j.Logger; @@ -292,13 +293,16 @@ public class RuntimeResourceCreatorServiceImpl extends RemoteServiceServlet impl return null; } } - + /** + * + * @return + */ public ArrayList getAvailableScopes() { ArrayList retval = new ArrayList(); String currentScope = getASLSession().getScopeName(); System.out.println("currentScope: " + currentScope); try { - Map scopes = readScopes(this.getScopeDataPath()); + Map scopes = ScopeManager.readScopes(this.getScopeDataPath()); for (ScopeBean scope : scopes.values()) { if (scope.toString().startsWith(currentScope)) retval.add(scope.toString()); @@ -313,35 +317,7 @@ public class RuntimeResourceCreatorServiceImpl extends RemoteServiceServlet impl return retval; } - public static Map readScopes(String confFile) throws Exception { - if (confFile == null) { - throw new NullPointerException("the scope file has not been defined"); - } - Map toReturn = new HashMap(); - String scopeXML = fileToString(confFile); - - Document scopeDocument = getDocumentGivenXML(scopeXML); - NodeList voElements = scopeDocument.getElementsByTagName("vo"); - - for (int i = 0; i < voElements.getLength(); i++) { - NodeList voDetails = voElements.item(i).getChildNodes(); - String voString = voDetails.item(5).getFirstChild().getNodeValue(); - // String voName = voDetails.item(1).getFirstChild().getNodeValue(); - ScopeBean vo = new ScopeBean(voString); - - toReturn.put(vo.toString(), vo); - try { - for (String vre : getVREFromVO(vo)) { - // This operation overrides the vo map - toReturn.put(vre.toString(), new ScopeBean(vo.toString()+"/"+vre)); - } - } catch (ISException e) { - _log.error("Exception raised while loading VREs for VO : " + vo, e); - } - } - return toReturn; - - } + private String getScopeDataPath() { String startDirectory = getServletFSPath(); @@ -388,25 +364,6 @@ public class RuntimeResourceCreatorServiceImpl extends RemoteServiceServlet impl return document; } - protected static List getVREFromVO(final ScopeBean vo) throws Exception { - _log.debug("Starting Retrieving VREs for VO : " + vo); - List toReturn = new ArrayList(); - - ScopeProvider.instance.set(vo.toString()); - SimpleQuery query = queryFor(GenericResource.class); - query.addCondition("$resource/Profile/SecondaryType/text() eq 'VRE'"); - - DiscoveryClient client = clientFor(GenericResource.class); - - List gRes = client.submit(query); - - for (GenericResource res : gRes) { - _log.debug("Found: " + res.profile().name()); - toReturn.add(res.profile().name()); - } - return toReturn; - } - } diff --git a/src/main/webapp/RuntimeResourceCreator.css b/src/main/webapp/RuntimeResourceCreator.css index b43a5d6..050faaa 100644 --- a/src/main/webapp/RuntimeResourceCreator.css +++ b/src/main/webapp/RuntimeResourceCreator.css @@ -1,3 +1,5 @@ +@import url(d4scienceOrg.css); + .wizardTextBox { background-color: white; border-color: #999; diff --git a/src/main/webapp/RuntimeResourceCreator.html b/src/main/webapp/RuntimeResourceCreator.html index 9259e32..75feb15 100644 --- a/src/main/webapp/RuntimeResourceCreator.html +++ b/src/main/webapp/RuntimeResourceCreator.html @@ -11,8 +11,8 @@ - + diff --git a/src/main/webapp/d4scienceOrg.css b/src/main/webapp/d4scienceOrg.css new file mode 100644 index 0000000..96db352 --- /dev/null +++ b/src/main/webapp/d4scienceOrg.css @@ -0,0 +1,107 @@ +#wrapper { + font: 11px/1.5 "Lucida Grande", "Lucida Sans Unicode", Arial, Verdana, + sans-serif; + margin: 0 auto; + width: 92% !important; +} + +.x-menubar { + background: #FFF url(images/bg-pattern.png) repeat; +} + +.x-panel { + border-color: transparent; +} + +.x-panel-body,.x-panel-body-noheader { + border-color: transparent; +} + +.x-border-layout-ct { + background-color: transparent; + border-color: transparent; +} + +.x-toolbar { + border-color: #226599; + background: #FFF url(images/bg-pattern.png) repeat; +} + +.x-panel-mc { + padding-top: 5px; + background: #FFF url(images/bg-pattern.png) repeat; + border-color: #226599; + -webkit-border-radius: 5px; + -moz-border-radius: 5px; + border-radius: 5px; +} + +.x-panel-bc { + +} + +.ext-el-mask-msg { + -webkit-border-radius: 5px; + -moz-border-radius: 5px; + border-radius: 5px; + border-width: 2px; + background-color: #FFF; +} + +.ext-el-mask-msg div { + border-color: transparent; + background-color: transparent; +} + +.loading-indicator { + background-position: 5px 50%; + background-image: url("images/loader.gif"); + } + +.x-panel-header { + background-color: #d0def0; + /* Mozilla Firefox */ + background-image: -moz-linear-gradient(top, #DFEAF8 0%, #d0def0 100%); + /* Webkit (Safari/Chrome 10) */ + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #DFEAF8), + color-stop(1, #d0def0)); + /* Webkit (Chrome 11+) */ + background-image: -webkit-linear-gradient(top, #DFEAF8 0%, #d0def0 100%); + /* W3C Markup, IE10 Release Preview */ + background-image: linear-gradient(to bottom, #DFEAF8 0%, #d0def0 100%); + /* IE10 Consumer Preview */ + background-image: -ms-linear-gradient(top, #DFEAF8 0%, #052045 100%); + -webkit-border-top-left-radius: 5px; + -webkit-border-top-right-radius: 5px; + -moz-border-radius-topleft: 5px; + -moz-border-radius-topright: 5px; + border-top-left-radius: 5px; + border-top-right-radius: 5px; +} + +.x-toolbar .xtb-sep { + background-image: none !important; + background-color: transparent; +} + +.x-accordion-hd { + background-position: 0 0px; +} + +.x-status-text { + color: #226599; + font-weight: bold !important; +} + +.x-status-text-panel { + border-color: transparent; +} + +.x-component { + color: #226599; +} + +.x-btn button { + color: #226599; + font-weight: bold !important; +} \ No newline at end of file diff --git a/src/main/webapp/images/bg-pattern.png b/src/main/webapp/images/bg-pattern.png new file mode 100644 index 0000000000000000000000000000000000000000..d9ca94b4c39905ae9d7bace9c2ee0dfec54ac0ed GIT binary patch literal 945 zcmaJ=&yLbS9G+z3MmO2S=t(b5W-ppZ+bOiWZK#_r1($>p0wl|k(hktD?bLR#g_H5N zFX1EX!IKFGz4`kx zm<88iqGtwL>*{=;n?(fI5H>N;T~Ix{1uHZrP!Wm+SHc*os(?$1s^ZsBmar^J{8kIN zq${c}pTfTRpG@x@OD8Z#E@qL`+skQN0Rk3_6#TCO3>1&$~rvyeGiAxuuT z3KmJ+*pHY`LzpW%13F~};*s8^5JWrKFxixe7fj5YNW_Aar?dsy_Wz+lutO)TP446U zr*P7pMMP|qgid3ZH*R>6yNdKmOdLkzE~VGoDz?Uy(PT^`Sm~(n<&__LG)-Qu@wTnk z!-P4ZOX`+^xPsvOo?gP$qNLR{<;=nuS7r0UlqyQGQj=5(n?-rcwWvD{NXWKa@1AS! z<>sRhMBKAQV*fqyYB3GqI%VD8AIs@py$#pfAIsTZuE>KC^Tz(w=&gxQPrluaEkEoA zpM-qcV?NfOrA34P5{Ioux4K%bmdoX>{p%68Jgr-1H~Ts0dwqaPAMD5Q8vvicgPYOf P3;zu2)uwfO(f{}dAORta literal 0 HcmV?d00001 diff --git a/src/main/webapp/images/bg_custom.png b/src/main/webapp/images/bg_custom.png new file mode 100644 index 0000000000000000000000000000000000000000..ec909f315d227a520bd12e102f6dd3c095d81373 GIT binary patch literal 2848 zcmV+*3*YpKP)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;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