|
@@ -17,6 +17,10 @@ class SelfRecommendationViewController: BaseViewController {
|
|
|
|
|
|
var selfMentionAddressArray = Array<SelfMentionAddressModel>()
|
|
|
|
|
|
+
|
|
|
+ /// 获取自提点
|
|
|
+ var selfMentionAddressModel : SelfMentionAddressModel?
|
|
|
+
|
|
|
typealias DidSelectClosure = () -> Void
|
|
|
var didSelectClosure : DidSelectClosure?
|
|
|
|
|
@@ -65,8 +69,8 @@ class SelfRecommendationViewController: BaseViewController {
|
|
|
}
|
|
|
selfRecommendationView.didSelectGoShoppingBlock = { //去首页自提
|
|
|
[weak self] indexPath in
|
|
|
- let selfMentionAddressModel = self?.selfMentionAddressArray[indexPath.row]
|
|
|
- self?.userAddSelfAddressApi(cityId:selfMentionAddressModel?.cityId ?? 0,cityName: selfMentionAddressModel?.cityName ?? "",pickupNodeId:selfMentionAddressModel?.id ?? 0, address: selfMentionAddressModel?.address ?? "")
|
|
|
+ self?.selfMentionAddressModel = self?.selfMentionAddressArray[indexPath.row]
|
|
|
+ self?.userAddSelfAddressApi(cityId:self?.selfMentionAddressModel?.cityId ?? 0,cityName: self?.selfMentionAddressModel?.cityName ?? "",pickupNodeId:self?.selfMentionAddressModel?.id ?? 0, address: self?.selfMentionAddressModel?.address ?? "")
|
|
|
|
|
|
}
|
|
|
selfRecommendationView.changeLocationBlock = {
|
|
@@ -130,6 +134,7 @@ class SelfRecommendationViewController: BaseViewController {
|
|
|
SwiftMoyaNetWorkServiceUser.shared().userAddSelfAddressApi(cityId: cityId, cityName: cityName, pickupNodeId: pickupNodeId, address: address) {
|
|
|
[weak self] (data) -> (Void) in
|
|
|
let deliveryMethodTypeModel = DeliveryMethodTypeModel.shared().getModel()
|
|
|
+ SelfMentionAddressModel.setModel(model: (self?.selfMentionAddressModel)!)
|
|
|
if deliveryMethodTypeModel?.deliveryMethodType?.isEmpty ?? true {
|
|
|
self?.tabbarController(deliveryMethodType: "1")
|
|
|
}else {
|