宽窄优行-由【嘉易行】项目成品而来
无故事王国
2023-05-25 dc1998fc1ac124f6b9a0e434ccf91103dd936409
修改与新增
34个文件已修改
352 ■■■■ 已修改文件
OKProject/API/API.swift 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Enums.swift 47 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Controller/HomeVC.swift 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Controller/TravelCardDetailVC.swift 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Controller/TravelCardListVC.swift 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Controller/TravelCardVC.swift 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Controller/TravelVC.swift 77 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/Model/MerchantModel.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/View/TravelCancelServicePayView.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/View/TripAddressCell.swift 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/ViewModel/TravelCouponsViewModel.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/ViewModel/TravelServicePayViewModel.swift 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/ViewModel/TravelServiceViewModel.swift 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/ViewModel/TravelViewModel.swift 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Home/ViewModel/YYCostDetailViewModel.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/LeftMenu/ViewModel/AgreementViewModel.swift 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Logistics(小件物流)/Controllers/ChooseItemTypeVC.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Logistics(小件物流)/Controllers/LogisticsListVC.swift 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Logistics(小件物流)/Controllers/ShippingInformationVC.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Logistics(小件物流)/ViewModels/LositcsViewModel.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Order/Controller/MyOrderListVC.swift 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Order/Controller/TaxiOrderListVC.swift 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Order/ViewModel/TaxiOrderViewModel.swift 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/SpecialCar/Controller/YYSpecialCarFlowViewController.swift 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/SpecialCar/Controller/YYSpecialCarpoolingCarFlowViewController.swift 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/SpecialCar/View/YYTravelInfosView.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/SpecialCar/ViewModel/YYSpecialCarViewModel.swift 16 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Taxi/Controller/ScanChooseTravelVC.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/Taxi/Controller/TravelServiceVC.swift 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelChooseCityVC.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelCityHomeVC.swift 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelInstructionsView.swift 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelInstructionsView.xib 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/Class/TravelAcrossCity(跨城)/ViewModels/TravelCityViewModel.swift 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
OKProject/API/API.swift
@@ -1706,7 +1706,7 @@
            case .getMyTaxiCardList(orderType: let type):
                let params = APIParamsAppender()
                    .append(key: "orderType", value: type.parame())
                    .append(key: "orderType", value: type.rawValue)
                return .requestParameters(parameters: params.done(), encoding: URLEncoding.queryString)
            case .getMyTaxiCardInfo(id: let id):
@@ -1749,13 +1749,13 @@
            case .giveAwayMerchantCoupon(orderType: let orderType, orderId: let orderId):
                let params = APIParamsAppender()
                    .append(key: "orderType", value: orderType.parame())
                    .append(key: "orderType", value: orderType.rawValue)
                    .append(key: "orderId", value: orderId)
                return .requestParameters(parameters: params.done(), encoding: URLEncoding.queryString)
            case .queryCouponList(orderType: let orderType, orderId: let orderId, pageNum: let pageNum):
                let params = APIParamsAppender()
                    .append(key: "orderType", value: orderType.parame())
                    .append(key: "orderType", value: orderType.rawValue)
                    .append(key: "orderId", value: orderId)
                    .append(key: "pageNum", value: pageNum)
                    .append(key: "size", value: 100)
OKProject/Class/Enums.swift
@@ -15,15 +15,44 @@
    case fullMinus = 2 //满减
}
enum UserType:Int,HandyJSONEnum {
    case usual = 0 //通用
    case special = 1 //快车
    case taxi = 2 //出租车
    case intercity = 3 //城际
    case expressSamecity = 4 //小件物流-同城
    case expressOthercity = 5 // 小件物流-跨城
    case charter = 6 //包车
}
//enum UserType:Int,HandyJSONEnum {
//    case usual = 0 //通用
//    case special = 1 //快车
//    case taxi = 2 //出租车
//    case intercity = 3 //城际
//    case expressSamecity = 4 //小件物流-同城
//    case expressOthercity = 5 // 小件物流-跨城
//    case charter = 6 //包车
//    case custom = 7 //95128电召
//    case scenic = 8 //景区直通车
//    case plane = 9 //机场专线
//    case offical = 10 //公务用车
//}
    /// 出行方式 /// 业务类型(1=快车,2=出租车,3=城际,4=小件物流-同城,5=小件物流-跨城,6=包车)
    enum OrderType: Int,HandyJSONEnum{
        // 出租车
        case taxi = 2
        /// 快车
        case special = 1
        /// 跨城
        case travel = 3
        /// 同城物流
        case cityLogistics = 4
        /// 跨城物流
        case acrossLogistics = 5
        /// 包车
        case charter = 6
        /// 95128电召
        case custom = 7
        /// 景区直通车
        case scenic = 8
        /// 机场专线
        case plane = 9
        ///公务用车
        case offical = 10
    }
enum DiscountType:Int,HandyJSONEnum{
    case numberOfDiscounts = 1 //打折次数卡
OKProject/Class/Home/Controller/HomeVC.swift
@@ -698,7 +698,7 @@
                vc.showCar = showCar
                return vc
            case "公务出行":
                let vc = TravelVC.init(orderType: .business)
                let vc = TravelVC.init(orderType: .offical)
                vc.showCar = showCar
                vc.officialCharterClouse = { [weak self] in
                    let officialCharterVC = OfficialCharterVC()
@@ -711,14 +711,16 @@
                    }
                }
                return vc
            case "机场专线","景区直通车":
            case "机场专线","景区直通车","跨城出行":
                var vc: TravelCityHomeVC! = magicView.dequeueReusablePage(withIdentifier: String(describing: name)) as? TravelCityHomeVC
                if vc == nil {
                    vc = TravelCityHomeVC()
                    if name == "机场专线"{
                        vc.type = 3
                        vc.type = .plane
                    }else if name == "景区直通车"{
                        vc.type = .scenic
                    }else{
                        vc.type = 7
                        vc.type = .travel
                    }
                }
                vc.showCar = showCar
