- Added DropDown

- Added api for show listing , made data model, updated the dropdown
- Added api for category, made data model
- Made the dynamic height tableview to show all the shows
- On fav add remove , will refresh the mylist screen
- Added default load on hindi
- On category selection change, updating the show list data
- Handled the fav category id as int, string , string seeprated with “,”
- Modifying my list with bookmark id with above
This commit is contained in:
2024-06-19 20:07:47 +05:30
parent a8f0b7b662
commit 1d6add0322
34 changed files with 1992 additions and 64 deletions

View File

@@ -130,11 +130,21 @@
52CA28FC2BE11A0400708B49 /* UserIntrestVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52CA28FB2BE11A0400708B49 /* UserIntrestVM.swift */; };
52CC38C32BDF812F00B74C3E /* LocalisedElements.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52CC38C22BDF812F00B74C3E /* LocalisedElements.swift */; };
52CCD7B02C1AF0F80078BD65 /* RadioVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52CCD7AF2C1AF0F80078BD65 /* RadioVC.swift */; };
52D6A2462C21A29800145908 /* ContinueWatchingDM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A2452C21A29800145908 /* ContinueWatchingDM.swift */; };
52D6A2482C21A3A500145908 /* WebSeriesVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A2472C21A3A500145908 /* WebSeriesVM.swift */; };
52D6A24B2C21B43300145908 /* WebSeriesCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 52D6A24A2C21B43300145908 /* WebSeriesCell.xib */; };
52D6A24C2C21B43300145908 /* WebSeriesCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A2492C21B43300145908 /* WebSeriesCell.swift */; };
52D6A24E2C22B3AB00145908 /* WebSeriesShowListDM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A24D2C22B3AB00145908 /* WebSeriesShowListDM.swift */; };
52D6A2512C22B58200145908 /* WebSeriesShowListingCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A24F2C22B58200145908 /* WebSeriesShowListingCell.swift */; };
52D6A2542C22B93F00145908 /* CategoryListingDM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D6A2532C22B93F00145908 /* CategoryListingDM.swift */; };
52D6A2572C22C1E300145908 /* WebSeriesShowListingCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 52D6A2562C22C1E300145908 /* WebSeriesShowListingCell.xib */; };
52D774E92BDFBDA4001D87DE /* AuthenticationStringConstant.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D774E82BDFBDA4001D87DE /* AuthenticationStringConstant.swift */; };
52D774EB2BDFC0BF001D87DE /* OTPVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D774EA2BDFC0BF001D87DE /* OTPVC.swift */; };
52D774ED2BDFC13F001D87DE /* OTPVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D774EC2BDFC13F001D87DE /* OTPVM.swift */; };
52D774EF2BDFC50D001D87DE /* StringValidations.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D774EE2BDFC50D001D87DE /* StringValidations.swift */; };
52D774F12BDFC53B001D87DE /* StringSubScript.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52D774F02BDFC53B001D87DE /* StringSubScript.swift */; };
52DAC6482C21762900E2F85B /* WebSeries.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 52DAC6472C21762900E2F85B /* WebSeries.storyboard */; };
52DAC64E2C21775300E2F85B /* WebSeriesVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52DAC64D2C21775300E2F85B /* WebSeriesVC.swift */; };
52FB2D8F2BDF898F0009B0C7 /* TextFieldPadding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52FB2D8E2BDF898F0009B0C7 /* TextFieldPadding.swift */; };
52FDBA782BFF23F4009D7AC7 /* TimePeriod.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52FDBA772BFF23F4009D7AC7 /* TimePeriod.swift */; };
52FDBA7B2BFF2712009D7AC7 /* AuthFuncTimeHandling.swift in Sources */ = {isa = PBXBuildFile; fileRef = 52FDBA7A2BFF2712009D7AC7 /* AuthFuncTimeHandling.swift */; };
@@ -364,11 +374,21 @@
52CA28FB2BE11A0400708B49 /* UserIntrestVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UserIntrestVM.swift; sourceTree = "<group>"; };
52CC38C22BDF812F00B74C3E /* LocalisedElements.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocalisedElements.swift; sourceTree = "<group>"; };
52CCD7AF2C1AF0F80078BD65 /* RadioVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RadioVC.swift; sourceTree = "<group>"; };
52D6A2452C21A29800145908 /* ContinueWatchingDM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContinueWatchingDM.swift; sourceTree = "<group>"; };
52D6A2472C21A3A500145908 /* WebSeriesVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WebSeriesVM.swift; sourceTree = "<group>"; };
52D6A2492C21B43300145908 /* WebSeriesCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WebSeriesCell.swift; sourceTree = "<group>"; };
52D6A24A2C21B43300145908 /* WebSeriesCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = WebSeriesCell.xib; sourceTree = "<group>"; };
52D6A24D2C22B3AB00145908 /* WebSeriesShowListDM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WebSeriesShowListDM.swift; sourceTree = "<group>"; };
52D6A24F2C22B58200145908 /* WebSeriesShowListingCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WebSeriesShowListingCell.swift; sourceTree = "<group>"; };
52D6A2532C22B93F00145908 /* CategoryListingDM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CategoryListingDM.swift; sourceTree = "<group>"; };
52D6A2562C22C1E300145908 /* WebSeriesShowListingCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = WebSeriesShowListingCell.xib; sourceTree = "<group>"; };
52D774E82BDFBDA4001D87DE /* AuthenticationStringConstant.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AuthenticationStringConstant.swift; sourceTree = "<group>"; };
52D774EA2BDFC0BF001D87DE /* OTPVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OTPVC.swift; sourceTree = "<group>"; };
52D774EC2BDFC13F001D87DE /* OTPVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OTPVM.swift; sourceTree = "<group>"; };
52D774EE2BDFC50D001D87DE /* StringValidations.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringValidations.swift; sourceTree = "<group>"; };
52D774F02BDFC53B001D87DE /* StringSubScript.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringSubScript.swift; sourceTree = "<group>"; };
52DAC6472C21762900E2F85B /* WebSeries.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = WebSeries.storyboard; sourceTree = "<group>"; };
52DAC64D2C21775300E2F85B /* WebSeriesVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = WebSeriesVC.swift; sourceTree = "<group>"; };
52E7E0F62BDF7DD500C86E10 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/AuthenticationSB.strings; sourceTree = "<group>"; };
52E7E0F82BDF7DD900C86E10 /* hi */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = hi; path = hi.lproj/AuthenticationSB.strings; sourceTree = "<group>"; };
52FB2D8E2BDF898F0009B0C7 /* TextFieldPadding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TextFieldPadding.swift; sourceTree = "<group>"; };
@@ -584,6 +604,7 @@
523ED25C2BDA2BC700CFED02 /* WOKA */ = {
isa = PBXGroup;
children = (
52DAC6462C21761700E2F85B /* WebSeries */,
9C834ED92C1C20EC00B29A9C /* WOKA.entitlements */,
523ED26B2BDA2BC900CFED02 /* Info.plist */,
9C9BEEC62BEE1BBF004ECC2F /* CollectionViewCenteredFlowLayout.swift */,
@@ -917,6 +938,55 @@
path = GIF_JSON;
sourceTree = "<group>";
};
52DAC6462C21761700E2F85B /* WebSeries */ = {
isa = PBXGroup;
children = (
52DAC64C2C2176D600E2F85B /* Model */,
52DAC64B2C2176CD00E2F85B /* View */,
52DAC64A2C2176CB00E2F85B /* ViewModel */,
52DAC6492C21767900E2F85B /* Controller */,
52DAC6472C21762900E2F85B /* WebSeries.storyboard */,
);
path = WebSeries;
sourceTree = "<group>";
};
52DAC6492C21767900E2F85B /* Controller */ = {
isa = PBXGroup;
children = (
52DAC64D2C21775300E2F85B /* WebSeriesVC.swift */,
);
path = Controller;
sourceTree = "<group>";
};
52DAC64A2C2176CB00E2F85B /* ViewModel */ = {
isa = PBXGroup;
children = (
52D6A2472C21A3A500145908 /* WebSeriesVM.swift */,
);
path = ViewModel;
sourceTree = "<group>";
};
52DAC64B2C2176CD00E2F85B /* View */ = {
isa = PBXGroup;
children = (
52D6A2492C21B43300145908 /* WebSeriesCell.swift */,
52D6A24A2C21B43300145908 /* WebSeriesCell.xib */,
52D6A24F2C22B58200145908 /* WebSeriesShowListingCell.swift */,
52D6A2562C22C1E300145908 /* WebSeriesShowListingCell.xib */,
);
path = View;
sourceTree = "<group>";
};
52DAC64C2C2176D600E2F85B /* Model */ = {
isa = PBXGroup;
children = (
52D6A2452C21A29800145908 /* ContinueWatchingDM.swift */,
52D6A24D2C22B3AB00145908 /* WebSeriesShowListDM.swift */,
52D6A2532C22B93F00145908 /* CategoryListingDM.swift */,
);
path = Model;
sourceTree = "<group>";
};
52F12C802C04569100AF8139 /* Model */ = {
isa = PBXGroup;
children = (
@@ -1303,6 +1373,8 @@
527AC6FE2C173A5100434FB7 /* SongListCell.xib in Resources */,
523ED26A2BDA2BC900CFED02 /* Base in Resources */,
52C8B05B2BDA5924003B51D0 /* WokaSplashSound.m4a in Resources */,
52D6A24B2C21B43300145908 /* WebSeriesCell.xib in Resources */,
52DAC6482C21762900E2F85B /* WebSeries.storyboard in Resources */,
527AC6F82C171C8F00434FB7 /* BlogsCell.xib in Resources */,
52A981D82C1B0E27000E0BEC /* FavouriteCell.xib in Resources */,
52C1A4E82C05C95D007BAA50 /* Theme.storyboard in Resources */,
@@ -1311,6 +1383,7 @@
9CBE1B422C0F37B300CA6E61 /* DropDownCell.xib in Resources */,
52A3F6A92BECBF2A0000BB0B /* LinkedChildCell.xib in Resources */,
523ED2652BDA2BC700CFED02 /* Base in Resources */,
52D6A2572C22C1E300145908 /* WebSeriesShowListingCell.xib in Resources */,
52BC3BE62C0E0326002FACA6 /* FaqCell.xib in Resources */,
52C6E01C2BE383C000E22D59 /* YourIntrestCell.xib in Resources */,
9C834ED32C1C1F9200B29A9C /* Exo2-SemiBold.ttf in Resources */,
@@ -1402,6 +1475,7 @@
files = (
9C535DC62C00BF2400DA6DCD /* HomeExploreCell.swift in Sources */,
52D774EF2BDFC50D001D87DE /* StringValidations.swift in Sources */,
52D6A2512C22B58200145908 /* WebSeriesShowListingCell.swift in Sources */,
5272FCE32BDFDB05000ECB1D /* UserDetailsRegisterVC.swift in Sources */,
525954102BE8B72900191286 /* FontCustom.swift in Sources */,
5202AAFE2BDF90590043B7BD /* TextFieldImage.swift in Sources */,
@@ -1419,6 +1493,7 @@
52B8D4DB2C04A25E00ED65F3 /* TransitionContext.swift in Sources */,
9C27E1602BDB6ECA00EC1DA9 /* UserDefaultsStruct.swift in Sources */,
52A3F6AD2BECC0340000BB0B /* TypeAlias.swift in Sources */,
52D6A24C2C21B43300145908 /* WebSeriesCell.swift in Sources */,
524C422B2C04781B0016A11C /* ThemeTwoVM.swift in Sources */,
52B8D4DF2C04A25E00ED65F3 /* StatusBar.swift in Sources */,
5259541D2BE8D94400191286 /* QueueHelper.swift in Sources */,
@@ -1430,11 +1505,13 @@
525327D02BFCBC4A00F64283 /* ExploreWokaVC.swift in Sources */,
52C8B0542BDA4BD1003B51D0 /* RoundCorner.swift in Sources */,
522242662BFC74380085C632 /* MyListVC.swift in Sources */,
52DAC64E2C21775300E2F85B /* WebSeriesVC.swift in Sources */,
5259542B2BEA292800191286 /* UserRegPostModel.swift in Sources */,
52C8B0572BDA57DB003B51D0 /* Constant.swift in Sources */,
52CCD7B02C1AF0F80078BD65 /* RadioVC.swift in Sources */,
52AECA802C08BCB6004A7579 /* PlayerVC.swift in Sources */,
5202AB012BDFA7900043B7BD /* EmailValidation.swift in Sources */,
52D6A24E2C22B3AB00145908 /* WebSeriesShowListDM.swift in Sources */,
52B8D4E12C04A25E00ED65F3 /* BasicTransitionAnimator.swift in Sources */,
52BC3BF02C1701F8002FACA6 /* BlogDM.swift in Sources */,
525954192BE8CC3400191286 /* ConstantString.swift in Sources */,
@@ -1483,6 +1560,7 @@
5259541B2BE8D6F900191286 /* NetworkReachibility.swift in Sources */,
52A981CE2C1AFE66000E0BEC /* FavouriteListingDM.swift in Sources */,
527AC6FD2C173A5100434FB7 /* SongListCell.swift in Sources */,
52D6A2542C22B93F00145908 /* CategoryListingDM.swift in Sources */,
9C27E1672BDB706700EC1DA9 /* StoryBoard.swift in Sources */,
52C8B0692BDA6E1E003B51D0 /* LocalizedEnum.swift in Sources */,
525954122BE8C84900191286 /* Toast.swift in Sources */,
@@ -1502,6 +1580,7 @@
52C8B0742BDA7626003B51D0 /* OnBoardVC.swift in Sources */,
5219C2C22C086D9C00A1DF4D /* DataTypeConversion.swift in Sources */,
525953CF2BE8B28F00191286 /* Utilities.swift in Sources */,
52D6A2462C21A29800145908 /* ContinueWatchingDM.swift in Sources */,
9CBCB2A12BE4E50A007D7934 /* TextFieldPassword.swift in Sources */,
52BC3BEC2C16DF9F002FACA6 /* MyOrdersVC.swift in Sources */,
9C56E8482BDBEFAB00E4CA14 /* AssetColor.swift in Sources */,
@@ -1550,6 +1629,7 @@
52B8D4E02C04A25E00ED65F3 /* UIView+Container.swift in Sources */,
9C56E8462BDBEE6400E4CA14 /* EmailVC.swift in Sources */,
522D65622C1ACDA40021E505 /* CommonNwCall.swift in Sources */,
52D6A2482C21A3A500145908 /* WebSeriesVM.swift in Sources */,
525327D92BFCDDF700F64283 /* AuthFuncStartupSoundHandling.swift in Sources */,
52663FFB2BDFB1700001D8CE /* TextFieldShadow.swift in Sources */,
52C6E0212BE3ADE300E22D59 /* GenderEnum.swift in Sources */,

View File

@@ -0,0 +1,21 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "liveaction.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View File

@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -0,0 +1,21 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "MasilaCover.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 324 KiB

View File

@@ -37,5 +37,10 @@ extension K{
static let userNotificationCell = "UserNotificationCell"
static let favouriteCell = "FavouriteCell"
}
struct WebSeries{
static let webSeriesCell = "WebSeriesCell"
static let webSeriesShowListingCell = "WebSeriesShowListingCell"
}
}
}

View File

@@ -16,5 +16,6 @@ extension K{
static let customAlerts = "CustomAlerts"
static let theme = "Theme"
static let sideBarNav = "SideBarNav"
static let webSeries = "WebSeries"
}
}

View File

@@ -55,5 +55,13 @@ extension K{
static let webViewVC = "WebViewVC"
static let myOrdersVC = "MyOrdersVC"
}
/*
Web Series
*/
struct WebSeries{
static let webSeriesVC = "WebSeriesVC"
}
}
}

