new to play and just trying to follow the video on:
http://www.playframework.org/
I'm coming so far that i want to create the list of tasks after creating the Task-class. I when i reload i get this error:
"UsupportedOperationException occured : Please annotate your JPA model with @javax.persistence.Entity annotation."
I'm using Eclipse. Also note that i have changed tasks to be persons in:
My Person model/class-defination in Person.java
package models;
import play.*;
import play.db.jpa.*;
import javax.persistence.*;
import java.util.*;
public class Person extends Model{
public String title;
public boolean done;
public Person(String title){
this.title = title;
}
}
And application.java:
package controllers;
import play.*;
import play.mvc.*;
import java.util.*;
import models.*;
public class Application extends Controller {
public static void index() {
List persons = Person.find("order by id desc").fetch();
render(persons);
}
}
The error is connected with this line: List persons = Person.find("order by id desc").fetch();
JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)