接单页面:拒单增加弹窗提示
This commit is contained in:
@@ -62,6 +62,7 @@
|
||||
79FB75FC2A9C3BEE00DB00A4 /* OrderSchedulingNotificationService.appex in Embed Foundation Extensions */ = {isa = PBXBuildFile; fileRef = 79FB75F52A9C3BEE00DB00A4 /* OrderSchedulingNotificationService.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; };
|
||||
79FB76102A9C6CAF00DB00A4 /* newJuheOrderAudio.wav in Resources */ = {isa = PBXBuildFile; fileRef = 79FB760E2A9C6CAF00DB00A4 /* newJuheOrderAudio.wav */; };
|
||||
79FB76132A9C6CC100DB00A4 /* newOrderAudio.wav in Resources */ = {isa = PBXBuildFile; fileRef = 79FB76122A9C6CC100DB00A4 /* newOrderAudio.wav */; };
|
||||
79FB76152A9DEE7400DB00A4 /* RefuseOrderConfirmView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 79FB76142A9DEE7400DB00A4 /* RefuseOrderConfirmView.swift */; };
|
||||
A64E95F00B82DC28C2B9306E /* libPods-OrderScheduling.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 98784A61C325B3D6C408016C /* libPods-OrderScheduling.a */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
@@ -169,6 +170,7 @@
|
||||
79FB76052A9C606100DB00A4 /* OrderSchedulingNotificationService.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = OrderSchedulingNotificationService.entitlements; sourceTree = "<group>"; };
|
||||
79FB760E2A9C6CAF00DB00A4 /* newJuheOrderAudio.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = newJuheOrderAudio.wav; sourceTree = "<group>"; };
|
||||
79FB76122A9C6CC100DB00A4 /* newOrderAudio.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = newOrderAudio.wav; sourceTree = "<group>"; };
|
||||
79FB76142A9DEE7400DB00A4 /* RefuseOrderConfirmView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RefuseOrderConfirmView.swift; sourceTree = "<group>"; };
|
||||
9758FDE3BEDA5A983CAE2DED /* Pods-OrderSchedulingNotificationService.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OrderSchedulingNotificationService.debug.xcconfig"; path = "Target Support Files/Pods-OrderSchedulingNotificationService/Pods-OrderSchedulingNotificationService.debug.xcconfig"; sourceTree = "<group>"; };
|
||||
98784A61C325B3D6C408016C /* libPods-OrderScheduling.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-OrderScheduling.a"; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
BD034FA1DD7C17CCBA6B0E5D /* Pods-OrderScheduling.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OrderScheduling.release.xcconfig"; path = "Target Support Files/Pods-OrderScheduling/Pods-OrderScheduling.release.xcconfig"; sourceTree = "<group>"; };
|
||||
@@ -229,6 +231,7 @@
|
||||
791887752A7CD633007EA0C1 /* View */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
79FB76142A9DEE7400DB00A4 /* RefuseOrderConfirmView.swift */,
|
||||
791887C02A839784007EA0C1 /* RefuseOrderEntryView.swift */,
|
||||
79FB75ED2A9898EB00DB00A4 /* AcceptOrderView.swift */,
|
||||
79FB75EF2A98A26C00DB00A4 /* AcceptOrderTool.swift */,
|
||||
@@ -905,6 +908,7 @@
|
||||
79DD0DB42A95F00B00768FE7 /* Extension.swift in Sources */,
|
||||
791887802A7CE6F1007EA0C1 /* UserDefaultStrings.swift in Sources */,
|
||||
79FB75EC2A988EC000DB00A4 /* MessageCenterTool.swift in Sources */,
|
||||
79FB76152A9DEE7400DB00A4 /* RefuseOrderConfirmView.swift in Sources */,
|
||||
79DD0DB12A94B3DB00768FE7 /* EmptyView.swift in Sources */,
|
||||
79DD0DAA2A9481BC00768FE7 /* NotificationAuthTool.swift in Sources */,
|
||||
794FBB1C2A8F4DE900D57BB8 /* MessageView.swift in Sources */,
|
||||
|
||||
Binary file not shown.
@@ -317,8 +317,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "551"
|
||||
endingLineNumber = "551"
|
||||
startingLineNumber = "570"
|
||||
endingLineNumber = "570"
|
||||
landmarkName = "tableView(_:cellForRowAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -333,8 +333,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "552"
|
||||
endingLineNumber = "552"
|
||||
startingLineNumber = "571"
|
||||
endingLineNumber = "571"
|
||||
landmarkName = "tableView(_:cellForRowAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -497,22 +497,6 @@
|
||||
</Locations>
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
uuid = "8A520E4B-3151-4F18-B59F-FFB529DEDA59"
|
||||
shouldBeEnabled = "No"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "634"
|
||||
endingLineNumber = "634"
|
||||
landmarkName = "tableView(_:cellForRowAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
@@ -539,8 +523,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "784"
|
||||
endingLineNumber = "784"
|
||||
startingLineNumber = "801"
|
||||
endingLineNumber = "801"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -555,8 +539,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "785"
|
||||
endingLineNumber = "785"
|
||||
startingLineNumber = "802"
|
||||
endingLineNumber = "802"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -1737,8 +1721,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "221"
|
||||
endingLineNumber = "221"
|
||||
startingLineNumber = "237"
|
||||
endingLineNumber = "237"
|
||||
landmarkName = "entry(model:remarkId:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -2771,8 +2755,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "781"
|
||||
endingLineNumber = "781"
|
||||
startingLineNumber = "798"
|
||||
endingLineNumber = "798"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -2787,8 +2771,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "779"
|
||||
endingLineNumber = "779"
|
||||
startingLineNumber = "796"
|
||||
endingLineNumber = "796"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@@ -2803,8 +2787,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "780"
|
||||
endingLineNumber = "780"
|
||||
startingLineNumber = "797"
|
||||
endingLineNumber = "797"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
<Locations>
|
||||
@@ -2979,8 +2963,8 @@
|
||||
filePath = "OrderScheduling/Rescue/ViewController/RescueController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "797"
|
||||
endingLineNumber = "797"
|
||||
startingLineNumber = "814"
|
||||
endingLineNumber = "814"
|
||||
landmarkName = "collectionView(_:didSelectItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
|
||||
BIN
OrderScheduling/.DS_Store
vendored
BIN
OrderScheduling/.DS_Store
vendored
Binary file not shown.
@@ -14,6 +14,50 @@ public let ENTRY = Entry.default
|
||||
open class Entry {
|
||||
public static let `default` = Entry()
|
||||
|
||||
public func showRefuseOrderConfirmEntry(view:UIView,name:String? = nil){
|
||||
var attributes = EKAttributes()
|
||||
attributes = .centerFloat
|
||||
attributes.name = name
|
||||
attributes.precedence = .override(priority: .min, dropEnqueuedEntries: false)
|
||||
attributes.displayMode = .inferred
|
||||
attributes.displayDuration = .infinity
|
||||
attributes.screenBackground = .color(color: .clear)
|
||||
attributes.entryBackground = .color(color: .white)
|
||||
attributes.screenInteraction = .absorbTouches
|
||||
attributes.entryInteraction = .absorbTouches
|
||||
attributes.scroll = .disabled
|
||||
attributes.entranceAnimation = .init(
|
||||
translate: .init(
|
||||
duration: 0.25,
|
||||
spring: .init(damping: 1, initialVelocity: 0)
|
||||
)
|
||||
)
|
||||
attributes.exitAnimation = .init(
|
||||
translate: .init(duration: 0.25)
|
||||
)
|
||||
attributes.popBehavior = .animated(
|
||||
animation: .init(
|
||||
translate: .init(duration: 0.25)
|
||||
)
|
||||
)
|
||||
attributes.shadow = .active(
|
||||
with: .init(
|
||||
color: .black,
|
||||
opacity: 0.3,
|
||||
radius: 6
|
||||
)
|
||||
)
|
||||
attributes.positionConstraints.size = .init(
|
||||
width: .constant(value: auto(280)),
|
||||
height: .constant(value: auto(130))
|
||||
)
|
||||
attributes.positionConstraints.verticalOffset = 0
|
||||
attributes.positionConstraints.safeArea = .overridden
|
||||
attributes.positionConstraints.rotation.isEnabled = false
|
||||
attributes.statusBar = .light
|
||||
SwiftEntryKit.display(entry: view, using: attributes)
|
||||
}
|
||||
|
||||
public func showRefuseOrderEntry(view:UIView,name:String? = nil){
|
||||
var attributes = EKAttributes()
|
||||
attributes = .centerFloat
|
||||
@@ -106,7 +150,7 @@ open class Entry {
|
||||
var attributes = EKAttributes()
|
||||
attributes = .centerFloat
|
||||
attributes.name = name
|
||||
attributes.precedence = .override(priority: .high, dropEnqueuedEntries: false)
|
||||
attributes.precedence = .override(priority: .low, dropEnqueuedEntries: false)
|
||||
attributes.displayMode = .inferred
|
||||
attributes.displayDuration = .infinity
|
||||
attributes.screenBackground = .color(color: .clear)
|
||||
@@ -148,7 +192,7 @@ open class Entry {
|
||||
var attributes = EKAttributes()
|
||||
attributes = .centerFloat
|
||||
attributes.name = name
|
||||
attributes.precedence = .override(priority: .low, dropEnqueuedEntries: false)
|
||||
attributes.precedence = .override(priority: .min, dropEnqueuedEntries: false)
|
||||
attributes.displayMode = .inferred
|
||||
attributes.displayDuration = .infinity
|
||||
attributes.screenBackground = .color(color: .clear)
|
||||
|
||||
120
OrderScheduling/Rescue/View/RefuseOrderConfirmView.swift
Normal file
120
OrderScheduling/Rescue/View/RefuseOrderConfirmView.swift
Normal file
@@ -0,0 +1,120 @@
|
||||
//
|
||||
// RefuseOrderConfirmView.swift
|
||||
// OrderScheduling
|
||||
//
|
||||
// Created by 中道 on 2023/8/29.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import DDControlsKit_Private
|
||||
import SnapKit
|
||||
import DDAutoUIKit_Private
|
||||
|
||||
open class RefuseOrderConfirmView : DDView {
|
||||
private let radiusView : DDView
|
||||
private let scrollView : DDScrollView
|
||||
private let scrollContentView : DDView
|
||||
public let titleLabel : DDLabel
|
||||
public let contentLabel : DDLabel
|
||||
public let horizontalLine : DDView
|
||||
public let verticalLine : DDView
|
||||
public let cancelButton : DDButton
|
||||
public let sureButton : DDButton
|
||||
public override init(frame: CGRect) {
|
||||
radiusView = DDView.init()
|
||||
scrollView = DDScrollView()
|
||||
scrollContentView = DDView.init()
|
||||
titleLabel = DDLabel.dd_init(withText: "", font: .mediumFont(auto(16)), textColor: .black)
|
||||
contentLabel = DDLabel.dd_init(withText: "", font: .mediumFont(auto(14)), textColor: .hex("203053"))
|
||||
horizontalLine = DDView()
|
||||
verticalLine = DDView()
|
||||
cancelButton = DDButton.dd_initCustom()
|
||||
sureButton = DDButton.dd_initCustom()
|
||||
super.init(frame: frame)
|
||||
radiusView.layer.cornerRadius = auto(10)
|
||||
radiusView.layer.masksToBounds = true
|
||||
addSubview(radiusView)
|
||||
radiusView.addSubview(scrollView)
|
||||
scrollView.addSubview(scrollContentView)
|
||||
radiusView.addSubview(titleLabel)
|
||||
contentLabel.numberOfLines = 0
|
||||
contentLabel.textAlignment = .center
|
||||
contentLabel.text = "确认取消订单吗?"
|
||||
scrollContentView.addSubview(contentLabel)
|
||||
horizontalLine.backgroundColor = .hex("979797").alpha(0.35)
|
||||
radiusView.addSubview(horizontalLine)
|
||||
verticalLine.backgroundColor = .hex("979797").alpha(0.35)
|
||||
radiusView.addSubview(verticalLine)
|
||||
cancelButton.titleLabel?.font = .mediumFont(auto(14))
|
||||
cancelButton.backgroundColor = .white
|
||||
cancelButton.setTitleColor(.black.alpha(0.3), for: .normal)
|
||||
cancelButton.setTitle("取消", for: .normal)
|
||||
radiusView.addSubview(cancelButton)
|
||||
sureButton.titleLabel?.font = .mediumFont(auto(14))
|
||||
sureButton.backgroundColor = .white
|
||||
sureButton.setTitleColor(.white, for: .normal)
|
||||
sureButton.setTitle("确定", for: .normal)
|
||||
sureButton.backgroundColor = .hex("1C62D9")
|
||||
radiusView.addSubview(sureButton)
|
||||
|
||||
radiusView.snp.makeConstraints { make in
|
||||
make.edges.equalToSuperview()
|
||||
}
|
||||
|
||||
titleLabel.snp.makeConstraints { make in
|
||||
make.centerX.equalToSuperview()
|
||||
make.top.equalToSuperview().offset(auto(20))
|
||||
}
|
||||
|
||||
scrollView.snp.makeConstraints { make in
|
||||
make.top.equalTo(titleLabel.snp.bottom).offset(auto(10))
|
||||
make.left.right.equalToSuperview()
|
||||
make.bottom.equalTo(horizontalLine.snp.top).offset(0)
|
||||
}
|
||||
|
||||
scrollContentView.snp.makeConstraints { make in
|
||||
make.edges.equalToSuperview()
|
||||
make.width.equalToSuperview()
|
||||
}
|
||||
|
||||
contentLabel.snp.makeConstraints { make in
|
||||
make.left.equalToSuperview().offset(auto(20))
|
||||
make.top.equalToSuperview()
|
||||
make.right.equalTo(-auto(20))
|
||||
make.height.greaterThanOrEqualTo(auto(40))
|
||||
make.bottom.equalTo(scrollContentView)
|
||||
}
|
||||
|
||||
horizontalLine.snp.makeConstraints { make in
|
||||
make.bottom.equalToSuperview().offset(-auto(40))
|
||||
make.left.right.equalToSuperview()
|
||||
make.height.equalTo(1)
|
||||
}
|
||||
|
||||
verticalLine.snp.makeConstraints { make in
|
||||
make.centerX.equalToSuperview()
|
||||
make.top.equalTo(horizontalLine.snp.bottom)
|
||||
make.bottom.equalToSuperview()
|
||||
make.width.equalTo(1)
|
||||
}
|
||||
|
||||
cancelButton.snp.makeConstraints { make in
|
||||
make.bottom.equalToSuperview()
|
||||
make.left.equalToSuperview()
|
||||
make.top.equalTo(horizontalLine.snp.bottom)
|
||||
make.right.equalTo(verticalLine.snp.left)
|
||||
}
|
||||
|
||||
sureButton.snp.makeConstraints { make in
|
||||
make.bottom.equalToSuperview()
|
||||
make.right.equalToSuperview()
|
||||
make.top.equalTo(horizontalLine.snp.bottom)
|
||||
make.left.equalTo(verticalLine.snp.right)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public required init?(coder: NSCoder) {
|
||||
fatalError("init(coder:) has not been implemented")
|
||||
}
|
||||
}
|
||||
@@ -142,6 +142,22 @@ extension RescuePendingOrderController {
|
||||
|
||||
pendingOrderView.tableView.mj_header?.beginRefreshing()
|
||||
|
||||
refuseOrderConfirmView.cancelButton.rx.tap
|
||||
.subscribe(onNext: { _ in
|
||||
ENTRY.dismiss(name: refuseOrderConfirmEntry)
|
||||
})
|
||||
.disposed(by: disposeBag)
|
||||
|
||||
refuseOrderConfirmView.sureButton.rx.tap
|
||||
.subscribe(onNext: {[weak self] _ in
|
||||
ENTRY.dismiss(name: refuseOrderConfirmEntry) {[weak self] in
|
||||
if let model = self?.refuseOrderModel {
|
||||
self?.refuseRemarkIdRelay.accept(model)
|
||||
}
|
||||
}
|
||||
})
|
||||
.disposed(by: disposeBag)
|
||||
|
||||
refuseRemarkIdRelay
|
||||
.observe(on: MainScheduler.instance)
|
||||
.do(onNext: {[weak self] _ in
|
||||
@@ -474,7 +490,10 @@ extension RescuePendingOrderController : UITableViewDelegate,UITableViewDataSour
|
||||
|
||||
cell?.refuseButton.rx.tap
|
||||
.subscribe(onNext: {[weak self] _ in
|
||||
self?.refuseRemarkIdRelay.accept(model)
|
||||
if let refuseOrderConfirmView = self?.refuseOrderConfirmView {
|
||||
self?.refuseOrderModel = model
|
||||
ENTRY.showRefuseOrderConfirmEntry(view: refuseOrderConfirmView,name:refuseOrderConfirmEntry)
|
||||
}
|
||||
})
|
||||
.disposed(by: cell!.disposeBag)
|
||||
|
||||
@@ -630,9 +649,7 @@ extension RescuePendingDispatchController : UITableViewDelegate,UITableViewDataS
|
||||
cell?.photoView.snp.updateConstraints({ make in
|
||||
make.height.equalTo(auto(50))
|
||||
})
|
||||
if let environmentPics {
|
||||
cell?.photoCollectionView.reloadData()
|
||||
}
|
||||
cell?.photoCollectionView.reloadData()
|
||||
}else{
|
||||
cell?.photoTitleLabel.text = nil
|
||||
cell?.photoView.isHidden = true
|
||||
@@ -882,6 +899,8 @@ class RescueController : ZDViewController {
|
||||
class RescuePendingOrderController : ZDViewController {
|
||||
private let disposeBag = DisposeBag()
|
||||
public let pendingOrderView = RescuePendingOrderView()
|
||||
public let refuseOrderConfirmView = RefuseOrderConfirmView()
|
||||
public var refuseOrderModel : OrderListDataModel?
|
||||
private var resultArr : [OrderListDataModel] = []
|
||||
private var refreshRelay = ReplayRelay<Int>.create(bufferSize: 1)
|
||||
private var pageNum : Int = 1
|
||||
|
||||
@@ -9,6 +9,8 @@ import Foundation
|
||||
|
||||
public let refuseOrderEntry = "refuseOrderEntry"
|
||||
|
||||
public let refuseOrderConfirmEntry = "refuseOrderConfirmEntry"
|
||||
|
||||
public let appUpdateEntry = "appUpdateEntry"
|
||||
|
||||
public let notificationAuthViewEntry = "notificationAuthViewEntry"
|
||||
|
||||
Reference in New Issue
Block a user