1 package org.kuali.ole.describe.form;
2
3
4
5
6
7
8
9
10
11 import org.kuali.ole.docstore.model.xmlpojo.work.instance.oleml.*;
12 import org.kuali.ole.editor.bo.InstanceRecordMetaData;
13 import org.kuali.ole.editor.bo.SourceEditorForUI;
14 import org.kuali.rice.core.api.util.tree.Tree;
15
16 import java.util.ArrayList;
17 import java.util.List;
18
19
20
21
22 public class WorkInstanceOlemlForm extends EditorForm {
23
24 private InstanceRecordMetaData itemRecordMetaData = new InstanceRecordMetaData();
25 private InstanceRecordMetaData holdingRecordMetaData = new InstanceRecordMetaData();
26 private OleHoldings selectedHolding;
27 private Instance instance;
28 private Item selectedItem;
29 private SourceEditorForUI selectedSourceHolding;
30 private String oldItemStatus;
31
32 public WorkInstanceOlemlForm () {
33 getSelectedHolding().getUri().add(new Uri());
34 getSelectedHolding().getNote().add(new Note());
35 getSelectedHolding().getExtentOfOwnership().add(new ExtentOfOwnership());
36 getSelectedHolding().getExtentOfOwnership().get(0).getNote().add(new Note());
37 getSelectedItem().getNote().add(new Note());
38 }
39
40
41 public String getMessage() {
42 return message;
43 }
44
45 public void setMessage(String message) {
46 this.message = message;
47 }
48
49 public InstanceRecordMetaData getItemRecordMetaData() {
50 return itemRecordMetaData;
51 }
52
53 public void setItemRecordMetaData(InstanceRecordMetaData itemRecordMetaData) {
54 this.itemRecordMetaData = itemRecordMetaData;
55 }
56
57 public InstanceRecordMetaData getHoldingRecordMetaData() {
58 return holdingRecordMetaData;
59 }
60
61 public void setHoldingRecordMetaData(InstanceRecordMetaData holdingRecordMetaData) {
62 this.holdingRecordMetaData = holdingRecordMetaData;
63 }
64
65 public OleHoldings getSelectedHolding() {
66 if (null == selectedHolding) {
67 selectedHolding = new OleHoldings();
68 selectedHolding.setCallNumber(new CallNumber());
69 }
70 return selectedHolding;
71 }
72
73 public void setSelectedHolding(OleHoldings selectedHolding) {
74 this.selectedHolding = selectedHolding;
75 }
76
77 public Instance getInstance() {
78 return instance;
79 }
80
81 public void setInstance(Instance instance) {
82 this.instance = instance;
83 }
84
85 public Item getSelectedItem() {
86 if (null == selectedItem) {
87 selectedItem = new Item();
88 selectedItem.setCallNumber(new CallNumber());
89 }
90 return selectedItem;
91 }
92
93 public void setSelectedItem(Item selectedItem) {
94 this.selectedItem = selectedItem;
95 }
96
97 public SourceEditorForUI getSelectedSourceHolding() {
98 return selectedSourceHolding;
99 }
100
101 public void setSelectedSourceHolding(SourceEditorForUI selectedSourceHolding) {
102 this.selectedSourceHolding = selectedSourceHolding;
103 }
104
105 public String getOldItemStatus() {
106 return oldItemStatus;
107 }
108
109 public void setOldItemStatus(String oldItemStatus) {
110 this.oldItemStatus = oldItemStatus;
111 }
112 }