A quarkus service that shows 5G antennas on a map along with incidents
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

29 lines
739 B

package org.sebi.incident;
import java.util.Date;
import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.event.Observes;
import javax.transaction.Transactional;
import io.quarkus.runtime.StartupEvent;
@ApplicationScoped
public class IncidentStartup {
@Transactional
void onStart(@Observes StartupEvent ev) {
Incident incident = new Incident();
incident.date = new Date();
incident.description = "coupure fibre";
incident.status = false;
incident.persist();
Incident incident1 = new Incident();
incident1.date = new Date();
incident1.description = "Panne émetteur";
incident1.status = true;
incident1.persist();
}
}