mirror of
https://github.com/corda/corda.git
synced 2024-12-28 00:38:55 +00:00
Reduce diffs.
This commit is contained in:
parent
a8d7fe11ea
commit
c22614ae86
@ -4,7 +4,9 @@ import com.google.common.net.HostAndPort
|
||||
import javafx.beans.property.SimpleObjectProperty
|
||||
import net.corda.client.rpc.CordaRPCClient
|
||||
import net.corda.client.rpc.CordaRPCClientConfiguration
|
||||
import net.corda.core.flows.StateMachineRunId
|
||||
import net.corda.core.messaging.CordaRPCOps
|
||||
import net.corda.core.messaging.StateMachineInfo
|
||||
import net.corda.core.messaging.StateMachineUpdate
|
||||
import net.corda.core.node.services.NetworkMapCache.MapChange
|
||||
import net.corda.core.node.services.StateMachineTransactionMapping
|
||||
@ -14,6 +16,16 @@ import net.corda.core.transactions.SignedTransaction
|
||||
import rx.Observable
|
||||
import rx.subjects.PublishSubject
|
||||
|
||||
data class ProgressTrackingEvent(val stateMachineId: StateMachineRunId, val message: String) {
|
||||
companion object {
|
||||
fun createStreamFromStateMachineInfo(stateMachine: StateMachineInfo): Observable<ProgressTrackingEvent>? {
|
||||
return stateMachine.progressTrackerStepAndUpdates?.let { (current, future) ->
|
||||
future.map { ProgressTrackingEvent(stateMachine.id, it) }.startWith(ProgressTrackingEvent(stateMachine.id, current))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* This model exposes raw event streams to and from the node.
|
||||
*/
|
||||
|
@ -10,20 +10,8 @@ import net.corda.client.jfx.utils.recordAsAssociation
|
||||
import net.corda.core.ErrorOr
|
||||
import net.corda.core.flows.FlowInitiator
|
||||
import net.corda.core.flows.StateMachineRunId
|
||||
import net.corda.core.messaging.StateMachineInfo
|
||||
import net.corda.core.messaging.StateMachineUpdate
|
||||
import org.fxmisc.easybind.EasyBind
|
||||
import rx.Observable
|
||||
|
||||
data class ProgressTrackingEvent(val stateMachineId: StateMachineRunId, val message: String) {
|
||||
companion object {
|
||||
fun createStreamFromStateMachineInfo(stateMachine: StateMachineInfo): Observable<ProgressTrackingEvent>? {
|
||||
return stateMachine.progressTrackerStepAndUpdates?.let { (current, future) ->
|
||||
future.map { ProgressTrackingEvent(stateMachine.id, it) }.startWith(ProgressTrackingEvent(stateMachine.id, current))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
data class ProgressStatus(val status: String?)
|
||||
|
||||
|
@ -1,7 +1,6 @@
|
||||
package net.corda.client.jfx.model
|
||||
|
||||
import javafx.beans.value.ObservableValue
|
||||
import javafx.collections.ObservableList
|
||||
import javafx.collections.ObservableMap
|
||||
import net.corda.client.jfx.utils.*
|
||||
import net.corda.core.contracts.ContractState
|
||||
@ -11,11 +10,6 @@ import net.corda.core.crypto.SecureHash
|
||||
import net.corda.core.transactions.SignedTransaction
|
||||
import org.fxmisc.easybind.EasyBind
|
||||
|
||||
data class GatheredTransactionData(
|
||||
val transaction: PartiallyResolvedTransaction,
|
||||
val stateMachines: ObservableList<out StateMachineData>
|
||||
)
|
||||
|
||||
/**
|
||||
* [PartiallyResolvedTransaction] holds a [SignedTransaction] that has zero or more inputs resolved. The intent is
|
||||
* to prepare clients for cases where an input can only be resolved in the future/cannot be resolved at all (for example
|
||||
@ -59,7 +53,6 @@ data class PartiallyResolvedTransaction(
|
||||
*/
|
||||
class TransactionDataModel {
|
||||
private val transactions by observable(NodeMonitorModel::transactions)
|
||||
|
||||
private val collectedTransactions = transactions.recordInSequence()
|
||||
private val transactionMap = collectedTransactions.associateBy(SignedTransaction::id)
|
||||
|
||||
|
@ -277,18 +277,3 @@
|
||||
.identicon {
|
||||
-fx-border-radius: 2;
|
||||
}
|
||||
|
||||
.flow-expanded {
|
||||
-fx-background-color: rgba(255, 255, 255);
|
||||
-fx-background-size: Auto 90%;
|
||||
-fx-background-repeat: no-repeat;
|
||||
-fx-background-position: center center;
|
||||
-fx-border-color: transparent;
|
||||
-fx-border-radius: 2;
|
||||
}
|
||||
|
||||
.flow-expanded:hover {
|
||||
-fx-border-color: -color-3;
|
||||
-fx-border-width: 2;
|
||||
-fx-border-radius: 2;
|
||||
}
|
||||
|
@ -0,0 +1,17 @@
|
||||
@import "corda-dark-color-scheme.css";
|
||||
|
||||
/* Flow triage css */
|
||||
.flow-expanded {
|
||||
-fx-background-color: rgba(255, 255, 255);
|
||||
-fx-background-size: Auto 90%;
|
||||
-fx-background-repeat: no-repeat;
|
||||
-fx-background-position: center center;
|
||||
-fx-border-color: transparent;
|
||||
-fx-border-radius: 2;
|
||||
}
|
||||
|
||||
.flow-expanded:hover {
|
||||
-fx-border-color: -color-3;
|
||||
-fx-border-width: 2;
|
||||
-fx-border-radius: 2;
|
||||
}
|
@ -6,7 +6,7 @@
|
||||
<?import javafx.scene.layout.RowConstraints?>
|
||||
<?import javafx.scene.layout.VBox?>
|
||||
|
||||
<GridPane styleClass="flow-expanded" stylesheets="@../css/corda.css" xmlns="http://javafx.com/javafx/8.0.112" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<GridPane styleClass="flow-expanded" stylesheets="@../css/enterprise.css" xmlns="http://javafx.com/javafx/8.0.112" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<padding>
|
||||
<Insets bottom="5" left="5" right="5" top="5" />
|
||||
</padding>
|
||||
|
Loading…
Reference in New Issue
Block a user