浏览代码

HL7LogEntry

testBranch
Johannes Oehm 10 年前
父节点
当前提交
39b1c1c17a
共有 3 个文件被更改,包括 80 次插入7 次删除
  1. +0
    -1
      src/main/java/de/uniluebeck/mi/projmi6/controller/MainController.java
  2. +18
    -6
      src/main/java/de/uniluebeck/mi/projmi6/controller/StationsHistorieController.java
  3. +62
    -0
      src/main/java/de/uniluebeck/mi/projmi6/model/HL7LogEntry.java

+ 0
- 1
src/main/java/de/uniluebeck/mi/projmi6/controller/MainController.java 查看文件

@@ -233,7 +233,6 @@ public class MainController {
}
setText(item.toString());
if (item.getStorniert()) {
System.out.println("Storniertes Item");
setGraphic(new Label("<storniert> "));
setTextFill(Color.GRAY); //TODO
} else {


+ 18
- 6
src/main/java/de/uniluebeck/mi/projmi6/controller/StationsHistorieController.java 查看文件

@@ -85,6 +85,9 @@ public class StationsHistorieController {
initStationsFilter();


initButtons();


fields.disableProperty().bind(stateProperty().isEqualTo(State.VIEW));

btnStatHistCreate.disableProperty().bind(mainController.fallProperty().isNull());
@@ -104,6 +107,20 @@ public class StationsHistorieController {
});
}

private void initButtons(){
btnStatHistCancel.visibleProperty().bind(state.isEqualTo(State.VIEW).and(tblStationsHistorie.getSelectionModel().selectedItemProperty().isNotNull()));
btnStatHistCancel.managedProperty().bind(btnStatHistCancel.visibleProperty());

btnStatHistSave.visibleProperty().bind(state.isEqualTo(State.VIEW).not());
btnStatHistSave.managedProperty().bind(btnStatHistSave.visibleProperty());

btnStatHistAbort.visibleProperty().bind(state.isEqualTo(State.VIEW).not());
btnStatHistAbort.managedProperty().bind(btnStatHistAbort.visibleProperty());

btnStatHistEdit.visibleProperty().bind(state.isEqualTo(State.VIEW));
btnStatHistEdit.managedProperty().bind(btnStatHistEdit.visibleProperty());
}

private void initStationsFilter(){
final String any = "beliebig";

@@ -114,11 +131,6 @@ public class StationsHistorieController {
cmbAbteilung.getItems().add(0, any);
cmbAbteilung.getSelectionModel().select(0);

btnStatHistCancel.visibleProperty().bind(state.isEqualTo(State.VIEW).and(tblStationsHistorie.getSelectionModel().selectedItemProperty().isNotNull()));
btnStatHistSave.visibleProperty().bind(state.isEqualTo(State.VIEW).not());
btnStatHistAbort.visibleProperty().bind(state.isEqualTo(State.VIEW).not());
btnStatHistEdit.visibleProperty().bind(state.isEqualTo(State.VIEW));

tblStationsHistorie.getSelectionModel().selectedItemProperty().addListener((observable, oldValue, newValue) -> {
setStationsHistorieSelected(newValue);
});
@@ -231,7 +243,7 @@ public class StationsHistorieController {
statHistCreateTime.setText(stationsHistorieSelected.getErstellDatumZeit().toString());
}
statHistEditor.setText(Integer.toString(stationsHistorieSelected.getBearbeiter()));
if(stationsHistorieSelected.getBearbeitetDatumZeit()!=null){
if (stationsHistorieSelected.getBearbeitetDatumZeit() != null) {
statHistEditTime.setText(stationsHistorieSelected.getBearbeitetDatumZeit().toString());
}
}


+ 62
- 0
src/main/java/de/uniluebeck/mi/projmi6/model/HL7LogEntry.java 查看文件

@@ -0,0 +1,62 @@
package de.uniluebeck.mi.projmi6.model;

import javafx.beans.property.SimpleObjectProperty;
import javafx.beans.property.SimpleStringProperty;

import java.time.LocalDateTime;

/**
* Created by 631806 on 19.11.15.
*/
public class HL7LogEntry {
private final int msgid;
private final SimpleStringProperty message = new SimpleStringProperty(this, "message");
private final SimpleStringProperty source = new SimpleStringProperty(this, "source");

public HL7LogEntry(int msgid) {
this.msgid = msgid;
}

public LocalDateTime getTimestamp() {
return timestamp.get();
}

public SimpleObjectProperty<LocalDateTime> timestampProperty() {
return timestamp;
}

public void setTimestamp(LocalDateTime timestamp) {
this.timestamp.set(timestamp);
}

public int getMsgid() {
return msgid;
}

public String getMessage() {
return message.get();
}

public SimpleStringProperty messageProperty() {
return message;
}

public void setMessage(String message) {
this.message.set(message);
}

public String getSource() {
return source.get();
}

public SimpleStringProperty sourceProperty() {
return source;
}

public void setSource(String source) {
this.source.set(source);
}


private final SimpleObjectProperty<LocalDateTime> timestamp = new SimpleObjectProperty<>(this, "timestamp");
}

正在加载...
取消
保存