Examples of save()


Examples of models.LightningTalk.save()

    private LightningTalk createLT(Member... speakers) {
        LightningTalk lt = new LightningTalk();
        for (Member s : speakers) {
            lt.addSpeaker(s);
        }
        return lt.save();
    }

    @Test
    public void grantedSpeaker() {
        // Member become speaker of a validated talk
View Full Code Here

Examples of models.Marker.save()

public class Markers extends Application {
    @Secure(login = true)
    public static void add(String lng, String lat) {
        Logger.info(lng + " " + lat);
        Marker marker = new Marker(lng, lat);
        marker.save();
    }

    public static void list() {
        List<Marker> markers = Marker.findAll();
        StringBuilder builder = new StringBuilder("[");
View Full Code Here

Examples of models.Member.save()

            try {
                txTemplate.execute(new TransactionCallbackWithoutResult() {
                    public void doInTransaction() {
                        final Member member = Member.findById(memberId);
                        member.setTicketingRegistered(YurPlan.isRegisteredAttendee(member, token));
                        member.save();
                    }
                });
            } catch (Exception e) {
                Logger.error("Exception while registering user, skipped to next", e);
            }
View Full Code Here

Examples of models.Module.save()

                    }
                    rate.rating = ratingForm.rating;
                    module.rating.add(rate);
                    module.rating.calculateAverage();

                    module.save();
                    user.save();
                }

                RatingResponseForm responseForm = new RatingResponseForm();
                responseForm.totalRatings = module.rating.totalRatings();
View Full Code Here

Examples of models.ModuleVersion.save()

            // everything below here needs to be implemented
            moduleVersion.binaryFile = new BinaryContent();
            moduleVersion.binaryFile.content = new byte[]{1};
            moduleVersion.binaryFile.contentLength = 1;
            moduleVersion.save();
            moduleVersion.saveManyToManyAssociations("compatibility");

            createHistoricalEvent("Module updated - " + moduleVersion.playModule.name,
                                  String.format("%s (%s) uploaded version %s of %s",
                                                user.displayName,
View Full Code Here

Examples of models.Nature.save()

    Form<Nature> filledForm = natureForm.bindFromRequest();
        if(filledForm.hasErrors()) {
            return ok(create.render(filledForm));
        } else {
            Nature created = filledForm.get();
            created.save();
            flash("success", "Nature ajoutée");
            return redirect("/nature");
        }
    }
}
View Full Code Here

Examples of models.Organization.save()

            flash(Constants.WARNING, newOrgForm.error("name").message());
            return badRequest(create.render("title.newOrganization", newOrgForm));
        } else {
            Organization org = newOrgForm.get();
            org.created = new Date();
            org.save();

            UserApp.currentUser().createOrganization(org);
            return redirect(routes.OrganizationApp.organization(org.name));
        }
    }
View Full Code Here

Examples of models.OutboxMessage.save()

    }
    message.insert();
   
    // Create the outbox message
    OutboxMessage outMessage = new OutboxMessage(from, message);
    outMessage.save()
   
       
    //Se inserta un mensaje que pertenece al receptor
     
    for(User receiver : receivers)  {
View Full Code Here

Examples of models.Person.save()

        return ok(index.render());
    }

    public Result addPerson() {
      Person person = Form.form(Person.class).bindFromRequest().get();
      person.save();
      return redirect(routes.Application.index());
    }

    public Result getPersons() {
      List<Person> persons = new Model.Finder(String.class, Person.class).all();
View Full Code Here

Examples of models.PersonLongAutoIDExtendedAbstract.save()

public class Inherit extends Controller {
  public static void index() {
    PersonLongAutoIDExtendedAbstract bob =
      new PersonLongAutoIDExtendedAbstract("Bob", "Doe", "Oklahoma", 1, "the_dog1");
    bob.save();
   
    // fetches it to be sure it has been saved
    bob =
      Model.getByKey(PersonLongAutoIDExtendedAbstract.class, bob.id);
   
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.