diff --git a/src/main/java/org/nrg/xapi/rest/settings/SiteConfigApi.java b/src/main/java/org/nrg/xapi/rest/settings/SiteConfigApi.java index f04aac762f7ff86a8be4a069b0ce402aafe74ca6..bd4957f10d1ea946e44a18c507cdb647992d46f8 100644 --- a/src/main/java/org/nrg/xapi/rest/settings/SiteConfigApi.java +++ b/src/main/java/org/nrg/xapi/rest/settings/SiteConfigApi.java @@ -84,7 +84,7 @@ public class SiteConfigApi extends AbstractXnatRestApi { final Map<String, Object> values = new HashMap<>(); for (final String preference : preferences) { - final Object value = _preferences.getValueByReference(preference); + final Object value = _preferences.getProperty(preference); if (value != null) { values.put(preference, value); } @@ -100,7 +100,7 @@ public class SiteConfigApi extends AbstractXnatRestApi { if (status != null) { return new ResponseEntity<>(status); } - final Object value = _preferences.getValueByReference(property); + final Object value = _preferences.getProperty(property); if (_log.isDebugEnabled()) { _log.debug("User " + getSessionUser().getUsername() + " requested the value for the site configuration property " + property + ", got value: " + value); } diff --git a/src/main/java/org/nrg/xnat/configuration/ApplicationConfig.java b/src/main/java/org/nrg/xnat/configuration/ApplicationConfig.java index bf0ce3f6d7c5bd556b47ff684bf57927832c42ca..b51580982bf1df0f55c8eac7bea1ff79df75dd79 100644 --- a/src/main/java/org/nrg/xnat/configuration/ApplicationConfig.java +++ b/src/main/java/org/nrg/xnat/configuration/ApplicationConfig.java @@ -68,15 +68,12 @@ public class ApplicationConfig { @Bean public RegExpValidator regexValidator() throws SiteConfigurationException { - final String complexityExpression = _preferences.getPasswordComplexity(); - final String complexityMessage = _preferences.getPasswordComplexityMessage(); - return new RegExpValidator(complexityExpression, complexityMessage); + return new RegExpValidator(); } @Bean public HistoricPasswordValidator historicPasswordValidator() throws SiteConfigurationException { - final int durationInDays = _preferences.getPasswordHistoryDuration(); - return new HistoricPasswordValidator(durationInDays); + return new HistoricPasswordValidator(); } @Bean diff --git a/src/main/java/org/nrg/xnat/configuration/SchedulerConfig.java b/src/main/java/org/nrg/xnat/configuration/SchedulerConfig.java index 36d36973c68278dc3d2f6cf52aa4a8dc0613d6cc..fd4206024839c323385e85582b1bc866b7161e7d 100644 --- a/src/main/java/org/nrg/xnat/configuration/SchedulerConfig.java +++ b/src/main/java/org/nrg/xnat/configuration/SchedulerConfig.java @@ -4,6 +4,7 @@ import org.nrg.config.exceptions.SiteConfigurationException; import org.nrg.framework.exceptions.NrgServiceError; import org.nrg.framework.exceptions.NrgServiceRuntimeException; import org.nrg.mail.services.EmailRequestLogService; +import org.nrg.xdat.XDAT; import org.nrg.xdat.preferences.InitializerSiteConfiguration; import org.nrg.xdat.preferences.SiteConfigPreferences; import org.nrg.xnat.helpers.prearchive.SessionXMLRebuilder; @@ -18,6 +19,8 @@ import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Lazy; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jms.core.JmsTemplate; +import org.springframework.scheduling.Trigger; +import org.springframework.scheduling.TriggerContext; import org.springframework.scheduling.annotation.EnableScheduling; import org.springframework.scheduling.annotation.SchedulingConfigurer; import org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler; @@ -28,6 +31,9 @@ import org.springframework.scheduling.support.PeriodicTrigger; import javax.inject.Inject; import java.sql.SQLException; +import java.util.Calendar; +import java.util.Date; +import java.util.GregorianCalendar; import java.util.List; @Configuration @@ -56,7 +62,24 @@ public class SchedulerConfig implements SchedulingConfigurer { @Bean public TriggerTask clearExpiredAliasTokens() throws SiteConfigurationException { - return new TriggerTask(new ClearExpiredAliasTokens(_template, _preferences.getAliasTokenTimeout()), new PeriodicTrigger(3600000)); + return new TriggerTask(new ClearExpiredAliasTokens(_template), new Trigger() { + @Override public Date nextExecutionTime(TriggerContext triggerContext) { + Calendar nextExecutionTime = new GregorianCalendar(); + Date lastActualExecutionTime = triggerContext.lastActualExecutionTime(); + nextExecutionTime.setTime(lastActualExecutionTime != null ? lastActualExecutionTime : new Date()); + long expirationInterval = XDAT.getSiteConfigPreferences().getAliasTokenTimeout(); + if(expirationInterval<120){//Check every minute if interval is 2 hours or less + nextExecutionTime.add(Calendar.MINUTE, 1); + } + else if(expirationInterval<2880){//Check every hour if interval is 2 days or less + nextExecutionTime.add(Calendar.HOUR, 1); + } + else{//Check every day + nextExecutionTime.add(Calendar.DAY_OF_MONTH, 1); + } + return nextExecutionTime.getTime(); + } + }); } @Bean diff --git a/src/main/java/org/nrg/xnat/event/listeners/AutomationEventScriptHandler.java b/src/main/java/org/nrg/xnat/event/listeners/AutomationEventScriptHandler.java index af07d88f65fce9f6dbd60229ef4ef9d82b0fba05..6f0d32a1cca965653e26b03c6a342bffa06c2a30 100644 --- a/src/main/java/org/nrg/xnat/event/listeners/AutomationEventScriptHandler.java +++ b/src/main/java/org/nrg/xnat/event/listeners/AutomationEventScriptHandler.java @@ -177,7 +177,8 @@ public class AutomationEventScriptHandler implements Consumer<Event<AutomationEv * * @param event the event */ - private void updateAutomationTables(Event<AutomationEventImplementerI> event) { + // Made this method synchronized to avoid some constraint violation exceptions that were occasionally being thrown. + private synchronized void updateAutomationTables(Event<AutomationEventImplementerI> event) { final AutomationEventImplementerI eventData = event.getData(); if (eventData.getEventId() == null || eventData.getClass() == null) { return; diff --git a/src/main/java/org/nrg/xnat/helpers/prearchive/PrearcDatabase.java b/src/main/java/org/nrg/xnat/helpers/prearchive/PrearcDatabase.java index 1b359a7e4d9685ac79fe96a72975e15a96c33962..6523ee706b504559ab0d8689086162530066dce2 100644 --- a/src/main/java/org/nrg/xnat/helpers/prearchive/PrearcDatabase.java +++ b/src/main/java/org/nrg/xnat/helpers/prearchive/PrearcDatabase.java @@ -17,7 +17,6 @@ import org.apache.commons.lang3.StringUtils; import org.nrg.action.ClientException; import org.nrg.automation.entities.Script; import org.nrg.automation.services.ScriptService; -import org.nrg.config.exceptions.ConfigServiceException; import org.nrg.dicomtools.filters.DicomFilterService; import org.nrg.dicomtools.filters.SeriesImportFilter; import org.nrg.framework.constants.PrearchiveCode; @@ -179,12 +178,7 @@ public final class PrearcDatabase { if (preferences != null) { return preferences.getPrearchivePath(); } - try { - final Properties properties = XDAT.getSiteConfiguration(); - return properties.getProperty("prearchivePath"); - } catch (ConfigServiceException e) { - return null; - } + return XDAT.getSiteConfigPreferences().getPrearchivePath(); } private static boolean tableExists() throws Exception { diff --git a/src/main/java/org/nrg/xnat/initialization/XnatWebAppInitializer.java b/src/main/java/org/nrg/xnat/initialization/XnatWebAppInitializer.java index 78901edce38b3d386a852d55685259b049e30b93..66eac2b498d7715368d0184403ee8515fc12fe62 100644 --- a/src/main/java/org/nrg/xnat/initialization/XnatWebAppInitializer.java +++ b/src/main/java/org/nrg/xnat/initialization/XnatWebAppInitializer.java @@ -19,7 +19,6 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.core.io.Resource; import org.springframework.core.io.support.PropertiesLoaderUtils; -import org.springframework.stereotype.Service; import org.springframework.web.filter.DelegatingFilterProxy; import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer; diff --git a/src/main/java/org/nrg/xnat/restlet/resources/UserListResource.java b/src/main/java/org/nrg/xnat/restlet/resources/UserListResource.java index 2eda908e4c661a7100895f5198532bc2f104fe4b..97c99d4689b5e0768ce2dc308c2e4d0d51a0372b 100644 --- a/src/main/java/org/nrg/xnat/restlet/resources/UserListResource.java +++ b/src/main/java/org/nrg/xnat/restlet/resources/UserListResource.java @@ -81,6 +81,6 @@ public class UserListResource extends SecureResource { * @return <b>true</b> if only site administrators can access the list of users, <b>false</b> otherwise. */ private boolean restrictUserListAccessToAdmins() { - return XDAT.getBoolSiteConfigurationProperty("restrictUserListAccessToAdmins", true); + return XDAT.getSiteConfigPreferences().getRestrictUserListAccessToAdmins(); } } diff --git a/src/main/java/org/nrg/xnat/security/XnatLdapUserDetailsMapper.java b/src/main/java/org/nrg/xnat/security/XnatLdapUserDetailsMapper.java index c0768d8673f5845ea0c409b91bd50f3480d29354..313b68e1b474210d2f5b769249ac95fa15627a6a 100644 --- a/src/main/java/org/nrg/xnat/security/XnatLdapUserDetailsMapper.java +++ b/src/main/java/org/nrg/xnat/security/XnatLdapUserDetailsMapper.java @@ -77,7 +77,7 @@ public class XnatLdapUserDetailsMapper extends LdapUserDetailsMapper { try { final UserI xdatUser = Users.getUser(userDetails.getUsername()); - if ((!XDAT.verificationOn() || xdatUser.isVerified()) && userDetails.getAuthorization().isEnabled()) { + if ((!XDAT.getSiteConfigPreferences().getEmailVerification() || xdatUser.isVerified()) && userDetails.getAuthorization().isEnabled()) { return userDetails; } else { throw new NewLdapAccountNotAutoEnabledException( diff --git a/src/main/java/org/nrg/xnat/security/XnatSessionEventPublisher.java b/src/main/java/org/nrg/xnat/security/XnatSessionEventPublisher.java index 19ccdfc73c6697c8febcfabf450391473484302e..437c17d7a9d91ea4d370f246514e258231d3acbb 100644 --- a/src/main/java/org/nrg/xnat/security/XnatSessionEventPublisher.java +++ b/src/main/java/org/nrg/xnat/security/XnatSessionEventPublisher.java @@ -10,6 +10,7 @@ */ package org.nrg.xnat.security; +import org.nrg.xdat.XDAT; import org.nrg.xft.security.UserI; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -52,7 +53,7 @@ public class XnatSessionEventPublisher implements HttpSessionListener, ServletCo } session.setAttribute("XNAT_CSRF", UUID.randomUUID().toString()); - + session.setMaxInactiveInterval(XDAT.getSiteConfigPreferences().getSessionTimeout()*60);//Preference is in minutes and setMaxInactiveInterval wants seconds. getContext(session.getServletContext()).publishEvent(e); } diff --git a/src/main/java/org/nrg/xnat/security/alias/ClearExpiredAliasTokens.java b/src/main/java/org/nrg/xnat/security/alias/ClearExpiredAliasTokens.java index cb1ed6fcf20a19d5b239877e4810c370eb14fbe1..5f8d325286ad6b89d3ee3c24277e287557d4f0e4 100644 --- a/src/main/java/org/nrg/xnat/security/alias/ClearExpiredAliasTokens.java +++ b/src/main/java/org/nrg/xnat/security/alias/ClearExpiredAliasTokens.java @@ -10,6 +10,7 @@ */ package org.nrg.xnat.security.alias; +import org.nrg.xdat.XDAT; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.jdbc.core.JdbcTemplate; @@ -18,13 +19,12 @@ import java.util.Arrays; import java.util.List; public class ClearExpiredAliasTokens implements Runnable { - public ClearExpiredAliasTokens(final JdbcTemplate template, final String timeout) { + public ClearExpiredAliasTokens(final JdbcTemplate template) { if (_log.isDebugEnabled()) { - _log.debug("Initializing the alias token sweeper job with an interval of: " + timeout); + _log.debug("Initializing the alias token sweeper job"); } _template = template; - _timeout = timeout; } /** @@ -35,7 +35,7 @@ public class ClearExpiredAliasTokens implements Runnable { _log.debug("Executing alias token sweep function"); } for (final String format : ALIAS_TOKEN_QUERIES) { - final String query = String.format(format, _timeout); + final String query = String.format(format, XDAT.getSiteConfigPreferences().getAliasTokenTimeout()); if (_log.isDebugEnabled()) { _log.debug("Executing alias token sweep query: " + query); } @@ -44,10 +44,9 @@ public class ClearExpiredAliasTokens implements Runnable { } private static final Logger _log = LoggerFactory.getLogger(ClearExpiredAliasTokens.class); - private static final String QUERY_DELETE_TOKEN_IP_ADDRESSES = "DELETE FROM xhbm_alias_token_validipaddresses WHERE alias_token in (SELECT id FROM xhbm_alias_token WHERE created < NOW() - INTERVAL '%s')"; - private static final String QUERY_DELETE_ALIAS_TOKENS = "DELETE FROM xhbm_alias_token WHERE created < NOW() - INTERVAL '%s'"; + private static final String QUERY_DELETE_TOKEN_IP_ADDRESSES = "DELETE FROM xhbm_alias_token_validipaddresses WHERE alias_token in (SELECT id FROM xhbm_alias_token WHERE created < NOW() - INTERVAL '%s minutes')"; + private static final String QUERY_DELETE_ALIAS_TOKENS = "DELETE FROM xhbm_alias_token WHERE created < NOW() - INTERVAL '%s minutes'"; private static final List<String> ALIAS_TOKEN_QUERIES = Arrays.asList(QUERY_DELETE_TOKEN_IP_ADDRESSES, QUERY_DELETE_ALIAS_TOKENS); private final JdbcTemplate _template; - private final String _timeout; } diff --git a/src/main/java/org/nrg/xnat/security/provider/XnatDatabaseAuthenticationProvider.java b/src/main/java/org/nrg/xnat/security/provider/XnatDatabaseAuthenticationProvider.java index 085bd95ec7b211d353d970e14718a4bc54c5f811..8dac7b2415dfef434d0a4e7f8abfd0775222f286 100644 --- a/src/main/java/org/nrg/xnat/security/provider/XnatDatabaseAuthenticationProvider.java +++ b/src/main/java/org/nrg/xnat/security/provider/XnatDatabaseAuthenticationProvider.java @@ -80,7 +80,7 @@ public class XnatDatabaseAuthenticationProvider extends DaoAuthenticationProvide throw new AuthenticationServiceException("User details class is not of a type I know how to handle: " + userDetails.getClass()); } final UserI xdatUserDetails = (UserI) userDetails; - if ((XDAT.verificationOn() && !xdatUserDetails.isVerified() && xdatUserDetails.isEnabled()) || !xdatUserDetails.isAccountNonLocked()) { + if ((XDAT.getSiteConfigPreferences().getEmailVerification() && !xdatUserDetails.isVerified() && xdatUserDetails.isEnabled()) || !xdatUserDetails.isAccountNonLocked()) { throw new CredentialsExpiredException("Attempted login to unverified or locked account: " + xdatUserDetails.getUsername()); } super.additionalAuthenticationChecks(userDetails, authentication); diff --git a/src/main/java/org/nrg/xnat/servlet/ArchiveServlet.java b/src/main/java/org/nrg/xnat/servlet/ArchiveServlet.java new file mode 100755 index 0000000000000000000000000000000000000000..d5ebc477123d0412883739e9ad889728978fe631 --- /dev/null +++ b/src/main/java/org/nrg/xnat/servlet/ArchiveServlet.java @@ -0,0 +1,481 @@ +/* + * org.nrg.xnat.servlet.ArchiveServlet + * XNAT http://www.xnat.org + * Copyright (c) 2014, Washington University School of Medicine + * All Rights Reserved + * + * Released under the Simplified BSD. + * + * Last modified 7/10/13 9:04 PM + */ +package org.nrg.xnat.servlet; + +import org.apache.commons.lang.RandomStringUtils; +import org.apache.commons.lang.StringUtils; +import org.nrg.xdat.XDAT; +import org.nrg.xdat.base.BaseElement; +import org.nrg.xdat.bean.CatCatalogBean; +import org.nrg.xdat.bean.CatEntryBean; +import org.nrg.xdat.bean.CatEntryMetafieldBean; +import org.nrg.xdat.om.XnatExperimentdata; +import org.nrg.xdat.om.XnatImagesessiondata; +import org.nrg.xdat.om.XnatProjectdata; +import org.nrg.xdat.om.XnatSubjectdata; +import org.nrg.xdat.security.helpers.Users; +import org.nrg.xdat.turbine.utils.TurbineUtils; +import org.nrg.xft.ItemI; +import org.nrg.xft.XFTItem; +import org.nrg.xft.db.DBAction; +import org.nrg.xft.db.PoolDBUtils; +import org.nrg.xft.exception.ElementNotFoundException; +import org.nrg.xft.exception.FieldNotFoundException; +import org.nrg.xft.exception.XFTInitException; +import org.nrg.xft.schema.Wrappers.GenericWrapper.GenericWrapperElement; +import org.nrg.xft.schema.Wrappers.GenericWrapper.GenericWrapperField; +import org.nrg.xft.schema.design.SchemaElementI; +import org.nrg.xft.search.ItemSearch; +import org.nrg.xft.security.UserI; +import org.nrg.xft.utils.FileUtils; +import org.nrg.xft.utils.ResourceFile; +import org.nrg.xft.utils.XftStringUtils; +import org.nrg.xft.utils.zip.ZipI; +import org.nrg.xft.utils.zip.ZipUtils; +import org.nrg.xnat.turbine.utils.ArcSpecManager; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import javax.servlet.ServletConfig; +import javax.servlet.ServletException; +import javax.servlet.ServletOutputStream; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.File; +import java.io.IOException; +import java.io.OutputStream; +import java.io.OutputStreamWriter; +import java.util.ArrayList; +import java.util.zip.ZipOutputStream; + +@SuppressWarnings("serial") +public class ArchiveServlet extends HttpServlet { + private static final Logger logger = LoggerFactory.getLogger(ArchiveServlet.class); + + /* (non-Javadoc) + * @see javax.servlet.http.HttpServlet#doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) + */ + @Override + protected void doGet(HttpServletRequest arg0, HttpServletResponse arg1) throws ServletException, IOException { + doGetOrPost(arg0, arg1); + } + + /* (non-Javadoc) + * @see javax.servlet.http.HttpServlet#doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) + */ + @Override + protected void doPost(HttpServletRequest arg0, HttpServletResponse arg1) throws ServletException, IOException { + doGetOrPost(arg0, arg1); + } + + @SuppressWarnings("unchecked") + protected void getCatalog(UserI user, String path, HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { + String rootElementName = path.substring(0, path.indexOf("/")); + path = path.substring(path.indexOf("/") + 1); + + res.setContentType("text/xml"); + + if (rootElementName.equals("stored")) { + File f = Users.getUserCacheFile(user, "catalogs/" + path); + if (f.exists()) { + writeFile(f, res); + return; + } else { + return; + } + } + + int indexOfSlash = path.indexOf("/"); + final String value; + if (indexOfSlash == -1) { + value = path; + path = ""; + } else { + value = path.substring(0, path.indexOf("/")); + path = path.substring(path.indexOf("/") + 1); + } + + CatCatalogBean cat = new CatCatalogBean(); + + String server = TurbineUtils.GetFullServerPath(req); + if (!server.endsWith("/")) { + server += "/"; + } + + ArrayList<String> ids = XftStringUtils.CommaDelimitedStringToArrayList(value, true); + + try { + final GenericWrapperElement root = GenericWrapperElement.GetElement(rootElementName); + final ItemSearch is = ItemSearch.GetItemSearch(root.getFullXMLName(), user); + int index = 0; + for (GenericWrapperField f : root.getAllPrimaryKeys()) { + is.addCriteria(f.getXMLPathString(root.getFullXMLName()), ids.get(index++)); + } + final ItemI rootO = is.exec(false).getFirst(); + final XFTItem i = (XFTItem) rootO; + ItemI rootOM = BaseElement.GetGeneratedItem(i); + + + String xmlPath = server + "archive/" + rootElementName + "/" + value; + String uri = server + "archive/cache/"; + + String rootPath = getRootPath(rootOM); + File rootDir = new File(rootPath); + + final ArrayList<XFTItem> al; + if (!path.equals("")) { + al = (ArrayList<XFTItem>) i.getProperty(path, true); + xmlPath += "/" + path.substring(0, path.indexOf("[")); + } else { + al = new ArrayList<>(); + al.add(i); + } + + for (XFTItem child : al) { + final String subString; + if (!path.equals("")) { + subString = xmlPath + "/" + child.getPKValueString() + "/"; + } else { + subString = xmlPath; + } + + BaseElement om = (BaseElement) BaseElement.GetGeneratedItem(child); + ArrayList<ResourceFile> rfs = om.getFileResources(rootPath); + for (ResourceFile rf : rfs) { + CatEntryBean entry = new CatEntryBean(); + + String relative = rf.getAbsolutePath(); + + Object id = cacheFileLink(subString + rf.getXdatPath(), relative, i.getDBName(), user.getLogin()); + + entry.setUri(uri + id); + + relative = relative.replace('\\', '/'); + String cleaned = rootPath.replace('\\', '/'); + + if (relative.startsWith(cleaned)) { + relative = relative.substring(cleaned.length()); + } else { + if (relative.contains("/" + rootDir.getName() + "/")) { + relative = relative.substring(relative.indexOf("/" + rootDir.getName() + "/") + 1); + } + } + + entry.setCachepath(relative); + + CatEntryMetafieldBean meta = new CatEntryMetafieldBean(); + meta.setMetafield(relative); + meta.setName("RELATIVE_PATH"); + entry.addMetafields_metafield(meta); + + meta = new CatEntryMetafieldBean(); + meta.setMetafield(rf.getSize().toString()); + meta.setName("SIZE"); + entry.addMetafields_metafield(meta); + + + cat.addEntries_entry(entry); + } + } + + ServletOutputStream out = res.getOutputStream(); + + OutputStreamWriter sw = new OutputStreamWriter(out); + cat.toXML(sw, false); + sw.flush(); + sw.close(); + } catch (XFTInitException e) { + logger.error("An error occurred initializing XFT", e); + } catch (ElementNotFoundException e) { + logger.error("Did not find the requested element on the item", e); + } catch (Exception e) { + logger.error("An unknown exception occurred", e); + } + } + + public static boolean ARCHIVE_PATH_CHECKED = false; + + public static Boolean CreatedArchivePathCache(String dbName, String login) throws Exception { + if (!ARCHIVE_PATH_CHECKED) { + String query = "SELECT relname FROM pg_catalog.pg_class WHERE relname=LOWER('xs_archive_path_cache');"; + String exists = (String) PoolDBUtils.ReturnStatisticQuery(query, "relname", dbName, login); + + if (exists != null) { + ARCHIVE_PATH_CHECKED = true; + } else { + query = "CREATE TABLE xs_archive_path_cache" + + "\n(" + + "\n id serial," + + "\n create_date timestamp DEFAULT now()," + + "\n username VARCHAR(255)," + + "\n url text," + + "\n _token VARCHAR(255)," + + "\n absolute_path text" + + "\n) " + + "\nWITH OIDS;"; + + PoolDBUtils.ExecuteNonSelectQuery(query, dbName, login); + + ARCHIVE_PATH_CHECKED = true; + } + } + return true; + } + + public static Object cacheFileLink(String url, String absolutePath, String dbName, String login) throws Exception { + CreatedArchivePathCache(dbName, login); + Object o = RandomStringUtils.randomAlphanumeric(64); + Object exists = PoolDBUtils.ReturnStatisticQuery("SELECT id FROM xs_archive_path_cache WHERE _token='" + o + "';", "id", dbName, login); + while (exists != null) { + o = RandomStringUtils.randomAlphanumeric(64); + exists = PoolDBUtils.ReturnStatisticQuery("SELECT id FROM xs_archive_path_cache WHERE _token='" + o + "';", "id", dbName, login); + } + String query = "INSERT INTO xs_archive_path_cache (username,url,_token,absolute_path) VALUES ('" + login + "'," + DBAction.ValueParser(url, "string", true) + ",'" + o + "'," + DBAction.ValueParser(absolutePath, "string", true) + ");"; + PoolDBUtils.ExecuteNonSelectQuery(query, dbName, login); + return o; + } + + public Object retrieveCacheFileLink(String o, String dbName, String login) throws Exception { + o = StringUtils.remove(o, '\''); + return PoolDBUtils.ReturnStatisticQuery("SELECT absolute_path FROM xs_archive_path_cache WHERE _token='" + o + "';", "absolute_path", dbName, login); + } + + protected String getRootPath(ItemI i) { + if (i instanceof XnatProjectdata) { + return ((XnatProjectdata) i).getRootArchivePath(); + } else if (i instanceof XnatSubjectdata) { + return ((XnatSubjectdata) i).getPrimaryProject(false).getRootArchivePath(); + } else if (i instanceof XnatExperimentdata) { + return ((XnatExperimentdata) i).getPrimaryProject(false).getRootArchivePath(); + } + return null; + } + + protected void writeFile(File _return, HttpServletResponse res) throws IOException { + writeFile(_return, res, _return.getName()); + } + + protected void writeFile(File _return, HttpServletResponse res, String name) throws IOException { + TurbineUtils.setContentDisposition(res, name, false); + + OutputStream os = res.getOutputStream(); + java.io.FileInputStream in = new java.io.FileInputStream(_return); + byte[] buf = new byte[FileUtils.LARGE_DOWNLOAD]; + int len; + while ((len = in.read(buf)) > 0) { + os.write(buf, 0, len); + os.flush(); + } + os.flush(); + in.close(); + } + + protected void getDataFile(UserI user, String path, HttpServletResponse response) throws ServletException, IOException { + String rootElementName = path.substring(0, path.indexOf("/")); + path = path.substring(path.indexOf("/") + 1); + String value = path.substring(0, path.indexOf("/")); + path = path.substring(path.indexOf("/") + 1); + + final ArrayList<String> ids = XftStringUtils.CommaDelimitedStringToArrayList(value, true); + + XFTItem session = null; + XFTItem project = null; + try { + final GenericWrapperElement root = GenericWrapperElement.GetElement(rootElementName); + SchemaElementI localE = root; + ItemSearch is = ItemSearch.GetItemSearch(root.getFullXMLName(), user); + int index = 0; + for (GenericWrapperField f : root.getAllPrimaryKeys()) { + is.addCriteria(f.getXMLPathString(root.getFullXMLName()), ids.get(index++)); + } + + final ItemI rootO = is.exec(false).getFirst(); + XFTItem i = (XFTItem) rootO; + + if (i.instanceOf("xnat:projectData")) { + project = i; + } else if (i.instanceOf("xnat:imageSessionData")) { + session = i; + } + + String nextPath = null; + GenericWrapperField lastField = null; + while (path.contains("/")) { + final String next = path.substring(0, path.indexOf("/")); + + try { + if (lastField == null) { + lastField = localE.getGenericXFTElement().getDirectField(next); + } else { + lastField = lastField.getDirectField(next); + } + + if (nextPath == null) { + nextPath = next; + } else { + nextPath += "/" + next; + } + + path = path.substring(path.indexOf("/") + 1); + + if (lastField.isReference()) { + localE = lastField.getReferenceElement(); + value = path.substring(0, path.indexOf("/")); + path = path.substring(path.indexOf("/") + 1); + + ids.clear(); + ids.addAll(XftStringUtils.CommaDelimitedStringToArrayList(value, true)); + + is = ItemSearch.GetItemSearch(localE.getFullXMLName(), user); + index = 0; + for (GenericWrapperField f : localE.getGenericXFTElement().getAllPrimaryKeys()) { + is.addCriteria(f.getXMLPathString(localE.getFullXMLName()), ids.get(index++)); + } + i = (XFTItem) is.exec(false).getFirst(); + + lastField = null; + nextPath = null; + + if (i.instanceOf("xnat:projectData")) { + project = i; + } else if (i.instanceOf("xnat:imageSessionData")) { + session = i; + } + } + } catch (FieldNotFoundException e) { + break; + } + } + + System.out.println("ENDING:" + path); + + + //identify project + if (project == null) { + if (session != null) { + XnatImagesessiondata img = (XnatImagesessiondata) BaseElement.GetGeneratedItem(session); + project = img.getPrimaryProject(false).getItem(); + } else { + ArrayList<XFTItem> parents = i.getParents("xnat:projectData"); + project = parents.get(0); + } + } + + XnatProjectdata p = (XnatProjectdata) BaseElement.GetGeneratedItem(project); + String rootPath = p.getRootArchivePath(); + + BaseElement om = (BaseElement) BaseElement.GetGeneratedItem(i); + + ArrayList<ResourceFile> resources = om.getFileResources(rootPath); + + if (path.equals("*")) { + response.setContentType("application/zip"); + TurbineUtils.setContentDisposition(response, value + ".zip", false); + OutputStream outStream = response.getOutputStream(); + final ZipI zip = new ZipUtils(); + zip.setOutputStream(outStream, ZipOutputStream.DEFLATED); + + for (ResourceFile rf : resources) { + File f = rf.getF(); + String relative = f.getAbsolutePath(); + if (session != null) { + if (relative.contains(File.separator + session.getProperty("ID"))) { + relative = relative.substring(relative.indexOf(File.separator + session.getProperty("ID")) + 1); + } else if (project != null) { + if (relative.contains(File.separator + project.getProperty("ID"))) { + relative = relative.substring(relative.indexOf(File.separator + project.getProperty("ID")) + 1); + } + } + } else if (project != null) { + if (relative.contains(File.separator + project.getProperty("ID"))) { + relative = relative.substring(relative.indexOf(File.separator + project.getProperty("ID")) + 1); + } + } + zip.write(relative, f); + } + + // Complete the ZIP file + zip.close(); + } else { + File _return = null; + for (ResourceFile rf : resources) { + if (rf.getF().getName().equals(path)) { + _return = rf.getF(); + break; + } + } + + if (_return == null) { + int count = Integer.parseInt(path); + _return = resources.get(count).getF(); + } + + if (_return != null) { + writeFile(_return, response); + } + } + } catch (XFTInitException e) { + logger.error("An error occurred initializing XFT", e); + } catch (ElementNotFoundException e) { + logger.error("Did not find the requested element on the item", e); + } catch (Exception e) { + logger.error("An unknown exception occurred", e); + } + } + + protected void doGetOrPost(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { + System.out.println("PathInfo: " + req.getPathInfo()); + String path = req.getPathInfo(); + if (path.startsWith("/")) { + path = path.substring(1); + } + + UserI user = XDAT.getUserDetails(); + if (user == null) { + user = (UserI) req.getSession().getAttribute("user"); + } + + if (path.startsWith("catalogs/")) { + if (user != null) + getCatalog(user, path.substring(9), req, res); + } else if (path.startsWith("cache/")) { + String o = path.substring(6); + try { + String dbName = GenericWrapperElement.GetElement("xdat:user").getDbName(); + String login = null; + if (user != null) { + login = user.getLogin(); + } + String filePath = (String) retrieveCacheFileLink(o, dbName, login); + if (filePath != null) { + File f = new File(filePath); + if (f.exists()) { + writeFile(f, res); + } + } + } catch (Exception e) { + logger.error("", e); + } + } else if (user != null) { + getDataFile(user, path, res); + } + } + + /* (non-Javadoc) + * @see javax.servlet.GenericServlet#init(javax.servlet.ServletConfig) + */ + @Override + public void init(ServletConfig arg0) throws ServletException { + super.init(arg0); + ArcSpecManager.GetInstance(); + } +} diff --git a/src/main/java/org/nrg/xnat/servlet/RESTServlet.java b/src/main/java/org/nrg/xnat/servlet/RESTServlet.java deleted file mode 100644 index 471495e8c7f289cf77454f0f889803d9919c4539..0000000000000000000000000000000000000000 --- a/src/main/java/org/nrg/xnat/servlet/RESTServlet.java +++ /dev/null @@ -1,50 +0,0 @@ -/* - * org.nrg.xnat.servlet.RESTServlet - * XNAT http://www.xnat.org - * Copyright (c) 2014, Washington University School of Medicine - * All Rights Reserved - * - * Released under the Simplified BSD. - * - * Last modified 7/10/13 9:04 PM - */ -package org.nrg.xnat.servlet; - -import java.io.IOException; - -import javax.servlet.ServletException; -import javax.servlet.http.HttpServlet; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; - -import org.apache.log4j.Logger; - -public class RESTServlet extends HttpServlet { - static org.apache.log4j.Logger logger = Logger.getLogger(RESTServlet.class); - - @Override - protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - response.sendError(400); - } - - @Override - protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - response.sendError(400); - } - - - - @Override - protected void doPut(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - response.sendError(400); - } - - @Override - protected void doDelete(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - - response.sendError(400); - } -} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/actions/PlexiViewerSpec.java b/src/main/java/org/nrg/xnat/turbine/modules/actions/PlexiViewerSpec.java deleted file mode 100644 index a03e05426b4280fa4853b74536654df1577ebc20..0000000000000000000000000000000000000000 --- a/src/main/java/org/nrg/xnat/turbine/modules/actions/PlexiViewerSpec.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * org.nrg.xnat.turbine.modules.actions.PlexiViewerSpec - * XNAT http://www.xnat.org - * Copyright (c) 2014, Washington University School of Medicine - * All Rights Reserved - * - * Released under the Simplified BSD. - * - * Last modified 7/10/13 9:04 PM - */ - -package org.nrg.xnat.turbine.modules.actions; - -import org.apache.log4j.Logger; -import org.apache.turbine.util.RunData; -import org.apache.velocity.context.Context; -import org.nrg.plexiViewer.manager.PlexiSpecDocReader; -import org.nrg.xdat.turbine.modules.actions.SecureAction; - -public class PlexiViewerSpec extends SecureAction { - - static Logger logger = Logger.getLogger(PlexiViewerSpec.class); - - public void doPerform(RunData data, Context context){ - boolean rtn = PlexiSpecDocReader.GetInstance().refresh(); - String msg = "PlexiViewerSpec file was refreshed with " + (rtn?"success":"failure"); - logger.info(msg); - data.setMessage(msg); - //data.getParameters().add("popup", "true"); - //data.setScreenTemplate("ClosePage.vm"); - } -} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/actions/ShowViewerAction.java b/src/main/java/org/nrg/xnat/turbine/modules/actions/ShowViewerAction.java deleted file mode 100644 index 0590066e63b5341f32e97f42c3b479dd84006d87..0000000000000000000000000000000000000000 --- a/src/main/java/org/nrg/xnat/turbine/modules/actions/ShowViewerAction.java +++ /dev/null @@ -1,120 +0,0 @@ -/* - * org.nrg.xnat.turbine.modules.actions.ShowViewerAction - * XNAT http://www.xnat.org - * Copyright (c) 2014, Washington University School of Medicine - * All Rights Reserved - * - * Released under the Simplified BSD. - * - * Last modified 7/10/13 9:04 PM - */ -package org.nrg.xnat.turbine.modules.actions; - -import org.apache.log4j.Logger; -import org.apache.turbine.util.RunData; -import org.apache.velocity.context.Context; -import org.nrg.xdat.turbine.modules.actions.DisplaySearchAction; -import org.nrg.xdat.turbine.modules.actions.SecureAction; -import org.nrg.xdat.turbine.utils.TurbineUtils; -import org.nrg.xft.exception.ElementNotFoundException; -import org.nrg.xft.exception.FieldNotFoundException; -import org.nrg.xft.exception.XFTInitException; -import org.nrg.xft.search.TableSearch; - -public class ShowViewerAction extends SecureAction { - static org.apache.log4j.Logger logger = Logger.getLogger(ShowViewerAction.class); - - /* (non-Javadoc) - * @see org.apache.turbine.modules.actions.VelocityAction#doPerform(org.apache.turbine.util.RunData, org.apache.velocity.context.Context) - */ - public void doPerform(RunData data, Context context) throws Exception { - if (data.getParameters().containsKey("searchValue")) - { - String s = ((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("searchValue",data)); - if (s==null || s.equalsIgnoreCase("")) - { - data.setMessage("Please specify a search value."); - data.setScreenTemplate("Index.vm"); - }else{ - s = s.toLowerCase(); - if(s.indexOf("'")>-1){ - data.setMessage("Invalid character '"); - data.setScreenTemplate("Index.vm"); - return; - } - if(s.indexOf("\\")>-1){ - data.setMessage("Invalid character \\"); - data.setScreenTemplate("Index.vm"); - return; - } - try { - org.nrg.xft.XFTTable table =TableSearch.Execute("SELECT ID from xnat_subjectdata WHERE LOWER(ID) LIKE '%" + s + "%';",TurbineUtils.getUser(data).getDBName(),TurbineUtils.getUser(data).getLogin()); - - if (table.size()>0) - { - if (table.size()==1) - { - String v = table.getFirstObject().toString(); - data.getParameters().setString("skipq","true"); - data.getParameters().setString("id",v); - }else{ - DisplaySearchAction dsa = new DisplaySearchAction(); - data.getParameters().setString("ELEMENT_0","xnat:subjectData"); - data.getParameters().setString("xnat:subjectData.COMBO0_FIELDS","xnat:subjectData.SUBJECTID_equals,xnat:subjectData/label_equals,xnat:subjectData/sharing/share/label_equals"); - data.getParameters().setString("xnat:subjectData.COMBO0",s); - dsa.doPerform(data,context); - return; - } - }else{ - table =TableSearch.Execute("SELECT ID FROM xnat_mrSessionData WHERE LOWER(ID) LIKE '%" + s + "%';",TurbineUtils.getUser(data).getDBName(),TurbineUtils.getUser(data).getLogin()); - - if (table.size()>0) - { - if (table.size()==1) - { - Object v = table.getFirstObject(); - data.getParameters().setString("search_value",v.toString()); - data.getParameters().setString("search_element","xnat:mrSessionData"); - data.getParameters().setString("search_field","xnat:mrSessionData.ID"); - }else{ - DisplaySearchAction dsa = new DisplaySearchAction(); - data.getParameters().setString("ELEMENT_0","xnat:mrSessionData"); - data.getParameters().setString("xnat:mrSessionData.SESSION_ID_equals",s); - dsa.doPerform(data,context); - return; - } - }else{ - data.setMessage("No matching items found."); - } - } - } catch (ElementNotFoundException e1) { - logger.error("",e1); - data.setMessage(e1.getMessage()); - } catch (XFTInitException e1) { - logger.error("",e1); - data.setMessage(e1.getMessage()); - } catch (FieldNotFoundException e1) { - logger.error("",e1); - data.setMessage(e1.getMessage()); - } catch (Exception e1) { - logger.error("",e1); - data.setMessage(e1.getMessage()); - } - } - } - - if (data.getParameters().containsKey("skipq")) { - context.put("skipq", "true"); - context.put("id",((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("id",data))); - data.getParameters().remove("skipq"); - }else { - String sessionId = ((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("session",data)); - context.put("sessionId",sessionId); - if (((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("startDisplayWith",data))!=null && !((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("startDisplayWith",data)).equalsIgnoreCase("")) - context.put("startDisplayWith",((String)org.nrg.xdat.turbine.utils.TurbineUtils.GetPassedParameter("startDisplayWith",data))); - } - - data.setScreenTemplate("Viewer.vm"); - } - -} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/actions/XDATRegisterUser.java b/src/main/java/org/nrg/xnat/turbine/modules/actions/XDATRegisterUser.java index b61c959281a8ef13a7567c88ec9bf8d04ab9862a..8db9f45c42be833aad9bf5f140c0bc07d34202ec 100644 --- a/src/main/java/org/nrg/xnat/turbine/modules/actions/XDATRegisterUser.java +++ b/src/main/java/org/nrg/xnat/turbine/modules/actions/XDATRegisterUser.java @@ -10,12 +10,6 @@ */ package org.nrg.xnat.turbine.modules.actions; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - import org.apache.commons.lang3.StringUtils; import org.apache.log4j.Logger; import org.apache.turbine.Turbine; @@ -25,12 +19,17 @@ import org.apache.turbine.util.RunData; import org.apache.velocity.context.Context; import org.nrg.xdat.XDAT; import org.nrg.xdat.turbine.utils.TurbineUtils; -import org.nrg.xft.XFT; import org.nrg.xft.security.UserI; import org.nrg.xnat.turbine.utils.ProjectAccessRequest; import org.springframework.security.web.savedrequest.HttpSessionRequestCache; import org.springframework.security.web.savedrequest.SavedRequest; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + public class XDATRegisterUser extends org.nrg.xdat.turbine.modules.actions.XDATRegisterUser { @Override @@ -94,13 +93,13 @@ public class XDATRegisterUser extends org.nrg.xdat.turbine.modules.actions.XDATR context.put("user", user); action.doPerform(data, context); } else if (!StringUtils.isEmpty(nextAction) && !nextAction.contains("XDATLoginUser") && !nextAction.equals(Turbine.getConfiguration().getString("action.login"))) { - if (XDAT.getSiteConfigPreferences().getUserRegistration() & !XDAT.verificationOn()) { + if (XDAT.getSiteConfigPreferences().getUserRegistration() & !XDAT.getSiteConfigPreferences().getEmailVerification()) { data.setAction(nextAction); VelocityAction action = (VelocityAction) ActionLoader.getInstance().getInstance(nextAction); action.doPerform(data, context); } } else if (!StringUtils.isEmpty(nextPage) && !nextPage.equals(Turbine.getConfiguration().getString("template.home"))) { - if (XDAT.getSiteConfigPreferences().getUserRegistration() && !XDAT.verificationOn()) { + if (XDAT.getSiteConfigPreferences().getUserRegistration() && !XDAT.getSiteConfigPreferences().getEmailVerification()) { data.setScreenTemplate(nextPage); } } diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/CompressedUploaderPage.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/CompressedUploaderPage.java new file mode 100644 index 0000000000000000000000000000000000000000..ab7ac9fe7b35182002a8ec09afdaf74c0c2fdc44 --- /dev/null +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/CompressedUploaderPage.java @@ -0,0 +1,32 @@ +/* + * org.nrg.xnat.turbine.modules.screens.ReportIssue + * XNAT http://www.xnat.org + * Copyright (c) 2014, Washington University School of Medicine + * All Rights Reserved + * + * Released under the Simplified BSD. + * + * Last modified 7/10/13 9:04 PM + */ +package org.nrg.xnat.turbine.modules.screens; + +import org.apache.turbine.util.RunData; +import org.apache.velocity.context.Context; +import org.nrg.xdat.om.ArcArchivespecification; +import org.nrg.xdat.turbine.modules.screens.SecureScreen; +import org.nrg.xnat.turbine.utils.ArcSpecManager; + +import java.text.SimpleDateFormat; +import java.util.Calendar; + +public class CompressedUploaderPage extends SecureScreen { + + @Override + protected void doBuildTemplate(RunData data, Context context) throws Exception { + final SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMdd_hhmmss"); + context.put("uploadID", formatter.format(Calendar.getInstance().getTime())); + final ArcArchivespecification arc = ArcSpecManager.GetInstance(); + context.put("arc", arc); + } + +} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/DICOMSCPPage.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/DICOMSCPPage.java new file mode 100644 index 0000000000000000000000000000000000000000..29b4036e7d6c58b9e60f6a53d883a9e9567b3604 --- /dev/null +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/DICOMSCPPage.java @@ -0,0 +1,32 @@ +/* + * org.nrg.xnat.turbine.modules.screens.ReportIssue + * XNAT http://www.xnat.org + * Copyright (c) 2014, Washington University School of Medicine + * All Rights Reserved + * + * Released under the Simplified BSD. + * + * Last modified 7/10/13 9:04 PM + */ +package org.nrg.xnat.turbine.modules.screens; + +import org.apache.turbine.util.RunData; +import org.apache.velocity.context.Context; +import org.nrg.xdat.om.ArcArchivespecification; +import org.nrg.xdat.turbine.modules.screens.SecureScreen; +import org.nrg.xnat.turbine.utils.ArcSpecManager; + +import java.text.SimpleDateFormat; +import java.util.Calendar; + +public class DICOMSCPPage extends SecureScreen { + + @Override + protected void doBuildTemplate(RunData data, Context context) throws Exception { + final SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMdd_hhmmss"); + context.put("uploadID", formatter.format(Calendar.getInstance().getTime())); + final ArcArchivespecification arc = ArcSpecManager.GetInstance(); + context.put("arc", arc); + } + +} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadApplet.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadApplet.java index c78e6e1952416dd77fbc30f17c6b9cecb113a17f..82d683f54f0b42c9775a77a0cca05792421fe9b3 100644 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadApplet.java +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadApplet.java @@ -12,8 +12,8 @@ package org.nrg.xnat.turbine.modules.screens; import org.apache.turbine.util.RunData; import org.apache.velocity.context.Context; +import org.nrg.xdat.XDAT; import org.nrg.xdat.turbine.utils.TurbineUtils; -import org.nrg.xnat.turbine.utils.ArcSpecManager; import org.nrg.xnat.utils.AppletConfig; import org.nrg.xnat.utils.XnatHttpUtils; import org.slf4j.Logger; @@ -57,9 +57,8 @@ public class UploadApplet extends UploadAppletScreen { } else if (TurbineUtils.HasPassedParameter("no_session_date", data)) { context.put("session_date", "no_session_date"); } - context.put("arc", ArcSpecManager.GetInstance()); - - org.nrg.config.entities.Configuration config = getAppletConfiguration(TurbineUtils.getUser(data), (String)context.get("project")); + + org.nrg.config.entities.Configuration config = getAppletConfiguration(XDAT.getUserDetails(), (String)context.get("project")); if(config != null) { String json = config.getContents(); diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAppletScreen.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAppletScreen.java index 743912a9ac7d87995869917082b8510a853597ef..36bb43c1ceb8af03d2103116fba4f02d7f5a444d 100644 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAppletScreen.java +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAppletScreen.java @@ -50,7 +50,7 @@ public abstract class UploadAppletScreen extends SecureScreen { scope = Scope.Site; } - boolean enableProjectAppletScript = XDAT.getBoolSiteConfigurationProperty("enableProjectAppletScript", false); + boolean enableProjectAppletScript = XDAT.getSiteConfigPreferences().getEnableProjectAppletScript(); org.nrg.config.entities.Configuration config = enableProjectAppletScript ? configService.getConfig(AppletConfig.toolName, AppletConfig.path, scope, projectId) : null; if (config == null || org.nrg.config.entities.Configuration.DISABLED_STRING.equalsIgnoreCase(config.getStatus())) { diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/ViewerHelp.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAssistantPage.java similarity index 58% rename from src/main/java/org/nrg/xnat/turbine/modules/screens/ViewerHelp.java rename to src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAssistantPage.java index 2fea87aea58e3edc8850d7cf89dc4114ca31e8d8..25dbf7a15d597d56b128687319959fe50ebdc382 100644 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/ViewerHelp.java +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadAssistantPage.java @@ -1,5 +1,5 @@ /* - * org.nrg.xnat.turbine.modules.screens.ViewerHelp + * org.nrg.xnat.turbine.modules.screens.ReportIssue * XNAT http://www.xnat.org * Copyright (c) 2014, Washington University School of Medicine * All Rights Reserved @@ -14,13 +14,11 @@ import org.apache.turbine.util.RunData; import org.apache.velocity.context.Context; import org.nrg.xdat.turbine.modules.screens.SecureScreen; -/** - * @author Tim - * - */ -public class ViewerHelp extends SecureScreen { +public class UploadAssistantPage extends SecureScreen { - public void doBuildTemplate(RunData data, Context context) - { + @Override + protected void doBuildTemplate(RunData data, Context context) throws Exception { + // doesn't currently need any context, just needed to subclass SecureScreen } + } diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadOptions.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadOptions.java new file mode 100644 index 0000000000000000000000000000000000000000..bf9f2a75c84c15fdc13bb53422f3f246c0501bea --- /dev/null +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/UploadOptions.java @@ -0,0 +1,41 @@ +/* + * org.nrg.xnat.turbine.modules.screens.ReportIssue + * XNAT http://www.xnat.org + * Copyright (c) 2014, Washington University School of Medicine + * All Rights Reserved + * + * Released under the Simplified BSD. + * + * Last modified 7/10/13 9:04 PM + */ +package org.nrg.xnat.turbine.modules.screens; + +import org.apache.turbine.util.RunData; +import org.apache.velocity.context.Context; +import org.nrg.xdat.om.ArcArchivespecification; +import org.nrg.xdat.turbine.modules.screens.SecureScreen; +import org.nrg.xnat.turbine.utils.ArcSpecManager; +import org.nrg.xnat.utils.AppletConfig; +import org.nrg.xnat.utils.XnatHttpUtils; +import org.apache.commons.lang3.StringUtils; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.nrg.framework.utilities.Reflection; +import org.nrg.xdat.om.XnatPvisitdata; +import org.nrg.xdat.turbine.utils.TurbineUtils; + +import java.text.SimpleDateFormat; +import java.util.Calendar; +import java.util.List; + +public class UploadOptions extends SecureScreen { + + @Override + protected void doBuildTemplate(RunData data, Context context) throws Exception { + final SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMdd_hhmmss"); + context.put("uploadID", formatter.format(Calendar.getInstance().getTime())); + final ArcArchivespecification arc = ArcSpecManager.GetInstance(); + context.put("arc", arc); + } + +} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/Viewer.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/Viewer.java deleted file mode 100644 index aec0f71c45039fa6990734d1fcda0cf7f1608caf..0000000000000000000000000000000000000000 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/Viewer.java +++ /dev/null @@ -1,86 +0,0 @@ -/* - * org.nrg.xnat.turbine.modules.screens.Viewer - * XNAT http://www.xnat.org - * Copyright (c) 2014, Washington University School of Medicine - * All Rights Reserved - * - * Released under the Simplified BSD. - * - * Last modified 7/10/13 9:04 PM - */ -package org.nrg.xnat.turbine.modules.screens; - -import org.apache.turbine.util.RunData; -import org.apache.velocity.context.Context; -import org.nrg.xdat.om.XnatMrassessordata; -import org.nrg.xdat.om.XnatMrsessiondata; -import org.nrg.xdat.om.XnatSubjectdata; -import org.nrg.xdat.turbine.modules.screens.SecureReport; -import org.nrg.xdat.turbine.utils.TurbineUtils; -import org.nrg.xnat.turbine.utils.XNATUtils; -import org.nrg.xnat.utils.XnatHttpUtils; - -/** - * @author Tim - * - */ -public class Viewer extends SecureReport { - - /* (non-Javadoc) - * @see org.apache.turbine.modules.screens.VelocityScreen#doBuildTemplate(org.apache.turbine.util.RunData, org.apache.velocity.context.Context) - */ - public void finalProcessing(RunData data, Context context) - { - if (om instanceof XnatMrsessiondata) - { - - }else if (om instanceof XnatSubjectdata) - { - om = ((XnatSubjectdata)om).getLastSession(); - item = om.getItem(); - - context.put("om",om); - context.put("item",item); - }else if (om instanceof XnatMrassessordata) - { - om = ((XnatMrassessordata)om).getMrSessionData(); - item = om.getItem(); - - context.put("om",om); - context.put("item",item); - } - context.put("appletPath",TurbineUtils.GetRelativeServerPath(data) + "/applet"); - context.put("jsessionid", XnatHttpUtils.getJSESSIONID(data)); - } - - public void noItemError(RunData data, Context context) - { - if (context.containsKey("skipq")) - { - try { - XnatMrsessiondata mr = XNATUtils.getLastSessionForParticipant((String)context.get("id"),TurbineUtils.getUser(data)); - - if (mr ==null) - { - try { - this.doRedirect(data,"ClosePage.vm"); - } catch (Exception e) { - } - }else{ - context.put("item",mr.getItem()); - context.put("om",mr); - context.put("appletPath",TurbineUtils.GetRelativeServerPath(data) + "/applet"); - context.put("jsessionid", XnatHttpUtils.getJSESSIONID(data)); - } - } catch (Exception e){ - e.printStackTrace(); - } - }else{ - data.setMessage("No results were found for your search."); - try { - this.doRedirect(data,"ClosePage.vm"); - } catch (Exception e) { - } - } - } -} diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_UpdateUser.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_UpdateUser.java index bbe5853cbcf632eb7aba1d6c8ccc8ffeb74eaf8e..758bf687598bcbf2a9b0c0fc726a5f0d2a96d20a 100644 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_UpdateUser.java +++ b/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_UpdateUser.java @@ -17,7 +17,6 @@ import org.apache.turbine.services.velocity.TurbineVelocity; import org.apache.turbine.util.RunData; import org.apache.velocity.context.Context; import org.apache.velocity.tools.generic.EscapeTool; -import org.nrg.config.exceptions.ConfigServiceException; import org.nrg.xdat.XDAT; import org.nrg.xdat.display.DisplayManager; import org.nrg.xdat.security.helpers.Users; @@ -26,7 +25,6 @@ import org.nrg.xdat.turbine.modules.screens.SecureScreen; import org.nrg.xdat.turbine.utils.AccessLogger; import org.nrg.xdat.turbine.utils.AdminUtils; import org.nrg.xdat.turbine.utils.TurbineUtils; -import org.nrg.xft.XFT; import org.nrg.xft.security.UserI; import java.sql.SQLException; @@ -54,10 +52,9 @@ public class XDATScreen_UpdateUser extends SecureScreen { c.put("showReason", XDAT.getSiteConfigPreferences().getShowChangeJustification()); c.put("requireReason", XDAT.getSiteConfigPreferences().getRequireChangeJustification()); - try{ - c.put("siteConfig", XDAT.getSiteConfiguration()); - }catch(ConfigServiceException ignored){ - } + + c.put("siteConfig", XDAT.getSiteConfigPreferences()); + doBuildTemplate(data, c); } @@ -132,7 +129,7 @@ public class XDATScreen_UpdateUser extends SecureScreen { if(!user.isEnabled()) { throw new Exception("User is not enabled: " + user.getUsername()); } - if (XDAT.verificationOn() && !user.isVerified()) { + if (XDAT.getSiteConfigPreferences().getEmailVerification() && !user.isVerified()) { throw new Exception("User is not verified: " + user.getUsername()); } } diff --git a/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_themes.java b/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_themes.java deleted file mode 100644 index 1308f443baa5d056be40e61f5c5ddbe725541e8e..0000000000000000000000000000000000000000 --- a/src/main/java/org/nrg/xnat/turbine/modules/screens/XDATScreen_themes.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * XNAT http://www.xnat.org - * Copyright (c) 2013, Washington University School of Medicine - * All Rights Reserved - * - * Released under the Simplified BSD. - * - * Author: Justin Cleveland <clevelandj@wustl.edu> - * Last modified 1/22/2016 3:20 PM - */ - -package org.nrg.xnat.turbine.modules.screens; - -import org.apache.log4j.Logger; -import org.apache.turbine.util.RunData; -import org.apache.velocity.context.Context; -import org.nrg.xdat.turbine.modules.screens.SecureScreen; - -public class XDATScreen_themes extends SecureScreen { - public final static Logger logger = Logger.getLogger(XDATScreen_themes.class); - @Override - protected void doBuildTemplate(RunData data, Context context) throws Exception { - } -} diff --git a/src/main/resources/META-INF/xnat/spawner/site-admin-elements.yaml b/src/main/resources/META-INF/xnat/spawner/site-admin-elements.yaml index 90ec9f5c385fe242258ffc6032ecf608ba2aa91c..96bedc629c821fcf574d230bc02972c1ddd2240a 100644 --- a/src/main/resources/META-INF/xnat/spawner/site-admin-elements.yaml +++ b/src/main/resources/META-INF/xnat/spawner/site-admin-elements.yaml @@ -18,22 +18,15 @@ siteId: description: "The id used to refer to this site (also used to generate database ids). The Site ID must start with a letter and contain only letters, numbers and underscores. It should be a short, one-word name or acronym which describes your site. No spaces or non-alphanumeric characters." siteDescriptionType: - kind: panel.display # make this a radio button group + kind: panel.display id: siteDescriptionType name: siteDescriptionType label: Site Description value: Select a site description option below - # onchange: # some javascript that toggles display of the elements below appropriately - -siteDescriptionOptionText: - kind: panel.input.checkbox # make this a radio button group - id: siteDescriptionOptionText - label: "Text (Markdown)" - -siteDescriptionOptionPage: - kind: panel.input.checkbox # make this a radio button group - id: siteDescriptionOptionPage - label: "Page" + before: + - "<script type=\"text/javascript\" src=\"../../scripts/xnat/admin/siteInfo.js\"></script>" + after: + - "<span style=\"position: relative; top: -15px;left: 270px;\"><input type=\"radio\" name=\"siteDescriptionType\" id=\"siteDescriptionTypePage\" value=\"Page\"> Page <input type=\"radio\" name=\"siteDescriptionType\" id=\"siteDescriptionTypeText\" value=\"Text\"> Text (Markdown)</span>" siteDescriptionPage: kind: panel.input.text @@ -90,7 +83,6 @@ adminEmail: id: adminEmail name: adminEmail label: Site Administrator Email Address - value: ?? XNAT.data.siteConfig.adminEmail fileSystemSettingsWarning: someInfo: @@ -101,7 +93,6 @@ fileSystemSettingsWarning: and are seldom, if ever, changed. style: fontWeight: bold - archivePath: kind: panel.input.text id: archivePath @@ -109,8 +100,6 @@ archivePath: label: Archive Path validation: required path description: "" - value: ?? XNAT.data.siteConfig.archivePath - cachePath: kind: panel.input.text id: cachePath @@ -118,8 +107,6 @@ cachePath: label: Cache Path validation: required path description: "" - value: ?? XNAT.data.siteConfig.cachePath - prearchivePath: kind: panel.input.text id: prearchivePath @@ -127,8 +114,6 @@ prearchivePath: label: Prearchive Path validation: required path description: "" - value: ?? XNAT.data.siteConfig.prearchivePath - ftpPath: kind: panel.input.text id: ftpPath @@ -136,7 +121,6 @@ ftpPath: label: FTP Path validation: required path description: "" - value: ??XNAT.data.siteConfig.cachePath buildPath: kind: panel.input.text id: buildPath @@ -144,7 +128,6 @@ buildPath: label: Build Path validation: required id onblur description: "" - value: ??XNAT.data.siteConfig.cachePath pipelinePath: kind: panel.input.text id: pipelinePath @@ -152,14 +135,6 @@ pipelinePath: label: Pipeline Path validation: required id onblur description: "" - value: ??XNAT.data.siteConfig.cachePath -dataFolders: - kind: panel.input.text - id: dataFolders - name: dataFolders - label: Data Folders - validation: required id onblur - description: "" zipExtensions: kind: panel.input.text id: zipExtensions @@ -171,16 +146,14 @@ siteInfo: name: siteInfo label: Site Information method: POST - action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: ${siteId} ${siteUrl} ${siteDescriptionType} - ${siteDescriptionOptionText} - ${siteDescriptionOptionPage} ${siteDescriptionPage} ${siteDescriptionText} ${siteLoginLanding} @@ -192,6 +165,11 @@ adminInfo: kind: panel.form name: adminInfo label: Admin Information + method: POST + contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: ${adminEmail} @@ -199,17 +177,25 @@ generalSecuritySettings: kind: panel.form name: generalSecuritySettings label: General Site Security Settings + method: POST + contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: securityChannel: kind: panel.select.single id: securityChannel name: securityChannel label: Security Channel - value: https + value: "" options: - # value: label # <- simplest setup - http: http - https: https + http: + label: http + value: http + https: + label: https + value: https element: id: security-channel title: Security Channel @@ -226,75 +212,63 @@ userLoginsSessionControls: label: User Logins / Session Controls method: POST action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig - refresh: /xapi/siteConfig + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig + contentType: json contents: - sessionTimeout: kind: panel.input.number id: sessionTimeout - name: aliasTokenTimeout + name: sessionTimeout label: Session Timeout - value: ?? XNAT.data.siteConfig.sessionTimeout || 15 - description: > - Interval for timing out alias tokens. Uses - <a target="_blank" href="http://www.postgresql.org/docs/9.0/static/functions-datetime.html">PostgreSQL interval notation</a> - - sessionTimeoutMessage: + description: "Number of minutes of inactivity before users are locked out of the site. This will not affect users that are currently logged in." + aliasTokenTimeout: kind: panel.input.text + id: aliasTokenTimeout + name: aliasTokenTimeout + label: Alias Token Timeout + description: Number of minutes before alias tokens expire. + sessionTimeoutMessage: + kind: panel.textarea id: sessionTimeoutMessage name: sessionTimeoutMessage label: Session Timeout Message - value: ?? XNAT.data.siteConfig.sessionTimeoutMessage || "Your session has timed out." - description: Alert message provided to users after a session timeout and logout. - + description: Alert message provided to users after a session timeout. TIMEOUT_TIME will be replaced by the timeout time. allowResumeOnNextLogin: kind: panel.input.checkbox id: allow-resume-on-next-login name: allowResumeOnNextLogin label: Allow Resume On Next Login? - value: ?? XNAT.data.siteConfig.allowResumeOnNextLogin description: Allow user to resume where they left off, if logging back in after a session timeout? - maximumConcurrentSessions: kind: panel.input.number id: maximumConcurrentSessions - name: security.sessions.concurrent_max + name: sessions.concurrent_max label: Maximum Concurrent Sessions - value: ?? XNAT.data.siteConfig.maximumConcurrentSessions || 5 description: The maximum number of permitted sessions a user can have open simultaneously - loginFailureMessage: - kind: panel.input.text + kind: panel.textarea id: loginFailureMessage name: UI.login_failure_message label: Login Failure Message - value: Login failed description: Text to show when a user fails to login - maximumFailedLogins: kind: panel.input.number id: maximumFailedLogins - name: security.max_failed_logins + name: maxFailedLogins label: Maximum Failed Logins - value: -1 description: Number of failed login attempts before accounts are temporarily locked. (-1 disables feature) - failedLoginLockoutDuration: kind: panel.input.number id: failedLoginLockoutDuration name: maxFailedLoginsLockoutDuration label: Failed Login Lockout Duration - value: 0 description: Number of milliseconds to lock user accounts that have exceeded the max_failed_logins count. Select (3600000 for 1 hour, 86400000 for 24 hours) - userInactivityLockout: kind: panel.input.number id: userInactivityLockout name: inactivityBeforeLockout label: User Inactivity Lockout - value: 31556926 description: Number of seconds of inactivity before an account is disabled (31556926 for 1 year) inactivityBeforeLockoutSchedule: kind: panel.input.text @@ -308,36 +282,33 @@ passwords: label: Passwords method: POST action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: passwordComplexity: kind: panel.input.text id: passwordComplexity name: passwordComplexity label: Password Complexity - value: "^.*$" description: Must be a valid regular expression. passwordComplexityMessage: - kind: panel.input.text + kind: panel.textarea id: passwordComplexityMessage name: passwordComplexityMessage label: Password Complexity Message - value: "Your password must contain..." passwordHistoryDuration: kind: panel.input.number id: passwordHistoryDuration name: passwordHistoryDuration label: Password History (Duration) - value: -1 description: "-1 to disable" passwordExpirationType: kind: panel.select.single id: passwordExpirationType name: passwordExpirationType label: passwordExpirationType - value: Interval + value: "" options: Interval: label: Interval @@ -350,7 +321,6 @@ passwords: id: passwordExpirationInterval name: passwordExpirationInterval label: Password Expiration (Interval) - value: -1 description: "-1 to disable" passwordExpirationDate: kind: panel.input.text @@ -368,57 +338,39 @@ passwords: id: requireSaltedPasswords name: requireSaltedPasswords label: Require Passwords To Be Salted - value: false csrf: kind: panel.form name: csrf label: CSRF + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: enableCsrfToken: kind: panel.input.checkbox id: enableCsrfToken name: enableCsrfToken label: Require CSRF Token? - value: true description: Should this site require the use of a token to prevent CSRF attacks on POST, PUT, and DELETEs? csrfEmailAlert: kind: panel.input.checkbox id: csrfEmailAlert name: enable_csrf_email_alert label: CSRF Email Alert - value: "Should this site send an email to the site admin whenever a CSRF attack is attempted?" - -auditTrail: - kind: panel.form - name: auditTrail - label: Audit Trail Configuration - contents: - enableAuditTrail: - kind: panel.input.checkbox - id: enableAuditTrail - name: enableAuditTrail - label: Enable Audit Trail? - value: true - allowUserJustificationForChanges: - kind: panel.input.checkbox - id: allowUserJustificationForChanges - name: allowUserJustificationForChanges - label: Allow User Justification For Changes - value: true - description: "Allow users to enter change justifications when modifying data" - requireUserJustificationForChanges: - kind: panel.input.checkbox - id: requireUserJustificationForChanges - name: requireUserJustificationForChanges - label: Require User Justification For Changes - value: false - description: "Force users to enter change justifications when modifying data" + description: "Should this site send an email to the site admin whenever a CSRF attack is attempted?" securityServices: kind: panel.form name: securityServices label: Security Services + action: /xapi/siteConfig/batch + method: POST + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: securityServicesFeatureDefault: kind: panel.input.text @@ -444,12 +396,10 @@ securityServices: emailServerSettings: kind: panel.form method: POST - action: /xapi/notifications/all - load: # load data - url: /xapi/siteConfig - prop: smtpServer # which root property? gets the root object if not set -# lookup: XNAT.data.siteConfig.smtpServer + action: /xapi/siteConfig/smtpServer contentType: json + load: ?? XNAT.data.siteConfig.smtpServer + refresh: /xapi/siteConfig/smtpServer name: emailServerSettings label: Mail Server Settings contents: @@ -458,38 +408,30 @@ emailServerSettings: id: smtpEnabled name: smtp.enabled label: "Enable SMTP?" - #value: true - checked: true hostname: kind: panel.input.text name: host label: Host - value: localhost + placeholder: localhost port: kind: panel.input.number name: port label: Port - value: "" - element: - placeholder: 587 + placeholder: 587 username: kind: panel.input.text name: username label: Username - url: /xapi/notifications/username - value: '' - element: - placeholder: name@host.org + placeholder: name@host.org password: kind: panel.input.password name: password label: Password - value: '' protocol: kind: panel.input.text name: protocol label: Protocol - value: '' + placeholder: smtp # subhead breaks up panel items mailServerProperties: kind: panel.subhead @@ -499,122 +441,147 @@ emailServerSettings: kind: panel.input.checkbox name: mail.smtp.auth label: SMTP Auth? - #value: true - checked: true smtpStartTls: kind: panel.input.checkbox name: mail.smtp.starttls.enable label: Smart TLS? - #value: true - checked: true smtpSSLTrust: kind: panel.input.text name: mail.smtp.ssl.trust label: SSL Trust - value: '' - element: - placeholder: localhost + placeholder: localhost emailPrefix: kind: panel.input.text name: emailPrefix label: Email Prefix - element: - placeholder: XNAT + placeholder: XNAT notifications: kind: panel.form name: notifications label: Notifications + action: /xapi/siteConfig/batch + method: POST + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: + helpContactInfo: kind: panel.input.email id: helpContactInfo - name: helpContactInfo + name: notifications.helpContactInfo label: "Help Contact Info" +# value: "!? XNAT.data.siteConfig['notifications.helpContactInfo'] || XNAT.data.siteConfig.adminEmail" + + emailMessageSubhead: + kind: panel.subhead + label: Email Messages + emailMessageUserRegistration: - kind: panel.textarea # textarea + kind: panel.textarea id: emailMessageUserRegistration - name: emailMessageUserRegistration - label: "Email Message: User Registration" + name: notifications.emailMessageUserRegistration + label: "User Registration" description: "Text of message emailed to users upon registration. Link for email validation is auto-populated." emailMessageForgotUsernameRequest: - kind: panel.textarea # textarea + kind: panel.textarea id: emailMessageForgotUsernameRequest - name: emailMessageForgotUsernameRequest - label: "Email Message: Forgot Username Request" + name: notifications.emailMessageForgotUsernameRequest + label: "Forgot Username Request" description: "Text of message emailed to users upon lost username request." emailMessageForgotPasswordReset: - kind: panel.textarea # textarea + kind: panel.textarea id: emailMessageForgotPasswordReset - name: emailMessageForgotPasswordReset - label: "Email Message: Password Reset" + name: notifications.emailMessageForgotPasswordReset + label: "Password Reset" description: "Text of message emailed to users upon lost password reset. Link for password reset is auto-populated" + + notifyAdminSubhead: + kind: panel.subhead + label: "Notify Administrator on..." + notifyAdminUserRegistration: kind: panel.input.checkbox id: notifyAdminUserRegistration - name: notifyAdminUserRegistration - label: "Notify Admin on User Registration" - value: ?? XNAT.data.siteConfig.notifyAdminUserRegistration + name: notifications.notifyAdminUserRegistration +# value: "?? XNAT:data:siteConfig:notifications.notifyAdminUserRegistration" + label: "User Registration" description: "Whether to cc admin user on new user emails. Requires valid admin email address." notifyAdminPipelineEmails: kind: panel.input.checkbox id: notifyAdminPipelineEmails - name: notifyAdminPipelineEmails - label: "Notify Admin on Pipeline Emails" - value: false + name: notifications.notifyAdminPipelineEmails +# value: "?? XNAT:data:siteConfig:notifications.notifyAdminPipelineEmails" + label: "Pipeline Emails" description: "Whether to cc admin user on pipeline processing submit. Requires valid admin email address." notifyAdminProjectAccessRequest: kind: panel.input.checkbox id: notifyAdminProjectAccessRequest - name: notifyAdminProjectAccessRequest - label: "Notify Admin on Project Access Request" - value: false + name: notifications.notifyAdminProjectAccessRequest +# value: "?? XNAT:data:siteConfig:notifications.notifyAdminProjectAccessRequest" + label: "Project Access Request" description: "Whether to cc admin user on user project access request. Requires valid admin email address." notifyAdminSessionTransfer: kind: panel.input.checkbox id: notifyAdminSessionTransfer - name: notifyAdminSessionTransfer - label: "Notify Admin on Session Transfer" - value: false + name: notifications.notifyAdminProjectOnSessionTransfer +# value: "?? XNAT:data:siteConfig:notifications.notifyAdminProjectOnSessionTransfer" + label: "Session Transfer" description: "Whether to cc admin user on session transfer by user. Requires valid admin email address." + + emailRecipientSubhead: + kind: panel.subhead + label: "Email Recipient(s) for..." + emailRecipientErrorMessages: kind: panel.input.email id: emailRecipientErrorMessages - name: emailRecipientErrorMessages - label: "Email Recipient: Error Messages" + name: notifications.emailRecipientErrorMessages + label: "Error Messages" description: "What email address should receive error emails" + #value: "!? XNAT.data.siteConfig['notifications.emailRecipientErrorMessages'] || XNAT.data.siteConfig.adminEmail" emailRecipientIssueReports: kind: panel.input.email id: emailRecipientIssueReports - name: emailRecipientIssueReports - label: "Email Recipient: Issue Reports" + name: notifications.emailRecipientIssueReports + label: "Issue Reports" description: "What email address should receive issue reports" + #value: "!? XNAT.data.siteConfig['notifications.emailRecipientIssueReports'] || XNAT.data.siteConfig.adminEmail" emailRecipientNewUserAlert: kind: panel.input.email id: emailRecipientNewUserAlert - name: emailRecipientNewUserAlert - label: "Email Recipient: New User Alert" + name: notifications.emailRecipientNewUserAlert + label: "New User Alert" description: "What email address should receive New User Registration emails" + #value: "!? XNAT.data.siteConfig['notifications.emailRecipientNewUserAlert'] || XNAT.data.siteConfig.adminEmail" emailRecipientUpdate: kind: panel.input.email id: emailRecipientUpdate - name: emailRecipientUpdate - label: "Email Recipient: Updates" + name: notifications.emailRecipientUpdate + label: "Updates" description: "What email address should receive update emails" + #value: "!? XNAT.data.siteConfig['notifications.emailRecipientUpdate'] || XNAT.data.siteConfig.adminEmail" + + otherSubhead: + kind: panel.subhead + label: "Other" + emailAllowNonuserSubscribers: kind: panel.input.checkbox id: emailAllowNonuserSubscribers name: emailAllowNonuserSubscribers label: "Allow Nonuser Subscribers" - value: ?? XNAT.data.siteConfig.emailAllowNonuserSubscribers +# value: "?? XNAT.data.siteConfig.emailAllowNonuserSubscribers" themeManagement: - kind: panel + kind: panel.form name: themeManagement label: Theme Management + action: /xapi/theme contents: themeScript: - tag: script|type=text/javascript;src=../../scripts/themeManagement.js + tag: script|type=text/javascript;src=../../scripts/xnat/admin/themeManagement.js themeStyle: tag: style element: @@ -624,22 +591,26 @@ themeManagement: id: currentTheme label: Current Theme description: The currently selected global theme. - value: None + value: "" element: style: color: 'red' existingTheme: kind: panel.select.single id: themeSelection + name: themeSelection label: Select an existing theme description: Selected a new global theme from those available on the system. - value: None + value: "" options: default: label: None value: None after: - - "<span style=\"position: relative; top: -49px;left: 270px;\"> <button id=\"submitThemeButton\" onclick=\"setTheme();\">Set Theme</button> <button id=\"removeThemeButton\" onclick=\"removeTheme();\">Remove Theme</button></span>" + - "<span style=\"position: relative; top: -49px;left: 270px;\"> <!-- <button id=\"submitThemeButton\" onclick=\"setTheme();\">Set Theme</button> --> <button id=\"removeThemeButton\" onclick=\"removeTheme();\">Remove Theme</button></span>" + element: + style: + min-width: 250px uploadTheme: kind: panel.input.upload id: themeFileUpload @@ -652,29 +623,36 @@ authenticationMethods: kind: panel.form name: authenticationMethods label: User Authentication Methods + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: xnatInternal: kind: panel.input.checkbox id: xnatInternal name: provider.providers.xnatInternal label: XNAT (Internal) - value: true ldapProvider: kind: panel.input.checkbox id: ldapProvider name: provider.providers.ldap label: LDAP - value: false - oauthProvider: - kind: panel.input.checkbox - id: oauthProvider - name: provider.providers.oauth - label: OAuth - value: false +# oauthProvider: +# kind: panel.input.checkbox +# id: oauthProvider +# name: provider.providers.oauth +# label: OAuth genericAuthenticationProvider: kind: panel.form name: genericAuthenticationProvider label: Generic Authentication Provider + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: providerDbName: kind: panel.input.text @@ -691,10 +669,16 @@ genericAuthenticationProvider: id: providerDbType name: providerDbType label: "Provider DB Type" + ldapAuthentication: kind: panel.form name: ldapAuthenticationProvider label: LDAP Authentication Provider + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: ldapName: kind: panel.input.text @@ -754,123 +738,112 @@ registrationOptions: kind: panel.form name: registrationOptions label: Registration Options + method: POST + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + contentType: json contents: requireLogin: kind: panel.input.checkbox id: requireLogin name: requireLogin label: "Require User?" - value: true - disabled: true + value: "" requireEmailVerificationToRegister: kind: panel.input.checkbox id: requireEmailVerificationToRegister name: emailVerification label: "Require Email Verification To Register?" - value: true emailVerificationMessage: - kind: panel.input.text #textarea + kind: panel.textarea id: emailVerificationMessage name: emailVerificationMessage label: "Email Verification Message" - value: "" emailVerificationExpiration: kind: panel.input.number id: emailVerificationExpiration name: emailVerificationExpiration label: "Email Verification Expiration" - value: 60000 autoEnableUserRegistration: kind: panel.input.checkbox id: autoEnableUserRegistration name: userRegistration label: "Auto-enable User Registration?" - value: false allowUserCommentsOnRegistration: kind: panel.input.checkbox id: allowUserCommentsOnRegistration name: allowUserCommentsOnRegistration label: "Allow User Comments on Registration?" - value: true restrictUserListAccessToAdmins: kind: panel.input.checkbox id: restrictUserListAccessToAdmins name: restrictUserListAccessToAdmins label: "Restrict User List Access To Admins?" - value: true - -dataReporting: - kind: panel.form - name: dataReporting - label: Data Reporting - contents: - enableAdvancedSearch: - kind: panel.input.checkbox - id: enableAdvancedSearch - name: enableAdvancedSearch - label: "Enable Advanced Search" - value: true manageDataTypes: kind: panel.form name: manageDataTypes label: Manage Data Types method: POST - action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: displayNameForGenericImageSessionSingular: kind: panel.input.text id: displayNameForGenericImageSessionSingular name: displayNameForGenericImageSession.singular label: "Singular Display Name For Generic Image Session Singular" - value: "Session" displayNameForGenericImageSessionPlural: kind: panel.input.text id: displayNameForGenericImageSessionPlural name: displayNameForGenericImageSession.plural label: "Plural Display Name For Generic Image Session Singular" - value: "Sessions" anonymization: kind: panel.form name: Anonymization label: "Anonymization Script (Site Wide)" + method: POST + contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: enableSitewideAnonymizationScript: kind: panel.input.checkbox id: enableSitewideAnonymizationScript name: enableSitewideAnonymizationScript label: "Enable Site-wide Anonymization Script" - value: true - editAnonymzationScript: - kind: panel.input.text #textarea - id: editAnonymzationScript - name: editAnonymzationScript - label: "Edit Anonymzation Script" - value: true + editAnonymizationScript: + kind: panel.textarea + id: editAnonymizationScript + name: editAnonymizationScript + label: "Edit Anonymization Script" seriesImportFilter: kind: panel.form name: seriesImportFilter label: "Series Import Filter" + method: POST + contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: enableSitewideSeriesImportFilter: kind: panel.input.checkbox id: enableSitewideSeriesImportFilter name: enableSitewideSeriesImportFilter label: "Enable Site-wide Series Import Filter" - value: false filterMode: kind: panel.input.checkbox id: filterMode name: filterMode label: Filter Mode - value: false seriesImportFilter: - kind: panel.input.text #textarea + kind: panel.textarea id: seriesImportFilter name: seriesImportFilter label: "Edit Series Import Filter" @@ -879,6 +852,11 @@ sessionUploadMethod: kind: panel.form name: sessionUploadMethod label: "Session Upload Method" + method: POST + contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: selectUploadMethod: kind: panel.select.single @@ -887,25 +865,23 @@ sessionUploadMethod: label: "Session Upload Method" # options: # don't know where to populate this from # http: -# label: http -# value: http +# label: +# value: # https: -# label: https -# value: https +# label: +# value: showApplet: kind: panel.input.checkbox id: showApplet name: showApplet label: Show Applet - value: false enableProjectAppletScript: kind: panel.input.checkbox id: enableProjectAppletScript name: enableProjectAppletScript label: Enable Project Applet Script - value: false appletScript: - kind: panel.input.text #textarea + kind: panel.textarea id: appletScript name: appletScript label: "Applet Script" @@ -914,14 +890,11 @@ sessionUploadMethod: id: sessionXmlRebuilderRepeat name: sessionXmlRebuilderRepeat label: Session Xml Rebuilder Repeat - value: 60000 sessionXmlRebuilderInterval: kind: panel.input.number id: sessionXmlRebuilderInterval name: sessionXmlRebuilderInterval label: Session Xml Rebuilder Interval - value: 5 - dicomScpReceivers: kind: panel.form @@ -929,17 +902,14 @@ dicomScpReceivers: label: DICOM SCP Receivers method: POST action: /xapi/dicomscp - load: - url: /xapi/dicomscp -# prop: # Not set, so should get the root object contentType: json + load: $? /xapi/dicomscp contents: enableDicomReceiver: kind: panel.input.checkbox id: enableDicomReceiver name: enableDicomReceiver label: DICOM Receiver Enabled? - value: true description: "Should the DICOM receiver listen for connections?" someInfo: tag: div.message @@ -952,7 +922,6 @@ dicomScpReceivers: id: enableDicomReceiverPropertyChangedListener name: enableDicomReceiverPropertyChangedListener # Should this be "enableDicomReceiver.property.changed.listener" label: "Enable Dicom Receiver Property Changed Listener" - value: "org.nrg.dcm.DicomSCPSiteConfigurationListener" dicomHost: kind: panel.input.text id: dicomHost @@ -982,7 +951,6 @@ dicomScpReceivers: id: receivedFileUser name: receivedFileUser label: "Default DICOM Receiver: User" - value: admin description: "User account for default DICOM receiver" fileSystem: @@ -990,10 +958,9 @@ fileSystem: name: fileSystem label: File System method: POST - action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig contents: ${archivePath} ${cachePath} @@ -1001,7 +968,6 @@ fileSystem: ${ftpPath} ${buildPath} ${pipelinePath} - ${dataFolders} ${zipExtensions} misc: @@ -1009,30 +975,49 @@ misc: name: misc label: Miscellaneous method: POST - action: /xapi/siteConfig/batch - load: - lookup: XNAT.data.siteConfig contentType: json + action: /xapi/siteConfig/batch + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig contents: checksums: kind: panel.input.checkbox id: checksums name: checksums label: Checksums? - value: true checksumsPropertyChangedListener: kind: panel.input.text id: checksumsPropertyChangedListener name: checksums.property.changed.listener label: Checksums Property Changed Listener? - value: org.nrg.xnat.utils.ChecksumsSiteConfigurationListener scanTypeMapping: kind: panel.input.checkbox id: scanTypeMapping name: scanTypeMapping label: Scan Type Mapping? - value: true - + development: + kind: panel.subhead + label: Development Utilities + spawner: + kind: panel.element + description: Manage spawner elements. + contents: + link: + tag: a.link + element: + href: ./page/admin/spawner/ + target: _blank + html: Manage The Spawner + swagger: + kind: panel.element + description: View the Swagger page. + contents: + link: + tag: a.link + element: + href: ./xapi/swagger-ui.html + target: _blank + html: Swagger development: kind: panel name: development @@ -1081,7 +1066,6 @@ adminPage: ${userLoginsSessionControls} ${passwords} ${csrf} - ${auditTrail} ${securityServices} emailServer: kind: tab @@ -1113,14 +1097,14 @@ adminPage: ${authenticationMethods} ${genericAuthenticationProvider} ${ldapAuthentication} -# users: # enable when users table can be re-implmented in spawner, until then use old users config? +# users: # enable when users table can be re-implemented in spawner, until then use old users config? # kind: tab # name: users # label: Users # group: manageAccess # contents: # ${users} -# userRoles: # enable when user roles table can be re-implmented in spawner, until then use old user roles config? +# userRoles: # enable when user roles table can be re-implemented in spawner, until then use old user roles config? # kind: tab # name: userRoles # label: User Roles @@ -1134,13 +1118,6 @@ adminPage: group: manageAccess contents: ${registrationOptions} - dataReporting: - kind: tab - name: dataReporting - label: Data Reporting - group: manageData - contents: - ${dataReporting} manageDataTypes: kind: tab name: manageDataTypes @@ -1171,14 +1148,13 @@ adminPage: group: advanced contents: ${fileSystem} - ${siteIdMain} misc: kind: tab name: misc label: Miscellaneous contents: ${misc} - ${development} +# ${development} ########################################### @@ -1203,7 +1179,6 @@ sitePaths: # ${ftpPath} # ${buildPath} # ${pipelinePath} - ${dataFolders} initialSetup: kind: panel name: initialSetup diff --git a/src/main/resources/META-INF/xnat/spawner/site-setup-elements.yaml b/src/main/resources/META-INF/xnat/spawner/site-setup-elements.yaml new file mode 100644 index 0000000000000000000000000000000000000000..4f826705412437689db0fa39b14b124f41c71290 --- /dev/null +++ b/src/main/resources/META-INF/xnat/spawner/site-setup-elements.yaml @@ -0,0 +1,204 @@ +# The initial setup page elements are in a separate file for now +setupMessage: + tag: div.message + element: + style: + marginBottom: 24px + html: > + The settings below need to be configured before this XNAT system + can be used. Please set the properties below and submit the form to continue. + +# ==================== +# PANEL +siteInfo: + kind: panel.form + name: siteInfo + label: Site Information + footer: false + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig + contents: + + siteId: + kind: panel.input.text + name: siteId + label: Site ID + value: '' + placeholder: XNAT + description: > + The id used to refer to this site (also used to generate ids). The Site ID must start + with a letter and contain only letters, numbers and underscores. It should be a short, + one-word name or acronym which describes your site. + validation: required id + + siteUrl: + kind: panel.input.text + name: siteUrl + label: Site URL + value: '' + placeholder: localhost + description: > + The address you want visible to users in emails, and other external links. This should be a + functional address (i.e. if the user pasted this address in their web browser, they should + come to the site). localhost only works if the web browser is located on the same machine. + You are required to guarantee that this address is functional for reaching the site. + validation: required url + + adminEmail: + kind: panel.input.email + name: adminEmail + label: Administrator Email Address + value: '' + placeholder: admin@localhost + description: Email address for site administrator. + validation: required email + +# ==================== +# PANEL +dataStorage: + kind: panel.form + name: dataStorage + label: Data Storage + footer: false + method: POST + action: /xapi/siteConfig/batch + contentType: json + load: ?? XNAT.data.siteConfig + refresh: /xapi/siteConfig + contents: + + archivePath: + kind: panel.input.text + name: archivePath + label: Archive Location + size: 50 + value: '' + validation: required path + + prearchivePath: + kind: panel.input.text + name: prearchivePath + label: Pre-archive Location + size: 50 + value: '' + validation: required path + + cachePath: + kind: panel.input.text + name: cachePath + label: Cache Location + size: 50 + value: '' + validation: required path + + buildPath: + kind: panel.input.text + name: buildPath + label: Build Location + size: 50 + value: '' + validation: required path + + ftpPath: + kind: panel.input.text + name: ftpPath + label: FTP Location + size: 50 + value: '' + validation: required path + + pipelinePath: + kind: panel.input.text + name: pipelinePath + label: Pipeline Installation Location + size: 50 + value: '' + validation: required path + +# ==================== +# PANEL +smtpServer: + kind: panel.form + name: smtpServer + label: SMTP Server Settings + footer: false + method: POST + action: /xapi/siteConfig/smtpServer + contentType: json + load: ?? XNAT.data.siteConfig.smtpServer + refresh: /xapi/siteConfig/smtpServer + contents: + + host: + kind: panel.input.text + name: host + label: Host + #value: "?? XNAT:data:siteConfig:smtpServer:host" + placeholder: localhost + validation: required + + port: + kind: panel.input.number + name: port + label: Port + #value: "?? XNAT:data:siteConfig:smtpServer:port" + placeholder: 25 + validation: required number + + username: + kind: panel.input.text + name: username + label: Username + #value: "?? XNAT:data:siteConfig:smtpServer:username" + + password: + kind: panel.input.password + name: password + label: Password + #value: "?? XNAT:data:siteConfig:smtpServer:password" + + protocol: + kind: panel.input.text + name: protocol + label: Protocol + #value: "?? XNAT:data:siteConfig:smtpServer:protocol" + + mailServerProperties: + kind: panel.subhead + text: Mail Server Settings + + smtpAuth: + kind: panel.input.checkbox + name: mail.smtp.auth + label: SMTP Auth? + #value: "?? XNAT:data:siteConfig:smtpServer:mail.smtp.auth" + + smtpStartTls: + kind: panel.input.checkbox + name: mail.smtp.starttls.enable + label: Smart TLS? + #value: "?? XNAT:data:siteConfig:smtpServer:mail.smtp.starttls.enable" + + smtpSSLTrust: + kind: panel.input.text + name: mail.smtp.ssl.trust + label: SSL Trust + #value: "?? XNAT:data:siteConfig:smtpServer:mail.smtp.ssl.trust" + + + +################################################# +#### Root Site Setup Spawner Config Object #### +################################################# +setupPage: + kind: app.siteSetup.form + name: setupPage + label: XNAT Initial Setup + contents: + ${setupMessage} + ${siteInfo} + ${dataStorage} + ${smtpServer} diff --git a/src/main/webapp/PlexiViewerSpec.xml b/src/main/webapp/PlexiViewerSpec.xml deleted file mode 100644 index aca96331fdf79eb8feb4506e5179e3247555a87e..0000000000000000000000000000000000000000 --- a/src/main/webapp/PlexiViewerSpec.xml +++ /dev/null @@ -1,159 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - ~ D:/Development/XNAT/1.6/xnat_builder_1_6dev/plugin-resources/project-skeletons/xnat/PlexiViewerSpec.xml - ~ XNAT http://www.xnat.org - ~ Copyright (c) 2014, Washington University School of Medicine - ~ All Rights Reserved - ~ - ~ Released under the Simplified BSD. - ~ - ~ Last modified 2/7/14 12:19 PM - --> -<Viewer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="/var/lib/tomcat7/webapps/xnat17/schemas/xdat/PlexiViewer.xsd"> - <PlexiViewer sessionType="PLEXI_DEFAULT"> - <DefaultLoResType>8bit</DefaultLoResType> - <CacheLocation>/data/xnat17/cache</CacheLocation> - <Layout name="tal_111" voxelSize="1"> - <Coordinates originX="88" originY="84" originZ="75"/> - </Layout> - <Layout name="tal_222" voxelSize="2"> - <Coordinates originX="63" originY="63" originZ="34"/> - </Layout> - <Layout name="tal_333" voxelSize="3"> - <Coordinates originX="24" originY="29" originZ="20"/> - </Layout> - <Layout name="native" voxelSize="1"> - <Coordinates originX="0" originY="0" originZ="0"/> - </Layout> - <ViewableItem type="MPRAGE"> - <SchemaLink element="xnat:imageScanData.type" value="MPRAGE"/> - <UserInterface selectionPriority="0" displayText="MPRAGE"> - <LinkedDropDown viewableItemType="MPRAGE_RAW"/> - <LinkedDropDown viewableItemType="SUBJ"/> - <LinkedDropDown viewableItemType="GFC"/> - <LinkedDropDown viewableItemType="MASKED"/> - <!--<LinkedDropDown viewableItemType="FSEG"/> --> - </UserInterface> - </ViewableItem> - <ViewableItem type="MPRAGE_RAW" imageViewerClassName="org.nrg.plexiViewer.lite.viewer.MR.MRImage"> - <UserInterface displayText="Raw" allowedToChooseID="true"/> - <Thumbnail format="GIF" converterClassName="org.nrg.plexiViewer.converter.CNLThumbnailConverter"> - <Slice number="79" orientation="transverse"/> - <Slice number="80" orientation="sagittal"/> - <Slice number="99" orientation="coronal"/> - </Thumbnail> - <Lo-Res type="8bit" converterClassName="org.nrg.plexiViewer.converter.DefaultConverter" format="ANALYZE 7.5"> - <MontageView scale="0.6"> - <transverse start_slice="60" end_slice="180" slice_spacing="8"/> - <sagittal start_slice="35" end_slice="125" slice_spacing="5"/> - <coronal start_slice="60" end_slice="180" slice_spacing="8"/> - </MontageView> - </Lo-Res> - <Hi-Res format="DICOM"> - <Layer element="xnat:imageScanData.file" value="MPRAGE_RAW" num="0"/> - <LayoutRef name="native"/> - <MontageView scale="0.6"> - <transverse start_slice="60" end_slice="180" slice_spacing="8"/> - <sagittal start_slice="35" end_slice="125" slice_spacing="5"/> - <coronal start_slice="60" end_slice="180" slice_spacing="8"/> - </MontageView> - </Hi-Res> - </ViewableItem> - <ViewableItem type="GFC" imageViewerClassName="org.nrg.plexiViewer.lite.viewer.MR.MRImage"> - <UserInterface displayText="Atlas Registered"/> - <Thumbnail format="GIF" converterClassName="org.nrg.plexiViewer.converter.CNLThumbnailConverter"> - <Slice number="79" orientation="transverse"/> - <Slice number="80" orientation="sagittal"/> - <Slice number="99" orientation="coronal"/> - </Thumbnail> - <Lo-Res type="8bit" converterClassName="org.nrg.plexiViewer.converter.DefaultConverter" format="ANALYZE 7.5"> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="35" end_slice="145" slice_spacing="5"/> - <coronal start_slice="30" end_slice="165" slice_spacing="5"/> - </MontageView> - </Lo-Res> - <Hi-Res format="ANALYZE 7.5"> - <Layer element="xnat:reconstructedImageData.out.file" value="T88" num="0"/> - <LayoutRef name="tal_111"/> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="35" end_slice="145" slice_spacing="5"/> - <coronal start_slice="30" end_slice="165" slice_spacing="5"/> - </MontageView> - </Hi-Res> - </ViewableItem> - <ViewableItem type="MASKED" imageViewerClassName="org.nrg.plexiViewer.lite.viewer.MR.MRImage"> - <UserInterface displayText="Masked Atlas Reg."/> - <Thumbnail format="GIF" converterClassName="org.nrg.plexiViewer.converter.CNLThumbnailConverter"> - <Slice number="79" orientation="transverse"/> - <Slice number="80" orientation="sagittal"/> - <Slice number="99" orientation="coronal"/> - </Thumbnail> - <Lo-Res type="8bit" converterClassName="org.nrg.plexiViewer.converter.DefaultConverter" format="ANALYZE 7.5"> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="30" end_slice="140" slice_spacing="5"/> - <coronal start_slice="80" end_slice="190" slice_spacing="5"/> - </MontageView> - </Lo-Res> - <Hi-Res format="ANALYZE 7.5"> - <Layer element="xnat:reconstructedImageData.out.file" value="MASKED" num="0"/> - <LayoutRef name="tal_111"/> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="30" end_slice="140" slice_spacing="5"/> - <coronal start_slice="80" end_slice="190" slice_spacing="5"/> - </MontageView> - </Hi-Res> - </ViewableItem> - <ViewableItem type="SUBJ" imageViewerClassName="org.nrg.plexiViewer.lite.viewer.MR.MRImage"> - <UserInterface displayText="Averaged"/> - <Thumbnail format="GIF" converterClassName="org.nrg.plexiViewer.converter.CNLThumbnailConverter"> - <Slice number="79" orientation="transverse"/> - <Slice number="80" orientation="sagittal"/> - <Slice number="99" orientation="coronal"/> - </Thumbnail> - <Lo-Res type="8bit" converterClassName="org.nrg.plexiViewer.converter.DefaultConverter" format="ANALYZE 7.5"> - <MontageView scale="0.6"> - <transverse start_slice="60" end_slice="180" slice_spacing="8"/> - <sagittal start_slice="35" end_slice="125" slice_spacing="5"/> - <coronal start_slice="60" end_slice="180" slice_spacing="8"/> - </MontageView> - </Lo-Res> - <Hi-Res format="ANALYZE 7.5"> - <Layer element="xnat:reconstructedImageData.out.file" value="SUBJ" num="0"/> - <LayoutRef name="native"/> - <MontageView scale="0.6"> - <transverse start_slice="70" end_slice="180" slice_spacing="8"/> - <sagittal start_slice="35" end_slice="145" slice_spacing="5"/> - <coronal start_slice="70" end_slice="180" slice_spacing="8"/> - </MontageView> - </Hi-Res> - </ViewableItem> - <!-- <ViewableItem type="FSEG" imageViewerClassName="org.nrg.plexiViewer.lite.viewer.MR.MRImage"> - <UserInterface displayText="Gray/White Segmented"/> - <Thumbnail format="GIF" converterClassName="org.nrg.plexiViewer.converter.CNLThumbnailConverter"> - <Slice number="79" orientation="transverse"/> - <Slice number="80" orientation="sagittal"/> - <Slice number="99" orientation="coronal"/> - </Thumbnail> - <Lo-Res type="8bit" converterClassName="org.nrg.plexiViewer.converter.DefaultConverter" format="ANALYZE 7.5"> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="35" end_slice="145" slice_spacing="5"/> - <coronal start_slice="30" end_slice="165" slice_spacing="5"/> - </MontageView> - </Lo-Res> - <Hi-Res format="ANALYZE 7.5"> - <Layer element="xnat:imageAssessorData.out.file" value="FSEG" num="0"/> - <LayoutRef name="tal_111"/> - <MontageView scale="0.65"> - <transverse start_slice="30" end_slice="140" slice_spacing="5"/> - <sagittal start_slice="35" end_slice="145" slice_spacing="5"/> - <coronal start_slice="30" end_slice="165" slice_spacing="5"/> - </MontageView> - </Hi-Res> - </ViewableItem> --> - </PlexiViewer> -</Viewer> diff --git a/src/main/webapp/WEB-INF/tags/page/init.tag b/src/main/webapp/WEB-INF/tags/page/init.tag index 69236762c8603a26dee59a63b544d2ef5c32b920..e1509914c52954f2cde57c82e820379ffb7d37f3 100755 --- a/src/main/webapp/WEB-INF/tags/page/init.tag +++ b/src/main/webapp/WEB-INF/tags/page/init.tag @@ -16,7 +16,7 @@ <%-- REDIRECT IF NOT LOGGED IN (username will be '-') --%> <c:if test="${username == '-'}"> - <c:redirect url="/?timeout=true"/> + <c:redirect url="/app/template/Login.vm"/> </c:if> <sec:authorize access="hasAnyRole('Administrator', 'administrator', 'Admin', 'admin', 'ADMIN')"> diff --git a/src/main/webapp/applet/DicomEdit-4.0.0.jar.pack.gz b/src/main/webapp/applet/DicomEdit-4.0.0.jar.pack.gz deleted file mode 100644 index f0cf29f95e82b657f0310e2f3eb63fe00aedcc2e..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/DicomEdit-4.0.0.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/DicomEdit-4.0.0.jar b/src/main/webapp/applet/DicomEdit__V4.0.0.jar similarity index 78% rename from src/main/webapp/applet/DicomEdit-4.0.0.jar rename to src/main/webapp/applet/DicomEdit__V4.0.0.jar index d7da29fdfdd96a518f7c07ec0dedacf7e99ab723..8aa57677e1d20d98648302a3a2b55b5442c57034 100644 Binary files a/src/main/webapp/applet/DicomEdit-4.0.0.jar and b/src/main/webapp/applet/DicomEdit__V4.0.0.jar differ diff --git a/src/main/webapp/applet/DicomEdit__V4.0.0.jar.pack.gz b/src/main/webapp/applet/DicomEdit__V4.0.0.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..cac5f0864e53415c80d78453027970d7d48123d3 Binary files /dev/null and b/src/main/webapp/applet/DicomEdit__V4.0.0.jar.pack.gz differ diff --git a/src/main/webapp/applet/DicomUtils-1.3.1.jar.pack.gz b/src/main/webapp/applet/DicomUtils-1.3.1.jar.pack.gz deleted file mode 100644 index dca0041e7bcfb9a29070ae85e485f9ffb649216b..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/DicomUtils-1.3.1.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/DicomUtils-1.3.1.jar b/src/main/webapp/applet/DicomUtils__V1.3.1.jar similarity index 59% rename from src/main/webapp/applet/DicomUtils-1.3.1.jar rename to src/main/webapp/applet/DicomUtils__V1.3.1.jar index fce4e019d19220575efd3400922c808139ee95b5..f5265c2488081fa7a20f289983cae2fef1e307f2 100644 Binary files a/src/main/webapp/applet/DicomUtils-1.3.1.jar and b/src/main/webapp/applet/DicomUtils__V1.3.1.jar differ diff --git a/src/main/webapp/applet/DicomUtils__V1.3.1.jar.pack.gz b/src/main/webapp/applet/DicomUtils__V1.3.1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..347763787da54469e90983510c1bb5c265181cc0 Binary files /dev/null and b/src/main/webapp/applet/DicomUtils__V1.3.1.jar.pack.gz differ diff --git a/src/main/webapp/applet/UploadAssistant-1.6.5.jar b/src/main/webapp/applet/UploadAssistant-1.6.5.jar deleted file mode 100644 index fe463abbc3288b699ccfb6bf24511292ef613fcb..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/UploadAssistant-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/UploadAssistant-1.6.5.jar.pack.gz b/src/main/webapp/applet/UploadAssistant-1.6.5.jar.pack.gz deleted file mode 100644 index 88470846f4c8fe4d5ab710cff71283ed18eeb669..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/UploadAssistant-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/antlr-runtime-3.5.2.jar.pack.gz b/src/main/webapp/applet/antlr-runtime-3.5.2.jar.pack.gz deleted file mode 100644 index 22430774b66b6f9f4ed5f89fa037582a2198dbf5..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/antlr-runtime-3.5.2.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/antlr-runtime-3.5.2.jar b/src/main/webapp/applet/antlr-runtime__V3.5.2.jar similarity index 80% rename from src/main/webapp/applet/antlr-runtime-3.5.2.jar rename to src/main/webapp/applet/antlr-runtime__V3.5.2.jar index ea0fc1f115ac206ec21c33792c013080dc0c86db..fcd1363c86a0691b656fdd5600cc47fbdf941325 100644 Binary files a/src/main/webapp/applet/antlr-runtime-3.5.2.jar and b/src/main/webapp/applet/antlr-runtime__V3.5.2.jar differ diff --git a/src/main/webapp/applet/antlr-runtime__V3.5.2.jar.pack.gz b/src/main/webapp/applet/antlr-runtime__V3.5.2.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..1531f11f508ca453e9277a92a305d33039021144 Binary files /dev/null and b/src/main/webapp/applet/antlr-runtime__V3.5.2.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-codec-1.5.jar b/src/main/webapp/applet/commons-codec-1.5.jar deleted file mode 100644 index f68e7eedcf6203760d9956f5c2722c5216237228..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/commons-codec-1.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/commons-codec-1.5.jar.pack.gz b/src/main/webapp/applet/commons-codec-1.5.jar.pack.gz deleted file mode 100644 index b793b87f840fb7967bbef34fe4ddaf32bd1deb4a..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/commons-codec-1.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/commons-codec__V1.10.jar b/src/main/webapp/applet/commons-codec__V1.10.jar new file mode 100644 index 0000000000000000000000000000000000000000..eac7f9f87bf58d902fcba5a0a234569a82618568 Binary files /dev/null and b/src/main/webapp/applet/commons-codec__V1.10.jar differ diff --git a/src/main/webapp/applet/commons-codec__V1.10.jar.pack.gz b/src/main/webapp/applet/commons-codec__V1.10.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..14b7e077a8ed26ca0beefbcb34a9788bade52147 Binary files /dev/null and b/src/main/webapp/applet/commons-codec__V1.10.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-collections__V3.2.1.jar b/src/main/webapp/applet/commons-collections__V3.2.1.jar new file mode 100644 index 0000000000000000000000000000000000000000..71621eef4aee695ec4191e7798d11016a13ead29 Binary files /dev/null and b/src/main/webapp/applet/commons-collections__V3.2.1.jar differ diff --git a/src/main/webapp/applet/commons-collections__V3.2.1.jar.pack.gz b/src/main/webapp/applet/commons-collections__V3.2.1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..86100402ec1ba3d6e4837e0044cae7369a25637a Binary files /dev/null and b/src/main/webapp/applet/commons-collections__V3.2.1.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-configuration__V1.5.jar b/src/main/webapp/applet/commons-configuration__V1.5.jar new file mode 100644 index 0000000000000000000000000000000000000000..83324108d1388e63a54e150ecd03ae0ca9d72ac6 Binary files /dev/null and b/src/main/webapp/applet/commons-configuration__V1.5.jar differ diff --git a/src/main/webapp/applet/commons-configuration__V1.5.jar.pack.gz b/src/main/webapp/applet/commons-configuration__V1.5.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..47a78c1e6eae9ebbc698cfebc5e4b3e910526928 Binary files /dev/null and b/src/main/webapp/applet/commons-configuration__V1.5.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-lang3__V3.4.jar b/src/main/webapp/applet/commons-lang3__V3.4.jar new file mode 100644 index 0000000000000000000000000000000000000000..968552c1f20b950d2a65d138255992af4afdc5df Binary files /dev/null and b/src/main/webapp/applet/commons-lang3__V3.4.jar differ diff --git a/src/main/webapp/applet/commons-lang3__V3.4.jar.pack.gz b/src/main/webapp/applet/commons-lang3__V3.4.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..030d74fe32a78577f01709b2e54a136647afc8ef Binary files /dev/null and b/src/main/webapp/applet/commons-lang3__V3.4.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-lang-2.6.jar b/src/main/webapp/applet/commons-lang__V2.6.jar similarity index 87% rename from src/main/webapp/applet/commons-lang-2.6.jar rename to src/main/webapp/applet/commons-lang__V2.6.jar index d99834b694eaf4a37fe634d3f6ff1911f5523c5c..95af5e644d49b5157ff36b2895bcf8765f6dd255 100644 Binary files a/src/main/webapp/applet/commons-lang-2.6.jar and b/src/main/webapp/applet/commons-lang__V2.6.jar differ diff --git a/src/main/webapp/applet/commons-lang-2.6.jar.pack.gz b/src/main/webapp/applet/commons-lang__V2.6.jar.pack.gz similarity index 75% rename from src/main/webapp/applet/commons-lang-2.6.jar.pack.gz rename to src/main/webapp/applet/commons-lang__V2.6.jar.pack.gz index 32208c6cd99b483f09bf9f327ec08b65c48432c6..e170a91e0e17c2c3459bd0214beef547da7b5a97 100644 Binary files a/src/main/webapp/applet/commons-lang-2.6.jar.pack.gz and b/src/main/webapp/applet/commons-lang__V2.6.jar.pack.gz differ diff --git a/src/main/webapp/applet/commons-logging__V1.1.1.jar b/src/main/webapp/applet/commons-logging__V1.1.1.jar new file mode 100644 index 0000000000000000000000000000000000000000..c6b727a5af33f1e9cbb232f025c3606e18105482 Binary files /dev/null and b/src/main/webapp/applet/commons-logging__V1.1.1.jar differ diff --git a/src/main/webapp/applet/commons-logging__V1.1.1.jar.pack.gz b/src/main/webapp/applet/commons-logging__V1.1.1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..c2e906f1bc88a09ede870cf1bbf2ec20afbe56d8 Binary files /dev/null and b/src/main/webapp/applet/commons-logging__V1.1.1.jar.pack.gz differ diff --git a/src/main/webapp/applet/config-1.6.5.jar b/src/main/webapp/applet/config-1.6.5.jar deleted file mode 100644 index 82dd72fb791e421d6b9304f5084c8b38124ff6ce..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/config-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/config-1.6.5.jar.pack.gz b/src/main/webapp/applet/config-1.6.5.jar.pack.gz deleted file mode 100644 index 11cd18e393035d44f342cdedb51ffdedc74ddaee..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/config-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..3f3c79da73c5d4ca87e19495ab343fef074592fc Binary files /dev/null and b/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..c630228e15b8ba64847ea887e2edfab46684c1a8 Binary files /dev/null and b/src/main/webapp/applet/config__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..d0736a1bf585ae4e20396f8578114d528b82d614 Binary files /dev/null and b/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..4da940e5d9aa6c7d704ab456d67f484e7556be3d Binary files /dev/null and b/src/main/webapp/applet/core__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/dcm4che-core-2.0.25.jar.pack.gz b/src/main/webapp/applet/dcm4che-core-2.0.25.jar.pack.gz deleted file mode 100644 index e252acb1d98a1c5c77529250f9c834b4e0ac9725..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/dcm4che-core-2.0.25.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/dcm4che-core-2.0.25.jar b/src/main/webapp/applet/dcm4che-core__V2.0.25.jar similarity index 87% rename from src/main/webapp/applet/dcm4che-core-2.0.25.jar rename to src/main/webapp/applet/dcm4che-core__V2.0.25.jar index 8f1a4658f203f0321fcc205dbbdd1546e333305a..ad14d05ee3cfb570b18210859d6bbc189dbb2b35 100644 Binary files a/src/main/webapp/applet/dcm4che-core-2.0.25.jar and b/src/main/webapp/applet/dcm4che-core__V2.0.25.jar differ diff --git a/src/main/webapp/applet/dcm4che-core__V2.0.25.jar.pack.gz b/src/main/webapp/applet/dcm4che-core__V2.0.25.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..e213557b6de7b3b7b85c8f9086128f31c5c32321 Binary files /dev/null and b/src/main/webapp/applet/dcm4che-core__V2.0.25.jar.pack.gz differ diff --git a/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar b/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar new file mode 100644 index 0000000000000000000000000000000000000000..1fa1ef955008b43fd1ce134da8125415baaa3139 Binary files /dev/null and b/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar differ diff --git a/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar.pack.gz b/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..f04aa5e82cd2affd15cc1c57c535498ad4a209a6 Binary files /dev/null and b/src/main/webapp/applet/dicom-xnat-sop__V1.7.0-20160210.212402-3.jar.pack.gz differ diff --git a/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar b/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar new file mode 100644 index 0000000000000000000000000000000000000000..eca7d3030d7d96201eb11dc5616e62047ecf3716 Binary files /dev/null and b/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar differ diff --git a/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar.pack.gz b/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..b2df7f7f0f6a69d597f11483b76c0b06c19666e1 Binary files /dev/null and b/src/main/webapp/applet/dicom-xnat-util__V1.7.0-20160210.212409-3.jar.pack.gz differ diff --git a/src/main/webapp/applet/dicomtools-1.6.5.jar b/src/main/webapp/applet/dicomtools-1.6.5.jar deleted file mode 100644 index 35ab45a5d7557e59e62374d73efad35536c0eef6..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/dicomtools-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/dicomtools-1.6.5.jar.pack.gz b/src/main/webapp/applet/dicomtools-1.6.5.jar.pack.gz deleted file mode 100644 index 66011bc82ef062acbab2a63dc6bdb894c004fda4..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/dicomtools-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..52293c26addf2d840de6323d86862dead80d6c48 Binary files /dev/null and b/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..2edc9ddc66788cca5a39712b330607bb80045b5e Binary files /dev/null and b/src/main/webapp/applet/dicomtools__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/ecat-edit-0.2.0.jar.pack.gz b/src/main/webapp/applet/ecat-edit-0.2.0.jar.pack.gz deleted file mode 100644 index d8ee69e38ab548faa0bcac1875babf9b5acbf1f4..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/ecat-edit-0.2.0.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/ecat-edit-0.2.0.jar b/src/main/webapp/applet/ecat-edit__V0.2.0.jar similarity index 59% rename from src/main/webapp/applet/ecat-edit-0.2.0.jar rename to src/main/webapp/applet/ecat-edit__V0.2.0.jar index 01aa043cf9f9df1be6a7aec2316a675e9bef230f..e29eb204612f9312dd154d138cb681a83708b5c4 100644 Binary files a/src/main/webapp/applet/ecat-edit-0.2.0.jar and b/src/main/webapp/applet/ecat-edit__V0.2.0.jar differ diff --git a/src/main/webapp/applet/ecat-edit__V0.2.0.jar.pack.gz b/src/main/webapp/applet/ecat-edit__V0.2.0.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..dcdf2d255c393e61e2d78a2ae018759051becfb3 Binary files /dev/null and b/src/main/webapp/applet/ecat-edit__V0.2.0.jar.pack.gz differ diff --git a/src/main/webapp/applet/ecat-io-0.1.0.jar b/src/main/webapp/applet/ecat-io-0.1.0.jar deleted file mode 100644 index 3c26a6eeba2894bff87426dcb4bc1c9f1f676a27..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/ecat-io-0.1.0.jar and /dev/null differ diff --git a/src/main/webapp/applet/ecat-io-0.1.0.jar.pack.gz b/src/main/webapp/applet/ecat-io-0.1.0.jar.pack.gz deleted file mode 100644 index 53c90c5c3239731b960b89fe746c0d48cc3483d6..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/ecat-io-0.1.0.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/ecat-io__V0.1.0.jar b/src/main/webapp/applet/ecat-io__V0.1.0.jar new file mode 100644 index 0000000000000000000000000000000000000000..8bcbdfe56c077bfdc5f208ff6622c5322c2169a9 Binary files /dev/null and b/src/main/webapp/applet/ecat-io__V0.1.0.jar differ diff --git a/src/main/webapp/applet/ecat-io__V0.1.0.jar.pack.gz b/src/main/webapp/applet/ecat-io__V0.1.0.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..cf6ca30928195a9431bb81b0d5f8c404892ab6c1 Binary files /dev/null and b/src/main/webapp/applet/ecat-io__V0.1.0.jar.pack.gz differ diff --git a/src/main/webapp/applet/file-downloader-1.6.5.jar b/src/main/webapp/applet/file-downloader-1.6.5.jar deleted file mode 100644 index c21164ec335cd9e113d7bc847af31a0ac980a2fa..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/file-downloader-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/file-downloader-1.6.5.jar.pack.gz b/src/main/webapp/applet/file-downloader-1.6.5.jar.pack.gz deleted file mode 100644 index 40e8cdf6f66eea88993e9b8a151e29ae2fcc45a3..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/file-downloader-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..7df9c13b3af82555ff413684d4c789a64a3e7b52 Binary files /dev/null and b/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..38b0e27798bd2e4000d78ccd247f89202496e74b Binary files /dev/null and b/src/main/webapp/applet/file-downloader__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/framework-1.6.5.jar b/src/main/webapp/applet/framework-1.6.5.jar deleted file mode 100644 index 7f8a095f1cd40fdee93174f8fc538c41c275ad0a..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/framework-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/framework-1.6.5.jar.pack.gz b/src/main/webapp/applet/framework-1.6.5.jar.pack.gz deleted file mode 100644 index 6e0dd6efbd312575968ec564a2c05fcd92dff042..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/framework-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..30d88677702d8dd6cdf85a830c2e3b56de5bd4ac Binary files /dev/null and b/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..c2c8c214e28cff8b8c0a02496aa5f608e5f82815 Binary files /dev/null and b/src/main/webapp/applet/framework__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/guava-18.0.jar b/src/main/webapp/applet/guava-18.0.jar deleted file mode 100644 index 80850781fa190d577689d79f05c65a4d3c015b8f..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/guava-18.0.jar and /dev/null differ diff --git a/src/main/webapp/applet/guava-18.0.jar.pack.gz b/src/main/webapp/applet/guava-18.0.jar.pack.gz deleted file mode 100644 index 69f8b4637ebe45ee5bbfa176c9080e737d002090..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/guava-18.0.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/guava__V19.0.jar b/src/main/webapp/applet/guava__V19.0.jar new file mode 100644 index 0000000000000000000000000000000000000000..f64ec1a89123b1ce3b5feb299d121cb293faa534 Binary files /dev/null and b/src/main/webapp/applet/guava__V19.0.jar differ diff --git a/src/main/webapp/applet/guava__V19.0.jar.pack.gz b/src/main/webapp/applet/guava__V19.0.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..d694ced1a6e74171538778a7fd5451c81ec0e36a Binary files /dev/null and b/src/main/webapp/applet/guava__V19.0.jar.pack.gz differ diff --git a/src/main/webapp/applet/ij-1.49t.jar b/src/main/webapp/applet/ij-1.49t.jar deleted file mode 100644 index 52dc5bb618ffca871e5d10c209ce759a617cff60..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/ij-1.49t.jar and /dev/null differ diff --git a/src/main/webapp/applet/ij-1.49t.jar.pack.gz b/src/main/webapp/applet/ij-1.49t.jar.pack.gz deleted file mode 100644 index daa65ba2a37082ce304d4fce927ea2b6b812bf4f..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/ij-1.49t.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/jackson-annotations-2.5.2.jar b/src/main/webapp/applet/jackson-annotations-2.5.2.jar deleted file mode 100644 index 56fd9f57699fd9b1045fff26183d1a9a82511161..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-annotations-2.5.2.jar and /dev/null differ diff --git a/src/main/webapp/applet/jackson-annotations-2.5.2.jar.pack.gz b/src/main/webapp/applet/jackson-annotations-2.5.2.jar.pack.gz deleted file mode 100644 index c38c156213c6b634b80fab2753f672f52f9bf0ec..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-annotations-2.5.2.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/jackson-annotations__V2.6.5.jar b/src/main/webapp/applet/jackson-annotations__V2.6.5.jar new file mode 100644 index 0000000000000000000000000000000000000000..328559613afd8de5c6c8461afccf807b48e8bdcf Binary files /dev/null and b/src/main/webapp/applet/jackson-annotations__V2.6.5.jar differ diff --git a/src/main/webapp/applet/jackson-annotations__V2.6.5.jar.pack.gz b/src/main/webapp/applet/jackson-annotations__V2.6.5.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..a0a10991fd115e8b17ec62528a2e3ff27a2ffeaa Binary files /dev/null and b/src/main/webapp/applet/jackson-annotations__V2.6.5.jar.pack.gz differ diff --git a/src/main/webapp/applet/jackson-core-2.5.2.jar b/src/main/webapp/applet/jackson-core-2.5.2.jar deleted file mode 100644 index b1d666dd142e190d619366ea60e009afbcc5791a..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-core-2.5.2.jar and /dev/null differ diff --git a/src/main/webapp/applet/jackson-core-2.5.2.jar.pack.gz b/src/main/webapp/applet/jackson-core-2.5.2.jar.pack.gz deleted file mode 100644 index 369ab6783d1a96fcd98109d465b9b3781cbe9249..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-core-2.5.2.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/jackson-core__V2.6.5.jar b/src/main/webapp/applet/jackson-core__V2.6.5.jar new file mode 100644 index 0000000000000000000000000000000000000000..ffae7556aa1ea8c396ee655692b68312b8ddadff Binary files /dev/null and b/src/main/webapp/applet/jackson-core__V2.6.5.jar differ diff --git a/src/main/webapp/applet/jackson-core__V2.6.5.jar.pack.gz b/src/main/webapp/applet/jackson-core__V2.6.5.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..595812cdfdc6638ff9f78d7775fc41d33c2c1cea Binary files /dev/null and b/src/main/webapp/applet/jackson-core__V2.6.5.jar.pack.gz differ diff --git a/src/main/webapp/applet/jackson-databind-2.5.2.jar b/src/main/webapp/applet/jackson-databind-2.5.2.jar deleted file mode 100644 index 0ba51b9a60fa0d6014bb9890ca68a1c3a880f554..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-databind-2.5.2.jar and /dev/null differ diff --git a/src/main/webapp/applet/jackson-databind-2.5.2.jar.pack.gz b/src/main/webapp/applet/jackson-databind-2.5.2.jar.pack.gz deleted file mode 100644 index 70dec3aae93de2c07fa8ca356e2b5e5fb83768e9..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jackson-databind-2.5.2.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/jackson-databind__V2.6.5.jar b/src/main/webapp/applet/jackson-databind__V2.6.5.jar new file mode 100644 index 0000000000000000000000000000000000000000..7aca76b1b79719c57aabbf1aff656324be257293 Binary files /dev/null and b/src/main/webapp/applet/jackson-databind__V2.6.5.jar differ diff --git a/src/main/webapp/applet/jackson-databind__V2.6.5.jar.pack.gz b/src/main/webapp/applet/jackson-databind__V2.6.5.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..fdbe3eb04d5f4cfbecb4c25d5addfe5e039cca2a Binary files /dev/null and b/src/main/webapp/applet/jackson-databind__V2.6.5.jar.pack.gz differ diff --git a/src/main/webapp/applet/java-uuid-generator-3.1.3.jar.pack.gz b/src/main/webapp/applet/java-uuid-generator-3.1.3.jar.pack.gz deleted file mode 100644 index b3878afd23367f7a8795b2d4d8d9eb9663e837e0..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/java-uuid-generator-3.1.3.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/java-uuid-generator-3.1.3.jar b/src/main/webapp/applet/java-uuid-generator__V3.1.3.jar similarity index 71% rename from src/main/webapp/applet/java-uuid-generator-3.1.3.jar rename to src/main/webapp/applet/java-uuid-generator__V3.1.3.jar index 26a1f359506fa499723742f91bfacf63cdf851c4..a80e3386280c5e043e34542533e51756711c7e48 100644 Binary files a/src/main/webapp/applet/java-uuid-generator-3.1.3.jar and b/src/main/webapp/applet/java-uuid-generator__V3.1.3.jar differ diff --git a/src/main/webapp/applet/java-uuid-generator__V3.1.3.jar.pack.gz b/src/main/webapp/applet/java-uuid-generator__V3.1.3.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..80738a88f4c89fa11e9ab59bafba00daeac4fabc Binary files /dev/null and b/src/main/webapp/applet/java-uuid-generator__V3.1.3.jar.pack.gz differ diff --git a/src/main/webapp/applet/javax.inject-1.jar b/src/main/webapp/applet/javax.inject-1.jar deleted file mode 100644 index 4888f446f44729afc6a924f13f8b221f1eb36322..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/javax.inject-1.jar and /dev/null differ diff --git a/src/main/webapp/applet/javax.inject-1.jar.pack.gz b/src/main/webapp/applet/javax.inject-1.jar.pack.gz deleted file mode 100644 index 4c9159087bd28ea9adb54759e1fabbdc2dd9fa50..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/javax.inject-1.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/javax.inject__V1.jar b/src/main/webapp/applet/javax.inject__V1.jar new file mode 100644 index 0000000000000000000000000000000000000000..4d43e972a9030841ee650690ce70ca5891052ff1 Binary files /dev/null and b/src/main/webapp/applet/javax.inject__V1.jar differ diff --git a/src/main/webapp/applet/javax.inject__V1.jar.pack.gz b/src/main/webapp/applet/javax.inject__V1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..57608495dea19daa6ae3a7ca290cbe3b275a12a9 Binary files /dev/null and b/src/main/webapp/applet/javax.inject__V1.jar.pack.gz differ diff --git a/src/main/webapp/applet/jcalendar-1.4.jar.pack.gz b/src/main/webapp/applet/jcalendar-1.4.jar.pack.gz deleted file mode 100644 index 5a0655a83200af58e457138d3e8cf47fc07a6e95..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/jcalendar-1.4.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/jcalendar-1.4.jar b/src/main/webapp/applet/jcalendar__V1.4.jar similarity index 56% rename from src/main/webapp/applet/jcalendar-1.4.jar rename to src/main/webapp/applet/jcalendar__V1.4.jar index f3ef0e16d529c95d34bbc3fa45ab9ce62131015b..e5529942351a273aec70145e6688a633029fa235 100644 Binary files a/src/main/webapp/applet/jcalendar-1.4.jar and b/src/main/webapp/applet/jcalendar__V1.4.jar differ diff --git a/src/main/webapp/applet/jcalendar__V1.4.jar.pack.gz b/src/main/webapp/applet/jcalendar__V1.4.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..6ad0c872f0cc1d59e9bee745e0feb6fe8726e083 Binary files /dev/null and b/src/main/webapp/applet/jcalendar__V1.4.jar.pack.gz differ diff --git a/src/main/webapp/applet/joda-time-2.1.jar.pack.gz b/src/main/webapp/applet/joda-time-2.1.jar.pack.gz deleted file mode 100644 index 672b1665e14ac678453259f5f57575c89e67195e..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/joda-time-2.1.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/joda-time-2.1.jar b/src/main/webapp/applet/joda-time__V2.1.jar similarity index 73% rename from src/main/webapp/applet/joda-time-2.1.jar rename to src/main/webapp/applet/joda-time__V2.1.jar index ea8fcdd7d16ab67dd12dd9fae76076a0b37732c6..4f23c6635880356717041fbd399eca1e40ab6fdd 100644 Binary files a/src/main/webapp/applet/joda-time-2.1.jar and b/src/main/webapp/applet/joda-time__V2.1.jar differ diff --git a/src/main/webapp/applet/joda-time__V2.1.jar.pack.gz b/src/main/webapp/applet/joda-time__V2.1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..3d5580883ad0c11a583ddd916612398aee68ab94 Binary files /dev/null and b/src/main/webapp/applet/joda-time__V2.1.jar.pack.gz differ diff --git a/src/main/webapp/applet/json-20140107.jar b/src/main/webapp/applet/json-20140107.jar deleted file mode 100644 index 05365060b49bf2c1c615b291b774ed82b60eb979..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/json-20140107.jar and /dev/null differ diff --git a/src/main/webapp/applet/json-20140107.jar.pack.gz b/src/main/webapp/applet/json-20140107.jar.pack.gz deleted file mode 100644 index c3510ed0b4ba4194a3c579ad904cd90139556d08..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/json-20140107.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/json__V20151123.jar b/src/main/webapp/applet/json__V20151123.jar new file mode 100644 index 0000000000000000000000000000000000000000..f8a07f94963d9829d0f3293d938221f594be83c0 Binary files /dev/null and b/src/main/webapp/applet/json__V20151123.jar differ diff --git a/src/main/webapp/applet/json__V20151123.jar.pack.gz b/src/main/webapp/applet/json__V20151123.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..8ecb70b74b0ee9be133512282f8a525d80995f05 Binary files /dev/null and b/src/main/webapp/applet/json__V20151123.jar.pack.gz differ diff --git a/src/main/webapp/applet/log4j-1.2.17.jar.pack.gz b/src/main/webapp/applet/log4j-1.2.17.jar.pack.gz deleted file mode 100644 index e6986cae87700f1407f078c17abfc3fd38cdcaf5..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/log4j-1.2.17.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/log4j-1.2.17.jar b/src/main/webapp/applet/log4j__V1.2.17.jar similarity index 82% rename from src/main/webapp/applet/log4j-1.2.17.jar rename to src/main/webapp/applet/log4j__V1.2.17.jar index 80c36bbaba7f2f13d4dd97f20e3ad41041506178..e1fe607d9927d7a6260257b66f25aec8b18fa581 100644 Binary files a/src/main/webapp/applet/log4j-1.2.17.jar and b/src/main/webapp/applet/log4j__V1.2.17.jar differ diff --git a/src/main/webapp/applet/log4j__V1.2.17.jar.pack.gz b/src/main/webapp/applet/log4j__V1.2.17.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..a4bc1f54d65b4cb307d349ceabca336f87d47846 Binary files /dev/null and b/src/main/webapp/applet/log4j__V1.2.17.jar.pack.gz differ diff --git a/src/main/webapp/applet/nrgutil-2.0.0.jar b/src/main/webapp/applet/nrgutil-2.0.0.jar deleted file mode 100644 index 61123e0fc5e419fd205051ab343ca7b08c09d3e7..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/nrgutil-2.0.0.jar and /dev/null differ diff --git a/src/main/webapp/applet/nrgutil-2.0.0.jar.pack.gz b/src/main/webapp/applet/nrgutil-2.0.0.jar.pack.gz deleted file mode 100644 index 0cee63d0b457f93f8ef8b557d5d20f279dbfe180..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/nrgutil-2.0.0.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/nrgutil__V1.1.0.jar b/src/main/webapp/applet/nrgutil__V1.1.0.jar new file mode 100644 index 0000000000000000000000000000000000000000..2bb66a242f0ca6f21c8abf9ab2b29e4696343681 Binary files /dev/null and b/src/main/webapp/applet/nrgutil__V1.1.0.jar differ diff --git a/src/main/webapp/applet/nrgutil__V1.1.0.jar.pack.gz b/src/main/webapp/applet/nrgutil__V1.1.0.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..8ffa06177378e71b198557b5f88fb02331dc055b Binary files /dev/null and b/src/main/webapp/applet/nrgutil__V1.1.0.jar.pack.gz differ diff --git a/src/main/webapp/applet/plexiviewer-1.6.5.jar b/src/main/webapp/applet/plexiviewer-1.6.5.jar deleted file mode 100644 index 2ff45b15bd143a3df8c9f0414dde6c4f344ef3ca..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/plexiviewer-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/plexiviewer-1.6.5.jar.pack.gz b/src/main/webapp/applet/plexiviewer-1.6.5.jar.pack.gz deleted file mode 100644 index cb55aaade245f31ced8cca302f7bca563ad6d9bd..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/plexiviewer-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/reflections__V0.9.10.jar b/src/main/webapp/applet/reflections__V0.9.10.jar new file mode 100644 index 0000000000000000000000000000000000000000..b4df7fc82f89ef57f203fb6625c741351c9993a0 Binary files /dev/null and b/src/main/webapp/applet/reflections__V0.9.10.jar differ diff --git a/src/main/webapp/applet/reflections__V0.9.10.jar.pack.gz b/src/main/webapp/applet/reflections__V0.9.10.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..7540addd81ce0ab08517f76b070ab997093929d2 Binary files /dev/null and b/src/main/webapp/applet/reflections__V0.9.10.jar.pack.gz differ diff --git a/src/main/webapp/applet/slf4j-api-1.7.7.jar.pack.gz b/src/main/webapp/applet/slf4j-api-1.7.7.jar.pack.gz deleted file mode 100644 index ce2636bbf3155c3a941ae7197a147f55aa93321c..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/slf4j-api-1.7.7.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/slf4j-api-1.7.7.jar b/src/main/webapp/applet/slf4j-api__V1.7.7.jar similarity index 65% rename from src/main/webapp/applet/slf4j-api-1.7.7.jar rename to src/main/webapp/applet/slf4j-api__V1.7.7.jar index c5c4612892e294a844746626197ed470b426868d..a934657518dbe60cd837402f6e765ebe83fb035a 100644 Binary files a/src/main/webapp/applet/slf4j-api-1.7.7.jar and b/src/main/webapp/applet/slf4j-api__V1.7.7.jar differ diff --git a/src/main/webapp/applet/slf4j-api__V1.7.7.jar.pack.gz b/src/main/webapp/applet/slf4j-api__V1.7.7.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..ab6db5d7eaa227ffe8e9113b4af7a36b877ef2a4 Binary files /dev/null and b/src/main/webapp/applet/slf4j-api__V1.7.7.jar.pack.gz differ diff --git a/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar b/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar deleted file mode 100644 index 44725f13aaa1c9cf622f35125fa1d18c82802cef..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar and /dev/null differ diff --git a/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar.pack.gz b/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar.pack.gz deleted file mode 100644 index 787356dad5c376613de3b7ac908e20e35fc3b25f..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/slf4j-log4j12-1.7.7.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar b/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar new file mode 100644 index 0000000000000000000000000000000000000000..f736993e71b5d0c0d9b74a7e1c09f81f8ab02d14 Binary files /dev/null and b/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar differ diff --git a/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar.pack.gz b/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..0ab331040fdf0f026216089ef83df0b6c3a93416 Binary files /dev/null and b/src/main/webapp/applet/slf4j-log4j12__V1.7.7.jar.pack.gz differ diff --git a/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..a6bb3613b56e0a1747a0b4009dfe067ecfcf9c42 Binary files /dev/null and b/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..5fdb05aea14e5a4aafd8c33b61c465a61c8d8b64 Binary files /dev/null and b/src/main/webapp/applet/upload-assistant__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/applet/wizard-1.1.jar.pack.gz b/src/main/webapp/applet/wizard-1.1.jar.pack.gz deleted file mode 100644 index fcf5f0e1b90c59137ea31ab4cde479ffe96e1a75..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/wizard-1.1.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/wizard-1.1.jar b/src/main/webapp/applet/wizard__V1.1.jar similarity index 82% rename from src/main/webapp/applet/wizard-1.1.jar rename to src/main/webapp/applet/wizard__V1.1.jar index 9ab93781af002a16307ade7dc18b7d5e1d0419d9..9bbc078b2f22df1961601757739ff968d120c1ff 100644 Binary files a/src/main/webapp/applet/wizard-1.1.jar and b/src/main/webapp/applet/wizard__V1.1.jar differ diff --git a/src/main/webapp/applet/wizard__V1.1.jar.pack.gz b/src/main/webapp/applet/wizard__V1.1.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..67f37548e017870c18dbe3ed6c8072962b5cb1f6 Binary files /dev/null and b/src/main/webapp/applet/wizard__V1.1.jar.pack.gz differ diff --git a/src/main/webapp/applet/xdat-beans-1.6.5.jar b/src/main/webapp/applet/xdat-beans-1.6.5.jar deleted file mode 100644 index 923281834f06f266311ca274f1ac2a52ee146088..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/xdat-beans-1.6.5.jar and /dev/null differ diff --git a/src/main/webapp/applet/xdat-beans-1.6.5.jar.pack.gz b/src/main/webapp/applet/xdat-beans-1.6.5.jar.pack.gz deleted file mode 100644 index b0a01a241c4d928534c5e9a05c81dd93105dbd24..0000000000000000000000000000000000000000 Binary files a/src/main/webapp/applet/xdat-beans-1.6.5.jar.pack.gz and /dev/null differ diff --git a/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar b/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar new file mode 100644 index 0000000000000000000000000000000000000000..953e80b8ae689cd929382a5d1900cac288925fed Binary files /dev/null and b/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar differ diff --git a/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar.pack.gz b/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar.pack.gz new file mode 100644 index 0000000000000000000000000000000000000000..f4c80e9dad841d0b33bf307ce2a083684f32b580 Binary files /dev/null and b/src/main/webapp/applet/xnat-data-models__V1.7.0-SNAPSHOT.jar.pack.gz differ diff --git a/src/main/webapp/page/admin/fake.jsp b/src/main/webapp/page/admin/fake.jsp index 5d63f24f09323bea4e3e452802c48e86fb0c9e6d..18e16850573a3bd3d634a89b2f828ecfac2c7261 100644 --- a/src/main/webapp/page/admin/fake.jsp +++ b/src/main/webapp/page/admin/fake.jsp @@ -199,7 +199,7 @@ <label class="element-label" for="session-timeout-input">Session Timeout</label> <div class="element-wrapper"> <input name="sessionTimeout" id="session-timeout-input" type="text" size="3" title="Session Timeout"> - <div class="description">Interval for timing out alias tokens. Uses PostgreSQL interval notation: http://www.postgresql.org/docs/9.0/static/functions-datetime.html</div> + <div class="description">Number of minutes of inactivity before users are locked out of the site. This will not affect users that are currently logged in.</div> </div> </div> <div class="panel-element" data-name="sessionTimeoutMessage"> diff --git a/src/main/webapp/page/admin/spawner/content.jsp b/src/main/webapp/page/admin/spawner/content.jsp index a2b46a582709ec3003c4b944406a5f44a06cdb80..e7633ba951fc41bd4bd0821660825308fc886b51 100644 --- a/src/main/webapp/page/admin/spawner/content.jsp +++ b/src/main/webapp/page/admin/spawner/content.jsp @@ -24,7 +24,7 @@ <%--<label class="element-label" for="!?"></label>--%> <%--<div class="element-wrapper">--%> - <table id="spawner-element-list" class="xnat-table alt1 clean" style="width:100%"> + <table id="spawner-element-list" class="xnat-table alt1 clean" style="width:100%;border:none;"> <!-- list of available namespaces will show here --> </table> diff --git a/src/main/webapp/page/admin/spawner/spawner-admin.js b/src/main/webapp/page/admin/spawner/spawner-admin.js index 7645623f608631cbedceec1a0a4d0e504f936c3c..b9556b8ed925c278bc0481c243776e6d86b15152 100644 --- a/src/main/webapp/page/admin/spawner/spawner-admin.js +++ b/src/main/webapp/page/admin/spawner/spawner-admin.js @@ -1,26 +1,26 @@ (function(){ - function showJSON(json){ - return xmodal.message({ - title: 'Site Admin JSON', - maximize: true, - width: '90%', - height: '90%', - content: spawn('pre.json', JSON.stringify(json, null, 2)).outerHTML - }) - } - - spawn('button|type=button', { - html: 'View JSON', - onclick: function(){ - XNAT.xhr.get(XNAT.url.rootUrl('/xapi/spawner/resolve/siteAdmin/adminPage'), function(data){ - showJSON(data); - }); - }, - $: { - appendTo: '#view-json' - } - }); + // function showJSON(json){ + // return xmodal.message({ + // title: 'Site Admin JSON', + // maximize: true, + // width: '90%', + // height: '90%', + // content: spawn('pre.json', JSON.stringify(json, null, 2)).outerHTML + // }) + // } + // + // spawn('button|type=button', { + // html: 'View JSON', + // onclick: function(){ + // XNAT.xhr.get(XNAT.url.rootUrl('/xapi/spawner/resolve/siteAdmin/adminPage'), function(data){ + // showJSON(data); + // }); + // }, + // $: { + // appendTo: '#view-json' + // } + // }); //$('#view-json').click(function(){}); @@ -72,7 +72,7 @@ XNAT.xhr.getJSON({ }] ]]); - var idsMenu = spawn('select#spawner-ns-ids', [['option|value=!', 'Select an Element']]); + var idsMenu = spawn('select.spawner-ns-ids', [['option|value=!', 'Select an Element']]); tds.push(['td', [ @@ -84,7 +84,7 @@ XNAT.xhr.getJSON({ type: 'button', html: 'View Selected Element', onclick: function(){ - var getId = $('#spawner-ns-ids').val(); + var getId = $(idsMenu).val(); if (!getId || getId === '!') { xmodal.message('Select an Element ID'); return false; diff --git a/src/main/webapp/scripts/search/dataTableSearch.js b/src/main/webapp/scripts/search/dataTableSearch.js index ccef3342b157cf3562cbb47bf33be9b26164cd52..c50c2e9dff994460d3f76d038cc2bcb726fa7633 100644 --- a/src/main/webapp/scripts/search/dataTableSearch.js +++ b/src/main/webapp/scripts/search/dataTableSearch.js @@ -676,7 +676,7 @@ function DataTableSearch(_div_table_id,obj,_config,_options){ //insert option menu this.renderOptions=function(obj1,obj2){ this.optionMenu=null; - this.optionMenu=new YAHOO.widget.MenuBar(this.div_table_id +"_options",{hidedelay:750}); + this.optionMenu=new YAHOO.widget.MenuBar(this.div_table_id +"_options",{hidedelay:300, maxheight:200, submenualignment: ["tr","br"]}); this.optionMenu.search=this; this.optionMenu.en=this.initResults.ResultSet.rootElementName; diff --git a/src/main/webapp/scripts/xnat/admin/siteInfo.js b/src/main/webapp/scripts/xnat/admin/siteInfo.js new file mode 100644 index 0000000000000000000000000000000000000000..10c0ede2fe4560605ef96616e12a2cd4e97b9682 --- /dev/null +++ b/src/main/webapp/scripts/xnat/admin/siteInfo.js @@ -0,0 +1,31 @@ +var sdtPage, sdtText; +setTimeout(function(){ + sdtPage = $('#siteDescriptionTypePage'); + sdtText = $('#siteDescriptionTypeText'); + sdtPage.click(changeSiteDescriptionType); + sdtText.click(changeSiteDescriptionType); + changeSiteDescriptionType(XNAT.data.siteConfig.siteDescriptionType); +}, 100); +function changeSiteDescriptionType(eventOrValue){ + var value = eventOrValue; + if(typeof eventOrValue === 'object'){ + if(eventOrValue.target.id == "siteDescriptionTypeText"){ + value = 'Text'; + } else { + value = 'Page'; + } + } + sdtText.val(value); + sdtPage.val(value); + var text = $('#siteDescriptionText').parent().parent(); + var page = $('#siteDescriptionPage').parent().parent(); + if(value == 'Text'){ + sdtText.prop('checked',true); + text.show(); + page.hide(); + } else { + sdtPage.prop('checked',true); + page.show(); + text.hide(); + } +}; \ No newline at end of file diff --git a/src/main/webapp/scripts/xnat/admin/themeManagement.js b/src/main/webapp/scripts/xnat/admin/themeManagement.js new file mode 100644 index 0000000000000000000000000000000000000000..930e230b9ced35ee49cde6d64c1d982e8f3d70bf --- /dev/null +++ b/src/main/webapp/scripts/xnat/admin/themeManagement.js @@ -0,0 +1,128 @@ +/* + * org.nrg.xnat.turbine.modules.screens.ManageProtocol + * XNAT http://www.xnat.org + * Copyright (c) 2013, Washington University School of Medicine + * All Rights Reserved + * + * Released under the Simplified BSD. + * + * Author: Justin Cleveland <clevelandj@wustl.edu> + * Last modified 3/17/2016 3:33 PM + */ +var themeUrl = XNAT.url.rootUrl('xapi/theme'); +var s = '/', q = '?', a = '&'; +var csrf = 'XNAT_CSRF='+window.csrfToken; +$('#titleAppName').text(XNAT.app.siteId); +var currentTheme = $('#currentTheme'); +var themeSelector = $('#themeSelection'); +var themeUploadForm = document.getElementById('themeFileUpload-form'); +var themeUploader = document.getElementById('themeFileUpload-input'); +var themeUploadSubmit = document.getElementById('themeFileUpload-button'); +var selectedTheme = null; +function populateThemes(){ + getCurrentTheme(getAvailableThemes); +}; +function getCurrentTheme(callback){ + var role = 'global'; + $.get(themeUrl+s+role+q+csrf, null, function (data){ + themeSelector.empty(); + selectedTheme = data.name?data.name:'None'; + currentTheme.text(selectedTheme); + if(typeof callback === 'function'){ + callback(data.name); + } + }, 'json'); +}; +function getAvailableThemes(selected){ + $.get(themeUrl+q+csrf, null, function (data){ + themeSelector.empty(); + addThemeOptions(data, selected); + }, 'json'); +}; +function addThemeOptions(newThemeOptions, selected){ + if(Array.isArray(newThemeOptions)) { + $(newThemeOptions).each(function (i, opt) { + var select = ''; + if (selected == opt.value) { + select = ' selected="selected"'; + } + themeSelector.append('<option value="'+opt.value+'"'+select+'>'+opt.label+'</option>'); + }); + } +}; +function selectTheme(themeToSelect){ + if(themeToSelect && typeof themeToSelect === 'string'){ + themeSelector.val(themeToSelect); + } +}; +var themeSelectionForm = $('#themeSelection').parent().parent().parent().parent(); +themeSelectionForm.off('submit'); +themeSelectionForm.submit(function(ev){ + ev.preventDefault(); + xmodal.confirm({ + content: 'Theme selection appearances may not fully take effect until users log out, clear their browser cache and log back in.'+ + '<br><br>Are you sure you wish to change the global theme?', + action: function(){ + $.put(themeUrl+s+encodeURI(themeSelector.val())+q+csrf, null, function(data){ + console.log(data); + populateThemes() + }); + } + }); +}) +function removeTheme(){ + xmodal.confirm({ + content: 'Are you sure you wish to delete the selected theme?', + action: function(){ + $.delete(themeUrl+s+encodeURI(themeSelector.val())+q+csrf, null, function(data){ + console.log(data); + populateThemes(); + }); + } + }); +}; + +/*** Theme Package Upload Functions ***/ +themeUploadForm.action = themeUrl+q+csrf; +$(themeUploadForm).parent().css('position','relative'); +$(themeUploadForm).parent().css('top','-30px'); +themeUploadForm.onsubmit = function(event) { + event.preventDefault(); + $(themeUploadSubmit).text('Uploading...'); + $(themeUploadSubmit).attr('disabled', 'disabled'); + var files = themeUploader.files; + var formData = new FormData(); + var uploaded = false; + for (var i = 0; i < files.length; i++) { + var file = files[i]; + if (!file.type.match('zip.*')) { + continue; + } + formData.append('themePackage', file, file.name); // formData.append('themes[]', file, file.name); + var xhr = new XMLHttpRequest(); + xhr.open('POST', themeUploadForm.action, true); + xhr.onload = function () { + if (xhr.status !== 200) { + console.log(xhr.statusText); + console.log(xhr.responseText); + xmodal.message('Upload Error', 'There was a problem uploading your theme package.<br>Server responded with: '+xhr.statusText); + } + $(themeUploadSubmit).text('Upload'); + $(themeUploadSubmit).removeAttr('disabled'); + var newThemeOptions = $.parseJSON(xhr.responseText); + var selected; + if(newThemeOptions[0]){ + selected = newThemeOptions[0].value; + } + addThemeOptions(newThemeOptions, selected); + }; + xhr.send(formData); + uploaded = true; + } + if(!uploaded){ + xmodal.message('Nothing Uploaded', 'No valid theme package files were selected for upload.'); + $(themeUploadSubmit).text('Upload'); + $(themeUploadSubmit).removeAttr('disabled'); + } +}; +$(populateThemes); // ...called once DOM is fully loaded "ready" diff --git a/src/main/webapp/scripts/xnat/app/siteSetup.js b/src/main/webapp/scripts/xnat/app/siteSetup.js index 45915b9fe04a5457d3b4839ee9be7e45fa30c962..997b6fa9c50897208026669e99c67d932d8cc989 100644 --- a/src/main/webapp/scripts/xnat/app/siteSetup.js +++ b/src/main/webapp/scripts/xnat/app/siteSetup.js @@ -87,7 +87,7 @@ var XNAT = getObject(XNAT); multiForm = spawn('form', { name: opts.name, - classes: 'xnat-form-panel multi-form panel panel-default', + classes: 'xnat-form-panel multi-form', method: opts.method || 'POST', action: opts.action ? XNAT.url.rootUrl(opts.action) : '#!', onsubmit: function(e){ @@ -213,10 +213,7 @@ var XNAT = getObject(XNAT); } }, [ - ['div.panel-heading', [ - ['h3.panel-title', opts.title || opts.label] - ]], - + // 'inner' is where the NEXT spawned item will render inner, diff --git a/src/main/webapp/scripts/xnat/ui/panel.js b/src/main/webapp/scripts/xnat/ui/panel.js index 54b24abfe724ba50669b7fd12aeff1f8a6fb1447..1f3c3c43d29751d77fa7f4f1016e8b13ce57fb46 100644 --- a/src/main/webapp/scripts/xnat/ui/panel.js +++ b/src/main/webapp/scripts/xnat/ui/panel.js @@ -137,16 +137,25 @@ var XNAT = getObject(XNAT || {}); // set form element values from an object map function setValues(form, dataObj){ // find all form inputs with a name attribute - $$(form).find(':input[name]').each(function(){ - var val = dataObj[this.name]; + $$(form).find(':input').each(function(){ + + var val = dataObj[this.name||this.title]; + if (!val) return; + if (Array.isArray(val)) { val = val.join(', '); } else { val = stringable(val) ? val : JSON.stringify(val); } - $(this).changeVal(val); + + $(this).val(val); + + if (/checkbox|radio/i.test(this.type)) { + this.checked = !!this.value; + } + }); if (xmodal && xmodal.loading && xmodal.loading.closeAll){ xmodal.loading.closeAll(); @@ -181,6 +190,7 @@ var XNAT = getObject(XNAT || {}); // if 'load' starts with '!?' do an eval() var doEval = '!?'; + if (obj.load && obj.load.toString().indexOf(doEval) === 0) { obj.load = (obj.load.split(doEval)[1]||'').trim(); setValues(form, eval(obj.load)); @@ -193,23 +203,18 @@ var XNAT = getObject(XNAT || {}); // REST ////////// + var ajaxUrl = obj.refresh || ''; + // if 'load' starts with $?, do ajax request var ajaxPrefix = '$?'; - var ajaxUrl = ''; var ajaxProp = ''; - - if (obj.refresh) { - ajaxUrl = obj.refresh; - } // value: $? /path/to/data | obj:prop:name - else if (obj.load && obj.load.toString().indexOf(ajaxPrefix) === 0) { - ajaxUrl = obj.load; + if (obj.load && obj.load.toString().indexOf(ajaxPrefix) === 0) { + ajaxUrl = (obj.load.split(ajaxPrefix)[1]||'').trim().split('|')[0]; + ajaxProp = ajaxUrl.split('|')[1] || ''; } - ajaxUrl = (ajaxUrl.split(ajaxPrefix)[1]||'').trim().split('|')[0]; - ajaxProp = ajaxUrl.split('|')[1] || ''; - // need a url to get the data if (!ajaxUrl || !stringable(ajaxUrl)) { xmodal.loading.close('#load-data'); @@ -268,7 +273,7 @@ var XNAT = getObject(XNAT || {}); // click 'Discard Changes' button to reload data _resetBtn.onclick = function(){ - if (!/^#/.test($formPanel.attr('action')||'#')){ + if (!/^#/.test($formPanel.attr('action'))){ $formPanel.triggerHandler('reload-data'); } }; @@ -296,7 +301,7 @@ var XNAT = getObject(XNAT || {}); multiform = {}; // don't submit forms with 'action' starting with '#' - if (/^#/.test($form.attr('action')||'#')) { + if (/^#/.test($form.attr('action'))) { return false; } diff --git a/src/main/webapp/scripts/xnat/ui/templates.js b/src/main/webapp/scripts/xnat/ui/templates.js index df5dadf4d40bc78fcda445acc23f3aa560752117..22fea19499da633696e49701d0560d5c7d2056e2 100644 --- a/src/main/webapp/scripts/xnat/ui/templates.js +++ b/src/main/webapp/scripts/xnat/ui/templates.js @@ -262,7 +262,9 @@ var XNAT = getObject(XNAT); var hiddenInput; // check buttons if value is true - if (/checkbox|radio/i.test(opts.type||'')) { + if (/checkbox|radio/i.test(element.type||'')) { + + element.checked = /true|checked/i.test((opts.checked || element.value).toString()); element.checked = /true|checked/i.test((opts.checked || element.value).toString()); @@ -320,7 +322,7 @@ var XNAT = getObject(XNAT); // add the options $.each(opts.options||{}, function(name, prop){ var _option = spawn('option', extend(true, { - html: prop.label || prop.value || prop, + html: prop.html || prop.text || prop.label || prop.value || prop, value: prop.value || name }, prop.element)); // select the option if it's the select element's value diff --git a/src/main/webapp/scripts/xnat/xhr.js b/src/main/webapp/scripts/xnat/xhr.js index e0df7ab2fcb9b2d2efa6986dce28268c751973f6..b7e97c987bb64b30479d534b9920a8dd041b867a 100755 --- a/src/main/webapp/scripts/xnat/xhr.js +++ b/src/main/webapp/scripts/xnat/xhr.js @@ -483,7 +483,7 @@ var XNAT = getObject(XNAT||{}), opts.method = opts.method || _form.method || 'GET'; if ($.isFunction(opts.validate)) { - validation = opts.validate.apply(_form, opts); + validation = opts.validate.call(_form, opts); if (!validation) { $form.removeClass('valid').addClass('invalid'); return validation; @@ -541,8 +541,8 @@ var XNAT = getObject(XNAT||{}), // intercept form submissions with 'ajax' or 'json' class // using namespaced event handler submit.json - $('body').on('submit-json, submit-ajax', 'form.ajax, form.json', function(opts){ - return xhr.form(this, opts); + $('body').on('submit.json, submit.ajax', 'form.ajax, form.json', function(){ + return xhr.form(this); }); // special case for YUI 'GET' request diff --git a/src/main/webapp/scripts/yui/build/assets/skins/xnat/xnat.css b/src/main/webapp/scripts/yui/build/assets/skins/xnat/xnat.css index 4299483238dad217832d0c6728a9a9b71c44f576..82ab74682e82282f01826b0c82ad69b8b0053d83 100644 --- a/src/main/webapp/scripts/yui/build/assets/skins/xnat/xnat.css +++ b/src/main/webapp/scripts/yui/build/assets/skins/xnat/xnat.css @@ -2124,7 +2124,7 @@ h2.yui-editor-skipheader,h3.yui-editor-skipheader { height: 0 ; margin: 0 ; padd .yui-skin-sam .yui-navset .yui-nav a em, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav a em { - border: 1px solid #e0e0e0; + border: 1px solid #aaa; border-bottom: none; padding: 8px 16px; cursor: hand; diff --git a/src/main/webapp/style/app.css b/src/main/webapp/style/app.css index 29caed8206049715b08329e05b9e62678b3d2be6..ee76cc001dcf71ffac5478b61acb9eca2dbdcaeb 100644 --- a/src/main/webapp/style/app.css +++ b/src/main/webapp/style/app.css @@ -985,6 +985,7 @@ body [type="reset"] { font-size: 13px; letter-spacing: 0.02em; text-decoration: none; + box-shadow: 0px 1px 1px #ccc; } /* style for button hover */ @@ -995,6 +996,7 @@ body button:hover, body [type="button"]:hover, body [type="submit"]:hover, body [type="reset"]:hover { + box-shadow: none; cursor: pointer; } @@ -1007,8 +1009,10 @@ body input.btn1, body .btn1[type="button"], body [type="submit"] { color: #fff; - background: #1A75BB; - border: 1px solid #096BB7; + background: #1A75BB linear-gradient( #3C8BC7, #1A75BB ); + /*border: 1px solid #102040;*/ + border: 1px solid #033E77; + box-shadow: 0 1px 1px #848484; } .btn1:hover, @@ -1018,7 +1022,9 @@ body [type="submit"] { body input.btn1:hover, body .btn1[type="button"]:hover, body [type="submit"]:hover { - background: #096BB7; + /*background: #096BB7;*/ + background: #1A75BB; + box-shadow: none; } /* btn2 gets gray background */ @@ -1028,7 +1034,7 @@ body button, body [type="button"], body [type="reset"] { background: #f0f0f0 linear-gradient( #ffffff, #f0f0f0 ); - border: 1px solid #c0c0c0; + border: 1px solid #848484; } .btn:hover, @@ -1511,6 +1517,8 @@ body.modal-popup #xnat_power { .yui-skin-sam .yui-button button, .yui-skin-sam .yui-button a, .yui-skin-sam .yui-button a:visited { + border: none; + box-shadow: none; color: #000000; font-size: 12px; height: 26px; @@ -1610,7 +1618,7 @@ div.edit_title { .yui-skin-sam .yuimenu .bd { background-color: #fff; - border: 1px solid #ccc; + border: 1px solid #aaa; } td.highlighted { @@ -1789,7 +1797,9 @@ div.containerTitle.withColor { margin-top: 0; padding: 1px; background: #fff; - border: 1px solid #c0c0c0; + border: solid #aaa; + border-width: 0 1px 1px; + border-top: 1px solid #102040; } /* make sure all sub-nav menus are wide enough */ @@ -1825,14 +1835,14 @@ div.containerTitle.withColor { display: none; top: 0; margin-left: -2px; - border: 1px solid #c0c0c0; + border: 1px solid #aaa; } #main_nav ul.nav ul, .shadowed { - -moz-box-shadow: 0 2px 12px rgba(96, 96, 96, 0.8); - -webkit-box-shadow: 0 2px 12px rgba(96, 96, 96, 0.8); - box-shadow: 0 2px 12px rgba(96, 96, 96, 0.8); + -moz-box-shadow: 0 1px 4px rgba(132, 132, 132, 0.8); + -webkit-box-shadow: 0 1px 4px rgba(132, 132, 132, 0.8); + box-shadow: 0 1px 4px rgba(132, 132, 132, 0.8); /* border: 2px solid rgba(204,204,204,0.5) ; */ } diff --git a/src/main/webapp/style/app.less b/src/main/webapp/style/app.less deleted file mode 100644 index 2c3e183ab924a2b443401151934f1c4f4cc1ce99..0000000000000000000000000000000000000000 --- a/src/main/webapp/style/app.less +++ /dev/null @@ -1,3280 +0,0 @@ -/* xdat.css */ -/***********************************************/ -/* Default styles */ -/***********************************************/ -body { - margin: 0; - padding: 0; - font-size: 12px; - line-height: 15px; - font-family: Arial, Helvetica, sans-serif; - background-color: white; -} - -th { - margin: 0; - border-top: none; - border-right: none; - border-left: none; - border-collapse: collapse; - padding: 0 4px; -} - -h2 { - line-height: 24px; -} - -h3 { - line-height: 20px; - margin: 0; -} - -h4 { - line-height: 18px; -} - -p { - font-size: 13px; - line-height: 17px; - margin: 0; -} - -td { - /* */ -} - -a.plainText { - text-decoration: none; - color: black; -} - -a { - cursor: pointer; - text-decoration: none; - color: #039; -} - -img { - border: none; -} - -input[type="text"], -input[type="password"], -input[type="number"] { - padding: 4px 5px 3px 5px; - border: 1px solid #b0b0b0; -} - -textarea { - padding: 4px; - font-family: Arial, Helvetica, sans-serif; - font-size: 12px; - border: 1px solid #b0b0b0; -} - -select { - /* */ -} - -/* xnat.css */ -/***********************************************/ -/* XNAT styles */ -/***********************************************/ -.withColor { - background-color: #2d69b8; - color: #fff; -} - -.withThinBorder { - border: 1px solid #aaa; -} - -.recentDataActivity { - cursor: default; -} - -.text { - font-size: 11px; - line-height: 13px; - font-family: Arial, Helvetica, sans-serif; -} - -div.link { - cursor: pointer; - text-decoration: none; - font-size: 11px; - font-family: Arial, Helvetica, sans-serif; - color: #039; -} - -div.edit_title { - font-size: 16px; - line-height: 18px; -} - -div.edit_header1 { - font-size: 14px; - line-height: 18px; -} - -div.edit_header2 { - font-size: 13px; - line-height: 16px; -} - -div.edit_header3 { - font-size: 12px; - line-height: 15px; -} - -div.spacer { - line-height: 13px; -} - -.actionsBox { - background-color: #dcdcdc; -} - -.quarantine { - background-color: #fc3; -} - -#loginBox { - top: 2px; - position: absolute; - text-align: right; - right: 5px; -} - -#menu1 { - position: relative; - top: 2px; - left: 5px; - width: 99%; - height: 28px; - border-bottom: 1px solid #aaa; -} - -div.option { - /* */ -} - -#tabbedList { - margin: 10px; -} - -#tabbedList li a { - height: 20px; - text-decoration: none; -} - -#tabbedList li a:link, #tabbedList li a:visited { - color: #000; - display: block; - padding: 8px 0 0 10px; -} - -#tabbedList li a:hover { - background-color: #fff; - padding: 8px 0 0 10px; -} - -td.leftBar { - width: 170px; - padding-top: 10px; - padding-left: 10px; -} - -/* hide leftBar if it decides to show up on a popup page */ -body.popup td.leftBar { - width: 0; - padding: 0; -} - -body.popup td.leftBar > div { - display: none; -} - -ul.menu { - list-style-type: none; - text-decoration: none; - margin: 0; - padding: 0; -} - -ul.menu li { - float: left; - position: relative; - margin: 0; - padding: 2px 6px; -} - -ul.subMenu { - margin: 0; - padding: 1px; - padding-top: 3px; - display: none; - position: absolute; - text-decoration: none; -} - -ul.subMenu li { - list-style-type: none; - margin: 0; - padding: 4px 8px; -} - -ul.topMenu { - background-color: #fff; - height: 20px; - text-align: center; - font-size: 11px; - color: #4D4D4D; - z-index: 4000; -} - -ul.topMenu li { - border: 0 solid #aaa; - width: 124px; -} - -li.topMenuHover { - background-color: #fff; -} - -ul.topSubMenu { - text-align: center; - color: #4D4D4D; - z-index: 4000; -} - -ul.topSubMenu li { - border: 1px solid #aaa; - font-size: 11px; -} - -li.topSubMenuHover { - /* */ -} - -div.container { - border: 1px solid #ccc; /* width:300px; */ -} - -div.mainContainer { - border: 1px solid #ccc; /* width:300px; */ -} - -div.containerTitle { - border-bottom: 1px solid #ccc; - font-size: 13px; - font-weight: 500; - line-height: 23px; - padding-left: 7px !important; - padding-right: 7px !important; -} - -div.containerBody { - overflow: auto; - font-size: 12px; - line-height: 15px; - padding: 0; -} - -div.containerBody a { - font-weight: bold; -} - -div.containerBody > div > div { - padding: 5px 10px 9px; - font-size: 12px; -} - -div.containerBody #min_expt_list { - /* */ -} - -div.containerBody #min_expt_list td { - padding: 3px 6px; -} - -div.containerBody h3 { - margin: 2px 0 5px; - font-size: 13px; - line-height: 15px; -} - -div.mainContainerBody { - overflow: auto; - font-size: 11px; - line-height: 13px; - padding: 3px; -} - -div.containerItem { /* font-size: 11px ; line-height: 13px ; */ - padding: /* 3px 0 0 3px */ 8px 12px 0 12px; -} - -div.projectIndex { - font-size: 11px; - line-height: 13px; - padding: 3px; - border-top: 1px solid #aaa; -} - -.horizontalMenu { - font-size: 13px; - line-height: 15px; - position: relative; - padding: 3px; -} - -.horizontalMenuItem { - font-size: 11px; - line-height: 13px; - bottom: 0; - display: inline; - padding-right: 3px; -} - -ul.containerMenu { - font-size: 11px; - padding-right: 0; -} - -ul.containerMenu li { - float: right; - padding-right: 0; -} - -ul.containerSubMenu { - background-color: #fff; - border: 1px solid #aaa; -} - -ul.containerSubMenu li { - float: none; - padding-right: 0; -} - -div.titleBarLink { - text-decoration: none; - font-size: 11px; - color: #039; - cursor: pointer; - display: inline; - height: 16px; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; - border-bottom: 1px solid #aaa; - padding-left: 5px; - padding-right: 5px; - margin-left: 0; - margin-right: 0; - background-color: #ffd; -} - -div.titleBarLink:hover { - background-color: #dedede; -} - -div.titleBarText { - text-decoration: none; - font-size: 11px; - color: black; - display: inline; - height: 16px; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; - border-bottom: 1px solid #aaa; - padding-left: 5px; - padding-right: 5px; - background-color: #fff; - margin-left: 0; - margin-right: 0; -} - -div.titleBarGrey { - text-decoration: none; - font-weight: 500; - font-size: 11px; - color: black; - display: inline; - height: 16px; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; - border-bottom: 1px solid #aaa; - padding-left: 5px; - padding-right: 5px; - margin-left: 0; - margin-right: 0; - background-color: #fff; -} - -font.titleBarComment { - text-decoration: none; - font-weight: 500; - font-size: 11px; - color: black; -} - -.odd { - background-color: #fff; -} - -.even { - background-color: #f7f7f7; - border-top: 1px solid #ececec; - border-bottom: 1px solid #ececec; -} - -div.projectPrimary { /* font-weight: 700 ; */ -} - -td.highlighted { - background-color: #ffc; - border: 1px solid #aaa; -} - -td.results { - white-space: nowrap; -} - -div.paging { - text-align: center; - font-size: 11px; - z-index: 4000; -} - -div.pagingTitle { - float: left; - position: relative; -} - -table.paging { - line-height: 11px; - margin: 0; - padding: 0; - font-size: 11px; -} - -tbody.paging { - line-height: 11px; - margin: 0; - padding: 0; - font-size: 11px; -} - -tr.paging { - line-height: 11px; - margin: 0; - padding: 0; - font-size: 11px; -} - -td.paging { - line-height: 11px; - margin: 0; - font-size: 11px; -} - -ul.paging { - text-decoration: none; - margin: 0; - padding-left: 10px; -} - -li.paging { - list-style-type: none; - float: left; - position: relative; - margin: 0; - padding-left: 6px; - padding-right: 6px; - font-size: 11px; -} - -a.paging { - cursor: pointer; - display: block; - text-decoration: none; - color: #039; -} - -div.optionsTab { - background-color: #fff; - border: 1px solid #aaa; - white-space: nowrap; - padding: 3px; -} - -div.quickSearch { - padding: 2px; - border: 1px solid #e8e8e8; - white-space: nowrap; - width: 180px; -} - -td.x_rs_td { - white-space: nowrap; - border: 1px solid #7F7F7F; - margin: 0; - border-left-style: none; - border-top-style: none; - font-size: 12px; - padding: 2px 6px 2px 4px; -} - -td.x_rs_td a { - font-weight: bold; -} - -th.x_rs_th { - white-space: nowrap; - border-collapse: collapse; - border: 1px solid #7F7F7F; - color: #000; - margin: 0; - padding: 4px 10px 4px 10px; - text-decoration: none; - vertical-align: middle; - border-left-style: none; -} - -tr.even > td.sorted { - background-color: #BFBFBF; -} - -tr.odd > td.sorted { - background-color: #F2F2F2; -} - -th.sorted { - /* */ -} - -td.first-td { - border-left-style: solid; -} - -th.first-td { - border-left-style: solid; -} - -td.ext-content { - width: 300px; - white-space: normal; -} - -/* yellow text = NOPE */ -font[color="yellow"] { - color: #888; -} - -/* universal button style with CSS gradient */ -.button { - display: inline-block; - margin: 1px; - padding: 2px 2px 4px; - border: 1px solid #808080; - border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - -khtml-border-radius: 3px; - font-weight: bold; - text-align: center; - background: #888; - background: -moz-linear-gradient(top, #cccccc 0%, #999999 25%); - /* FF3.6+ */ - background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #cccccc), color-stop(25%, #999999)); - /* Chrome,Safari4+ */ - background: linear-gradient(top, #cccccc 0%, #999999 25%); - /* W3C */ - color: #fff; -} - -/* width set for QC buttons */ -.QC { - width: 4em; -} - -/* styles set for QC results */ -.good { - background: #390; - background: -moz-linear-gradient(top, #66cc33 0%, #339900 25%); - background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #66cc33), color-stop(25%, #339900)); - background: linear-gradient(top, #66cc33 0%, #339900 25%); -} - -.acceptable { - background: #c90; - background: -moz-linear-gradient(top, #ffcc33 0%, #cc9900 25%); - background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #ffcc33), color-stop(25%, #cc9900)); - background: linear-gradient(top, #ffcc33 0%, #cc9900 25%); -} - -.bad { - background: #900; - background: -moz-linear-gradient(top, #cc3333 0%, #990000 25%); - background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #cc3333), color-stop(25%, #990000)); - background: linear-gradient(top, #cc3333 0%, #990000 25%); -} - -/* OPTIONAL HOVER STATES */ -.button:hover { - background: #ccc -} - -.good:hover, -.acceptable:hover, -.bad:hover { - background: #ccc; - color: #999; -} - -/* table styling for a ruled table */ -table.ruled { - background: #eee; - border: 1px solid #000; - font-family: Verdana, Geneva, sans-serif; -} - -table.ruled th { - background: #ddd; - border-bottom: 1px solid #000; - text-align: left; -} - -table.ruled th, -table.ruled td { - border-left: 1px solid #000; -} - -table.ruled th:first-child, -table.ruled td:first-child { - border-left: none; -} - -table.ruled tr:nth-child(2n+1) { - background: #fff; -} - -.ic, .ic_spacer { - display: none; - visibility: hidden; -} - -.underscore { - border-bottom: 2px solid #f93; - padding-bottom: 1px; - padding-right: 20px; - padding-left: 5px; -} - -.hidden { - display: none !important; - visibility: hidden !important; - opacity: 0 !important; -} - -.mono { - font-family: Courier, monospace; -} - -/* ALERTS & MESSAGES TO USERS */ - -div.alert, -div.error, -div.justification, -div.message, -div.info, -div.note, -div.success, -div.warning { - background-color: #f7f7f7; - background-size: 16px 16px; - background-position: 8px 9px; - background-image: url('icons/icon-check-blue-48.png'); - background-repeat: no-repeat; - border: #ccc solid; - border-width: 1px; - color: #444; - font-size: 12px; - padding: 10px 10px 10px 32px; - position: relative; -} - -div.alert, -div.warning { - background-color: #ffc; - background-image: url(icons/icon-alert-48.png); -} - -div.error { - background-color: #ffcfcf; - background-image: url(icons/icon-error-48.png); -} - -div.message, -div.info { - background-color: #e4efff; - background-image: url(icons/icon-info-48.png); -} - -div.success { - background-color: #dbffc9; - background-image: url(icons/icon-check-green-48.png); -} - -div.justification { - background-image: url(icons/icon-check-blue-48.png); -} - -div.message.loginPage, -div.error.loginPage, -div.message.loginPage, -div.note.loginPage { - top: -40px; -} - -/* smaller messages */ -div.alert.small, -div.warning.small, -div.error.small, -div.message.small, -div.info.small, -div.success.small, -div.justification.small { - padding-left: 28px; - background-size: 12px 12px; - background-position: 9px 11px; - font-size: 11px; - line-height: 14px; -} - -/* messages without the icon */ -div.alert.no-icon, -div.error.no-icon, -div.justification.no-icon, -div.message.no-icon, -div.info.no-icon, -div.note.no-icon, -div.success.no-icon, -div.warning.no-icon { - background-image: none; - padding: 10px 12px; -} - -#header div.alert, -#header div.error, -#header div.justification, -#header div.message, -#header div.note, -#header div.success, -#header div.warning { - background-image: none; - border-width: 1px 0; - font-size: 11px; - margin: 0 -3px 0 -27px; - padding: 6px; -} - -#header div span { - padding: 0 4px; -} - -#header .close-notification:hover { - cursor: pointer; -} - -.warning-inbody { - background: url('icons/icon-alert-48.png') 10px center no-repeat #ffa; - border: 1px solid #cc8; - font-size: 16px; - padding: 10px 10px 10px 70px; -} - -#warning_bar { - background: #ffa; - border: 1px solid #ee9; - border-left: none; - color: #444; - font-size: 11px; - line-height: 20px; - min-height: 20px; - padding: 2px; - position: absolute; - left: 0; - top: 0; - vertical-align: middle; - width: 550px; -} - -#warning_bar > span { - padding: 0 4px; -} - -#warning_bar .close:hover { - cursor: pointer; -} - -#warning_bar .tip_text { - border: none; -} - -#warning_bar .tip_text i { - border-bottom: 1px dotted #888; - font-style: normal; -} - -#warning_bar .tip_text .tip { - left: 0; - top: 28px; - width: 250px; -} - -#aspera_messagebar { /* positioned dynamically above #layout_content */ - background-color: #fff; - display: block; - margin: 0 auto; - padding: 0; - position: relative; - left: -1px; - width: 1000px; -} - -#aspera_messagebar .note, -#aspera_messagebar .warning { - font-size: 14px; - line-height: 18px; - top: 0; - left: 0; - background-image: none; - padding-left: 20px; - padding-right: 20px; -} - -#aspera_messagebar .note { - background-color: #e7e7e7; - border-top-color: #c7c7c7; -} - -.note .warning-inset, -.warning .warning-inset { - color: #c60; - display: inline-block; - font-weight: bold; - margin-top: 18px; - vertical-align: top; - width: 210px; -} - -.note .message-inset, -.warning .message-inset { - border-left: 1px solid #999; - display: inline-block; - padding-left: 30px; - width: 700px; -} - -table.dark { - background-color: /* #DCDCDC */ #f0f0f0; - border: 1px solid #ccc !important; - color: #000; - font-size: 12px; - font-weight: bold; -} - -table.dark th, table.dark td { - padding: 4px 8px; -} - -/* new header and body styles */ -body, html body, * body { - margin: 0; - background: #fff url('../images/left_margin.gif') -5px top repeat-y; - font-family: Arial, Helvetica, sans-serif !important; - font-size: 12px; - line-height: 15px; /* letter-spacing: 0.02em ; */ - position: relative; - overflow-y: scroll; - overflow-x: auto; -} - -a { - color: /* #2a70c6 */ #1A75BB; -} - -a.link { - text-decoration: underline !important; -} - -/* force links to look like links by adding the 'link' class */ -a, a:link, a:active, a:focus, -button, button:enabled, button:target, button:active, button:focus { - outline: none !important; -} - -img { /* vertical-align: bottom ; */ - border: none; - outline: none; -} - -hr { - color: transparent; - border: none; - border-bottom: 1px solid #ccc; -} - -.clear { - height: 0; - clear: both; -} - -/* ////////// FORM ELEMENTS ////////// */ -input { - font-family: Arial, Helvetica, sans-serif; - font-size: 12px; -} - -/* base button style */ -.btn1, -.btn2, -body button, -body input[type="button"], -body input[type="submit"], -body input[type="reset"] { - display: inline-block; - padding: 4px 9px; - max-height: 28px; - background-position: center top; - background-repeat: repeat-x; - border-radius: 3px; - font-family: Arial, Helvetica, sans-serif; - font-size: 13px; - text-decoration: none; -} - -/* 'required' items */ -.required i { - font-style: normal; - color: #c00; -} - -/* style for button hover */ -.btn1:hover, -.btn2:hover, -body button:hover, -body input[type="button"]:hover, -body input[type="submit"]:hover, -body input[type="reset"]:hover { - cursor: pointer; -} - -/* btn1 gets blue background - gradient image and base color to match the bottom of the background image */ -.btn1, -body input.btn1, -body input.btn1[type="button"], -body input.btn1[type="submit"] { - color: #fff; - background-color: #07428d; - background-image: url('../images/btn1_30px.png'); - border: 1px solid /* #508ad0 */ /* #243356 */ /* #293d66 */ #102040; - font-weight: bold; -} - -/* btn2 gets gray background */ -.btn2, -body button, -body input[type="button"], -body input[type="submit"], -body input[type="reset"] { - background-image: url('../images/btn2_30px.png'); - border: 1px solid /* #a8a8a8 */ /* #a0a0a0 */ #848484; -} - -/* smaller btn */ -.btn1.btn-sm, -.btn2.btn-sm { - font-size: 11px !important; - padding: 3px 6px !important; -} - -.btn-inline { - display: inline-block !important; -} - -.btn-inline.right { - position: absolute; - right: 0; -} - -/* <button> or button-like elements that are disabled or have class="disabled" will LOOK like they're disabled */ -.btn1.disabled, -.btn2.disabled, -body button.disabled, -body button:disabled, -body input[type="button"]:disabled, -body input[type="submit"]:disabled, -body input[type="reset"]:disabled { - color: #a0a0a0; - border-color: #c0c0c0; - background: #e0e0e0; - cursor: default !important; -} - -/* remove outline from <button> or <input type="button/submit/reset"> elements */ -body button:focus, -body input[type="button"]:focus, -body input[type="submit"]:focus, -body input[type="reset"]:focus { - outline: none !important; -} - -input.date_mask { - font-family: Courier, monospace; -} - -select { - padding: 2px; - font-family: Arial, Helvetica, sans-serif; - font-size: 12px; -} - -select[multiple] { - max-width: 200px; -} - -/* page layout styles */ -#page_wrapper { - padding: 28px /* 20px */; - padding-left: 15px; -} - -#layout_content.main { - min-width: 728px; - width: 740px; -} - -.ie7 #layout_content.main { - width: 740px; - overflow: auto; -} - -#wrapper_table { - min-width: 940px; -} - -.ltie9 #wrapper_table { - width: 940px; -} - -/* search results page */ -#search_results_container { - min-width: 930px; - width: 100%; - margin: 0 10px 0 0; - padding: 0; -} - -#search_tab_module { - width: 100%; -} - -#search_tabs { - width: 100% -} - -#search_tabs .xT_p, -#search_tabs .xT_c { - width: 850px !important; - /* width: 1010px ; max-width: 1010px ; */ -} - -#search_tabs .xT_c { - min-height: 150px; -} - -/* login box */ -#login_area { - line-height: 1.1; - margin: 0 auto; - width: 960px; -} - -#login_area p { - margin-bottom: 1em; -} - -#login_welcome { - display: inline-block; - margin: 0 0 3em; - vertical-align: top; - width: 450px; -} - -@media screen and (min-width: 1000px) { - #login_welcome { - margin: 0 100px 0 0; - } -} - -#login_box, #register_box { - background-color: #f0f0f0; - display: inline-block; - line-height: 1.1; - padding: 0; - width: 392px; -} - -#login_box div.message, #register_box div.message { - margin-bottom: 0; -} - -#login_form, #register_form { - border: 1px solid #ccc; - padding: 20px; -} - -#login_box_container, #register_box_container { - display: inline-block; - position: relative; - vertical-align: top; - width: 400px; -} - -#login_container { - margin: 0 auto; - max-width: 1200px; -} - -#register_forgot a { - margin-right: 20px; -} - -#login_container #header { - position: absolute; - left: 20px; -} - -#login_container #layout_content, #login_container #layout_content2 { - margin-top: 90px; -} - -#site_description { - /* */ -} - -#site_description img { - width: 100%; -} - -#site_description a { - text-decoration: underline; -} - -span.sep { - background-color: #999; - margin: 0 .25em; - height: 0.8em; - width: 1px; - display: inline-block; -} - -/* user bar stuff */ -#user_bar { - position: absolute; - left: 0; - top: 0; - width: 960px; - height: 28px; - font-size: 11px; - line-height: 28px; - vertical-align: middle; - background: #dadada url('../images/user_bar_bkgd.png') left top repeat-x; -} - -#user_bar.no_menu { - width: 100%; -} - -#last_login { - display: block; - float: left; - padding-left: 1em; - color: #666; - white-space: nowrap; -} - -#user_info { - display: block; - margin-right: 1em; - float: right; - color: #333; - text-align: right; -} - -.ie7 #user_info { - line-height: 24px; -} - -#user_info a { - font-weight: normal; - text-decoration: underline; -} - -#user_info b { - padding: 0 5px; - font-weight: normal; -} - -#user_info #timeLeft { - padding: 0 0 0 1px; - font-family: "Courier New", Courier, monospace; - font-weight: bold; - color: #000; - white-space: nowrap; -} - -#header { - position: relative; - width: 932px; - min-height: 72px; - margin: 0; - margin-bottom: 16px; - padding-left: 10px; - background: #fff; - z-index: 2; -} - -#header_logo { - max-width: 240px; - max-height: 120px; -} - -#header_logo img { - display: block; /* width: 100% ; height: 100% ; */ - max-width: 240px; - max-height: 120px; -} - -#quickSearchForm { - position: absolute; - right: 0; - bottom: 35px; -} - -#searchValue { - border: 1px solid #ccc; - height: 17px; -} - -/* .ie #searchValue { position: relative ; top: 1px ; } */ -#quickSearchForm a { - padding: 2px 8px; - font-size: 11px; - font-weight: bold; -} - -#search_btn { - color: #fff; -} - -#advanced_btn { - color: #333; - border: 1px solid #aaa; -} - -#DefaultTopTR td { - padding: 0; -} - -#main_nav, -#topMenuBar { - position: absolute !important; - right: 0; - bottom: 0; - height: 24px; - width: 600px; -} - -#main_nav.hidden { - overflow: hidden; -} - -/* warning bar */ -#warning_bar { - width: 520px; - height: 20px; - position: absolute; - left: 0; - top: 0; - line-height: 20px; - vertical-align: middle; - font-size: 11px; - background: #ffc; - color: #444; - border: 1px solid #ee9; - border-left: none; -} - -/* warning bar with no left 'page border' and 960px user bar */ -/* #warning_bar { background: none repeat scroll 0 0 #FFFFCC; border: 1px solid #EEEE99; color: #666666; font-size: 11px; height: 20px; left: -22px; line-height: 20px; position: relative; top: -2px; vertical-align: middle; width: 958px; } */ -/* warning bar with no left 'page border' and 100% user bar */ -/* #warning_bar { background: none repeat scroll 0 0 #FFFFCC; border: 1px solid #EEEE99; color: #666666; display: inline-block; font-size: 11px; height: 22px; left: -22px; line-height: 22px; padding-left: 1px; padding-right: 5px; position: relative; top: -2px; vertical-align: middle; } */ -#warning_bar > span { - padding: 0 4px; -} - -#warning_bar .close:hover { - cursor: pointer; -} - -#warning_bar .tip_text { - border: none; -} - -#warning_bar .tip_text i { - border-bottom: 1px dotted #888; - font-style: normal; -} - -#warning_bar .tip_text .tip { - left: 20px; - top: 25px; - width: 250px; - padding: 10px 20px; - line-height: 15px; - background: #ffc; - border: 1px solid #ee9; -} - -/* footer graphic */ -#xnat_power { - border-top: 1px solid #ccc; - bottom: -70px; - height: 70px; - left: 0; - margin: inherit; - position: relative; - text-align: right; - width: 100%; -} - -#xnat_power a { - float: inherit; - margin: 10px; -} - -#xnat_power small { - display: block; - color: #888; - font-size: 11px; - padding: 0 15px; -} - -/* hide in popups? */ -body.modal-popup #xnat_power { - display: none; -} - -/* overrides to make this thing look better? */ -.yui-skin-sam .yui-panel-container { - padding: 0 1px; /* z-index: 999999991 !important; */ -} - -.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel { - height: 26px; - line-height: 26px; - padding-left: 15px; - padding-right: 27px; - vertical-align: middle; - font-weight: bold; - font-size: 12px; -} - -.yui-skin-sam .yui-button button, .yui-skin-sam .yui-button a, .yui-skin-sam .yui-button a:visited { - color: #000000; - font-size: 12px; - height: 26px; - line-height: 26px; - padding: 0 12px; - vertical-align: middle; -} - -/*.yui-content { font-size: 12px ; }*/ -.yui-skin-sam .yui-dialog .ft span.default button, -.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn.yui-default button { - background: #07428d url('../images/btn1_30px.png') repeat-x center center; - color: #fff; - outline: none !important; -} - -/*.yui-skin-sam .yui-dialog .ft { height: auto !important ; padding: 14px ; }*/ -/* -.yui-skin-sam .yui-dialog .ft span.default button { color: #FFFFFF ; border: none ; outline: none ; } -.yui-skin-sam .yui-dialog .ft span.default button:active { border: none ; outline: none ; } -a, a:active, button, button:active, *:active { outline: none ; border: none ; } -.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel { padding-right: 24px; padding-left: 12px ; } -*/ -.yui-nav a { - font-weight: bold; -} - -.yui-nav li.disabled { - position: fixed; - left: -9999px; -} - -.yui-navset .select_add_tab { - display: none; -} - -.yui-skin-sam .yui-button { - margin: auto 4px; -} - -.yui-skin-sam .yui-button a, -.yui-button button { - font-weight: bold; - font-size: 12px; -} - -.yui-button, .yui-button button { - border-radius: 0 !important; -} - -.yui-panel-container.yui-dialog { - margin-top: -180px; - box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5); -} - -.yui-skin-sam .yui-panel-container .underlay { - display: none; -} - -.yui-skin-sam .yui-pg-container { - white-space: normal; -} - -/* yui-module yui-overlay yui-panel */ -/* yui-panel-container yui-dialog hide-scrollbars yui-simple-dialog shadow yui-overlay-hidden */ - -div.edit_header1, div.edit_title { - font-size: 15px; - font-weight: bold; - line-height: 16px; - padding-bottom: 2px; - /*margin-bottom: 5px ;*/ - /*margin-left: 12px;*/ - min-width: 470px; -} - -div.edit_title { - margin-bottom: 10px; - margin-left: 8px; -} - -.withColor.withThinBorder { - color: #000; - background: #f0f0f0; - border: 1px solid #ccc; -} - -.yui-skin-sam .yui-navset .yui-content, .yui-skin-sam .yui-navset .yui-navset-top .yui-content { - padding: 8px; - border-color: #ccc; -} - -.yui-skin-sam #actionsMenu { - height: auto !important; - overflow: visible !important; -} - -.yui-skin-sam .yuimenu .bd { - background-color: #fff; - border: 1px solid #ccc; -} - -td.highlighted { - background-color: #f0f0f0; - border: 1px solid #d8d8d8; -} - -.yuimenubaritemlabel, -.yuimenuitemlabel { - outline: none; -} - -#layout_content { - margin-left: 0; - padding-top: 10px; - z-index: 0; - font-size: 13px; - line-height: 17px; -} - -body.popup #layout_content { - margin: 0; - padding: 0; -} - -/* -#layout_content, #layout_content .yui-content { width: 700px ; } -#layout_content .yui-nav { width: 714px ; } -*/ - -div.containerTitle.withColor { - font-weight: bold; - background: #1A75BB; -} - -.leftBar a.ygtvlabel { - text-decoration: underline; -} - -#breadcrumbs { - margin: 8px; -} - -#breadcrumbs a { - text-decoration: underline; -} - -#breadcrumbs a.nolink { - color: inherit; - text-decoration: none; -} - -#breadcrumbs a.nolink:hover { - cursor: default; -} - -#breadcrumbs a.last { - font-weight: bold; -} - -.highlight-row:hover { - background: #e5f2ff; -} - -.off-canvas, .off-screen, .offscreen, .html-template { - position: fixed; - left: -9999px; - top: -9999px; -} - -/* ////////// BRAND-SPANKING NEW NAV BAR! ////////// */ -#main_nav { - position: absolute; - right: 0; - bottom: 0; - height: 24px; - width: /* 578px */ /* 525px */ 728px; - color: #333; - background: url('../images/nav_bkgd.png') center center repeat-x; - font-family: Arial, Helvetica, sans-serif; - font-size: 12px; - font-weight: bold; - border: 1px solid #c0c0c0; -} - -#main_nav a { - color: #333; - text-decoration: none; -} - -#main_nav a:hover { - cursor: pointer !important; -} - -#main_nav > ul { - /* */ -} - -#main_nav ul { - margin: 0; - padding: 0; - list-style: none; - background: #f8f8f8; -} - -#main_nav > ul > li { - border-right: 1px solid #c0c0c0; -} - -#main_nav li { - float: left; - display: block; - position: relative; -} - -#main_nav li:hover { - background: url('../images/nav_bkgd_hover.png') center center repeat-x; -} - -#main_nav li a { - display: block; - padding: 0 24px 0 12px; - line-height: 24px; - vertical-align: middle; - white-space: nowrap; - background-position: right center; - background-repeat: no-repeat; - color: #000; -} - -#main_nav li:hover > a { - color: #000; -} - -#main_nav li a.more { - background: url('../images/nav_more.png') right center no-repeat; -} - -/* second-level menus */ -#main_nav li > ul { - display: none; - position: absolute; - left: 0; - top: 25px; - margin-top: -1px; - padding: 1px; - border: 1px solid #c0c0c0; -} - -#main_nav li li { - width: 100%; -} - -#main_nav li li:hover { - background: /* #D8ECFF */ /* #EDF5FF */ #e5f2ff right center no-repeat; -} - -.ie7 #main_nav li li:hover { - background: transparent; -} - -#main_nav li li a { - display: block; - padding: 3px 24px 3px 12px; - line-height: 22px; - font-size: 12px; - background-position: right center; - background-repeat: no-repeat; -} - -#main_nav li li a.more { - background: url('../images/subnav_more.png') right center no-repeat; -} - -#main_nav li li a:hover { - /* */ -} - -.ie7 #main_nav li li a:hover { - text-decoration: underline; -} - -/* third-level menus */ -#main_nav li li ul { - display: none; - top: 0; - margin-left: -2px; - border: 1px solid #c0c0c0; -} - -/* #main_nav li li:hover > ul { display: block ; } */ - -#main_nav li a { - /* */ -} - -#main_nav > ul ul, .shadowed { - -moz-box-shadow: 0px 2px 12px rgba(96, 96, 96, 0.8); - -webkit-box-shadow: 0px 2px 12px rgba(96, 96, 96, 0.8); - box-shadow: 0px 2px 12px rgba(96, 96, 96, 0.8); - /* border: 2px solid rgba(204,204,204,0.5) ; */ -} - -/* leftBar */ -.leftBar { - /* */ -} - -.leftBarTable { - /* */ -} - -.leftBarTableTD { - /* */ -} - -.leftBarTableBlank { - /* */ -} - -.thc { - padding-bottom: 10px; - font-weight: normal; -} - -.formLabel, -.formLabelRequired, -.formSublabel { - text-align: left; /* vertical-align: text-top; */ - white-space: nowrap; -} - -.formLabelRequired b { - color: #cc0000; /* font-size: 1.2em ; */ -} - -.formLabelRequiredStatement { - color: #555555; - font-style: italic; -} - -tr.requirementStatement { - font-size: 0.875em; -} - -td.requirementStatement { - padding-left: 3px; -} - -td.newProjectSpacer { - height: 10px; -} - -span.noteRequired { - font-weight: bold; - color: #cc0000; -} - -span.noteOptional { - font-weight: bold; - color: #000055; -} - -input.requiredField { - padding: 3px 5px 2px 4px; - border: 1px solid #cc0000; -} - -input.title, -input.project_title { - width: auto; -} - -input.abbreviation { - width: auto; - padding-right: 4px; -} - -div.icon-remove { - width: 16px; - height: 16px; - background-position: 0 -1099px; -} - -input.invalid { - background: #ffc; -} - -.summary h3 { - line-height: 15px; - margin: 0 !important; - padding: 3px 0 !important; -} - -/* -.ie7 .containerBody, -.ie7 .containerBody > div { height: auto !important ; overflow: auto !important ; } -*/ - -#min_projects_list, -#min_expt_list { - min-height: 350px; - max-height: 700px; - overflow-y: scroll; -} - -/* -.ie7 #min_projects_list > div, -.ie7 #min_expt_list > div { height: auto ; overflow: visible ; } -*/ -#min_projects_list { /* min-width: 409px ; min-height: 350px ; */ -} - -/* -.ie7 #min_projects_list, -.ie7 #min_expt_list { width: auto ; } -*/ -#min_expt_list { /* min-width: 289px ; */ -} - -/* RESET THE ACTIONS MENU */ -#actionsMenu, #actionsMenu * { - height: auto !important; - margin: 0; - padding: 0; - font-size: 12px; - font-weight: bold; - background: #fff; -} - -/* REBUILD THE ACTIONS MENU */ -#actionsMenu { /* border: 1px solid #eee ; */ -} - -#actionsMenu ul { - list-style: none !important; - border-color: #ddd; -} - -#actionsMenu .bd ul { - padding: 2px 0; -} - -#actionsMenu .bd ul ul { - min-width: 100px; - max-width: 200px; - max-height: 300px; - overflow-x: hidden; - overflow-y: auto; -} - -#actionsMenu .ic, -#actionsMenu .ic_spacer, -#actionsMenu .topscrollbar, -#actionsMenu .bottomscrollbar { - display: none !important; - visibility: hidden !important; -} - -#actionsMenu > .bd { - width: 180px; -} - -#actionsMenu > .bd > .first-of-type { - padding: 0; -} - -#actionsMenu > .bd > .first-of-type a { - padding: 6px 8px; - font-weight: bold; - background: #1A75BB; - color: #fff; -} - -#actionsMenu > .bd > .first-of-type a:hover { - cursor: default; -} - -#actionsMenu li a { - padding: 4px 8px; -} - -#actionsMenu li a:hover { - cursor: pointer; - background-color: #e5f2ff; -} - -#actionsMenu li.yuimenuitem-hassubmenu > a { - background: transparent url('../images/menuitem_submenuindicator.png') right center no-repeat; -} - -#actionsMenu li.yuimenuitem-hassubmenu > a:hover { - background-color: #e5f2ff; -} - -#actionsMenu .yui-menu-body-scrolled { - overflow: auto; - height: auto !important; -} - -/* ADD EXPERIMENT PAGE */ -#add_experiment #breadcrumbs { - margin-bottom: 10px; -} - -#add_experiment #form1 * { - font-size: 13px !important; -} - -#add_experiment #form1 p { - margin-bottom: 10px; -} - -#add_experiment #form1 table { - border: none; - font-size: 13px; -} - -#add_experiment #form1 td { - padding: 0; -} - -#add_experiment #form1 .label { - display: inline-block; - width: 76px; - font-weight: bold !important; - color: #000; -} - -#add_experiment #form1 #expt_list { - width: 550px; -} - -#add_experiment #form1 #expt_list #expt_list_filter { - padding: 4px 16px; - background: #f3f3f3; -} - -#add_experiment #form1 #expt_list #expt_list_filter input { - font-size: 12px !important; - color: #b0b0b0; -} - -#add_experiment #form1 #expt_list #expt_list_filter #filter_clear { - padding: 3px 8px; - color: #333; /* background: #e5f2ff ; */ - border: 1px solid #b0b0b0; -} - -#add_experiment #form1 #expt_list .label { - width: 100%; -} - -#add_experiment #form1 #expt_list .label i { - display: block; - margin-top: 3px; - font-size: 12px; - font-style: normal; - color: #888; -} - -#add_experiment #form1 #expt_list .rows { - margin-top: 8px; - border: 1px solid #ccc; -} - -#add_experiment #form1 #expt_list .rows h4, -#add_experiment #form1 #expt_list .rows p { - margin: 2px 0; - padding: 0; - color: #666; -} - -#add_experiment #form1 #expt_list h4 a { - font-weight: bold !important; /* line-height: 18px; */ - text-decoration: underline; -} - -#add_experiment #form1 #expt_list div.row { - display: none; - margin: 0; - padding: 12px 16px; - background: #fff !important; - border-top: 1px solid #ddd; -} - -#add_experiment #form1 #expt_list div.row:hover { - cursor: pointer; - background: #e5f2ff !important; -} - -/* for filter */ -#add_experiment #form1 #expt_list div.row.show, -#add_experiment #form1 #expt_list div.row.match { - display: block; - visibility: visible; -} - -/* POP-UP ELEMENTS */ -body #timeout_dialog_wrapper { - z-index: 999990 !important; -} - -body #session_timeout_dialog_mask { - z-index: 999991 !important; -} - -body #session_timeout_dialog_c { - z-index: 999992 !important; -} - -body #session_timeout_dialog { - width: 396px !important; - line-height: 1.5; - z-index: 999999 !important; -} - -body #fileListing_mask { - z-index: 2001 !important; -} - -body #fileListing_c { - z-index: 2002 !important; -} - -body #fileListing { - z-index: 2003 !important; -} - -body #file_remove_confirm_mask { - z-index: 2004 !important; -} - -body #file_remove_confirm_c { - z-index: 2005 !important; -} - -body #file_remove_confirm { - z-index: 2006 !important; -} - -body #fileUploadDialog_mask { - z-index: 2101 !important; -} - -body #fileUploadDialog_c { - z-index: 2102 !important; -} - -body #fileUploadDialog { - z-index: 2103 !important; -} - -body #fileUploadDialog fieldset { - padding: 5px 8px; - border: 1px solid #dedede; -} - -body #fileUploadDialog h3 { - padding-bottom: 5px; /* margin-bottom: 8px !important ; */ /* border-bottom: 1px solid #dedede ; */ - font-size: 13px; -} - -body #rest_deleter_mask { - z-index: 2201 !important; -} - -body #rest_deleter_c { - z-index: 2202 !important; -} - -body #rest_deleter { - z-index: 2203 !important; -} - -span.close { - position: relative; - left: 2px; - top: 2px; -} - -.yui-dt-button img { - position: relative; - top: 2px; -} - -.ie .yui-dt-button img { - top: 1px; -} - -/* #layout_content form * { font-weight: normal !important ; } */ -#layout_content form * b { - font-weight: bold !important; -} - -#layout_content form * b u { - font-weight: bold !important; - text-decoration: underline; -} - -/* #expts_header .alts { float:right;position:relative;bottom:4px; } */ -#expts_container, .expts_container { - display: inline-block; - width: auto; -} - -#expts_link_legend, .legend { - min-width: 505px; - margin-bottom: 10px; -} - -#expts_link_legend #expts_header, -.legend .header { - display: inline-block; /* float: left ; */ - min-width: 220px; - padding-left: 5px; - font-size: 15px; - font-weight: bold; -} - -/* #expts_link_legend #view_all_link, */ -#expts_link_legend #toggle_expts_link, -#expts_link_legend #expt_shared_legend, -#expts_link_legend #expt_denied_legend { - float: right; - padding: 0 3px; - font-size: 12px; - font-weight: normal; -} - -#expts_link_legend #expt_shared_legend { - /* */ -} - -#expts_link_legend #expt_denied_legend { - /* */ -} - -#proj_expts td, #all_expts td, -.expts_container td { - padding: 2px 20px 2px 5px; - min-width: 80px; -} - -#proj_expts td a, #all_expts td a { - text-decoration: underline; -} - -.yui-pg-container { - font-size: 12px !important; -} - -.yui-calcontainer { - z-index: 2201; -} - -#downloadForm .withColor { - min-width: 200px; - color: #000; - background: #f0f0f0; - border: 1px solid #ccc; -} - -#downloadForm #subTableSessions tr { - background: #f0f0f0; - border: none; -} - -/* "No more wire inline font-size styles!" */ -.smallest_text, .ie .smallest_text, -.smaller_text, .ie .smaller_text, -.small_text, .ie .small_text { - font-size: 11px !important; - line-height: 15px !important; -} - -/* begin defining defaults for Add Experiment page */ -.add_experiment_form { - /* */ -} - -.add_experiment_form .results_summary { - /* */ -} - -.report_results { - border: 1px solid #ccc; -} - -.report_results td, .report_results th { - padding: 8px 12px; - border-bottom: 1px solid #ccc; -} - -.report_results th { - font-size: 15px; - background: #f0f0f0; -} - -.report_results td:nth-child(3) { - text-align: center; - font-size: 15px; - font-weight: bold; -} - -/* results summary for experiment submissions */ -.results_summary > * { - padding: 10px 6px; - font-size: 15px; - background: #f0f0f0; -} - -.results_summary th, -.results_summary td { - outline: none; - border: 4px solid #f0f0f0; -} - -.results_summary td { - background: #fff; - text-align: center; -} - -/* ////////// styles for tooltips ////////// */ - -/* icon and text tooltip common styles */ -.tip_text, -.tip_icon { - display: inline-block; - position: relative; - overflow: visible; -} - -.tip_text:hover, -.tip_icon:hover { - cursor: help; -} - -/* the tooltip box common styles */ -.tip_text .tip, -.tip_icon .tip { - display: none; - width: 400px; - padding: 9px 12px; - position: absolute; - left: 20px; - top: -5px; - font-size: 11px; - line-height: 14px; - text-align: left; - color: #666; - background: #ffffd0; - border: 1px solid #ccc; -} - -.tip_text:hover .tip, -.tip_icon:hover .tip { - display: block; - z-index: /* 11 */ 3000; -} - -/* tooltip using text */ -.tip_text { - font-weight: normal; - border-bottom: 1px dotted #888; -} - -.tip_text .tip { - left: 80px; -} - -/* tooltip using icon styles */ -.tip_icon { - width: 14px; - height: 14px; - left: 4px; - top: 3px; - background: transparent url('../images/qm.gif') center center no-repeat; -} - -.tip_icon .tip { - /* */ -} - -.tip_icon.note { - width: 16px; - height: 16px; - background-image: url('../images/notes.gif'); -} - -.tip_icon.note .tip { - font-size: 12px; - line-height: 15px; - color: #333; - background-color: #f0f0f0; -} - -.yui-skin-sam .yui-ac-input { - width: auto !important; -} - -#labelDialog { - height: auto !important; -} - -#labelDialog .bd { - height: auto !important; -} - -div.extension { - background-color: #FF9; -} - -div.extension_js { - background-color: #FF9; -} - -.yui-navset .yui-nav { /* height: 28px ; overflow: hidden !important ; */ /* white-space: nowrap !important ; */ -} - -.yui-navset .yui-nav li select { - position: relative; - top: -2px; - left: -3px; -} - -.yui-navset.wrangled ul.yui-nav li { - white-space: nowrap; -} - -body.popup .yui-navset.wrangled { - margin: 0 auto; -} - -#tab_module ul.yui-nav li { - height: 28px; - overflow: hidden; -} - -#tab_module ul.yui-nav li.selected { - height: 29px; -} - -#tab_module ul.yui-nav select { - font-size: 11px !important; - font-weight: normal !important; -} - -/* 'fix' for pseudo-YUI tabs */ -.yui-skin-sam .yui-navset.bogus-tabs .yui-nav li, -.yui-skin-sam .yui-navset.bogus-tabs .yui-navset-top .yui-nav li, -.yui-skin-sam .yui-navset.bogus-tabs .yui-nav .selected, -.yui-skin-sam .yui-navset.bogus-tabs .yui-navset-top .yui-nav .selected { - margin-right: -1px; -} - -.totals { - position: relative; - padding-top: 10px; -} - -input::-ms-clear { - width: 0; - height: 0; -} - -/* gets rid of the 'clear' button in IE 10+ */ - -.cornflower_border { - border: /* 1px solid #6D99B6 */ none; -} - -.cornflower_border_bottom { - border-bottom: 1px solid #6D99B6; -} - -/* moving scans.css here */ -td.quality-usable { - color: green; - font-weight: bold; -} - -td.quality-questionable { - color: orange; - font-weight: bold; -} - -td.quality-unusable { - color: red; - font-weight: bold; -} - -#scan_list { - /* */ -} - -#scan_list tr { - /* */ -} - -#scan_list th { - padding: 1px 10px 1px 5px; -} - -#scan_list td { - padding: 0 10px 0 5px; -} - -#scan_list table { - width: 100%; - margin-bottom: 10px; - padding-bottom: 10px; - border-bottom: 2px solid #d0d0d0; -} - -#scan_list table tr { - /* */ -} - -#scan_list table th { - /* */ -} - -#scan_list table td { - /* */ -} - -/* not sure what these spacers do but pretty sure they should go away - let's see what breaks */ -span.spacer { - display: none !important; -} - -/* configuration tabs */ -.mgmt_container { - padding: 10px; -} - -.mgmt_container p, -.mgmt_container .row { - margin-bottom: 15px; - padding-bottom: 15px; - border-bottom: 1px solid #ccc; -} - -.mgmt_container label { - display: inline-block; - width: 160px; - font-weight: bold; -} - -.mgmt_container small { - display: block; - margin-top: 5px; - font-size: 12px !important; -} - -.mgmt_container input[type="text"] { - padding: 2px 6px 1px 5px; - vertical-align: bottom; -} - -.mgmt_container textarea { - width: 100%; -} - -.mgmt_container .buttons { - margin-top: -5px; - text-align: right; -} - -/* per-tab customizations */ -.mgmt_container #anonymization_mgmt_div p, -.mgmt_container #applet_mgmt_div p { - padding-bottom: 0; - border: none; -} - -.mgmt_container #notifications_mgmt_div th, -.mgmt_container #notifications_mgmt_div td { - padding: 5px 0; -} - -.mgmt_container #notifications_mgmt_div th { - padding-right: 10px; -} - -/* styling for "xnat-table" table */ -.xnat-table { - background: #fff; - border-spacing: 0; - border: 1px solid #aaa; -} - -.xnat-table th, -.xnat-table td { - padding: 6px 12px; - border: 1px solid #ccc; - border-top: none; - border-left: none; -} - -.xnat-table th { - vertical-align: middle; - font-size: 12px; - font-weight: normal; - text-align: center; - white-space: nowrap; - background: #d8d8d8 url('../images/nav_bkgd.png') left top repeat-x; - border-color: #aaa; -} - -.xnat-table td { - vertical-align: middle; - text-align: left; -} - -.xnat-table td.checkbox { - padding: 0; - text-align: center; -} - -.xnat-table td.checkbox label { - display: block; - padding: 6px 12px; -} - -.xnat-table td.checkbox label:hover { - cursor: pointer; -} - -.xnat-table td.checkbox label:hover input[type="checkbox"], -.xnat-table td.checkbox input[type="checkbox"]:hover { - cursor: pointer; - box-shadow: 0 0 5px rgba(8, 80, 180, 0.5); -} - -.xnat-table td.checkbox input[type="checkbox"]:active { - box-shadow: 0 0 5px rgba(8, 80, 180, 1); -} - -.xnat-table th:last-of-type, -.xnat-table td:last-of-type { - border-right: none; -} - -.xnat-table tr:last-of-type td { - border-bottom: none; -} - -.xnat-table tr.highlight:hover { - background: #e5f2ff; -} - -.xnat-table .top { - vertical-align: top; -} - -.xnat-table .middle { - vertical-align: middle; -} - -.xnat-table .bottom { - vertical-align: bottom; -} - -.xnat-table .left { - text-align: left !important; -} - -.xnat-table .center { - text-align: center !important; -} - -.xnat-table .right { - text-align: right !important; -} - -/* override .even and .odd styles - these are not needed in .xnat-table tables */ -.xnat-table .even, -.xnat-table .odd { - background: #fff; - border: none; -} - -/* alternate styling options for "xnat-table" tables */ -.xnat-table.alt1 { - border-color: #d0d0d0; -} - -.xnat-table.alt1 th { - background: #f0f0f0; - text-align: left; - font-weight: bold; -} - -.xnat-table.alt1 th, -.xnat-table.alt1 td { - border-color: #d0d0d0; -} - -.xnat-table.rows-only th, -.xnat-table.rows-only td { - border-left: none; - border-right: none; -} - -.xnat-table.clean th { - border-right: none; -} - -.xnat-table.clean td { - border: none; -} - -.xnat-table.clean tr:hover { - background: #e5f2ff; -} - -/* overrides for Chosen menus (if used) */ -html .chosen-container-single .chosen-single { - color: #000; -} - -/* fix for #layout_content being rendered in an xmodal modal */ -div.xmodal #layout_content { - padding-top: 0; -} - -/* prearchive file list modal */ -table.file-details { - margin-top: -5px; -} - -table.file-details th, -table.file-details td { - padding: 3px 5px; - white-space: nowrap; -} - -/*table.file-details td { border-right: 1px solid #d0d0d0 ; }*/ -table.file-details td.scan-image-link { - max-width: 275px; - overflow: hidden; -} - -table.file-details td.scan-image-size { - font-family: Courier, monospace; - font-size: 13px; -} - -table.file-details td.scan-image-buttons { - border: none; -} - -/* 'Administer' pages */ -#admin-nav { - margin: 0 0 10px 20px; - background: #f0f0f0; - border: 1px solid #ccc; - border-collapse: collapse; -} - -#admin-nav td { - padding: 0; - font-weight: bold; -} - -#admin-nav td b { - font-weight: inherit; -} - -#admin-nav b, -#admin-nav a { - display: inline-block; - float: left; - padding: 6px 12px; -} - -#admin-nav a:hover { - color: #222; - background: #e8e8e8; -} - -#admin-nav .active { - color: #fff; - background: #1A75BB; - border: 1px solid #293D66; -} - -.admin-content { - margin: 20px; -} - -.admin-content .header { - margin: 20px 2px 10px; -} - -.admin-content .header b { - font-size: 15px; -} - -.admin-content .header i { - margin: 0 10px; - color: #ccc; - font-weight: normal; - font-style: normal; -} - -.admin-content .data-table th .sortheader { - position: relative; - padding: 0 12px; - color: #000; -} - -.admin-content .data-table th .sortarrow[sortdir] { - display: inline-block; - position: absolute; - right: 0; - opacity: 0.3; -} - -.admin-content .data-table th .sortarrow img { - width: 9px; -} - -.admin-content .data-table th .sortarrow img[src*="arrow-none"] { - display: none; -} - -.admin-content .data-table input[type="text"] { - padding: 3px 5px; - border: 1px solid #d0d0d0 -} - -#edit-user-details { - margin: 0 10px; -} - -body.popup #edit-user-details { - margin: 0 auto; -} - -#edit-user-details th { - background: #f0f0f0; -} - -#edit-user-details h3 { - padding-left: 10px; - font-weight: inherit; -} - -#edit-user-details th, -#edit-user-details td { - padding: 8px 4px; -} - -#edit-user-details .label { - text-align: right; - font-weight: bold; -} - -#edit-user-details input[type="text"], -#edit-user-details input[type="password"] { - padding: 4px; -} - -/* Data Types page */ -#data-type-table th, -#data-type-table td { - padding: 6px 4px; -} - -#data-type-table .data-type-link { - padding: 0 6px; - font-weight: bold; -} - -/* Advanced Search wizard pages */ -form.search-wizard { - min-width: 720px; - max-width: 720px; -} - -/* Step-by-step numbers */ -.steps { - padding: 0; - list-style: none; -} - -.steps > li { - padding: 0 20px 20px 40px; - margin-bottom: 20px; - background: url('../images/_.gif') 0 0 no-repeat; - border-bottom: 1px solid #ccc; -} - -.steps > li > h3 { - line-height: 30px; - vertical-align: middle; -} - -.steps > li > p { - margin: 10px 0 15px; -} - -.steps > li.step1 { - background-image: url('../images/number_1.gif'); -} - -.steps > li.step2 { - background-image: url('../images/number_2.gif'); -} - -.steps > li.step3 { - background-image: url('../images/number_3.gif'); -} - -.steps > li.step4 { - background-image: url('../images/number_4.gif'); -} - -.steps > li.step5 { - background-image: url('../images/number_5.gif'); -} - -/* Advanced Search tabs */ -.advanced-search-fields { - position: relative; - margin: 10px; - font-size: 13px; - line-height: 15px; -} - -.advanced-search-fields table td { - padding: 0 8px 0 0; - vertical-align: top; -} - -.advanced-search-fields h4 { - margin: 15px 0 5px 0; - font-size: 13px; - border-bottom: 1px solid #ccc; -} - -.advanced-search-fields h5 { - margin: 5px 0 2px; - font-size: 13px; - font-weight: normal; -} - -.advanced-search-fields div.search-group { - float: left; - margin-bottom: 10px; - overflow: visible; -} - -.advanced-search-fields div.search-group.by-criteria { - max-width: 60%; -} - -.advanced-search-fields div.search-group.by-id { - max-width: 30%; -} - -.advanced-search-fields div.search-group.by-id > select { - margin-top: 10px; -} - -.advanced-search-fields div.search-group h3 { - margin-bottom: 5px; -} - -.advanced-search-fields div.search-group .disabled { - opacity: 0.5; -} - -.advanced-search-fields textarea.exact-ids { - display: block; - margin-top: 5px; -} - -.advanced-search-fields .search-item { - /* generic search item */ - display: inline-block; - float: left; - height: 50px; - margin: 0 5px 0 0; - padding: 0 10px 0 0; - overflow: visible; - white-space: nowrap; -} - -.advanced-search-fields.autogen .search-item { - /*min-width: 160px;*/ - max-width: 200px; -} - -label.search-method-label { - padding: 2px 12px 2px 10px; -} - -/* date range input */ -.date-range { - white-space: nowrap; -} - -/* friendlyForm styles. Taken from ConnectomeDB. To be refactored / replaced in XNAT 1.7, most likely */ -fieldset, -.friendlyForm fieldset { - border: solid #e4efff; - border-width: 4px 0 0; - margin: 1em 0; - padding: 1em 0; -} - -.friendlyForm fieldset.error { - background-color: #fffcc9; - border-color: #cc9; - color: #d40000; -} - -.friendlyForm p { - line-height: 1.4em !important; - margin-bottom: 1em; - position: relative; -} - -.friendlyForm h4 { - border-bottom: 1px solid #999; - font-size: 14px; - font-weight: bold; - margin-top: 1em; - padding-bottom: 6px; -} - -.friendlyForm label { - color: #777; - display: block; - font-size: 12px !important; - font-weight: bold; - text-transform: uppercase; -} - -.friendlyForm input[type=text], -.friendlyForm input[type=password], -.friendlyForm input[type=file], -.friendlyForm textarea, -.friendlyForm select { - font-size: 14px !important; - padding: 6px; - width: 96%; -} - -.friendlyForm input[type=file] { - border: 1px solid #e0e0e0; - border-radius: 3px; - margin: 1em 0; - margin-bottom: inherit; - padding: 1em; -} - -.inputWrapper { - background-color: #f0f0f0; - border: 1px solid #ccc; - margin-bottom: 2em; - padding: 20px 0; - position: relative; -} - -.inputWrapper.horizontal { - display: inline-block; - vertical-align: top; - width: 350px; -} - -.inputWrapper.highlighted { - background-color: #e4efff; -} - -.inputWrapper.error { - border: none; - padding: 6px; - position: relative; - top: 0; - left: 0; - width: inherit; /* override other .error styles */ -} - -.inputWrapper.error, -.inputWrapper table tr.error { - background-color: #fde; -} - -.inputWrapper.wide { - width: 600px; -} - -.inputWrapper.error h3, -.inputWrapper.error ul { - margin-left: 30px !important; -} - -.friendlyForm p.error { - color: #c33; - font-size: 12px !important; - font-weight: bold; -} - -.inputWrapper label { - color: #37c; -} - -.inputWrapper input[type=text], -.inputWrapper input[type=password], -.inputWrapper textarea { - width: 330px; -} - -.inputWrapper.wide input[type=text], -.inputWrapper.wide input[type=password], -.inputWrapper.wide textarea { - width: 600px; -} - -.inputWrapper input:read-only { - background-color: #f0f0f0; - color: #999; -} - -.inputWrapper .helptext, -.inputWrapper .helptext-error { - color: #888; - font-size: 12px; - line-height: 14px; - position: absolute; - bottom: 18px; - left: 425px; -} - -.inputWrapper.wide .helptext, -.inputWrapper.wide .helptext-error { - padding-top: 4px; - position: inherit; - bottom: inherit; - left: inherit; -} - -.inputWrapper table { - border: 1px solid #ccc; - border-collapse: collapse; -} - -.inputWrapper td, .inputWrapper th { - padding: 3px; -} - -.inputWrapper td { - border-top: 0; -} - -.inputWrapper th { - text-align: left; - background-color: #f3f3f3; -} - -p.form-submit { - font-size: 12px !important; - text-align: right; -} - -.form-submit input, -.request-access input, -.overlay-action input { - font-size: 16px !important; - padding: 6px 12px; -} - -.request-access input { - float: right; -} - -.friendlyForm .inputWrapper { - background-color: #fff; - border: none; -} - -.friendlyForm.mini .inputWrapper { - padding: 10px; -} - -.friendlyForm.mini label { - display: inline-block; - width: 200px; - text-transform: inherit; -} - -.friendlyForm.mini input[type=text], -.friendlyForm.mini input[type=password], -.friendlyForm.mini input[type=file], -.friendlyForm.mini textarea { - font-size: 12px !important; - padding: 3px; - width: inherit; -} - -.friendlyForm.mini .dataTable label { - width: 100px; -} - -label.disabled { - color: #a0a0a0; - font-weight: normal; -} - -/* prearchives.css */ -/***********************************************/ -div.instructions { - width: 80%; - margin: 1em; -} - -div.instructions p { - margin-bottom: 1em; -} - -div.prearcs { - width: 85%; - height: 400px; - margin-top: 2em; - margin-bottom: 2em; -} - -div.inbox div.content table { - width: 100%; - padding: 0.5em; - padding-top: 0; - padding-bottom: 0; -} - -div.inbox div.actions { - padding-bottom: 0.5em; - margin: 0.5em; - margin-top: 0; -} - -div.inbox div.actions input { - float: right; -} - -div.inbox div.importlog { - margin: 1em; - padding: 0.5em; - height: 100px; - overflow: auto; - border: 2px solid green; -} - -div.inbox div.importlog p { - margin-left: 1em; - margin-right: 1em; - margin-top: 0.25em; - margin-bottom: 0.25em; -} - -div.inbox div.importlog p.header { - font-size: larger; - font-weight: bolder; -} - -div.inbox div.importlog p.processing { - /* */ -} - -div.inbox div.importlog p.warning { - background: #ccccff; -} - -div.inbox div.importlog p.failed { - background: #ff6666; -} - -div.inbox div.importlog p.completed { - background: #ccffcc; -} - -div.prearc-select { - text-align: center; -} - -div.prearc-select select { - margin: 1em; -} - -div.prearc { - width: 100%; - height: 100%; - border: 1px solid #000000; - padding: 0.5em; - overflow: auto; -} - -table.prearc { - width: 100%; - padding: 0.5em; - padding-top: 0; -} - -div.match-op { - width: 80%; - padding: 1em; - text-align: right; -} - -/* Sessions get background color indicating status */ -div.instructions div.colorkey { - width: 100%; - text-align: center -} - -div.instructions div.colorkey span { - text-align: center; - padding-left: 1em; - padding-right: 1em; -} - -table.prearc tr.RECEIVING { - background: #ccccff; -} - -div.colorkey span.RECEIVING { - background: #ccccff; -} - -table.prearc tr.BUILDING { - background: #ffccff; -} - -div.colorkey span.BUILDING { - background: #ffccff; -} - -/* table.prearc tr.READY { } */ -table.prearc tr.ARCHIVING { - background: #ccffff; -} - -div.colorkey span.ARCHIVING { - background: #ccffff; -} - -table.prearc tr.ERROR { - background: #ff6666; -} - -div.colorkey span.ERROR { - background: #ff6666; -} - -/* scans.css */ -/***********************************************/ -td.quality-usable { - color: green; - font-weight: 700 -} - -td.quality-questionable { - color: orange; - font-weight: 700 -} - -td.quality-unusable { - color: red; - font-weight: 700 -} - -/* uploaded.css */ -/***********************************************/ -div.submit div.actions { - text-align: center; -} - -hr { - margin: 2em 0; -} diff --git a/src/main/webapp/xnat-templates/screens/Basic.vm b/src/main/webapp/xnat-templates/screens/Basic.vm index 98eb09a9107efaa28f6ac5016efb7c652a00d4d0..a1babb6560413d36190b2911d157b678ba67c25c 100644 --- a/src/main/webapp/xnat-templates/screens/Basic.vm +++ b/src/main/webapp/xnat-templates/screens/Basic.vm @@ -1,10 +1,5 @@ ## There's not a Java class file for this template yet. -###* @vtlvariable name="displayManager" type="org.nrg.xdat.display.DisplayManager" *# -###* @vtlvariable name="par_count" type="java.lang.Integer" *# ###* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# -###* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# -###* @vtlvariable name="siteConfig" type="java.util.Properties" *# -###* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# #set ($template = $data.getTemplateInfo()) $!template.setLayoutTemplate("Basic.vm") <head> diff --git a/src/main/webapp/xnat-templates/screens/CompressedUploaderPage.vm b/src/main/webapp/xnat-templates/screens/CompressedUploaderPage.vm new file mode 100644 index 0000000000000000000000000000000000000000..cdb8ad38200732062534a8120c6c8c2fd2226569 --- /dev/null +++ b/src/main/webapp/xnat-templates/screens/CompressedUploaderPage.vm @@ -0,0 +1,579 @@ +<script type="text/javascript"> + function disableForm(theform) { + if (document.getElementById) { + document.getElementById('progressBar').style.display = 'block'; + } + else if (document.all) { + document.all['progressBar'].style.display = 'block'; + } + + if (document.all || document.getElementById) { + for (i = 0; i < theform.length; i++) { + var tempobj = theform.elements[i]; + if (tempobj.type.toLowerCase() == "submit" || tempobj.type.toLowerCase() == "reset" || tempobj.type.toLowerCase() == "button") + tempobj.disabled = true; + } + return true; + } + else { + return true; + } + } + + function enableForm() { + var theform; + if (document.getElementById) { + theform = document.getElementById('uploadFORM'); + } + else if (document.all) { + theform = document.all['uploadFORM']; + } + + if (document.all || document.getElementById) { + for (i = 0; i < theform.length; i++) { + var tempobj = theform.elements[i]; + if (tempobj.type.toLowerCase() == "submit" || tempobj.type.toLowerCase() == "reset" || tempobj.type.toLowerCase() == "button") + tempobj.disabled = false; + } + return true; + } else { + return true; + } + } +</script> +<script type="text/javascript"> + var i; + var req; + + var uploadCount = 0; + var extractCount = 0; + var progressBar; + var progressPercent; + var uploadID = "$uploadID"; + var started = 0; + var extractTimeOut = 300; + + function setUploadProgress(i) { + if (i == 0) { + document.getElementById("uploadPercent").innerHTML = ""; + document.getElementById("uploadBar").style.width = 0 + "px"; + } else { + if (i > 100) { + + } else { + var pixels = i * 3; + if (i > 10) { + document.getElementById("uploadPercent").innerHTML = parseInt(i) + "%"; + } + else { + document.getElementById('preparing').innerHTML = ""; + } + document.getElementById("uploadBar").style.width = pixels + "px"; + document.getElementById('preparing').innerHTML = "Loading File... "; + } + } + } + + function setExtractSummary(jsonobj) { + var messages = ""; + try { + var respPos = jsonobj.msgs[0].length - 1; + for (i = 0; i <= respPos; i++) { + var level = jsonobj.msgs[0][i].status; + var message = jsonobj.msgs[0][i].msg; + if (level == "COMPLETED") { + message = "<tr bgcolor='#CCFFCC'><td>" + message; + } else if (level == "PROCESSING") { + message = "<tr bgcolor='#CCFFFF'><td>" + message; + } else if (level == "WARNING") { + message = "<tr bgcolor='#FFCCC'><td>" + message; + } else if (level == "FAILED") { + message = "<tr bgcolor='#FF99CC'><td>" + message; + } else { + message = "<tr bgcolor='#CCCCCC'><td>" + message; + } + messages = messages + message + "</td></tr>"; + } + } catch (e) { + } + document.getElementById("extractSummary").innerHTML = + "<table width='100%' cellpadding='2' cellspacing='0'><tr><th>Extraction / Review summary:</th></tr>" + + messages + + "</table>"; + } + + function toggleExtractSummary() { + if (document.getElementById("extractSummary").style.display == "none") { + document.getElementById("extractSummaryTable").border = "1"; + document.getElementById("extractSummary").style.display = "block"; + } else { + document.getElementById("extractSummaryTable").border = "0"; + document.getElementById("extractSummary").style.display = "none"; + } + } + + function setExtractProgress(i) { + if (i == 0) { + document.getElementById("extractPercent").innerHTML = ""; + document.getElementById("extractBar").style.width = 0 + "px"; + } else { + if (i > 100) { + + } else { + var pixels = i * 3; + if (i > 10) { + document.getElementById("extractPercent").innerHTML = parseInt(i) + "%"; + } + document.getElementById("extractBar").style.width = pixels + "px"; + } + } + } + + function evaluateDestination(ele) { + if (ele.value == '2') { + document.getElementById("auto-archive").value = 'true'; + document.getElementById("quarantine").value = 'true'; + } else if (ele.value == '1') { + document.getElementById("auto-archive").value = 'true'; + document.getElementById("quarantine").value = 'false'; + } else if (ele.value == '0') { + document.getElementById("auto-archive").value = 'false'; + document.getElementById("quarantine").value = 'false'; + } + } + + var checkProgressFinal = 0; + + function prog(theform) { + var imageArchive = document.getElementById("image_archive"); + if (!imageArchive.value) { + xModalMessage('Upload Action', 'Please select an archive to upload.'); + return false; + } + if (!(imageArchive.value.endsWith(".gz") || imageArchive.value.endsWith(".tgz") || imageArchive.value.endsWith(".zip"))) { + xModalMessage('Upload Action', 'Please select a tar or zip archive to upload.'); + return false; + } + if (document.getElementById("project").selectedIndex == 0) { + xModalMessage('Upload Action', 'Please select a $displayManager.getSingularDisplayNameForProject().toLowerCase().'); + return false; + } + disableForm(theform); + document.getElementById("iframe").src = ""; + started = 0; + checkProgressFinal = 0; + progressBar = document.getElementById("uploadBar"); + progressPercent = document.getElementById("uploadPercent"); + + document.getElementById('preparing').style.display = 'block'; + document.getElementById('preparing').innerHTML = "Loading File... "; + setUploadProgress(0); + setExtractProgress(0); + setExtractSummary(""); + resetProgress(); + checkProgress(); + + return true; + } + + function callback() { + if (req.readyState == 4) { + if (req.status == 200) { + started = 1; + // handle response + var respDat = YAHOO.lang.JSON.parse(req.responseText); + var respPos = respDat.msgs[0].length - 1; + var uploadI = 0; + var extractI = 0; + var statusCount = 0; + if (respDat.msgs[0].length > 0) { + if (respDat.msgs[0].length > 0) { + var level = respDat.msgs[0][respPos].status; + var message = respDat.msgs[0][respPos].msg; + } + } + + if (req.responseText.indexOf("file uploaded") >= 0) { + uploadI = 100; + } + if (req.responseText.indexOf("Successfully uploaded") >= 0) { + extractI = 100; + } + if (req.responseText.indexOf("archiving operation complete") >= 0) { + extractI = 100; + } + setExtractSummary(respDat); + setCurrentStep(message); + + //alert("Upload(" + uploadI + "); Extract(" + extractI + ");\r\n" + statusText + "\r\n" + req.responseText); + + if (uploadI == -1) { + document.getElementById('preparing').innerHTML = " <font color=red><B>Error: Upload Failed. Please retry at a later time or contact technical support.</B></font>"; + document.getElementById('preparing').style.display = 'block'; + } else if (extractI == -1) { + document.getElementById('preparing').innerHTML = " <font color=red><B>Error: Extraction/Review Failed. Please verify the integrity of the zipped file and the contained image files.</B></font>"; + document.getElementById('preparing').style.display = 'block'; + } else if (uploadI != 100) { + //upload complete + + if (uploadCount != 98) { + uploadCount = uploadCount + 1; + } + + if (uploadCount > 40) { + extractTimeOut = 600; + } + if (uploadCount > 50) { + extractTimeOut = 800; + } + if (uploadCount > 60) { + extractTimeOut = 1000; + } + if (uploadCount > 70) { + extractTimeOut = 2000; + } + if (uploadCount > 80) { + extractTimeOut = 3000; + } + if (uploadCount > 85) { + extractTimeOut = 6000; + } + if (uploadCount > 88) { + extractTimeOut = 9000; + } + + setUploadProgress(uploadCount); + setExtractProgress(0); + + setTimeout("checkProgress();", extractTimeOut); + } else if (extractI == 100) { + //extract complete + setUploadProgress(100); + setExtractProgress(100); + + setExtractSummary(respDat); + setCurrentStep(message); + if (checkProgressFinal == 0) { + checkProgressFinal = 1; + //check progress one final time to capture final step summary + setTimeout("checkProgress();", 200); + } + } else { + //extract in progress + setUploadProgress(100); + + if (extractCount != 98) { + extractCount = extractCount + 1; + } + if (extractCount < 10) { + extractTimeOut = 500; + } + if (extractCount > 10) { + extractTimeOut = 100; + } + if (extractCount > 20) { + extractTimeOut = 1500; + } + if (extractCount > 30) { + extractTimeOut = 2000; + } + if (extractCount > 50) { + extractTimeOut = 2800; + } + if (extractCount > 60) { + extractTimeOut = 3300; + } + if (extractCount > 70) { + extractTimeOut = 4000; + } + if (extractCount > 80) { + extractTimeOut = 5000; + } + if (extractCount > 85) { + extractTimeOut = 6000; + } + if (extractCount > 88) { + extractTimeOut = 9000; + } + + setExtractProgress(extractCount); + + if (statusCount > 0) { + setExtractSummary(respDat); + setCurrentStep(message); + } + setTimeout("checkProgress();", extractTimeOut); + } + } + } + } + + + function setCurrentStep(message) { + if (message != null && message != undefined) { + document.getElementById("current_step").innerHTML = "<A href='' ONCLICK='toggleExtractSummary();return false;'>" + message + "...</A>"; + } + } + + function resetProgress() { + var url = "$content.getURI("servlet/AjaxServlet")?remote-class=org.nrg.xnat.ajax.UploadProgress"; + url = url + "&remote-method=start"; + url = url + "&ID=" + uploadID; + if (window.XMLHttpRequest) { + req = new XMLHttpRequest(); + } else if (window.ActiveXObject) { + req = new ActiveXObject("Microsoft.XMLHTTP"); + } + req.open("GET", url, true); + req.send(null); + } + + function checkProgress() { + //var url = "$content.getURI("/REST/status/$uploadID")?format=json"; + var url = "$content.getURI("/REST/status/$uploadID")?format=json&stamp=" + (new Date()).getTime(); + if (window.XMLHttpRequest) { + req = new XMLHttpRequest(); + } else if (window.ActiveXObject) { + req = new ActiveXObject("Microsoft.XMLHTTP"); + } + req.open("GET", url, true); + req.onreadystatechange = callback; + req.send(null); + } + function makeTheFormGo() { + var form = document.getElementById("uploadFORM"); + prog(form); + form.submit(); + } +</script> + +<table border="0" cellpadding="5" cellspacing="0"> + <tr> + <td> + <h4> + Compressed upload</h4></td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">Raw image files can be zipped (.zip or .tar.gz) and uploaded using the form. This + tool currently supports DICOM and ECAT files. Selecting 'Prearchive' will place your images into a + temporary holding space. You will then have the ability to review the details and match the data to the + proper $displayManager.getSingularDisplayNameForSubject().toLowerCase() & $displayManager.getSingularDisplayNameForImageSession().toLowerCase() ID. If you are confident the data will be mapped properly, you can directly + 'Archive' the files and specify whether the resulting $displayManager.getSingularDisplayNameForImageSession().toLowerCase() should go into a quarantine state. + </div> + <div class="alert" style="margin:15px 0;max-width:696px;min-width:400px;"> + The compressed uploader does not yet support splitting PET/MR sessions based on the site-wide or + project-specific settings for handling PET/MR data. If you are uploading PET/MR data and need to have + the data split into separate PET and MR sessions or created as a PET session rather than a PET/MR + session, you should use either the <a href="$link.setPage("LaunchUploadApplet.vm")">upload applet</a> or the + DICOM C-STORE receiver as described below. + </div> + </td> + </tr> + <tr> + <td> </td> + </tr> + <tr id="option1"> + <td> + <input type="hidden" name="popup" value="true"/> + <form id="uploadFORM" class="noHide" target="iframe" enctype="multipart/form-data" method="POST" + action="$content.getURI("/REST/services/import?http-session-listener=$uploadID&format=html&XNAT_CSRF=$!XNAT_CSRF")"> + <input type="hidden" name="threshhold" value="51516279"/> + + #if($session) + <input type="hidden" name="EXPT_LABEL" value="$!session.getLabel()"/> + <input type="hidden" name="SUBJECT_ID" value="$!session.getSubjectData().getLabel()"/> + #end + + <table border=0 cellpadding="5" cellspacing="0"> + <tr> + <th align="left">$displayManager.getSingularDisplayNameForProject()</th> + <td> + #if(!$session) + <select id="project" name="project" disabled=true></select> + #else + <input type="hidden" name="project" id="project" + value="$session.getProject()"/>$session.getProject() + #end + </td> + </tr> + + #if($session) + <tr> + <th align="left">$displayManager.getSingularDisplayNameForImageSession()</th> + <td>$!session.getLabel()</td> + </tr> + #end + <tr> + <th align="left">Destination</th> + <td> + <label><input id="pc_0" type='radio' name='prearchive_code' value='0' + #if(!$session)CHECKED#end onchange="evaluateDestination(this)"/> + Prearchive</label> + <label><input id="pc_2" type='radio' name='prearchive_code' value='1' + #if($session)CHECKED#end onchange="evaluateDestination(this)"/> + Archive</label> + #if($session) + <input type="hidden" name="overwrite" value="append"/> + <input type="hidden" id="auto-archive" name='auto-archive' value='TRUE'/> + #else + <input type="hidden" id="auto-archive" name='auto-archive' value='FALSE'/> + #end + <input type="hidden" id="quarantine" name='quarantine' value='FALSE'/> + </td> + </tr> + <tr> + <th align="left">File</th> + <td><input type="file" id="image_archive" name="image_archive" size="60" + accept="application/zip, application/x-gzip, application/x-tgz"/></td> + </tr> + #auditBoxes("3" "" "Standard Upload" "Upload Images") + #hideFormJustification() + <tr> + <td> </td> + <td><input id="directButton" type="button" name="eventSubmit_doPerform" value="Begin Upload" onclick="makeTheFormGo();"/> + </td> + </tr> + </table> + </form> + +<span id="progressBar" style="position:relative; display:none;"> +<div id="ex" style="position:relative;width:468px;background:#eeeeee;border:3px double #000000;"> + <table width="100%"> + <tr> + <td colspan=2 align="left"> + <div id="preparing">Loading File... </div> + </td> + </tr> + <tr> + <td> + <div id="uploadLabel">Upload: </div> + </td> + <td align="center"> + <div id="emptyUpload" + style="background-color:#cccccc;border:1px solid black;height:22px;width:300px;padding:0;" + align="left"> + <div id="uploadBar" + style="position:relative;top:0;left:0;background-color:#333333;height:22px;width:0;padding-top:5px;padding:0;"> + <div id="uploadPercent" + style="position:relative;top:0;left:0;color:#f0ffff;height:22px;text-align:center;font:bold;padding:0;padding-top:5px;"> + </div> + </div> + </div> + </td> + </tr> + <tr> + <td> </td> + </tr> + <tr> + <td> + <div id="extractLabel">Extract/Review: </div> + </td> + <td align="center"> + <div id="emptyExtract" + style="background-color:#cccccc;border:1px solid black;height:22px;width:300px;padding:0;" + align="left"> + <div id="extractBar" + style="position:relative;top:0;left:0;background-color:#333333;height:22px;width:0;padding-top:5px;padding:0;"> + <div id="extractPercent" + style="position:relative;top:0;left:0;color:#f0ffff;height:22px;text-align:center;font:bold;padding:0;padding-top:5px;"> + </div> + </div> + </div> + </td> + </tr> + <tr> + <td colspan=2 align="center"> + <div id="current_step"></div> + </td> + </tr> + </table> +</div> +<br> +<table id="extractSummaryTable" border=0 style="border-collapse: collapse;"> + <tr> + <td> + <span id="extractSummary" + style="position:relative;width:468px;height:100px;display:none;overflow:auto; "></span> + </td> + </tr> +</table> +<br> +<iframe id="iframe" name="iframe" src="" width="468" height="80" frameborder="0"> + PROGRESS BAR DISABLED. <br>Try using a more recent web browser. +</iframe> +</span> + <script type="text/javascript"> + progressBar = document.getElementById("uploadBar"); + progressPercent = document.getElementById("uploadPercent"); + </script> + </td> + </tr> + <tr> + <td> </td> + </tr> + <script type="text/javascript"> + // Adapted from Sun Java Web Start Auto-Install Demo + // http://java.sun.com/developer/technicalArticles/JavaLP/javawebstart/AutoInstallDemo.html + var detect = navigator.userAgent.toLowerCase(); + var windowsIE = (checkPlatform("msie") && checkPlatform("win")); + + function checkPlatform(string) { + place = detect.indexOf(string) + 1; + thestring = string; + return place; + } + </script> +</table> + +#if(!$session) +<script type="text/javascript" src="$content.getURI('scripts/subjectAssessorData/proj_tools.js')"></script> + +<script type="text/javascript"> + //load projects + window.defaultProject = "$!project"; + + window.projectLoader = new ProjectLoader(); + + window.projectLoader.onLoadComplete.subscribe(function () { + renderProjects(document.getElementById("project"), window.projectLoader.list, window.defaultProject); + }); + + document.getElementById("project").onchange = function (o) { + if (this.selectedIndex > 0) { + var s = this.options[this.selectedIndex]; + var pc = document.getElementById("pc_0"); + if (pc != undefined && pc != null) { + if (s.pc == "4") { + if (s.qc == "0") { + document.getElementById("pc_2").click(); + } else { + document.getElementById("pc_1").click(); + } + } else { + document.getElementById("pc_0").click(); + } + } + } + }; + + window.projectLoader.init(); + + function prepApplet(_form) { + return true; + } + + //build breadcrumb + var breadcrumbs = document.getElementById('breadcrumbs'); + + if (breadcrumbs != null) { + var bread = ""; + #if($project) + bread = bread + "<a href='$link.setAction("DisplayItemAction").addPathInfo("search_element","xnat:projectData").addPathInfo("search_field","xnat:projectData.ID").addPathInfo("search_value","$project")'>$displayManager.getSingularDisplayNameForProject().toUpperCase(): $!project</a>"; + bread = bread + " > Upload Images"; + #end + breadcrumbs.innerHTML = bread; + } + +</script> +#end \ No newline at end of file diff --git a/src/main/webapp/xnat-templates/screens/DICOMSCPPage.vm b/src/main/webapp/xnat-templates/screens/DICOMSCPPage.vm new file mode 100644 index 0000000000000000000000000000000000000000..e40241f0258ab0614c33340fccb828eea73f8304 --- /dev/null +++ b/src/main/webapp/xnat-templates/screens/DICOMSCPPage.vm @@ -0,0 +1,24 @@ +<table> +<tr> + <td> + <h4>DICOM C-STORE Service Class User</h4> + </td> +</tr> +<tr> + <td valign="top" align="left"> + <div style="width:500px">Any DICOM C-STORE SCU, including scanner consoles or DICOM applications like + <a href="http://www.osirix-viewer.com">OsiriX</a> or <a href="http://nrg.wustl.edu/software/dicom-browser">DicomBrowser</a>, + can send files directly to this server. + </div> +</tr> +<tr id="option4"> + <td> + <br><b>DICOM C-STORE receiver (SCP) Specifications</b> + <ul> + <li>Host Name: $!arc.getDcm_dcmHost()</li> + <li>Port: $!arc.getDcm_dcmPort()</li> + <li>AE Title(s): $!arc.getDcm_dcmAe()</li> + </ul> + </td> +</tr> + </table> \ No newline at end of file diff --git a/src/main/webapp/xnat-templates/screens/Index.vm b/src/main/webapp/xnat-templates/screens/Index.vm index b3be92bbd689868928d6ea0410084925eb9df6b5..e2ed210c971241742bd3b68897fb84779807f09e 100644 --- a/src/main/webapp/xnat-templates/screens/Index.vm +++ b/src/main/webapp/xnat-templates/screens/Index.vm @@ -3,7 +3,7 @@ #* @vtlvariable name="par_count" type="java.lang.Integer" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# #set ($template = $data.getTemplateInfo()) #if($data.getParameters().getString("login").equals("true")) diff --git a/src/main/webapp/xnat-templates/screens/Login.vm b/src/main/webapp/xnat-templates/screens/Login.vm index 10ddc6ef72f44ab0a4fabae3d31e660404f520c7..5dd17f54993edd06ae7481e123756854d68191a6 100644 --- a/src/main/webapp/xnat-templates/screens/Login.vm +++ b/src/main/webapp/xnat-templates/screens/Login.vm @@ -2,7 +2,7 @@ #* @vtlvariable name="method" type="java.lang.String" *# #* @vtlvariable name="login_methods" type="java.util.List" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# #* @vtlvariable name="page" type="org.apache.turbine.util.template.HtmlPageAttributes" *# #* @vtlvariable name="ui" type="org.apache.turbine.services.pull.util.UIManager" *# diff --git a/src/main/webapp/xnat-templates/screens/Page.vm b/src/main/webapp/xnat-templates/screens/Page.vm index 18c7aaa7e9cb85b71e8c385677c9447e5d644287..729980183bc89bfa1daa381a0ab041c78ad3ac1b 100644 --- a/src/main/webapp/xnat-templates/screens/Page.vm +++ b/src/main/webapp/xnat-templates/screens/Page.vm @@ -2,7 +2,7 @@ #* @vtlvariable name="par_count" type="java.lang.Integer" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# <!-- start xnat-templates/screens/Page.vm --> diff --git a/src/main/webapp/xnat-templates/screens/Register.vm b/src/main/webapp/xnat-templates/screens/Register.vm index cdd653d1112210e654df3713442a1574590a12fd..48b117f516e715e57987b7d8a5fd940f28f5c861 100644 --- a/src/main/webapp/xnat-templates/screens/Register.vm +++ b/src/main/webapp/xnat-templates/screens/Register.vm @@ -1,5 +1,5 @@ <!-- BEGIN xnat-templates/screens/Register.vm --> -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="page" type="org.apache.turbine.util.template.HtmlPageAttributes" *# #* @vtlvariable name="ui" type="org.apache.turbine.services.pull.util.UIManager" *# diff --git a/src/main/webapp/xnat-templates/screens/Scripts.vm b/src/main/webapp/xnat-templates/screens/Scripts.vm index 3737ecb0a3cfdb4bf226cfdce6689a4ab634335e..decd810e2b0468c9452ee84ca960a93a9f6983d4 100644 --- a/src/main/webapp/xnat-templates/screens/Scripts.vm +++ b/src/main/webapp/xnat-templates/screens/Scripts.vm @@ -1,6 +1,6 @@ <!-- BEGIN plugin-resources/webapp/xnat-templates/screens/Scripts.vm --> #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="tabs" type="java.util.List<java.util.Properties>" *# diff --git a/src/main/webapp/xnat-templates/screens/UploadApplet.vm b/src/main/webapp/xnat-templates/screens/UploadApplet.vm index b74ab4ca15563f73e31fa70e6b353b6b5d9d3db9..16fdc1372ff1ae97563c719a7334272e0b84eea4 100644 --- a/src/main/webapp/xnat-templates/screens/UploadApplet.vm +++ b/src/main/webapp/xnat-templates/screens/UploadApplet.vm @@ -1,3 +1,9 @@ +#* @vtlvariable name="appletParams" type="java.lang.String" *# +#* @vtlvariable name="expectedModality" type="java.lang.String" *# +#* @vtlvariable name="protocol" type="java.lang.String" *# +#* @vtlvariable name="visit" type="java.lang.String" *# +#* @vtlvariable name="jsessionid" type="java.lang.String" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="session_id" type="java.lang.String" *# #* @vtlvariable name="scan_type" type="java.lang.String" *# #* @vtlvariable name="visit_id" type="java.lang.String" *# @@ -5,7 +11,6 @@ #* @vtlvariable name="subject_id" type="java.lang.String" *# #* @vtlvariable name="project" type="java.lang.String" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# -#* @vtlvariable name="arc" type="org.nrg.xdat.om.ArcArchivespecification" *# <!-- UploadApplet.vm --> <script type="text/javascript" src="https://java.com/js/deployJava.js"></script> <p style="width:760px;margin-bottom:20px;font-size:12px;">This tool supports uploading DICOM and ECAT formatted medical imaging data. If you are unsure of the format of your data, please contact @@ -55,7 +60,7 @@ function loadApplet() { var attributes = { code: 'org.nrg.xnat.upload.ui.UploadAssistantApplet', codebase: '$content.getURI("applet/")', width: 800, height: 500, /* class: 'upload_applet', */ archive: 'upload-assistant__V1.7.0-SNAPSHOT.jar, DicomEdit__V4.0.0.jar, DicomUtils__V1.3.1.jar, antlr-runtime__V3.5.2.jar, commons-codec__V1.10.jar, commons-lang3__V3.4.jar, commons-lang__V2.6.jar, config__V1.7.0-SNAPSHOT.jar, dcm4che-core__V2.0.25.jar, dicom-xnat-sop__V1.7.0-20160210.212402-3.jar, dicom-xnat-util__V1.7.0-20160210.212409-3.jar, dicomtools__V1.7.0-SNAPSHOT.jar, ecat-edit__V0.2.0.jar, ecat-io__V0.1.0.jar, framework__V1.7.0-SNAPSHOT.jar, guava__V19.0.jar, jackson-annotations__V2.6.5.jar, jackson-core__V2.6.5.jar, jackson-databind__V2.6.5.jar, java-uuid-generator__V3.1.3.jar, javax.inject__V1.jar, jcalendar__V1.4.jar, joda-time__V2.1.jar, json__V20151123.jar, log4j__V1.2.17.jar, nrgutil__V1.1.0.jar, slf4j-api__V1.7.7.jar, slf4j-log4j12__V1.7.7.jar, wizard__V1.1.jar' } - var parameters = { 'xnat-url': '$!arc.getSiteUrl()', 'xnat-admin-email': '$!arc.getSiteAdminEmail()', 'xnat-description': '$!arc.getSiteId()', 'n-upload-threads': '4', 'fixed-size-streaming': 'true', 'java_arguments': '-Djnlp.packEnabled=true', 'jsessionid': '$jsessionid'}; + var parameters = { 'xnat-url': '$!siteConfig.getSiteUrl()', 'xnat-admin-email': '$!siteConfig.getAdminEmail()', 'xnat-description': '$!siteConfig.getSiteId()', 'n-upload-threads': '4', 'fixed-size-streaming': 'true', 'java_arguments': '-Djnlp.packEnabled=true', 'jsessionid': '$jsessionid'}; parameters['window-name'] = this.window.name; diff --git a/src/main/webapp/xnat-templates/screens/UploadAssistantPage.vm b/src/main/webapp/xnat-templates/screens/UploadAssistantPage.vm new file mode 100644 index 0000000000000000000000000000000000000000..20c3dc90e3a8c5c655f7ea64de3d734593615342 --- /dev/null +++ b/src/main/webapp/xnat-templates/screens/UploadAssistantPage.vm @@ -0,0 +1,12 @@ +<table> + <tr> + <td> + <h4>Download Upload Assistant application</h4> + </td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">You can download the XNAT Upload Assistant application and use it to upload your session. If the Upload Applet does not work for you, you might want to try this. <a href="https://bitbucket.org/xnatdev/upload-assistant/downloads">Click here</a> to find the appropriate version of the XNAT Upload Assistant application for your operating system. + </div> + </tr> +</table> \ No newline at end of file diff --git a/src/main/webapp/xnat-templates/screens/UploadOptions.vm b/src/main/webapp/xnat-templates/screens/UploadOptions.vm new file mode 100644 index 0000000000000000000000000000000000000000..89b03f05ca54cb4eec243616fd7a21a27629125f --- /dev/null +++ b/src/main/webapp/xnat-templates/screens/UploadOptions.vm @@ -0,0 +1,646 @@ +<script type="text/javascript"> + function disableForm(theform) { + if (document.getElementById) { + document.getElementById('progressBar').style.display = 'block'; + } + else if (document.all) { + document.all['progressBar'].style.display = 'block'; + } + + if (document.all || document.getElementById) { + for (i = 0; i < theform.length; i++) { + var tempobj = theform.elements[i]; + if (tempobj.type.toLowerCase() == "submit" || tempobj.type.toLowerCase() == "reset" || tempobj.type.toLowerCase() == "button") + tempobj.disabled = true; + } + return true; + } + else { + return true; + } + } + + function enableForm() { + var theform; + if (document.getElementById) { + theform = document.getElementById('uploadFORM'); + } + else if (document.all) { + theform = document.all['uploadFORM']; + } + + if (document.all || document.getElementById) { + for (i = 0; i < theform.length; i++) { + var tempobj = theform.elements[i]; + if (tempobj.type.toLowerCase() == "submit" || tempobj.type.toLowerCase() == "reset" || tempobj.type.toLowerCase() == "button") + tempobj.disabled = false; + } + return true; + } else { + return true; + } + } +</script> +<script type="text/javascript"> + var i; + var req; + + var uploadCount = 0; + var extractCount = 0; + var progressBar; + var progressPercent; + var uploadID = "$uploadID"; + var started = 0; + var extractTimeOut = 300; + + function setUploadProgress(i) { + if (i == 0) { + document.getElementById("uploadPercent").innerHTML = ""; + document.getElementById("uploadBar").style.width = 0 + "px"; + } else { + if (i > 100) { + + } else { + var pixels = i * 3; + if (i > 10) { + document.getElementById("uploadPercent").innerHTML = parseInt(i) + "%"; + } + else { + document.getElementById('preparing').innerHTML = ""; + } + document.getElementById("uploadBar").style.width = pixels + "px"; + document.getElementById('preparing').innerHTML = "Loading File... "; + } + } + } + + function setExtractSummary(jsonobj) { + var messages = ""; + try { + var respPos = jsonobj.msgs[0].length - 1; + for (i = 0; i <= respPos; i++) { + var level = jsonobj.msgs[0][i].status; + var message = jsonobj.msgs[0][i].msg; + if (level == "COMPLETED") { + message = "<tr bgcolor='#CCFFCC'><td>" + message; + } else if (level == "PROCESSING") { + message = "<tr bgcolor='#CCFFFF'><td>" + message; + } else if (level == "WARNING") { + message = "<tr bgcolor='#FFCCC'><td>" + message; + } else if (level == "FAILED") { + message = "<tr bgcolor='#FF99CC'><td>" + message; + } else { + message = "<tr bgcolor='#CCCCCC'><td>" + message; + } + messages = messages + message + "</td></tr>"; + } + } catch (e) { + } + document.getElementById("extractSummary").innerHTML = + "<table width='100%' cellpadding='2' cellspacing='0'><tr><th>Extraction / Review summary:</th></tr>" + + messages + + "</table>"; + } + + function toggleExtractSummary() { + if (document.getElementById("extractSummary").style.display == "none") { + document.getElementById("extractSummaryTable").border = "1"; + document.getElementById("extractSummary").style.display = "block"; + } else { + document.getElementById("extractSummaryTable").border = "0"; + document.getElementById("extractSummary").style.display = "none"; + } + } + + function setExtractProgress(i) { + if (i == 0) { + document.getElementById("extractPercent").innerHTML = ""; + document.getElementById("extractBar").style.width = 0 + "px"; + } else { + if (i > 100) { + + } else { + var pixels = i * 3; + if (i > 10) { + document.getElementById("extractPercent").innerHTML = parseInt(i) + "%"; + } + document.getElementById("extractBar").style.width = pixels + "px"; + } + } + } + + function evaluateDestination(ele) { + if (ele.value == '2') { + document.getElementById("auto-archive").value = 'true'; + document.getElementById("quarantine").value = 'true'; + } else if (ele.value == '1') { + document.getElementById("auto-archive").value = 'true'; + document.getElementById("quarantine").value = 'false'; + } else if (ele.value == '0') { + document.getElementById("auto-archive").value = 'false'; + document.getElementById("quarantine").value = 'false'; + } + } + + var checkProgressFinal = 0; + + function prog(theform) { + var imageArchive = document.getElementById("image_archive"); + if (!imageArchive.value) { + xModalMessage('Upload Action', 'Please select an archive to upload.'); + return false; + } + if (!(imageArchive.value.endsWith(".gz") || imageArchive.value.endsWith(".tgz") || imageArchive.value.endsWith(".zip"))) { + xModalMessage('Upload Action', 'Please select a tar or zip archive to upload.'); + return false; + } + if (document.getElementById("project").selectedIndex == 0) { + xModalMessage('Upload Action', 'Please select a $displayManager.getSingularDisplayNameForProject().toLowerCase().'); + return false; + } + disableForm(theform); + document.getElementById("iframe").src = ""; + started = 0; + checkProgressFinal = 0; + progressBar = document.getElementById("uploadBar"); + progressPercent = document.getElementById("uploadPercent"); + + document.getElementById('preparing').style.display = 'block'; + document.getElementById('preparing').innerHTML = "Loading File... "; + setUploadProgress(0); + setExtractProgress(0); + setExtractSummary(""); + resetProgress(); + checkProgress(); + + return true; + } + + function callback() { + if (req.readyState == 4) { + if (req.status == 200) { + started = 1; + // handle response + var respDat = YAHOO.lang.JSON.parse(req.responseText); + var respPos = respDat.msgs[0].length - 1; + var uploadI = 0; + var extractI = 0; + var statusCount = 0; + if (respDat.msgs[0].length > 0) { + if (respDat.msgs[0].length > 0) { + var level = respDat.msgs[0][respPos].status; + var message = respDat.msgs[0][respPos].msg; + } + } + + if (req.responseText.indexOf("file uploaded") >= 0) { + uploadI = 100; + } + if (req.responseText.indexOf("Successfully uploaded") >= 0) { + extractI = 100; + } + if (req.responseText.indexOf("archiving operation complete") >= 0) { + extractI = 100; + } + setExtractSummary(respDat); + setCurrentStep(message); + + //alert("Upload(" + uploadI + "); Extract(" + extractI + ");\r\n" + statusText + "\r\n" + req.responseText); + + if (uploadI == -1) { + document.getElementById('preparing').innerHTML = " <font color=red><B>Error: Upload Failed. Please retry at a later time or contact technical support.</B></font>"; + document.getElementById('preparing').style.display = 'block'; + } else if (extractI == -1) { + document.getElementById('preparing').innerHTML = " <font color=red><B>Error: Extraction/Review Failed. Please verify the integrity of the zipped file and the contained image files.</B></font>"; + document.getElementById('preparing').style.display = 'block'; + } else if (uploadI != 100) { + //upload complete + + if (uploadCount != 98) { + uploadCount = uploadCount + 1; + } + + if (uploadCount > 40) { + extractTimeOut = 600; + } + if (uploadCount > 50) { + extractTimeOut = 800; + } + if (uploadCount > 60) { + extractTimeOut = 1000; + } + if (uploadCount > 70) { + extractTimeOut = 2000; + } + if (uploadCount > 80) { + extractTimeOut = 3000; + } + if (uploadCount > 85) { + extractTimeOut = 6000; + } + if (uploadCount > 88) { + extractTimeOut = 9000; + } + + setUploadProgress(uploadCount); + setExtractProgress(0); + + setTimeout("checkProgress();", extractTimeOut); + } else if (extractI == 100) { + //extract complete + setUploadProgress(100); + setExtractProgress(100); + + setExtractSummary(respDat); + setCurrentStep(message); + if (checkProgressFinal == 0) { + checkProgressFinal = 1; + //check progress one final time to capture final step summary + setTimeout("checkProgress();", 200); + } + } else { + //extract in progress + setUploadProgress(100); + + if (extractCount != 98) { + extractCount = extractCount + 1; + } + if (extractCount < 10) { + extractTimeOut = 500; + } + if (extractCount > 10) { + extractTimeOut = 100; + } + if (extractCount > 20) { + extractTimeOut = 1500; + } + if (extractCount > 30) { + extractTimeOut = 2000; + } + if (extractCount > 50) { + extractTimeOut = 2800; + } + if (extractCount > 60) { + extractTimeOut = 3300; + } + if (extractCount > 70) { + extractTimeOut = 4000; + } + if (extractCount > 80) { + extractTimeOut = 5000; + } + if (extractCount > 85) { + extractTimeOut = 6000; + } + if (extractCount > 88) { + extractTimeOut = 9000; + } + + setExtractProgress(extractCount); + + if (statusCount > 0) { + setExtractSummary(respDat); + setCurrentStep(message); + } + setTimeout("checkProgress();", extractTimeOut); + } + } + } + } + + + function setCurrentStep(message) { + if (message != null && message != undefined) { + document.getElementById("current_step").innerHTML = "<A href='' ONCLICK='toggleExtractSummary();return false;'>" + message + "...</A>"; + } + } + + function resetProgress() { + var url = "$content.getURI("servlet/AjaxServlet")?remote-class=org.nrg.xnat.ajax.UploadProgress"; + url = url + "&remote-method=start"; + url = url + "&ID=" + uploadID; + if (window.XMLHttpRequest) { + req = new XMLHttpRequest(); + } else if (window.ActiveXObject) { + req = new ActiveXObject("Microsoft.XMLHTTP"); + } + req.open("GET", url, true); + req.send(null); + } + + function checkProgress() { + //var url = "$content.getURI("/REST/status/$uploadID")?format=json"; + var url = "$content.getURI("/REST/status/$uploadID")?format=json&stamp=" + (new Date()).getTime(); + if (window.XMLHttpRequest) { + req = new XMLHttpRequest(); + } else if (window.ActiveXObject) { + req = new ActiveXObject("Microsoft.XMLHTTP"); + } + req.open("GET", url, true); + req.onreadystatechange = callback; + req.send(null); + } + function makeTheFormGo() { + var form = document.getElementById("uploadFORM"); + prog(form); + form.submit(); + } +</script> + +<table border="0" cellpadding="5" cellspacing="0"> + <tr> + <td> </td> + </tr> + <tr> + <td><h3>Options for Uploading $displayManager.getPluralDisplayNameForImageSession()</h3></td> + </tr> + <tr> + <td> </td> + </tr> + + + <tr> + <td> + <hr/> + <h4>Option 1: Upload Applet</h4> + </td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">DICOM and ECAT files can be uploaded via the Upload Applet. <a href="$link.setPage("LaunchUploadApplet.vm")">Click here</a> to upload using the Upload Applet. + </div> + </tr> + + + + <tr> + <td> + <hr/> + <h4>Option 2: Download Upload Assistant application</h4> + </td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">You can download the XNAT Upload Assistant application and use it to upload your session. If the Upload Applet does not work for you, you might want to try this. <a href="https://bitbucket.org/xnatdev/upload-assistant/downloads">Click here</a> to find the appropriate version of the XNAT Upload Assistant application for your operating system. + </div> + </tr> + + + + <tr> + <td> + <hr/> + <h4> + Option 3: Compressed upload</h4></td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">Raw image files can be zipped (.zip or .tar.gz) and uploaded using the form. This + tool currently supports DICOM and ECAT files. Selecting 'Prearchive' will place your images into a + temporary holding space. You will then have the ability to review the details and match the data to the + proper $displayManager.getSingularDisplayNameForSubject().toLowerCase() & $displayManager.getSingularDisplayNameForImageSession().toLowerCase() ID. If you are confident the data will be mapped properly, you can directly + 'Archive' the files and specify whether the resulting $displayManager.getSingularDisplayNameForImageSession().toLowerCase() should go into a quarantine state. + </div> + <div class="alert" style="margin:15px 0;max-width:696px;min-width:400px;"> + The compressed uploader does not yet support splitting PET/MR sessions based on the site-wide or + project-specific settings for handling PET/MR data. If you are uploading PET/MR data and need to have + the data split into separate PET and MR sessions or created as a PET session rather than a PET/MR + session, you should use either the <a href="$link.setPage("LaunchUploadApplet.vm")">upload applet</a> or the + DICOM C-STORE receiver as described below. + </div> + </td> + </tr> + <tr> + <td> </td> + </tr> + <tr id="option3"> + <td> + <input type="hidden" name="popup" value="true"/> + <form id="uploadFORM" class="noHide" target="iframe" enctype="multipart/form-data" method="POST" + action="$content.getURI("/REST/services/import?http-session-listener=$uploadID&format=html&XNAT_CSRF=$!XNAT_CSRF")"> + <input type="hidden" name="threshhold" value="51516279"/> + + #if($session) + <input type="hidden" name="EXPT_LABEL" value="$!session.getLabel()"/> + <input type="hidden" name="SUBJECT_ID" value="$!session.getSubjectData().getLabel()"/> + #end + + <table border=0 cellpadding="5" cellspacing="0"> + <tr> + <th align="left">$displayManager.getSingularDisplayNameForProject()</th> + <td> + #if(!$session) + <select id="project" name="project" disabled=true></select> + #else + <input type="hidden" name="project" id="project" + value="$session.getProject()"/>$session.getProject() + #end + </td> + </tr> + + #if($session) + <tr> + <th align="left">$displayManager.getSingularDisplayNameForImageSession()</th> + <td>$!session.getLabel()</td> + </tr> + #end + <tr> + <th align="left">Destination</th> + <td> + <label><input id="pc_0" type='radio' name='prearchive_code' value='0' + #if(!$session)CHECKED#end onchange="evaluateDestination(this)"/> + Prearchive</label> + <label><input id="pc_2" type='radio' name='prearchive_code' value='1' + #if($session)CHECKED#end onchange="evaluateDestination(this)"/> + Archive</label> + #if($session) + <input type="hidden" name="overwrite" value="append"/> + <input type="hidden" id="auto-archive" name='auto-archive' value='TRUE'/> + #else + <input type="hidden" id="auto-archive" name='auto-archive' value='FALSE'/> + #end + <input type="hidden" id="quarantine" name='quarantine' value='FALSE'/> + </td> + </tr> + <tr> + <th align="left">File</th> + <td><input type="file" id="image_archive" name="image_archive" size="60" + accept="application/zip, application/x-gzip, application/x-tgz"/></td> + </tr> + #auditBoxes("3" "" "Standard Upload" "Upload Images") + #hideFormJustification() + <tr> + <td> </td> + <td><input id="directButton" type="button" name="eventSubmit_doPerform" value="Begin Upload" onclick="makeTheFormGo();"/> + </td> + </tr> + </table> + </form> + +<span id="progressBar" style="position:relative; display:none;"> +<div id="ex" style="position:relative;width:468px;background:#eeeeee;border:3px double #000000;"> + <table width="100%"> + <tr> + <td colspan=2 align="left"> + <div id="preparing">Loading File... </div> + </td> + </tr> + <tr> + <td> + <div id="uploadLabel">Upload: </div> + </td> + <td align="center"> + <div id="emptyUpload" + style="background-color:#cccccc;border:1px solid black;height:22px;width:300px;padding:0;" + align="left"> + <div id="uploadBar" + style="position:relative;top:0;left:0;background-color:#333333;height:22px;width:0;padding-top:5px;padding:0;"> + <div id="uploadPercent" + style="position:relative;top:0;left:0;color:#f0ffff;height:22px;text-align:center;font:bold;padding:0;padding-top:5px;"> + </div> + </div> + </div> + </td> + </tr> + <tr> + <td> </td> + </tr> + <tr> + <td> + <div id="extractLabel">Extract/Review: </div> + </td> + <td align="center"> + <div id="emptyExtract" + style="background-color:#cccccc;border:1px solid black;height:22px;width:300px;padding:0;" + align="left"> + <div id="extractBar" + style="position:relative;top:0;left:0;background-color:#333333;height:22px;width:0;padding-top:5px;padding:0;"> + <div id="extractPercent" + style="position:relative;top:0;left:0;color:#f0ffff;height:22px;text-align:center;font:bold;padding:0;padding-top:5px;"> + </div> + </div> + </div> + </td> + </tr> + <tr> + <td colspan=2 align="center"> + <div id="current_step"></div> + </td> + </tr> + </table> +</div> +<br> +<table id="extractSummaryTable" border=0 style="border-collapse: collapse;"> + <tr> + <td> + <span id="extractSummary" + style="position:relative;width:468px;height:100px;display:none;overflow:auto; "></span> + </td> + </tr> +</table> +<br> +<iframe id="iframe" name="iframe" src="" width="468" height="80" frameborder="0"> + PROGRESS BAR DISABLED. <br>Try using a more recent web browser. +</iframe> +</span> + <script type="text/javascript"> + progressBar = document.getElementById("uploadBar"); + progressPercent = document.getElementById("uploadPercent"); + </script> + </td> + </tr> + + + <tr> + <td> + <hr/> + <h4>Option 4: DICOM C-STORE Service Class User</h4> + </td> + </tr> + <tr> + <td valign="top" align="left"> + <div style="width:500px">Any DICOM C-STORE SCU, including scanner consoles or DICOM applications like + <a href="http://www.osirix-viewer.com">OsiriX</a> or <a href="http://nrg.wustl.edu/software/dicom-browser">DicomBrowser</a>, + can send files directly to this server. + </div> + </tr> + <tr id="option4"> + <td> + <br><b>DICOM C-STORE receiver (SCP) Specifications</b> + <ul> + <li>Host Name: $!arc.getDcm_dcmHost()</li> + <li>Port: $!arc.getDcm_dcmPort()</li> + <li>AE Title(s): $!arc.getDcm_dcmAe()</li> + </ul> + </td> + </tr> + <tr> + <td> + <hr/> + </td> + </tr> + <script type="text/javascript"> + // Adapted from Sun Java Web Start Auto-Install Demo + // http://java.sun.com/developer/technicalArticles/JavaLP/javawebstart/AutoInstallDemo.html + var detect = navigator.userAgent.toLowerCase(); + var windowsIE = (checkPlatform("msie") && checkPlatform("win")); + + function checkPlatform(string) { + place = detect.indexOf(string) + 1; + thestring = string; + return place; + } + </script> +</table> + +#if(!$session) +<script type="text/javascript" src="$content.getURI('scripts/subjectAssessorData/proj_tools.js')"></script> + +<script type="text/javascript"> + //load projects + window.defaultProject = "$!project"; + + window.projectLoader = new ProjectLoader(); + + window.projectLoader.onLoadComplete.subscribe(function () { + renderProjects(document.getElementById("project"), window.projectLoader.list, window.defaultProject); + }); + + document.getElementById("project").onchange = function (o) { + if (this.selectedIndex > 0) { + var s = this.options[this.selectedIndex]; + var pc = document.getElementById("pc_0"); + if (pc != undefined && pc != null) { + if (s.pc == "4") { + if (s.qc == "0") { + document.getElementById("pc_2").click(); + } else { + document.getElementById("pc_1").click(); + } + } else { + document.getElementById("pc_0").click(); + } + } + } + }; + + window.projectLoader.init(); + + function prepApplet(_form) { + return true; + } + + //build breadcrumb + var breadcrumbs = document.getElementById('breadcrumbs'); + + if (breadcrumbs != null) { + var bread = ""; + #if($project) + bread = bread + "<a href='$link.setAction("DisplayItemAction").addPathInfo("search_element","xnat:projectData").addPathInfo("search_field","xnat:projectData.ID").addPathInfo("search_value","$project")'>$displayManager.getSingularDisplayNameForProject().toUpperCase(): $!project</a>"; + bread = bread + " > Upload Images"; + #end + breadcrumbs.innerHTML = bread; + } + +</script> +#end \ No newline at end of file diff --git a/src/main/webapp/xnat-templates/screens/Viewer.vm b/src/main/webapp/xnat-templates/screens/Viewer.vm deleted file mode 100644 index 334793b5e4872d8c3aeca5e54a935454db2d9c21..0000000000000000000000000000000000000000 --- a/src/main/webapp/xnat-templates/screens/Viewer.vm +++ /dev/null @@ -1,89 +0,0 @@ -##Copyright 2005 Harvard University / Howard Hughes Medical Institute (HHMI) All Rights Reserved -$page.setTitle("Viewer: $om.Id") - -#set ($age = $om.SubjectAge) -#if ($age < 0) -#set ($age = "--") -#end - -#set ($qt='"') - -<script type="text/javascript"> - jq(document).ready(function() { - // add "applet" class to body to support special handling for applets - jq('body').addClass('applet'); - }); -</script> - -<table border="0" > - <tr bgcolor="white"> - <td style="border-style:none;" valign="top" align="left" colspan="2"> - <applet name="plexiviewer" code="org.nrg.plexiViewer.lite.applet.PlexiViewerApplet" - codebase="$!appletPath" archive="plexiviewer-1.6.5.jar, ij-1.49t.jar, framework-1.6.5.jar, xdat-beans-1.6.5.jar, log4j-1.2.17.jar, commons-lang-2.6.jar, nrgutil-2.0.0.jar" - width=250 height=200> - <param name="sessionId" value="$om.Id"> - #if ($startDisplayWith) - <param name="startDisplayWith" value="$!startDisplayWith"> - #end - <param name="jsessionid" value="$jsessionid"> - </applet> - </td> - </tr> - <tr style="border-style:none;"> - <td style="border-style:none;" > - <b>$displayManager.getSingularDisplayNameForImageSession() information</b> - </td> - <td style="border-style:none;" valign="top" align="right"> - <a class=b HREF="" onClick="return popup('$link.setPage('ViewerHelp.vm').addPathInfo('popup','true')','$om.Id')">Help</a> - </td> - </tr> - <tr style="border-style:none;"> - <td style="border-style:none;" colspan="2" > - <textarea - rows="10" - cols="32" - style="font-family:'courier'; font-style:normal; font-weight:normal; font-size:12px; border-style:ridge;">$displayManager.getSingularDisplayNameForImageSession().toUpperCase() ID: $om.Label -LAB ID: $!om.SubjectData.LabId -MAP#: $!om.SubjectData.Map -AGE: $age -GENDER: $om.SubjectData.GenderText -HANDEDNESS: $om.SubjectData.HandedText -ACQ. DATE: $!om.Date -SCANNER: $!om.Scanner -STABILIZATION:$!om.Stabilization -REF. MARKER: $!om.Marker -INVESTIGATOR: $!om.Investigator.Firstname $!om.Investigator.Lastname -OPERATOR: $!om.Operator - -#foreach ($scan in $om.Scans_scan) -$scan.Id $!scan.Type $!scan.Quality -#end - -Additional notes -$!om.Note - -#foreach ($scan in $om.Scans_scan) -SCAN NUMBER: $!scan.Id -TYPE: $!scan.Type -Quality: $!scan.Quality -Vox res (mm):$!scan.Parameters_voxelres_x x $!scan.Parameters_voxelres_y x $!scan.Parameters_voxelres_z -Rect. Fov: $!scan.Parameters_fov_x/$!scan.Parameters_fov_y -Matrix: $!scan.Parameters_matrix_x/$!scan.Parameters_matrix_y -Partitions: $!scan.Parameters_partitions -Orientation: $!scan.Parameters_orientation -TR (ms): $!scan.Parameters_tr -TE (ms): $!scan.Parameters_te -TI (ms): $!scan.Parameters_ti -Flip: $!scan.Parameters_flip -Sequence: $!scan.Parameters_sequence -Origin: $!scan.Parameters_origin -Time: $!scan.startTime -Note: $!scan.Note - -#end -</textarea> - </td> - </tr> -</table> - - diff --git a/src/main/webapp/xnat-templates/screens/ViewerHelp.vm b/src/main/webapp/xnat-templates/screens/ViewerHelp.vm deleted file mode 100644 index 3c2a245adce2d11bd306a930bc3220700a76adee..0000000000000000000000000000000000000000 --- a/src/main/webapp/xnat-templates/screens/ViewerHelp.vm +++ /dev/null @@ -1,130 +0,0 @@ -##Copyright 2005 Harvard University / Howard Hughes Medical Institute (HHMI) All Rights Reserved -<a name="#top"> Frequently Asked Questions </a> -<UL> -<li> <b>Adjusting an Image </b> - <ul> - <li> <a href="#adjustZ"> How do I zoom an Image?</a></li> - <li> <a href="#adjustBC"> How do I adjust brightness of an Image?</a></li> - <li> <a href="#adjustBC"> How do I adjust contrast of an Image?</a></li> - <li> <a href="#adjustMM"> How do I adjust Max and Min intensity of an Image?</a></li> - </ul> -</li> -<li><a href="#printImage"> How do I print an image?</a> </li> -<li><a href="#saveImage"> How do I save a snapshot of an image?</a> </li> -<li><a href="#blankScanData"> Why are Scan and Data choices blank?</a> </li> -<li><a href="#tooSlow"> Why do some images like ASEG take more than a minute to load </a> </li> -<li><a href="#increaseJvmMemory">How do I increase memory and avoid the error message of "Not enough memory..."? </a> </li> -<li><b> Macintosh Issues (OS ver. 9x and earlier)</b> - <ol> - <li> <a href="#menuInvisible"> I do not see a menu after the image loads</a></li> - <li> <a href="#saveMac"> When I save a snapshot, files are not saved as "GIF"</a></li> - <li> <a href="#mrjIssue"> When I try to load ASEG images, I get an error message "read/write error..." and my machine hangs</a></li> - </ol> -</li> - -<li><a href="#contact"> Whom should I contact to report a bug? </a></li> -</UL> - - -<h3><a name="adjustZ">How do I zoom an Image? </a></h3> -<p> -Pressing digits 1, 2 or 3 on the keyboard will zoom an image by a factor of 1, 2 or 3. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3><a name="adjustBC">How do I adjust brightness/contrast of an Image? </a></h3> -<p> -To adjust brighness/contrast of an image: -<p> You can either -<p> Under the menu item <b>Adjust</b> on the viewer, use <b>Brightness/Contrast</b> -<p> Or -<p> Use the combination <b>Ctrl+B</b> to pop-up the brightness/contrast adjuster window -<p> Or -<p> drag the mouse over the image while pressing the left or right mouse button down -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3><a name="adjustMM">How do I adjust max and min intensity of an Image? </a></h3> -<p> -To adjust max and/or min intensity of an image: -<p> Under the menu <b>Adjust</b> on the viewer, use <b>Brightness/Contrast<b> -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3><a name="printImage">How do I print an image? </a></h3> -<p> - To print the image, <b>choose Print (Ctrl+P)</b> on the menu under <b>File</b> -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3><a name="saveImage">How do I save a snapshot of an image? </a></h3> -<p> - To save a snapshot of the image, <b>choose Save (Ctrl+S)</b> on the menu under <b>File</b>. The image files are saved as "GIF" files. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3><a name="blankScanData">Why are Scan and Data choices blank? </a></h3> -<p> - Scan and Data Choices are displayed for built images. The $displayManager.getSingularDisplayNameForImageSession().toLowerCase() that you chose may not have been built. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3> <a name="tooSlow"> Why do some images like ASEG take more than a minute to load? </a> </h3> -<p> - In order to display an image, a lot of the processing is handled by your machine, the delay in displaying an image could be because of slow network and less memory on your machine. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3> <a name="menuInvisible"> I do not see a menu after the image loads </a> </h3> -<p> - On Mac machines, the menu of the viewer will be added to the main Menu bar of the browser. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3> <a name="saveMac"> When I save a snapshot, files are not saved as "GIF"</a> </h3> -<p> - Due to the restriction of max. 31 characters for a file name, if the name of the file is more than 31 characters, the file name is truncated. The extension and/or part of the file name may be lost due this truncation. You should manually set the extension of the saved file. -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3> <a name="mrjIssue"> When I try to load ASEG images, I get an error message "read/write error..." and my machine hangs</a> </h3> -<p> - We suspect this problem is because the JAVA/MRJ version on your Mac is MRJ 2.2.5. Please upgrade MRJ to version 2.2.6 from here - <a href="http://docs.info.apple.com/article.html?artnum=120209" target="_blank">MRJ 2.2.6</a> - - <p> - In order to check the version of MRJ running on your machine, perform the following steps: - - <ol> - <li>Open the System Folder in your Hard Disk</li> - <li>Open the 'Extensions' folder</li> - <li>Find and open the 'MRJ Libraries' folder (if there is no MRJ folder then you need to download and install MRJ Version 2.2.6)</li> - <li>Select (highlight) the file 'MRJLib'</li> - <li>Choose 'Get Info' from the File menu</li> - <li>Check the version of MRJ you have</li> - </ol> </p> - -<p align="right"><small><a href="#top">Top</a></small></p> - -<h3> <a name="increaseJvmMemory"> How do I increase memory and avoid the error message of "Not enough memory..."?</a> </h3> -<p> - <ul> - <li> <b>Windows Users</b></li> - <p> Open Control Panel - <p> Click on Java (opens Java Control Panel) - <p> Select Java Tab - <p> Click on View (under Java Applet Runtime Settings) - <p> Depending on the amount of RAM on you machine set -Xms128m -Xmx128m under the Java Runtime Parameter Column - <p> Note: 128m above assumes that your machine has more than 128MB of physical RAM memory available. - <p> Restart your browser - <li> <b>Mac X Users</b></li> - <p> Open Applications - <p> Open Utilities - <p> Open Java - <p> Select Java <version number> Plugin Settings - <p> Select the Advanced Tab - <p> Depending on the amount of RAM on you machine set -Xms128m -Xmx128m under Java Runtime Parameter - <p> Note: 128m above assumes that your machine has more than 128MB of physical RAM memory available. - <p> Restart your browser - <li> <b>Linux Users</b></li> - </ul> -</p> -<p align="right"><small><a href="#top">Top</a></small></p> - - -<h3> <a name="contact"> Whom should I contact to report a bug? </a></h3> -<p> - Email <a href="mailto:cnltech@iacmail.wustl.edu?subject=Image Viewer Assistance">CNDA Management </A> -<p align="right"><small><a href="#top">Top</a></small></p> - diff --git a/src/main/webapp/xnat-templates/screens/XDATScreen_themes.vm b/src/main/webapp/xnat-templates/screens/XDATScreen_themes.vm deleted file mode 100644 index cf8dab12ced971d3f65e7ea985117ed427d06743..0000000000000000000000000000000000000000 --- a/src/main/webapp/xnat-templates/screens/XDATScreen_themes.vm +++ /dev/null @@ -1,30 +0,0 @@ -<!-- Begin XDATScreen_themes.vm --> -<style> - .bold{ - font-weight: bold; - } -</style> -<div style="margin-left: 20px;"> - <h2><span id="titleAppName"></span> Theme Management</h2> - <div id="currentThemeDiv"> - <span class="label bold">Current theme: </span> - <span id="currentTheme">None</span> - </div> - <br> - <div id="selectThemeDiv"> - <span class="label bold">Select an existing theme: </span> - <select id="themeSelection" name="theme" style="width: 270px;"></select> - <button id="submitThemeButton" onclick="setTheme();">Set Theme</button> - <button id="removeThemeButton" onclick="removeTheme();">Remove Theme</button> - </div> - <br> - <form id="uploadThemeForm" method="POST" class="optOutOfXnatDefaultFormValidation"> - <span class="label bold">Upload a theme package: </span> - <input type="file" id="themeFileUpload" name="themeFileUpload" multiple style="width: 270px;"/> - <button type="submit" id="submitThemeUploadButton">Upload</button> - </form> -</div> - -<script type="text/javascript" src="$content.getURI('scripts/themeManagement.js')"></script> - -<!-- End XDATScreen_themes.vm --> \ No newline at end of file diff --git a/src/main/webapp/xnat-templates/screens/register_box.vm b/src/main/webapp/xnat-templates/screens/register_box.vm index c17ec1a544f95d6661c51fecffaaf2d1dae51394..1fd5adc2b37dfca0ee2b5514ac9db0acc3b9422e 100644 --- a/src/main/webapp/xnat-templates/screens/register_box.vm +++ b/src/main/webapp/xnat-templates/screens/register_box.vm @@ -5,7 +5,7 @@ #* @vtlvariable name="phone" type="java.lang.String" *# #* @vtlvariable name="lab" type="java.lang.String" *# #* @vtlvariable name="comments" type="java.lang.String" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="link" type="org.apache.turbine.services.pull.tools.TemplateLink" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# diff --git a/src/main/webapp/xnat-templates/screens/topBar/New/Default.vm b/src/main/webapp/xnat-templates/screens/topBar/New/Default.vm index 26ee8c3e88c9cf7a747a77c8faaabbd9457e655e..0080ac60de5fcabb8c5397e3a4fa4487b67cacbf 100644 --- a/src/main/webapp/xnat-templates/screens/topBar/New/Default.vm +++ b/src/main/webapp/xnat-templates/screens/topBar/New/Default.vm @@ -1,5 +1,5 @@ #* @vtlvariable name="projectString" type="java.lang.String" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="link" type="org.apache.turbine.services.pull.tools.TemplateLink" *# #* @vtlvariable name="displayManager" type="org.nrg.xdat.display.DisplayManager" *# diff --git a/src/main/webapp/xnat-templates/screens/xnat_ctSessionData/edit/scans.vm b/src/main/webapp/xnat-templates/screens/xnat_ctSessionData/edit/scans.vm index 8e12c586b0c9806c601a73531bc2b8004cb266f4..714a6d849d13311e088347a4cac790c96a77cdf1 100644 --- a/src/main/webapp/xnat-templates/screens/xnat_ctSessionData/edit/scans.vm +++ b/src/main/webapp/xnat-templates/screens/xnat_ctSessionData/edit/scans.vm @@ -1,5 +1,5 @@ #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# #* @vtlvariable name="user" type="org.nrg.xdat.security.XDATUser" *# #* @vtlvariable name="om" type="org.nrg.xdat.om.XnatCtsessiondata" *# diff --git a/src/main/webapp/xnat-templates/screens/xnat_imageSessionData/xnat_imageSessionData_scans.vm b/src/main/webapp/xnat-templates/screens/xnat_imageSessionData/xnat_imageSessionData_scans.vm index b5de0812351fb963d717e848c0e53ed652866480..c572cf802bcfe31cdedd00f7e928e8197f461805 100644 --- a/src/main/webapp/xnat-templates/screens/xnat_imageSessionData/xnat_imageSessionData_scans.vm +++ b/src/main/webapp/xnat-templates/screens/xnat_imageSessionData/xnat_imageSessionData_scans.vm @@ -1,6 +1,6 @@ #* @vtlvariable name="item" type="org.nrg.xft.XFTItem" *# #* @vtlvariable name="user" type="org.nrg.xdat.security.XDATUser" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# #* @vtlvariable name="om" type="org.nrg.xdat.om.XnatImagesessiondata" *# #* @vtlvariable name="scan" type="org.nrg.xdat.om.XnatImagescandata" *# diff --git a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_actions_box.vm b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_actions_box.vm index ae62bd05c05567366db83c9f406bc93a615f6a31..abfc804c1b8f967e8cfcfe1ddb899d60dac81219 100644 --- a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_actions_box.vm +++ b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_actions_box.vm @@ -22,7 +22,8 @@ autosubmenudisplay: true, scrollincrement: 5, position: "static", - maxheight: 150 + maxheight: 150, + submenualignment: ["tr","br"] // aligns top-right (tr) corner of submenu to bottom-right (br) corner of parent item }); // Render the MenuBar instance actionsMenu.getItem(0).cfg.setProperty("disabled", true); diff --git a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_manage.vm b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_manage.vm index 29a51ff89185998c6fd6eb3a105cca383cac14e9..024af73d65d004b61a76325a90d691b8ba9392a2 100644 --- a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_manage.vm +++ b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_manage.vm @@ -1,5 +1,5 @@ #* @vtlvariable name="displayManager" type="org.nrg.xdat.display.DisplayManager" *# -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# #* @vtlvariable name="project" type="org.nrg.xdat.om.XnatProjectdata" *# diff --git a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_management.vm b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_management.vm index b6807c984a4e1aa91cf7ee6cf6e7d59f184718c6..8fd56e1fe413e6e88538da160280ddcc268136b2 100644 --- a/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_management.vm +++ b/src/main/webapp/xnat-templates/screens/xnat_projectData/xnat_projectData_summary_management.vm @@ -1,4 +1,4 @@ -#* @vtlvariable name="siteConfig" type="java.util.Properties" *# +#* @vtlvariable name="siteConfig" type="org.nrg.xdat.preferences.SiteConfigPreferences" *# #* @vtlvariable name="data" type="org.apache.turbine.util.RunData" *# #* @vtlvariable name="turbineUtils" type="org.nrg.xdat.turbine.utils.TurbineUtils" *# #* @vtlvariable name="content" type="org.apache.turbine.services.pull.tools.ContentTool" *#