app/Http/Controllers/Customers/CustomerContactsController.php 1 location
|
@@ 166-176 (lines=11) @@
|
| 163 |
|
} |
| 164 |
|
|
| 165 |
|
// Delete an existing contact |
| 166 |
|
public function destroy($id) |
| 167 |
|
{ |
| 168 |
|
$cont = CustomerContacts::find($id); |
| 169 |
|
|
| 170 |
|
Log::debug('Route '.Route::currentRouteName().' visited by '.Auth::user()->full_name); |
| 171 |
|
Log::info('Customer Contact deleted for Customer ID-'.$cont->cust_id.' by User ID-'.Auth::user()->full_name.'. Deleted Contact ID-'.$id); |
| 172 |
|
|
| 173 |
|
$cont->delete(); |
| 174 |
|
|
| 175 |
|
return response()->json(['success' => true]); |
| 176 |
|
} |
| 177 |
|
} |
| 178 |
|
|
app/Http/Controllers/Customers/CustomerSystemsController.php 1 location
|
@@ 143-155 (lines=13) @@
|
| 140 |
|
} |
| 141 |
|
|
| 142 |
|
// Delete a system attached to a customer |
| 143 |
|
public function destroy($id) |
| 144 |
|
{ |
| 145 |
|
Log::debug('Route ' . Route::currentRouteName() . ' visited by ' . Auth::user()->full_name); |
| 146 |
|
|
| 147 |
|
// return response('deleted '.$id); |
| 148 |
|
$system = CustomerSystems::find($id); |
| 149 |
|
|
| 150 |
|
Log::notice('Customer System Deleted for Customer ID-'.$system->cust_id.' by '.Auth::user()->full_name.'. System ID-'.$id); |
| 151 |
|
|
| 152 |
|
$system->delete(); |
| 153 |
|
|
| 154 |
|
return response()->json(['success' => true]); |
| 155 |
|
} |
| 156 |
|
} |
| 157 |
|
|