ソースを参照

4月文档修改

吴彦祖 7 ヶ月 前
コミット
9a62853c26

BIN
ADHTuanCan.xcworkspace/xcuserdata/aodeheng.xcuserdatad/UserInterfaceState.xcuserstate


+ 4 - 2
ADHTuanCan/AppDelegate.swift

@@ -46,11 +46,13 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
         
         //默认域名
 //        Defaults[\.BaseUrl] = "http://47.108.114.127:10888"
-//        Defaults[\.BaseUrl] = "http://47.109.38.72:10887"
+        Defaults[\.BaseUrl] = "http://47.109.38.72:10887"
 //        Defaults[\.BaseUrl] = "http://www.gzzzyd.com/gm-api"
 //        Defaults[\.BaseUrl] = "http://wine.gzzzyd.com/api"
 //        Defaults[\.BaseUrl] = "https://kcapp.kiansengculinary.com/api"
-        Defaults[\.BaseUrl] = "https://kcapp.gzzzyd.com/api"
+//        Defaults[\.BaseUrl] = "https://kcapp.gzzzyd.com/api"
+//        Defaults[\.BaseUrl] = "https://kscapp.kiansengculinary.com/api"
+//    https://kscapp.kiansengculinary.com/api/
 //        Defaults[\.BaseUrl] = "https://kcapp.gzzzyd.com/api"
         
         if  Defaults[\.isFirstOpen]{

BIN
ADHTuanCan/Assets.xcassets/首页/素菜icon.imageset/60481712546862_.pic.jpg


+ 21 - 0
ADHTuanCan/Assets.xcassets/首页/素菜icon.imageset/Contents.json

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

+ 1 - 1
ADHTuanCan/Class/我的/Base.lproj/MyViewController.xib

@@ -208,7 +208,7 @@
                                         <action selector="headTouchAction:" destination="-1" eventType="touchUpInside" id="gwX-DY-UWQ"/>
                                     </connections>
                                 </button>
-                                <view hidden="YES" clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="kB9-RQ-Bfx">
+                                <view clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="kB9-RQ-Bfx">
                                     <rect key="frame" x="120" y="125.66666666666669" width="103.33333333333331" height="30"/>
                                     <subviews>
                                         <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="k6K-fM-Gs8">

+ 1 - 1
ADHTuanCan/Class/评价/MealEvaluateListVC.swift

@@ -32,7 +32,7 @@ class MealEvaluateListVC: ADHBaseVC {
         let navStyle = MCNavBarStyle()
         navStyle.styleForBackImage = UIImage.init(named: "黑色返回")!
         navStyle.styleForTitleColor = UIColor.black
-        self.navBar = MCNavBarView.init(title: LanguagesUtil.createTextBy(Ctext: "发表评价", Etext: "Comment"), subTitle: nil,style: navStyle)
+        self.navBar = MCNavBarView.init(title: LanguagesUtil.createTextBy(Ctext: "查看评价", Etext: "Comment"), subTitle: nil,style: navStyle)
         self.navBar?.backgroundColor = UIColor.white
         
         tableView.register(withType: MealEcaluateCell.self)

+ 2 - 0
ADHTuanCan/Class/餐品详情/model/SetMealModel.swift

@@ -138,6 +138,8 @@ class SetMealDetailModel : MCBaseModel{
     ///"优惠类型,0无,1优惠,2折扣 3活动"
     var disType : String?
     
+    /// 是否素食,1是,0否
+    var vegetarian : String?
 }
 
 class MealPricesModel : MCBaseModel{

+ 11 - 0
ADHTuanCan/Class/餐品详情/view/Base.lproj/MealHeadView.xib

@@ -149,6 +149,13 @@
                         <constraint firstAttribute="height" constant="60" id="znb-ga-VXz"/>
                     </constraints>
                 </imageView>
+                <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="素菜icon" translatesAutoresizingMaskIntoConstraints="NO" id="DWR-Ln-A3V">
+                    <rect key="frame" x="15" y="15" width="60" height="60"/>
+                    <constraints>
+                        <constraint firstAttribute="height" constant="60" id="1xU-En-TXr"/>
+                        <constraint firstAttribute="width" constant="60" id="qLc-0e-AEB"/>
+                    </constraints>
+                </imageView>
             </subviews>
             <color key="backgroundColor" systemColor="systemBackgroundColor"/>
             <constraints>
@@ -161,10 +168,12 @@
                 <constraint firstItem="V9C-AN-oyt" firstAttribute="centerY" secondItem="J8c-GB-QAE" secondAttribute="top" id="Msr-cM-hEc"/>
                 <constraint firstItem="HLU-We-ajz" firstAttribute="centerX" secondItem="JqI-4Y-l7F" secondAttribute="centerX" id="QPm-Nn-nNy"/>
                 <constraint firstItem="HLU-We-ajz" firstAttribute="centerY" secondItem="J8c-GB-QAE" secondAttribute="top" id="RJg-cR-sH8"/>
+                <constraint firstItem="DWR-Ln-A3V" firstAttribute="leading" secondItem="JqI-4Y-l7F" secondAttribute="leading" constant="15" id="RXM-tM-eJD"/>
                 <constraint firstAttribute="trailing" secondItem="FdS-i5-umo" secondAttribute="trailing" constant="15" id="aXx-ov-00s"/>
                 <constraint firstItem="Wif-ly-xQG" firstAttribute="leading" secondItem="JqI-4Y-l7F" secondAttribute="leading" id="e6q-Pd-rcy"/>
                 <constraint firstAttribute="trailing" secondItem="J8c-GB-QAE" secondAttribute="trailing" id="eI6-ef-TRT"/>
                 <constraint firstItem="FdS-i5-umo" firstAttribute="top" secondItem="JqI-4Y-l7F" secondAttribute="top" constant="15" id="qfw-GG-vFN"/>
+                <constraint firstItem="DWR-Ln-A3V" firstAttribute="top" secondItem="JqI-4Y-l7F" secondAttribute="top" constant="15" id="wOw-HG-gdC"/>
             </constraints>
             <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
             <connections>
@@ -174,6 +183,7 @@
                 <outlet property="saleImg" destination="FdS-i5-umo" id="mSe-2Y-AJi"/>
                 <outlet property="scoreLab" destination="ato-6S-9j3" id="53m-WD-SWT"/>
                 <outlet property="sellDetailLab" destination="FFc-R6-Pa4" id="BS6-Pe-nra"/>
+                <outlet property="suCaiImg" destination="DWR-Ln-A3V" id="tMa-sa-trL"/>
             </connections>
             <point key="canvasLocation" x="126.71755725190839" y="-129.57746478873241"/>
         </view>
@@ -181,6 +191,7 @@
     <resources>
         <image name="fire" width="16" height="16"/>
         <image name="优惠ICON" width="200" height="200"/>
+        <image name="素菜icon" width="64" height="64"/>
         <image name="黄星星" width="16" height="16"/>
         <systemColor name="systemBackgroundColor">
             <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>

+ 8 - 0
ADHTuanCan/Class/餐品详情/view/MealHeadView.swift

@@ -12,6 +12,8 @@ class MealHeadView: UIView {
     ///优惠图标
     @IBOutlet weak var saleImg: UIImageView!
     
+    @IBOutlet weak var suCaiImg: UIImageView!
+    
     
     @IBOutlet weak var foodImg: UIImageView!
     
@@ -63,6 +65,12 @@ class MealHeadView: UIView {
         if model.disType === 3{
             self.saleImg.image = UIImage(named: "活动ICON")
         }
+        
+        if model.vegetarian === 1{
+            self.suCaiImg.isHidden = false
+        }else{
+            self.suCaiImg.isHidden = true
+        }
     }
     
     @IBAction func evaluateAction(_ sender: UIButton) {

+ 4 - 0
ADHTuanCan/Class/首页/model/TCHomeGetDataModel.swift

@@ -164,6 +164,10 @@ class HomeFoodDetailModel : MCBaseModel{
     
     /// 1打折,2满减,3 赠送金额
     var disType : String?
+    
+    /// 是否素食,1是,0否
+    var vegetarian : String?
+
 }
 
 

+ 11 - 0
ADHTuanCan/Class/首页/view/Base.lproj/HomeFoodItem.xib

@@ -68,6 +68,13 @@
                                     <constraint firstAttribute="width" constant="35" id="mG4-O1-5il"/>
                                 </constraints>
                             </imageView>
+                            <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="素菜icon" translatesAutoresizingMaskIntoConstraints="NO" id="2BB-Nn-mzM">
+                                <rect key="frame" x="12" y="12" width="30" height="30"/>
+                                <constraints>
+                                    <constraint firstAttribute="width" constant="30" id="Fk9-Ey-MF4"/>
+                                    <constraint firstAttribute="height" constant="30" id="ZEW-jn-nST"/>
+                                </constraints>
+                            </imageView>
                         </subviews>
                         <color key="backgroundColor" red="0.98039215690000003" green="0.97254901959999995" blue="0.96862745100000003" alpha="1" colorSpace="calibratedRGB"/>
                         <constraints>
@@ -77,10 +84,12 @@
                             <constraint firstAttribute="trailing" secondItem="bia-Xw-5r2" secondAttribute="trailing" constant="12" id="CXh-y6-Ooj"/>
                             <constraint firstAttribute="trailing" secondItem="u7q-Ml-7OB" secondAttribute="trailing" constant="5" id="DED-He-oe7"/>
                             <constraint firstItem="vbK-nw-OZ9" firstAttribute="leading" secondItem="U2u-46-ylv" secondAttribute="leading" constant="12" id="GQL-1g-ngz"/>
+                            <constraint firstItem="2BB-Nn-mzM" firstAttribute="leading" secondItem="U2u-46-ylv" secondAttribute="leading" constant="12" id="PxV-ld-JKx"/>
                             <constraint firstAttribute="trailing" secondItem="vbK-nw-OZ9" secondAttribute="trailing" constant="12" id="StM-17-sSW"/>
                             <constraint firstItem="i1Z-vb-kIT" firstAttribute="top" secondItem="vbK-nw-OZ9" secondAttribute="bottom" constant="8" id="T0s-0N-Cjr"/>
                             <constraint firstItem="i1Z-vb-kIT" firstAttribute="centerY" secondItem="bia-Xw-5r2" secondAttribute="centerY" id="UaQ-ux-qEl"/>
                             <constraint firstItem="u7q-Ml-7OB" firstAttribute="top" secondItem="U2u-46-ylv" secondAttribute="top" constant="5" id="jUC-vU-LZs"/>
+                            <constraint firstItem="2BB-Nn-mzM" firstAttribute="top" secondItem="U2u-46-ylv" secondAttribute="top" constant="12" id="qaN-jJ-wSu"/>
                             <constraint firstItem="ijZ-6a-yaD" firstAttribute="centerX" secondItem="U2u-46-ylv" secondAttribute="centerX" id="ruZ-ds-LRy"/>
                             <constraint firstItem="ijZ-6a-yaD" firstAttribute="top" secondItem="U2u-46-ylv" secondAttribute="top" constant="20" id="uXa-Ar-MUC"/>
                         </constraints>
@@ -105,6 +114,7 @@
                 <outlet property="nameLab" destination="vbK-nw-OZ9" id="rTc-Mg-jJI"/>
                 <outlet property="priceLab" destination="i1Z-vb-kIT" id="vfj-fT-qf8"/>
                 <outlet property="saleImg" destination="u7q-Ml-7OB" id="fGg-31-Bua"/>
+                <outlet property="suCaiImg" destination="2BB-Nn-mzM" id="rXr-bG-oA5"/>
             </connections>
             <point key="canvasLocation" x="158.77862595419847" y="81.338028169014095"/>
         </collectionViewCell>
@@ -112,5 +122,6 @@
     <resources>
         <image name="优惠ICON" width="200" height="200"/>
         <image name="分类菜品尺寸" width="100" height="100"/>
+        <image name="素菜icon" width="64" height="64"/>
     </resources>
 </document>

+ 8 - 0
ADHTuanCan/Class/首页/view/HomeFoodItem.swift

@@ -18,6 +18,8 @@ class HomeFoodItem: UICollectionViewCell {
     
     @IBOutlet weak var saleImg: UIImageView!
     
+    @IBOutlet weak var suCaiImg: UIImageView!
+    
     override func awakeFromNib() {
         super.awakeFromNib()
         
@@ -45,6 +47,12 @@ class HomeFoodItem: UICollectionViewCell {
             self.saleImg.image = UIImage(named: "活动ICON")
         }
         
+        if dataModel.vegetarian === 1{
+            self.suCaiImg.isHidden = false
+        }else{
+            self.suCaiImg.isHidden = true
+        }
+        
         
     }
     

+ 11 - 0
ADHTuanCan/Class/首页/view/大家都爱点/Base.lproj/EverybodyLoveItem.xib

@@ -81,9 +81,17 @@
                         <constraint firstAttribute="width" constant="35" id="dho-dD-iQJ"/>
                     </constraints>
                 </imageView>
+                <imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="素菜icon" translatesAutoresizingMaskIntoConstraints="NO" id="WV4-LI-1z2">
+                    <rect key="frame" x="12" y="42" width="30" height="30"/>
+                    <constraints>
+                        <constraint firstAttribute="width" constant="30" id="4vz-is-013"/>
+                        <constraint firstAttribute="height" constant="30" id="nUL-6D-YWS"/>
+                    </constraints>
+                </imageView>
             </subviews>
             <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
             <constraints>
+                <constraint firstItem="WV4-LI-1z2" firstAttribute="leading" secondItem="0ob-Sz-Gve" secondAttribute="leading" constant="12" id="2yv-xY-6VF"/>
                 <constraint firstAttribute="trailing" secondItem="CXl-24-Pmk" secondAttribute="trailing" constant="10" id="50e-LE-GLQ"/>
                 <constraint firstAttribute="bottom" secondItem="9JH-p8-Pnu" secondAttribute="bottom" id="8QD-RS-7mz"/>
                 <constraint firstItem="tmS-kf-G6c" firstAttribute="leading" secondItem="0ob-Sz-Gve" secondAttribute="leading" id="94s-ur-09I"/>
@@ -100,6 +108,7 @@
                 <constraint firstAttribute="bottom" secondItem="qlc-Cv-FMT" secondAttribute="bottom" constant="18" id="aQK-OL-7m2"/>
                 <constraint firstAttribute="trailing" secondItem="iMa-gS-Hlk" secondAttribute="trailing" id="eES-hY-GNe"/>
                 <constraint firstItem="CXl-24-Pmk" firstAttribute="top" secondItem="0ob-Sz-Gve" secondAttribute="top" constant="10" id="jfw-f5-tg2"/>
+                <constraint firstItem="WV4-LI-1z2" firstAttribute="top" secondItem="tmS-kf-G6c" secondAttribute="bottom" constant="12" id="llz-mM-ZdE"/>
                 <constraint firstAttribute="trailing" secondItem="gzx-Gl-ktw" secondAttribute="trailing" id="lzD-Jk-RSp"/>
                 <constraint firstItem="iMa-gS-Hlk" firstAttribute="top" secondItem="0ob-Sz-Gve" secondAttribute="top" id="o1R-T4-s2t"/>
                 <constraint firstAttribute="trailing" secondItem="pBr-Sd-iJg" secondAttribute="trailing" constant="16" id="o8c-i5-bxC"/>
@@ -119,6 +128,7 @@
                 <outlet property="rightBtn" destination="gzx-Gl-ktw" id="GFz-aU-fEm"/>
                 <outlet property="saleImg" destination="CXl-24-Pmk" id="Zt2-XX-WJI"/>
                 <outlet property="scoreLab" destination="GzW-4o-aM9" id="awP-cv-blO"/>
+                <outlet property="suCaiImg" destination="WV4-LI-1z2" id="H3o-v5-BSI"/>
             </connections>
             <point key="canvasLocation" x="439.69465648854958" y="-204.22535211267606"/>
         </view>
@@ -126,6 +136,7 @@
     <resources>
         <image name="分类菜品尺寸" width="100" height="100"/>
         <image name="斜杆背景" width="129" height="130"/>
+        <image name="素菜icon" width="64" height="64"/>
         <image name="黄星星" width="16" height="16"/>
     </resources>
 </document>

+ 9 - 0
ADHTuanCan/Class/首页/view/大家都爱点/EverybodyLoveItem.swift

@@ -21,6 +21,9 @@ class EverybodyLoveItem: UIView {
     
     @IBOutlet weak var saleImg: UIImageView!
     
+    @IBOutlet weak var suCaiImg: UIImageView!
+    
+    
     var touchUpActionBlock : (()->Void)?
     
     override func awakeFromNib() {
@@ -52,6 +55,12 @@ class EverybodyLoveItem: UIView {
         if model.disType === 3{
             self.saleImg.image = UIImage(named: "活动ICON")
         }
+        
+        if model.vegetarian === 1{
+            self.suCaiImg.isHidden = false
+        }else{
+            self.suCaiImg.isHidden = true
+        }
     }
 
     @IBAction func touchUpAction(_ sender: UIButton) {