Skip to content

Instantly share code, notes, and snippets.

View iaditya's full-sized avatar
🐢
Learning

Aditya Pansari iaditya

🐢
Learning
View GitHub Profile
public function updateCsv() {
if($this->request->session()->read('Auth.User.role') == "user") {
$facilityTable = TableRegistry::get('Facilities');
$facilities = $facilityTable->find('list');
$users = TableRegistry::get('Users');
if($this->request->is('post')) {
$file = $this->request->data['csv']['tmp_name'];
//debug($file); exit;
//debug ($_FILES['csv']['size']); exit;
$data = [
'recipientLists' => 'toPatientNoEmail',
'template' => 'toPatientNoEmail',
'vars' => [
'username' => '20161130-27821',
'name' => 'Aditya',
'role' => 'Provider',
'added_from' => 'Ketan',
'facility_name' => 'Happy Hippo Clinic'
// here , we are adding new invoice - 1
<?php echo $this->Html->script('arrive.min'); ?>
<div class="invoices form col-lg-10 col-md-9 columns">
<?php
$invoice_types = [
'op_new_consultation' => 'OP New Consultation',
// go to line 81 from first file -- 2nd file
<?php
$key = isset($key) ? $key : '<%= key %>';
$idkey = $key;
?>
<tr>
public function report($id)
{
$role = $this->request->session()->read('Auth.User.role');
$facilitiesTable = TableRegistry::get('Facilities');
$providersTable = TableRegistry::get('providers');
if ($role == "Provider") {
$provider_user_id = $this->request->session()->read('Auth.User.id');
$provider_id = $providersTable->findByUserId($provider_user_id)->first()->id;
<?php
echo $this->Html->script('moment/moment.min');
echo $this->Html->css('AdminLTE./plugins/datepicker/datepicker3');
echo $this->Html->css('AdminLTE./bootstrap/css/bootstrap-datetimepicker.min');
echo $this->Html->script('AdminLTE./bootstrap/js/bootstrap-datetimepicker');
echo $this->Html->script('AdminLTE./plugins/datepicker/bootstrap-datepicker');
?>
<script type="text/javascript">
<?php
/** System Mail Notification **/
$notificationManager->addTemplate('messageNotificationToPatient', [
'title' => 'New Message from :from_user.',
'body' => 'Hello :to_user, :from_user has sent you a message. Please check your mailbox on your talkaDoc Account.',
'smsbody' => 'Hello :to_user, :from_user has sent you a message. Please check your mailbox on your talkaDoc Account.'
]);
$notificationManager->addTemplate('messageNotificationToFAdmin', [
'title' => 'New Message from :from_user.',
<script type="text/javascript">
function showAjaxModal(id) {
// alert(id);
// jQuery('#issue_modal').modal('show', {backdrop: 'static'});
$("#issue_modal").modal();
jQuery.ajax({
type: 'GET',
<?php
echo $this->Html->script('moment/moment.min');
echo $this->Html->css('AdminLTE./plugins/datepicker/datepicker3');
echo $this->Html->css('AdminLTE./bootstrap/css/bootstrap-datetimepicker.min');
echo $this->Html->script('AdminLTE./bootstrap/js/bootstrap-datetimepicker');
echo $this->Html->script('AdminLTE./plugins/datepicker/bootstrap-datepicker');
?>
<script type="text/javascript">
select: function(startDate, endDate, jsEvent, view,resource) {
// here startDate and endDate will give you the date-range selected
//alert(startDate);
//alert(slotType);
console.log(view);
if (!startDate.hasTime()) {
// alert("Date has time: " + startDate.hasTime());
return false;
// should be all-day
}