antragstracker/static/_app/immutable/nodes/2.CLqOxIAV.js
Dotty Dotter 9d8a73e2a9 feat: Parteien-Filter, Klassifikation, Umsetzungsbewertung, KI-Neubewertung
- Vorlagen + Ketten: Partei-Dropdown-Filter mit Badges (#9)
- Vorlagen-Detail: Ketten-Klassifikation mit Begründung anzeigen
- Vorlagen-Detail: Umsetzungsbewertungen mit Score + Begründung
- SPA-Routing: Catch-All für direkten URL-Zugriff
- Status-Engine: Begründungen für alle Ketten-Status generieren
- Kurze Beschlusstexte (<=5 Zeichen) nicht mehr als Beschluss werten
- POST /api/bewertung/vorlagen/{id} + /ketten/{id} für KI-Neubewertung
- Frontend: 'Neu bewerten' Button + Kommentarfeld auf beiden Detailseiten
- Job-Status-Polling mit Spinner
- ALLRIS-Rescrape vor Bewertung noch offen (#10)

Closes #9
2026-04-01 10:36:22 +02:00

2 lines
4.1 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{a as l,f as v}from"../chunks/Bkzsmr9I.js";import{p as S,s as $,t as m,a as u,g as o,e as Q,$ as T,b as d,c as s,r as a,n as _}from"../chunks/Cjw4vZKn.js";import{s as n}from"../chunks/DfJQ0EIT.js";import{i as U}from"../chunks/kjB3f-xG.js";import{h as W,e as X,i as Y}from"../chunks/DaCWmHjB.js";/* empty css */var ee=v('<div class="p-6 text-center text-red-500"> </div>'),te=v('<div class="p-6 text-center text-gray-500"> </div>'),ae=v('<div class="p-6 text-center text-gray-500">Keine Anträge gefunden</div>'),se=v('<li class="px-6 py-4 hover:bg-gray-50 cursor-pointer"><div class="flex justify-between items-start"><div class="flex-1"><div class="flex items-center gap-2"><span class="font-mono text-sm text-green-700 bg-green-50 px-2 py-0.5 rounded"> </span> <span class="text-xs text-gray-400"> </span></div> <p class="mt-1 text-gray-700 line-clamp-2"> </p></div> <span class="text-xs px-2 py-1 rounded-full bg-yellow-100 text-yellow-800">⏳ offen</span></div></li>'),re=v('<ul class="divide-y divide-gray-100"></ul>'),oe=v('<main class="min-h-screen bg-gray-50"><header class="bg-green-700 text-white py-6 shadow-lg"><div class="max-w-6xl mx-auto px-4"><h1 class="text-3xl font-bold">🏛️ Antragstracker Hagen</h1> <p class="text-green-100 mt-1">Kommunale Anträge & Anfragen nachverfolgen</p></div></header> <div class="max-w-6xl mx-auto px-4 py-8"><div class="grid grid-cols-2 md:grid-cols-4 gap-4 mb-8"><div class="bg-white rounded-lg shadow p-4 text-center"><div class="text-3xl font-bold text-green-600"> </div> <div class="text-gray-500 text-sm">Vorlagen</div></div> <div class="bg-white rounded-lg shadow p-4 text-center"><div class="text-3xl font-bold text-blue-600"> </div> <div class="text-gray-500 text-sm">Ketten</div></div> <div class="bg-white rounded-lg shadow p-4 text-center"><div class="text-3xl font-bold text-purple-600">41</div> <div class="text-gray-500 text-sm">Gremien</div></div> <div class="bg-white rounded-lg shadow p-4 text-center"><div class="text-3xl font-bold text-orange-600">20042026</div> <div class="text-gray-500 text-sm">Zeitraum</div></div></div> <section class="bg-white rounded-lg shadow"><div class="px-6 py-4 border-b border-gray-200"><h2 class="text-xl font-semibold text-gray-800">📋 Aktuelle Anträge</h2></div> <!></section></div></main>');function ge(K){let g=S({vorlagen:0,beratungen:0,ketten:0,gremien:0}),x=$(S([])),R=$(!0),p=$("");const i=typeof window<"u"&&window.location.port==="5173"?`http://${window.location.hostname}:8099/api`:"/api";async function B(){console.log("API_BASE:",i);try{console.log("Fetching health...");const e=await fetch(`${i}/health`);if(console.log("Health response:",e.status),e.ok){console.log("Fetching vorlagen...");const r=await fetch(`${i}/vorlagen?page_size=1`);console.log("Vorlagen response:",r.status);const c=await r.json();g.vorlagen=c.total;const f=await(await fetch(`${i}/ketten?page_size=1`)).json();g.ketten=f.total}else u(p,`Health check failed: ${e.status}`);const t=await fetch(`${i}/vorlagen?typ=antrag&page_size=10`);if(console.log("Antraege response:",t.status),t.ok){const r=await t.json();console.log("Antraege data:",r.items.length),u(x,r.items,!0)}}catch(e){console.error("API Fehler:",e),u(p,`Fehler: ${e}`)}finally{u(R,!1),console.log("Loading done, antraege:",o(x).length)}}B();var w=oe();W("1uha8ag",e=>{Q(()=>{T.title="Antragstracker Hagen"})});var j=d(s(w),2),y=s(j),b=s(y),z=s(b),E=s(z,!0);a(z),_(2),a(b);var D=d(b,2),F=s(D),V=s(F,!0);a(F),_(2),a(D),_(4),a(y);var H=d(y,2),G=d(s(H),2);{var Z=e=>{var t=ee(),r=s(t,!0);a(t),m(()=>n(r,o(p))),l(e,t)},q=e=>{var t=te(),r=s(t);a(t),m(()=>n(r,`Lade Daten... (API: ${i})`)),l(e,t)},C=e=>{var t=ae();l(e,t)},J=e=>{var t=re();X(t,21,()=>o(x),Y,(r,c)=>{var h=se(),f=s(h),I=s(f),k=s(I),A=s(k),M=s(A,!0);a(A);var L=d(A,2),N=s(L,!0);a(L),a(k);var P=d(k,2),O=s(P,!0);a(P),a(I),_(2),a(f),a(h),m(()=>{n(M,o(c).aktenzeichen),n(N,o(c).datum_eingang),n(O,o(c).betreff)}),l(r,h)}),a(t),l(e,t)};U(G,e=>{o(p)?e(Z):o(R)?e(q,1):o(x).length===0?e(C,2):e(J,-1)})}a(H),a(j),a(w),m((e,t)=>{n(E,e),n(V,t)},[()=>g.vorlagen.toLocaleString(),()=>g.ketten.toLocaleString()]),l(K,w)}export{ge as component};