Commit 8e284f57 by Angel FS

Merge Vijith's code

parent cad42707
......@@ -9,12 +9,20 @@
/* Begin PBXBuildFile section */
040DB2F327B51E2100A1C34F /* PickDropVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 040DB2F227B51E2100A1C34F /* PickDropVC.swift */; };
040DB2F827B5264F00A1C34F /* AddressVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 040DB2F727B5264F00A1C34F /* AddressVC.swift */; };
041F404327B7C044009AC6A8 /* OrderDetailTVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041F404127B7C044009AC6A8 /* OrderDetailTVC.swift */; };
041F404427B7C044009AC6A8 /* OrderDetailTVC.xib in Resources */ = {isa = PBXBuildFile; fileRef = 041F404227B7C044009AC6A8 /* OrderDetailTVC.xib */; };
041F404927B7D17F009AC6A8 /* YourItemListVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041F404827B7D17F009AC6A8 /* YourItemListVC.swift */; };
041F404E27B7E2B9009AC6A8 /* StoreListVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041F404D27B7E2B9009AC6A8 /* StoreListVC.swift */; };
0429CFFC27B3CD3B00F79B06 /* SignUpVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0429CFFB27B3CD3B00F79B06 /* SignUpVC.swift */; };
04500D2C27B3DE6600982455 /* AddAddressVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04500D2B27B3DE6600982455 /* AddAddressVC.swift */; };
04500D3127B430BA00982455 /* OrderDetailVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04500D3027B430BA00982455 /* OrderDetailVC.swift */; };
0450753127B4E1180016448E /* PackageDetailsVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0450753027B4E1180016448E /* PackageDetailsVC.swift */; };
0476A54527BCA79C00847E07 /* RoundedCornerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0476A54427BCA79C00847E07 /* RoundedCornerView.swift */; };
0476A54A27BCA7FD00847E07 /* HomeVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0476A54927BCA7FD00847E07 /* HomeVC.swift */; };
0480F9E827B53E9E000F33A5 /* CarrierStatusVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0480F9E727B53E9E000F33A5 /* CarrierStatusVC.swift */; };
0480F9ED27B55F87000F33A5 /* YourOrderVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0480F9EC27B55F87000F33A5 /* YourOrderVC.swift */; };
0486376D27BA109D00EDC696 /* StoreDetailTVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0486376B27BA109D00EDC696 /* StoreDetailTVC.swift */; };
0486376E27BA109D00EDC696 /* StoreDetailTVC.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0486376C27BA109D00EDC696 /* StoreDetailTVC.xib */; };
181926AE27B0DAF00000A85C /* Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 181926AD27B0DAF00000A85C /* Extensions.swift */; };
181926B327B0DAFA0000A85C /* validation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 181926B227B0DAFA0000A85C /* validation.swift */; };
181926B827B0DB000000A85C /* snackBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = 181926B727B0DB000000A85C /* snackBar.swift */; };
......@@ -54,12 +62,20 @@
/* Begin PBXFileReference section */
040DB2F227B51E2100A1C34F /* PickDropVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PickDropVC.swift; sourceTree = "<group>"; };
040DB2F727B5264F00A1C34F /* AddressVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddressVC.swift; sourceTree = "<group>"; };
041F404127B7C044009AC6A8 /* OrderDetailTVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OrderDetailTVC.swift; sourceTree = "<group>"; };
041F404227B7C044009AC6A8 /* OrderDetailTVC.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = OrderDetailTVC.xib; sourceTree = "<group>"; };
041F404827B7D17F009AC6A8 /* YourItemListVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YourItemListVC.swift; sourceTree = "<group>"; };
041F404D27B7E2B9009AC6A8 /* StoreListVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreListVC.swift; sourceTree = "<group>"; };
0429CFFB27B3CD3B00F79B06 /* SignUpVC.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SignUpVC.swift; sourceTree = "<group>"; };
04500D2B27B3DE6600982455 /* AddAddressVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddAddressVC.swift; sourceTree = "<group>"; };
04500D3027B430BA00982455 /* OrderDetailVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OrderDetailVC.swift; sourceTree = "<group>"; };
0450753027B4E1180016448E /* PackageDetailsVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PackageDetailsVC.swift; sourceTree = "<group>"; };
0476A54427BCA79C00847E07 /* RoundedCornerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = RoundedCornerView.swift; sourceTree = "<group>"; };
0476A54927BCA7FD00847E07 /* HomeVC.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = HomeVC.swift; sourceTree = "<group>"; };
0480F9E727B53E9E000F33A5 /* CarrierStatusVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CarrierStatusVC.swift; sourceTree = "<group>"; };
0480F9EC27B55F87000F33A5 /* YourOrderVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YourOrderVC.swift; sourceTree = "<group>"; };
0486376B27BA109D00EDC696 /* StoreDetailTVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StoreDetailTVC.swift; sourceTree = "<group>"; };
0486376C27BA109D00EDC696 /* StoreDetailTVC.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = StoreDetailTVC.xib; sourceTree = "<group>"; };
181926AD27B0DAF00000A85C /* Extensions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Extensions.swift; sourceTree = "<group>"; };
181926B227B0DAFA0000A85C /* validation.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = validation.swift; sourceTree = "<group>"; };
181926B727B0DB000000A85C /* snackBar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = snackBar.swift; sourceTree = "<group>"; };
......@@ -132,6 +148,9 @@
040DB2F727B5264F00A1C34F /* AddressVC.swift */,
0480F9E727B53E9E000F33A5 /* CarrierStatusVC.swift */,
0480F9EC27B55F87000F33A5 /* YourOrderVC.swift */,
041F404827B7D17F009AC6A8 /* YourItemListVC.swift */,
0476A54927BCA7FD00847E07 /* HomeVC.swift */,
041F404D27B7E2B9009AC6A8 /* StoreListVC.swift */,
);
path = Controller;
sourceTree = "<group>";
......@@ -143,6 +162,7 @@
181926B227B0DAFA0000A85C /* validation.swift */,
181926B727B0DB000000A85C /* snackBar.swift */,
181926AD27B0DAF00000A85C /* Extensions.swift */,
0476A54427BCA79C00847E07 /* RoundedCornerView.swift */,
);
path = Common;
sourceTree = "<group>";
......@@ -151,6 +171,10 @@
isa = PBXGroup;
children = (
181926CC27B0E3250000A85C /* LoginCollectionCell.swift */,
041F404127B7C044009AC6A8 /* OrderDetailTVC.swift */,
041F404227B7C044009AC6A8 /* OrderDetailTVC.xib */,
0486376B27BA109D00EDC696 /* StoreDetailTVC.swift */,
0486376C27BA109D00EDC696 /* StoreDetailTVC.xib */,
);
path = Cells;
sourceTree = "<group>";
......@@ -345,6 +369,8 @@
1863387827ABB83A00A7FD69 /* LaunchScreen.storyboard in Resources */,
1863387527ABB83A00A7FD69 /* Assets.xcassets in Resources */,
1863387327ABB82D00A7FD69 /* Main.storyboard in Resources */,
041F404427B7C044009AC6A8 /* OrderDetailTVC.xib in Resources */,
0486376E27BA109D00EDC696 /* StoreDetailTVC.xib in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -473,6 +499,8 @@
buildActionMask = 2147483647;
files = (
181926B827B0DB000000A85C /* snackBar.swift in Sources */,
041F404927B7D17F009AC6A8 /* YourItemListVC.swift in Sources */,
041F404E27B7E2B9009AC6A8 /* StoreListVC.swift in Sources */,
181926CD27B0E3250000A85C /* LoginCollectionCell.swift in Sources */,
0480F9ED27B55F87000F33A5 /* YourOrderVC.swift in Sources */,
0429CFFC27B3CD3B00F79B06 /* SignUpVC.swift in Sources */,
......@@ -481,14 +509,18 @@
0480F9E827B53E9E000F33A5 /* CarrierStatusVC.swift in Sources */,
1863387027ABB82D00A7FD69 /* LoginVC.swift in Sources */,
040DB2F327B51E2100A1C34F /* PickDropVC.swift in Sources */,
0486376D27BA109D00EDC696 /* StoreDetailTVC.swift in Sources */,
040DB2F827B5264F00A1C34F /* AddressVC.swift in Sources */,
0476A54A27BCA7FD00847E07 /* HomeVC.swift in Sources */,
181926BD27B0DB070000A85C /* colors.swift in Sources */,
1863386C27ABB82D00A7FD69 /* AppDelegate.swift in Sources */,
1863386E27ABB82D00A7FD69 /* SceneDelegate.swift in Sources */,
181926B327B0DAFA0000A85C /* validation.swift in Sources */,
0476A54527BCA79C00847E07 /* RoundedCornerView.swift in Sources */,
18F1703427B38BA5009E0ACC /* OtpVC.swift in Sources */,
04500D3127B430BA00982455 /* OrderDetailVC.swift in Sources */,
181926AE27B0DAF00000A85C /* Extensions.swift in Sources */,
041F404327B7C044009AC6A8 /* OrderDetailTVC.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......
......@@ -7,7 +7,7 @@
<key>OrderPicky.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>4</integer>
<integer>2</integer>
</dict>
</dict>
</dict>
......
{
"images" : [
{
"filename" : "grocery-sale-advertisement-banner-concept-260nw-1847536216.jpg",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "cart.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "home.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img1.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img2.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img3.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img4.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img5.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img6.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img7.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img8.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "notification.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "setting.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "starFlledColor-48.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "icons8-star-filled-48.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"filename" : "img2.png",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
//
// OrderDetailTVC.swift
// OrderPicky
//
// Created by ANGEL FS on 12/02/22.
//
import UIKit
class OrderDetailTVC: UITableViewCell {
@IBOutlet weak var outerView: UIView!
@IBOutlet weak var addItemView: UIView!
override func awakeFromNib() {
super.awakeFromNib()
self.outerView.dropShadow(color: UIColor.lightGray, opacity: 0.5, offSet: CGSize(width: 0, height: 0), radius: 5, scale: true)
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
//
// StoreDetailTVC.swift
// OrderPicky
//
// Created by ANGEL FS on 14/02/22.
//
import UIKit
class StoreDetailTVC: UITableViewCell {
@IBOutlet weak var outerView: UIView!
override func awakeFromNib() {
super.awakeFromNib()
self.outerView.dropShadow()
}
override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
}
......@@ -121,9 +121,9 @@ extension UIView {
layer.shadowOffset = offSet
layer.shadowRadius = radius
layer.shadowPath = UIBezierPath(rect: self.bounds).cgPath
layer.shouldRasterize = true
layer.rasterizationScale = scale ? UIScreen.main.scale : 1
// layer.shadowPath = UIBezierPath(rect: self.bounds).cgPath
// layer.shouldRasterize = true
// layer.rasterizationScale = scale ? UIScreen.main.scale : 1
}
func createDashedLine(color:UIColor ) {
......@@ -140,6 +140,13 @@ extension UIView {
layer.addSublayer(shapeLayer)
}
func roundCorners(corners: UIRectCorner, radius: CGFloat) {
let path = UIBezierPath(roundedRect: bounds, byRoundingCorners: corners, cornerRadii: CGSize(width: radius, height: radius))
let mask = CAShapeLayer()
mask.path = path.cgPath
layer.mask = mask
}
}
extension UITextField {
......
//
// RoundedCornerView.swift
// OrderPicky
//
// Created by Vijith on 10/02/22.
//
import Foundation
import UIKit
@IBDesignable
class RoundedCornerView: UIView {
// if cornerRadius variable is set/changed, change the corner radius of the UIView
@IBInspectable var cornerRadius: CGFloat = 0 {
didSet {
layer.cornerRadius = cornerRadius
layer.masksToBounds = cornerRadius > 0
}
}
}
@IBDesignable
class RoundedCornerImageView: UIImageView {
// if cornerRadius variable is set/changed, change the corner radius of the UIView
@IBInspectable var cornerRadius: CGFloat = 0 {
didSet {
layer.cornerRadius = cornerRadius
layer.masksToBounds = cornerRadius > 0
}
}
}
......@@ -30,6 +30,11 @@ class AddressVC: UIViewController {
self.navigationController?.pushViewController(nextVC, animated: true)
}
@IBAction func locationOneTapped(_ sender: Any) {
let nextVC = self.storyboard?.instantiateViewController(withIdentifier: "yourItemList")as! YourItemListVC
self.navigationController?.pushViewController(nextVC, animated: true)
}
}
extension AddressVC
......
//
// HomeVC.swift
// OrderPicky
//
// Created by Vijith on 10/02/22.
//
import UIKit
class HomeVC: UIViewController {
@IBOutlet weak var CollectionView: UICollectionView!
@IBOutlet weak var PageView: UIPageControl!
@IBOutlet weak var leftView:UIView!
@IBOutlet weak var rightView:UIView!
@IBOutlet weak var tableView: UITableView!
@IBOutlet weak var tableHeight: NSLayoutConstraint!
@IBOutlet weak var tabView: UIView!
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view.
}
override func viewWillAppear(_ animated: Bool) {
setui()
setPageView()
}
override func viewWillLayoutSubviews() {
super.updateViewConstraints()
self.tableHeight.constant = self.tableView.contentSize.height
}
var timer = Timer()
var counter = 0
var images = [
UIImage(named: "banner1"),UIImage(named: "banner1"),UIImage(named: "banner1")
]
func setPageView()
{
PageView.numberOfPages = images.count
PageView.currentPage = 0
DispatchQueue.main.async {
self.timer = Timer.scheduledTimer(timeInterval: 2.0, target: self, selector: #selector(self.changeScreen), userInfo: nil, repeats: true)
}
}
@objc func changeScreen()
{
if counter < images.count
{
let index = IndexPath.init(item: counter, section: 0)
CollectionView.isPagingEnabled = false
self.CollectionView.scrollToItem(at: index, at: .centeredHorizontally, animated: true)
CollectionView.isPagingEnabled = true
PageView.currentPage = counter
counter += 1
} else {
counter = 0
let index = IndexPath.init(item: counter, section: 0)
CollectionView.isPagingEnabled = false
self.CollectionView.scrollToItem(at: index, at: .centeredHorizontally, animated: false)
CollectionView.isPagingEnabled = true
PageView.currentPage = counter
}
}
func setui(){
self.leftView.dropShadow(color: UIColor.lightGray, opacity: 0.5, offSet: CGSize(width: 0, height: 0), radius: 5, scale: true)
self.rightView.dropShadow(color: UIColor.lightGray, opacity: 0.5, offSet: CGSize(width: 0, height: 0), radius: 5, scale: true)
self.tabView.roundCorners(corners: [.topLeft, .topRight], radius: 16)
}
@IBAction func homeBtnTapped(_ sender: Any) {
let nextVc = self.storyboard?.instantiateViewController(withIdentifier: "addAddress")as! AddAddressVC
self.navigationController?.pushViewController(nextVc, animated: true)
}
}
extension HomeVC : UICollectionViewDelegate,UICollectionViewDataSource,UICollectionViewDelegateFlowLayout
{
func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
return images.count
}
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "banner", for: indexPath) as! BannerCollectionCell
cell.image1.image = images[indexPath.row]
return cell
}
func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {
return CGSize(width: collectionView.frame.width - 60, height: collectionView.frame.height - 10)
}
}
extension HomeVC : UITableViewDelegate,UITableViewDataSource
{
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 5
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "tcell") as! TableListCell
//cell.outerView.dropShadow()
return cell
}
func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
viewWillLayoutSubviews()
}
}
class BannerCollectionCell: UICollectionViewCell {
@IBOutlet weak var image1:UIImageView!
}
class TableListCell: UITableViewCell {
@IBOutlet weak var image1:UIImageView!
@IBOutlet weak var outerView: UIView!
override class func awakeFromNib() {
}
override func layoutSubviews() {
self.outerView.dropShadow(color: UIColor.lightGray, opacity: 0.5, offSet: CGSize(width: 0, height: 0), radius: 5, scale: true)
self.outerView.layer.cornerRadius = 12.0
}
}
......@@ -113,7 +113,7 @@ class OtpVC: UIViewController,UITextFieldDelegate {
}
@IBAction func onTapVerifyBtn(_ sender: Any) {
let nextVc = self.storyboard?.instantiateViewController(withIdentifier: "addAddress")as! AddAddressVC
let nextVc = self.storyboard?.instantiateViewController(withIdentifier: "HomeVC")as! HomeVC
self.navigationController?.pushViewController(nextVc, animated: true)
}
......
//
// StoreListVC.swift
// OrderPicky
//
// Created by ANGEL FS on 12/02/22.
//
import UIKit
class StoreListVC: UIViewController {
@IBOutlet weak var storeListTable: UITableView!
override func viewDidLoad() {
super.viewDidLoad()
self.viewLoadingProperties()
}
@IBAction func backBtnTapped(_ sender: Any) {
self.navigationController?.popViewController(animated: true)
}
}
extension StoreListVC
{
func viewLoadingProperties()
{
self.storeListTable.register(UINib(nibName: "StoreDetailTVC", bundle: nil), forCellReuseIdentifier: "storeDetail")
}
}
extension StoreListVC : UITableViewDelegate , UITableViewDataSource
{
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 5
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "storeDetail")as! StoreDetailTVC
return cell
}
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return UITableView.automaticDimension
}
}
//
// YourItemListVC.swift
// OrderPicky
//
// Created by ANGEL FS on 12/02/22.
//
import UIKit
class YourItemListVC: UIViewController {
@IBOutlet weak var orderDetailTable: UITableView!
@IBOutlet weak var deliverToView: UIView!
@IBOutlet weak var searchBar: UISearchBar!
override func viewDidLoad() {
super.viewDidLoad()
self.viewLoadingProperties()
}
@IBAction func backBtnTapped(_ sender: Any) {
self.navigationController?.popViewController(animated: true)
}
@IBAction func proceedBtnTapped(_ sender: Any) {
let nextVC = self.storyboard?.instantiateViewController(withIdentifier: "yourOrder")as! YourOrderVC
self.navigationController?.pushViewController(nextVC, animated: true)
}
}
extension YourItemListVC
{
func viewLoadingProperties()
{
self.orderDetailTable.register(UINib(nibName: "OrderDetailTVC", bundle: nil), forCellReuseIdentifier: "orderDetail")
self.deliverToView.dropShadow()
self.searchBar.barTintColor = UIColor.white
self.searchBar.setBackgroundImage(UIImage.init(), for: UIBarPosition.any, barMetrics: UIBarMetrics.default)
self.searchBar.dropShadow()
}
}
extension YourItemListVC : UITableViewDelegate , UITableViewDataSource
{
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 5
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "orderDetail")as! OrderDetailTVC
if indexPath.row == 4
{
cell.addItemView.isHidden = false
}
else
{
cell.addItemView.isHidden = true
}
return cell
}
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return 75
}
}
......@@ -9,21 +9,57 @@ import UIKit
class YourOrderVC: UIViewController {
@IBOutlet weak var orderDetailTable: UITableView!
@IBOutlet weak var deliverToView: UIView!
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view.
self.viewLoadingProperties()
}
@IBAction func backBtnTapped(_ sender: Any) {
self.navigationController?.popViewController(animated: true)
}
@IBAction func payBtnTapped(_ sender: Any) {
let nextVC = self.storyboard?.instantiateViewController(withIdentifier: "storeList")as! StoreListVC
self.navigationController?.pushViewController(nextVC, animated: true)
}
}
/*
// MARK: - Navigation
// In a storyboard-based application, you will often want to do a little preparation before navigation
override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
// Get the new view controller using segue.destination.
// Pass the selected object to the new view controller.
extension YourOrderVC
{
func viewLoadingProperties()
{
self.orderDetailTable.register(UINib(nibName: "OrderDetailTVC", bundle: nil), forCellReuseIdentifier: "orderDetail")
self.deliverToView.dropShadow()
}
*/
}
extension YourOrderVC : UITableViewDelegate , UITableViewDataSource
{
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 5
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "orderDetail")as! OrderDetailTVC
if indexPath.row == 4
{
cell.addItemView.isHidden = false
}
else
{
cell.addItemView.isHidden = true
}
return cell
}
func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
return 75
}
}
......@@ -7,7 +7,7 @@
<key>Alamofire.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>2</integer>
<integer>3</integer>
</dict>
<key>Pods-OrderPicky-OrderPickyUITests.xcscheme_^#shared#^_</key>
<dict>
......@@ -17,12 +17,12 @@
<key>Pods-OrderPicky.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
<integer>4</integer>
</dict>
<key>Pods-OrderPickyTests.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>3</integer>
<integer>0</integer>
</dict>
</dict>
</dict>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment