order cancell started

This commit is contained in:
merdan 2022-03-17 16:33:15 +05:00
parent 74cb937809
commit f10a8bbc9c
3 changed files with 13 additions and 0 deletions

View File

@ -20,4 +20,8 @@ class Orders extends OrderController
return view($this->_config['view']);
}
public function cancelOrderItem($item_id){
}
}

View File

@ -294,6 +294,7 @@
<th>{{ __('admin::app.sales.orders.discount-amount') }}</th>
@endif
<th>{{ __('admin::app.sales.orders.grand-total') }}</th>
<th>{{ __('admin::app.sales.invoices.action') }}</th>
</tr>
</thead>
@ -351,6 +352,11 @@
@endif
<td>{{ core()->formatPrice($item->total + $item->tax_amount - $item->discount_amount,$order->order_currency_code) }}</td>
<td class="action">
<a href="{{ route('admin.sales.orders.cancel_item', $item->id) }}">
<i class="icon trash-icon"></i>
</a>
</td>
</tr>
@endforeach
</table>

View File

@ -12,5 +12,8 @@ Route::group(['middleware' => ['web', 'admin', 'admin_locale'], 'prefix' => conf
Route::get('/orders', [\Sarga\Admin\Http\Controllers\Orders::class, 'index'])->defaults('_config', [
'view' => 'admin::sales.orders.index',
])->name('admin.sales.orders.index');
Route::post('/orders/item/{id}/cancel', [\Sarga\Admin\Http\Controllers\Orders::class, 'cancelOrderItem'])
->name('admin.sales.orders.cancel_item');
});
});