Changeset 3816


Ignore:
Timestamp:
Sep 6, 2010, 10:57:24 AM (13 years ago)
Author:
Gregory Vincic
Message:

Refs #698. Removed method getGelExternalIdField from FormFactory.

Location:
trunk/client/servlet/src/org/proteios
Files:
1 added
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/client/servlet/src/org/proteios/action/hit/CreateProteinAssemblyJob.java

    r3774 r3816  
    4141import org.proteios.core.Project;
    4242import org.proteios.core.StringParameterType;
    43 import org.proteios.gui.form.FormFactory;
     43import org.proteios.gui.form.*;
    4444
    4545import se.lu.thep.waf.ActionException;
     
    8787    Project project = isProjectActive(dc);
    8888    ItemFactory factory = getItemFactory(dc);
    89     String gelId = getString(FormFactory.VREQUIRED_GELEXTERNALID);
     89    String gelId = getString(ExternalGelIdField.VPARAM_REQUIRED);
    9090    String localSampleId = getString(FormFactory.VLOCALSAMPLEIDSELECTED);
    9191    log.debug("gelId:" + gelId);
  • trunk/client/servlet/src/org/proteios/action/hit/ImportHits.java

    r1916 r3816  
    3939import org.proteios.core.Project;
    4040import org.proteios.core.StringParameterType;
    41 import org.proteios.gui.form.FormFactory;
     41import org.proteios.gui.form.*;
    4242import se.lu.thep.waf.ActionException;
    4343import se.lu.thep.waf.constraints.InvalidParameterValue;
     
    6464    DbControl dc = newDbControl();
    6565    Project project = isProjectActive(dc);
    66     String gelId = getSessionAttribute(FormFactory.VGELEXTERNALID);
     66    String gelId = getSessionAttribute(ExternalGelIdField.VPARAM);
    6767    String plateId = getSessionAttribute(FormFactory.VPLATEEXTERNALID);
    6868    Integer pluginDefId = getSessionAttribute(FormFactory.VPLUGINDEFID);
    69     List<Integer> fileIds = getValidIntegerList(FormFactory.VID);
     69    List<Integer> fileIds = getValidIntegerList(ItemIdField.VPARAM);
    7070    ItemFactory factory = new ItemFactory(dc);
    7171    /***********************************************************************
  • trunk/client/servlet/src/org/proteios/action/hit/ImportHitsStep2.java

    r1916 r3816  
    3232import org.proteios.core.DbControl;
    3333import org.proteios.core.Project;
    34 import org.proteios.gui.form.Form;
    35 import org.proteios.gui.form.FormFactory;
     34import org.proteios.gui.form.*;
    3635import se.lu.thep.waf.ActionException;
    3736import se.lu.thep.waf.constraints.InvalidParameterValue;
     
    5958    Form impForm = getFormFactory().getImportHitsForm(project);
    6059    verifyParameters(impForm);
    61     saveToSession(FormFactory.VGELEXTERNALID);
     60    saveToSession(ExternalGelIdField.VPARAM);
    6261    saveToSession(FormFactory.VPLATEEXTERNALID);
    63     saveToSession(FormFactory.VFWDACTION);
     62    saveToSession(ForwardField.VPARAM);
    6463    saveToSession(FormFactory.VPLUGINDEFID);
    6564    setForwardTo(SelectFile.class);
  • trunk/client/servlet/src/org/proteios/action/hit/ImportHitsWizardStep1a.java

    r2070 r3816  
    3232import org.proteios.core.DbControl;
    3333import org.proteios.core.Project;
    34 import org.proteios.gui.form.Form;
    35 import org.proteios.gui.form.FormFactory;
     34import org.proteios.gui.form.*;
    3635
    3736import se.lu.thep.waf.ActionException;
     
    6059    Form impForm = getFormFactory().getImportHitsWizardStep1Form(project);
    6160    verifyParameters(impForm);
    62     saveToSession(FormFactory.VGELEXTERNALID);
    63     saveToSession(FormFactory.VFWDACTION);
     61    saveToSession(ExternalGelIdField.VPARAM);
     62    saveToSession(ForwardField.VPARAM);
    6463    saveToSession(FormFactory.VPLUGINDEFID);
    6564    setSessionAttribute(ViewActiveDirectory.VDIRID, project
  • trunk/client/servlet/src/org/proteios/action/hit/ImportHitsWizardStep1b.java

    r3630 r3816  
    3939import org.proteios.core.Project;
    4040import org.proteios.core.StringParameterType;
    41 import org.proteios.gui.form.FormFactory;
     41import org.proteios.gui.form.*;
    4242import se.lu.thep.waf.ActionException;
    4343import se.lu.thep.waf.constraints.InvalidParameterValue;
     
    6464    DbControl dc = newDbControl();
    6565    Project project = isProjectActive(dc);
    66     String gelId = getSessionAttribute(FormFactory.VGELEXTERNALID);
     66    String gelId = getSessionAttribute(ExternalGelIdField.VPARAM);
    6767    Integer pluginDefId = getSessionAttribute(FormFactory.VPLUGINDEFID);
    68     List<Integer> fileIds = getValidIntegerList(FormFactory.VID);
     68    List<Integer> fileIds = getValidIntegerList(ItemIdField.VPARAM);
    6969  if(fileIds == null || fileIds.isEmpty())
    7070  {
  • trunk/client/servlet/src/org/proteios/action/hit/SelectPrideProtocolFileStep1a.java

    r3815 r3816  
    3535import org.proteios.core.Project;
    3636import org.proteios.core.User;
    37 import org.proteios.gui.form.Form;
    38 import org.proteios.gui.form.FormFactory;
     37import org.proteios.gui.form.*;
    3938import se.lu.thep.waf.ActionException;
    4039import se.lu.thep.waf.constraints.InvalidParameterValue;
     
    7069      activeProject, null);
    7170    verifyParameters(form);
    72     String gelId = getString(FormFactory.VREQUIRED_GELEXTERNALID);
     71    String gelId = getString(ExternalGelIdField.VPARAM_REQUIRED);
    7372    log.debug("gelId = " + gelId);
    7473    String localSampleId = getString(FormFactory.VLOCALSAMPLEIDSELECTED);
     
    8988    // Save parameter values as session attributes
    9089    setSessionAttribute(CreatePrideExportJob.VEXPERIMENTTITLE, experimentTitle);
    91     setSessionAttribute(FormFactory.VREQUIRED_GELEXTERNALID, gelId);
     90    setSessionAttribute(ExternalGelIdField.VPARAM_REQUIRED, gelId);
    9291    setSessionAttribute(FormFactory.VLOCALSAMPLEIDSELECTED, localSampleId);
    9392    setSessionAttribute(CreatePrideExportJob.VCUTOFFSTRING, fdrCutoffStr);
     
    10099    setSessionAttribute(CreatePrideExportJob.VCONTACTINST, getString(CreatePrideExportJob.VCONTACTINST));   
    101100    // Get original forward action
    102     String forward2Id = getValidString(FormFactory.VFWDACTION);
     101    String forward2Id = getValidString(ForwardField.VPARAM);
    103102    String forwardId = getActionFactory().getId(SelectPrideProtocolFileStep1b.class);
    104103    log.debug("forward2Id = " + forward2Id);
     
    128127    setSessionAttribute(FormFactory.VFILESELECTIONNEXTBUTTONNAME, "NextCreateExportJobs");
    129128    setSessionAttribute(FormFactory.VFWD2ACTION, forward2Id);
    130     setSessionAttribute(FormFactory.VFWDACTION, forwardId);
     129    setSessionAttribute(ForwardField.VPARAM, forwardId);
    131130    setForwardTo(ViewActiveDirectory.class);
    132131  }
  • trunk/client/servlet/src/org/proteios/gui/form/FormFactory.java

    r3813 r3816  
    246246  public static final VString VWELLPOSITION = new VString("wellPosition", 0,
    247247    8, false);
    248   public static final VString VGELEXTERNALID = new VString("gelExtId", 0, 32,
    249     false);
    250   public static final VString VREQUIRED_GELEXTERNALID = new VString(
    251     "gelExtId", 0, 32, true);
    252248  public static final VString VREQUIRED_LOCALSAMPLEID = new VString(
    253249    "localSampleId", 0, 32, true);
     
    24242420      properties.add(forwardF);
    24252421      //
    2426       properties.add(getGelExternalIdField(false));
     2422      properties.add(new ExternalGelIdField(false));
    24272423      //
    24282424      properties.add(getPlateExternalIdField());
     
    24822478      properties.add(forwardF);
    24832479      // Gel id (optional)
    2484       properties.add(getGelExternalIdField(false));
     2480      properties.add(new ExternalGelIdField(false));
    24852481    }
    24862482    return form;
     
    35023498    plateIdF.setLabel("PlateExternalId");
    35033499    return plateIdF;
    3504   }
    3505 
    3506 
    3507   private TextField<String> getGelExternalIdField(boolean isRequired)
    3508   {
    3509     TextField<String> field;
    3510     if (isRequired)
    3511       field = new TextField<String>(VREQUIRED_GELEXTERNALID);
    3512     else
    3513       field = new TextField<String>(VGELEXTERNALID);
    3514     field.setLabel("GelExternalId");
    3515     return field;
    35163500  }
    35173501
Note: See TracChangeset for help on using the changeset viewer.