Fakultas Ilmu Komputer UI

Commit ebd90b71 authored by Putri Salsabila's avatar Putri Salsabila
Browse files

[REFACTOR] Add navigation to detail post kegiatan page

parent 1e18a230
Pipeline #76795 failed with stages
in 23 minutes and 22 seconds
// import 'package:bisaGo/config/strings.dart';
import 'package:bisaGo/config/styles.dart';
import 'package:bisaGo/model/lokasi.dart';
import 'package:bisaGo/model/kegiatan.dart';
import 'package:bisaGo/page/filter_fasilitas/postingan/detail_post_kegiatan.dart';
import 'package:flutter/material.dart';
// import 'package:bisaGo/component/image_holder.dart';
import 'package:bisaGo/config/styles.dart';
import 'package:bisaGo/model/kegiatan.dart';
class Kegiatan extends StatefulWidget {
final Lokasi lokasi;
......@@ -24,7 +24,25 @@ class _KegiatanState extends State<Kegiatan> {
Widget build(BuildContext context) {
return InkWell(
// key: Key('Kegiatan'),
key: Key('Kegiatan'),
onTap: () {
builder: (BuildContext context) => DetailPostKegiatanPage(
lokasi: widget.lokasi,
kegiatan: KegiatanModel(
id: widget.kegiatan.id,
namaLokasi: widget.lokasi.name,
creator: widget.kegiatan.creator,
namaKegiatan: widget.kegiatan.namaKegiatan,
penyelenggara: widget.kegiatan.penyelenggara,
narahubung: widget.kegiatan.narahubung,
deskripsi: widget.kegiatan.deskripsi,
timeStart: widget.kegiatan.timeStart,
timeEnd: widget.kegiatan.timeEnd
child: Container(
margin: const EdgeInsets.only(bottom: regularSpace),
padding: const EdgeInsets.all(doubleSpace),
......@@ -22,7 +22,7 @@ class DetailPostKegiatanPage extends StatefulWidget {
final Lokasi lokasi;
final KegiatanModel kegiatan; // ganti model x // sudah
const DetailPostKegiatanPage(
{@required this.lokasi, @required this.kegiatan, Key key})
{@required this.kegiatan, @required this.lokasi, Key key})
: super(key: key);
_DetailPostKegiatanPageState createState() => _DetailPostKegiatanPageState();
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment