conflict resolved
This commit is contained in:
BIN
assets/images/png/Group 1000004149.png
Normal file
BIN
assets/images/png/Group 1000004149.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.7 KiB |
@@ -180,6 +180,10 @@ class ApiUrls {
|
||||
|
||||
static const geteditcommunity = "${baseUrl}edit-community";
|
||||
|
||||
static const posteditcommunity = "${baseUrl}update-community";
|
||||
|
||||
static const getactivitieslist = "${baseUrl}get_activity";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -229,7 +229,7 @@ class _FeedTabState extends State<FeedTab> {
|
||||
}
|
||||
}
|
||||
|
||||
setValues() {
|
||||
Future<void> setValues() async {
|
||||
if (mounted) {
|
||||
combinedList.clear();
|
||||
combinedListGlobal.clear();
|
||||
@@ -239,7 +239,7 @@ class _FeedTabState extends State<FeedTab> {
|
||||
combinedListGlobal.addAll(combinedList);
|
||||
_setModel();
|
||||
countersHelper.setListsPopular();
|
||||
_fetchIcons();
|
||||
await _fetchIcons();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@ import 'package:flutter/services.dart';
|
||||
import 'package:image_gallery_saver/image_gallery_saver.dart';
|
||||
import 'package:path_provider/path_provider.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:path/path.dart' as path;
|
||||
|
||||
class Helper {
|
||||
static Future<MultipartFile> networkImageToMultipartFile(
|
||||
@@ -16,14 +17,24 @@ class Helper {
|
||||
Response<Uint8List> response = await dio.get<Uint8List>(imageUrl,
|
||||
options: Options(responseType: ResponseType.bytes));
|
||||
|
||||
final cleanedFileName = _cleanFileName(imageUrl);
|
||||
|
||||
MultipartFile multipartFile = MultipartFile.fromBytes(
|
||||
response.data!,
|
||||
filename: imageUrl.substring(imageUrl.lastIndexOf("/") + 1),
|
||||
filename: cleanedFileName,
|
||||
// imageUrl.substring(imageUrl.lastIndexOf("/") + 1),
|
||||
);
|
||||
|
||||
return multipartFile;
|
||||
}
|
||||
|
||||
static String _cleanFileName(String url) {
|
||||
// Parse the URL and extract the path
|
||||
final uri = Uri.parse(url);
|
||||
// Extract the base name from the path, removing any query parameters
|
||||
return path.basename(uri.path);
|
||||
}
|
||||
|
||||
static Future<MultipartFile> assetImageToMultipartFile(
|
||||
String assetImagePath, String fileName) async {
|
||||
ByteData assetByteData = await rootBundle.load(assetImagePath);
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -53,26 +53,26 @@ class _ManageGroupsState extends State<ManageGroups> {
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: CommonAppbar(
|
||||
titleTxt: "Manage groups",
|
||||
customActionWidget: InkWell(
|
||||
onTap: () {},
|
||||
child: Container(
|
||||
height: 35.h,
|
||||
width: 35.w,
|
||||
decoration: BoxDecoration(
|
||||
color: Color(0xFFD90B2E),
|
||||
shape: BoxShape.circle,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: Color(0x40000000),
|
||||
offset: Offset(0, 6),
|
||||
blurRadius: 8,
|
||||
spreadRadius: 0,
|
||||
),
|
||||
],
|
||||
),
|
||||
child: Icon(Icons.add, color: Colors.white, weight: 2),
|
||||
),
|
||||
),
|
||||
// customActionWidget: InkWell(
|
||||
// onTap: () {},
|
||||
// child: Container(
|
||||
// height: 35.h,
|
||||
// width: 35.w,
|
||||
// decoration: BoxDecoration(
|
||||
// color: Color(0xFFD90B2E),
|
||||
// shape: BoxShape.circle,
|
||||
// boxShadow: [
|
||||
// BoxShadow(
|
||||
// color: Color(0x40000000),
|
||||
// offset: Offset(0, 6),
|
||||
// blurRadius: 8,
|
||||
// spreadRadius: 0,
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// child: Icon(Icons.add, color: Colors.white, weight: 2),
|
||||
// ),
|
||||
// ),
|
||||
),
|
||||
body: Stack(children: [
|
||||
Container(
|
||||
@@ -111,7 +111,7 @@ class _ManageGroupsState extends State<ManageGroups> {
|
||||
opacity2: 0.24,
|
||||
width: 50.w,
|
||||
height: 50.h,
|
||||
borderRadius: BorderRadius.circular( 100),
|
||||
borderRadius: BorderRadius.circular(100),
|
||||
customWidget: Center(
|
||||
child: Image.asset(
|
||||
"assets/images/png/Black.png",
|
||||
@@ -178,11 +178,14 @@ Widget groupWidget({
|
||||
],
|
||||
),
|
||||
Spacer(),
|
||||
Icon(
|
||||
Icons.clear,
|
||||
color: Color(0xFFFFFFFF),
|
||||
weight: 1.88,
|
||||
Image.asset(
|
||||
'assets/images/png/Group 1000004149.png',
|
||||
)
|
||||
// Icon(
|
||||
// Icons.clear,
|
||||
// color: Color(0xFFFFFFFF),
|
||||
// weight: 1.88,
|
||||
// )
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -152,151 +152,154 @@ class _AddGroupState extends State<AddGroup> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
// key: _scaffoldKey1,
|
||||
backgroundColor: Color(0xFF222935),
|
||||
extendBody: true,
|
||||
appBar: CommonAppbar(
|
||||
titleTxt: "Add groups",
|
||||
),
|
||||
resizeToAvoidBottomInset: false,
|
||||
bottomNavigationBar: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.w, vertical: 10.h),
|
||||
child: CustomButton(
|
||||
text: "Add",
|
||||
onPressed: () {
|
||||
// Get.toNamed(RouteName.mycommunity);
|
||||
print('selected groups are ${_selectedIndices.toString()}');
|
||||
Uploadata();
|
||||
},
|
||||
return GestureDetector(
|
||||
onTap: () => FocusManager.instance.primaryFocus?.unfocus(),
|
||||
child: Scaffold(
|
||||
// key: _scaffoldKey1,
|
||||
backgroundColor: Color(0xFF222935),
|
||||
extendBody: true,
|
||||
appBar: CommonAppbar(
|
||||
titleTxt: "Add groups",
|
||||
),
|
||||
),
|
||||
body: Stack(children: [
|
||||
Container(
|
||||
decoration: const BoxDecoration(
|
||||
image: DecorationImage(
|
||||
image: AssetImage("assets/images/png/Ellipse 1496.png"),
|
||||
fit: BoxFit.fill)),
|
||||
resizeToAvoidBottomInset: false,
|
||||
bottomNavigationBar: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.w, vertical: 10.h),
|
||||
child: CustomButton(
|
||||
text: "Add",
|
||||
onPressed: () {
|
||||
// Get.toNamed(RouteName.mycommunity);
|
||||
print('selected groups are ${_selectedIndices.toString()}');
|
||||
Uploadata();
|
||||
},
|
||||
),
|
||||
),
|
||||
SingleChildScrollView(
|
||||
child: Column(children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.w),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
sizedBoxHeight(20.h),
|
||||
CustomTextFormField(
|
||||
leadingIcon: SizedBox(
|
||||
height: 23,
|
||||
width: 23,
|
||||
child: Center(
|
||||
child: Image.asset(
|
||||
"assets/images/png/ion_search-outline.png",
|
||||
height: 23,
|
||||
width: 23,
|
||||
body: Stack(children: [
|
||||
Container(
|
||||
decoration: const BoxDecoration(
|
||||
image: DecorationImage(
|
||||
image: AssetImage("assets/images/png/Ellipse 1496.png"),
|
||||
fit: BoxFit.fill)),
|
||||
),
|
||||
SingleChildScrollView(
|
||||
child: Column(children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.w),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
sizedBoxHeight(20.h),
|
||||
CustomTextFormField(
|
||||
leadingIcon: SizedBox(
|
||||
height: 23,
|
||||
width: 23,
|
||||
child: Center(
|
||||
child: Image.asset(
|
||||
"assets/images/png/ion_search-outline.png",
|
||||
height: 23,
|
||||
width: 23,
|
||||
),
|
||||
),
|
||||
),
|
||||
hintText: "Search groups",
|
||||
onInput: (value) {
|
||||
Getcommunity().getCommunityAddGroupsearch(value,
|
||||
streamController: searchcontroller);
|
||||
},
|
||||
),
|
||||
hintText: "Search groups",
|
||||
onInput: (value) {
|
||||
Getcommunity().getCommunityAddGroupsearch(value,
|
||||
streamController: searchcontroller);
|
||||
},
|
||||
),
|
||||
sizedBoxHeight(25.h),
|
||||
// Row(
|
||||
// children: [
|
||||
// commonGlassUI(
|
||||
// opacity1: 0.24,
|
||||
// opacity2: 0.24,
|
||||
// width: 50.w,
|
||||
// height: 50.h,
|
||||
// borderRadius: BorderRadius.circular( 100),
|
||||
// customWidget: Center(
|
||||
// child: Image.asset(
|
||||
// "assets/images/png/Black.png",
|
||||
// height: 30.h,
|
||||
// width: 30.w,
|
||||
// )),
|
||||
// borderwidth: 0.5),
|
||||
// sizedBoxWidth(8.w),
|
||||
// text18w400_FCFCFC("Create group"),
|
||||
// Spacer(),
|
||||
// Icon(
|
||||
// Icons.arrow_forward_ios_outlined,
|
||||
// color: Colors.white,
|
||||
// size: 14.sp,
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// sizedBoxHeight(25.h),
|
||||
sizedBoxHeight(30.h),
|
||||
text18w700white("Existing Groups"),
|
||||
sizedBoxHeight(20.h),
|
||||
]),
|
||||
),
|
||||
StreamBuilder<CommunityAddgroupsModel>(
|
||||
stream: searchcontroller.stream,
|
||||
builder: (ctx, snapshot) {
|
||||
if (snapshot.connectionState == ConnectionState.waiting) {
|
||||
return const Center(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
CircularProgressIndicator(),
|
||||
],
|
||||
),
|
||||
);
|
||||
} else if (snapshot.hasError) {
|
||||
return Center(
|
||||
child: Text(
|
||||
'${snapshot.error} occured',
|
||||
style: TextStyle(fontSize: 18.sp),
|
||||
),
|
||||
);
|
||||
} else {
|
||||
return communityaddgroupobj!.data.isEmpty
|
||||
? _buildNoDataBody(context)
|
||||
: ListView.builder(
|
||||
shrinkWrap: true,
|
||||
physics: ScrollPhysics(),
|
||||
itemCount: communityaddgroupobj!.data.length,
|
||||
itemBuilder: (context, index) {
|
||||
final isChecked = _selectedIndices.contains(
|
||||
communityaddgroupobj!.data[index].id!);
|
||||
return Column(
|
||||
children: [
|
||||
groupWidget(
|
||||
index:
|
||||
communityaddgroupobj!.data[index].id!,
|
||||
imagePath: communityaddgroupobj!
|
||||
.data[index].groupImage ??
|
||||
'',
|
||||
title: communityaddgroupobj!
|
||||
.data[index].title!,
|
||||
subtitle: communityaddgroupobj!
|
||||
.data[index].description!,
|
||||
isChecked: isChecked,
|
||||
// isCheckedList[index],
|
||||
onCheckedChanged: (bool? value) {
|
||||
// isCheckedList[index] = value ?? false;
|
||||
_onContainerTap(communityaddgroupobj!
|
||||
.data[index].id!);
|
||||
},
|
||||
),
|
||||
commonDivider(),
|
||||
],
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
}),
|
||||
sizedBoxHeight(50.h),
|
||||
]),
|
||||
)
|
||||
]));
|
||||
sizedBoxHeight(25.h),
|
||||
// Row(
|
||||
// children: [
|
||||
// commonGlassUI(
|
||||
// opacity1: 0.24,
|
||||
// opacity2: 0.24,
|
||||
// width: 50.w,
|
||||
// height: 50.h,
|
||||
// borderRadius: BorderRadius.circular( 100),
|
||||
// customWidget: Center(
|
||||
// child: Image.asset(
|
||||
// "assets/images/png/Black.png",
|
||||
// height: 30.h,
|
||||
// width: 30.w,
|
||||
// )),
|
||||
// borderwidth: 0.5),
|
||||
// sizedBoxWidth(8.w),
|
||||
// text18w400_FCFCFC("Create group"),
|
||||
// Spacer(),
|
||||
// Icon(
|
||||
// Icons.arrow_forward_ios_outlined,
|
||||
// color: Colors.white,
|
||||
// size: 14.sp,
|
||||
// ),
|
||||
// ],
|
||||
// ),
|
||||
// sizedBoxHeight(25.h),
|
||||
sizedBoxHeight(30.h),
|
||||
text18w700white("Existing Groups"),
|
||||
sizedBoxHeight(20.h),
|
||||
]),
|
||||
),
|
||||
StreamBuilder<CommunityAddgroupsModel>(
|
||||
stream: searchcontroller.stream,
|
||||
builder: (ctx, snapshot) {
|
||||
if (snapshot.connectionState == ConnectionState.waiting) {
|
||||
return const Center(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
CircularProgressIndicator(),
|
||||
],
|
||||
),
|
||||
);
|
||||
} else if (snapshot.hasError) {
|
||||
return Center(
|
||||
child: Text(
|
||||
'${snapshot.error} occured',
|
||||
style: TextStyle(fontSize: 18.sp),
|
||||
),
|
||||
);
|
||||
} else {
|
||||
return communityaddgroupobj!.data.isEmpty
|
||||
? _buildNoDataBody(context)
|
||||
: ListView.builder(
|
||||
shrinkWrap: true,
|
||||
physics: ScrollPhysics(),
|
||||
itemCount: communityaddgroupobj!.data.length,
|
||||
itemBuilder: (context, index) {
|
||||
final isChecked = _selectedIndices.contains(
|
||||
communityaddgroupobj!.data[index].id!);
|
||||
return Column(
|
||||
children: [
|
||||
groupWidget(
|
||||
index:
|
||||
communityaddgroupobj!.data[index].id!,
|
||||
imagePath: communityaddgroupobj!
|
||||
.data[index].groupImage ??
|
||||
'',
|
||||
title: communityaddgroupobj!
|
||||
.data[index].title!,
|
||||
subtitle: communityaddgroupobj!
|
||||
.data[index].description!,
|
||||
isChecked: isChecked,
|
||||
// isCheckedList[index],
|
||||
onCheckedChanged: (bool? value) {
|
||||
// isCheckedList[index] = value ?? false;
|
||||
_onContainerTap(communityaddgroupobj!
|
||||
.data[index].id!);
|
||||
},
|
||||
),
|
||||
commonDivider(),
|
||||
],
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
}),
|
||||
sizedBoxHeight(50.h),
|
||||
]),
|
||||
)
|
||||
])),
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildNoDataBody(context) {
|
||||
|
||||
@@ -80,7 +80,7 @@ class Datum {
|
||||
final bool? isILiked;
|
||||
final bool? isIFollow;
|
||||
final bool? isISaved;
|
||||
final dynamic likeIcon;
|
||||
final LikeIcon? likeIcon;
|
||||
final int? totalComment;
|
||||
final int? totalSave;
|
||||
final List<int> tagsXid;
|
||||
@@ -116,7 +116,8 @@ class Datum {
|
||||
isILiked: json["is_i_liked"],
|
||||
isIFollow: json["is_i_follow"],
|
||||
isISaved: json["is_i_saved"],
|
||||
likeIcon: json["likeIcon"],
|
||||
// likeIcon: json["likeIcon"],
|
||||
likeIcon: json["likeIcon"] == null ? null : LikeIcon.fromJson(json["likeIcon"]),
|
||||
totalComment: json["total_comment"],
|
||||
totalSave: json["total_save"],
|
||||
tagsXid: json["tags_xid"] == null
|
||||
@@ -164,6 +165,42 @@ class AttachTag {
|
||||
}
|
||||
}
|
||||
|
||||
class LikeIcon {
|
||||
LikeIcon({
|
||||
required this.likeIconsXid,
|
||||
required this.likeIcon,
|
||||
});
|
||||
|
||||
final int? likeIconsXid;
|
||||
final LikeIconClass? likeIcon;
|
||||
|
||||
factory LikeIcon.fromJson(Map<String, dynamic> json){
|
||||
return LikeIcon(
|
||||
likeIconsXid: json["like_icons_xid"],
|
||||
likeIcon: json["like_icon"] == null ? null : LikeIconClass.fromJson(json["like_icon"]),
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class LikeIconClass {
|
||||
LikeIconClass({
|
||||
required this.id,
|
||||
required this.image,
|
||||
});
|
||||
|
||||
final int? id;
|
||||
final String? image;
|
||||
|
||||
factory LikeIconClass.fromJson(Map<String, dynamic> json){
|
||||
return LikeIconClass(
|
||||
id: json["id"],
|
||||
image: json["image"],
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class ManageTag {
|
||||
ManageTag({
|
||||
required this.id,
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
class ActivitiesListsModel {
|
||||
ActivitiesListsModel({
|
||||
required this.status,
|
||||
required this.statusCode,
|
||||
required this.message,
|
||||
required this.data,
|
||||
});
|
||||
|
||||
final String? status;
|
||||
final int? statusCode;
|
||||
final String? message;
|
||||
final List<Datum> data;
|
||||
|
||||
factory ActivitiesListsModel.fromJson(Map<String, dynamic> json){
|
||||
return ActivitiesListsModel(
|
||||
status: json["status"],
|
||||
statusCode: json["status_code"],
|
||||
message: json["message"],
|
||||
data: json["data"] == null ? [] : List<Datum>.from(json["data"]!.map((x) => Datum.fromJson(x))),
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class Datum {
|
||||
Datum({
|
||||
required this.id,
|
||||
required this.title,
|
||||
required this.image,
|
||||
});
|
||||
|
||||
final int? id;
|
||||
final String? title;
|
||||
final String? image;
|
||||
|
||||
factory Datum.fromJson(Map<String, dynamic> json){
|
||||
return Datum(
|
||||
id: json["id"],
|
||||
title: json["title"],
|
||||
image: json["image"],
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -2,17 +2,12 @@ import 'dart:developer';
|
||||
import 'dart:io';
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:dio/dio.dart';
|
||||
import 'package:dotted_border/dotted_border.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:get/get.dart' hide MultipartFile, FormData;
|
||||
import 'package:get/get_connect/http/src/utils/utils.dart';
|
||||
import 'package:regroup/Common/CommonButton.dart';
|
||||
import 'package:regroup/Common/CommonGlassmorphism.dart';
|
||||
import 'package:regroup/Common/base_manager.dart';
|
||||
import 'package:regroup/Main_Screens/ProfileTab/EditProfile/Model/InterestModel.dart'
|
||||
as primaryactlist;
|
||||
import 'package:regroup/Utils/Common/CommonAppbar.dart';
|
||||
import 'package:regroup/Utils/Common/CommonDropdown.dart';
|
||||
import 'package:regroup/Utils/Common/CustomNextButton.dart';
|
||||
@@ -23,7 +18,7 @@ import 'package:regroup/Utils/Common/sized_box.dart';
|
||||
import 'package:regroup/Utils/dialogs.dart';
|
||||
import 'package:regroup/Utils/texts.dart';
|
||||
import 'package:regroup/resources/routes/route_name.dart';
|
||||
import 'package:regroup/sidemenu/Community/MyCommunity/view_model/postmethod.dart';
|
||||
import 'package:regroup/sidemenu/Community/MyCommunity/Model/activitiesListModel.dart' as primaryactlist;
|
||||
import 'package:regroup/sidemenu/Community/MyCommunity/view_model/primaryactivity.dart';
|
||||
import 'package:remove_emoji_input_formatter/remove_emoji_input_formatter.dart';
|
||||
import 'package:path/path.dart' as path;
|
||||
@@ -60,8 +55,8 @@ class _NewCommunityState extends State<NewCommunity> {
|
||||
});
|
||||
}
|
||||
|
||||
primaryactlist.InterestModel? abilityModel;
|
||||
List<primaryactlist.Data> activity = [];
|
||||
primaryactlist.ActivitiesListsModel? abilityModel;
|
||||
List<primaryactlist.Datum> activity = [];
|
||||
List<String> _activitydrop = [];
|
||||
|
||||
Future<void> fetchActivitylist() async {
|
||||
@@ -69,11 +64,11 @@ class _NewCommunityState extends State<NewCommunity> {
|
||||
ResponseData<dynamic> response = await abilityLsitAPI.getActivitylistApi();
|
||||
|
||||
if (response.status == ResponseStatus.SUCCESS) {
|
||||
abilityModel = primaryactlist.InterestModel.fromJson(response.data!);
|
||||
abilityModel = primaryactlist.ActivitiesListsModel.fromJson(response.data!);
|
||||
setState(() {
|
||||
activity = abilityModel!.data ?? []; // Store the fetched cities
|
||||
activity = abilityModel?.data ?? []; // Store the fetched cities
|
||||
_activitydrop =
|
||||
activity.map((platform) => platform.name.toString()).toList();
|
||||
activity.map((platform) => platform.title.toString()).toList();
|
||||
});
|
||||
log(activity.toString());
|
||||
} else {
|
||||
@@ -89,7 +84,7 @@ class _NewCommunityState extends State<NewCommunity> {
|
||||
|
||||
// Find and add the ID of the selected ability
|
||||
for (var activityItem in activity) {
|
||||
if (selectedAbility == activityItem.name) {
|
||||
if (selectedAbility == activityItem.title) {
|
||||
selectedactivityid = activityItem.id!;
|
||||
break; // Stop once the matching item is found
|
||||
}
|
||||
@@ -160,7 +155,7 @@ class _NewCommunityState extends State<NewCommunity> {
|
||||
// key: _scaffoldKey1,
|
||||
backgroundColor: Color(0xFF222935),
|
||||
extendBody: true,
|
||||
resizeToAvoidBottomInset: false,
|
||||
resizeToAvoidBottomInset: true,
|
||||
appBar: CommonAppbar(
|
||||
titleTxt: "New community",
|
||||
),
|
||||
|
||||
@@ -205,6 +205,28 @@ class _CommunityDetailsState extends State<CommunityDetails> {
|
||||
),
|
||||
),
|
||||
),
|
||||
PopupMenuDivider(),
|
||||
PopupMenuItem(
|
||||
onTap: () {
|
||||
Get.toNamed(RouteName.communitysetting, arguments: {
|
||||
'communityid': CommunityId,
|
||||
});
|
||||
},
|
||||
child: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 8.w),
|
||||
child: Row(
|
||||
children: [
|
||||
text14w400white("Edit community"),
|
||||
Spacer(),
|
||||
Image.asset(
|
||||
"assets/images/png/setting2.png",
|
||||
height: 18.h,
|
||||
width: 18.w,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
child: Image.asset(
|
||||
'assets/images/png/Group 1000004071.png',
|
||||
@@ -458,7 +480,11 @@ class _CommunityDetailsState extends State<CommunityDetails> {
|
||||
sizedBoxHeight(20.h),
|
||||
GestureDetector(
|
||||
onTap: () {
|
||||
Get.toNamed(RouteName.addgroup);
|
||||
// Get.toNamed(RouteName.addgroup);
|
||||
Get.toNamed(RouteName.group, arguments: {
|
||||
'id': CommunityId,
|
||||
'iscommunity': true,
|
||||
});
|
||||
},
|
||||
child: commonGlassUI(
|
||||
width: double.infinity,
|
||||
@@ -678,6 +704,7 @@ class _PostsTabState extends State<PostsTab> {
|
||||
likeIcon: LikeIcon1(
|
||||
likeIcon: LikeIconClass1(
|
||||
id: e.likeIcon?.likeIcon?.id,
|
||||
// likeIcon?.id,
|
||||
image: e.likeIcon?.likeIcon?.image),
|
||||
likeIconsXid: e.likeIcon?.likeIconsXid,
|
||||
),
|
||||
|
||||
@@ -15,4 +15,15 @@ class PostMethodCommunity {
|
||||
print("response message is ${response.message}");
|
||||
return response;
|
||||
}
|
||||
|
||||
Future<ResponseData<dynamic>> postEditcommunity(updata) async {
|
||||
print("updata is $updata");
|
||||
final response = await NetworkApiServices().postApi(
|
||||
updata,
|
||||
ApiUrls.posteditcommunity,
|
||||
);
|
||||
print("response is ${response.data}");
|
||||
print("response message is ${response.message}");
|
||||
return response;
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
import 'package:regroup/Common/api_urls.dart';
|
||||
import 'package:regroup/Common/base_manager.dart';
|
||||
import 'package:regroup/Common/controller/data/network/network_api.dart';
|
||||
import 'package:regroup/Main_Screens/ProfileTab/EditProfile/Model/InterestModel.dart';
|
||||
import 'package:regroup/sidemenu/Community/MyCommunity/Model/activitiesListModel.dart';
|
||||
|
||||
InterestModel? interestlistobj;
|
||||
ActivitiesListsModel? interestlistobj;
|
||||
|
||||
|
||||
class PrimaryActivityListApi {
|
||||
@@ -11,7 +11,7 @@ class PrimaryActivityListApi {
|
||||
var data = "";
|
||||
Future<ResponseData<dynamic>> getActivitylistApi() async {
|
||||
final response = await NetworkApiServices().getApi(
|
||||
ApiUrls.getinterestlist,
|
||||
ApiUrls.getactivitieslist,
|
||||
|
||||
);
|
||||
|
||||
@@ -20,8 +20,8 @@ class PrimaryActivityListApi {
|
||||
Map<String, dynamic>.from(response.data);
|
||||
if (responseData['status'] == "success") {
|
||||
print("success");
|
||||
InterestModel interestlistobj =
|
||||
InterestModel.fromJson(responseData);
|
||||
ActivitiesListsModel interestlistobj =
|
||||
ActivitiesListsModel.fromJson(responseData);
|
||||
} else {
|
||||
// return ResponseData<dynamic>(
|
||||
// responseData['message'], ResponseStatus.FAILED);
|
||||
|
||||
Reference in New Issue
Block a user