1 | |
package org.kuali.student.lum.program.client.major.edit; |
2 | |
|
3 | |
import org.kuali.student.common.ui.client.configurable.mvc.Configurer; |
4 | |
import org.kuali.student.common.ui.client.mvc.Controller; |
5 | |
import org.kuali.student.common.ui.client.mvc.View; |
6 | |
import org.kuali.student.lum.common.client.configuration.AbstractControllerConfiguration; |
7 | |
import org.kuali.student.lum.program.client.ProgramMsgConstants; |
8 | |
import org.kuali.student.lum.program.client.ProgramSections; |
9 | |
import org.kuali.student.lum.program.client.major.MajorManager; |
10 | |
import org.kuali.student.lum.program.client.requirements.ProgramRequirementsViewController; |
11 | |
|
12 | |
import com.google.gwt.user.client.ui.Widget; |
13 | |
|
14 | |
public class ProgramRequirementsEditConfiguration extends AbstractControllerConfiguration { |
15 | |
|
16 | |
private ProgramRequirementsViewController progReqcontroller; |
17 | |
|
18 | |
|
19 | |
|
20 | |
public ProgramRequirementsEditConfiguration(Configurer configurer) { |
21 | 0 | super(); |
22 | 0 | this.setConfigurer(configurer); |
23 | 0 | } |
24 | |
|
25 | |
@Override |
26 | |
public View getView() { |
27 | 0 | progReqcontroller = new ProgramRequirementsViewController(controller, MajorManager.getEventBus(), |
28 | |
getLabel(ProgramMsgConstants.PROGRAM_MENU_SECTIONS_REQUIREMENTS), ProgramSections.PROGRAM_REQUIREMENTS_EDIT, false, null); |
29 | 0 | return progReqcontroller; |
30 | |
} |
31 | |
|
32 | |
@Override |
33 | |
protected void buildLayout() { |
34 | |
|
35 | 0 | } |
36 | |
|
37 | |
@Override |
38 | |
public void setController(Controller controller) { |
39 | 0 | this.controller = controller; |
40 | 0 | if (progReqcontroller != null) { |
41 | 0 | progReqcontroller.setParentController(controller); |
42 | |
} |
43 | 0 | } |
44 | |
|
45 | |
@Override |
46 | |
public Widget asWidget() { |
47 | 0 | return controller; |
48 | |
} |
49 | |
|
50 | |
@Override |
51 | |
public Enum<?> getName() { |
52 | 0 | return ProgramSections.PROGRAM_REQUIREMENTS_EDIT; |
53 | |
} |
54 | |
} |