View File

@@ -12,6 +12,10 @@ class ExploreWokaVC: UIViewController {
@IBOutlet weak var blurView: UIView!
@IBOutlet weak var extraView: UIView!
@IBOutlet weak var customView: UIView!
@IBOutlet weak var wokaFmBtn: UIButton!
@IBOutlet weak var liveTvBtn: UIButton!
@IBOutlet weak var layerView: UIView!
override func viewDidLoad() {
@@ -38,6 +42,24 @@ class ExploreWokaVC: UIViewController {
blurredView.contentView.addSubview(vibrancyView)
}
@IBAction func btnTapped(_ sender: UIButton) {
switch sender{
case wokaFmBtn:
self.dismiss(animated: true) {
// let sb = UIStoryboard(name: K.StoryBoard.theme, bundle: nil)
// let vcPush = sb.instantiateViewController(withIdentifier: K.StoryBoardID.Theme.radioVC) as! RadioVC
// vcPush.modalPresentationStyle = .overCurrentContext
// vcPush.modalTransitionStyle = .crossDissolve
// self.present(vcPush, animated: true)
}
case liveTvBtn:
self.dismiss(animated: true)
default:
break
}
}
@IBAction func closeTapped(_ sender: UIButton) {
self.dismiss(animated: true)
}

View File

@@ -606,6 +606,9 @@
<state key="normal" title="WOKA FM" image="WokaFmIcon">
<color key="titleColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</state>
<connections>
<action selector="btnTapped:" destination="wHe-qy-JF8" eventType="touchUpInside" id="aqy-Ob-ieO"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" red="0.78431372549019607" green="0.70588235294117641" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
@@ -628,6 +631,9 @@
<state key="normal" title="LIVE TV" image="LiveTvIcon">
<color key="titleColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</state>
<connections>
<action selector="btnTapped:" destination="wHe-qy-JF8" eventType="touchUpInside" id="PWm-Wo-tFp"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" red="0.0" green="0.63529411764705879" blue="0.87058823529411766" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
@@ -826,6 +832,8 @@
<outlet property="blurView" destination="bkq-AU-CNT" id="0nM-J2-yrv"/>
<outlet property="customView" destination="DNc-fQ-fy8" id="zKU-Vc-wBz"/>
<outlet property="extraView" destination="lxy-WU-CSd" id="ba7-wu-ZGj"/>
<outlet property="liveTvBtn" destination="pfM-e9-xeS" id="evM-rB-9H9"/>
<outlet property="wokaFmBtn" destination="nOR-gr-8Ab" id="NGX-cj-tAW"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="HdD-nD-JtP" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
@@ -1214,7 +1222,7 @@
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
<systemColor name="systemGreenColor">
<color red="0.20392156862745098" green="0.7803921568627451" blue="0.34901960784313724" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.20392156859999999" green="0.78039215689999997" blue="0.34901960780000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
</resources>
</document>

View File

@@ -98,7 +98,7 @@ struct FavouriteListingDM: Codable {
var markAsFavourite, isLiked: Bool?
var likesCount : Int?
let viewsCount, bookmarkCount: Int?
let bookmarkCategoryIDS: String?
var bookmarkCategoryIDS: String?
enum CodingKeys: String, CodingKey {
case id, title, description

View File

@@ -81,10 +81,21 @@ class MyListVM{
Taking out the hindi series , 1-> English , 18-> Hindi
And the saving it to hindi series
*/
webSeriesHindi = hindiData.compactMap { $0 }.filter { $0.bookmarkCategoryIDS == "18" }
webSeriesHindi = hindiData.compactMap { $0 }.filter { ($0.bookmarkCategoryIDS?.components(separatedBy: ",").first == "18" || $0.bookmarkCategoryIDS?.components(separatedBy: ",").last == "18") }
// Deleting the hindi series from main (those with category ID "18")
hindiData.removeAll { $0.bookmarkCategoryIDS == "18" }
for (index, element) in favListingData!.showData!.enumerated() {
let bookMarkCatID = element.bookmarkCategoryIDS?.components(separatedBy: ",")
if bookMarkCatID?.count == 2{
hindiData[index-1].bookmarkCategoryIDS = "1"
}else{
hindiData.remove(at: index-1)
}
}
// hindiData.removeAll { $0.bookmarkCategoryIDS?.components(separatedBy: ",").count == 1 ? $0.bookmarkCategoryIDS? }
// Updating the showData with the filtered list
favListingData?.showData = hindiData

View File

@@ -79,6 +79,12 @@ struct APIEndPoints {
static let favourite_add = makeURL(path: "favourite_add")
}
struct WebSeries{
static let continue_watching = makeURL(path: "continue_watching")
static let watch_show_listing = makeURL(path: "watch_show_listing")
static let category_listing = makeURL(path: "category_listing")
}
// Other endpoint categories...
struct Links {
static let privacyPolicy = "https://www.wokaland.com/privacy-policy/"

View File

@@ -58,7 +58,7 @@ class NetworkManager{
switch response.result {
case .success(let value):
/*
if Sucess == 4 menas user has logined in other device
if Sucess == 4 menas user has logined in other device, logout that user by saying session timeout
*/
if value.success == 4{
if let topController = UIApplication.topViewController() {
@@ -161,7 +161,6 @@ final class AlamofireLogger: EventMonitor {
}
extension UIApplication {
class func topViewController(_ base: UIViewController? = UIApplication.shared.mainKeyWindow?.rootViewController) -> UIViewController? {
if let nav = base as? UINavigationController {

View File

@@ -19,7 +19,7 @@ class TabBarVC: UITabBarController {
self.delegate = self
self.title = ""
customizeTabBarItemFont()
updateText()
self.setupTabBarUI()
self.addCustomTabBarView()
NotificationCenter.default.addObserver(self, selector: #selector(languageDidChange), name: .languageDidChange, object: nil)

View File

@@ -254,26 +254,36 @@
<constraint firstAttribute="width" secondItem="lRy-nX-Xia" secondAttribute="height" multiplier="1:1" id="l2d-W3-pqP"/>
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" distribution="fillProportionally" spacing="1" translatesAutoresizingMaskIntoConstraints="NO" id="Sp0-yh-bdj" userLabel="WebSeries">
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="GGC-rX-Pyw">
<rect key="frame" x="10" y="77.333333333333314" width="95" height="95"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="WebSeries" translatesAutoresizingMaskIntoConstraints="NO" id="LGm-UX-yVh">
<rect key="frame" x="0.0" y="0.0" width="95" height="79"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="WEB SERIES" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zmu-oJ-DFc" customClass="LocalisedElementsLabel" customModule="WOKA" customModuleProvider="target">
<rect key="frame" x="0.0" y="80" width="95" height="15"/>
<constraints>
<constraint firstAttribute="height" constant="15" id="tmo-ie-b2U"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" distribution="fillProportionally" spacing="1" translatesAutoresizingMaskIntoConstraints="NO" id="Sp0-yh-bdj" userLabel="WebSeries">
<rect key="frame" x="0.0" y="0.0" width="95" height="95"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="WebSeries" translatesAutoresizingMaskIntoConstraints="NO" id="LGm-UX-yVh">
<rect key="frame" x="0.0" y="0.0" width="95" height="79"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="WEB SERIES" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zmu-oJ-DFc" customClass="LocalisedElementsLabel" customModule="WOKA" customModuleProvider="target">
<rect key="frame" x="0.0" y="80" width="95" height="15"/>
<constraints>
<constraint firstAttribute="height" constant="15" id="tmo-ie-b2U"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
</subviews>
</stackView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" secondItem="Sp0-yh-bdj" secondAttribute="height" multiplier="1:1" id="w9u-Jp-Y4L"/>
<constraint firstAttribute="bottom" secondItem="Sp0-yh-bdj" secondAttribute="bottom" id="T7h-FQ-qbV"/>
<constraint firstItem="Sp0-yh-bdj" firstAttribute="leading" secondItem="GGC-rX-Pyw" secondAttribute="leading" id="d8n-hm-t7J"/>
<constraint firstAttribute="trailing" secondItem="Sp0-yh-bdj" secondAttribute="trailing" id="fUo-ZW-rdm"/>
<constraint firstAttribute="width" secondItem="GGC-rX-Pyw" secondAttribute="height" multiplier="1:1" id="mIF-bW-d9N"/>
<constraint firstItem="Sp0-yh-bdj" firstAttribute="top" secondItem="GGC-rX-Pyw" secondAttribute="top" id="wcv-Pf-dXx"/>
</constraints>
</stackView>
</view>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" distribution="fillProportionally" spacing="1" translatesAutoresizingMaskIntoConstraints="NO" id="r88-JP-phS" userLabel="Games">
<rect key="frame" x="298" y="134.99999999999994" width="95" height="95"/>
<subviews>
@@ -338,17 +348,16 @@
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="r88-JP-phS" firstAttribute="height" secondItem="ppi-HI-rj1" secondAttribute="height" multiplier="0.208333" id="0sg-36-CK8"/>
<constraint firstItem="Sp0-yh-bdj" firstAttribute="centerY" secondItem="lRy-nX-Xia" secondAttribute="centerY" constant="25" id="3t3-nm-6LF"/>
<constraint firstItem="Ehe-Th-asW" firstAttribute="baseline" secondItem="lRy-nX-Xia" secondAttribute="firstBaseline" constant="40" id="6HI-BQ-pxx"/>
<constraint firstItem="r88-JP-phS" firstAttribute="top" secondItem="Ehe-Th-asW" secondAttribute="bottom" constant="40" id="6wM-Ss-Lui"/>
<constraint firstItem="GGC-rX-Pyw" firstAttribute="leading" secondItem="ppi-HI-rj1" secondAttribute="leading" constant="10" id="Go0-Ui-etR"/>
<constraint firstItem="JHO-R6-WGZ" firstAttribute="centerX" secondItem="lRy-nX-Xia" secondAttribute="centerX" constant="30" id="KjY-SZ-e5Z"/>
<constraint firstItem="r88-JP-phS" firstAttribute="centerX" secondItem="Ehe-Th-asW" secondAttribute="centerX" constant="10" id="M0G-TU-M2T"/>
<constraint firstItem="GGC-rX-Pyw" firstAttribute="centerY" secondItem="lRy-nX-Xia" secondAttribute="centerY" constant="25" id="NmB-T5-Lvq"/>
<constraint firstItem="9fz-vc-Ufb" firstAttribute="height" secondItem="ppi-HI-rj1" secondAttribute="height" multiplier="0.208333" id="RjE-7v-VJf"/>
<constraint firstItem="lRy-nX-Xia" firstAttribute="height" secondItem="ppi-HI-rj1" secondAttribute="height" multiplier="0.208333" id="Slx-Jj-1Nl"/>
<constraint firstItem="Sp0-yh-bdj" firstAttribute="height" secondItem="ppi-HI-rj1" secondAttribute="height" multiplier="0.208333" id="TkC-nc-gwE"/>
<constraint firstItem="lRy-nX-Xia" firstAttribute="centerX" secondItem="ppi-HI-rj1" secondAttribute="centerX" id="ZMq-Za-1eg"/>
<constraint firstItem="Ehe-Th-asW" firstAttribute="height" secondItem="ppi-HI-rj1" secondAttribute="height" multiplier="0.208333" id="bYM-Cl-mWm"/>
<constraint firstItem="Sp0-yh-bdj" firstAttribute="leading" secondItem="ppi-HI-rj1" secondAttribute="leading" constant="10" id="fen-AW-Pgf"/>
<constraint firstAttribute="trailing" secondItem="Ehe-Th-asW" secondAttribute="trailing" constant="10" id="h6R-gj-t8n"/>
<constraint firstItem="Ehe-Th-asW" firstAttribute="top" secondItem="ppi-HI-rj1" secondAttribute="top" id="rPo-rh-Nry"/>
<constraint firstItem="JHO-R6-WGZ" firstAttribute="firstBaseline" secondItem="r88-JP-phS" secondAttribute="baseline" constant="-25" id="snK-f5-Dqo"/>
@@ -415,6 +424,7 @@
<constraint firstItem="kzE-UE-7KK" firstAttribute="height" secondItem="UEh-jl-IQp" secondAttribute="height" multiplier="0.212054" id="s5Y-TI-1sZ"/>
<constraint firstItem="ppi-HI-rj1" firstAttribute="height" secondItem="UEh-jl-IQp" secondAttribute="height" multiplier="0.535714" id="sLx-ty-T4s"/>
<constraint firstItem="sf9-me-n7i" firstAttribute="centerX" secondItem="vdl-cu-G32" secondAttribute="centerX" id="vZE-xF-UKh"/>
<constraint firstItem="GGC-rX-Pyw" firstAttribute="height" secondItem="UEh-jl-IQp" secondAttribute="height" multiplier="0.111502" id="wVS-AA-kvz"/>
</constraints>
</view>
<tabBarItem key="tabBarItem" title="HOME" image="HomeIcon" selectedImage="HomeIcon" id="4Hm-tg-Heb"/>
@@ -432,7 +442,7 @@
<outlet property="moreStack" destination="LYo-Uy-0nM" id="Ea6-hD-ZEj"/>
<outlet property="nameLabel" destination="tQN-s8-9SK" id="GIQ-nv-8rM"/>
<outlet property="notificationBtnn" destination="b3F-hf-9c8" id="elI-0K-6uE"/>
<outlet property="webSeriesView" destination="Sp0-yh-bdj" id="HMn-cX-z6Y"/>
<outlet property="webSeriesView" destination="GGC-rX-Pyw" id="ZJt-XZ-15X"/>
<outlet property="welcomeLabel" destination="dnl-w0-q5K" id="ePX-F9-APX"/>
<outletCollection property="star" destination="XTn-ID-1Yb" collectionClass="NSMutableArray" id="8Fh-RB-UOY"/>
<outletCollection property="star" destination="s5k-HV-Zkc" collectionClass="NSMutableArray" id="icE-65-uve"/>
@@ -589,7 +599,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="none" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="-1" estimatedSectionHeaderHeight="-1" sectionFooterHeight="-1" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="4Jz-rO-ToO">
<rect key="frame" x="0.0" y="59" width="393" height="759"/>
<rect key="frame" x="0.0" y="74" width="393" height="744"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</tableView>
</subviews>
@@ -599,7 +609,7 @@
<constraint firstItem="4Jz-rO-ToO" firstAttribute="leading" secondItem="HwS-aW-IIl" secondAttribute="leading" id="Pwc-fY-ijS"/>
<constraint firstItem="HwS-aW-IIl" firstAttribute="trailing" secondItem="4Jz-rO-ToO" secondAttribute="trailing" id="pPA-fS-veG"/>
<constraint firstItem="HwS-aW-IIl" firstAttribute="bottom" secondItem="4Jz-rO-ToO" secondAttribute="bottom" id="x2e-Ns-hm9"/>
<constraint firstItem="4Jz-rO-ToO" firstAttribute="top" secondItem="HwS-aW-IIl" secondAttribute="top" id="zIS-dJ-FOj"/>
<constraint firstItem="4Jz-rO-ToO" firstAttribute="top" secondItem="HwS-aW-IIl" secondAttribute="top" constant="15" id="zIS-dJ-FOj"/>
</constraints>
</view>
<connections>
@@ -625,23 +635,50 @@
<constraint firstAttribute="height" constant="220" id="ezY-uu-Vnb"/>
</constraints>
</view>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="4qI-5q-8TH">
<rect key="frame" x="338" y="69" width="40" height="40"/>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="LiveHindi" translatesAutoresizingMaskIntoConstraints="NO" id="03W-c9-Rk6">
<rect key="frame" x="0.0" y="134" width="54.333333333333336" height="25"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="width" secondItem="4qI-5q-8TH" secondAttribute="height" multiplier="1:1" id="HP0-u8-WP8"/>
<constraint firstAttribute="height" constant="40" id="pa1-no-jcD"/>
<constraint firstAttribute="width" secondItem="03W-c9-Rk6" secondAttribute="height" multiplier="13:6" id="1ok-RR-hUo"/>
<constraint firstAttribute="height" constant="25" id="GDh-JH-6kY"/>
</constraints>
<fontDescription key="fontDescription" name="HelveticaNeue" family="Helvetica Neue" pointSize="15"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="SideMenu"/>
<connections>
<action selector="barButtonTapped:" destination="VXi-XB-hOy" eventType="touchUpInside" id="WFm-XG-XFm"/>
<action selector="sideBarBtnTapped:" destination="3jm-7v-5GP" eventType="touchUpInside" id="UpJ-Ec-H82"/>
</connections>
</button>
</imageView>
<stackView opaque="NO" contentMode="scaleToFill" spacing="10" translatesAutoresizingMaskIntoConstraints="NO" id="dUF-uY-OBL">
<rect key="frame" x="348" y="69" width="40" height="40"/>
<subviews>
<button hidden="YES" opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="tl8-VA-AjQ">
<rect key="frame" x="0.0" y="0.0" width="40" height="40"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="DyV-uZ-VWU"/>
<constraint firstAttribute="width" secondItem="tl8-VA-AjQ" secondAttribute="height" multiplier="1:1" id="yLA-fY-vto"/>
</constraints>
<fontDescription key="fontDescription" name="HelveticaNeue" family="Helvetica Neue" pointSize="15"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="Notification"/>
<connections>
<action selector="notificationBtnTapped:" destination="VXi-XB-hOy" eventType="touchUpInside" id="XCL-Rm-Odz"/>
<action selector="notificationBtnTapped:" destination="3jm-7v-5GP" eventType="touchUpInside" id="mfO-0o-Q5d"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="4qI-5q-8TH">
<rect key="frame" x="0.0" y="0.0" width="40" height="40"/>
<constraints>
<constraint firstAttribute="width" secondItem="4qI-5q-8TH" secondAttribute="height" multiplier="1:1" id="HP0-u8-WP8"/>
<constraint firstAttribute="height" constant="40" id="pa1-no-jcD"/>
</constraints>
<fontDescription key="fontDescription" name="HelveticaNeue" family="Helvetica Neue" pointSize="15"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="SideMenu"/>
<connections>
<action selector="barButtonTapped:" destination="VXi-XB-hOy" eventType="touchUpInside" id="WFm-XG-XFm"/>
<action selector="sideBarBtnTapped:" destination="3jm-7v-5GP" eventType="touchUpInside" id="UpJ-Ec-H82"/>
</connections>
</button>
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" spacing="10" translatesAutoresizingMaskIntoConstraints="NO" id="wHk-XC-Cqq" userLabel="Avatar Stack">
<rect key="frame" x="10" y="64" width="235" height="50"/>
<rect key="frame" x="10" y="64" width="318" height="50"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="Boy" translatesAutoresizingMaskIntoConstraints="NO" id="4xI-oX-ffb">
<rect key="frame" x="0.0" y="0.0" width="50" height="50"/>
@@ -651,7 +688,7 @@
</constraints>
</imageView>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="top" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="LZa-k2-Fa1">
<rect key="frame" x="60" y="0.0" width="175" height="50"/>
<rect key="frame" x="60" y="0.0" width="258" height="50"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" spacing="3" translatesAutoresizingMaskIntoConstraints="NO" id="Eb9-At-Mtt">
<rect key="frame" x="0.0" y="0.0" width="53.333333333333336" height="25.666666666666668"/>
@@ -733,17 +770,20 @@
<constraint firstAttribute="bottom" secondItem="wIw-DO-ba0" secondAttribute="bottom" id="8aT-sg-dlZ"/>
<constraint firstItem="wIw-DO-ba0" firstAttribute="top" secondItem="Ksi-1c-xBG" secondAttribute="bottom" constant="5" id="9iK-1y-iUL"/>
<constraint firstItem="wIw-DO-ba0" firstAttribute="trailing" secondItem="QRd-bR-MwE" secondAttribute="trailing" id="B2f-vS-BlM"/>
<constraint firstItem="03W-c9-Rk6" firstAttribute="top" secondItem="Ksi-1c-xBG" secondAttribute="top" id="Lbz-Fr-iIx"/>
<constraint firstAttribute="bottom" secondItem="1fD-0F-KMn" secondAttribute="bottom" constant="-70" id="Prn-39-0xD"/>
<constraint firstItem="dUF-uY-OBL" firstAttribute="centerY" secondItem="wHk-XC-Cqq" secondAttribute="centerY" id="VXh-QC-K3B"/>
<constraint firstItem="wHk-XC-Cqq" firstAttribute="leading" secondItem="QRd-bR-MwE" secondAttribute="leading" constant="10" id="YGq-MK-aVC"/>
<constraint firstItem="wHk-XC-Cqq" firstAttribute="top" secondItem="QRd-bR-MwE" secondAttribute="top" constant="5" id="aC0-db-DaE"/>
<constraint firstItem="1fD-0F-KMn" firstAttribute="top" secondItem="wIw-DO-ba0" secondAttribute="top" constant="100" id="f0v-wy-myo"/>
<constraint firstItem="dUF-uY-OBL" firstAttribute="leading" secondItem="wHk-XC-Cqq" secondAttribute="trailing" constant="20" id="gKp-S3-FKR"/>
<constraint firstItem="wIw-DO-ba0" firstAttribute="leading" secondItem="QRd-bR-MwE" secondAttribute="leading" id="icN-WK-7ux"/>
<constraint firstItem="1fD-0F-KMn" firstAttribute="trailing" secondItem="QRd-bR-MwE" secondAttribute="trailing" id="isc-ka-Z4S"/>
<constraint firstItem="QRd-bR-MwE" firstAttribute="trailing" secondItem="Ksi-1c-xBG" secondAttribute="trailing" id="l1S-Jm-gVK"/>
<constraint firstItem="Ksi-1c-xBG" firstAttribute="top" secondItem="wHk-XC-Cqq" secondAttribute="bottom" constant="20" id="nBa-4R-qSd"/>
<constraint firstItem="4qI-5q-8TH" firstAttribute="centerY" secondItem="wHk-XC-Cqq" secondAttribute="centerY" id="rWN-WN-Oxo"/>
<constraint firstItem="QRd-bR-MwE" firstAttribute="trailing" secondItem="dUF-uY-OBL" secondAttribute="trailing" constant="5" id="pz9-PS-CM6"/>
<constraint firstItem="03W-c9-Rk6" firstAttribute="leading" secondItem="Ksi-1c-xBG" secondAttribute="leading" id="rxk-EA-GIQ"/>
<constraint firstItem="Ksi-1c-xBG" firstAttribute="leading" secondItem="QRd-bR-MwE" secondAttribute="leading" id="suG-9y-lQs"/>
<constraint firstItem="QRd-bR-MwE" firstAttribute="trailing" secondItem="4qI-5q-8TH" secondAttribute="trailing" constant="15" id="wHe-KW-pfN"/>
</constraints>
</view>
<connections>
@@ -751,6 +791,7 @@
<outlet property="collectionView" destination="4rq-xX-XRh" id="Z66-JF-bp2"/>
<outlet property="liveTvView" destination="Ksi-1c-xBG" id="xcg-na-dB1"/>
<outlet property="nameLabel" destination="Qn2-Bb-Ud6" id="t3V-Kr-Tkh"/>
<outlet property="notificationBtn" destination="tl8-VA-AjQ" id="p7t-q6-5US"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="AKa-H1-a6U" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
@@ -970,6 +1011,7 @@
<image name="HomeGrassDay" width="570.66668701171875" height="641.33331298828125"/>
<image name="HomeIcon" width="26.666666030883789" height="26.666666030883789"/>
<image name="Karaoke" width="172" height="137.33332824707031"/>
<image name="LiveHindi" width="326.66665649414062" height="176.66667175292969"/>
<image name="LiveTV" width="172" height="122.66666412353516"/>
<image name="LiveTVBaloon" width="135" height="135"/>
<image name="LiveTVBorder" width="79.333335876464844" height="67"/>
@@ -989,10 +1031,10 @@
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
<systemColor name="systemBrownColor">
<color red="0.63529411764705879" green="0.51764705882352946" blue="0.36862745098039218" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.63529411759999999" green="0.51764705879999995" blue="0.36862745099999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
<systemColor name="systemGreenColor">
<color red="0.20392156862745098" green="0.7803921568627451" blue="0.34901960784313724" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color red="0.20392156859999999" green="0.78039215689999997" blue="0.34901960780000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</systemColor>
</resources>
</document>

View File

@@ -32,6 +32,7 @@ class CommonNwCall{
case 1:
Utilities.dismissProgressHUD()
guard let data = data.data else{return}
self.userNotification.removeAll()
self.userNotification.append(contentsOf: data)
//Fetched Blogs
completion(true)

View File

@@ -22,7 +22,7 @@ class ThemeOneVC: UIViewController {
@IBOutlet weak var notificationBtnn: UIButton!
@IBOutlet weak var avatarImage: UIImageView!
@IBOutlet weak var webSeriesView: UIStackView!
@IBOutlet weak var webSeriesView: UIView!
@IBOutlet var star: [UIImageView]!
@IBOutlet weak var moonImage: UIImageView!
@IBOutlet weak var moreStack: UIStackView!

View File

@@ -14,6 +14,7 @@ class ThemeTwoVC: UIViewController {
@IBOutlet weak var liveTvView: UIView!
@IBOutlet weak var nameLabel: UILabel!
@IBOutlet weak var avatarImage: UIImageView!
@IBOutlet weak var notificationBtn: UIButton!
var vm = ThemeTwoVM()
@@ -27,11 +28,12 @@ class ThemeTwoVC: UIViewController {
vm.initView()
liveTvView.addTapGesture { [weak self] in
guard let self else{return}
delegate?.didPressSwitchButton(from: self)
self.vm.playLiveTV()
}
}
override func viewDidLayoutSubviews() {
super.viewDidLayoutSubviews()
vm.setData()
}
@@ -39,6 +41,15 @@ class ThemeTwoVC: UIViewController {
self.sideMenuController?.revealMenu()
}
@IBAction func notificationBtnTapped(_ sender: UIButton) {
CommonNwCall.shareInstance.getUserNotification(vc: self) { isDone in
if isDone{
let sb = UIStoryboard(name: K.StoryBoard.theme, bundle: nil)
let vcPush = sb.instantiateViewController(withIdentifier: K.StoryBoardID.Home.userNotificationVC) as! UserNotificationVC
self.navigationController?.pushViewController(vcPush, animated: true)
}
}
}
}
// MARK: - CollectionView DataSource Delegate
@@ -56,6 +67,20 @@ extension ThemeTwoVC : CollectionViewSRC{
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
print(indexPath.row)
switch indexPath.row{
case 0:
let sb = UIStoryboard(name: K.StoryBoard.theme, bundle: nil)
let vcPush = sb.instantiateViewController(withIdentifier: K.StoryBoardID.Theme.radioVC) as! RadioVC
vcPush.modalPresentationStyle = .overCurrentContext
vcPush.modalTransitionStyle = .crossDissolve
self.present(vcPush, animated: true)
case 1:
vm.playLiveTV()
case 2:
break
default:
break
}
}
}

View File

@@ -24,8 +24,6 @@ class UserNotificationVC: UIViewController {
navigationController?.navigationBar.setBackgroundImage(UIImage(), for: .default)
navigationController?.navigationBar.shadowImage = UIImage()
self.navigationController?.setColor(color: .white)
//Adding pull to Refresh
refreshControl.attributedTitle = NSAttributedString(string: "Refreshing...",attributes: [.foregroundColor: UIColor.white])
refreshControl.tintColor = .white
@@ -47,11 +45,15 @@ class UserNotificationVC: UIViewController {
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
navigationController?.setNavigationBarHidden(false, animated: animated)
self.navigationController?.setColor(color: .white)
}
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
navigationController?.setNavigationBarHidden(true, animated: animated)
self.navigationController?.setNavigationBarHidden(true, animated: animated)
// Customize the navigation bar's appearance
self.navigationController?.setColor(color: .black)
}

View File

@@ -15,10 +15,10 @@ class HomeExploreCell: UICollectionViewCell {
override func awakeFromNib() {
super.awakeFromNib()
self.addTapGesture { [weak self] in
guard let self else{return}
btnTap()
}
// self.addTapGesture { [weak self] in
// guard let self else{return}
// btnTap()
// }
}

View File

@@ -117,8 +117,9 @@ class ThemeOneVM{
//WebSeries
vc.webSeriesView.addTapGesture {
ViewButtonAnimation.sharedInstance.btnTapped(in: self.vc, view: self.vc.webSeriesView) {
// self.vc.delegate?.didPressSwitchButton(from: self.vc)
let sb = UIStoryboard(name: K.StoryBoard.webSeries, bundle: nil)
let vcPush = sb.instantiateViewController(withIdentifier: K.StoryBoardID.WebSeries.webSeriesVC) as! WebSeriesVC
self.vc.navigationController?.pushViewController(vcPush, animated: true)
}
}

View File

@@ -6,16 +6,21 @@
//
import UIKit
import AVFoundation
import JWPlayerKit
struct Theme2Struct{
let imageName : String
let text : String
}
class ThemeTwoVM{
weak var vc : ThemeTwoVC!
var liveStreamURL = "https://d3volyx7jx7oal.cloudfront.net/master.m3u8"
var avPlayer : AVPlayer!
var playerLayer: AVPlayerLayer!
// var cellData = ["WokaFMT2", "LiveTVT2", "WebSeriesT2", "GamesT2", "AudioBooksT2", "KaraokeT2", "ShopT2"]
var cellData = [Theme2Struct(imageName: "WokaFMT2", text: "WOKA FM"),
Theme2Struct(imageName: "LiveTVT2", text: "LIVE TV"),
Theme2Struct(imageName: "WebSeriesT2", text: "WEB SERIES"),
@@ -27,9 +32,131 @@ class ThemeTwoVM{
func initView(){
setupCell()
NotificationCenter.default.addObserver(self, selector: #selector(self.reloadTheme), name: NSNotification.Name(rawValue: K.NotificationCenterReloads.reloadTheme), object: nil)
setupAvPlayer()
setUserData()
}
func playLiveTV(){
Utilities.startProgressHUD(msg: "Loading...")
print("tapped")
let vc = self.vc.storyboard?.instantiateViewController(identifier: "PlayerVC") as! PlayerVC
DispatchQueue.main.async {
do {
// Create a JWMediaTrack with the thumbnails .vtt file
// let thumbnailTrack = try JWThumbnailTrackBuilder()
// .file(URL(string:"https://content.jwplatform.com/videos/Agy4RIje-Ysj2G4DQ.mp4")!)
// .build()
// Create a JWPlayerItem
let item = try JWPlayerItemBuilder()
.file(URL(string: self.liveStreamURL)!)
.title("Testing Title")
// .posterImage(URL(string: "https://img.freepik.com/free-photo/painting-mountain-lake-with-mountain-background_188544-9126.jpg")!)
// .mediaTracks([thumbnailTrack])
.build()
// Create a config, and give it the item as a playlist.
let config = try JWPlayerConfigurationBuilder()
.playlist(items: [item])
.autostart(true)
// .preload(.auto)
// .repeatContent(true)
.build()
vc.config = config
vc.dismissTapped = self.tapped
vc.modalPresentationStyle = .overFullScreen
Utilities.dismissProgressHUD()
self.vc.present(vc, animated: false) {
self.stopLiveStream()
vc.transitionToFullScreen(animated: true) {
print("FullScreen")
}
// vc.setDeviceOrientation(orientation: .landscapeRight)
}
// Utilities.dismissProgressHUD()
// self.vc.navigationController?.pushViewController(vc, animated: true)
// self.stopLiveStream()
}
catch {
// Handle Error
}
}
}
func tapped(){
Timer.scheduledTimer(withTimeInterval: 0.2, repeats: false) { _ in
self.startLiveStream()
self.vc.liveTvView.layoutIfNeeded()
}
print("Sadasd")
}
func startLiveStream(){
avPlayer.play()
avPlayer.volume = 0
}
func stopLiveStream(){
avPlayer.pause()
}
func setUserData(){
guard let data = AuthFunc.shareInstance.userData else{return}
//set the first name as the name
/*
Check User Type,
Dont show username if the user type is guest
*/
switch data.userType{
case "1": // child
vc.nameLabel.text = data.fullname?.components(separatedBy: " ").first
vc.notificationBtn.isHidden = false
case "2" : // adult
vc.nameLabel.text = data.fullname?.components(separatedBy: " ").first
vc.notificationBtn.isHidden = false
case "3": // Guest
vc.nameLabel.text = ""
vc.notificationBtn.isHidden = true
break
default:
break
}
if let avatar = data.avtar{
//https://wokaland.com/admin/storage/app/public/uploads/avtar/avatar2.png?d=1716889852
vc.avatarImage.imageURL("https://wokaland.com/admin/storage/app/public/uploads/avtar/avatar6.png")
}
}
func setupAvPlayer(){
/*
Av Player Setup
*/
let streamURL = URL(string: liveStreamURL)
// Create AVPlayer with the stream URL
avPlayer = AVPlayer(url: streamURL!)
// avPlayer.isMuted = true
// Create AVPlayerLayer
playerLayer = AVPlayerLayer(player: avPlayer)
playerLayer.videoGravity = .resizeAspectFill // You can set different videoGravity as per your need
playerLayer.frame = self.vc.liveTvView.bounds
self.vc.liveTvView.layer.addSublayer(playerLayer)
avPlayer.play()
avPlayer.volume = 0
}
func setData(){
playerLayer.frame = self.vc.liveTvView.bounds
guard let data = AuthFunc.shareInstance.userData else{return}
//set the first name as the name
/*
@@ -48,11 +175,6 @@ class ThemeTwoVM{
break
}
if let avatar = data.avtar{
//https://wokaland.com/admin/storage/app/public/uploads/avtar/avatar2.png?d=1716889852
vc.avatarImage.imageURL("https://i.pinimg.com/280x280_RS/da/0b/bd/da0bbdb22d191272f32fa2c7c7c8e5c2.jpg", color: .white)
}
}
// MARK: - Notification Center Handlers

View File

@@ -0,0 +1,263 @@
//
// WebSeriesVC.swift
// WOKA
//
// Created by MacBook Pro on 18/06/24.
//
import UIKit
class WebSeriesVC: UIViewController {
@IBOutlet weak var headerView: UIView!
@IBOutlet weak var topLabel: UILabel!
@IBOutlet weak var scrollView: UIScrollView!
@IBOutlet weak var headerViewTopConstraint: NSLayoutConstraint!
@IBOutlet weak var languageLabel: UILabel!
@IBOutlet weak var languageStack: UIStackView!
@IBOutlet weak var expandBtn: UIButton!
@IBOutlet weak var headerHeight: NSLayoutConstraint!
@IBOutlet weak var continueWatchingCV: UICollectionView!
@IBOutlet weak var showListingTableView: UITableView!
@IBOutlet weak var tableHeight: NSLayoutConstraint!
var vm = WebSeriesVM()
override func viewDidLoad() {
super.viewDidLoad()
vm.vc = self
scrollView.delegate = self
vm.initView()
navigationController?.navigationBar.setBackgroundImage(UIImage(), for: .default)
navigationController?.navigationBar.shadowImage = UIImage()
}
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
navigationController?.setNavigationBarHidden(false, animated: animated)
self.navigationController?.setColor(color: .white)
}
override func viewWillDisappear(_ animated: Bool) {
super.viewWillDisappear(animated)
self.navigationController?.setNavigationBarHidden(true, animated: animated)
}
override func viewDidDisappear(_ animated: Bool) {
super.viewDidDisappear(animated)
// Customize the navigation bar's appearance
self.navigationController?.setColor(color: .black)
}
// MARK: - Tap Handler
@IBAction func expandLanguageTapped(_ sender: UIButton) {
vm.dropDownModule.show()
self.expandBtn.setImage(UIImage(named: "SupportUpArrow"), for: .normal)
}
}
// MARK: - TableView DataSource , Delegates
extension WebSeriesVC : TableViewSRC{
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return vm.showData.count
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: K.CellIdentifier.WebSeries.webSeriesShowListingCell) as! WebSeriesShowListingCell
let data = vm.showData[indexPath.row]
let categoryID = vm.categoryListingData[vm.dropDownModule.indexForSelectedRow ?? 0].id ?? 0
cell.setData(data: data,selectedCategory: categoryID)
cell.btnTapped = { [self] (type) -> Void in
updateFavLikes(type: type, index: indexPath.row)
}
return cell
}
func updateFavLikes(type : FavCellCLick, index : Int){
let data = vm.showData[index]
let categoryID = vm.categoryListingData[vm.dropDownModule.indexForSelectedRow ?? 0].id ?? 0
switch type {
case .favourite:
guard let isFav = data.markAsFavourite ,let postID = data.id,let postType = data.contentMoreDetails?.first?.postType else{return}
if let categoryIds = data.favouriteCategoryIDS?.rawValue {
let components = categoryIds.components(separatedBy: ",")
if isFav == true && (components.first == categoryID.toString() || components.last == categoryID.toString()){
vm.removeFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
if isDone{
vm.showData[index].markAsFavourite = false
vm.showData[index].favouriteCategoryIDS = ValueWrapper.stringValue("")
showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
K.GVar.reloadMyList = true
}
}
}else{
vm.addFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
if isDone{
vm.showData[index].markAsFavourite = true
vm.showData[index].favouriteCategoryIDS = ValueWrapper.stringValue(categoryID.toString())
showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
K.GVar.reloadMyList = true
}
}
}
return
}
// if isFav == true && data.favouriteCategoryIDS?.intValue == 0{ // means this is fav
// vm.removeFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
// if isDone{
// vm.showData[index].markAsFavourite = false
// showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
// K.GVar.reloadMyList = true
// }
// }
// }else if isFav == true && data.favouriteCategoryIDS?.intValue == categoryID{
// vm.removeFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
// if isDone{
// vm.showData[index].markAsFavourite = false
// showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
// K.GVar.reloadMyList = true
// }
// }
// }else{
// vm.addFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
// if isDone{
// vm.showData[index].markAsFavourite = true
// showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
// K.GVar.reloadMyList = true
// }
// }
// }
// if isFav{
// vm.removeFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
// if isDone{
// vm.showData[index].markAsFavourite = false
// showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
// K.GVar.reloadMyList = true
// }
// }
// }else{
// vm.addFavourite(postID: postID, postType: postType, categoryID: categoryID, index: index) { [unowned self] isDone in
// if isDone{
// vm.showData[index].markAsFavourite = true
// showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
// K.GVar.reloadMyList = true
// }
// }
// }
case .liked:
guard let isLiked = data.isLiked ,let postID = data.id,let postType = data.contentMoreDetails?.first?.postType else{return}
if isLiked{
vm.unlikePost(postID: postID, postType: postType, index: index) { [unowned self] isDone in
if isDone{
vm.showData[index].isLiked = false
vm.showData[index].likesCount! -= 1
showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
}
}
}else{
vm.likePost(postID: postID, postType: postType, index: index){ [unowned self] isDone in
if isDone{
vm.showData[index].isLiked = true
vm.showData[index].likesCount! += 1
showListingTableView.reloadRows(at: [IndexPath(row: index, section: 0)],with: .none)
}
}
}
}
}
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
print(indexPath.row)
}
}
// MARK: - CollectionView Delegate and Data Source
extension WebSeriesVC : CollectionViewSRC{
func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
return vm.continueWatchingData.count
}
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
let cell = collectionView.dequeueReusableCell(withReuseIdentifier: K.CellIdentifier.WebSeries.webSeriesCell, for: indexPath) as! WebSeriesCell
let data = vm.continueWatchingData[indexPath.row]
cell.setData(data: data)
return cell
}
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
print(indexPath.row)
}
}
// MARK: - Collection Flow Layout
extension WebSeriesVC : UICollectionViewDelegateFlowLayout{
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, minimumInteritemSpacingForSectionAt section: Int) -> CGFloat {
return 5
}
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, insetForSectionAt section: Int) -> UIEdgeInsets {
let inset: CGFloat = 10
return UIEdgeInsets(top: 0, left: inset, bottom: 0, right: inset)
}
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, minimumLineSpacingForSectionAt section: Int) -> CGFloat {
return 0 // Space between cells
}
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {
let widthPerItem = collectionView.frame.width - 30 // Adjust to your desired width
return CGSize(width: widthPerItem, height: 230)
}
}
// MARK: - Animating scrollView
extension WebSeriesVC: UIScrollViewDelegate {
func scrollViewDidScroll(_ scrollView: UIScrollView) {
// Get the current vertical offset of the scroll view
let y = scrollView.contentOffset.y
// Define the height range for the header view
let minHeaderHeight: CGFloat = 0.0 // Height at which the header becomes invisible
let maxHeaderHeight: CGFloat = 200.0 // Maximum height when fully visible
// Calculate the new height for the header view based on the scroll position
let newHeaderHeight: CGFloat
if y < 0 {
// When scrolling up beyond the top, ensure the header view is fully expanded
newHeaderHeight = maxHeaderHeight
} else {
// Calculate the new height for the header view, ensuring it doesn't go below the minimum height
newHeaderHeight = max(minHeaderHeight, maxHeaderHeight - y)
}
// Update the header view's height constraint with the new height
headerHeight.constant = newHeaderHeight
// Animate the layout changes to smoothly transition the header height
UIView.animate(withDuration: 0.3) {
self.view.layoutIfNeeded()
}
}
}

View File

@@ -0,0 +1,33 @@
//
// CategoryListingDM.swift
// WOKA
//
// Created by MacBook Pro on 19/06/24.
//
import Foundation
// MARK: - CategoryListingDM
struct CategoryListingDM: Codable {
let result: [ResultData]?
let totalRecords: Int?
enum CodingKeys: String, CodingKey {
case result
case totalRecords = "total_records"
}
// MARK: - Result
struct ResultData: Codable {
let id: Int?
let categoryName: String?
let categoryThumbnail: String?
enum CodingKeys: String, CodingKey {
case id
case categoryName = "category_name"
case categoryThumbnail = "category_thumbnail"
}
}
}

View File

@@ -0,0 +1,109 @@
//
// ContinueWatchingDM.swift
// WOKA
//
// Created by MacBook Pro on 18/06/24.
//
import Foundation
// MARK: - ContinueWatchingDM
struct ContinueWatchingDM: Codable {
let result: [ResultData]?
let totalRecords: Int?
enum CodingKeys: String, CodingKey {
case result
case totalRecords = "total_records"
}
// MARK: - Result
struct ResultData: Codable {
let id, watchShowsMasterID, seasonMasterID, episodeNumber: Int?
let episodeTitle, episodeDescription: String?
let thumbnailPath: String?
let thumbnailImgURL: String?
let episodeURL: String?
let languageMasterID: Int?
let tagsKeyword, episodeDuration, releaseDate: String?
let contentMoreDetails: [ContentMoreDetail]?
let showDataCount: ShowDataCount?
let userVideoView: [UserVideoView]?
let seasonNumber: String?
let markAsFavourite, isLiked: Bool?
let viewsCount, likesCount, bookmarkCount: Int?
enum CodingKeys: String, CodingKey {
case id
case watchShowsMasterID = "watch_shows_master_id"
case seasonMasterID = "season_master_id"
case episodeNumber = "episode_number"
case episodeTitle = "episode_title"
case episodeDescription = "episode_description"
case thumbnailPath = "thumbnail_path"
case thumbnailImgURL = "thumbnail_img_url"
case episodeURL = "episode_url"
case languageMasterID = "language_master_id"
case tagsKeyword = "tags_keyword"
case episodeDuration = "episode_duration"
case releaseDate = "release_date"
case contentMoreDetails = "content_more_details"
case showDataCount = "show_data_count"
case userVideoView = "user_video_view"
case seasonNumber = "season_number"
case markAsFavourite = "mark_as_favourite"
case isLiked = "is_liked"
case viewsCount = "views_count"
case likesCount = "likes_count"
case bookmarkCount = "bookmark_count"
}
}
// MARK: - ContentMoreDetail
struct ContentMoreDetail: Codable {
let id, contentID, postType, languageMasterID: Int?
let title, description, tagsKeywords: String?
let contentHDURL, contentSDURL: String?
enum CodingKeys: String, CodingKey {
case id
case contentID = "content_id"
case postType = "post_type"
case languageMasterID = "language_master_id"
case title, description
case tagsKeywords = "tags_keywords"
case contentHDURL = "content_hd_url"
case contentSDURL = "content_sd_url"
}
}
// MARK: - ShowDataCount
struct ShowDataCount: Codable {
let id, totalSeasons, totalEpisodes: Int?
enum CodingKeys: String, CodingKey {
case id
case totalSeasons = "total_seasons"
case totalEpisodes = "total_episodes"
}
}
// MARK: - UserVideoView
struct UserVideoView: Codable {
let id, userID, postID, postType: Int?
let totalWatchedDuration: String?
let lastWatchedLeft: String?
let categoryID: Int?
enum CodingKeys: String, CodingKey {
case id
case userID = "user_id"
case postID = "post_id"
case postType = "post_type"
case totalWatchedDuration = "total_watched_duration"
case lastWatchedLeft = "last_watched_left"
case categoryID = "category_id"
}
}
}

View File

@@ -0,0 +1,192 @@
//
// WebSeriesShowListDM.swift
// WOKA
//
// Created by MacBook Pro on 19/06/24.
//
import Foundation
// MARK: - WebSeriesShowListDM
struct WebSeriesShowListDM: Codable {
let showData: [ShowDatum]?
let totalRecords: Int?
enum CodingKeys: String, CodingKey {
case showData = "show_data"
case totalRecords = "total_records"
}
// MARK: - ShowDatum
struct ShowDatum: Codable {
let id: Int?
let title, description: String?
let thumbnailPath: String?
let showType: String?
let totalSeasons, totalEpisodes: Int?
let categoryMasterID: String?
let ageRangeMasterID, genderMasterID: String?
let contentMoreDetails: [MoreDetail]?
let seasonData: [SeasonDatum]?
let categoryData: [CategoryDatum]?
let ageRangeData: [AgeRangeDatum]?
let genderData: [GenderDatum]?
var markAsFavourite, isLiked: Bool?
let likedCategoryIDS: LikedCategoryIDS?
var favouriteCategoryIDS: ValueWrapper?
var likesCount : Int?
let viewsCount, bookmarkCount: Int?
enum CodingKeys: String, CodingKey {
case id, title, description
case thumbnailPath = "thumbnail_path"
case showType = "show_type"
case totalSeasons = "total_seasons"
case totalEpisodes = "total_episodes"
case categoryMasterID = "category_master_id"
case ageRangeMasterID = "age_range_master_id"
case genderMasterID = "gender_master_id"
case contentMoreDetails = "content_more_details"
case seasonData = "season_data"
case categoryData = "category_data"
case ageRangeData = "age_range_data"
case genderData = "gender_data"
case markAsFavourite = "mark_as_favourite"
case isLiked = "is_liked"
case likedCategoryIDS = "liked_category_ids"
case favouriteCategoryIDS = "favourite_category_ids"
case viewsCount = "views_count"
case likesCount = "likes_count"
case bookmarkCount = "bookmark_count"
}
}
// MARK: - AgeRangeDatum
struct AgeRangeDatum: Codable {
let id: Int?
let ageRange: String?
enum CodingKeys: String, CodingKey {
case id
case ageRange = "age_range"
}
}
// MARK: - CategoryDatum
struct CategoryDatum: Codable {
let id: Int?
let categoryName: CategoryName?
enum CodingKeys: String, CodingKey {
case id
case categoryName = "category_name"
}
}
enum CategoryName: String, Codable {
case english = "English"
case hindi = "Hindi"
}
// enum CategoryMasterID: String, Codable {
// case the118 = "1,18"
// }
// MARK: - MoreDetail
struct MoreDetail: Codable {
let id, contentID, postType, languageMasterID: Int?
let title, description, tagsKeywords: String?
let trailerHDURL, trailerSDURL: String?
enum CodingKeys: String, CodingKey {
case id
case contentID = "content_id"
case postType = "post_type"
case languageMasterID = "language_master_id"
case title, description
case tagsKeywords = "tags_keywords"
case trailerHDURL = "trailer_hd_url"
case trailerSDURL = "trailer_sd_url"
}
}
// MARK: - GenderDatum
struct GenderDatum: Codable {
let id: Int?
let genderName: String?
enum CodingKeys: String, CodingKey {
case id
case genderName = "gender_name"
}
}
enum LikedCategoryIDS: Codable {
case integer(Int)
case string(String)
case null
init(from decoder: Decoder) throws {
let container = try decoder.singleValueContainer()
if let x = try? container.decode(Int.self) {
self = .integer(x)
return
}
if let x = try? container.decode(String.self) {
self = .string(x)
return
}
if container.decodeNil() {
self = .null
return
}
throw DecodingError.typeMismatch(LikedCategoryIDS.self, DecodingError.Context(codingPath: decoder.codingPath, debugDescription: "Wrong type for LikedCategoryIDS"))
}
func encode(to encoder: Encoder) throws {
var container = encoder.singleValueContainer()
switch self {
case .integer(let x):
try container.encode(x)
case .string(let x):
try container.encode(x)
case .null:
try container.encodeNil()
}
}
}
// MARK: - SeasonDatum
struct SeasonDatum: Codable {
let id, watchShowsMasterID: Int?
let seasonNumber: String?
let noOfEpisodes: Int?
let seasonDescription: String?
let releaseYear: Int?
let seasonTitle: String?
let trailerURL: String?
let thumbnailPath: String?
let thumbnailImgURL: String?
let tagsKeyword, releaseDate: String?
let seasonMoreDetails: [MoreDetail]?
enum CodingKeys: String, CodingKey {
case id
case watchShowsMasterID = "watch_shows_master_id"
case seasonNumber = "season_number"
case noOfEpisodes = "no_of_episodes"
case seasonDescription = "season_description"
case releaseYear = "release_year"
case seasonTitle = "season_title"
case trailerURL = "trailer_url"
case thumbnailPath = "thumbnail_path"
case thumbnailImgURL = "thumbnail_img_url"
case tagsKeyword = "tags_keyword"
case releaseDate = "release_date"
case seasonMoreDetails = "season_more_details"
}
}
}

View File

@@ -0,0 +1,40 @@
//
// WebSeriesCell.swift
// WOKA
//
// Created by MacBook Pro on 18/06/24.
//
import UIKit
class WebSeriesCell: UICollectionViewCell {
@IBOutlet weak var cellImage: UIImageView!
@IBOutlet weak var cellTitle: UILabel!
@IBOutlet weak var episodeSeason: UILabel!
@IBOutlet weak var outerStack: UIStackView!
override func awakeFromNib() {
super.awakeFromNib()
// Initialization code
}
override func layoutSubviews() {
super.layoutSubviews()
outerStack.roundCorner(radius: 10)
cellImage.addBorderView(width: 0.5, color: .white)
}
func setData(data : ContinueWatchingDM.ResultData){
self.cellTitle.text = data.episodeTitle
let seasonNumer = "S" + (data.seasonNumber ?? "0")
let episodeNumer = "E" + (data.episodeNumber?.toString() ?? "0")
self.episodeSeason.text = seasonNumer + "-" + episodeNumer
if let url = data.thumbnailPath{
cellImage.imageURL(url , color: .black)
}
}
}

View File

@@ -0,0 +1,92 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<customFonts key="customFonts">
<array key="Exo2-Bold.ttf">
<string>Exo2-Bold</string>
</array>
</customFonts>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<collectionViewCell opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" id="gTV-IL-0wX" customClass="WebSeriesCell" customModule="WOKA" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="327" height="190"/>
<autoresizingMask key="autoresizingMask"/>
<view key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center">
<rect key="frame" x="0.0" y="0.0" width="327" height="190"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bKX-iS-vWm">
<rect key="frame" x="0.0" y="0.0" width="327" height="190"/>
<subviews>
<stackView opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" axis="vertical" spacing="3" translatesAutoresizingMaskIntoConstraints="NO" id="4fB-cn-lTV">
<rect key="frame" x="5" y="5" width="317" height="180"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Czb-Hj-E6D">
<rect key="frame" x="10" y="64" width="297" height="39"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="5"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</imageView>
<stackView opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" distribution="equalSpacing" alignment="center" translatesAutoresizingMaskIntoConstraints="NO" id="FVh-Am-jwu">
<rect key="frame" x="10" y="106" width="297" height="40"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="80Y-vk-pEH">
<rect key="frame" x="0.0" y="12.333333333333329" width="34" height="15.666666666666664"/>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="hpR-vj-wP1">
<rect key="frame" x="263" y="12.333333333333329" width="34" height="15.666666666666664"/>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<constraints>
<constraint firstAttribute="height" constant="40" id="dUJ-fF-VTm"/>
</constraints>
</stackView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<edgeInsets key="layoutMargins" top="10" left="10" bottom="5" right="10"/>
</stackView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="4fB-cn-lTV" firstAttribute="top" secondItem="bKX-iS-vWm" secondAttribute="top" constant="5" id="7EF-as-cLN"/>
<constraint firstAttribute="bottom" secondItem="4fB-cn-lTV" secondAttribute="bottom" constant="5" id="8hq-wz-1ST"/>
<constraint firstItem="4fB-cn-lTV" firstAttribute="leading" secondItem="bKX-iS-vWm" secondAttribute="leading" constant="5" id="KKf-QZ-Jpg"/>
<constraint firstAttribute="trailing" secondItem="4fB-cn-lTV" secondAttribute="trailing" constant="5" id="L86-bR-O9E"/>
</constraints>
</view>
</subviews>
</view>
<viewLayoutGuide key="safeArea" id="ZTg-uK-7eu"/>
<constraints>
<constraint firstItem="bKX-iS-vWm" firstAttribute="leading" secondItem="gTV-IL-0wX" secondAttribute="leading" id="lAQ-rf-SRw"/>
<constraint firstItem="bKX-iS-vWm" firstAttribute="top" secondItem="gTV-IL-0wX" secondAttribute="top" id="laj-n3-4gv"/>
<constraint firstAttribute="trailing" secondItem="bKX-iS-vWm" secondAttribute="trailing" id="uxB-Rb-dbt"/>
<constraint firstAttribute="bottom" secondItem="bKX-iS-vWm" secondAttribute="bottom" id="xR3-YK-af9"/>
</constraints>
<size key="customSize" width="327" height="190"/>
<connections>
<outlet property="cellImage" destination="Czb-Hj-E6D" id="flX-xf-nns"/>
<outlet property="cellTitle" destination="80Y-vk-pEH" id="c2g-RI-JWI"/>
<outlet property="episodeSeason" destination="hpR-vj-wP1" id="kvh-Hi-6P4"/>
<outlet property="outerStack" destination="4fB-cn-lTV" id="VJu-qK-r9t"/>
</connections>
<point key="canvasLocation" x="350.38167938931298" y="69.014084507042256"/>
</collectionViewCell>
</objects>
</document>

View File

@@ -0,0 +1,90 @@
//
// WebSeriesShowListingCell.swift
// WOKA
//
// Created by MacBook Pro on 19/06/24.
//
import UIKit
class WebSeriesShowListingCell: UITableViewCell {
@IBOutlet weak var showThumbnail: UIImageView!
@IBOutlet weak var showTitle: UILabel!
@IBOutlet weak var totalLikes: UILabel!
@IBOutlet weak var likeBtn: UIButton!
@IBOutlet weak var favBtn: UIButton!
typealias btnTappedBlock = ( _ from : FavCellCLick) -> Void // 0 - plus 1 - minus
var btnTapped : btnTappedBlock!
override func awakeFromNib() {
super.awakeFromNib()
// Initialization code
}
func setData(data : WebSeriesShowListDM.ShowDatum, selectedCategory : Int){
//heart.fill , heart , hand.thumbsup.fill , hand.thumbsup
if AuthFunc.shareInstance.getDefaultLanguage() == .english{
showTitle.text = data.contentMoreDetails?.filter({$0.languageMasterID == 1}).first?.title
}else{
showTitle.text = data.contentMoreDetails?.filter({$0.languageMasterID == 2}).first?.title
}
totalLikes.text = data.likesCount?.toString() ?? "0"
if let url = data.thumbnailPath{
showThumbnail.imageURL(url)
}
if let like = data.isLiked{
switch like{
case true:
likeBtn.setImage(UIImage(systemName: "hand.thumbsup.fill"), for: .normal)
case false:
likeBtn.setImage(UIImage(systemName: "hand.thumbsup"), for: .normal)
}
}
if let favourite = data.markAsFavourite{
if let categoryIds = data.favouriteCategoryIDS?.rawValue { // if string, it means category is selected for multiple language
let components = categoryIds.components(separatedBy: ",")
if favourite == true && (components.first == selectedCategory.toString() || components.last == selectedCategory.toString()){
favBtn.setImage(UIImage(systemName: "heart.fill"), for: .normal)
}else{
favBtn.setImage(UIImage(systemName: "heart"), for: .normal)
}
return
}
if favourite == true && data.favouriteCategoryIDS?.intValue == selectedCategory{
favBtn.setImage(UIImage(systemName: "heart.fill"), for: .normal)
}else{
favBtn.setImage(UIImage(systemName: "heart"), for: .normal)
}
// switch favourite{
// case true:
// favBtn.setImage(UIImage(systemName: "heart.fill"), for: .normal)
// case false:
// favBtn.setImage(UIImage(systemName: "heart"), for: .normal)
//
// }
}
}
@IBAction func btnTapped(_ sender: UIButton) {
switch sender{
case likeBtn:
if btnTapped != nil {
btnTapped( .liked)
}
case favBtn:
if btnTapped != nil {
btnTapped( .favourite)
}
default:
break
}
}
}

View File

@@ -0,0 +1,143 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<customFonts key="customFonts">
<array key="Exo2-Bold.ttf">
<string>Exo2-Bold</string>
</array>
</customFonts>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<tableViewCell contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" reuseIdentifier="WebSeriesShowListingCell" rowHeight="244" id="KGk-i7-Jjw" customClass="WebSeriesShowListingCell" customModule="WOKA" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="517" height="244"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
<rect key="frame" x="0.0" y="0.0" width="517" height="244"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<stackView opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" axis="vertical" spacing="3" translatesAutoresizingMaskIntoConstraints="NO" id="G54-zR-8Xw">
<rect key="frame" x="5" y="5" width="507" height="234"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="EAi-LC-2U0">
<rect key="frame" x="10" y="10" width="487" height="176"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="170" id="yPf-xi-Xrf"/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="5"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</imageView>
<stackView opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" distribution="equalSpacing" alignment="center" translatesAutoresizingMaskIntoConstraints="NO" id="nyj-pp-g9k">
<rect key="frame" x="10" y="189" width="487" height="40"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="m8K-7d-Jib">
<rect key="frame" x="0.0" y="12.333333333333343" width="34" height="15.666666666666664"/>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<stackView opaque="NO" contentMode="scaleToFill" alignment="bottom" spacing="7" translatesAutoresizingMaskIntoConstraints="NO" id="Yeo-E9-Zv6">
<rect key="frame" x="355.33333333333331" y="0.0" width="131.66666666666669" height="40"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" spacing="2" translatesAutoresizingMaskIntoConstraints="NO" id="BXr-9k-Qk2">
<rect key="frame" x="0.0" y="0.0" width="131.66666666666666" height="40"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="1hk-86-QRw">
<rect key="frame" x="0.0" y="0.0" width="40" height="40"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstAttribute="width" secondItem="1hk-86-QRw" secondAttribute="height" multiplier="1:1" id="xxl-2N-8EP"/>
</constraints>
</view>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="JZR-Nd-wLM">
<rect key="frame" x="42" y="0.0" width="40" height="40"/>
<constraints>
<constraint firstAttribute="width" secondItem="JZR-Nd-wLM" secondAttribute="height" multiplier="1:1" id="atx-c5-FRS"/>
</constraints>
<color key="tintColor" name="TextDarkBlue"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="hand.thumbsup.fill" catalog="system"/>
<connections>
<action selector="btnTapped:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="EuW-HE-LQb"/>
</connections>
</button>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="1" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="1ig-SQ-qye">
<rect key="frame" x="84" y="0.0" width="5.6666666666666714" height="40"/>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="13"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="JKZ-Mx-BE0">
<rect key="frame" x="91.666666666666686" y="0.0" width="40" height="40"/>
<constraints>
<constraint firstAttribute="width" secondItem="JKZ-Mx-BE0" secondAttribute="height" multiplier="1:1" id="Klv-tP-CFQ"/>
</constraints>
<color key="tintColor" name="TextDarkBlue"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="heart.fill" catalog="system"/>
<connections>
<action selector="btnTapped:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="Lac-h1-kbx"/>
</connections>
</button>
</subviews>
</stackView>
</subviews>
</stackView>
</subviews>
<constraints>
<constraint firstAttribute="height" constant="40" id="eHz-Hw-4GD"/>
</constraints>
</stackView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<edgeInsets key="layoutMargins" top="10" left="10" bottom="5" right="10"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="5"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</stackView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="G54-zR-8Xw" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="5" id="Mzr-1D-4EY"/>
<constraint firstItem="G54-zR-8Xw" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="5" id="ZAr-tc-Dd5"/>
<constraint firstAttribute="trailing" secondItem="G54-zR-8Xw" secondAttribute="trailing" constant="5" id="lD2-m8-2nk"/>
<constraint firstAttribute="bottom" secondItem="G54-zR-8Xw" secondAttribute="bottom" constant="5" id="rf1-fD-USN"/>
</constraints>
</tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="njF-e1-oar"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<connections>
<outlet property="favBtn" destination="JKZ-Mx-BE0" id="RmY-pT-bZ9"/>
<outlet property="likeBtn" destination="JZR-Nd-wLM" id="dfG-hW-1PZ"/>
<outlet property="showThumbnail" destination="EAi-LC-2U0" id="UqK-Mv-yaC"/>
<outlet property="showTitle" destination="m8K-7d-Jib" id="uK6-U5-gBN"/>
<outlet property="totalLikes" destination="1ig-SQ-qye" id="XAw-XE-AYg"/>
</connections>
<point key="canvasLocation" x="212.97709923664121" y="59.154929577464792"/>
</tableViewCell>
</objects>
<resources>
<image name="hand.thumbsup.fill" catalog="system" width="128" height="121"/>
<image name="heart.fill" catalog="system" width="128" height="107"/>
<namedColor name="TextDarkBlue">
<color red="0.10599999874830246" green="0.050999999046325684" blue="0.60399997234344482" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>

View File

@@ -0,0 +1,337 @@
//
// WebSeriesVM.swift
// WOKA
//
// Created by MacBook Pro on 18/06/24.
//
import Foundation
import Alamofire
class WebSeriesVM{
weak var vc : WebSeriesVC!
var continueWatchingData = [ContinueWatchingDM.ResultData]()
var categoryListingData = [CategoryListingDM.ResultData]()
var showData = [WebSeriesShowListDM.ShowDatum]()
let dropDownModule = DropDown()
var dataSource = [String]()
func initView(){
vc.scrollView.indicatorStyle = .white // or .white
let color1 = #colorLiteral(red: 0.5921568627, green: 0.2588235294, blue: 0.8941176471, alpha: 1)
let color2 = #colorLiteral(red: 0.368627451, green: 0.1215686275, blue: 0.768627451, alpha: 1)
vc.title = "WEB SERIES".localized(loc: AuthFunc.shareInstance.languageSelected.rawValue)
vc.view.applyGradient(colors: [color2, color1], startPoint: CGPoint(x: 0, y: 0), endPoint: CGPoint(x: 0.8, y: 0))
getContinueWatching()
getCategoryListing()
// for the first load always send hindi as it is default category
getShowListing(categoryID: 18)
vc.languageStack.addTapGesture { [weak self] in
guard let self else {return}
dropDownModule.show()
self.vc.expandBtn.setImage(UIImage(named: "SupportUpArrow"), for: .normal)
}
setupCell()
}
func setupCell(){
vc.continueWatchingCV.register(UINib(nibName: K.CellIdentifier.WebSeries.webSeriesCell, bundle: nil), forCellWithReuseIdentifier: K.CellIdentifier.WebSeries.webSeriesCell)
vc.continueWatchingCV.delegate = vc.self
vc.continueWatchingCV.dataSource = vc.self
vc.showListingTableView.register(UINib(nibName: K.CellIdentifier.WebSeries.webSeriesShowListingCell, bundle: nil), forCellReuseIdentifier: K.CellIdentifier.WebSeries.webSeriesShowListingCell)
vc.showListingTableView.delegate = vc.self
vc.showListingTableView.dataSource = vc.self
}
// MARK: - DropDown
func initDropDown(){
dropDownModule.anchorView = vc.languageStack
dropDownModule.dataSource = dataSource
dropDownModule.cornerRadius = 10
dropDownModule.bottomOffset = CGPoint(x: 0, y:(dropDownModule.anchorView?.plainView.bounds.height)!)
dropDownModule.topOffset = CGPoint(x: 0, y:-(dropDownModule.anchorView?.plainView.bounds.height)!)
dropDownModule.direction = .bottom
dropDownModule.textFont = FontCustom.shareInstance.customFont(fontName: .Exo2_Bold, size: 14)
dropDownModule.shadowColor = UIColor.appColor(.TextDarkBlue)!
dropDownModule.backgroundColor = .white
dropDownModule.shadowOffset = CGSize(width: 0, height: 1)
dropDownModule.separatorColor = UIColor.lightGray
dropDownModule.width = vc.languageStack.frame.width
dropDownModule.selectionBackgroundColor = UIColor.appColor(.TextDarkBlue)!
dropDownModule.selectedTextColor = .white
dropDownModule.selectRow(at: 0)
dropDownModule.selectionAction = { [weak self] (index: Int, item: String) in
guard let self else{return}
vc.languageLabel.text = item
vc.expandBtn.setImage(UIImage(named: "SupportBottomArrow"), for: .normal)
//if the language is changed call the showlisting api
if let id = categoryListingData[index].id {
getShowListing(categoryID: id)
}
}
}
// MARK: - Api Calls
func getContinueWatching(){
Utilities.startProgressHUD()
// let headers : HTTPHeaders = ["access-token" : AuthFunc.shareInstance.getAccessToken()]
let headers : HTTPHeaders = ["access-token" : "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczovL3dva2FsYW5kLmNvbS9hZG1pbi9hcGkvbG9naW5fcHJvY2VlZCIsImlhdCI6MTcxODcxNTk4OSwiZXhwIjoxNzUwMjUxOTg5LCJuYmYiOjE3MTg3MTU5ODksImp0aSI6Ilh1QzVIdjY1RkcwQ1hqUkYiLCJzdWIiOiIyMTYiLCJwcnYiOiIyM2JkNWM4OTQ5ZjYwMGFkYjM5ZTcwMWM0MDA4NzJkYjdhNTk3NmY3In0.w8AfPv_6WUoDiBRcJzHz036qhaxfw_R9Gcb2C2wGLvs"]
let params : Parameters = ["post_type" : 3] // 3- webseries
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.WebSeries.continue_watching, method: .post,parameters: params,headers : headers) { [weak self](result : Result<BaseResponseModel<ContinueWatchingDM>, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{
Utilities.dismissProgressHUD()
return
}
switch data.success{
case 0:
/*
Error
*/
Utilities.dismissProgressHUD()
vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
case 1:
Utilities.dismissProgressHUD()
guard let data = data.data?.result else{return}
self.continueWatchingData = data
self.vc.continueWatchingCV.reloadData()
default:
break
}
case .failure(let error):
guard let self else{
Utilities.dismissProgressHUD()
return
}
Utilities.dismissProgressHUD()
vc.toast(msg: error.localizedDescription , time: 2)
}
}
}
func getShowListing(categoryID : Int){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["access-token" : AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["category_id" : categoryID] // from category listing api , default will be 1
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.WebSeries.watch_show_listing, method: .post,parameters: params,headers: headers) { [weak self](result : Result<BaseResponseModel<WebSeriesShowListDM>, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{
Utilities.dismissProgressHUD()
return
}
switch data.success{
case 0:
/*
Error
*/
Utilities.dismissProgressHUD()
vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
case 1:
Utilities.dismissProgressHUD()
guard let data = data.data?.showData else{return}
self.showData.removeAll()
self.showData = data
self.vc.showListingTableView.reloadData()
self.vc.tableHeight.constant = self.vc.showListingTableView.contentSize.height + 100
self.vc.showListingTableView.layoutIfNeeded()
self.vc.tableHeight.constant = self.vc.showListingTableView.contentSize.height
default:
break
}
case .failure(let error):
guard let self else{
Utilities.dismissProgressHUD()
return
}
Utilities.dismissProgressHUD()
vc.toast(msg: error.localizedDescription , time: 2)
}
}
}
func getCategoryListing(){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["access-token" : AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["module_id" : 7] // 7 - webseries
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.WebSeries.category_listing, method: .post,parameters: params,headers : headers) { [weak self](result : Result<BaseResponseModel<CategoryListingDM>, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{
Utilities.dismissProgressHUD()
return
}
switch data.success{
case 0:
/*
Error
*/
Utilities.dismissProgressHUD()
vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
case 1:
Utilities.dismissProgressHUD()
guard let data = data.data?.result else{return}
self.categoryListingData = data
dataSource = categoryListingData.map({$0.categoryName ?? "Unknown"})
initDropDown()
default:
break
}
case .failure(let error):
guard let self else{
Utilities.dismissProgressHUD()
return
}
Utilities.dismissProgressHUD()
vc.toast(msg: error.localizedDescription , time: 2)
}
}
}
// MARK: - Like , unlike
func likePost(postID : Int, postType : Int, index : Int , onCompletion : @escaping (Bool) -> Void){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["Accept-Language" : AuthFunc.shareInstance.languageSelected == .english ? "English" : "Hindi",
"access-token": AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["post_id" : postID,
"post_type" : postType]
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.post_like, method: .post, parameters: params, headers: headers) { [weak self](result : Result<CommonResponseModel, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{return}
switch data.success{
case 0:
Utilities.dismissProgressHUD()
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
onCompletion(false)
case 1:
Utilities.dismissProgressHUD()
onCompletion(true)
default:
Utilities.dismissProgressHUD()
onCompletion(false)
}
case .failure(let error):
guard let self else{return}
Utilities.dismissProgressHUD()
self.vc.toast(msg: error.localizedDescription , time: 2)
onCompletion(false)
}
}
}
func unlikePost(postID : Int, postType : Int , index : Int, onCompletion : @escaping (Bool) -> Void){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["Accept-Language" : AuthFunc.shareInstance.languageSelected == .english ? "English" : "Hindi",
"access-token": AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["post_id" : postID,
"post_type" : postType]
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.post_unlike, method: .post, parameters: params, headers: headers) { [weak self](result : Result<BaseResponseModel<CommonResponseModel>, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{return}
switch data.success{
case 0:
Utilities.dismissProgressHUD()
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
onCompletion(false)
case 1:
Utilities.dismissProgressHUD()
onCompletion(true)
default:
Utilities.dismissProgressHUD()
onCompletion(false)
}
case .failure(let error):
guard let self else{return}
Utilities.dismissProgressHUD()
self.vc.toast(msg: error.localizedDescription , time: 2)
onCompletion(false)
}
}
}
// MARK: - Remove Favourite
func removeFavourite(postID : Int, postType : Int, categoryID : Int, index : Int , onCompletion : @escaping (Bool) -> Void){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["Accept-Language" : AuthFunc.shareInstance.languageSelected == .english ? "English" : "Hindi",
"access-token": AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["id" : postID,
"post_type" : postType,
"category_id" : categoryID]
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.favourite_remove, method: .post, parameters: params, headers: headers) { [weak self](result : Result<CommonResponseModel, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{return}
switch data.success{
case 0:
Utilities.dismissProgressHUD()
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
onCompletion(false)
case 1:
Utilities.dismissProgressHUD()
onCompletion(true)
default:
Utilities.dismissProgressHUD()
onCompletion(false)
}
case .failure(let error):
guard let self else{return}
Utilities.dismissProgressHUD()
self.vc.toast(msg: error.localizedDescription , time: 2)
onCompletion(false)
}
}
}
func addFavourite(postID : Int, postType : Int, categoryID : Int, index : Int , onCompletion : @escaping (Bool) -> Void){
Utilities.startProgressHUD()
let headers : HTTPHeaders = ["Accept-Language" : AuthFunc.shareInstance.languageSelected == .english ? "English" : "Hindi",
"access-token": AuthFunc.shareInstance.getAccessToken()]
let params : Parameters = ["post_id" : postID,
"post_type" : postType,
"category_id" : categoryID]
NetworkManager.shareInstance.apiRequest(url: APIEndPoints.Home.favourite_add, method: .post, parameters: params, headers: headers) { [weak self](result : Result<CommonResponseModel, NetworkManager.APIError>) in
switch result{
case .success(let data):
guard let self else{return}
switch data.success{
case 0:
Utilities.dismissProgressHUD()
self.vc.toast(msg: data.message ?? "Unrecognised error" , time: 2)
onCompletion(false)
case 1:
Utilities.dismissProgressHUD()
onCompletion(true)
default:
Utilities.dismissProgressHUD()
onCompletion(false)
}
case .failure(let error):
guard let self else{return}
Utilities.dismissProgressHUD()
self.vc.toast(msg: error.localizedDescription , time: 2)
onCompletion(false)
}
}
}
}

View File

@@ -0,0 +1,248 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="32700.99.1234" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_12" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="22685"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<customFonts key="customFonts">
<array key="Exo2-Bold.ttf">
<string>Exo2-Bold</string>
</array>
</customFonts>
<scenes>
<!--Web SeriesVC-->
<scene sceneID="s0d-6b-0kx">
<objects>
<viewController storyboardIdentifier="WebSeriesVC" id="Y6W-OH-hqX" customClass="WebSeriesVC" customModule="WOKA" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="5EZ-qb-Rvc">
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bTO-Ql-tyN">
<rect key="frame" x="0.0" y="59" width="393" height="200"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="MasilaComingSoon" translatesAutoresizingMaskIntoConstraints="NO" id="wnB-dE-0v3">
<rect key="frame" x="0.0" y="0.0" width="393" height="200"/>
</imageView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="bottom" secondItem="wnB-dE-0v3" secondAttribute="bottom" id="BG4-7Q-bIb"/>
<constraint firstAttribute="trailing" secondItem="wnB-dE-0v3" secondAttribute="trailing" id="JQb-FA-v0E"/>
<constraint firstItem="wnB-dE-0v3" firstAttribute="top" secondItem="bTO-Ql-tyN" secondAttribute="top" id="LAu-Iu-1sV"/>
<constraint firstAttribute="height" constant="200" id="X2g-lr-CX0"/>
<constraint firstItem="wnB-dE-0v3" firstAttribute="leading" secondItem="bTO-Ql-tyN" secondAttribute="leading" id="sQQ-a5-rhV"/>
</constraints>
</view>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="0UD-sZ-RF4">
<rect key="frame" x="0.0" y="259" width="393" height="593"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="center" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="tRo-aT-Zuf">
<rect key="frame" x="0.0" y="0.0" width="393" height="98"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="MASILA" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="RDe-bw-Rsd">
<rect key="frame" x="145.66666666666666" y="0.0" width="102" height="50"/>
<constraints>
<constraint firstAttribute="height" constant="50" id="niS-eQ-1x0"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="28"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Vyo-SD-Uke" customClass="LocalisedElementsButton" customModule="WOKA" customModuleProvider="target">
<rect key="frame" x="146.66666666666666" y="58" width="100" height="40"/>
<color key="backgroundColor" red="0.36862745099999999" green="0.1215686275" blue="0.76862745099999996" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="Xr1-4J-QSr"/>
<constraint firstAttribute="width" constant="100" id="wO4-9d-U0h"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="14"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" title="TRAILER"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="20"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</button>
</subviews>
</stackView>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="rom-H6-7RC">
<rect key="frame" x="0.0" y="106" width="393" height="487"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="15" translatesAutoresizingMaskIntoConstraints="NO" id="c6v-VU-iKP">
<rect key="frame" x="0.0" y="0.0" width="393" height="645"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="mFz-UO-YUA">
<rect key="frame" x="10" y="0.0" width="373" height="270"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="CONTINUE WATCHING" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="l9e-Rq-ZI5">
<rect key="frame" x="0.0" y="0.0" width="373" height="40"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="MAT-Vz-Ee8"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="18"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" dataMode="prototypes" translatesAutoresizingMaskIntoConstraints="NO" id="SbC-xR-iRW">
<rect key="frame" x="0.0" y="40" width="373" height="230"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="230" id="SdM-w2-Zqn"/>
</constraints>
<collectionViewFlowLayout key="collectionViewLayout" scrollDirection="horizontal" minimumLineSpacing="10" minimumInteritemSpacing="10" id="tOS-Le-dTY">
<size key="itemSize" width="128" height="128"/>
<size key="headerReferenceSize" width="0.0" height="0.0"/>
<size key="footerReferenceSize" width="0.0" height="0.0"/>
<inset key="sectionInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
</collectionViewFlowLayout>
<cells/>
</collectionView>
</subviews>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="sVS-IL-R2M">
<rect key="frame" x="10" y="285" width="373" height="90"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Select Video Language" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="4zk-yS-92w">
<rect key="frame" x="0.0" y="0.0" width="373" height="40"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="fjV-kt-Sf2"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="18"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" alignment="top" translatesAutoresizingMaskIntoConstraints="NO" id="aqw-eq-zU5">
<rect key="frame" x="0.0" y="40" width="373" height="50"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="yFH-vA-sul">
<rect key="frame" x="0.0" y="0.0" width="205" height="50"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Hindi" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Exa-2W-66W">
<rect key="frame" x="15" y="10" width="150" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="150" id="RUF-0Z-y7n"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="15"/>
<color key="textColor" name="TextDarkBlue"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="nJQ-BB-3U3">
<rect key="frame" x="165" y="10" width="30" height="30"/>
<constraints>
<constraint firstAttribute="width" constant="30" id="HRV-zm-4xd"/>
</constraints>
<color key="tintColor" name="TextDarkBlue"/>
<inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
<state key="normal" image="SupportBottomArrow"/>
<connections>
<action selector="expandLanguageTapped:" destination="Y6W-OH-hqX" eventType="touchUpInside" id="NlA-yz-KeY"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<edgeInsets key="layoutMargins" top="10" left="15" bottom="10" right="10"/>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="10"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</stackView>
</subviews>
<constraints>
<constraint firstAttribute="height" constant="50" id="1hs-aK-S1w"/>
</constraints>
</stackView>
</subviews>
</stackView>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" scrollEnabled="NO" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" dataMode="prototypes" style="plain" separatorStyle="none" rowHeight="-1" estimatedRowHeight="244" sectionHeaderHeight="-1" estimatedSectionHeaderHeight="-1" sectionFooterHeight="-1" estimatedSectionFooterHeight="-1" translatesAutoresizingMaskIntoConstraints="NO" id="Oxv-4e-Qj0">
<rect key="frame" x="10" y="390" width="373" height="0.0"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" id="WLI-rz-zRP"/>
</constraints>
</tableView>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="DUm-IQ-hRU">
<rect key="frame" x="10" y="405" width="373" height="240"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Labelsad" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="NUp-lE-9Lp">
<rect key="frame" x="0.0" y="0.0" width="373" height="40"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="05W-0e-kZ5"/>
</constraints>
<fontDescription key="fontDescription" name="Exo2-Bold" family="Exo 2" pointSize="18"/>
<color key="textColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" image="AboutKids" translatesAutoresizingMaskIntoConstraints="NO" id="6qQ-sF-he2">
<rect key="frame" x="0.0" y="40" width="373" height="200"/>
<constraints>
<constraint firstAttribute="height" constant="200" id="lxT-4m-HAv"/>
</constraints>
</imageView>
</subviews>
</stackView>
</subviews>
<edgeInsets key="layoutMargins" top="0.0" left="10" bottom="0.0" right="10"/>
</stackView>
</subviews>
<constraints>
<constraint firstAttribute="bottom" secondItem="c6v-VU-iKP" secondAttribute="bottom" constant="-8" id="B8s-bz-Dd9"/>
<constraint firstItem="c6v-VU-iKP" firstAttribute="leading" secondItem="kWi-Yi-A7Z" secondAttribute="leading" id="JxV-Dw-HDg"/>
<constraint firstItem="c6v-VU-iKP" firstAttribute="top" secondItem="rom-H6-7RC" secondAttribute="top" id="OQm-HP-hpi"/>
<constraint firstItem="kWi-Yi-A7Z" firstAttribute="trailing" secondItem="c6v-VU-iKP" secondAttribute="trailing" id="Rdj-B6-s7x"/>
<constraint firstItem="c6v-VU-iKP" firstAttribute="width" secondItem="HJy-UQ-f93" secondAttribute="width" id="hFg-1R-IHZ"/>
</constraints>
<viewLayoutGuide key="contentLayoutGuide" id="HJy-UQ-f93"/>
<viewLayoutGuide key="frameLayoutGuide" id="kWi-Yi-A7Z"/>
</scrollView>
</subviews>
<color key="backgroundColor" red="0.035294117647058823" green="0.0" blue="0.36470588235294116" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</stackView>
</subviews>
<viewLayoutGuide key="safeArea" id="vDu-zF-Fre"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="0UD-sZ-RF4" firstAttribute="trailing" secondItem="vDu-zF-Fre" secondAttribute="trailing" id="DCe-Vn-7Dt"/>
<constraint firstItem="bTO-Ql-tyN" firstAttribute="leading" secondItem="vDu-zF-Fre" secondAttribute="leading" id="Wo8-6g-sdc"/>
<constraint firstItem="vDu-zF-Fre" firstAttribute="trailing" secondItem="bTO-Ql-tyN" secondAttribute="trailing" id="bPs-s1-jpc"/>
<constraint firstItem="bTO-Ql-tyN" firstAttribute="top" secondItem="vDu-zF-Fre" secondAttribute="top" id="qkp-BT-BFx"/>
<constraint firstAttribute="bottom" secondItem="0UD-sZ-RF4" secondAttribute="bottom" id="r39-DL-DAV"/>
<constraint firstItem="0UD-sZ-RF4" firstAttribute="leading" secondItem="vDu-zF-Fre" secondAttribute="leading" id="uk6-z5-78R"/>
<constraint firstItem="0UD-sZ-RF4" firstAttribute="top" secondItem="bTO-Ql-tyN" secondAttribute="bottom" id="v8E-mU-P1X"/>
</constraints>
</view>
<connections>
<outlet property="continueWatchingCV" destination="SbC-xR-iRW" id="nKM-9B-Dk2"/>
<outlet property="expandBtn" destination="nJQ-BB-3U3" id="AZm-uJ-RpA"/>
<outlet property="headerHeight" destination="X2g-lr-CX0" id="PAQ-Df-ZBb"/>
<outlet property="headerView" destination="bTO-Ql-tyN" id="85Y-HZ-SN0"/>
<outlet property="headerViewTopConstraint" destination="qkp-BT-BFx" id="5E7-T8-qUm"/>
<outlet property="languageLabel" destination="Exa-2W-66W" id="e7q-aD-laV"/>
<outlet property="languageStack" destination="yFH-vA-sul" id="pBj-Ph-i57"/>
<outlet property="scrollView" destination="rom-H6-7RC" id="8bD-vg-lG2"/>
<outlet property="showListingTableView" destination="Oxv-4e-Qj0" id="Yye-0B-zRg"/>
<outlet property="tableHeight" destination="WLI-rz-zRP" id="g40-aL-ik2"/>
<outlet property="topLabel" destination="RDe-bw-Rsd" id="xAP-OV-KId"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Ief-a0-LHa" userLabel="First Responder" customClass="UIResponder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-63.358778625954194" y="3.5211267605633805"/>
</scene>
</scenes>
<resources>
<image name="AboutKids" width="256" height="188.33332824707031"/>
<image name="MasilaComingSoon" width="200" height="100"/>
<image name="SupportBottomArrow" width="16.333333969116211" height="16.333333969116211"/>
<namedColor name="TextDarkBlue">
<color red="0.10599999874830246" green="0.050999999046325684" blue="0.60399997234344482" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</namedColor>
</resources>
</document>