Remove separate label field from PatchSetApproval
This is now stored directly in the key. Change-Id: I9c53e6a08fb4de17e8faa1153f85f5226a3a51fb
This commit is contained in:
@@ -137,9 +137,6 @@ public final class PatchSetApproval {
|
|||||||
@Column(id = 5, length = 16, notNull = false)
|
@Column(id = 5, length = 16, notNull = false)
|
||||||
protected String changeSortKey;
|
protected String changeSortKey;
|
||||||
|
|
||||||
/** Label name copied from corresponding {@link ApprovalCategory}. */
|
|
||||||
protected String label;
|
|
||||||
|
|
||||||
protected PatchSetApproval() {
|
protected PatchSetApproval() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -200,15 +197,11 @@ public final class PatchSetApproval {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public String getLabel() {
|
public String getLabel() {
|
||||||
return label;
|
return getLabelId().get();
|
||||||
}
|
|
||||||
|
|
||||||
public void setLabel(String label) {
|
|
||||||
this.label = label;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isSubmit() {
|
public boolean isSubmit() {
|
||||||
return LabelId.SUBMIT.get().equals(getLabelId().get());
|
return LabelId.SUBMIT.get().equals(getLabel());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@@ -108,7 +108,6 @@ public class LabelNormalizer {
|
|||||||
private PatchSetApproval copy(PatchSetApproval src, ChangeControl ctl) {
|
private PatchSetApproval copy(PatchSetApproval src, ChangeControl ctl) {
|
||||||
PatchSetApproval dest = new PatchSetApproval(src.getPatchSetId(), src);
|
PatchSetApproval dest = new PatchSetApproval(src.getPatchSetId(), src);
|
||||||
dest.cache(ctl.getChange());
|
dest.cache(ctl.getChange());
|
||||||
dest.setLabel(src.getLabel());
|
|
||||||
return dest;
|
return dest;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user