

<div class="page-content-wrapper">
    <div class="page-content">
        <div class="row">
            <div class="col-md-12">
                <!-- BEGIN EXAMPLE TABLE PORTLET-->
                <div class="portlet box blue">
                    <div class="portlet-title">
                        <div class="caption">
                            <i class="fa fa-user"></i>SMS Control 
                        </div>
                        <div class="actions">
                            <a href="{$hosturl}/controllers/{$controllname}.php?ac=show"   class="btn btn-default btn-sm">Show </a>
                        </div>
                    </div>
                    <div class="portlet-body">
                        <div class="row">
                            <div class="portlet-title tbox">
                                <div class="caption font-green-haze col-md-6">
                                    <span class="caption-subject bold uppercase">Edit SMS Control </span>
                                </div>
                            </div>

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

                            <form action="{$hosturl}/controllers/{$controllname}.php?ac=updateit" method="post" 
                                  class="clinick">
                                <div class="form-body">
                                    <div class="form-group ">
                                        <label class="col-md-2 txtl" for="form_control_1">Name</label>
                                        <div class="col-md-10">
                                            <input type="text" class="form-control" id="form_control_1"  readonly
                                                   placeholder="Enter Name" name="name" required value="{$editElement->name}">
                                            <div class="form-control-focus">
                                            </div>

                                        </div>
                                    </div>

                                    <div class="form-group ">
                                        <label class="col-md-2 txtl" for="form_control_1">Fixed Link</label>
                                        <div class="col-md-10">
                                            <input type="text" class="form-control" id="form_control_1" 
                                                   placeholder="Enter Link" name="fixed_link" value="{$editElement->fixed_link}" >
                                            <div class="form-control-focus">
                                            </div>

                                        </div>
                                    </div>

                                    <div class="form-group ">
                                        <label class="col-md-2 txtl" for="form_control_1"> Link to Encrypt</label>
                                        <div class="col-md-10">
                                            <input type="text" class="form-control" id="form_control_1" 
                                                   placeholder="Enter Link" name="en_link" value="{$editElement->en_link}" >
                                            <div class="form-control-focus">
                                            </div>

                                        </div>
                                    </div>

                                    <div class="form-group ">
                                        <label class="col-md-2 txtl" for="form_control_1">Place</label>
                                        <div class="col-md-10">
                                            <select class="form-control   select2h txtc" name="message_place" required>
                                                <option value="">Choose </option>
                                                <option value="1" {if  $editElement->message_place == 1 } selected {/if}>Add Patient </option>
                                                <option value="2" {if  $editElement->message_place == 2 } selected {/if}>Add Visit </option>
                                                <option value="3" {if  $editElement->message_place == 3 } selected {/if}>Add Visit By Customer Service</option>
                                            </select>

                                        </div>
                                    </div>

                                    <div class="form-group ">
                                        <label class="col-md-2 txtl" for="form_control_1">Type</label>
                                        <div class="col-md-10">
                                            <select class="form-control   select2h txtc" name="message_type" required>
                                                <option value="1" {if  $editElement->message_type == 1 } selected {/if}>Message Only</option>
                                                <option value="2" {if  $editElement->message_type == 2 } selected {/if}>Message With Link  Only</option>
                                                <option value="3" {if  $editElement->message_type == 3 } selected {/if}>Message With Patient  Only</option>
                                                <option value="4" {if  $editElement->message_type == 4 } selected {/if}>Message With Link + Patient </option>
                                                <option value="5" {if  $editElement->message_type == 5 } selected {/if}>Message With Link + Visit </option>
                                            </select>

                                        </div>
                                    </div>


                                    <div class="form-group col-md-8 ">
                                        <label class="col-md-3 txtl" for="form_control_1">Departments</label>
                                        <div class="col-md-9">
                                            <select multiple class="form-control input-xlarge select2me input-sm select2-offscreen noborder"   
                                                    data-placeholder="Choose" name="for_depts[]">
                                                <option value=""></option>
                                                {foreach $roles as $single}
                                                <option value="{$single->id}"   {if in_array($single->id, $for_depts)} selected="selected" {/if} >
                                                    {$single->name}</option>
                                                {/foreach}
                                            </select>
                                        </div>
                                    </div>

                                    <label class="wds8  fleft " style="text-align: center !important; margin-top: 12px;">OR  </label>

                                    <div class="form-group col-md-3 " style="margin-top: 8px;">
                                        <div class="col-md-1">
                                            <input type="checkbox" class="form-control" name="for_depts_all" value="1" 
                                                   {if $editElement->for_depts_all == 1 } checked="" {/if}>
                                        </div>
                                        <label class="col-md-9 txtl" for="form_control_1">All Departments</label>
                                    </div>

                                    <div class="form-group col-md-12 ">
                                        <label class="col-md-2 txtl" for="form_control_1">Message</label>
                                        <div class="col-md-10">
                                            <textarea class="form-control has-info " rows="2" placeholder="Enter message" 
                                                      name="message" > {$editElement->message}</textarea>
                                            <div class="form-control-focus">
                                            </div>
                                        </div>
                                    </div>
                                    <input type="hidden" id="id" name="id" value="{$editElement->id}" />
                                </div>
                                <div class="form-actions">
                                    <div class="row">
                                        <div class="col-md-offset-2 col-md-10">
                                            <a class="btn default" href="{$hosturl}/controllers/{$controllname}.php?ac=show">Cancel</a>
                                            <button type="submit" class="btn blue">Submit</button>
                                        </div>
                                    </div>
                                </div>
                            </form>

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


