aboutsummaryrefslogtreecommitdiff
path: root/qc_app/templates/rqtl2/select-tissue.html
blob: 6f7d1340220ba538d1d621ce36729399f8a766fe (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
{%extends "base.html"%}
{%from "flash_messages.html" import flash_messages%}

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

{%block contents%}
<h2 class="heading">Tissue</h2>

<div class="explainer">
  <p>The data you are uploading concerns a tissue, cell, organ, or other
    biological material used in an experiment.</p>
  <p>Select the appropriate biological material below</p>
</div>

{%if tissues | length > 0%}
<form method="POST"
      action="{{url_for('upload.rqtl2.select_tissue',
	      species_id=species.SpeciesId, population_id=population.Id)}}"
      id="frm:select-probeset-dataset">
  <legend class="heading">Select from existing ProbeSet datasets</legend>
  {{flash_messages("error-select-tissue")}}

  <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}}" />

  <fieldset>
    <label for="select-tissue">Tissue</label>
    <select id="select-tissue"
	    name="tissueid"
	    required="required"
	    {%if tissues | length == 0%}disabled="disabled"{%endif%}>
      <option value="">Select a tissue</option>
      {%for tissue in tissues%}
      <option value={{tissue.Id}}>
	{{tissue.Name}}
	{%if tissue.Short_Name%}
	 -- ({{tissue.Short_Name}})
	{%endif%}
      </option>
      {%endfor%}
    </select>

    <span class="form-col-2">Select from existing biological material.</span>
  </fieldset>

  <fieldset>
    <input type="submit"
	   value="use selected"
	   class="btn btn-main form-col-2" />
  </fieldset>
</form>

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

<div class="explainer">
  <p>If you cannot find the biological material in the drop-down above, add it
    to the system below.</p>
</div>

<form method="POST"
      action="{{url_for('upload.rqtl2.create_tissue',
	      species_id=species.SpeciesId, population_id=population.Id)}}"
      id="frm:create-probeset-dataset">
  <legend class="heading">Add new tissue, organ or biological material</legend>
  {{flash_messages("error-create-tissue")}}

  <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}}" />

  <fieldset>
    <label for="tissue-name">name</label>
    <input type="text"
           id="txt-tissuename"
           name="tissuename"
           required="required"
           title = "A name to identify the tissue, organ or biological material." />

    <span class="form-col-2">
      A name to identify the tissue, organ or biological material.
    </span>
  </fieldset>

  <fieldset>
    <label for="txt-shortname">short name</label>
    <input type="text" id="txt-tissueshortname" name="tissueshortname"
	   required="required"
	   maxlength="7"
	   title="A short name (e.g. 'Mam') for the biological material." />

    <span class="form-col-2">
      Provide a short name for the tissue, organ or biological material used in
      the experiment.
    </span>
  </fieldset>

  <fieldset>
    <input type="submit"
	   value="add new material"
	   class="btn btn-main form-col-2" />
  </fieldset>
</form>

{%endblock%}