commit
023329f021
14
filcnaplo/ios/Flutter/Generated 3.xcconfig
Normal file
14
filcnaplo/ios/Flutter/Generated 3.xcconfig
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
// This is a generated file; do not edit or check into version control.
|
||||||
|
FLUTTER_ROOT=/Users/kima/src/flutter
|
||||||
|
FLUTTER_APPLICATION_PATH=/Users/kima/Documents/refilc/app/naplo/filcnaplo
|
||||||
|
COCOAPODS_PARALLEL_CODE_SIGN=true
|
||||||
|
FLUTTER_TARGET=lib/main.dart
|
||||||
|
FLUTTER_BUILD_DIR=build
|
||||||
|
FLUTTER_BUILD_NAME=4.2.0
|
||||||
|
FLUTTER_BUILD_NUMBER=220
|
||||||
|
EXCLUDED_ARCHS[sdk=iphonesimulator*]=i386
|
||||||
|
EXCLUDED_ARCHS[sdk=iphoneos*]=armv7
|
||||||
|
DART_OBFUSCATION=false
|
||||||
|
TRACK_WIDGET_CREATION=true
|
||||||
|
TREE_SHAKE_ICONS=false
|
||||||
|
PACKAGE_CONFIG=.dart_tool/package_config.json
|
@ -5,6 +5,7 @@ class Ad {
|
|||||||
Uri? logoUrl;
|
Uri? logoUrl;
|
||||||
bool overridePremium;
|
bool overridePremium;
|
||||||
DateTime date;
|
DateTime date;
|
||||||
|
DateTime expireDate;
|
||||||
Uri launchUrl;
|
Uri launchUrl;
|
||||||
|
|
||||||
Ad({
|
Ad({
|
||||||
@ -14,10 +15,12 @@ class Ad {
|
|||||||
this.logoUrl,
|
this.logoUrl,
|
||||||
this.overridePremium = false,
|
this.overridePremium = false,
|
||||||
required this.date,
|
required this.date,
|
||||||
|
required this.expireDate,
|
||||||
required this.launchUrl,
|
required this.launchUrl,
|
||||||
});
|
});
|
||||||
|
|
||||||
factory Ad.fromJson(Map json) {
|
factory Ad.fromJson(Map json) {
|
||||||
|
print(json);
|
||||||
return Ad(
|
return Ad(
|
||||||
title: json['title'] ?? 'Ad',
|
title: json['title'] ?? 'Ad',
|
||||||
description: json['description'] ?? '',
|
description: json['description'] ?? '',
|
||||||
@ -26,6 +29,9 @@ class Ad {
|
|||||||
overridePremium: json['override_premium'] ?? false,
|
overridePremium: json['override_premium'] ?? false,
|
||||||
date:
|
date:
|
||||||
json['date'] != null ? DateTime.parse(json['date']) : DateTime.now(),
|
json['date'] != null ? DateTime.parse(json['date']) : DateTime.now(),
|
||||||
|
expireDate: json['expire_date'] != null
|
||||||
|
? DateTime.parse(json['expire_date'])
|
||||||
|
: DateTime.now(),
|
||||||
launchUrl: Uri.parse(json['launch_url'] ?? 'https://refilc.hu'),
|
launchUrl: Uri.parse(json['launch_url'] ?? 'https://refilc.hu'),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -8,7 +8,8 @@ List<DateWidget> getWidgets(List<Ad> providerAds) {
|
|||||||
|
|
||||||
if (providerAds.isNotEmpty) {
|
if (providerAds.isNotEmpty) {
|
||||||
for (var ad in providerAds) {
|
for (var ad in providerAds) {
|
||||||
if (ad.date.isAfter(DateTime.now())) {
|
if (ad.date.isBefore(DateTime.now()) &&
|
||||||
|
ad.expireDate.isAfter(DateTime.now())) {
|
||||||
providerAds.sort((a, b) => -a.date.compareTo(b.date));
|
providerAds.sort((a, b) => -a.date.compareTo(b.date));
|
||||||
|
|
||||||
items.add(DateWidget(
|
items.add(DateWidget(
|
||||||
|
@ -13,6 +13,9 @@ class AdTile extends StatelessWidget {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
print('geic');
|
||||||
|
print(ad);
|
||||||
|
|
||||||
return Padding(
|
return Padding(
|
||||||
padding: padding ?? const EdgeInsets.symmetric(horizontal: 8.0),
|
padding: padding ?? const EdgeInsets.symmetric(horizontal: 8.0),
|
||||||
child: PanelButton(
|
child: PanelButton(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user