[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1117) support enum types in @RaiseEvent or a new @RaiseEventType annotation
by Bradley Smith (JIRA)
support enum types in @RaiseEvent or a new @RaiseEventType annotation
---------------------------------------------------------------------
Key: JBSEAM-1117
URL: http://jira.jboss.com/jira/browse/JBSEAM-1117
Project: JBoss Seam
Issue Type: Feature Request
Components: Core
Reporter: Bradley Smith
RaiseEvent:
@Target(METHOD)
@Retention(RUNTIME)
@Documented
public @interface RaiseEvent
{
/**
* The event name, defaults to the name
* of the method.
*
* @return the event name
*/
String value() default "";
//TODO: String[] ifOutcome() default {};
}
Is it possible to make the value be based on an enum type? I currently have all my application event types enumerated in enum called EventType.
I've tried doing:
@RaiseEvent(EventType.ApplicationSaved.name())
however, this doesn't count as a constant String and is invalid syntax. It seems more 'elegant' to be able to enumerate the event types of an application in something like an enum than to sprinkle strings throughout the code with the specific event String values.
Maybe an alternate annotation is called for - say, @RaiseEventType(MyEnum.MyEventType)?
I'm not sure - I don't have a solid grasp of the syntax used to define an annotation.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1110) Support multiple bundle for a view-id in pages.xml
by Bing Zou (JIRA)
Support multiple bundle for a view-id in pages.xml
--------------------------------------------------
Key: JBSEAM-1110
URL: http://jira.jboss.com/jira/browse/JBSEAM-1110
Project: JBoss Seam
Issue Type: Feature Request
Components: Core
Affects Versions: 1.2.0.GA
Reporter: Bing Zou
Since Seam supports Facelets. A typical thing we do by using Facelets is the idea of templates. For example, two concrete pages a.xhtml, b.xhtml both extend from template.xhtml. We want to separate the resource bundle for each concrete page as a coding standard. Then in pages.xml we will have
<page view-id="/parentfolder/a.xhtml" bundle="parentFolder/a" />
<page view-id="/parentfolder/b.xhtml" bundle="parentFolder/b" />
However, since both a.xhtml and b.xhtml has the same template.xhtml, we want to separate the common fields from template.xhtml to it's own resource bundle. Therefore, for each view-id should have an additional bundle, for example,
<page view-id="/parentfolder/a.xhtml" bundle="parentFolder/a,parentFolder/template" />
Or maybe Seam can be smart to find out that a.xhtml extends from template.xhtml and there is a <page view-id="/parentFolder/template.xhtml" bundle="parentFolder/template" /> and then both bundle will be available for view-id a.xhtml. Of course, if there is any conflict, the child page always override parent page's property.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1055) Query Pagination in JBoss Seam Framework
by Antonio Navas (JIRA)
Query Pagination in JBoss Seam Framework
----------------------------------------
Key: JBSEAM-1055
URL: http://jira.jboss.com/jira/browse/JBSEAM-1055
Project: JBoss Seam
Issue Type: Patch
Components: Framework
Affects Versions: 1.2.0.GA
Reporter: Antonio Navas
Priority: Minor
I'm not sure that this is the correct procedure, but I want to contribute to this project....
I think there is an issue regarding pagination in EntityQuery. The problem is that it adds an unnecessary last page when the actual size of the result list equals the maxResults attribute. For example, if maxResults is set to 5 and the total result count for the query is 10, the pagination returns 3 pages instead of 2, and the last page is empty. I think that the implementation of the methods "isNextExists" and "getLastFirstResult" are wrong, and the correct implementation should be:
public boolean isNextExists() {
return getResultCount() > (getFirstResult() == null ? 0 : getFirstResult()) + getMaxResults();
}
public long getLastFirstResult() {
return ( (getResultCount()-1) / getMaxResults() ) * getMaxResults();
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months
[jbossseam-issues] [JBoss JIRA] Commented: (JBSEAM-225) Maven 2 support
by Geoffrey De Smet (JIRA)
[ http://jira.jboss.com/jira/browse/JBSEAM-225?page=comments#action_12362633 ]
Geoffrey De Smet commented on JBSEAM-225:
-----------------------------------------
Some raised a similar issue, where you can still vote: http://jira.jboss.com/jira/browse/JBSEAM-983
> Maven 2 support
> ---------------
>
> Key: JBSEAM-225
> URL: http://jira.jboss.com/jira/browse/JBSEAM-225
> Project: JBoss Seam
> Issue Type: Feature Request
> Components: Core
> Affects Versions: 1.0 beta 2
> Environment: Maven 2.0.x
> Reporter: Tuomas Kiviaho
>
> Mavenizing of the project would be very helpful when using cvs shapshots instead of prebuild releases.
> It seems that all of the 3rd party projects previously available separately have been merged together as thirdparty-all.jar. Some of the 3rd party jars are missing like jsf-facelets.jar which should be some older version than the current release.
> What is needed is a pom.xml currently producing both jboss-seam.jar and jboss-seam-ui.jar and having all of the dependencies enlisted. Most of the dependent projects are already available by default or then they exist in JBoss maven repository (refer to next gen jboss build system). I see that (propably missing) installments like jBPM have similar feature requests. pom.xml functions as a documentation where to place manually different jars in order to get for instance jboss seam digester working.
> An optional feature would be to replace all of the .classpath lib references with maven2 classpath container that comes with Maven2 Eclipse plugin. This will make pom.xml useful for eclipse users even if current JBoss build engine is to be used, but requires maven2 plugin to be installed. The project wasn't not compiling for me directly when checked out from CVS, so plugin requirement is less of a pain than sonting out "broken" .classpath.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1287) Enable support for DataModelSelection when used with entiy-query
by Brian Smith (JIRA)
Enable support for DataModelSelection when used with entiy-query
----------------------------------------------------------------
Key: JBSEAM-1287
URL: http://jira.jboss.com/jira/browse/JBSEAM-1287
Project: JBoss Seam
Issue Type: Feature Request
Components: Framework
Reporter: Brian Smith
It would be nice to be able to match up a DataModelSelection with a DataModel that is provided by an entity-query. As of now a deployment error is thrown.
Use Case: If a data table is driven by an entity-query, the only way currently to select a row is by passing the var using the Extended EL Seam provides. The extended EL is not compatible with some component libraries (Trinidad) and it is very ugly to go through component bindings to get the current value of the selected row. It would be nice to hook a DataModelSelection to the entity-query.
Something like this
-components.xml-
<framework:entity-query name="allUsers"
ejbql="select u from User u"/>
-facelets page-
[code]
<tr:table id="user_table" value="#{allUsers}" var="user">
<tr:column id="user_column">
<f:facet name="header">
<tr:outputText id="user_header" value="Customer"/>
</f:facet>
<tr:commandLink id="user_link" text="#{useruserName}" actionListener="#{attachUser.done}"/>
</tr:column>
</tr:table>[
/code]
-Seam Bean-
@DataModelSelection("allUsers")
List <User> userList;
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1290) EntityQuery.refresh() does not clear parsedEjbql variable
by Milli Coelho (JIRA)
EntityQuery.refresh() does not clear parsedEjbql variable
---------------------------------------------------------
Key: JBSEAM-1290
URL: http://jira.jboss.com/jira/browse/JBSEAM-1290
Project: JBoss Seam
Issue Type: Bug
Components: Framework
Affects Versions: 1.2.1.GA
Environment: Windows XP/JBoss4.0.5GA/JDK1.6
Reporter: Milli Coelho
I'm using the seam-gen generated class SubcategoriesList which is derived from EntityQuery and modified it to accept any query passed by a calling object as below:
public class SubCategoriesList extends EntityQuery {
private SubCategories subCategories = new SubCategories();
private String query;
private Integer maxResults;
public SubCategoriesList()
{
query = "select subCategories from SubCategories subCategories";
this.maxResults = 25;
}
@Override
public String getEjbql() {
return query;
}
@Override
public Integer getMaxResults() {
return this.maxResults;
}
public SubCategories getSubCategories() {
return subCategories;
}
@Override
public List<String> getRestrictions() {
return Arrays.asList(RESTRICTIONS);
}
public List<SubCategories> forCategory(String categoryId)
{
query = "select subCategories from SubCategories subCategories where subCategories.categories.id = " + Integer.parseInt(categoryId);
return getResultList();
}
}
In my calling object, I instantiate this class and use the method forCategory to get the list of subcategories for a given category id. If I reuse the object after calling refresh() and pass a different category id, it gives the same resultlist. After looking in EntityQuery and Query classes, I see refresh() does not nullify parsedEjbql and therefore createQuery() uses the same query everytime to get the resultlist.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 8 months