Changeset 5136


Ignore:
Timestamp:
Oct 15, 2009, 8:33:07 AM (12 years ago)
Author:
Nicklas Nordborg
Message:

Merged patch release 2.13.1 to the trunk.

Location:
trunk
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/doc/src/docbook/admindoc/installation_upgrade.xml

    r5031 r5136  
    77
    88  Copyright (C) 2007 Jari Häkkinen, Peter Johansson, Nicklas Nordborg, Martin Svensson
     9  Copyright (C) 2008 Jari Häkkinen, Nicklas Nordborg, Martin Svensson
     10  Copyright (C) 2009 Jari Häkkinen, Nicklas Nordborg
    911
    1012  This file is part of BASE - BioArray Software Environment.
     
    670672        <listitem>
    671673          <para>
    672             Download and install Apache Tomcat 6.0.14 or later, available
     674            Download and install Apache Tomcat 6.0.20 or later, available
    673675            from <ulink
    674676            url="http://tomcat.apache.org" />.
     
    13381340          <listitem>
    13391341            <para>
    1340             The title of the message. It should be a short and consice to
     1342            The title of the message. It should be a short and concise to
    13411343            avoid confusion. The title will be displayed on a lot of places
    13421344            and a user may have to click on it to read the more detailed
     
    13491351          <listitem>
    13501352            <para>
    1351             Mark this checkbox to try to prevent new users from logging in. To
     1353            Mark this check-box to try to prevent new users from logging in. To
    13521354            avoid problems that can be caused by blocking the server admin out,
    13531355            the login is not completely, disabled. Any user can still login but
  • trunk/src/clients/web/net/sf/basedb/clients/web/formatter/FormatterFactory.java

    r4544 r5136  
    2626import net.sf.basedb.clients.web.Base;
    2727import net.sf.basedb.core.Annotation;
    28 import net.sf.basedb.core.AnnotationType;
    2928import net.sf.basedb.core.Coloring;
    3029import net.sf.basedb.core.ExtendedProperty;
     
    330329  public static Formatter<?> getAnnotationFormatter(SessionControl sc, Annotation a, Unit unit)
    331330  {
    332     AnnotationType at = a.getAnnotationType();
    333331    Formatter<?> f = getTypeFormatter(sc, a.getValueType());
    334332    return a.getUnitFormatter(f, unit);
  • trunk/src/core/net/sf/basedb/core/ArrayDesign.java

    r4889 r5136  
    131131    ad.setNumArrays(1);
    132132    ad.getData().setFeatureIdentificationMethod(FeatureIdentificationMethod.NONE.getValue());
     133    ad.getData().setEntryDate(new Date());
    133134    return ad;
    134135  }
  • trunk/src/core/net/sf/basedb/core/HibernateUtil.java

    r5038 r5136  
    12361236    most useful with <code>lockMode</code> = {@link LockMode#NONE} if
    12371237    the logged in user only has read permission to the object.
    1238     @see DbControl#reattachItem(BasicItem)
     1238    @see DbControl#reattachItem(BasicItem, boolean)
    12391239  */
    12401240  static void lockData(Session session, BasicData data, LockMode lockMode)
  • trunk/src/core/net/sf/basedb/core/ItemContext.java

    r5061 r5136  
    12931293    <li>%: The rest of the string is the channel number. We use the
    12941294      {@link Dynamic#column(VirtualColumn)} to create the expression
    1295       for {@link VirtualColumn#channel(int)}
     1295      for {@link VirtualColumn#channelRaw(int)}
    12961296
    12971297    <li>$: The rest of the string is a raw data property name. We use
  • trunk/src/core/net/sf/basedb/util/overview/validator/PlatformValidator.java

    r4764 r5136  
    2424import net.sf.basedb.core.BasicItem;
    2525import net.sf.basedb.core.DbControl;
     26import net.sf.basedb.core.FileStoreEnabled;
    2627import net.sf.basedb.core.Item;
    2728import net.sf.basedb.core.Platform;
     
    7172    BasicItem defaultVariant = OverviewUtil.getProjectDefaultItem(dc, project, Project.Default.PLATFORM_VARIANT);
    7273    Platform platform = (Platform)node.getItem();
    73     Node variantNode = node.getChild("variant");
    74     PlatformVariant variant = variantNode == null ? null : (PlatformVariant)node.getItem();
     74    PlatformVariant variant = null;
     75    boolean failedVariant = false;
    7576    BasicItem parentItem = parentNode.getItem();
     77    try
     78    {
     79      variant = ((FileStoreEnabled)parentItem).getVariant();
     80    }
     81    catch (Throwable t)
     82    {
     83      // Failure to load the variant is detected by other validators
     84      failedVariant = true;
     85    }
    7686    String parentTypeName = parentNode.getItemType().toString().toLowerCase();
    7787    boolean canChangePlatform = false;
     
    8393   
    8494    if ((defaultPlatform != null && !defaultPlatform.equals(platform)) ||
    85       (defaultVariant != null && !defaultVariant.equals(variant)))
     95      (defaultVariant != null && !defaultVariant.equals(variant) && !failedVariant))
    8696    {
    8797      context.createFailure(Validator.NONDEFAULT_PLATFORM, parentNode, null,
  • trunk/www/common/share/submit_share.jsp

    r4889 r5136  
    107107    }
    108108    mp.updateKeys(dc, recursive);
     109    sc.reloadPermissions();
    109110    dc.commit();
    110111    cc.removeObject("MultiPermissions");
  • trunk/www/filemanager/files/ajax.jsp

    r4867 r5136  
    2727  import="net.sf.basedb.core.Config"
    2828  import="net.sf.basedb.core.File"
     29  import="net.sf.basedb.core.InvalidDataException"
    2930  import="net.sf.basedb.util.Values"
    3031  import="net.sf.basedb.util.FileUtil"
     
    5758    try
    5859    {
     60      int size = Values.getInt(request.getParameter("size"), -1);
    5961      dc = sc.newDbControl();
    6062      File f = File.getById(dc, itemId);
     
    6870      Writer toFile = new OutputStreamWriter(
    6971          f.getUploadStream(false, f.isCompressed()), charset);
    70       FileUtil.copy(in, toFile);
     72      int copied = (int)FileUtil.copy(in, toFile);
     73      if (size >= 0 && copied != size)
     74      {
     75        throw new InvalidDataException("Incomplete file; expected " + size +
     76          " bytes; got " + copied + ".");
     77      }
    7178      toFile.flush();
    7279      toFile.close();
     
    7683    catch (Exception ex)
    7784    {
    78       out.println("Failed: " + ex.getMessage());
     85      out.println("Save failed: " + ex.getMessage());
    7986      ex.printStackTrace();
    8087    }
  • trunk/www/filemanager/files/edit_file_data.jsp

    r4889 r5136  
    127127      var frm = document.forms['file'];
    128128      var url = 'ajax.jsp?ID=<%=ID%>&cmd=StoreFile&item_id=<%=itemId%>';
     129      url += '&size='+frm.filedata.value.length;
    129130      var request = Main.getAjaxRequest();
    130131      request.closeIfSuccess = closeIfSuccess;
     
    136137    {
    137138      var response = request.responseText;
    138       var failed = response.indexOf('Failed') == 0;
     139      var failed = response.indexOf('Save failed') == 0;
    139140      if (!failed)
    140141      {
  • trunk/www/lims/arrayslides/create_wizard.jsp

    r4511 r5136  
    315315      <input type="hidden" name="arraybatch_id" value="<%=arrayBatchId%>">
    316316      <input type="hidden" name="quantity" value="<%=quantity%>">
    317      
     317      <input type="hidden" name="start_at" value="<%=startAt%>">
     318           
    318319      <h3 class="docked"><%=title%> <base:help tabcontrol="settings" /></h3>
    319320      <t:tabcontrol id="settings" contentstyle="<%="height: "+(int)(scale*370)+"px;"%>"
  • trunk/www/lims/arrayslides/index.jsp

    r5060 r5136  
    183183    dc = sc.newDbControl();
    184184    int quantity = Values.getInt(request.getParameter("quantity"));
    185     int batchId = Values.getInt(request.getParameter("arraybatch_id"));   
     185    int batchId = Values.getInt(request.getParameter("arraybatch_id"));
     186    int startAt = Values.getInt(request.getParameter("start_at"), 1);
    186187    String description = Values.getStringOrNull(request.getParameter("description"));
    187188    ArrayBatch batch = ArrayBatch.getById(dc, batchId);
     
    195196      dc.saveItem(slide);
    196197      slide.setName(Values.getStringOrNull(request.getParameter("name"+i)));
    197       slide.setBatchIndex(batchId);
     198      slide.setBatchIndex(startAt + i);
    198199     
    199200      String newBarcode = Values.getStringOrNull(request.getParameter("barcode" + i));
Note: See TracChangeset for help on using the changeset viewer.