Sindbad~EG File Manager

Current Path : /home/numerotech/public_html/livemt2023.aios-scientificcommittee.org/app/views/arc/
Upload File :
Current File : //home/numerotech/public_html/livemt2023.aios-scientificcommittee.org/app/views/arc/step1.blade.php


{{ Form::open(array('url' => 'arc/store','role'=>'form','id'=>'form_s1')) }}

{{ Form::hidden('hdnId', isset($arc)? $arc->abs_id : 0,array('id'=>'hdnId')) }}
{{ Form::hidden('hdnStep', '1',array('id'=>'hdnStep')) }}
{{ Form::hidden('hdnIsNext', '1',array('id'=>'hdnIsNext')) }}

{{ Form::hidden('hdnPAId', $pres_auth_id ,array('id'=>'hdnPAId')) }}

<div class="row">            
    <div class="col-sm-12">               
       <div class="alert alert-success" style="display:none">            
       </div>

      <div class="alert alert-danger"  style="display:none">                  
      </div>
    </div>
</div>

<div class="col-lg-12 col-md-12 col-sm-12 nopadding margin10">
      <div class="step activestep">STEP 1 </div>
      <div class="step ">STEP 2 </div>
      <div class="step">STEP 3 </div>
      <div class="step">STEP 4 </div> 
      <!-- <div class="step">STEP 5 </div> --> 
</div>

<!--step 1 details  -->
<div class="row">            
    <div class="col-lg-6 col-md-6 col-sm-12">                
          <label>Applicant's Membership Number </label>             
          <p>{{  empty($membership)? '':$membership->membership_no}}</p>    
    </div>            
    <div class="col-lg-6 col-md-6 col-sm-12">        
          <label>Applicant Name </label>             
          <p>{{ isset(Auth::user()->prefix)?Auth::user()->prefix.'.':'' }}{{ Auth::user()->first_name }}</p>    
    </div>            
</div>

{{-- <div class="row">            
    <div class="col-lg-12 col-md-12 col-sm-12">        
      <label>Presenting Author : </label> <label id="hdnPAId-error" class="error" for="hdnPAId"></label>                                                
        <div class="table-responsive">             
          <table id="tbl_PA" class="table table-bordered" style="display:none">
            <thead>
              <tr>                         
                <th>
                Membership No
                </th>
                <th>
                Author Name
                </th>
                <th>
                Email
                </th>
                <th>
                Mobile
                </th>                                                                     
              </tr>
            </thead>
            <tbody>                   

            </tbody>  

          </table>
        </div>

      <div id="show_Add_PA" class="form-group text-center"  style="display:none">
          <input type="button" value="Click here to Search the Presenting Author Details" id="btnSearch" class="btn btn-md btn-primary"
          onclick="SearchPAPOP()">
          <!-- SearchPAPOP funcation in search_pa.blade.php  -->
         </div>

    </div>        
  </div>  --}}  

  

<div class="row">      
      <div class="col-lg-6 col-md-6 col-sm-12">                            
              <label>Section <sup>*</sup></label>                  
              {{ Form::select('ddlSection',$categories,$arc->category_id ,array("id"=>"ddlSection","class"=>"form-control ddlSection"))}}                         
        </div>      
     {{-- <div class="col-lg-6 col-md-6 col-sm-12">                        
            <label>Type of Presentation <sup>*</sup></label>                          
               {{ Form::select('ddlType',$pres_types,$arc->presentation_type_id,array("id"=>"ddlType","class"=>"form-control ddlType"))}}         
      </div> --}}
</div>


<div class="row">      
      <div class="col-lg-12 col-md-12 col-sm-12">                                
              <label id="lbl_award_txt" class="text-red"></label>                                    
        </div>            
</div>

<!--End step 1 details  -->

<div class="row margin30">  
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-6">
</div>
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-6">
<input type="button" value="Next" id ="btnNext_s1" class="btn primary button-large pull-right"
  onclick="Move(1,1)">
</div>
</div>

{{ Form::close() }}



@include('arc.search_pa')


<script type="text/javascript">

var hdnPAId     = "#hdnPAId"
var tbl_PA      = "#tbl_PA";     
var show_Add_PA = "#show_Add_PA"; 

(function($){
  // getPADetails();
  hideshowPA();    

   $("#ddlSection").bind("change", null, function (e) {
         get_set_pa_awards();
    });

    $("#ddlType").bind("change", null, function (e) {
       get_set_pa_awards();
    });


}(jQuery));