OKProject/Class/Home/Controller/TravelCardDetailVC.swift
@@ -11,7 +11,7 @@
class TravelCardDetailVC: YYViewController {
    var id = 0
    var type = 0
    var type:OrderType = .taxi
    @IBOutlet weak var titleL: UILabel!
    @IBOutlet weak var nameL: UILabel!
    @IBOutlet weak var infoL: UILabel!
@@ -37,11 +37,11 @@
        tableView.register(cellName: "TravelCouponTCell", identifier: "_TravelCouponTCell")
        switch type {
            case 1:titleL.text = "快车/专车"
            case 2:titleL.text = "出租车"
            case 3:titleL.text = "跨城出行"
            case 4:titleL.text = "同城物流"
            case 5:titleL.text = "跨城物流"
            case .special:titleL.text = "快车/专车"
            case .taxi:titleL.text = "出租车"
            case .travel:titleL.text = "跨城出行"
            case .cityLogistics:titleL.text = "同城物流"
            case .acrossLogistics:titleL.text = "跨城物流"
            default:break
        }
OKProject/Class/Home/Controller/TravelCardListVC.swift
@@ -13,7 +13,7 @@
    /// viewModel
    let viewModel = TravelMyCardViewModel()
    init(orderType: Int) {
    init(orderType: OrderType) {
        viewModel.type.accept(orderType)
        super.init(nibName: nil, bundle: nil)
    }
@@ -89,13 +89,13 @@
        cell.contentView.backgroundColor = UIColor(hexString: "#F3F4F5")
        cell.couponListModel = m
        switch viewModel.type.value {
            case 1:cell.titleL.text = "快车/专车"
            case 2:cell.titleL.text = "出租车"
            case 3:cell.titleL.text = "跨城出行"
            case 4:
            case .special:cell.titleL.text = "快车/专车"
            case .taxi:cell.titleL.text = "出租车"
            case .travel:cell.titleL.text = "跨城出行"
            case .cityLogistics:
                cell.titleL.text = "同城物流"
                if m.businessTypes.contains([4,5]){cell.titleL.text = "同城/跨城物流"}
            case 5:
            case .acrossLogistics:
                cell.titleL.text = "跨城物流"
                if m.businessTypes.contains([4,5]){cell.titleL.text = "同城/跨城物流"}
            default:break
OKProject/Class/Home/Controller/TravelCardVC.swift
@@ -92,22 +92,22 @@
        let name = menu[Int(pageIndex)]
        switch name {
            case "出租车":
                let vc = TravelCardListVC.init(orderType: 2)
                let vc = TravelCardListVC.init(orderType:.taxi)
                return vc
            case "快车":
                let vc = TravelCardListVC.init(orderType: 1)
                let vc = TravelCardListVC.init(orderType: .special)
                return vc
            case "跨城出行":
                let vc = TravelCardListVC.init(orderType: 3)
                let vc = TravelCardListVC.init(orderType: .travel)
                return vc
            case "同城小件物流":
                let vc = TravelCardListVC.init(orderType: 4)
                let vc = TravelCardListVC.init(orderType: .cityLogistics)
                return vc
            case "跨城小件物流":
                let vc = TravelCardListVC.init(orderType: 5)
                let vc = TravelCardListVC.init(orderType: .acrossLogistics)
                return vc
            case "包车":
                let vc = TravelCardListVC.init(orderType: 6)
                let vc = TravelCardListVC.init(orderType: .charter)
                return vc
            default:
                break
OKProject/Class/Home/Controller/TravelVC.swift
@@ -11,65 +11,6 @@
import RxSwift
import HandyJSON
/// 出行方式 /// 业务类型(1=快车,2=出租车,3=城际,4=小件物流-同城,5=小件物流-跨城,6=包车)
enum OrderType: Int,HandyJSONEnum{
    // 出租车
    case taxi = 2
    /// 快车
    case special = 1
    /// 跨城
    case travel = 3
    /// 同城物流
    case cityLogistics = 4
    /// 跨城物流
    case acrossLogistics = 5
    /// 包车
    case charter = 6
    //公务用车
    case business = 8
    func parame() -> Int {
        switch self {
        case .taxi:
            return 2
        case .travel :
            return 3
        case .cityLogistics:
            return 4
        case .acrossLogistics:
            return 5
        case .charter:
            return 6
        case .business:
            return 8
        default:
            return 1
        }
    }
    static func type(id: Int) -> OrderType {
        switch id {
        case 2:
            return .taxi
        case 3:
            return .travel
        case 4:
            return .cityLogistics
        case 5:
            return .acrossLogistics
        case 6:
            return .charter
        case 8:
            return .business
        default:
            return .special
        }
    }
}
/// 出行
class TravelVC: YYViewController {
    
@@ -219,7 +160,7 @@
        
        // 选择人数
        cell.appointment.delegate(on: self) { (self, _) in
            if self.viewModel.orderType.value == .special{
            if self.viewModel.orderType.value == OrderType.special{
                let num = YYMapViewManager.share.passengerNum.value
                SpecialSealAffirmView.show(defaultNum: num, affirmClouse: { num in
                    YYMapViewManager.share.passengerNum.accept(num)
@@ -238,7 +179,7 @@
                return
            }
            if self.viewModel.orderType.value == .business{
            if self.viewModel.orderType.value == OrderType.offical{
                let view = TaxiReservationView()
                view.show(intervalMinute:20)
                view.complete.delegate(on: self) { (self, timeStamp) in
@@ -257,7 +198,7 @@
        cell.passenger.delegate(on: self) { (self, _) in
            //公务车出行事由
            if self.viewModel.orderType.value == .business{
            if self.viewModel.orderType.value == .offical{
                let vc = ReasonforTravelVC()
                vc.view.backgroundColor = UIColor.black.withAlphaComponent(0)
                vc.view.frame = CGRect(x: 0, y: screenH, width: ScreenWidth, height: ScreenHeight)
@@ -292,7 +233,7 @@
        // 添加小费
        cell.tip.delegate(on: self) { (self, _) in
                //公务车计费方式
                if self.viewModel.orderType.value == .business{
                if self.viewModel.orderType.value == .offical{
                    MineInfoView.instance(data: ["单程计费","包车计费"]).show { (row) in
                        if row == 0{
@@ -389,7 +330,7 @@
        super.init(nibName: nil, bundle: nil)
        viewModel.orderType.accept(orderType)
        if orderType == .business{
        if orderType == .offical{
            YYMapViewManager.share.state.accept(.appointment)
        }
    }
@@ -550,7 +491,7 @@
                        let vc = YYSpecialCarViewController.init(orderId: self.viewModel.orderId.value)
                        self.yy_push(vc: vc)
                        break
                    case .business:
                    case .offical:
                        let vc = TravelServiceVC.init(orderId: self.viewModel.orderId.value, orderType: self.viewModel.orderType.value)
                        self.yy_push(vc: vc)
                        default:break
@@ -571,7 +512,7 @@
        
        viewModel.number.bind(to: view_carNum.label_content.rx.text).disposed(by: disposeBag)
        
        view_carNum.didPressTrip.delegate(on: self) { (self, _) in
        view_carNum.didPressTrip.delegate(on: self) { (_, _) in
            switch self.viewModel.orderType.value{
            case .taxi:
                // 订单流程界面
@@ -585,7 +526,7 @@
                let vc = YYSpecialCarViewController.init(orderId: self.viewModel.currentOrderId.value,isCarpool: isCarpool)
                self.yy_push(vc: vc)
                case .business:
                case .offical:
                    break
            case .travel:
                break
@@ -611,7 +552,7 @@
                        self.offset = 0
                    }
                    if viewModel.orderType.value == .business{
                    if viewModel.orderType.value == .offical{
                        self.cellHeight = 280
                    }
OKProject/Class/Home/Model/MerchantModel.swift
@@ -90,5 +90,5 @@
    var state:CouponStateType = .overdue
    var time  = ""
    var type:CouponDiscountType = .discount
    var userType:UserType = .usual
    var userType:OrderType = .taxi
}
OKProject/Class/Home/View/TravelCancelServicePayView.swift
@@ -205,7 +205,7 @@
            self.viewModel.payType.accept(self.payType.value.parame())
            if self.payType.value == .weChat{
                let content = (self.viewModel.cancelId.value) == 0 ? nil : "{cancelId:\(self.viewModel.cancelId.value)}"
                let request = YYWeChatMiniProgramPayRequest.init(orderId: self.viewModel.orderId.value, orderType: self.viewModel.orderType.value.parame(), type: 2, uid: app.loginInfo.id, userType: 1, content: content)
                let request = YYWeChatMiniProgramPayRequest.init(orderId: self.viewModel.orderId.value, orderType: self.viewModel.orderType.value.rawValue, type: 2, uid: app.loginInfo.id, userType: 1, content: content)
                 self.dismiss()
                YYPaymentManager.shared.sendWXPaymentRequest(request) { (result) in
                    switch result {
OKProject/Class/Home/View/TripAddressCell.swift
@@ -370,7 +370,7 @@
                    self.button_tip.isHidden = false
                    if YYMapViewManager.share.orderType.value == .taxi{
                        self.button_date.setTitle(YYMapViewManager.share.timeStamp.value == nil ? "选择时间" : "\(YYMapViewManager.share.timeStamp.value?.toFormat(format: "M月d日 HH:mm") ?? "选择时间")", for: .normal)
                    }else if YYMapViewManager.share.orderType.value == .business{
                    }else if YYMapViewManager.share.orderType.value == .offical{
                        self.button_date.setTitle(YYMapViewManager.share.timeStamp.value == nil ? "时间" : "\(YYMapViewManager.share.timeStamp.value?.toFormat(format: "M月d日 HH:mm") ?? "时间")", for: .normal)
                        self.button_passenger.setTitle(YYMapViewManager.share.passenger.value == nil ? "事由出行" : "\(YYMapViewManager.share.passenger.value?.name ?? "事由出行")", for: .normal)
                    }else{
@@ -410,7 +410,7 @@
                self.sitSingleView.isHidden = true
                self.onePriceView.isHidden = true
                if YYMapViewManager.share.orderType.value == .business{
                if YYMapViewManager.share.orderType.value == .offical{
                    self.view_now.isHidden = true
                    self.view_call.isHidden = false
                    self.view_taxi.isHidden = true
@@ -455,7 +455,7 @@
                    title = "呼叫出租车"
                }else if YYMapViewManager.share.orderType.value == .special {
                    title = "呼叫快车/专车"
                }else if YYMapViewManager.share.orderType.value == .business{
                }else if YYMapViewManager.share.orderType.value == .offical{
                    title = "预约出行"
                }
            self.button_submit.setTitle(title, for: .normal)
@@ -474,7 +474,7 @@
        YYMapViewManager.share.tip
        .subscribeOn(MainScheduler.instance)
            .subscribe(onNext: {[unowned self] (string) in
                if YYMapViewManager.share.orderType.value == .business{
                if YYMapViewManager.share.orderType.value == .offical{
                    self.button_tip.setTitle(string == nil ? "计费方式" : string, for: .normal)
                }else{
                    self.button_tip.setTitle(string == nil ? "小费" : string, for: .normal)
OKProject/Class/Home/ViewModel/TravelCouponsViewModel.swift
@@ -19,6 +19,6 @@
    let orderId  = BehaviorRelay<Int>(value: 0)
    
    override func api() -> API! {
        return .queryCoupon(orderId: orderId.value, orderType: orderType.value.parame(), pageNum: currentPage, size: totalPages)
        return .queryCoupon(orderId: orderId.value, orderType: orderType.value.rawValue, pageNum: currentPage, size: totalPages)
    }
}
OKProject/Class/Home/ViewModel/TravelServicePayViewModel.swift
@@ -36,7 +36,7 @@
    func queryBalance()  {
        queryBalanceSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.queryBalance(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryBalance(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<QueryBalanceModel>.self)
        .validate()
        .subscribe(onSuccess: { [unowned self] (model) in
@@ -52,7 +52,7 @@
    func payTaxiOrder(type:PayTypeNormal? = nil)  {
        requestSubject.onNext(.loading)
            APIManager.shared.provider.rx
            .request(.payTaxiOrder(orderId: orderId.value, payType: payType.value,orderType: orderType.value.parame(), couponId: couponId.value,objectType:couponDataType.value))
            .request(.payTaxiOrder(orderId: orderId.value, payType: payType.value,orderType: orderType.value.rawValue, couponId: couponId.value,objectType:couponDataType.value))
            .map(YYModel<PayModel>.self)
            .validate()
            .subscribe(onSuccess: { [unowned self] (model) in
OKProject/Class/Home/ViewModel/TravelServiceViewModel.swift
@@ -95,7 +95,7 @@
    func queryTrack()  {
        queryTrackSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.queryTrack(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryTrack(orderId: orderId.value, orderType: orderType.value.rawValue))
            .map(YYModel<[TrackModel]>.self)
            .validate()
            .subscribe(onSuccess: { [unowned self] (model) in
@@ -111,7 +111,7 @@
    /// 获取详情
    func queryOrderInfo()  {
        APIManager.shared.provider.rx
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<TravelServiceModel>.self)
        .validate()
        .subscribe(onSuccess: {  (model) in
@@ -127,7 +127,7 @@
    func cancleOrderTaxi()  {
        cancleOrderTaxiSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.cancleOrderTaxi(cancleId: cancelId.value, id: orderId.value,orderType: orderType.value.parame(), payType: payType.value))
            .request(.cancleOrderTaxi(cancleId: cancelId.value, id: orderId.value,orderType: orderType.value.rawValue, payType: payType.value))
        .map(YYModel<PayModel>.self)
        .validate()
        .subscribe(onSuccess: { [unowned self] (model) in
@@ -142,7 +142,7 @@
    func addCancle()  {
        addCancleSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.addCancle(id: orderId.value, orderType: orderType.value.parame(), reason: reason.value, remark: remark.value))
            .request(.addCancle(id: orderId.value, orderType: orderType.value.rawValue, reason: reason.value, remark: remark.value))
        .map(YYModel<SystemMessageModel>.self)
        .validate()
        .subscribe(onSuccess: { [unowned self] (model) in
@@ -158,12 +158,12 @@
    /// 获取司机位置
    func queryOrderServer()  {
        APIManager.shared.provider.rx
            .request(.queryOrderServer(orderId: self.orderId.value, orderType: orderType.value.parame()))
            .request(.queryOrderServer(orderId: self.orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<SocketInfoModel>.self)
        .validate()
        .subscribe(onSuccess: {  (model) in
            guard let data = model.data else{return}
            if data.orderType == self.orderType.value.parame(){
            if data.orderType == self.orderType.value.rawValue{
                self.driverInfo.accept(data)
            }
        }) { (error) in
@@ -175,7 +175,7 @@
    func orderEvaluate()  {
        evaluateSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.orderEvaluate(orderId: self.orderId.value, orderType: orderType.value.parame(), fraction: fraction.value, content: content.value))
            .request(.orderEvaluate(orderId: self.orderId.value, orderType: orderType.value.rawValue, fraction: fraction.value, content: content.value))
        .map(YYModel<Nothing>.self)
        .validate()
        .subscribe(onSuccess: {[unowned self]  (model) in
@@ -190,7 +190,7 @@
    func queryRedMoney()  {
        queryRedMoneySubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.queryRedMoney(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryRedMoney(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<CancleAmountModel>.self)
        .validate()
        .subscribe(onSuccess: {[unowned self]  (model) in
@@ -205,7 +205,7 @@
    func pushOrderTaxi() {
        pushOrderTaxiTaxiSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.pushOrderTaxi(id: orderId.value,orderType: orderType.value.parame()))
            .request(.pushOrderTaxi(id: orderId.value,orderType: orderType.value.rawValue))
        .map(YYModel<TravelServiceModel>.self)
        .validate()
        .subscribe(onSuccess: { [unowned self] (model) in
@@ -221,7 +221,7 @@
    func queryCancleAmount()  {
        queryCancleAmountSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.queryCancleAmount(id: orderId.value,orderType: orderType.value.parame()))
            .request(.queryCancleAmount(id: orderId.value,orderType: orderType.value.rawValue))
        .map(YYModel<CancleAmountModel>.self)
        .validate()
        .subscribe(onSuccess: { [unowned self] (model) in
@@ -253,7 +253,7 @@
    func shareRedEnvelope()  {
        shareRedEnvelopeSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.shareRedEnvelope(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.shareRedEnvelope(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<Nothing>.self)
        .validate()
        .subscribe(onSuccess: {[unowned self]  (model) in
@@ -268,7 +268,7 @@
    func completeOrder()  {
        completeOrderSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.completeOrder(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.completeOrder(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<Nothing>.self)
        .validate()
        .subscribe(onSuccess: {[unowned self]  (model) in
@@ -283,7 +283,7 @@
    func queryEndPush()  {
        queryEndPushSubject.onNext(.loading)
        APIManager.shared.provider.rx
            .request(.queryEndPush(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryEndPush(orderId: orderId.value, orderType: orderType.value.rawValue))
        .map(YYModel<SocketInfoModel>.self)
        .validate()
        .subscribe(onSuccess: {[unowned self]  (model) in
OKProject/Class/Home/ViewModel/TravelViewModel.swift
@@ -66,7 +66,7 @@
                }else{
                    // 查找数据
                    let model = data.filter { (model) -> Bool in
                        return model.orderType == self.orderType.value.parame()
                        return model.orderType == self.orderType.value.rawValue
                    }
                    if model.count == 0{
                        self.queryIdleDriver()
@@ -85,7 +85,7 @@
    /// 获取5公里范围内空闲司机数量
    func queryIdleDriver() {
        APIManager.shared.provider.rx
            .request(.queryIdleDriver(lat: Double(YYMapViewManager.share.userLocation.latitude), lon: Double(YYMapViewManager.share.userLocation.longitude), type: orderType.value.parame()))
            .request(.queryIdleDriver(lat: Double(YYMapViewManager.share.userLocation.latitude), lon: Double(YYMapViewManager.share.userLocation.longitude), type: orderType.value.rawValue))
            .map(YYModel<SwitchCityModel>.self)
            .validate()
            .subscribe(onSuccess: {[unowned self]  (model) in
OKProject/Class/Home/ViewModel/YYCostDetailViewModel.swift
@@ -23,7 +23,7 @@
    func queryOrderInfo() -> Observable<Result<TravelServiceModel?, Error>>  {
        return
            APIManager.shared.provider.rx
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(TravelServiceModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
OKProject/Class/LeftMenu/ViewModel/AgreementViewModel.swift
@@ -46,6 +46,7 @@
    case carRent
    case carSale
    case scenic
    func parame() -> Int {
        switch self {
        case .privacy:
@@ -82,6 +83,8 @@
                return 19
            case .carSale:
                return 20
            case .scenic:
                return 22
        }
    }
    
@@ -121,6 +124,8 @@
                return "汽车出租协议"
            case .question:
                return "常见问题"
            case .scenic:
                return "景区直通车"
        }
    }
}
OKProject/Class/Logistics(小件物流)/Controllers/ChooseItemTypeVC.swift
@@ -198,7 +198,7 @@
        model.startLat = lat
        model.address = info.address
        model.addressDeatil = info.addressDeatil
        model.type = orderType.value.parame()
        model.type = orderType.value.rawValue
        model.isFirst = priceModel.first
        
        let vc = ShippingInformationVC()
OKProject/Class/Logistics(小件物流)/Controllers/LogisticsListVC.swift
@@ -14,7 +14,7 @@
    /// viewModel
    let viewModel = TaxiOrderViewModel()
    
    init(orderType: Int) {
    init(orderType: OrderType) {
        super.init(nibName: nil, bundle: nil)
        viewModel.type.accept(orderType)
    }
@@ -69,7 +69,7 @@
        let model = viewModel.dataSource.value[sender.tag]
        alert(popup: .double, title: "提示", text: "您确定要取消该订单吗?", submitTitle: "确定取消", cancelTitle: "不取消", submitClick: { [weak self]  in
            guard let self = self else{return}
            if self.viewModel.type.value == 4 || self.viewModel.type.value == 5 {
            if self.viewModel.type.value == .cityLogistics || self.viewModel.type.value == .acrossLogistics {
                self.cancelPay(model: model)
            }else {
                self.cancelCharter(model: model)
@@ -187,7 +187,7 @@
    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
        let cell = tableView.dequeueReusableCell(withIdentifier: "item", for: indexPath) as! LogisticsListCell
        cell.selectionStyle = .none
        if viewModel.type.value == 5 || viewModel.type.value == 4 {
        if viewModel.type.value == .acrossLogistics || viewModel.type.value == .cityLogistics {
            cell.cancle_bt.tag = indexPath.row
            cell.cancle_bt.addTarget(self, action: #selector(cancle(sender:)), for: .touchUpInside)
            cell.pay_bt.tag = indexPath.row
OKProject/Class/Logistics(小件物流)/Controllers/ShippingInformationVC.swift
@@ -80,7 +80,7 @@
        view.needsUpdateConstraints()
        viewModel.logisticsQueryPayMoney(endAddress: model!.address+model!.addressDeatil, number: model!.cargoNumber, startLonLat: "\(model!.startLon),\(model!.startLat)", type: orderType.value.parame()).subscribe { (data) in
        viewModel.logisticsQueryPayMoney(endAddress: model!.address+model!.addressDeatil, number: model!.cargoNumber, startLonLat: "\(model!.startLon),\(model!.startLat)", type: orderType.value.rawValue).subscribe { (data) in
            YYAlertKit.dismiss()
            switch data{
            case .success( let data):
OKProject/Class/Logistics(小件物流)/ViewModels/LositcsViewModel.swift
@@ -36,7 +36,7 @@
    ///  获取价格 
    func queryLogisticsUnitPrice()-> Observable<Result<LogisticsModel?,Error>>{
        return APIManager.shared.provider.rx
            .request(.queryLogisticsUnitPrice(endAddress: endAddress.value, startLonLat: startLonLat.value, type: type.value.parame()))
            .request(.queryLogisticsUnitPrice(endAddress: endAddress.value, startLonLat: startLonLat.value, type: type.value.rawValue))
            .mapThenValidate(LogisticsModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
OKProject/Class/Order/Controller/MyOrderListVC.swift
@@ -93,24 +93,25 @@
        let name = menu[Int(pageIndex)]
        switch name {
        case "出租车":
            let vc = TaxiOrderListVC.init(orderType: 2)
                let vc = TaxiOrderListVC.init(orderType: .taxi)
            return vc
        case "快车":
            let vc = TaxiOrderListVC.init(orderType: 1)
        case "快车/专车":
                let vc = TaxiOrderListVC.init(orderType: .special)
            return vc
        case "机场专线":
            let vc = TaxiOrderListVC.init(orderType: 3)
                let vc = TaxiOrderListVC.init(orderType: .plane)
            return vc
        case "景区直通车":
            var vc:LogisticsListVC?
                //LogisticsListVC
            var vc:TaxiOrderListVC?
            if vc == nil {
                vc = LogisticsListVC.init(orderType: 4)
                vc = TaxiOrderListVC.init(orderType: .scenic)
            }
            return vc!
        case "公务出行":
            var vc:LogisticsListVC?
            if vc == nil {
                vc = LogisticsListVC.init(orderType: 5)
                vc = LogisticsListVC.init(orderType: .offical)
            }
            return vc!
//        case "包车":
OKProject/Class/Order/Controller/TaxiOrderListVC.swift
@@ -16,7 +16,7 @@
    /// viewModel
    let viewModel = TaxiOrderViewModel()
    
    init(orderType: Int) {
    init(orderType: OrderType) {
        super.init(nibName: nil, bundle: nil)
        viewModel.type.accept(orderType)
    }
@@ -78,21 +78,37 @@
    
    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
        let data = viewModel.dataSource.value[indexPath.row]
        // 8=待评价,9=已完成
        if data.state == 8 || data.state == 9{
            // 新的界面 有轨迹
            let vc = TaxiOrderDetailsVC.init(orderId: data.orderId, orderType: OrderType(rawValue: viewModel.type.value) ?? .taxi)
            let vc = TaxiOrderDetailsVC.init(orderId: data.orderId, orderType: viewModel.type.value)
            self.yy_push(vc: vc) 
        }else{
            // 订单流程界面
            if self.viewModel.type.value == 1{
            if self.viewModel.type.value == .special{
                var isCarpool:Bool = false
                if data.rideType == .seating{isCarpool = true}
                let vc = YYSpecialCarViewController.init(orderId: data.orderId,isCarpool: isCarpool)
                vc.viewModel.orderType.accept(.special)
                self.yy_push(vc: vc)
            }else if self.viewModel.type.value == 3{
            }else if viewModel.type.value == .scenic{
                if data.state == 7{
                    let vc = TravelOrderSuccessVC()
                    vc.id.accept(data.orderId)
                    vc.statusType = .MyOrder
                    yy_push(vc: vc)
                    return
                }
                let vc = TravelServiceVC(orderId: data.orderId, orderType: .scenic)
                wy_pushAnimate(vc: vc)
//                let vc = YYSpecialCarViewController.init(orderId: data.orderId)
//                vc.viewModel.orderType.accept(.scenic)
//                self.yy_push(vc: vc)
            }else if self.viewModel.type.value == .travel{
                if data.state == 7 {
                    //待支付
                    let vc = TravelOrderSuccessVC()
@@ -112,7 +128,7 @@
                vc.viewModel.orderType.accept(.travel)
                self.yy_push(vc: vc)
            }else{
                let vc = TravelServiceVC.init(orderId: data.orderId, orderType: OrderType(rawValue: viewModel.type.value) ?? .taxi)
                let vc = TravelServiceVC.init(orderId: data.orderId, orderType: viewModel.type.value)
                self.yy_push(vc: vc)
            }
        }
OKProject/Class/Order/ViewModel/TaxiOrderViewModel.swift
@@ -13,10 +13,10 @@
class TaxiOrderViewModel: YYRefreshViewModel<TaxiOrderModel> {
    
    /// 订单类型(1=快车,2=出租车,3=跨城出行)
    let type = BehaviorRelay<Int>(value: 1)
    let type = BehaviorRelay<OrderType>(value: .taxi)
    override func api() -> API! {
        return .queryMyOrderList(type: type.value, pageNum: currentPage, size: totalPages)
        return .queryMyOrderList(type: type.value.rawValue, pageNum: currentPage, size: totalPages)
    }
    
}
@@ -34,10 +34,10 @@
class TravelMyCardViewModel:YYRefreshViewModel<CouponListModel> {
    let type = BehaviorRelay<Int>(value: 1)
    let type = BehaviorRelay<OrderType>(value: .special)
    override func api() -> API! {
        return .getMyTaxiCardList(orderType: OrderType(rawValue: type.value)!)
        return .getMyTaxiCardList(orderType: type.value)
    }
}
OKProject/Class/SpecialCar/Controller/YYSpecialCarFlowViewController.swift
@@ -157,7 +157,7 @@
            .rx.tap
            .subscribe(onNext: { (_) in
            // 弹出分享框
                ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行快车(\(self.viewModel.dataSource.value?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.parame())",hiddenMessage: false).show(success: {
                ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行快车(\(self.viewModel.dataSource.value?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.rawValue)",hiddenMessage: false).show(success: {
                
            })
        }).disposed(by: disposeBag)
@@ -211,7 +211,7 @@
        YYSocketManager.shared().position
            .subscribe(onNext: {[unowned self] (r) in
                guard let data = r.data else{return}
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.parame(){
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.rawValue{
                    self.updateDriverLocation(data: data)
                }
            }).disposed(by: rx.disposeBag)
OKProject/Class/SpecialCar/Controller/YYSpecialCarpoolingCarFlowViewController.swift
@@ -284,7 +284,7 @@
            .rx.tap
            .subscribe(onNext: { (_) in
            // 弹出分享框
                ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行快车(\(self.viewModel.dataSource.value?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.parame())",hiddenMessage: false).show(success: {
                ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行快车(\(self.viewModel.dataSource.value?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.rawValue)",hiddenMessage: false).show(success: {
            })
        }).disposed(by: disposeBag)
@@ -338,7 +338,7 @@
        YYSocketManager.shared().position
            .subscribe(onNext: {[unowned self] (r) in
                guard let data = r.data else{return}
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.parame(){
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.rawValue{
                    self.updateDriverLocation(data: data)
                }
OKProject/Class/SpecialCar/View/YYTravelInfosView.swift
@@ -62,7 +62,7 @@
            complain_driverBt.isHidden = false
        }
        // 跨城
        if viewModel?.orderType.value.parame() == 3 || model?.orderType == 3{
        if viewModel?.orderType.value == .travel || model?.orderType == 3{
            userInfo_view.isHidden = false
            complain_driverBt.isHidden = true
        }
OKProject/Class/SpecialCar/ViewModel/YYSpecialCarViewModel.swift
@@ -75,7 +75,7 @@
        
        return
            APIManager.shared.provider.rx
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryOrderInfo(orderId: orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(YYSpecialCarModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -85,7 +85,7 @@
    /// 取消订单获取金额
    func queryCancleAmount()  -> Observable<Result<CancleAmountModel?, Error>> {
        return APIManager.shared.provider.rx
            .request(.queryCancleAmount(id: orderId.value,orderType: orderType.value.parame()))
            .request(.queryCancleAmount(id: orderId.value,orderType: orderType.value.rawValue))
            .mapThenValidate(CancleAmountModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -113,7 +113,7 @@
    func queryOrderServer() -> Observable<Result<SocketInfoModel?, Error>> {
        return
            APIManager.shared.provider.rx
            .request(.queryOrderServer(orderId: self.orderId.value, orderType: orderType.value.parame()))
            .request(.queryOrderServer(orderId: self.orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(SocketInfoModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -123,7 +123,7 @@
    func queryEndPush() -> Observable<Result<SocketInfoModel?, Error>> {
        return
            APIManager.shared.provider.rx
            .request(.queryEndPush(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.queryEndPush(orderId: orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(SocketInfoModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -134,7 +134,7 @@
    func pushOrder() -> Observable<Result<TravelServiceModel?, Error>> {
        return
            APIManager.shared.provider.rx
            .request(.pushOrderTaxi(id: orderId.value, orderType: orderType.value.parame()))
            .request(.pushOrderTaxi(id: orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(TravelServiceModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -144,7 +144,7 @@
    func orderEvaluate() -> Observable<Result<Nothing?, Error>>  {
        return
            APIManager.shared.provider.rx
            .request(.orderEvaluate(orderId: self.orderId.value, orderType: orderType.value.parame(), fraction: fraction.value, content: content.value))
            .request(.orderEvaluate(orderId: self.orderId.value, orderType: orderType.value.rawValue, fraction: fraction.value, content: content.value))
            .mapThenValidate(Nothing.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -176,7 +176,7 @@
    func queryRedMoney()  -> Observable<Result<CancleAmountModel?, Error>> {
        return
            APIManager.shared.provider.rx
            .request(.queryRedMoney(orderId: orderId.value,orderType: orderType.value.parame()))
            .request(.queryRedMoney(orderId: orderId.value,orderType: orderType.value.rawValue))
            .mapThenValidate(CancleAmountModel.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
@@ -185,7 +185,7 @@
    /// 评论成功后获取红包金额
    func shareRedEnvelope()  -> Observable<Result<Nothing?, Error>> {
        APIManager.shared.provider.rx
            .request(.shareRedEnvelope(orderId: orderId.value, orderType: orderType.value.parame()))
            .request(.shareRedEnvelope(orderId: orderId.value, orderType: orderType.value.rawValue))
            .mapThenValidate(Nothing.self)
            .catchError { Single.just(.failure($0)) }
            .asObservable()
OKProject/Class/Taxi/Controller/ScanChooseTravelVC.swift
@@ -70,7 +70,7 @@
            vc.model = self.setDriverModel(model: data)
            self.yy_push(vc: vc)
        }else{
            let vc = ScanTravelVC(model: data, type: OrderType.type(id: id))
            let vc = ScanTravelVC(model: data, type: OrderType(rawValue: id)!)
            self.yy_push(vc: vc)
        }
    }
OKProject/Class/Taxi/Controller/TravelServiceVC.swift
@@ -447,7 +447,7 @@
        YYSocketManager.shared().position
            .subscribe(onNext: {[unowned self] (r) in
                guard let data = r.data else{return}
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.parame(){
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.rawValue{
                    self.updateDriverLocation(data: data)
                }
            }).disposed(by: rx.disposeBag)
@@ -465,7 +465,7 @@
                }
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.parame(){
                if data.orderId == self.viewModel.orderId.value && data.orderType == self.viewModel.orderType.value.rawValue{
                    guard let model = self.dataSource else{return}
                    if data.state < 7{
                        if data.state == 4{
@@ -539,7 +539,7 @@
        /// 分享
        button_share.rx.tap.subscribe(onNext: { (_) in
            // 弹出分享框
            ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行出租车(\(self.dataSource?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.parame())",hiddenMessage: false).show(success: {
            ShareView.share(controller: self, title: "分享行程", content: "你的好友(\(app.userInfo.phone))正在使用宽窄出行出租车(\(self.dataSource?.licensePlate ?? ""))。", url: "\(share_url)/orderShare/index.html?orderId=\(self.viewModel.orderId.value)&orderType=\(self.viewModel.orderType.value.rawValue)",hiddenMessage: false).show(success: {
                
            })
        }).disposed(by: disposeBag)
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelChooseCityVC.swift
@@ -26,7 +26,7 @@
    /// 筛选后的模型
    var screenModel = [TravleCityModel]()
    var pyData = [String]()
    var subType = 0
    var subType:OrderType = .taxi
    
    @IBOutlet weak var tableView: UITableView!
    override func viewDidLoad() {
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelCityHomeVC.swift
@@ -27,7 +27,7 @@
    var endModel = TravelSitesModel()
    var viewModel = TravelLineViewModel()
    var showCar = true
    var type = 0 //3=机场专线,7=景区直通车
    var type:OrderType = .taxi //9=机场专线,7=景区直通车,10=公务用车
    override func viewWillAppear(_ animated: Bool) {
@@ -42,7 +42,7 @@
        //74067 【特惠购卡】需根据返回的状态,是否显示 购卡模块、 我的商家中心模块
//        buyCardView.isHidden = !showCar
        if type == 3{
        if type == .travel{
            banner_imageView.image = UIImage(named: "banner")
        }else{
            banner_imageView.image = UIImage(named: "banner_1")
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelInstructionsView.swift
@@ -38,7 +38,7 @@
        return v
    }
    func loadData(){
        agreement.type.accept(.travel)
        agreement.type.accept(.scenic)
        agreement.agreement()
        agreement.requestSubject.subscribe { (r) in
            YYAlertKit.dismiss()
OKProject/Class/TravelAcrossCity(跨城)/Controller/TravelInstructionsView.xib
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="19455" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
    <device id="retina6_1" orientation="portrait" appearance="light"/>
    <dependencies>
        <deployment version="4352" identifier="iOS"/>
        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="19454"/>
        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21678"/>
        <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"/>
@@ -17,13 +17,13 @@
            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
            <subviews>
                <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="ZII-g6-c3Y">
                    <rect key="frame" x="0.0" y="44" width="414" height="818"/>
                    <rect key="frame" x="0.0" y="48" width="414" height="814"/>
                    <connections>
                        <action selector="dimssAction:" destination="iN0-l3-epB" eventType="touchUpInside" id="C05-nU-1mL"/>
                    </connections>
                </button>
                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="8f0-S8-9Wq">
                    <rect key="frame" x="48" y="191" width="318" height="372"/>
                    <rect key="frame" x="48" y="195" width="318" height="372"/>
                    <subviews>
                        <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="JPf-go-oHo">
                            <rect key="frame" x="0.0" y="34" width="318" height="292"/>
@@ -90,7 +90,7 @@
    </objects>
    <resources>
        <namedColor name="Color">
            <color red="0.0" green="0.74900001287460327" blue="0.18799999356269836" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
            <color red="0.27099999785423279" green="0.70599997043609619" blue="0.57999998331069946" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
        </namedColor>
        <systemColor name="systemBackgroundColor">
            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
OKProject/Class/TravelAcrossCity(跨城)/ViewModels/TravelCityViewModel.swift
@@ -14,7 +14,7 @@
    var type = BehaviorRelay<TravelChooseCityType>(value: .start)
    /// 起点站点id
    var startSiteId = BehaviorRelay<String>.init(value: "")
    var subType = BehaviorRelay<Int>(value: 0)
    var subType = BehaviorRelay<OrderType>(value: .taxi)
    /// 拼音数组
    var pyData = BehaviorRelay<[String]>(value: [])
    var data = BehaviorRelay<[TravleCityModel]>.init(value:[])
@@ -23,7 +23,7 @@
    func getStartSite(){
        subject.onNext(.loading)
        if type.value == .start {
            APIManager.shared.provider.rx.request(.siteQuerySite(startSiteId: "", type: subType.value)).map(YYModel<[TravleCityModel]>.self).validate().subscribe {[unowned self] (r) in
            APIManager.shared.provider.rx.request(.siteQuerySite(startSiteId: "", type: subType.value.rawValue)).map(YYModel<[TravleCityModel]>.self).validate().subscribe {[unowned self] (r) in
                guard let model = r.data else { return}
                /// 处理拼音
                for (_,vaule) in model.enumerated(){
@@ -38,7 +38,7 @@
                self.subject.onNext(.error(e))
            }.disposed(by: disposeBag)
        }else{
            APIManager.shared.provider.rx.request(.siteQuerySite(startSiteId: startSiteId.value, type: subType.value)).map(YYModel<[TravleCityModel]>.self).validate().subscribe {[unowned self] (r) in
            APIManager.shared.provider.rx.request(.siteQuerySite(startSiteId: startSiteId.value, type: subType.value.rawValue)).map(YYModel<[TravleCityModel]>.self).validate().subscribe {[unowned self] (r) in
                guard let model = r.data else { return}
                /// 处理拼音
                for (_,vaule) in model.enumerated(){