Search in sources :

Example 6 with Tag

use of com.autentia.tnt.businessobject.Tag in project TNTConcept by autentia.

the class PositionBean method getAllTags.

public List<SelectItem> getAllTags() {
    final List<Tag> refs = TagManager.getDefault().getAllEntities(null, new SortCriteria("id"));
    final List<SelectItem> ret = new ArrayList<SelectItem>();
    for (Tag ref : refs) {
        ret.add(new SelectItem(ref, ref.getName()));
    }
    return ret;
}
Also used : SortCriteria(com.autentia.tnt.dao.SortCriteria) SelectItem(javax.faces.model.SelectItem) ArrayList(java.util.ArrayList) Tag(com.autentia.tnt.businessobject.Tag)

Example 7 with Tag

use of com.autentia.tnt.businessobject.Tag in project TNTConcept by autentia.

the class TagBean method create.

/**
 * Go to create page
 *
 * @return forward to CREATE page
 */
public String create() {
    tag = new Tag();
    tag.setInsertDate(new Date());
    return NavigationResults.CREATE;
}
Also used : Tag(com.autentia.tnt.businessobject.Tag) Date(java.util.Date)

Example 8 with Tag

use of com.autentia.tnt.businessobject.Tag in project TNTConcept by autentia.

the class DepartmentBean method getAllTags.

public List<SelectItem> getAllTags() {
    final List<Tag> refs = TagManager.getDefault().getAllEntities(null, new SortCriteria("id"));
    final List<SelectItem> ret = new ArrayList<SelectItem>();
    for (Tag ref : refs) {
        ret.add(new SelectItem(ref, ref.getName()));
    }
    return ret;
}
Also used : SortCriteria(com.autentia.tnt.dao.SortCriteria) SelectItem(javax.faces.model.SelectItem) ArrayList(java.util.ArrayList) Tag(com.autentia.tnt.businessobject.Tag)

Aggregations

Tag (com.autentia.tnt.businessobject.Tag)8 SortCriteria (com.autentia.tnt.dao.SortCriteria)3 ArrayList (java.util.ArrayList)3 UIData (javax.faces.component.UIData)3 SelectItem (javax.faces.model.SelectItem)3 Contact (com.autentia.tnt.businessobject.Contact)1 EntityChange (com.autentia.tnt.tracking.EntityChange)1 Date (java.util.Date)1