// function getPADetails()
// {
//       $.ajax({
//             url: baseUrl + '/arc/get_pa_details',
//             type: 'POST',
//             dataType: 'json',
//             async: false,
//             data: {'pa_id': $(hdnPAId).val()},            
//             })
//         .done(function(d) {                                          
//           data = d.data;
//           if(d.code == 1)
//           {
//            setPA(data.user_id,data.membership_no,data.prefix +"."+ data.name,data.email,data.mobile);
//           }
//         })
//         .fail(function() {
//             //alert("Internal Server Error");
//             //return false;
//         });     
// }


function hideshowPA() {
  clearError();
  get_set_pa_awards();
 if($(hdnPAId).val()>0)
 {
    $(tbl_PA).show();
    $(show_Add_PA).hide();
 }
 else
 {
    $(tbl_PA).hide();
    $(show_Add_PA).show();
 } 
}


function store_pa(user_id,membership_no,name,email,mobile)
{
  
   $.ajax({
        type: 'POST', // <-- get method of form
        url: baseUrl + '/arc/store_pa', // <-- get action of form
        data: {'pa_user_id':user_id,'arc_id':$(hdnId).val()}, 
        async: false,
        dataType: 'json',
        // <-- serialize all fields into a string that is ready to be posted to your PHP file
        beforeSend: function(){
            //$('#result').html('<img src="loading.gif" />');
        },
        success: function(data){
          if(data.code == 1)
          {
              setPA(user_id,membership_no,name,email,mobile);
          }
          else
          {
            errormsg(data.msg)
          }
        }
    });   
   
  }


function Remove(pa_id) {
    //var checkstr =  confirm('Are you sure you want to delete this Presenting Author?');
    // var checkstr =  confirm('Change to Click here to search the presenting Author Details(Accurate Presenting Author Details Are Listed)');
    var checkstr = true;
    if(checkstr == true){
        $.ajax({
            type: 'POST', // <-- get method of form
            url: baseUrl + '/arc/remove_pa', // <-- get action of form
            data: {'pa_id':pa_id,'arc_id':$(hdnId).val()} , // <-- serialize all fields into a string that is ready to be posted to your PHP file
            dataType: 'json',
            beforeSend: function(){
                //$('#result').html('<img src="loading.gif" />');
            },
            success: function(data){
              if(data.code == 1)
              {              
                  //$('#frm').html(data.data);
                  $(hdnPAId).val(0);  
                  hideshowPA();
              }   
              else
              {
                 errormsg(data.msg);
              }       
            }
        });   
      }
}

function onSelectPA(user_id,membership_no,name,email,mobile)
{
  store_pa(user_id,membership_no,name,email,mobile);
}

  // function setPA(user_id,membership_no,name,email,mobile) {  
  //       closeModel("#searchModalPA");
  //       $(hdnPAId).val(user_id);
        
  //       $(tbl_PA + ' tbody').html('');
  //       var str = "";    
  //       if(user_id  >0)         
  //       {
  //           str +="<tr>";
  //           str +="<td data-label=\"Membership No\">" + (membership_no==null?'':membership_no)  + "</td>";    
  //           str +="<td data-label=\"Author Name\">" + (name==null?'':name)  + "</td>";
  //           str +="<td data-label=\"Email\">" + (email==null?'':email)    + "</td>";        
  //           str +="<td data-label=\"Mobile\">" + (mobile==null?'':mobile)  + "</td>";                
  //           str +="</tr>";      
  //           str +="<tr>";
  //           str +="<td colspan=\"4\">" + "<a href=\"#\" onclick=\"ChangePA()\">Click here to Change Presenting Author</a>" + "</td>"; 
  //           str +="</tr>";             
  //       }

  //       $(tbl_PA + ' tbody').html(str);

  //       hideshowPA();
  // }

function ChangePA() {    
    Remove($(hdnPAId).val());
    
}

function get_set_pa_awards()
{

  abs_type = "";
  if($("#ddlType").val()==2)
  {
    abs_type = "ARC"
  }
  else if($("#ddlType").val()==3)
  {
    abs_type = "ARC"
  }
  else if($("#ddlType").val()==1)
  {
    abs_type = "ARC,ARC"
  }


//     $("#lbl_award_txt").html("");
//       $.ajax({
//             url: baseUrl + '/arc/get_pa_awards',
//             type: 'POST',
//             dataType: 'json',
//             async: false,
//             data: {'pa_id': $(hdnPAId).val(),'cat_id':$("#ddlSection").val(),'abs_type':abs_type},            
//             })
//         .done(function(d) {                                                    
//           if(d.code == 1)
//           {
//           $("#lbl_award_txt").html(d.msg);
//           }
//         })
//         .fail(function() {
//             //alert("Internal Server Error");
//             //return false;
//         });     
}


</script>

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists