Surface Google, Pinterest, Snapchat, and shipping status from the WordPress plugin with deep links to finish setup in WooCommerce. Co-authored-by: Cursor <cursoragent@cursor.com>
29 lines
772 B
PHP
29 lines
772 B
PHP
<?php
|
|
|
|
namespace App\Http\Controllers\Woo;
|
|
|
|
use App\Http\Controllers\Controller;
|
|
use App\Http\Controllers\Woo\Concerns\ResolvesWooContext;
|
|
use App\Services\Woo\IntegrationStatusService;
|
|
use Illuminate\Http\Request;
|
|
use Illuminate\View\View;
|
|
|
|
class IntegrationController extends Controller
|
|
{
|
|
use ResolvesWooContext;
|
|
|
|
public function __construct(private IntegrationStatusService $integrations) {}
|
|
|
|
public function index(Request $request): View
|
|
{
|
|
$store = $this->currentStore($request);
|
|
$payload = $this->integrations->forStore($store);
|
|
|
|
return view('woo.integrations.index', [
|
|
'store' => $store,
|
|
'reachable' => $payload['reachable'],
|
|
'integrations' => $payload['integrations'],
|
|
]);
|
|
}
|
|
}
|