Manos Chorianopoulos

add MarketAnalysisItemViewCell

...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
7 <key>Pods-SwiftWarplyFramework.xcscheme_^#shared#^_</key> 7 <key>Pods-SwiftWarplyFramework.xcscheme_^#shared#^_</key>
8 <dict> 8 <dict>
9 <key>orderHint</key> 9 <key>orderHint</key>
10 - <integer>0</integer> 10 + <integer>1</integer>
11 </dict> 11 </dict>
12 </dict> 12 </dict>
13 </dict> 13 </dict>
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
7 <key>SwiftWarplyFramework.xcscheme_^#shared#^_</key> 7 <key>SwiftWarplyFramework.xcscheme_^#shared#^_</key>
8 <dict> 8 <dict>
9 <key>orderHint</key> 9 <key>orderHint</key>
10 - <integer>1</integer> 10 + <integer>0</integer>
11 </dict> 11 </dict>
12 </dict> 12 </dict>
13 </dict> 13 </dict>
......
...@@ -906,18 +906,18 @@ ...@@ -906,18 +906,18 @@
906 <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> 906 <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
907 <color key="sectionIndexBackgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> 907 <color key="sectionIndexBackgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
908 <prototypes> 908 <prototypes>
909 - <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisItemViewCell" id="rSM-8Z-ffM" customClass="AnalysisItemViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target"> 909 + <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" selectionStyle="none" indentationWidth="10" reuseIdentifier="MarketAnalysisItemViewCell" id="rSM-8Z-ffM" customClass="MarketAnalysisItemViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target">
910 - <rect key="frame" x="0.0" y="55.5" width="414" height="94.5"/> 910 + <rect key="frame" x="0.0" y="55.5" width="414" height="113"/>
911 <autoresizingMask key="autoresizingMask"/> 911 <autoresizingMask key="autoresizingMask"/>
912 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="rSM-8Z-ffM" id="fGo-Oz-RqO"> 912 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="rSM-8Z-ffM" id="fGo-Oz-RqO">
913 - <rect key="frame" x="0.0" y="0.0" width="414" height="94.5"/> 913 + <rect key="frame" x="0.0" y="0.0" width="414" height="113"/>
914 <autoresizingMask key="autoresizingMask"/> 914 <autoresizingMask key="autoresizingMask"/>
915 <subviews> 915 <subviews>
916 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="5k6-t4-gFM" userLabel="Border View"> 916 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="5k6-t4-gFM" userLabel="Border View">
917 - <rect key="frame" x="10" y="0.0" width="394" height="94.5"/> 917 + <rect key="frame" x="10" y="0.0" width="394" height="113"/>
918 <subviews> 918 <subviews>
919 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bUU-PS-edj" userLabel="Inner View"> 919 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bUU-PS-edj" userLabel="Inner View">
920 - <rect key="frame" x="1" y="0.0" width="392" height="94.5"/> 920 + <rect key="frame" x="1" y="0.0" width="392" height="113"/>
921 <subviews> 921 <subviews>
922 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="05/05/2022" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="9VR-A0-cUn" userLabel="Date"> 922 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="05/05/2022" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="9VR-A0-cUn" userLabel="Date">
923 <rect key="frame" x="20" y="25" width="352" height="16"/> 923 <rect key="frame" x="20" y="25" width="352" height="16"/>
...@@ -929,10 +929,10 @@ ...@@ -929,10 +929,10 @@
929 <nil key="highlightedColor"/> 929 <nil key="highlightedColor"/>
930 </label> 930 </label>
931 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ni8-Py-xEo"> 931 <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ni8-Py-xEo">
932 - <rect key="frame" x="20" y="51" width="352" height="43.5"/> 932 + <rect key="frame" x="20" y="51" width="352" height="62"/>
933 <subviews> 933 <subviews>
934 <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="1Mu-3a-ZW1"> 934 <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="1Mu-3a-ZW1">
935 - <rect key="frame" x="0.0" y="8" width="28" height="28"/> 935 + <rect key="frame" x="0.0" y="17" width="28" height="28"/>
936 <constraints> 936 <constraints>
937 <constraint firstAttribute="width" constant="28" id="JMm-vz-JST"/> 937 <constraint firstAttribute="width" constant="28" id="JMm-vz-JST"/>
938 <constraint firstAttribute="height" constant="28" id="y90-Bp-tpm"/> 938 <constraint firstAttribute="height" constant="28" id="y90-Bp-tpm"/>
...@@ -944,14 +944,20 @@ ...@@ -944,14 +944,20 @@
944 <color key="textColor" red="0.12941176469999999" green="0.12941176469999999" blue="0.12941176469999999" alpha="1" colorSpace="calibratedRGB"/> 944 <color key="textColor" red="0.12941176469999999" green="0.12941176469999999" blue="0.12941176469999999" alpha="1" colorSpace="calibratedRGB"/>
945 <nil key="highlightedColor"/> 945 <nil key="highlightedColor"/>
946 </label> 946 </label>
947 + <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="248" verticalHuggingPriority="251" text="Έκπτωτικό κουπόνι" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="xeT-di-ZfP" userLabel="ProductTitle">
948 + <rect key="frame" x="38" y="24" width="251.5" height="17.5"/>
949 + <fontDescription key="fontDescription" name="PeridotPE-Regular" family="Peridot PE" pointSize="14"/>
950 + <color key="textColor" red="0.61568627450000002" green="0.61568627450000002" blue="0.61176470589999998" alpha="1" colorSpace="calibratedRGB"/>
951 + <nil key="highlightedColor"/>
952 + </label>
947 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="248" verticalHuggingPriority="251" text="Έκπτωτικό κουπόνι" lineBreakMode="tailTruncation" numberOfLines="2" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="y30-3S-677" userLabel="Subtitle"> 953 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="248" verticalHuggingPriority="251" text="Έκπτωτικό κουπόνι" lineBreakMode="tailTruncation" numberOfLines="2" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="y30-3S-677" userLabel="Subtitle">
948 - <rect key="frame" x="38" y="26" width="251.5" height="17.5"/> 954 + <rect key="frame" x="38" y="44.5" width="251.5" height="17.5"/>
949 <fontDescription key="fontDescription" name="PeridotPE-Regular" family="Peridot PE" pointSize="14"/> 955 <fontDescription key="fontDescription" name="PeridotPE-Regular" family="Peridot PE" pointSize="14"/>
950 <color key="textColor" red="0.61568627450000002" green="0.61568627450000002" blue="0.61176470589999998" alpha="1" colorSpace="calibratedRGB"/> 956 <color key="textColor" red="0.61568627450000002" green="0.61568627450000002" blue="0.61176470589999998" alpha="1" colorSpace="calibratedRGB"/>
951 <nil key="highlightedColor"/> 957 <nil key="highlightedColor"/>
952 </label> 958 </label>
953 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" horizontalCompressionResistancePriority="751" text="4,00€" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="SS9-PI-ZUR" userLabel="Price"> 959 <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" horizontalCompressionResistancePriority="751" text="4,00€" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="SS9-PI-ZUR" userLabel="Price">
954 - <rect key="frame" x="299.5" y="12" width="52.5" height="20"/> 960 + <rect key="frame" x="299.5" y="21" width="52.5" height="20"/>
955 <constraints> 961 <constraints>
956 <constraint firstAttribute="height" constant="20" id="nNy-3a-Ztq"/> 962 <constraint firstAttribute="height" constant="20" id="nNy-3a-Ztq"/>
957 </constraints> 963 </constraints>
...@@ -968,8 +974,10 @@ ...@@ -968,8 +974,10 @@
968 <constraint firstAttribute="bottom" secondItem="y30-3S-677" secondAttribute="bottom" id="K3k-Hd-w89"/> 974 <constraint firstAttribute="bottom" secondItem="y30-3S-677" secondAttribute="bottom" id="K3k-Hd-w89"/>
969 <constraint firstItem="1Mu-3a-ZW1" firstAttribute="leading" secondItem="ni8-Py-xEo" secondAttribute="leading" id="NjH-Zm-4gS"/> 975 <constraint firstItem="1Mu-3a-ZW1" firstAttribute="leading" secondItem="ni8-Py-xEo" secondAttribute="leading" id="NjH-Zm-4gS"/>
970 <constraint firstAttribute="trailing" secondItem="SS9-PI-ZUR" secondAttribute="trailing" id="RdF-lo-9QV"/> 976 <constraint firstAttribute="trailing" secondItem="SS9-PI-ZUR" secondAttribute="trailing" id="RdF-lo-9QV"/>
977 + <constraint firstItem="SS9-PI-ZUR" firstAttribute="leading" secondItem="xeT-di-ZfP" secondAttribute="trailing" constant="10" id="SVr-jL-XJd"/>
971 <constraint firstItem="SS9-PI-ZUR" firstAttribute="centerY" secondItem="ni8-Py-xEo" secondAttribute="centerY" id="XQe-fS-mjb"/> 978 <constraint firstItem="SS9-PI-ZUR" firstAttribute="centerY" secondItem="ni8-Py-xEo" secondAttribute="centerY" id="XQe-fS-mjb"/>
972 - <constraint firstItem="y30-3S-677" firstAttribute="top" secondItem="sSa-Y8-U8x" secondAttribute="bottom" constant="5" id="Ycx-MH-IOt"/> 979 + <constraint firstItem="xeT-di-ZfP" firstAttribute="leading" secondItem="1Mu-3a-ZW1" secondAttribute="trailing" constant="10" id="Xcm-cI-8Ee"/>
980 + <constraint firstItem="y30-3S-677" firstAttribute="top" secondItem="xeT-di-ZfP" secondAttribute="bottom" constant="3" id="Ycx-MH-IOt"/>
973 <constraint firstItem="SS9-PI-ZUR" firstAttribute="leading" secondItem="sSa-Y8-U8x" secondAttribute="trailing" constant="10" id="ZPe-i4-8pX"/> 981 <constraint firstItem="SS9-PI-ZUR" firstAttribute="leading" secondItem="sSa-Y8-U8x" secondAttribute="trailing" constant="10" id="ZPe-i4-8pX"/>
974 <constraint firstItem="y30-3S-677" firstAttribute="leading" secondItem="1Mu-3a-ZW1" secondAttribute="trailing" constant="10" id="hPn-vC-hQV"/> 982 <constraint firstItem="y30-3S-677" firstAttribute="leading" secondItem="1Mu-3a-ZW1" secondAttribute="trailing" constant="10" id="hPn-vC-hQV"/>
975 <constraint firstItem="SS9-PI-ZUR" firstAttribute="top" relation="greaterThanOrEqual" secondItem="ni8-Py-xEo" secondAttribute="top" constant="5" id="lVi-jg-DFs"/> 983 <constraint firstItem="SS9-PI-ZUR" firstAttribute="top" relation="greaterThanOrEqual" secondItem="ni8-Py-xEo" secondAttribute="top" constant="5" id="lVi-jg-DFs"/>
...@@ -977,6 +985,7 @@ ...@@ -977,6 +985,7 @@
977 <constraint firstAttribute="bottom" relation="greaterThanOrEqual" secondItem="SS9-PI-ZUR" secondAttribute="bottom" constant="5" id="pdM-NR-NSU"/> 985 <constraint firstAttribute="bottom" relation="greaterThanOrEqual" secondItem="SS9-PI-ZUR" secondAttribute="bottom" constant="5" id="pdM-NR-NSU"/>
978 <constraint firstItem="sSa-Y8-U8x" firstAttribute="top" secondItem="ni8-Py-xEo" secondAttribute="top" id="qpr-9J-aX9"/> 986 <constraint firstItem="sSa-Y8-U8x" firstAttribute="top" secondItem="ni8-Py-xEo" secondAttribute="top" id="qpr-9J-aX9"/>
979 <constraint firstItem="1Mu-3a-ZW1" firstAttribute="centerY" secondItem="ni8-Py-xEo" secondAttribute="centerY" id="qxj-kQ-VYX"/> 987 <constraint firstItem="1Mu-3a-ZW1" firstAttribute="centerY" secondItem="ni8-Py-xEo" secondAttribute="centerY" id="qxj-kQ-VYX"/>
988 + <constraint firstItem="xeT-di-ZfP" firstAttribute="top" secondItem="sSa-Y8-U8x" secondAttribute="bottom" constant="3" id="tlX-DO-FVe"/>
980 </constraints> 989 </constraints>
981 </view> 990 </view>
982 </subviews> 991 </subviews>
...@@ -1014,12 +1023,13 @@ ...@@ -1014,12 +1023,13 @@
1014 <outlet property="dateLabel" destination="9VR-A0-cUn" id="6Jp-5S-wEE"/> 1023 <outlet property="dateLabel" destination="9VR-A0-cUn" id="6Jp-5S-wEE"/>
1015 <outlet property="itemImage" destination="1Mu-3a-ZW1" id="DpC-2M-R3z"/> 1024 <outlet property="itemImage" destination="1Mu-3a-ZW1" id="DpC-2M-R3z"/>
1016 <outlet property="priceLabel" destination="SS9-PI-ZUR" id="aGY-2M-P2d"/> 1025 <outlet property="priceLabel" destination="SS9-PI-ZUR" id="aGY-2M-P2d"/>
1026 + <outlet property="productTitleLabel" destination="xeT-di-ZfP" id="Yw6-U0-LJP"/>
1017 <outlet property="subtitleLabel" destination="y30-3S-677" id="fSw-ur-2th"/> 1027 <outlet property="subtitleLabel" destination="y30-3S-677" id="fSw-ur-2th"/>
1018 <outlet property="titleLabel" destination="sSa-Y8-U8x" id="1ab-Ow-o76"/> 1028 <outlet property="titleLabel" destination="sSa-Y8-U8x" id="1ab-Ow-o76"/>
1019 </connections> 1029 </connections>
1020 </tableViewCell> 1030 </tableViewCell>
1021 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisHeaderViewCell" id="XvY-ms-M6u" customClass="AnalysisHeaderViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target"> 1031 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisHeaderViewCell" id="XvY-ms-M6u" customClass="AnalysisHeaderViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target">
1022 - <rect key="frame" x="0.0" y="150" width="414" height="183.5"/> 1032 + <rect key="frame" x="0.0" y="168.5" width="414" height="183.5"/>
1023 <autoresizingMask key="autoresizingMask"/> 1033 <autoresizingMask key="autoresizingMask"/>
1024 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="XvY-ms-M6u" id="Vyz-vd-NeA"> 1034 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="XvY-ms-M6u" id="Vyz-vd-NeA">
1025 <rect key="frame" x="0.0" y="0.0" width="414" height="183.5"/> 1035 <rect key="frame" x="0.0" y="0.0" width="414" height="183.5"/>
...@@ -1062,7 +1072,7 @@ ...@@ -1062,7 +1072,7 @@
1062 </connections> 1072 </connections>
1063 </tableViewCell> 1073 </tableViewCell>
1064 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisHeaderMessageViewCell" id="NZW-xW-f4G" customClass="AnalysisHeaderMessageViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target"> 1074 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisHeaderMessageViewCell" id="NZW-xW-f4G" customClass="AnalysisHeaderMessageViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target">
1065 - <rect key="frame" x="0.0" y="333.5" width="414" height="305.5"/> 1075 + <rect key="frame" x="0.0" y="352" width="414" height="305.5"/>
1066 <autoresizingMask key="autoresizingMask"/> 1076 <autoresizingMask key="autoresizingMask"/>
1067 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="NZW-xW-f4G" id="QSk-w7-BGe"> 1077 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="NZW-xW-f4G" id="QSk-w7-BGe">
1068 <rect key="frame" x="0.0" y="0.0" width="414" height="305.5"/> 1078 <rect key="frame" x="0.0" y="0.0" width="414" height="305.5"/>
...@@ -1147,7 +1157,7 @@ ...@@ -1147,7 +1157,7 @@
1147 </connections> 1157 </connections>
1148 </tableViewCell> 1158 </tableViewCell>
1149 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisMoreViewCell" id="nmR-bx-rhS" customClass="AnalysisMoreViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target"> 1159 <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" preservesSuperviewLayoutMargins="YES" selectionStyle="none" indentationWidth="10" reuseIdentifier="AnalysisMoreViewCell" id="nmR-bx-rhS" customClass="AnalysisMoreViewCell" customModule="SwiftWarplyFramework" customModuleProvider="target">
1150 - <rect key="frame" x="0.0" y="639" width="414" height="60"/> 1160 + <rect key="frame" x="0.0" y="657.5" width="414" height="60"/>
1151 <autoresizingMask key="autoresizingMask"/> 1161 <autoresizingMask key="autoresizingMask"/>
1152 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="nmR-bx-rhS" id="I5V-Yk-yS9"> 1162 <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" preservesSuperviewLayoutMargins="YES" insetsLayoutMarginsFromSafeArea="NO" tableViewCell="nmR-bx-rhS" id="I5V-Yk-yS9">
1153 <rect key="frame" x="0.0" y="0.0" width="414" height="60"/> 1163 <rect key="frame" x="0.0" y="0.0" width="414" height="60"/>
......
...@@ -14,6 +14,7 @@ class MarketAnalysisItemViewCell: UITableViewCell { ...@@ -14,6 +14,7 @@ class MarketAnalysisItemViewCell: UITableViewCell {
14 @IBOutlet weak var titleLabel: UILabel! 14 @IBOutlet weak var titleLabel: UILabel!
15 @IBOutlet weak var priceLabel: UILabel! 15 @IBOutlet weak var priceLabel: UILabel!
16 @IBOutlet weak var subtitleLabel: UILabel! 16 @IBOutlet weak var subtitleLabel: UILabel!
17 + @IBOutlet weak var productTitleLabel: UILabel!
17 18
18 var postImageURL: String? { 19 var postImageURL: String? {
19 didSet { 20 didSet {
...@@ -43,7 +44,7 @@ class MarketAnalysisItemViewCell: UITableViewCell { ...@@ -43,7 +44,7 @@ class MarketAnalysisItemViewCell: UITableViewCell {
43 44
44 // title 45 // title
45 titleLabel.textColor = UIColor(rgb: 0x212121) 46 titleLabel.textColor = UIColor(rgb: 0x212121)
46 - titleLabel.font = UIFont(name: "PeridotPE-Regular", size: 17.0) 47 + titleLabel.font = UIFont(name: "PeridotPE-SBold", size: 17.0)
47 48
48 // price 49 // price
49 priceLabel.textColor = UIColor(rgb: 0x212121) 50 priceLabel.textColor = UIColor(rgb: 0x212121)
...@@ -52,74 +53,15 @@ class MarketAnalysisItemViewCell: UITableViewCell { ...@@ -52,74 +53,15 @@ class MarketAnalysisItemViewCell: UITableViewCell {
52 // subtitle 53 // subtitle
53 // subtitleLabel.textColor = UIColor(rgb: 0x9D9D9C) 54 // subtitleLabel.textColor = UIColor(rgb: 0x9D9D9C)
54 subtitleLabel.textColor = UIColor(rgb: 0x212121) 55 subtitleLabel.textColor = UIColor(rgb: 0x212121)
55 - subtitleLabel.font = UIFont(name: "PeridotPE-Regular", size: 14.0) 56 + subtitleLabel.font = UIFont(name: "PeridotPE-SBold", size: 14.0)
56 - }
57 -}
58 -
59 -extension AnalysisItemViewCell {
60 - func configureCell(item: swiftApi.SharingCouponModel) {
61 -
62 - let merchantList:Array<swiftApi.MerchantModel> = swiftApi().getMerchantList()
63 57
64 - titleLabel.text = "" 58 + // productTitleLabel
65 - 59 + productTitleLabel.textColor = UIColor(rgb: 0x212121)
66 - for merchant in merchantList { 60 + productTitleLabel.font = UIFont(name: "PeridotPE-Regular", size: 14.0)
67 - if (merchant._uuid == item._merchant_uuid) {
68 - // itemImage.load(link: merchant._img_preview, placeholder: UIImage(), cache: URLCache())
69 - self.postImageURL = merchant._img_preview
70 - titleLabel.text = merchant._admin_name
71 - break;
72 - }
73 - }
74 -
75 - dateLabel.text = item._date
76 - // titleLabel.text = item._name
77 -
78 - let priceFloat = Float(round(100 * (Float(item._final_price) )) / 100)
79 - var priceString = "0"
80 - priceString = String(format: "%.2f", priceFloat).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil)
81 - priceLabel.text = priceString + "€"
82 -
83 - if ("sent" == item._sharing_type) {
84 - subtitleLabel.text = String(format: "Εκπτωτικό κουπόνι προς " + item._receiver_msisdn)
85 - } else if ("received" == item._sharing_type) {
86 - subtitleLabel.text = String(format: "Εκπτωτικό κουπόνι από " + item._sender_msisdn)
87 - }
88 - }
89 -
90 - func configureCell(item: swiftApi.SharingCouponModel, isMarket: Bool) {
91 -
92 - let merchantList:Array<swiftApi.MerchantModel> = swiftApi().getMerchantList()
93 - let couponSetData: swiftApi.CouponSetItemModel? = item._sm_couponset_data
94 -
95 - titleLabel.text = ""
96 -
97 - for merchant in merchantList {
98 - if (merchant._uuid == item._merchant_uuid) {
99 - // itemImage.load(link: merchant._img_preview, placeholder: UIImage(), cache: URLCache())
100 - self.postImageURL = merchant._img_preview
101 - titleLabel.text = merchant._admin_name
102 - break;
103 - }
104 - }
105 -
106 - dateLabel.text = item._date
107 - // titleLabel.text = item._name
108 -// titleLabel.text = couponSetData?.name ?? ""
109 -
110 -// let priceFloat = Float(round(100 * (Float(item._final_price) )) / 100)
111 - let priceFloat = Float(round(100 * (Float(couponSetData?.final_price ?? 0.0) )) / 100)
112 - var priceString = "0"
113 - priceString = String(format: "%.2f", priceFloat).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil)
114 - priceLabel.text = priceString + "€"
115 -
116 - if ("sent" == item._sharing_type) {
117 - subtitleLabel.text = String(format: "Εκπτωτικό κουπόνι προς " + item._receiver_msisdn)
118 - } else if ("received" == item._sharing_type) {
119 - subtitleLabel.text = String(format: "Εκπτωτικό κουπόνι από " + item._sender_msisdn)
120 - }
121 } 61 }
62 +}
122 63
64 +extension MarketAnalysisItemViewCell {
123 func configureCell(item: swiftApi.CouponItemModel) { 65 func configureCell(item: swiftApi.CouponItemModel) {
124 66
125 // COUPONSET: desc, img_preview, name, terms, merchant_uuid 67 // COUPONSET: desc, img_preview, name, terms, merchant_uuid
...@@ -154,12 +96,15 @@ extension AnalysisItemViewCell { ...@@ -154,12 +96,15 @@ extension AnalysisItemViewCell {
154 priceString = String(format: "%.2f", priceFloat).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil) 96 priceString = String(format: "%.2f", priceFloat).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil)
155 priceLabel.text = priceString + "€" 97 priceLabel.text = priceString + "€"
156 98
157 - subtitleLabel.text = "Έκπτωτικό κουπόνι" 99 + subtitleLabel.text = "Έκπτωτικό κουπόνι" // TODO: FIX
158 // subtitleLabel.text = couponSetData?.short_description ?? "" 100 // subtitleLabel.text = couponSetData?.short_description ?? ""
159 // OR 101 // OR
160 // let htmlText = couponSetData?.inner_text ?? "" 102 // let htmlText = couponSetData?.inner_text ?? ""
161 // subtitleLabel.text = htmlText.htmlToString 103 // subtitleLabel.text = htmlText.htmlToString
162 104
105 + let htmlText = couponSetData?.inner_text ?? ""
106 + productTitleLabel.text = htmlText.htmlToString
107 +
163 } 108 }
164 109
165 func configureCell(item: swiftApi.CouponItemModel, isMarket: Bool) { 110 func configureCell(item: swiftApi.CouponItemModel, isMarket: Bool) {
......
...@@ -139,7 +139,7 @@ class MarketHistoryViewController: AnalysisChildViewController { ...@@ -139,7 +139,7 @@ class MarketHistoryViewController: AnalysisChildViewController {
139 return cell 139 return cell
140 } 140 }
141 141
142 - let cell = tableView.dequeueReusableCell(withIdentifier: "AnalysisItemViewCell", for: indexPath) as! SwiftWarplyFramework.AnalysisItemViewCell 142 + let cell = tableView.dequeueReusableCell(withIdentifier: "MarketAnalysisItemViewCell", for: indexPath) as! SwiftWarplyFramework.MarketAnalysisItemViewCell
143 // cell.configureCell(item: items[indexPath.row], isMarket: true) 143 // cell.configureCell(item: items[indexPath.row], isMarket: true)
144 cell.configureCell(item: items[indexPath.row]) 144 cell.configureCell(item: items[indexPath.row])
145 145
......