Extend integrations hub with more channels, caching, and refresh.

Cache per-store status for five minutes, add TikTok/Reddit/Meta cards, and let merchants refresh without reloading WordPress on every visit.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-07-08 07:37:41 +00:00
co-authored by Cursor
parent 5a0022af72
commit 1b0831b176
8 changed files with 162 additions and 11 deletions
@@ -22,7 +22,20 @@ class IntegrationController extends Controller
return view('woo.integrations.index', [
'store' => $store,
'reachable' => $payload['reachable'],
'cached' => (bool) ($payload['cached'] ?? false),
'integrations' => $payload['integrations'],
]);
}
public function refresh(Request $request): \Illuminate\Http\RedirectResponse
{
$store = $this->currentStore($request);
if ($store) {
$this->integrations->forStore($store, refresh: true);
}
return redirect()
->route('woo.integrations.index')
->with('status', 'Integration status refreshed.');
}
}