Commit 0d84a29a by Jansa Jose

change in booked service

parent 32eb1a35
...@@ -203,6 +203,7 @@ class Product extends CI_Controller { ...@@ -203,6 +203,7 @@ class Product extends CI_Controller {
} }
$status = $this->Product_model->updateProductImage(decode_param($product_id),$evtMediaData,$existingImages); $status = $this->Product_model->updateProductImage(decode_param($product_id),$evtMediaData,$existingImages);
} }
}
if($status || $product){ if($status || $product){
$flashMsg =array('message'=>'Successfully Updated brand Details..!','class'=>'success'); $flashMsg =array('message'=>'Successfully Updated brand Details..!','class'=>'success');
$this->session->set_flashdata('message', $flashMsg); $this->session->set_flashdata('message', $flashMsg);
...@@ -213,10 +214,9 @@ class Product extends CI_Controller { ...@@ -213,10 +214,9 @@ class Product extends CI_Controller {
} }
} }
public function getProductData(){ public function getProductData(){
$return_arr = array('status'=>'0'); $return_arr = array('status'=>'0');
if(!isset($_POST) || empty($_POST) || !isset($_POST['product_id']) || empty($_POST['product_id']) || if(!isset($_POST) || empty($_POST) || !isset($_POST['product_id']) || empty($_POST['product_id']) || empty(decode_param($_POST['product_id']))){
empty(decode_param($_POST['product_id']))){
echo json_encode($return_arr);exit; echo json_encode($return_arr);exit;
} }
$product_id = decode_param($_POST['product_id']); $product_id = decode_param($_POST['product_id']);
...@@ -229,7 +229,6 @@ class Product extends CI_Controller { ...@@ -229,7 +229,6 @@ class Product extends CI_Controller {
echo json_encode($return_arr);exit; echo json_encode($return_arr);exit;
} }
public function exportProductData(){ public function exportProductData(){
$mechanic_id = ($this->session->userdata['user_type']==2)?$this->session->userdata['id']:''; $mechanic_id = ($this->session->userdata['user_type']==2)?$this->session->userdata['id']:'';
$productData = $this->Product_model->getProduct('',1,$mechanic_id); $productData = $this->Product_model->getProduct('',1,$mechanic_id);
......
...@@ -703,7 +703,7 @@ ...@@ -703,7 +703,7 @@
$headers = apache_request_headers(); $headers = apache_request_headers();
if(!isset($headers['Auth']) || empty($headers['Auth'])){ if(!isset($headers['Auth']) || empty($headers['Auth'])){
$respArr['status'] = 'error'; $respArr['status'] = 'error';
$respArr['message'] = 'Authtoken is Required'; $respArr['message'] = 'Authtoken is Required';
echo json_encode($respArr);exit; echo json_encode($respArr);exit;
} }
$authRes = $this->Webservice_model->get_customer_authtoken($headers['Auth']); $authRes = $this->Webservice_model->get_customer_authtoken($headers['Auth']);
......
...@@ -165,7 +165,7 @@ class Webservice_model extends CI_Model { ...@@ -165,7 +165,7 @@ class Webservice_model extends CI_Model {
if($type == 1){ if($type == 1){
$bookDetails = ",mechanic.location,mechanic.location_lat,mechanic.location_lng"; $bookDetails = ",mechanic.location,mechanic.location_lat,mechanic.location_lng";
} }
$this->db->select("bookings.booking_id as id,bookings.scheduled_date as booked_date,bookings.scheduled_time as time,customer_vehicle.vehicle_data,customer_vehicle.customer_veh_id as vehicle_id,customer_vehicle.customer_veh_id as year,customer_vehicle.customer_veh_id as vehcle_make,customer_vehicle.customer_veh_id as vehicle_type,bookings.mileage, $this->db->select("bookings.booking_id as id,bookings.scheduled_date as booked_date,bookings.scheduled_time as time,customer_vehicle.vehicle_data,customer_vehicle.customer_veh_id as vehicle_id,customer_vehicle.car_model_year as year,customer_vehicle.car_maker as vehcle_make,customer_vehicle.car_model as vehicle_type,bookings.mileage,
bookings.service_type as is_emergency,bookings.status as service_status,bookings.issues_selected,bookings.custom_issue_data".$bookDetails); bookings.service_type as is_emergency,bookings.status as service_status,bookings.issues_selected,bookings.custom_issue_data".$bookDetails);
$this->db->join('customer_vehicle','customer_vehicle.customer_veh_id = bookings.customer_veh_id'); $this->db->join('customer_vehicle','customer_vehicle.customer_veh_id = bookings.customer_veh_id');
if($type == 1){ if($type == 1){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment