aboutsummaryrefslogtreecommitdiff
path: root/qc_app/templates/rqtl2/select-probeset-study-id.html
blob: c387514eee43c1772865ffa7c765163ba1c461b5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
{%extends "base.html"%}
{%from "flash_messages.html" import flash_messages %}

{%block title%}Upload R/qtl2 Bundle{%endblock%}

{%block contents%}
<h2 class="heading">Phenotype(ProbeSet) Study</h2>

<div class="explainer">
  <p>The R/qtl2 bundle you uploaded contains (a) "<strong>pheno</strong>"
    file(s). This data needs to be organised under a study.</p>
  <p>In this page, you can either select from a existing dataset:</p>
</div>

<form method="POST"
      action="{{url_for('upload.rqtl2.select_probeset_study',
	      species_id=species.SpeciesId, population_id=population.Id)}}"
      id="frm:select-probeset-study">
  <legend class="heading">Select from existing ProbeSet studies</legend>
  {{flash_messages("error-rqtl2-select-probeset-study")}}

  <input type="hidden" name="species_id" value="{{species.SpeciesId}}" />
  <input type="hidden" name="population_id"
	 value="{{population.InbredSetId}}" />
  <input type="hidden" name="rqtl2_bundle_file"
	 value="{{rqtl2_bundle_file}}" />
  <input type="hidden" name="geno-dataset-id" value="{{geno_dataset.Id}}" />
  <input type="hidden" name="tissueid" value="{{tissue.Id}}" />

  <fieldset>
    <label for="select:probe-study">Study</label>
    <select id="select:probe-study"
	    name="probe-study-id"
	    required="required"
	    {%if studies | length == 0%}disabled="disabled"{%endif%}>
      <option value="">Select a study</option>
      {%for study in studies%}
      <option value={{study.Id}}>
	{{study.Name}}
	{%if study.FullName%}
	 -- ({{study.FullName}})
	{%endif%}
      </option>
      {%endfor%}
    </select>
    <span class="form-col-2">Select from existing ProbeSet studies.</span>
  </fieldset>

  <fieldset>
    <input type="submit"
	   value="select study"
	   class="btn btn-primary form-col-2" />
  </fieldset>
</form>

<p style="color:#FE3535; padding-left:20em; font-weight:bolder;">OR</p>

<div class="explainer">
  <p>Create a new ProbeSet dataset below:</p>
</div>

<form method="POST"
      action="{{url_for('upload.rqtl2.create_probeset_study',
	      species_id=species.SpeciesId, population_id=population.Id)}}"
      id="frm:create-probeset-study">
  <legend class="heading">Create new ProbeSet study</legend>

  {{flash_messages("error-rqtl2-create-probeset-study")}}

  <input type="hidden" name="species_id" value="{{species.SpeciesId}}" />
  <input type="hidden" name="population_id"
	 value="{{population.InbredSetId}}" />
  <input type="hidden" name="rqtl2_bundle_file"
	 value="{{rqtl2_bundle_file}}" />
  <input type="hidden" name="geno-dataset-id" value="{{geno_dataset.Id}}" />
  <input type="hidden" name="tissueid" value="{{tissue.Id}}" />

  <fieldset>
    <label for="select:platform">Platform</label>
    <select id="select:platform"
	    name="platformid"
	    required="required"
	    {%if platforms | length == 0%}disabled="disabled"{%endif%}>
      <option value="">Select a platform</option>
      {%for platform in platforms%}
      <option value="{{platform.GeneChipId}}">
	{{platform.GeneChipName}} ({{platform.Name}})
      </option>
      {%endfor%}
    </select>
    <span class="form-col-2">Select from a list of known genomics platforms.
    </span>
  </fieldset>

  <fieldset>
    <label for="txt:studyname">Study name</label>
    <input type="text" id="txt:studyname" name="studyname"
	   placeholder="Name of the study. (Required)"
	   required="required"
	   maxlength="100" />
    <span class="form-col-2">Provide a name for the study.</span>
  </fieldset>

  <fieldset>
    <label for="txt:studyfullname">Full Study Name</label>
    <input type="text" id="txt:studyfullname" name="studyfullname"
	   placeholder="Longer name of the study. (Optional)"
	   maxlength="100" />
    <span class="form-col-2">
      Provide a longer, more descriptive name for the study. This is optional
      and you can leave it blank.
    </span>
  </fieldset>

  <fieldset>
    <label for="txt:studyshortname">Short Study Name</label>
    <input type="text" id="txt:studyshortname" name="studyshortname"
	   placeholder="Shorter name of the study. (Optional)"
	   maxlength="100" />
    <span class="form-col-2">
      Provide a shorter name for the study. This is optional and you can leave
      it blank.
    </span>
  </fieldset>

    <fieldset>
    <input type="submit"
	   value="create study"
	   class="btn btn-primary form-col-2" />
  </fieldset>
</form>

{%endblock%}