mijn_profiel_widget.dart 173 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675
  1. import '/backend/api_requests/api_calls.dart';
  2. import '/components/header_buttons_component_widget.dart';
  3. import '/flutter_flow/flutter_flow_icon_button.dart';
  4. import '/flutter_flow/flutter_flow_language_selector.dart';
  5. import '/flutter_flow/flutter_flow_theme.dart';
  6. import '/flutter_flow/flutter_flow_util.dart';
  7. import '/flutter_flow/flutter_flow_widgets.dart';
  8. import '/horecagelegenhedenoverzicht/horecagelegenheidoverzicht_kaart/horecagelegenheidoverzicht_kaart_widget.dart';
  9. import '/shared/drawer_component/drawer_component_widget.dart';
  10. import '/shared/lege_lijst_component/lege_lijst_component_widget.dart';
  11. import 'dart:ui';
  12. import '/custom_code/actions/index.dart' as actions;
  13. import '/flutter_flow/custom_functions.dart' as functions;
  14. import '/index.dart';
  15. import 'package:aligned_tooltip/aligned_tooltip.dart';
  16. import 'package:flutter/material.dart';
  17. import 'package:flutter/scheduler.dart';
  18. import 'package:flutter_spinkit/flutter_spinkit.dart';
  19. import 'package:google_fonts/google_fonts.dart';
  20. import 'package:provider/provider.dart';
  21. import 'mijn_profiel_model.dart';
  22. export 'mijn_profiel_model.dart';
  23. class MijnProfielWidget extends StatefulWidget {
  24. const MijnProfielWidget({
  25. super.key,
  26. int? tabIndex,
  27. }) : this.tabIndex = tabIndex ?? 0;
  28. final int tabIndex;
  29. static String routeName = 'mijnProfiel';
  30. static String routePath = '/mijnProfiel';
  31. @override
  32. State<MijnProfielWidget> createState() => _MijnProfielWidgetState();
  33. }
  34. class _MijnProfielWidgetState extends State<MijnProfielWidget>
  35. with TickerProviderStateMixin, RouteAware {
  36. late MijnProfielModel _model;
  37. final scaffoldKey = GlobalKey<ScaffoldState>();
  38. @override
  39. void initState() {
  40. super.initState();
  41. _model = createModel(context, () => MijnProfielModel());
  42. // On page load action.
  43. SchedulerBinding.instance.addPostFrameCallback((_) async {
  44. _model.apiResultvpn = await MijnHorecagelegenhedenCall.call(
  45. sessionName: FFAppState().userSessionname,
  46. sessid: FFAppState().userSessionid,
  47. );
  48. if ((_model.apiResultvpn?.succeeded ?? true)) {
  49. _model.mijnHorecaRespons =
  50. (_model.apiResultvpn?.jsonBody ?? '').toList().cast<dynamic>();
  51. safeSetState(() {});
  52. }
  53. _model.apiResultFavGem = await FavorietenGemeentenCall.call(
  54. sessionName: FFAppState().userSessionname,
  55. sessid: FFAppState().userSessionid,
  56. );
  57. if ((_model.apiResultFavGem?.succeeded ?? true)) {
  58. _model.favGemeenten = getJsonField(
  59. (_model.apiResultFavGem?.jsonBody ?? ''),
  60. r'''$''',
  61. true,
  62. )!
  63. .toList()
  64. .cast<dynamic>();
  65. safeSetState(() {});
  66. }
  67. });
  68. _model.tabBarmijnevenementenController = TabController(
  69. vsync: this,
  70. length: 4,
  71. initialIndex: min(
  72. valueOrDefault<int>(
  73. widget!.tabIndex,
  74. 0,
  75. ),
  76. 3),
  77. )
  78. ..addListener(() => safeSetState(() {}))
  79. ..addListener(() {
  80. debugLogWidgetClass(_model);
  81. });
  82. }
  83. @override
  84. void dispose() {
  85. routeObserver.unsubscribe(this);
  86. _model.dispose();
  87. super.dispose();
  88. }
  89. @override
  90. void didUpdateWidget(MijnProfielWidget oldWidget) {
  91. super.didUpdateWidget(oldWidget);
  92. _model.widget = widget;
  93. }
  94. @override
  95. void didChangeDependencies() {
  96. super.didChangeDependencies();
  97. final route = DebugModalRoute.of(context);
  98. if (route != null) {
  99. routeObserver.subscribe(this, route);
  100. }
  101. debugLogGlobalProperty(context);
  102. }
  103. @override
  104. void didPopNext() {
  105. if (mounted && DebugFlutterFlowModelContext.maybeOf(context) == null) {
  106. setState(() => _model.isRouteVisible = true);
  107. debugLogWidgetClass(_model);
  108. }
  109. }
  110. @override
  111. void didPush() {
  112. if (mounted && DebugFlutterFlowModelContext.maybeOf(context) == null) {
  113. setState(() => _model.isRouteVisible = true);
  114. debugLogWidgetClass(_model);
  115. }
  116. }
  117. @override
  118. void didPop() {
  119. _model.isRouteVisible = false;
  120. }
  121. @override
  122. void didPushNext() {
  123. _model.isRouteVisible = false;
  124. }
  125. @override
  126. Widget build(BuildContext context) {
  127. DebugFlutterFlowModelContext.maybeOf(context)
  128. ?.parentModelCallback
  129. ?.call(_model);
  130. context.watch<FFAppState>();
  131. _model.horecagelegenheidoverzichtKaartModels.clear();
  132. return GestureDetector(
  133. onTap: () {
  134. FocusScope.of(context).unfocus();
  135. FocusManager.instance.primaryFocus?.unfocus();
  136. },
  137. child: Scaffold(
  138. key: scaffoldKey,
  139. backgroundColor: FlutterFlowTheme.of(context).primaryBackground,
  140. drawer: Drawer(
  141. elevation: 16.0,
  142. child: wrapWithModel(
  143. model: _model.drawerComponentModel,
  144. updateCallback: () => safeSetState(() {}),
  145. child: Builder(builder: (_) {
  146. return DebugFlutterFlowModelContext(
  147. rootModel: _model.rootModel,
  148. child: DrawerComponentWidget(),
  149. );
  150. }),
  151. ),
  152. ),
  153. appBar: PreferredSize(
  154. preferredSize: Size.fromHeight(80.0),
  155. child: AppBar(
  156. backgroundColor: FlutterFlowTheme.of(context).primaryText,
  157. automaticallyImplyLeading: false,
  158. actions: [],
  159. flexibleSpace: FlexibleSpaceBar(
  160. background: wrapWithModel(
  161. model: _model.headerButtonsComponentModel,
  162. updateCallback: () => safeSetState(() {}),
  163. child: Builder(builder: (_) {
  164. return DebugFlutterFlowModelContext(
  165. rootModel: _model.rootModel,
  166. child: HeaderButtonsComponentWidget(
  167. showBackButton: true,
  168. ),
  169. );
  170. }),
  171. ),
  172. centerTitle: true,
  173. expandedTitleScale: 1.0,
  174. ),
  175. bottom: PreferredSize(
  176. preferredSize: Size.fromHeight(70.0),
  177. child: Container(),
  178. ),
  179. toolbarHeight: MediaQuery.sizeOf(context).height * 0.25,
  180. elevation: 2.0,
  181. ),
  182. ),
  183. body: SafeArea(
  184. top: true,
  185. child: Padding(
  186. padding: EdgeInsets.all(16.0),
  187. child: Column(
  188. mainAxisSize: MainAxisSize.max,
  189. children: [
  190. Expanded(
  191. child: Column(
  192. children: [
  193. Align(
  194. alignment: Alignment(0.0, 0),
  195. child: TabBar(
  196. isScrollable: true,
  197. tabAlignment: TabAlignment.center,
  198. labelColor: FlutterFlowTheme.of(context).primaryText,
  199. unselectedLabelColor:
  200. FlutterFlowTheme.of(context).secondaryText,
  201. labelStyle:
  202. FlutterFlowTheme.of(context).titleMedium.override(
  203. font: GoogleFonts.roboto(
  204. fontWeight: FlutterFlowTheme.of(context)
  205. .titleMedium
  206. .fontWeight,
  207. fontStyle: FlutterFlowTheme.of(context)
  208. .titleMedium
  209. .fontStyle,
  210. ),
  211. letterSpacing: 0.0,
  212. fontWeight: FlutterFlowTheme.of(context)
  213. .titleMedium
  214. .fontWeight,
  215. fontStyle: FlutterFlowTheme.of(context)
  216. .titleMedium
  217. .fontStyle,
  218. ),
  219. unselectedLabelStyle:
  220. FlutterFlowTheme.of(context).titleMedium.override(
  221. font: GoogleFonts.roboto(
  222. fontWeight: FlutterFlowTheme.of(context)
  223. .titleMedium
  224. .fontWeight,
  225. fontStyle: FlutterFlowTheme.of(context)
  226. .titleMedium
  227. .fontStyle,
  228. ),
  229. letterSpacing: 0.0,
  230. fontWeight: FlutterFlowTheme.of(context)
  231. .titleMedium
  232. .fontWeight,
  233. fontStyle: FlutterFlowTheme.of(context)
  234. .titleMedium
  235. .fontStyle,
  236. ),
  237. indicatorColor:
  238. FlutterFlowTheme.of(context).secondary,
  239. tabs: [
  240. Tab(
  241. text: FFLocalizations.of(context).getText(
  242. 'p45zqsya' /* Mijn evenementen */,
  243. ),
  244. ),
  245. Tab(
  246. text: FFLocalizations.of(context).getText(
  247. 'lt5ws43d' /* Stadseditor */,
  248. ),
  249. ),
  250. Tab(
  251. text: FFLocalizations.of(context).getText(
  252. 'hwmb9ntf' /* Account */,
  253. ),
  254. ),
  255. Tab(
  256. text: FFLocalizations.of(context).getText(
  257. '9s07bzb1' /* Nieuwsbrieven */,
  258. ),
  259. ),
  260. ],
  261. controller: _model.tabBarmijnevenementenController,
  262. onTap: (i) async {
  263. [
  264. () async {},
  265. () async {},
  266. () async {},
  267. () async {}
  268. ][i]();
  269. },
  270. ),
  271. ),
  272. Expanded(
  273. child: TabBarView(
  274. controller: _model.tabBarmijnevenementenController,
  275. children: [
  276. SingleChildScrollView(
  277. child: Column(
  278. mainAxisSize: MainAxisSize.max,
  279. children: [
  280. if (_model.mijnHorecaRespons.isNotEmpty)
  281. Row(
  282. mainAxisSize: MainAxisSize.max,
  283. mainAxisAlignment:
  284. MainAxisAlignment.spaceBetween,
  285. children: [
  286. Text(
  287. FFLocalizations.of(context).getText(
  288. '70jtz6zq' /* Komende evenementen */,
  289. ),
  290. style: FlutterFlowTheme.of(context)
  291. .titleMedium
  292. .override(
  293. font: GoogleFonts.roboto(
  294. fontWeight:
  295. FlutterFlowTheme.of(
  296. context)
  297. .titleMedium
  298. .fontWeight,
  299. fontStyle:
  300. FlutterFlowTheme.of(
  301. context)
  302. .titleMedium
  303. .fontStyle,
  304. ),
  305. letterSpacing: 0.0,
  306. fontWeight:
  307. FlutterFlowTheme.of(context)
  308. .titleMedium
  309. .fontWeight,
  310. fontStyle:
  311. FlutterFlowTheme.of(context)
  312. .titleMedium
  313. .fontStyle,
  314. ),
  315. ),
  316. FFButtonWidget(
  317. onPressed: () async {
  318. context.pushNamed(
  319. MijnAanmeldingenWidget.routeName,
  320. queryParameters: {
  321. 'type': serializeParam(
  322. 'go_out_event',
  323. ParamType.String,
  324. ),
  325. }.withoutNulls,
  326. );
  327. },
  328. text: FFLocalizations.of(context)
  329. .getText(
  330. 'x70608fh' /* Bekijk alles */,
  331. ),
  332. options: FFButtonOptions(
  333. height: 40.0,
  334. padding:
  335. EdgeInsetsDirectional.fromSTEB(
  336. 16.0, 0.0, 16.0, 0.0),
  337. iconPadding:
  338. EdgeInsetsDirectional.fromSTEB(
  339. 0.0, 0.0, 0.0, 0.0),
  340. color: FlutterFlowTheme.of(context)
  341. .secondary,
  342. textStyle:
  343. FlutterFlowTheme.of(context)
  344. .titleSmall
  345. .override(
  346. font: GoogleFonts.roboto(
  347. fontWeight:
  348. FlutterFlowTheme.of(
  349. context)
  350. .titleSmall
  351. .fontWeight,
  352. fontStyle:
  353. FlutterFlowTheme.of(
  354. context)
  355. .titleSmall
  356. .fontStyle,
  357. ),
  358. color: Colors.white,
  359. letterSpacing: 0.0,
  360. fontWeight:
  361. FlutterFlowTheme.of(
  362. context)
  363. .titleSmall
  364. .fontWeight,
  365. fontStyle:
  366. FlutterFlowTheme.of(
  367. context)
  368. .titleSmall
  369. .fontStyle,
  370. ),
  371. elevation: 0.0,
  372. borderRadius:
  373. BorderRadius.circular(8.0),
  374. ),
  375. ),
  376. ],
  377. ),
  378. if (_model.mijnHorecaRespons.isNotEmpty)
  379. FutureBuilder<ApiCallResponse>(
  380. future: MijnAanmeldingenCall.call(
  381. sessionName:
  382. FFAppState().userSessionname,
  383. sessid: FFAppState().userSessionid,
  384. limit: 5,
  385. type: 'go_out_event',
  386. komend: '1',
  387. ),
  388. builder: (context, snapshot) {
  389. // Customize what your widget looks like when it's loading.
  390. if (!snapshot.hasData) {
  391. return Center(
  392. child: SizedBox(
  393. width: 80.0,
  394. height: 80.0,
  395. child: SpinKitFadingCircle(
  396. color:
  397. FlutterFlowTheme.of(context)
  398. .primary,
  399. size: 80.0,
  400. ),
  401. ),
  402. );
  403. }
  404. final listViewMijnAanmeldingenResponse =
  405. snapshot.data!;
  406. _model.debugBackendQueries[
  407. 'MijnAanmeldingenCall_statusCode_ListView_pnx616wd'] =
  408. debugSerializeParam(
  409. listViewMijnAanmeldingenResponse
  410. .statusCode,
  411. ParamType.int,
  412. link:
  413. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  414. name: 'int',
  415. nullable: false,
  416. );
  417. _model.debugBackendQueries[
  418. 'MijnAanmeldingenCall_responseBody_ListView_pnx616wd'] =
  419. debugSerializeParam(
  420. listViewMijnAanmeldingenResponse
  421. .bodyText,
  422. ParamType.String,
  423. link:
  424. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  425. name: 'String',
  426. nullable: false,
  427. );
  428. debugLogWidgetClass(_model);
  429. return Builder(
  430. builder: (context) {
  431. final aanmeldingItem =
  432. MijnAanmeldingenCall.items(
  433. listViewMijnAanmeldingenResponse
  434. .jsonBody,
  435. )?.toList() ??
  436. [];
  437. if (aanmeldingItem.isEmpty) {
  438. return LegeLijstComponentWidget(
  439. tekst:
  440. 'Je hebt nog geen komende evenementen aangemaakt. Hiervoor moet je eigenaar zijn van een horecagelegenheid.',
  441. );
  442. }
  443. _model.debugGeneratorVariables[
  444. 'aanmeldingItem${aanmeldingItem.length > 100 ? ' (first 100)' : ''}'] =
  445. debugSerializeParam(
  446. aanmeldingItem.take(100),
  447. ParamType.JSON,
  448. isList: true,
  449. link:
  450. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  451. name: 'dynamic',
  452. nullable: false,
  453. );
  454. debugLogWidgetClass(_model);
  455. return ListView.builder(
  456. padding: EdgeInsets.zero,
  457. shrinkWrap: true,
  458. scrollDirection: Axis.vertical,
  459. itemCount: aanmeldingItem.length,
  460. itemBuilder: (context,
  461. aanmeldingItemIndex) {
  462. final aanmeldingItemItem =
  463. aanmeldingItem[
  464. aanmeldingItemIndex];
  465. return Padding(
  466. padding: EdgeInsetsDirectional
  467. .fromSTEB(
  468. 0.0, 0.0, 0.0, 12.0),
  469. child: Column(
  470. mainAxisSize:
  471. MainAxisSize.max,
  472. children: [
  473. Stack(
  474. children: [
  475. Container(
  476. width:
  477. double.infinity,
  478. decoration:
  479. BoxDecoration(),
  480. child: InkWell(
  481. splashColor: Colors
  482. .transparent,
  483. focusColor: Colors
  484. .transparent,
  485. hoverColor: Colors
  486. .transparent,
  487. highlightColor:
  488. Colors
  489. .transparent,
  490. onTap: () async {
  491. if (functions
  492. .isOngepubliceerd(
  493. aanmeldingItemItem)) {
  494. ScaffoldMessenger.of(
  495. context)
  496. .showSnackBar(
  497. SnackBar(
  498. content:
  499. Text(
  500. 'Dit item staat nog in beoordeling en is nog niet online.',
  501. style:
  502. TextStyle(
  503. color:
  504. FlutterFlowTheme.of(context).primaryText,
  505. ),
  506. ),
  507. duration: Duration(
  508. milliseconds:
  509. 4000),
  510. backgroundColor:
  511. FlutterFlowTheme.of(context)
  512. .secondary,
  513. ),
  514. );
  515. } else {
  516. context
  517. .pushNamed(
  518. EventCurrentWidget
  519. .routeName,
  520. queryParameters:
  521. {
  522. 'nid':
  523. serializeParam(
  524. getJsonField(
  525. aanmeldingItemItem,
  526. r'''$.nid''',
  527. ).toString(),
  528. ParamType
  529. .String,
  530. ),
  531. }.withoutNulls,
  532. );
  533. }
  534. },
  535. child: Material(
  536. color: Colors
  537. .transparent,
  538. child: ListTile(
  539. title: Text(
  540. getJsonField(
  541. aanmeldingItemItem,
  542. r'''$.title''',
  543. ).toString(),
  544. style: FlutterFlowTheme.of(
  545. context)
  546. .titleLarge
  547. .override(
  548. font:
  549. GoogleFonts.roboto(
  550. fontWeight:
  551. FlutterFlowTheme.of(context).titleLarge.fontWeight,
  552. fontStyle:
  553. FlutterFlowTheme.of(context).titleLarge.fontStyle,
  554. ),
  555. letterSpacing:
  556. 0.0,
  557. fontWeight: FlutterFlowTheme.of(context)
  558. .titleLarge
  559. .fontWeight,
  560. fontStyle: FlutterFlowTheme.of(context)
  561. .titleLarge
  562. .fontStyle,
  563. ),
  564. ),
  565. subtitle:
  566. Text(
  567. getJsonField(
  568. aanmeldingItemItem,
  569. r'''$.datum_start''',
  570. ).toString(),
  571. style: FlutterFlowTheme.of(
  572. context)
  573. .labelMedium
  574. .override(
  575. font:
  576. GoogleFonts.roboto(
  577. fontWeight:
  578. FlutterFlowTheme.of(context).labelMedium.fontWeight,
  579. fontStyle:
  580. FlutterFlowTheme.of(context).labelMedium.fontStyle,
  581. ),
  582. letterSpacing:
  583. 0.0,
  584. fontWeight: FlutterFlowTheme.of(context)
  585. .labelMedium
  586. .fontWeight,
  587. fontStyle: FlutterFlowTheme.of(context)
  588. .labelMedium
  589. .fontStyle,
  590. ),
  591. ),
  592. tileColor: FlutterFlowTheme.of(
  593. context)
  594. .secondaryBackground,
  595. dense: false,
  596. contentPadding:
  597. EdgeInsetsDirectional.fromSTEB(
  598. 12.0,
  599. 0.0,
  600. 52.0,
  601. 0.0),
  602. shape:
  603. RoundedRectangleBorder(
  604. borderRadius:
  605. BorderRadius.circular(
  606. 8.0),
  607. ),
  608. ),
  609. ),
  610. ),
  611. ),
  612. Align(
  613. alignment:
  614. AlignmentDirectional(
  615. 1.0, 0.0),
  616. child: Padding(
  617. padding:
  618. EdgeInsetsDirectional
  619. .fromSTEB(
  620. 0.0,
  621. 0.0,
  622. 4.0,
  623. 0.0),
  624. child:
  625. AlignedTooltip(
  626. content:
  627. Padding(
  628. padding:
  629. EdgeInsets
  630. .all(
  631. 4.0),
  632. child: Text(
  633. FFLocalizations.of(
  634. context)
  635. .getText(
  636. '8mxemaqc' /* Kopieer naar een nieuw eveneme... */,
  637. ),
  638. style: FlutterFlowTheme.of(
  639. context)
  640. .bodyLarge
  641. .override(
  642. font:
  643. GoogleFonts.roboto(
  644. fontWeight:
  645. FlutterFlowTheme.of(context).bodyLarge.fontWeight,
  646. fontStyle:
  647. FlutterFlowTheme.of(context).bodyLarge.fontStyle,
  648. ),
  649. letterSpacing:
  650. 0.0,
  651. fontWeight: FlutterFlowTheme.of(context)
  652. .bodyLarge
  653. .fontWeight,
  654. fontStyle: FlutterFlowTheme.of(context)
  655. .bodyLarge
  656. .fontStyle,
  657. ),
  658. ),
  659. ),
  660. offset: 4.0,
  661. preferredDirection:
  662. AxisDirection
  663. .down,
  664. borderRadius:
  665. BorderRadius
  666. .circular(
  667. 8.0),
  668. backgroundColor:
  669. FlutterFlowTheme.of(
  670. context)
  671. .secondaryBackground,
  672. elevation: 4.0,
  673. tailBaseWidth:
  674. 24.0,
  675. tailLength:
  676. 12.0,
  677. waitDuration:
  678. Duration(
  679. milliseconds:
  680. 100),
  681. showDuration:
  682. Duration(
  683. milliseconds:
  684. 1500),
  685. triggerMode:
  686. TooltipTriggerMode
  687. .longPress,
  688. child:
  689. FlutterFlowIconButton(
  690. borderRadius:
  691. 8.0,
  692. buttonSize:
  693. 34.0,
  694. fillColor: FlutterFlowTheme.of(
  695. context)
  696. .primaryBackground,
  697. icon: Icon(
  698. Icons
  699. .content_copy,
  700. color: FlutterFlowTheme.of(
  701. context)
  702. .secondary,
  703. size: 20.0,
  704. ),
  705. onPressed:
  706. () async {
  707. _model.apiResultmls =
  708. await AanmeldingKloonbronCall
  709. .call(
  710. sessionName:
  711. FFAppState()
  712. .userSessionname,
  713. sessid: FFAppState()
  714. .userSessionid,
  715. nid:
  716. getJsonField(
  717. aanmeldingItemItem,
  718. r'''$.nid''',
  719. ).toString(),
  720. );
  721. if ((_model
  722. .apiResultmls
  723. ?.succeeded ??
  724. true)) {
  725. FFAppState()
  726. .kloonBron = (_model
  727. .apiResultmls
  728. ?.jsonBody ??
  729. '');
  730. safeSetState(
  731. () {});
  732. context
  733. .pushNamed(
  734. UitgaansevenementAanmakenWidget
  735. .routeName,
  736. queryParameters:
  737. {
  738. 'horecagelegenheidNid':
  739. serializeParam(
  740. getJsonField(
  741. aanmeldingItemItem,
  742. r'''$.horecagelegenheidnid''',
  743. ).toString(),
  744. ParamType.String,
  745. ),
  746. }.withoutNulls,
  747. );
  748. }
  749. safeSetState(
  750. () {});
  751. },
  752. ),
  753. ),
  754. ),
  755. ),
  756. ],
  757. ),
  758. ],
  759. ),
  760. );
  761. },
  762. );
  763. },
  764. );
  765. },
  766. ),
  767. Row(
  768. mainAxisSize: MainAxisSize.max,
  769. mainAxisAlignment:
  770. MainAxisAlignment.spaceBetween,
  771. children: [
  772. Text(
  773. FFLocalizations.of(context).getText(
  774. 'aiokgolu' /* Mijn horecagelegenheden */,
  775. ),
  776. style: FlutterFlowTheme.of(context)
  777. .titleMedium
  778. .override(
  779. font: GoogleFonts.roboto(
  780. fontWeight:
  781. FlutterFlowTheme.of(context)
  782. .titleMedium
  783. .fontWeight,
  784. fontStyle:
  785. FlutterFlowTheme.of(context)
  786. .titleMedium
  787. .fontStyle,
  788. ),
  789. letterSpacing: 0.0,
  790. fontWeight:
  791. FlutterFlowTheme.of(context)
  792. .titleMedium
  793. .fontWeight,
  794. fontStyle:
  795. FlutterFlowTheme.of(context)
  796. .titleMedium
  797. .fontStyle,
  798. ),
  799. ),
  800. FFButtonWidget(
  801. onPressed: () async {
  802. await launchURL(
  803. 'https://uitgaanskrant.com/en/ondernemers#aanmaken');
  804. },
  805. text:
  806. FFLocalizations.of(context).getText(
  807. '8a7ti6zc' /* Zaak toevoegen */,
  808. ),
  809. options: FFButtonOptions(
  810. height: 40.0,
  811. padding:
  812. EdgeInsetsDirectional.fromSTEB(
  813. 16.0, 0.0, 16.0, 0.0),
  814. iconPadding:
  815. EdgeInsetsDirectional.fromSTEB(
  816. 0.0, 0.0, 0.0, 0.0),
  817. color: FlutterFlowTheme.of(context)
  818. .secondary,
  819. textStyle: FlutterFlowTheme.of(
  820. context)
  821. .titleSmall
  822. .override(
  823. font: GoogleFonts.roboto(
  824. fontWeight:
  825. FlutterFlowTheme.of(
  826. context)
  827. .titleSmall
  828. .fontWeight,
  829. fontStyle:
  830. FlutterFlowTheme.of(
  831. context)
  832. .titleSmall
  833. .fontStyle,
  834. ),
  835. color: Colors.white,
  836. letterSpacing: 0.0,
  837. fontWeight:
  838. FlutterFlowTheme.of(context)
  839. .titleSmall
  840. .fontWeight,
  841. fontStyle:
  842. FlutterFlowTheme.of(context)
  843. .titleSmall
  844. .fontStyle,
  845. ),
  846. elevation: 0.0,
  847. borderRadius:
  848. BorderRadius.circular(8.0),
  849. ),
  850. ),
  851. ],
  852. ),
  853. FutureBuilder<ApiCallResponse>(
  854. future: MijnHorecagelegenhedenCall.call(
  855. sessionName: FFAppState().userSessionname,
  856. sessid: FFAppState().userSessionid,
  857. ),
  858. builder: (context, snapshot) {
  859. // Customize what your widget looks like when it's loading.
  860. if (!snapshot.hasData) {
  861. return Center(
  862. child: SizedBox(
  863. width: 80.0,
  864. height: 80.0,
  865. child: SpinKitFadingCircle(
  866. color:
  867. FlutterFlowTheme.of(context)
  868. .primary,
  869. size: 80.0,
  870. ),
  871. ),
  872. );
  873. }
  874. final listViewMijnHorecagelegenhedenResponse =
  875. snapshot.data!;
  876. _model.debugBackendQueries[
  877. 'MijnHorecagelegenhedenCall_statusCode_ListView_gxiuys53'] =
  878. debugSerializeParam(
  879. listViewMijnHorecagelegenhedenResponse
  880. .statusCode,
  881. ParamType.int,
  882. link:
  883. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  884. name: 'int',
  885. nullable: false,
  886. );
  887. _model.debugBackendQueries[
  888. 'MijnHorecagelegenhedenCall_responseBody_ListView_gxiuys53'] =
  889. debugSerializeParam(
  890. listViewMijnHorecagelegenhedenResponse
  891. .bodyText,
  892. ParamType.String,
  893. link:
  894. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  895. name: 'String',
  896. nullable: false,
  897. );
  898. debugLogWidgetClass(_model);
  899. return Builder(
  900. builder: (context) {
  901. final horecaItem =
  902. listViewMijnHorecagelegenhedenResponse
  903. .jsonBody
  904. .toList();
  905. if (horecaItem.isEmpty) {
  906. return LegeLijstComponentWidget(
  907. tekst:
  908. 'Je hebt geen horecagelegenheden. Deze kun je gratis aanmaken op de uitgaanskrant.com website.',
  909. );
  910. }
  911. _model.debugGeneratorVariables[
  912. 'horecaItem${horecaItem.length > 100 ? ' (first 100)' : ''}'] =
  913. debugSerializeParam(
  914. horecaItem.take(100),
  915. ParamType.JSON,
  916. isList: true,
  917. link:
  918. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  919. name: 'dynamic',
  920. nullable: false,
  921. );
  922. debugLogWidgetClass(_model);
  923. return ListView.builder(
  924. padding: EdgeInsets.zero,
  925. shrinkWrap: true,
  926. scrollDirection: Axis.vertical,
  927. itemCount: horecaItem.length,
  928. itemBuilder:
  929. (context, horecaItemIndex) {
  930. final horecaItemItem =
  931. horecaItem[horecaItemIndex];
  932. return Column(
  933. mainAxisSize: MainAxisSize.max,
  934. children: [
  935. Builder(builder: (_) {
  936. return DebugFlutterFlowModelContext(
  937. rootModel:
  938. _model.rootModel,
  939. parentModelCallback: (m) {
  940. _model.horecagelegenheidoverzichtKaartModels[
  941. 'Key4vp_${horecaItemIndex}_of_${horecaItem.length}'] = m;
  942. },
  943. child:
  944. HorecagelegenheidoverzichtKaartWidget(
  945. key: Key(
  946. 'Key4vp_${horecaItemIndex}_of_${horecaItem.length}'),
  947. titel: getJsonField(
  948. horecaItemItem,
  949. r'''$.titel''',
  950. ).toString(),
  951. logo: getJsonField(
  952. horecaItemItem,
  953. r'''$.logo''',
  954. ).toString(),
  955. nid: getJsonField(
  956. horecaItemItem,
  957. r'''$.nid''',
  958. ).toString(),
  959. adres: getJsonField(
  960. horecaItemItem,
  961. r'''$.adres''',
  962. ).toString(),
  963. plaats: getJsonField(
  964. horecaItemItem,
  965. r'''$.plaats''',
  966. ).toString(),
  967. categorie:
  968. (getJsonField(
  969. horecaItemItem,
  970. r'''$.categorie''',
  971. true,
  972. ) as List?)
  973. ?.map<String>(
  974. (e) => e
  975. .toString())
  976. .toList()
  977. .cast<String>(),
  978. ),
  979. );
  980. }),
  981. FFButtonWidget(
  982. onPressed: () async {
  983. FFAppState().kloonBron =
  984. null;
  985. safeSetState(() {});
  986. context.pushNamed(
  987. UitgaansevenementAanmakenWidget
  988. .routeName,
  989. queryParameters: {
  990. 'horecagelegenheidNid':
  991. serializeParam(
  992. getJsonField(
  993. horecaItemItem,
  994. r'''$.nid''',
  995. ).toString(),
  996. ParamType.String,
  997. ),
  998. }.withoutNulls,
  999. );
  1000. },
  1001. text: FFLocalizations.of(
  1002. context)
  1003. .getText(
  1004. 'y6wd6qpb' /* + Evenement aanmaken */,
  1005. ),
  1006. options: FFButtonOptions(
  1007. width: double.infinity,
  1008. height: 40.0,
  1009. padding:
  1010. EdgeInsetsDirectional
  1011. .fromSTEB(
  1012. 16.0,
  1013. 0.0,
  1014. 16.0,
  1015. 0.0),
  1016. iconPadding:
  1017. EdgeInsetsDirectional
  1018. .fromSTEB(
  1019. 0.0,
  1020. 0.0,
  1021. 0.0,
  1022. 0.0),
  1023. color:
  1024. FlutterFlowTheme.of(
  1025. context)
  1026. .secondary,
  1027. textStyle:
  1028. FlutterFlowTheme.of(
  1029. context)
  1030. .titleSmall
  1031. .override(
  1032. font:
  1033. GoogleFonts
  1034. .roboto(
  1035. fontWeight: FlutterFlowTheme.of(
  1036. context)
  1037. .titleSmall
  1038. .fontWeight,
  1039. fontStyle: FlutterFlowTheme.of(
  1040. context)
  1041. .titleSmall
  1042. .fontStyle,
  1043. ),
  1044. color: Colors
  1045. .white,
  1046. letterSpacing:
  1047. 0.0,
  1048. fontWeight: FlutterFlowTheme.of(
  1049. context)
  1050. .titleSmall
  1051. .fontWeight,
  1052. fontStyle: FlutterFlowTheme.of(
  1053. context)
  1054. .titleSmall
  1055. .fontStyle,
  1056. ),
  1057. elevation: 0.0,
  1058. borderRadius:
  1059. BorderRadius.circular(
  1060. 8.0),
  1061. ),
  1062. ),
  1063. ],
  1064. );
  1065. },
  1066. );
  1067. },
  1068. );
  1069. },
  1070. ),
  1071. Text(
  1072. FFLocalizations.of(context).getText(
  1073. 'xw2yzyh1' /* Een horecagelegenheid toevoege... */,
  1074. ),
  1075. style: FlutterFlowTheme.of(context)
  1076. .bodySmall
  1077. .override(
  1078. font: GoogleFonts.roboto(
  1079. fontWeight:
  1080. FlutterFlowTheme.of(context)
  1081. .bodySmall
  1082. .fontWeight,
  1083. fontStyle:
  1084. FlutterFlowTheme.of(context)
  1085. .bodySmall
  1086. .fontStyle,
  1087. ),
  1088. color: FlutterFlowTheme.of(context)
  1089. .secondaryText,
  1090. letterSpacing: 0.0,
  1091. fontWeight:
  1092. FlutterFlowTheme.of(context)
  1093. .bodySmall
  1094. .fontWeight,
  1095. fontStyle:
  1096. FlutterFlowTheme.of(context)
  1097. .bodySmall
  1098. .fontStyle,
  1099. ),
  1100. ),
  1101. ],
  1102. ),
  1103. ),
  1104. SingleChildScrollView(
  1105. child: Column(
  1106. mainAxisSize: MainAxisSize.max,
  1107. children: [
  1108. Row(
  1109. mainAxisSize: MainAxisSize.max,
  1110. mainAxisAlignment:
  1111. MainAxisAlignment.spaceBetween,
  1112. children: [
  1113. Text(
  1114. FFLocalizations.of(context).getText(
  1115. 'od5wmxf8' /* Eigen activiteiten */,
  1116. ),
  1117. style: FlutterFlowTheme.of(context)
  1118. .titleMedium
  1119. .override(
  1120. font: GoogleFonts.roboto(
  1121. fontWeight:
  1122. FlutterFlowTheme.of(context)
  1123. .titleMedium
  1124. .fontWeight,
  1125. fontStyle:
  1126. FlutterFlowTheme.of(context)
  1127. .titleMedium
  1128. .fontStyle,
  1129. ),
  1130. letterSpacing: 0.0,
  1131. fontWeight:
  1132. FlutterFlowTheme.of(context)
  1133. .titleMedium
  1134. .fontWeight,
  1135. fontStyle:
  1136. FlutterFlowTheme.of(context)
  1137. .titleMedium
  1138. .fontStyle,
  1139. ),
  1140. ),
  1141. FFButtonWidget(
  1142. onPressed: () async {
  1143. context.pushNamed(
  1144. MijnAanmeldingenWidget.routeName,
  1145. queryParameters: {
  1146. 'type': serializeParam(
  1147. 'activity',
  1148. ParamType.String,
  1149. ),
  1150. }.withoutNulls,
  1151. );
  1152. },
  1153. text:
  1154. FFLocalizations.of(context).getText(
  1155. 'lkv2denp' /* Bekijk alles */,
  1156. ),
  1157. options: FFButtonOptions(
  1158. height: 40.0,
  1159. padding:
  1160. EdgeInsetsDirectional.fromSTEB(
  1161. 16.0, 0.0, 16.0, 0.0),
  1162. iconPadding:
  1163. EdgeInsetsDirectional.fromSTEB(
  1164. 0.0, 0.0, 0.0, 0.0),
  1165. color: FlutterFlowTheme.of(context)
  1166. .secondary,
  1167. textStyle: FlutterFlowTheme.of(
  1168. context)
  1169. .titleSmall
  1170. .override(
  1171. font: GoogleFonts.roboto(
  1172. fontWeight:
  1173. FlutterFlowTheme.of(
  1174. context)
  1175. .titleSmall
  1176. .fontWeight,
  1177. fontStyle:
  1178. FlutterFlowTheme.of(
  1179. context)
  1180. .titleSmall
  1181. .fontStyle,
  1182. ),
  1183. color: Colors.white,
  1184. letterSpacing: 0.0,
  1185. fontWeight:
  1186. FlutterFlowTheme.of(context)
  1187. .titleSmall
  1188. .fontWeight,
  1189. fontStyle:
  1190. FlutterFlowTheme.of(context)
  1191. .titleSmall
  1192. .fontStyle,
  1193. ),
  1194. elevation: 0.0,
  1195. borderRadius:
  1196. BorderRadius.circular(8.0),
  1197. ),
  1198. ),
  1199. ],
  1200. ),
  1201. FutureBuilder<ApiCallResponse>(
  1202. future: MijnAanmeldingenCall.call(
  1203. sessionName: FFAppState().userSessionname,
  1204. sessid: FFAppState().userSessionid,
  1205. limit: 5,
  1206. type: 'activity',
  1207. komend: '1',
  1208. ),
  1209. builder: (context, snapshot) {
  1210. // Customize what your widget looks like when it's loading.
  1211. if (!snapshot.hasData) {
  1212. return Center(
  1213. child: SizedBox(
  1214. width: 80.0,
  1215. height: 80.0,
  1216. child: SpinKitFadingCircle(
  1217. color:
  1218. FlutterFlowTheme.of(context)
  1219. .primary,
  1220. size: 80.0,
  1221. ),
  1222. ),
  1223. );
  1224. }
  1225. final listViewMijnAanmeldingenResponse =
  1226. snapshot.data!;
  1227. _model.debugBackendQueries[
  1228. 'MijnAanmeldingenCall_statusCode_ListView_zmsqmody'] =
  1229. debugSerializeParam(
  1230. listViewMijnAanmeldingenResponse
  1231. .statusCode,
  1232. ParamType.int,
  1233. link:
  1234. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1235. name: 'int',
  1236. nullable: false,
  1237. );
  1238. _model.debugBackendQueries[
  1239. 'MijnAanmeldingenCall_responseBody_ListView_zmsqmody'] =
  1240. debugSerializeParam(
  1241. listViewMijnAanmeldingenResponse
  1242. .bodyText,
  1243. ParamType.String,
  1244. link:
  1245. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1246. name: 'String',
  1247. nullable: false,
  1248. );
  1249. debugLogWidgetClass(_model);
  1250. return Builder(
  1251. builder: (context) {
  1252. final aanmeldingItem =
  1253. MijnAanmeldingenCall.items(
  1254. listViewMijnAanmeldingenResponse
  1255. .jsonBody,
  1256. )?.toList() ??
  1257. [];
  1258. if (aanmeldingItem.isEmpty) {
  1259. return LegeLijstComponentWidget(
  1260. tekst:
  1261. 'Je hebt nog geen komende stadsactiviteiten aangemaakt.',
  1262. );
  1263. }
  1264. _model.debugGeneratorVariables[
  1265. 'aanmeldingItem${aanmeldingItem.length > 100 ? ' (first 100)' : ''}'] =
  1266. debugSerializeParam(
  1267. aanmeldingItem.take(100),
  1268. ParamType.JSON,
  1269. isList: true,
  1270. link:
  1271. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1272. name: 'dynamic',
  1273. nullable: false,
  1274. );
  1275. debugLogWidgetClass(_model);
  1276. return ListView.builder(
  1277. padding: EdgeInsets.zero,
  1278. shrinkWrap: true,
  1279. scrollDirection: Axis.vertical,
  1280. itemCount: aanmeldingItem.length,
  1281. itemBuilder:
  1282. (context, aanmeldingItemIndex) {
  1283. final aanmeldingItemItem =
  1284. aanmeldingItem[
  1285. aanmeldingItemIndex];
  1286. return Padding(
  1287. padding: EdgeInsetsDirectional
  1288. .fromSTEB(
  1289. 0.0, 0.0, 0.0, 12.0),
  1290. child: Column(
  1291. mainAxisSize:
  1292. MainAxisSize.max,
  1293. children: [
  1294. Stack(
  1295. children: [
  1296. Container(
  1297. width:
  1298. double.infinity,
  1299. decoration:
  1300. BoxDecoration(),
  1301. child: InkWell(
  1302. splashColor: Colors
  1303. .transparent,
  1304. focusColor: Colors
  1305. .transparent,
  1306. hoverColor: Colors
  1307. .transparent,
  1308. highlightColor:
  1309. Colors
  1310. .transparent,
  1311. onTap: () async {
  1312. if (functions
  1313. .isOngepubliceerd(
  1314. aanmeldingItemItem)) {
  1315. ScaffoldMessenger.of(
  1316. context)
  1317. .showSnackBar(
  1318. SnackBar(
  1319. content:
  1320. Text(
  1321. 'Dit item staat nog in beoordeling en is nog niet online.',
  1322. style:
  1323. TextStyle(
  1324. color: FlutterFlowTheme.of(context)
  1325. .primaryText,
  1326. ),
  1327. ),
  1328. duration: Duration(
  1329. milliseconds:
  1330. 4000),
  1331. backgroundColor:
  1332. FlutterFlowTheme.of(context)
  1333. .secondary,
  1334. ),
  1335. );
  1336. } else {
  1337. context
  1338. .pushNamed(
  1339. EventCurrentWidget
  1340. .routeName,
  1341. queryParameters:
  1342. {
  1343. 'nid':
  1344. serializeParam(
  1345. getJsonField(
  1346. aanmeldingItemItem,
  1347. r'''$.nid''',
  1348. ).toString(),
  1349. ParamType
  1350. .String,
  1351. ),
  1352. 'horecaid':
  1353. serializeParam(
  1354. getJsonField(
  1355. aanmeldingItemItem,
  1356. r'''$.horecagelegenheidnid''',
  1357. ).toString(),
  1358. ParamType
  1359. .String,
  1360. ),
  1361. }.withoutNulls,
  1362. );
  1363. }
  1364. },
  1365. child: Material(
  1366. color: Colors
  1367. .transparent,
  1368. child: ListTile(
  1369. title: Text(
  1370. getJsonField(
  1371. aanmeldingItemItem,
  1372. r'''$.title''',
  1373. ).toString(),
  1374. style: FlutterFlowTheme.of(
  1375. context)
  1376. .titleLarge
  1377. .override(
  1378. font: GoogleFonts
  1379. .roboto(
  1380. fontWeight: FlutterFlowTheme.of(context)
  1381. .titleLarge
  1382. .fontWeight,
  1383. fontStyle: FlutterFlowTheme.of(context)
  1384. .titleLarge
  1385. .fontStyle,
  1386. ),
  1387. letterSpacing:
  1388. 0.0,
  1389. fontWeight: FlutterFlowTheme.of(context)
  1390. .titleLarge
  1391. .fontWeight,
  1392. fontStyle: FlutterFlowTheme.of(context)
  1393. .titleLarge
  1394. .fontStyle,
  1395. ),
  1396. ),
  1397. subtitle: Text(
  1398. getJsonField(
  1399. aanmeldingItemItem,
  1400. r'''$.datum_start''',
  1401. ).toString(),
  1402. style: FlutterFlowTheme.of(
  1403. context)
  1404. .labelMedium
  1405. .override(
  1406. font: GoogleFonts
  1407. .roboto(
  1408. fontWeight: FlutterFlowTheme.of(context)
  1409. .labelMedium
  1410. .fontWeight,
  1411. fontStyle: FlutterFlowTheme.of(context)
  1412. .labelMedium
  1413. .fontStyle,
  1414. ),
  1415. letterSpacing:
  1416. 0.0,
  1417. fontWeight: FlutterFlowTheme.of(context)
  1418. .labelMedium
  1419. .fontWeight,
  1420. fontStyle: FlutterFlowTheme.of(context)
  1421. .labelMedium
  1422. .fontStyle,
  1423. ),
  1424. ),
  1425. tileColor: FlutterFlowTheme.of(
  1426. context)
  1427. .secondaryBackground,
  1428. dense: false,
  1429. contentPadding:
  1430. EdgeInsetsDirectional
  1431. .fromSTEB(
  1432. 12.0,
  1433. 0.0,
  1434. 52.0,
  1435. 0.0),
  1436. shape:
  1437. RoundedRectangleBorder(
  1438. borderRadius:
  1439. BorderRadius
  1440. .circular(
  1441. 8.0),
  1442. ),
  1443. ),
  1444. ),
  1445. ),
  1446. ),
  1447. Align(
  1448. alignment:
  1449. AlignmentDirectional(
  1450. 1.0, 0.0),
  1451. child: Padding(
  1452. padding:
  1453. EdgeInsetsDirectional
  1454. .fromSTEB(
  1455. 0.0,
  1456. 0.0,
  1457. 4.0,
  1458. 0.0),
  1459. child:
  1460. AlignedTooltip(
  1461. content: Padding(
  1462. padding:
  1463. EdgeInsets
  1464. .all(
  1465. 4.0),
  1466. child: Text(
  1467. FFLocalizations.of(
  1468. context)
  1469. .getText(
  1470. 'adjt2leo' /* Kopieer naar een nieuwe activi... */,
  1471. ),
  1472. style: FlutterFlowTheme.of(
  1473. context)
  1474. .bodyLarge
  1475. .override(
  1476. font: GoogleFonts
  1477. .roboto(
  1478. fontWeight: FlutterFlowTheme.of(context)
  1479. .bodyLarge
  1480. .fontWeight,
  1481. fontStyle: FlutterFlowTheme.of(context)
  1482. .bodyLarge
  1483. .fontStyle,
  1484. ),
  1485. letterSpacing:
  1486. 0.0,
  1487. fontWeight: FlutterFlowTheme.of(context)
  1488. .bodyLarge
  1489. .fontWeight,
  1490. fontStyle: FlutterFlowTheme.of(context)
  1491. .bodyLarge
  1492. .fontStyle,
  1493. ),
  1494. ),
  1495. ),
  1496. offset: 4.0,
  1497. preferredDirection:
  1498. AxisDirection
  1499. .down,
  1500. borderRadius:
  1501. BorderRadius
  1502. .circular(
  1503. 8.0),
  1504. backgroundColor:
  1505. FlutterFlowTheme.of(
  1506. context)
  1507. .secondaryBackground,
  1508. elevation: 4.0,
  1509. tailBaseWidth:
  1510. 24.0,
  1511. tailLength: 12.0,
  1512. waitDuration:
  1513. Duration(
  1514. milliseconds:
  1515. 100),
  1516. showDuration:
  1517. Duration(
  1518. milliseconds:
  1519. 1500),
  1520. triggerMode:
  1521. TooltipTriggerMode
  1522. .longPress,
  1523. child:
  1524. FlutterFlowIconButton(
  1525. borderRadius:
  1526. 8.0,
  1527. buttonSize:
  1528. 34.0,
  1529. fillColor: FlutterFlowTheme.of(
  1530. context)
  1531. .primaryBackground,
  1532. icon: Icon(
  1533. Icons
  1534. .content_copy,
  1535. color: FlutterFlowTheme.of(
  1536. context)
  1537. .secondary,
  1538. size: 20.0,
  1539. ),
  1540. onPressed:
  1541. () async {
  1542. _model.apiResultAct =
  1543. await AanmeldingKloonbronCall
  1544. .call(
  1545. sessionName:
  1546. FFAppState()
  1547. .userSessionname,
  1548. sessid: FFAppState()
  1549. .userSessionid,
  1550. nid:
  1551. getJsonField(
  1552. aanmeldingItemItem,
  1553. r'''$.nid''',
  1554. ).toString(),
  1555. );
  1556. if ((_model
  1557. .apiResultAct
  1558. ?.succeeded ??
  1559. true)) {
  1560. FFAppState()
  1561. .kloonBron = (_model
  1562. .apiResultAct
  1563. ?.jsonBody ??
  1564. '');
  1565. safeSetState(
  1566. () {});
  1567. context
  1568. .pushNamed(
  1569. StadsactiviteitAanmakenWidget
  1570. .routeName,
  1571. queryParameters:
  1572. {
  1573. 'gemeenteTid':
  1574. serializeParam(
  1575. getJsonField(
  1576. (_model.apiResultAct?.jsonBody ??
  1577. ''),
  1578. r'''$.gemeente_tid''',
  1579. ).toString(),
  1580. ParamType
  1581. .String,
  1582. ),
  1583. }.withoutNulls,
  1584. );
  1585. }
  1586. safeSetState(
  1587. () {});
  1588. },
  1589. ),
  1590. ),
  1591. ),
  1592. ),
  1593. ],
  1594. ),
  1595. ],
  1596. ),
  1597. );
  1598. },
  1599. );
  1600. },
  1601. );
  1602. },
  1603. ),
  1604. Row(
  1605. mainAxisSize: MainAxisSize.max,
  1606. mainAxisAlignment:
  1607. MainAxisAlignment.spaceBetween,
  1608. children: [
  1609. Text(
  1610. FFLocalizations.of(context).getText(
  1611. '5iw84w8w' /* Mijn gemeenten (stadsrechten) */,
  1612. ),
  1613. style: FlutterFlowTheme.of(context)
  1614. .titleMedium
  1615. .override(
  1616. font: GoogleFonts.roboto(
  1617. fontWeight:
  1618. FlutterFlowTheme.of(context)
  1619. .titleMedium
  1620. .fontWeight,
  1621. fontStyle:
  1622. FlutterFlowTheme.of(context)
  1623. .titleMedium
  1624. .fontStyle,
  1625. ),
  1626. letterSpacing: 0.0,
  1627. fontWeight:
  1628. FlutterFlowTheme.of(context)
  1629. .titleMedium
  1630. .fontWeight,
  1631. fontStyle:
  1632. FlutterFlowTheme.of(context)
  1633. .titleMedium
  1634. .fontStyle,
  1635. ),
  1636. ),
  1637. FFButtonWidget(
  1638. onPressed: () async {
  1639. FFAppState().kloonBron = null;
  1640. safeSetState(() {});
  1641. context.pushNamed(
  1642. StadsactiviteitAanmakenWidget
  1643. .routeName);
  1644. },
  1645. text:
  1646. FFLocalizations.of(context).getText(
  1647. 'h3caw9re' /* + Activiteit */,
  1648. ),
  1649. options: FFButtonOptions(
  1650. height: 40.0,
  1651. padding:
  1652. EdgeInsetsDirectional.fromSTEB(
  1653. 16.0, 0.0, 16.0, 0.0),
  1654. iconPadding:
  1655. EdgeInsetsDirectional.fromSTEB(
  1656. 0.0, 0.0, 0.0, 0.0),
  1657. color: FlutterFlowTheme.of(context)
  1658. .secondary,
  1659. textStyle: FlutterFlowTheme.of(
  1660. context)
  1661. .titleSmall
  1662. .override(
  1663. font: GoogleFonts.roboto(
  1664. fontWeight:
  1665. FlutterFlowTheme.of(
  1666. context)
  1667. .titleSmall
  1668. .fontWeight,
  1669. fontStyle:
  1670. FlutterFlowTheme.of(
  1671. context)
  1672. .titleSmall
  1673. .fontStyle,
  1674. ),
  1675. color: Colors.white,
  1676. letterSpacing: 0.0,
  1677. fontWeight:
  1678. FlutterFlowTheme.of(context)
  1679. .titleSmall
  1680. .fontWeight,
  1681. fontStyle:
  1682. FlutterFlowTheme.of(context)
  1683. .titleSmall
  1684. .fontStyle,
  1685. ),
  1686. elevation: 0.0,
  1687. borderRadius:
  1688. BorderRadius.circular(8.0),
  1689. ),
  1690. ),
  1691. ],
  1692. ),
  1693. FutureBuilder<ApiCallResponse>(
  1694. future: MijnStadsrechtenCall.call(
  1695. sessionName: FFAppState().userSessionname,
  1696. sessid: FFAppState().userSessionid,
  1697. ),
  1698. builder: (context, snapshot) {
  1699. // Customize what your widget looks like when it's loading.
  1700. if (!snapshot.hasData) {
  1701. return Center(
  1702. child: SizedBox(
  1703. width: 80.0,
  1704. height: 80.0,
  1705. child: SpinKitFadingCircle(
  1706. color:
  1707. FlutterFlowTheme.of(context)
  1708. .primary,
  1709. size: 80.0,
  1710. ),
  1711. ),
  1712. );
  1713. }
  1714. final listViewMijnStadsrechtenResponse =
  1715. snapshot.data!;
  1716. _model.debugBackendQueries[
  1717. 'MijnStadsrechtenCall_statusCode_ListView_m1osuvrr'] =
  1718. debugSerializeParam(
  1719. listViewMijnStadsrechtenResponse
  1720. .statusCode,
  1721. ParamType.int,
  1722. link:
  1723. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1724. name: 'int',
  1725. nullable: false,
  1726. );
  1727. _model.debugBackendQueries[
  1728. 'MijnStadsrechtenCall_responseBody_ListView_m1osuvrr'] =
  1729. debugSerializeParam(
  1730. listViewMijnStadsrechtenResponse
  1731. .bodyText,
  1732. ParamType.String,
  1733. link:
  1734. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1735. name: 'String',
  1736. nullable: false,
  1737. );
  1738. debugLogWidgetClass(_model);
  1739. return Builder(
  1740. builder: (context) {
  1741. final rechtItem =
  1742. listViewMijnStadsrechtenResponse
  1743. .jsonBody
  1744. .toList();
  1745. if (rechtItem.isEmpty) {
  1746. return LegeLijstComponentWidget(
  1747. tekst:
  1748. 'Je hebt geen rechten als stadseditor. Je kunt wel activiteiten toevoegen, maar ze moeten eerst worden goedgekeurd door Uitgaanskrant.com.',
  1749. );
  1750. }
  1751. _model.debugGeneratorVariables[
  1752. 'rechtItem${rechtItem.length > 100 ? ' (first 100)' : ''}'] =
  1753. debugSerializeParam(
  1754. rechtItem.take(100),
  1755. ParamType.JSON,
  1756. isList: true,
  1757. link:
  1758. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  1759. name: 'dynamic',
  1760. nullable: false,
  1761. );
  1762. debugLogWidgetClass(_model);
  1763. return ListView.builder(
  1764. padding: EdgeInsets.zero,
  1765. shrinkWrap: true,
  1766. scrollDirection: Axis.vertical,
  1767. itemCount: rechtItem.length,
  1768. itemBuilder:
  1769. (context, rechtItemIndex) {
  1770. final rechtItemItem =
  1771. rechtItem[rechtItemIndex];
  1772. return Padding(
  1773. padding: EdgeInsets.all(12.0),
  1774. child: Container(
  1775. decoration: BoxDecoration(
  1776. color: FlutterFlowTheme.of(
  1777. context)
  1778. .secondaryBackground,
  1779. borderRadius:
  1780. BorderRadius.circular(
  1781. 8.0),
  1782. ),
  1783. child: Column(
  1784. mainAxisSize:
  1785. MainAxisSize.max,
  1786. crossAxisAlignment:
  1787. CrossAxisAlignment
  1788. .start,
  1789. children: [
  1790. Text(
  1791. '${getJsonField(
  1792. rechtItemItem,
  1793. r'''$.titel''',
  1794. ).toString()} — ${getJsonField(
  1795. rechtItemItem,
  1796. r'''$.parent_titel''',
  1797. ).toString()}',
  1798. style:
  1799. FlutterFlowTheme.of(
  1800. context)
  1801. .bodyMedium
  1802. .override(
  1803. font: GoogleFonts
  1804. .roboto(
  1805. fontWeight: FlutterFlowTheme.of(
  1806. context)
  1807. .bodyMedium
  1808. .fontWeight,
  1809. fontStyle: FlutterFlowTheme.of(
  1810. context)
  1811. .bodyMedium
  1812. .fontStyle,
  1813. ),
  1814. letterSpacing:
  1815. 0.0,
  1816. fontWeight: FlutterFlowTheme.of(
  1817. context)
  1818. .bodyMedium
  1819. .fontWeight,
  1820. fontStyle: FlutterFlowTheme.of(
  1821. context)
  1822. .bodyMedium
  1823. .fontStyle,
  1824. ),
  1825. ),
  1826. FFButtonWidget(
  1827. onPressed: () async {
  1828. FFAppState()
  1829. .kloonBron = null;
  1830. safeSetState(() {});
  1831. context.pushNamed(
  1832. StadsactiviteitAanmakenWidget
  1833. .routeName,
  1834. queryParameters: {
  1835. 'gemeenteTid':
  1836. serializeParam(
  1837. getJsonField(
  1838. rechtItemItem,
  1839. r'''$.tid''',
  1840. ).toString(),
  1841. ParamType
  1842. .String,
  1843. ),
  1844. }.withoutNulls,
  1845. );
  1846. },
  1847. text:
  1848. FFLocalizations.of(
  1849. context)
  1850. .getText(
  1851. 'hfqho9ti' /* + Activiteit aanmaken */,
  1852. ),
  1853. options:
  1854. FFButtonOptions(
  1855. width:
  1856. double.infinity,
  1857. height: 40.0,
  1858. padding:
  1859. EdgeInsetsDirectional
  1860. .fromSTEB(
  1861. 16.0,
  1862. 0.0,
  1863. 16.0,
  1864. 0.0),
  1865. iconPadding:
  1866. EdgeInsetsDirectional
  1867. .fromSTEB(
  1868. 0.0,
  1869. 0.0,
  1870. 0.0,
  1871. 0.0),
  1872. color: FlutterFlowTheme
  1873. .of(context)
  1874. .secondary,
  1875. textStyle:
  1876. FlutterFlowTheme.of(
  1877. context)
  1878. .titleSmall
  1879. .override(
  1880. font: GoogleFonts
  1881. .roboto(
  1882. fontWeight: FlutterFlowTheme.of(
  1883. context)
  1884. .titleSmall
  1885. .fontWeight,
  1886. fontStyle: FlutterFlowTheme.of(
  1887. context)
  1888. .titleSmall
  1889. .fontStyle,
  1890. ),
  1891. color: Colors
  1892. .white,
  1893. letterSpacing:
  1894. 0.0,
  1895. fontWeight: FlutterFlowTheme.of(
  1896. context)
  1897. .titleSmall
  1898. .fontWeight,
  1899. fontStyle: FlutterFlowTheme.of(
  1900. context)
  1901. .titleSmall
  1902. .fontStyle,
  1903. ),
  1904. elevation: 0.0,
  1905. borderRadius:
  1906. BorderRadius
  1907. .circular(
  1908. 8.0),
  1909. ),
  1910. ),
  1911. ],
  1912. ),
  1913. ),
  1914. );
  1915. },
  1916. );
  1917. },
  1918. );
  1919. },
  1920. ),
  1921. ],
  1922. ),
  1923. ),
  1924. SingleChildScrollView(
  1925. child: Column(
  1926. mainAxisSize: MainAxisSize.max,
  1927. children: [
  1928. Padding(
  1929. padding: EdgeInsets.all(16.0),
  1930. child: Text(
  1931. FFAppState().userName,
  1932. style: FlutterFlowTheme.of(context)
  1933. .bodyMedium
  1934. .override(
  1935. font: GoogleFonts.roboto(
  1936. fontWeight:
  1937. FlutterFlowTheme.of(context)
  1938. .bodyMedium
  1939. .fontWeight,
  1940. fontStyle:
  1941. FlutterFlowTheme.of(context)
  1942. .bodyMedium
  1943. .fontStyle,
  1944. ),
  1945. letterSpacing: 0.0,
  1946. fontWeight:
  1947. FlutterFlowTheme.of(context)
  1948. .bodyMedium
  1949. .fontWeight,
  1950. fontStyle:
  1951. FlutterFlowTheme.of(context)
  1952. .bodyMedium
  1953. .fontStyle,
  1954. ),
  1955. ),
  1956. ),
  1957. Text(
  1958. FFLocalizations.of(context).getText(
  1959. 'zlpb2nvy' /* Taal / Language */,
  1960. ),
  1961. style: FlutterFlowTheme.of(context)
  1962. .bodySmall
  1963. .override(
  1964. font: GoogleFonts.roboto(
  1965. fontWeight:
  1966. FlutterFlowTheme.of(context)
  1967. .bodySmall
  1968. .fontWeight,
  1969. fontStyle:
  1970. FlutterFlowTheme.of(context)
  1971. .bodySmall
  1972. .fontStyle,
  1973. ),
  1974. color: FlutterFlowTheme.of(context)
  1975. .secondaryText,
  1976. letterSpacing: 0.0,
  1977. fontWeight:
  1978. FlutterFlowTheme.of(context)
  1979. .bodySmall
  1980. .fontWeight,
  1981. fontStyle:
  1982. FlutterFlowTheme.of(context)
  1983. .bodySmall
  1984. .fontStyle,
  1985. ),
  1986. ),
  1987. FlutterFlowLanguageSelector(
  1988. width: 200.0,
  1989. height: 40.0,
  1990. backgroundColor:
  1991. FlutterFlowTheme.of(context)
  1992. .secondaryBackground,
  1993. borderColor: Colors.transparent,
  1994. dropdownIconColor:
  1995. FlutterFlowTheme.of(context)
  1996. .secondaryText,
  1997. borderRadius: 8.0,
  1998. textStyle: FlutterFlowTheme.of(context)
  1999. .bodyMedium
  2000. .override(
  2001. font: GoogleFonts.roboto(
  2002. fontWeight:
  2003. FlutterFlowTheme.of(context)
  2004. .bodyMedium
  2005. .fontWeight,
  2006. fontStyle:
  2007. FlutterFlowTheme.of(context)
  2008. .bodyMedium
  2009. .fontStyle,
  2010. ),
  2011. letterSpacing: 0.0,
  2012. fontWeight:
  2013. FlutterFlowTheme.of(context)
  2014. .bodyMedium
  2015. .fontWeight,
  2016. fontStyle:
  2017. FlutterFlowTheme.of(context)
  2018. .bodyMedium
  2019. .fontStyle,
  2020. ),
  2021. hideFlags: false,
  2022. flagSize: 24.0,
  2023. flagTextGap: 8.0,
  2024. currentLanguage: FFLocalizations.of(context)
  2025. .languageCode,
  2026. languages: FFLocalizations.languages(),
  2027. onChanged: (lang) =>
  2028. setAppLanguage(context, lang),
  2029. ),
  2030. InkWell(
  2031. splashColor: Colors.transparent,
  2032. focusColor: Colors.transparent,
  2033. hoverColor: Colors.transparent,
  2034. highlightColor: Colors.transparent,
  2035. onTap: () async {
  2036. context.pushNamed(
  2037. WachtwoordVergetenWidget.routeName);
  2038. },
  2039. child: Material(
  2040. color: Colors.transparent,
  2041. child: ListTile(
  2042. title: Text(
  2043. FFLocalizations.of(context).getText(
  2044. '0sxtqp61' /* Wachtwoord wijzigen */,
  2045. ),
  2046. style: FlutterFlowTheme.of(context)
  2047. .titleLarge
  2048. .override(
  2049. font: GoogleFonts.roboto(
  2050. fontWeight:
  2051. FlutterFlowTheme.of(
  2052. context)
  2053. .titleLarge
  2054. .fontWeight,
  2055. fontStyle:
  2056. FlutterFlowTheme.of(
  2057. context)
  2058. .titleLarge
  2059. .fontStyle,
  2060. ),
  2061. letterSpacing: 0.0,
  2062. fontWeight:
  2063. FlutterFlowTheme.of(context)
  2064. .titleLarge
  2065. .fontWeight,
  2066. fontStyle:
  2067. FlutterFlowTheme.of(context)
  2068. .titleLarge
  2069. .fontStyle,
  2070. ),
  2071. ),
  2072. trailing: Icon(
  2073. Icons.arrow_forward_ios_rounded,
  2074. color: FlutterFlowTheme.of(context)
  2075. .secondaryText,
  2076. size: 24.0,
  2077. ),
  2078. tileColor: FlutterFlowTheme.of(context)
  2079. .secondaryBackground,
  2080. dense: false,
  2081. contentPadding:
  2082. EdgeInsetsDirectional.fromSTEB(
  2083. 12.0, 0.0, 12.0, 0.0),
  2084. shape: RoundedRectangleBorder(
  2085. borderRadius:
  2086. BorderRadius.circular(8.0),
  2087. ),
  2088. ),
  2089. ),
  2090. ),
  2091. InkWell(
  2092. splashColor: Colors.transparent,
  2093. focusColor: Colors.transparent,
  2094. hoverColor: Colors.transparent,
  2095. highlightColor: Colors.transparent,
  2096. onTap: () async {
  2097. await launchURL(
  2098. 'https://uitgaanskrant.com/nl/support/mobieleapp');
  2099. },
  2100. child: Material(
  2101. color: Colors.transparent,
  2102. child: ListTile(
  2103. title: Text(
  2104. FFLocalizations.of(context).getText(
  2105. '4sjzjw0j' /* Account verwijderen */,
  2106. ),
  2107. style: FlutterFlowTheme.of(context)
  2108. .titleLarge
  2109. .override(
  2110. font: GoogleFonts.roboto(
  2111. fontWeight:
  2112. FlutterFlowTheme.of(
  2113. context)
  2114. .titleLarge
  2115. .fontWeight,
  2116. fontStyle:
  2117. FlutterFlowTheme.of(
  2118. context)
  2119. .titleLarge
  2120. .fontStyle,
  2121. ),
  2122. letterSpacing: 0.0,
  2123. fontWeight:
  2124. FlutterFlowTheme.of(context)
  2125. .titleLarge
  2126. .fontWeight,
  2127. fontStyle:
  2128. FlutterFlowTheme.of(context)
  2129. .titleLarge
  2130. .fontStyle,
  2131. ),
  2132. ),
  2133. trailing: Icon(
  2134. Icons.arrow_forward_ios_rounded,
  2135. color: FlutterFlowTheme.of(context)
  2136. .secondaryText,
  2137. size: 24.0,
  2138. ),
  2139. tileColor: FlutterFlowTheme.of(context)
  2140. .secondaryBackground,
  2141. dense: false,
  2142. contentPadding:
  2143. EdgeInsetsDirectional.fromSTEB(
  2144. 12.0, 0.0, 12.0, 0.0),
  2145. shape: RoundedRectangleBorder(
  2146. borderRadius:
  2147. BorderRadius.circular(8.0),
  2148. ),
  2149. ),
  2150. ),
  2151. ),
  2152. InkWell(
  2153. splashColor: Colors.transparent,
  2154. focusColor: Colors.transparent,
  2155. hoverColor: Colors.transparent,
  2156. highlightColor: Colors.transparent,
  2157. onTap: () async {
  2158. FFAppState().deleteUserToken();
  2159. FFAppState().userToken = '';
  2160. FFAppState().deleteUserSessionid();
  2161. FFAppState().userSessionid = '';
  2162. FFAppState().deleteUserSessionname();
  2163. FFAppState().userSessionname = '';
  2164. FFAppState().deleteUserName();
  2165. FFAppState().userName = '';
  2166. FFAppState().deleteUserUid();
  2167. FFAppState().userUid = 0;
  2168. FFAppState().deleteUserMail();
  2169. FFAppState().userMail = '';
  2170. safeSetState(() {});
  2171. context.goNamed(LoginWidget.routeName);
  2172. },
  2173. child: Material(
  2174. color: Colors.transparent,
  2175. child: ListTile(
  2176. title: Text(
  2177. FFLocalizations.of(context).getText(
  2178. 'owegb3ht' /* Uitloggen */,
  2179. ),
  2180. style: FlutterFlowTheme.of(context)
  2181. .titleLarge
  2182. .override(
  2183. font: GoogleFonts.roboto(
  2184. fontWeight:
  2185. FlutterFlowTheme.of(
  2186. context)
  2187. .titleLarge
  2188. .fontWeight,
  2189. fontStyle:
  2190. FlutterFlowTheme.of(
  2191. context)
  2192. .titleLarge
  2193. .fontStyle,
  2194. ),
  2195. letterSpacing: 0.0,
  2196. fontWeight:
  2197. FlutterFlowTheme.of(context)
  2198. .titleLarge
  2199. .fontWeight,
  2200. fontStyle:
  2201. FlutterFlowTheme.of(context)
  2202. .titleLarge
  2203. .fontStyle,
  2204. ),
  2205. ),
  2206. trailing: Icon(
  2207. Icons.arrow_forward_ios_rounded,
  2208. color: FlutterFlowTheme.of(context)
  2209. .secondaryText,
  2210. size: 24.0,
  2211. ),
  2212. tileColor: FlutterFlowTheme.of(context)
  2213. .secondaryBackground,
  2214. dense: false,
  2215. contentPadding:
  2216. EdgeInsetsDirectional.fromSTEB(
  2217. 12.0, 0.0, 12.0, 0.0),
  2218. shape: RoundedRectangleBorder(
  2219. borderRadius:
  2220. BorderRadius.circular(8.0),
  2221. ),
  2222. ),
  2223. ),
  2224. ),
  2225. ],
  2226. ),
  2227. ),
  2228. Column(
  2229. mainAxisSize: MainAxisSize.max,
  2230. children: [
  2231. FutureBuilder<ApiCallResponse>(
  2232. future: NieuwsbrievenCall.call(
  2233. sessionName: FFAppState().userSessionname,
  2234. sessid: FFAppState().userSessionid,
  2235. ),
  2236. builder: (context, snapshot) {
  2237. // Customize what your widget looks like when it's loading.
  2238. if (!snapshot.hasData) {
  2239. return Center(
  2240. child: SizedBox(
  2241. width: 80.0,
  2242. height: 80.0,
  2243. child: SpinKitFadingCircle(
  2244. color: FlutterFlowTheme.of(context)
  2245. .primary,
  2246. size: 80.0,
  2247. ),
  2248. ),
  2249. );
  2250. }
  2251. final listViewNieuwsbrievenResponse =
  2252. snapshot.data!;
  2253. _model.debugBackendQueries[
  2254. 'NieuwsbrievenCall_statusCode_ListView_35upog4p'] =
  2255. debugSerializeParam(
  2256. listViewNieuwsbrievenResponse.statusCode,
  2257. ParamType.int,
  2258. link:
  2259. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  2260. name: 'int',
  2261. nullable: false,
  2262. );
  2263. _model.debugBackendQueries[
  2264. 'NieuwsbrievenCall_responseBody_ListView_35upog4p'] =
  2265. debugSerializeParam(
  2266. listViewNieuwsbrievenResponse.bodyText,
  2267. ParamType.String,
  2268. link:
  2269. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  2270. name: 'String',
  2271. nullable: false,
  2272. );
  2273. debugLogWidgetClass(_model);
  2274. return Builder(
  2275. builder: (context) {
  2276. final nieuwsbriefItem =
  2277. NieuwsbrievenCall.items(
  2278. listViewNieuwsbrievenResponse
  2279. .jsonBody,
  2280. )?.toList() ??
  2281. [];
  2282. _model.debugGeneratorVariables[
  2283. 'nieuwsbriefItem${nieuwsbriefItem.length > 100 ? ' (first 100)' : ''}'] =
  2284. debugSerializeParam(
  2285. nieuwsbriefItem.take(100),
  2286. ParamType.JSON,
  2287. isList: true,
  2288. link:
  2289. 'https://app.flutterflow.io/project/uitgaanskrant-1qhvtd?tab=uiBuilder&page=mijnProfiel',
  2290. name: 'dynamic',
  2291. nullable: false,
  2292. );
  2293. debugLogWidgetClass(_model);
  2294. return ListView.builder(
  2295. padding: EdgeInsets.zero,
  2296. shrinkWrap: true,
  2297. scrollDirection: Axis.vertical,
  2298. itemCount: nieuwsbriefItem.length,
  2299. itemBuilder:
  2300. (context, nieuwsbriefItemIndex) {
  2301. final nieuwsbriefItemItem =
  2302. nieuwsbriefItem[
  2303. nieuwsbriefItemIndex];
  2304. return Padding(
  2305. padding: EdgeInsetsDirectional
  2306. .fromSTEB(
  2307. 16.0, 10.0, 16.0, 10.0),
  2308. child: Row(
  2309. mainAxisSize: MainAxisSize.max,
  2310. children: [
  2311. Expanded(
  2312. child: Column(
  2313. mainAxisSize:
  2314. MainAxisSize.max,
  2315. crossAxisAlignment:
  2316. CrossAxisAlignment
  2317. .start,
  2318. children: [
  2319. Text(
  2320. getJsonField(
  2321. nieuwsbriefItemItem,
  2322. r'''$.naam''',
  2323. ).toString(),
  2324. style: FlutterFlowTheme
  2325. .of(context)
  2326. .titleSmall
  2327. .override(
  2328. font:
  2329. GoogleFonts
  2330. .roboto(
  2331. fontWeight: FlutterFlowTheme.of(
  2332. context)
  2333. .titleSmall
  2334. .fontWeight,
  2335. fontStyle: FlutterFlowTheme.of(
  2336. context)
  2337. .titleSmall
  2338. .fontStyle,
  2339. ),
  2340. letterSpacing:
  2341. 0.0,
  2342. fontWeight: FlutterFlowTheme.of(
  2343. context)
  2344. .titleSmall
  2345. .fontWeight,
  2346. fontStyle: FlutterFlowTheme.of(
  2347. context)
  2348. .titleSmall
  2349. .fontStyle,
  2350. ),
  2351. ),
  2352. Text(
  2353. getJsonField(
  2354. nieuwsbriefItemItem,
  2355. r'''$.omschrijving''',
  2356. ).toString(),
  2357. style: FlutterFlowTheme
  2358. .of(context)
  2359. .bodySmall
  2360. .override(
  2361. font:
  2362. GoogleFonts
  2363. .roboto(
  2364. fontWeight: FlutterFlowTheme.of(
  2365. context)
  2366. .bodySmall
  2367. .fontWeight,
  2368. fontStyle: FlutterFlowTheme.of(
  2369. context)
  2370. .bodySmall
  2371. .fontStyle,
  2372. ),
  2373. color: FlutterFlowTheme.of(
  2374. context)
  2375. .secondaryText,
  2376. letterSpacing:
  2377. 0.0,
  2378. fontWeight: FlutterFlowTheme.of(
  2379. context)
  2380. .bodySmall
  2381. .fontWeight,
  2382. fontStyle: FlutterFlowTheme.of(
  2383. context)
  2384. .bodySmall
  2385. .fontStyle,
  2386. ),
  2387. ),
  2388. ],
  2389. ),
  2390. ),
  2391. if (!functions.nieuwsbriefAan(
  2392. nieuwsbriefItemItem))
  2393. FlutterFlowIconButton(
  2394. borderRadius: 8.0,
  2395. buttonSize: 40.0,
  2396. icon: Icon(
  2397. Icons.toggle_off,
  2398. color:
  2399. FlutterFlowTheme.of(
  2400. context)
  2401. .secondaryText,
  2402. size: 32.0,
  2403. ),
  2404. onPressed: () async {
  2405. _model.abonneerResultaat =
  2406. await actions
  2407. .drupalRequest(
  2408. 'POST',
  2409. 'https://uitgaanskrant.com/nl/flutterdrup/nieuwsbrieven/subscribe.json',
  2410. FFAppState()
  2411. .userSessionname,
  2412. FFAppState()
  2413. .userSessionid,
  2414. FFAppState()
  2415. .userToken,
  2416. '{\"tid\": ${getJsonField(
  2417. nieuwsbriefItemItem,
  2418. r'''$.tid''',
  2419. ).toString()}}',
  2420. );
  2421. safeSetState(() {});
  2422. ScaffoldMessenger.of(
  2423. context)
  2424. .showSnackBar(
  2425. SnackBar(
  2426. content: Text(
  2427. functions.nieuwsbriefGelukt(
  2428. _model
  2429. .abonneerResultaat)
  2430. ? 'Je bent nu aangemeld voor de nieuwsbrief'
  2431. : 'Er ging iets mis. Probeer het later opnieuw.',
  2432. style: TextStyle(
  2433. color: FlutterFlowTheme.of(
  2434. context)
  2435. .primaryText,
  2436. ),
  2437. ),
  2438. duration: Duration(
  2439. milliseconds:
  2440. 4000),
  2441. backgroundColor:
  2442. FlutterFlowTheme.of(
  2443. context)
  2444. .secondary,
  2445. ),
  2446. );
  2447. safeSetState(() {});
  2448. },
  2449. ),
  2450. if (functions.nieuwsbriefAan(
  2451. nieuwsbriefItemItem))
  2452. FlutterFlowIconButton(
  2453. borderRadius: 8.0,
  2454. buttonSize: 40.0,
  2455. icon: Icon(
  2456. Icons.toggle_on,
  2457. color:
  2458. FlutterFlowTheme.of(
  2459. context)
  2460. .primary,
  2461. size: 32.0,
  2462. ),
  2463. onPressed: () async {
  2464. _model.afmeldResultaat =
  2465. await actions
  2466. .drupalRequest(
  2467. 'POST',
  2468. 'https://uitgaanskrant.com/nl/flutterdrup/nieuwsbrieven/unsubscribe.json',
  2469. FFAppState()
  2470. .userSessionname,
  2471. FFAppState()
  2472. .userSessionid,
  2473. FFAppState()
  2474. .userToken,
  2475. '{\"tid\": ${getJsonField(
  2476. nieuwsbriefItemItem,
  2477. r'''$.tid''',
  2478. ).toString()}}',
  2479. );
  2480. safeSetState(() {});
  2481. ScaffoldMessenger.of(
  2482. context)
  2483. .showSnackBar(
  2484. SnackBar(
  2485. content: Text(
  2486. functions.nieuwsbriefGelukt(
  2487. _model
  2488. .afmeldResultaat)
  2489. ? 'Je bent nu afgemeld voor de nieuwsbrief'
  2490. : 'Er ging iets mis. Probeer het later opnieuw.',
  2491. style: TextStyle(
  2492. color: FlutterFlowTheme.of(
  2493. context)
  2494. .primaryText,
  2495. ),
  2496. ),
  2497. duration: Duration(
  2498. milliseconds:
  2499. 4000),
  2500. backgroundColor:
  2501. FlutterFlowTheme.of(
  2502. context)
  2503. .secondary,
  2504. ),
  2505. );
  2506. safeSetState(() {});
  2507. },
  2508. ),
  2509. ],
  2510. ),
  2511. );
  2512. },
  2513. );
  2514. },
  2515. );
  2516. },
  2517. ),
  2518. if (!(_model.favGemeenten.isNotEmpty))
  2519. Padding(
  2520. padding: EdgeInsetsDirectional.fromSTEB(
  2521. 16.0, 8.0, 16.0, 24.0),
  2522. child: InkWell(
  2523. splashColor: Colors.transparent,
  2524. focusColor: Colors.transparent,
  2525. hoverColor: Colors.transparent,
  2526. highlightColor: Colors.transparent,
  2527. onTap: () async {
  2528. context.pushNamed(
  2529. SelectprovinciegemeenteWidget
  2530. .routeName);
  2531. },
  2532. child: Text(
  2533. FFLocalizations.of(context).getText(
  2534. '13hlbqrf' /* Je volgt nog geen gemeenten, d... */,
  2535. ),
  2536. style: FlutterFlowTheme.of(context)
  2537. .bodyMedium
  2538. .override(
  2539. font: GoogleFonts.roboto(
  2540. fontWeight:
  2541. FlutterFlowTheme.of(context)
  2542. .bodyMedium
  2543. .fontWeight,
  2544. fontStyle:
  2545. FlutterFlowTheme.of(context)
  2546. .bodyMedium
  2547. .fontStyle,
  2548. ),
  2549. color:
  2550. FlutterFlowTheme.of(context)
  2551. .primary,
  2552. letterSpacing: 0.0,
  2553. fontWeight:
  2554. FlutterFlowTheme.of(context)
  2555. .bodyMedium
  2556. .fontWeight,
  2557. fontStyle:
  2558. FlutterFlowTheme.of(context)
  2559. .bodyMedium
  2560. .fontStyle,
  2561. ),
  2562. ),
  2563. ),
  2564. ),
  2565. Padding(
  2566. padding: EdgeInsetsDirectional.fromSTEB(
  2567. 16.0, 8.0, 16.0, 24.0),
  2568. child: InkWell(
  2569. splashColor: Colors.transparent,
  2570. focusColor: Colors.transparent,
  2571. hoverColor: Colors.transparent,
  2572. highlightColor: Colors.transparent,
  2573. onTap: () async {
  2574. context.pushNamed(
  2575. SelectprovinciegemeenteWidget
  2576. .routeName);
  2577. },
  2578. child: Text(
  2579. FFLocalizations.of(context).getText(
  2580. 'jmzi90pc' /* De wekelijkse uitgaansagenda g... */,
  2581. ),
  2582. style: FlutterFlowTheme.of(context)
  2583. .bodyMedium
  2584. .override(
  2585. font: GoogleFonts.roboto(
  2586. fontWeight:
  2587. FlutterFlowTheme.of(context)
  2588. .bodyMedium
  2589. .fontWeight,
  2590. fontStyle:
  2591. FlutterFlowTheme.of(context)
  2592. .bodyMedium
  2593. .fontStyle,
  2594. ),
  2595. color: FlutterFlowTheme.of(context)
  2596. .secondary,
  2597. letterSpacing: 0.0,
  2598. fontWeight:
  2599. FlutterFlowTheme.of(context)
  2600. .bodyMedium
  2601. .fontWeight,
  2602. fontStyle:
  2603. FlutterFlowTheme.of(context)
  2604. .bodyMedium
  2605. .fontStyle,
  2606. ),
  2607. ),
  2608. ),
  2609. ),
  2610. ],
  2611. ),
  2612. ],
  2613. ),
  2614. ),
  2615. ],
  2616. ),
  2617. ),
  2618. ],
  2619. ),
  2620. ),
  2621. ),
  2622. ),
  2623. );
  2624. }
  2625. }