<? global $vis_language;?>
<section id="breadcrumb" class="row m-b m-l-none m-r-none">
  <div class="col-sm-6">
    <h3 class="m-b-xs text-black"><? echo $vis_language['TXTCHATTRANSCRIPT'];?></h3>
    <ul class="breadcrumb bg-empty no-border m-b-xxs no-padder">
      <li><a class="link" href="#/home/quick_view/<? echo $vis_language['TXTHOME']; ?>"><? echo $vis_language['TXTHOME'];?></a></li>
      <li><a class="link" href="#/chat/crisp_chat/<? echo $action[3];?>"><? echo $vis_language['TXTCRISPAPP'];?></a></li>
      <li><? echo $vis_language['TXTCHATTRANSCRIPT'];?></li>
    </ul>
  </div>
</section>
<section class="padder">
  <section class="panel panel-default">
    <div class="wrapper-sm">
    <!--<button type="button" class="btn btn-default btn-sm btn-block" data-toggle="ajaxModal" data-modal-arguments="vis_module=ticket&vis_operation=new_ticket_step_one&vis_static_area=vis_open_new_dialog&vis_email_id='<? echo $chat_object->visitor->email; ?>'&vis_client=1&vis_domain_id=<? echo $vis_domain; ?>"><? echo $vis_language['TXTADDTICKET']; ?></button>-->
    
      <div class="btn-group">
        <div class="form-group">
          <h5><? echo $vis_language['TXTCHATTRANSCRIPT'];?></h5>
        </div>
      </div>
    <div class="line b-b line-lg pull-in"></div>
    </div>
    <div class="row m-t">
      <div class="col-md-6">
	   
      <?php $start_time = format_datetime(substr(($allchat['data']['created_at']),0,-3)); ?>
        <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTDATE'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $start_time; ?></div>
        </div>
         
        <div class="row m-b-sm"> <span class="col-xs-3 text-right "><? echo $vis_language['TXTVISITORNAME'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo ucfirst($allchat['data']['meta']['nickname'] ); ?></div>
        </div>
        <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTVISITOREMAIL'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $allchat['data']['meta']['email'] ; ?></div>
        </div>
      </div>
      <div class="col-md-6">
	   <!-- <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTCHATURL'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $allchat['data']['meta']['pages'][0]['page_url'] ; ?></div>
        </div> -->
        <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTCOUNTRY'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $allchat['data']['meta']['browsing_informations']['geolocation']['country']; ?></div>
        </div>
        <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTSTAFFNAME'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $opertor_id['data'][0]['details']['first_name'].' ' ; ?><? echo $opertor_id['data'][0]['details']['last_name'].'' ; ?></div>
        </div>
		<div class="row m-b-sm"> <span class="col-xs-3 text-right"><? echo $vis_language['TXTSTAFFEMAIL'];?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? echo $opertor_id['data'][0]['details']['email'].' ' ; ?> </div>
        </div>
       <!-- <div class="row m-b-sm"> <span class="col-xs-3 text-right"><? //echo 'End time';?> :</span>
          <div class=" col-xs-9 text-lt text-muted"><? //echo $chat_object->TimeEnd; ?></div>
        </div>-->
          
      </div>
    </div>
    <!--<div class="line b-b line-lg pull-in"></div>-->
      <div class="wrapper m-b-sm">
        <div class="clear">
          <form name="vis_selfhelp_article_form" id="vis_selfhelp_article_form" class="form-horizontal" method="post">
            <br/>
            <h5><? echo $vis_language['TXTCONVERSATIONS'];?></h5>
            <div class="line b-b line-lg pull-in"></div>
            <br/>
            <?php
			 
			  for($i=0;$i<count($allchat['data']['messages']);$i++)
			  {
				   
				  echo '<div class="row m-b-sm">';
				  $chat_date = format_datetime(substr(($allchat['data']['messages'][$i]['timestamp']),0,-3));
				  echo '<div class="col-xs-2 text-right">['.$chat_date.']</div>';
				   
				  echo '<div class=" col-xs-10 text-lt text-muted">'.$allchat['data']['messages'][$i]['user']['nickname']. ' : ' .$allchat['data']['messages'][$i]['content'].'</div>
				        </div>';
					 
			  }

		    ?>
          </form>
		  <div class="row m-b-sm">
		   <div class="col-xs-2 text-right"> </div>
		    <div class=" col-xs-10 text-lt text-muted">
			<a href="javascript:void(0);" class="btn btn-primary" data-toggle="ajaxModal" data-modal-arguments="vis_module=ticket&vis_operation=new_ticket_step_one&vis_static_area=vis_open_new_dialog&vis_chat_type=crisp&vis_email_id=<? echo $allchat['data']['meta']['email']; ?>&vis_client=1&vis_domain_id=<? echo $vis_domain; ?>&vis_session_id=<? echo $action[3];?>&vis_website_id=<? echo $action[4]; ?>" onclick="" type="button"><? echo $vis_language['TXTCONVERTTOTICKET']; ?></a>
		 
		  </div>
		</div>
        </div>
    </div>
  </section>
</section>
 
 
 