Jean-Francois Leveque

Injection par constructeur.

......@@ -28,9 +28,7 @@ import java.util.List;
public class PublisherVersionView implements Serializable {
Logger logger = LoggerFactory.getLogger(getClass());
@Inject
PublisherService publisherService;
@Inject
SharedService sharedService;
private boolean editMode;
......@@ -55,6 +53,16 @@ public class PublisherVersionView implements Serializable {
private List<Country> availableCountries;
@Inject
public PublisherVersionView(PublisherService publisherService, SharedService sharedService) {
this.publisherService = publisherService;
this.sharedService = sharedService;
}
//no args constructor to make it proxyable
PublisherVersionView() {
}
@PostConstruct
public void init() {
availableCountries = sharedService.getAllCountries();
......