<div style="display:none;padding-top: 5px;padding-right: 15px;" id="freezingDiv">

    <div class="caption font-green-haze col-md-12 txtc">
        <span class="caption-subject bold " style="color: black">Embryo Freezing</span>
    </div>

    <div class="col-md-12">

        <div class="caption font-green-haze col-md-4">
            <div class="form-group">
                <label class="col-md-5 control-label" for="form_control_1">
                    No Of Straws :
                </label>
                <div class="col-md-6">
                    <input type="text" name="no_straws" class="form-control input-sm updateEmbryoLab" id="form_control_1"  value="{$updatedate.no_straws}" data-colName="no_straws" data-tableName="embryoslab">

                </div>
            </div>
        </div>

        <div class="caption font-green-haze col-md-4">
            <div class="form-group">
                <label class="col-md-5 control-label" for="form_control_1">
                    No Of Embryos :
                </label>
                <div class="col-md-6">
                    <input type="text" name="no_embryos" class="form-control input-sm updateEmbryoLab" id="form_control_1"  value="{$updatedate.no_embryos}" data-colName="no_embryos" data-tableName="embryoslab">

                </div>
            </div>
        </div>

        <div class="caption font-green-haze col-md-4">
            <div class="form-group">
                <label class="col-md-5 control-label" for="form_control_1">
                    Location :
                </label>
                <div class="col-md-6">
                    <!--                                                                        <input type="text" name="location" class="form-control input-sm updateEmbryoLab bp_location" id="form_control_1"  value="{$updatedate.location}" data-colName="location" data-tableName="embryoslab">-->
                    {foreach $tank_cells as $cell}
                    <label style="display: block;">{$cell.name}-{$cell.up_level_name}-{$cell.cell_name}
                    </label>
                    {/foreach}
                    {foreach $tank_cells_2 as $cell}
                    <label style="display: block;">{$cell.name}-{$cell.up_level_name}-{$cell.cell_name}-{$cell.cell_part_name}
                    </label>
                    {/foreach}
                    <button type="button" class="btn btn-primary" data-toggle="modal" data-target="#addTankLocation">
                        Add location in tank
                    </button>
                </div>
            </div>
        </div>
    </div>


    <div class="col-md-11">
        <label class="col-md-3 control-label" for="form_control_1">
            Day of Freezing:
        </label>
        <div class="col-md-8">
            <div class="col-md-2">
                <div class="md-radio-list">
                    <div class="md-radio">
                        <input type="radio"  id="2d" name="days" class="md-radiobtn sradio updateEmbryoLab" 
                               data-val="1" value="1" data-colName="dayoffreezzing" data-tableName="embryoslab" 
                               {if $updatedate.dayoffreezzing eq 1 && $updatedate.dayoffreezzing neq ""}checked{/if}>
                        <label for="2d">
                            <span></span>
                            <span class="check"></span>
                            <span class="box"></span>
                            2nd day</label>
                    </div>
                </div>
            </div>
            <div class="col-md-2">
                <div class="md-radio-list">
                    <div class="md-radio">
                        <input type="radio"  id="3d" name="days" class="md-radiobtn sradio updateEmbryoLab" data-val="2" value="2" data-colName="dayoffreezzing" data-tableName="embryoslab" {if $updatedate.dayoffreezzing eq 2 && $updatedate.dayoffreezzing neq ""}checked{/if}>
                        <label for="3d">
                            <span></span>
                            <span class="check"></span>
                            <span class="box"></span>
                            3rd day</label>
                    </div>
                </div>
            </div>
            <div class="col-md-2">
                <div class="md-radio-list">
                    <div class="md-radio">
                        <input type="radio"  id="4d" name="days" class="md-radiobtn sradio updateEmbryoLab" data-val="3" value="3" data-colName="dayoffreezzing" data-tableName="embryoslab" {if $updatedate.dayoffreezzing eq 3 && $updatedate.dayoffreezzing neq ""}checked{/if}>
                        <label for="4d">
                            <span></span>
                            <span class="check"></span>
                            <span class="box"></span>
                            4nd day</label>
                    </div>
                </div>
            </div>
            <div class="col-md-2">
                <div class="md-radio-list">
                    <div class="md-radio">
                        <input type="radio" id="5d" name="days" class="md-radiobtn sradio updateEmbryoLab" data-val="4" value="4" data-colName="dayoffreezzing" data-tableName="embryoslab" {if $updatedate.dayoffreezzing eq 4 && $updatedate.dayoffreezzing neq ""}checked{/if}>
                        <label for="5d">
                            <span></span>
                            <span class="check"></span>
                            <span class="box"></span>
                            5nd day</label>
                    </div>
                </div>
            </div>
            <div class="col-md-2">
                <div class="md-radio-list">
                    <div class="md-radio">
                        <input type="radio" id="6d" name="days" class="md-radiobtn sradio updateEmbryoLab" data-val="5" value="5" data-colName="dayoffreezzing" data-tableName="embryoslab" {if $updatedate.dayoffreezzing eq 5 && $updatedate.dayoffreezzing neq ""}checked{/if}>
                        <label for="6d">
                            <span></span>
                            <span class="check"></span>
                            <span class="box"></span>
                            6nd day</label>
                    </div>
                </div>
            </div>
        </div>
    </div>


    <div class="actions col-md-1">
        <a href="javascript:;" class="btn btn-default btn-sm " data-tableName="embryofreezing" id="addnewRowfreezing">
            Add New</a>
    </div>


    <div class="clearfix"></div>
    <br>
    <table>
        <thead>

            <tr>
                <th  rowspan="2" class="wds6">
                    Straw#
                </th>
                <th  colspan="2">
                    1
                </th>
                <th  colspan="2">
                    2
                </th>
                <th  colspan="2">
                    3
                </th>

                <th  colspan="2">
                    4
                </th>
                <th  colspan="2">
                    5
                </th>
                <th  colspan="2">
                    6
                </th>
                <th  colspan="2">
                    7
                </th>

                <th rowspan="2" class="wds4"  >

                </th>
            </tr>
            <tr>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>

                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
                <th >
                    stage
                </th>
                <th >
                    grade
                </th>
            </tr>

        </thead>
        <tbody id="freezingTable">
            {assign var=itr value=1}
            {foreach $embryofreezing as $one_freezing}
            <tr>
                <td>
                    Straw#{$itr}
                </td>
                <td>
                    <select id="s11" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage1" select-tableName="stage" data-colName="stage1">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage1 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g11" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade1" select-tableName="grade" data-colName="grade1">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade1 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s12" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage2" select-tableName="stage" data-colName="stage2">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage2 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g12" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade2" select-tableName="grade" data-colName="grade2">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade2 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s13" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage3" select-tableName="stage" data-colName="stage3">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage3 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g13" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade3" select-tableName="grade" data-colName="grade3">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade3 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s14" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage4" select-tableName="stage" data-colName="stage4">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage4 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g14" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade4" select-tableName="grade" data-colName="grade4">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade4 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s15" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage5" select-tableName="stage" data-colName="stage5">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage5 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g15" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade5" select-tableName="grade" data-colName="grade5">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade5 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s16" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage6" select-tableName="stage" data-colName="stage6">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage6 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g16" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade6" select-tableName="grade" data-colName="grade6">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade6 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="s17" class="form-control selectStage update_item2" data-rowid="{$one_freezing->id}" name="stage7" select-tableName="stage" data-colName="stage7">
                        <option value="">choose</option>
                        {foreach  $stages as $one}
                        <option value="{$one->id}"{if $one_freezing->stage7 eq $one->id}selected{/if}>{$one->stage}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td>
                    <select id="g17" class="form-control selectGrade update_item2" data-rowid="{$one_freezing->id}" name="grade7" select-tableName="grade" data-colName="grade7">
                        <option value="">choose</option>
                        {foreach  $grades as $one}
                        <option value="{$one->id}"{if $one_freezing->grade7 eq $one->id}selected{/if}>{$one->grade}</option>
                        {/foreach}

                        <option value="-2" class="deleteoptincompo">Delete</option>
                    </select>
                </td>
                <td rowspan="2">
                    <a class="btn grey-cascade btn-xs delFromTableFreezing" data-rowid="{$one_freezing->id}" style=" float: left;">
                        <i class="fa fa-close"></i>
                    </a>
                </td>
            </tr>
            <tr >
                <td colspan="15">
                    <textarea class="form-control update_item2" data-rowid="{$one_freezing->id}" rows="2"  name='straw_notes' placeholder="Enter more text"
                              data-id="{$one_freezing->id}" data-colName="straw_notes" data-tableName="embryofreezing">{$one_freezing->straw_notes}</textarea>
                    <div class="form-control-focus">
                    </div>
                </td>
            </tr>
            {capture assign=itr}{$itr+1}{/capture}
            {/foreach}
        <input type="hidden" name="Itr" id="Itr" value="{$count_embryofreezing}"/>

        </tbody>
    </table>



    <div class="col-md-12">
        <div class="portlet box blue">
            <div class="portlet-title" style="height: 5px">
                <div class="caption">
                    <i class="fa fa-edit"></i>Embryo Thawing
                </div>
                <div class="actions ">
                    <a href="javascript:;" class="btn btn-default btn-sm" id="addNewthawingRow" 
                       data-tableName="embryothawing">
                        <i class="fa fa-plus"></i> Add New</a>
                </div>
            </div>
            <div class="portlet-body"  >

                <input type="hidden" id="storesController" value="1">
                <table class="table table-striped table-hover table-bordered" >
                    <thead>
                        <tr>
                            <th class="col-md-1 wds5">
                                Straw
                            </th >
                            <th class="col-md-1">
                                No Of Embryos
                            </th>
                            <th class="col-md-1">
                                Thawing Date
                            </th>

                            <th class="col-md-1">
                                Recovered
                            </th>
                            <th class="col-md-1">
                                Lost
                            </th>
                            <th class="col-md-1">
                                E.T Date
                            </th>
                            <th class="col-md-1">
                                Embryos
                            </th>

                            <th class="col-md-1">
                                Grades
                            </th>
                            <th class="col-md-1 wds15">
                                Embryol oigist
                            </th>
                            <th class="col-md-1 wds15">
                                Clinician
                            </th>
                            <th class="col-md-1 wds15">
                                Cathetr
                            </th>
                            <th class="col-md-1 wds5">
                                Delete
                            </th>
                        </tr>

                    </thead>
                    <tbody id="thawingContent">
                        {assign var=itr value=1}
                        {foreach $embryothawing as $pre}
                        <tr>

                            <td>
                                {$itr}
                                <input type="hidden" name="safyinput1_{$itr}" id="safyinput1_{$itr}" value="{$itr}"/>
                            </td>
                            <td>
                                <input type="text" class="form-control updateEmbryoLab_thawing" value="{$pre.no_of_embryos}" id="no_of_embryos_{$itr}_1"  data-itra="{$itr}_1" name="no_of_embryos_{$itr}_1" data-colName="no_of_embryos" data-tableName="embryothawing" data-tableRow="{$pre.id}"/>
                            </td>
                            <td>
                                <input type="text" class="form-control datepicker updateEmbryoLab_thawing" data-colName="thawing_date" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.thawing_date}" id="thawing_date_{$itr}_2"  data-itra="{$itr}_2" name="thawing_date_{$itr}_2"/>
                            </td>
                            <td>
                                <input type="text" class="form-control updateEmbryoLab_thawing" data-colName="recovered" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.recovered}" id="recovered_{$itr}_3"  data-itra="{$itr}_3" name="recovered_{$itr}_3"/>
                            </td>
                            <td>
                                <input type="text" class="form-control updateEmbryoLab_thawing" data-colName="lost" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.lost}" id="lost_{$itr}_4"  data-itra="{$itr}_4" name="lost_{$itr}_4"/>
                            </td>
                            <td>
                                <input type="text" class="form-control datepicker updateEmbryoLab_thawing" data-colName="e_t_date" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.e_t_date}" id="et_date_{$itr}_5"  data-itra="{$itr}_5" name="et_date_{$itr}_5"/>
                            </td>
                            <td>
                                <input type="text" class="form-control updateEmbryoLab_thawing" data-colName="embryos" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.embryos}" id="embryos_{$itr}_6"  data-itra="{$itr}_6" name="embryos_{$itr}_6"/>
                            </td>
                            <td>
                                <input type="text" class="form-control updateEmbryoLab_thawing" data-colName="grades" data-tableName="embryothawing" data-tableRow="{$pre.id}" value="{$pre.grades}" id="grades_{$itr}_7"  data-itra="{$itr}_7" name="grades_{$itr}_7"/>
                            </td>
                            <td>
                                <div class="col-md-12">
                                    <select class="form-control  select2me updateEmbryoLab_thawing" id="embryol_{$itr}_8" name="embryol_{$itr}_8" data-itr="{$itr}_8" data-id="{$pre.id}" data-colName="embryol_oigist" data-tableName="embryothawing" data-tableRow="{$pre.id}"  data-placeholder="Select..."  >
                                        <option value="">choose</option>
                                        {foreach  $embryologist as $one}
                                        <option value="{$one.user_id}"  {if $pre.embryol_oigist == $one.user_id}selected{/if}>{$one.name}</option>
                                        {/foreach}
                                    </select>
                                </div>                                                                    </td>
                            <td>
                                <div class="col-md-12">
                                    <select class="form-control  select2me updateEmbryoLab_thawing" id="clinician_{$itr}_9" name="clinician_{$itr}_9" data-itr="{$itr}_9" data-id="{$pre->id}"  data-colName="clinician" data-tableName="embryothawing" data-tableRow="{$pre.id}"  data-placeholder="Select...">
                                        <option value="">choose</option>
                                        {foreach  $clinician as $one}
                                        <option value="{$one.user_id}"  {if $pre.clinician == $one.user_id}selected{/if}>{$one.name}</option>
                                        {/foreach}
                                    </select>
                                </div>
                            </td>
                            <td>
                                <div class="col-md-12">
                                    <select class="form-control xx dname select2me cathetrselect allupdateselect cathetr updateEmbryoLab_thawing" data-itra="{$itr}_10" id="cathetr_{$itr}_10" name="cathetr_{$itr}_10" data-id="{$pre->id}" data-colName="cathetr" data-tableName="embryothawing" data-tableRow="{$pre.id}" select-tableName="cathetr"  data-placeholder="Select...">
                                        <option value="">choose</option>
                                        {foreach  $cathetrs as $one}
                                        <option value="{$one.id}" {if $pre.cathetr == $one.id}selected{/if}>{$one.cathetr}</option>
                                        {/foreach}

                                        <option value="-2" class="deleteoptincompo">Delete</option>
                                    </select>
                                </div>
                            </td>
                            <td>
                                <a class="btn grey-cascade btn-xs deletemsgEX" data-id="{$pre.id}" style=" float: left;" href="#" data-link="embryofreezing" data-fn="delRowsommedel" data-tableName="embryothawing">
                                    <i class="fa fa-close"></i>
                                </a>

                            </td>
                        </tr>

                        {capture assign=itr}{$itr+1}{/capture}
                        {/foreach}

                    <input id="thawitr" value="{$itr-1}" type="hidden">

                    </tbody>
                </table>
            </div>
        </div>
    </div>

    <div class="clearfix"></div>


    <div class="col-md-12">

        <table>
            <thead>

                <tr>
                    <th>   Culture Incubator  </th>   
                    <th class="wds20">   Temp. </th>   
                    <th class="wds20">   Co2 </th>   
                    <th class="wds20">   O2  </th>   
                </tr>
            </thead>
            <tbody>
                <tr>
                    <td>
                        <input type="text" class="form-control updateEmbryoLab" name="freezing_incubator" 
                               value="{$updatedate.freezing_incubator}" data-colName="freezing_incubator" data-tableName="embryoslab"/>
                    </td>

                    <td>
                        <input type="text" class="form-control updateEmbryoLab" name="freezing_temp" 
                               value="{$updatedate.freezing_temp}" data-colName="freezing_temp" data-tableName="embryoslab"/>
                    </td>

                    <td>
                        <input type="text" class="form-control updateEmbryoLab" name="freezing_co2" 
                               value="{$updatedate.freezing_co2}" data-colName="freezing_co2" data-tableName="embryoslab"/>
                    </td>

                    <td>
                        <input type="text" class="form-control updateEmbryoLab" name="freezing_o2" 
                               value="{$updatedate.freezing_o2}" data-colName="freezing_o2" data-tableName="embryoslab"/>
                    </td>
                </tr>
            </tbody>
        </table>

    </div>

</div>
</div>