extended possibilities to edit transaction
Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
@@ -42,6 +42,12 @@ public class Transaction implements Mappable {
|
||||
return amount;
|
||||
}
|
||||
|
||||
public Transaction amount(double newVal){
|
||||
amount = newVal;
|
||||
dirtyFields.add(Field.AMOUNT);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Transaction clearDirtyState(){
|
||||
dirtyFields.clear();
|
||||
return this;
|
||||
@@ -65,6 +71,12 @@ public class Transaction implements Mappable {
|
||||
return destination;
|
||||
}
|
||||
|
||||
public Transaction destination(IdOrString newVal){
|
||||
destination = newVal;
|
||||
dirtyFields.add(Field.DESTINATION);
|
||||
return this;
|
||||
}
|
||||
|
||||
public long id(){
|
||||
return id;
|
||||
}
|
||||
@@ -99,6 +111,12 @@ public class Transaction implements Mappable {
|
||||
return source;
|
||||
}
|
||||
|
||||
public Transaction source(IdOrString newVal){
|
||||
source = newVal;
|
||||
dirtyFields.add(Field.SOURCE);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Set<String> tags(){
|
||||
return tags;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user