dispute is pending until requested and chat disabled until acked

This commit is contained in:
woodser 2024-11-08 08:14:16 -05:00
parent 577cfa249e
commit 0d82f8827f
3 changed files with 7 additions and 1 deletions

View file

@ -466,6 +466,10 @@ public final class Dispute implements NetworkPayload, PersistablePayload {
return this.disputeState == State.NEW;
}
public boolean isOpen() {
return this.disputeState == State.OPEN || this.disputeState == State.REOPENED;
}
public boolean isClosed() {
return this.disputeState == State.CLOSED;
}

View file

@ -70,7 +70,7 @@ public abstract class DisputeSession extends SupportSession {
@Override
public boolean chatIsOpen() {
return dispute != null && !dispute.isClosed();
return dispute != null && dispute.isOpen();
}
@Override

View file

@ -1420,6 +1420,8 @@ public abstract class DisputeView extends ActivatableView<VBox, Void> implements
}
if (dispute.isClosed()) return Res.get("support.closed");
switch (trade.getDisputeState()) {
case NO_DISPUTE:
return Res.get("shared.pending");
case DISPUTE_REQUESTED:
return Res.get("support.requested");
default: