|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.squashtest.tm.service.internal.customfield.CustomFieldBindingModificationServiceImpl
@Service(value="squashtest.tm.service.CustomFieldBindingService") @Transactional public class CustomFieldBindingModificationServiceImpl
| Constructor Summary | |
|---|---|
CustomFieldBindingModificationServiceImpl()
|
|
| Method Summary | |
|---|---|
void |
addNewCustomFieldBinding(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity,
long customFieldId,
org.squashtest.tm.domain.customfield.CustomFieldBinding newBinding)
Will attach a CustomField to a Project. |
void |
addRenderingLocation(long bindingId,
org.squashtest.tm.domain.customfield.RenderingLocation location)
Add a rendering location to a custom field binding |
void |
copyCustomFieldsSettingsFromTemplate(org.squashtest.tm.domain.project.Project newProject,
org.squashtest.tm.domain.project.ProjectTemplate projectTemplate)
Will copy the custom field bindings of the template and apply them to the project. |
List<org.squashtest.tm.domain.customfield.CustomField> |
findAvailableCustomFields()
returns all the existing custom fields. |
List<org.squashtest.tm.domain.customfield.CustomField> |
findAvailableCustomFields(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
same as CustomFieldBindingFinderService.findAvailableCustomFields(), restricted to the given project and bindable entity. |
List<org.squashtest.tm.domain.customfield.CustomField> |
findBoundCustomFields(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
Returns the complementary of CustomFieldBindingFinderService.findAvailableCustomFields(long, BindableEntity) |
List<org.squashtest.tm.domain.customfield.CustomFieldBinding> |
findCustomFieldsForBoundEntity(org.squashtest.tm.domain.customfield.BoundEntity boundEntity)
returns all the custom field bindinds associated to that entity wrt its project and BindableEntity type |
List<org.squashtest.tm.domain.customfield.CustomFieldBinding> |
findCustomFieldsForGenericProject(long projectId)
returns all the custom field bindings associated to a GenericProject. |
List<org.squashtest.tm.domain.customfield.CustomFieldBinding> |
findCustomFieldsForProjectAndEntity(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
returns all the custom field bindings associated to a project for a given entity type |
org.squashtest.tm.core.foundation.collection.PagedCollectionHolder<List<org.squashtest.tm.domain.customfield.CustomFieldBinding>> |
findCustomFieldsForProjectAndEntity(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity,
org.squashtest.tm.core.foundation.collection.Paging paging)
returns all the custom field bindings associated to a project for a given entity type (paged version) |
void |
moveCustomFieldbindings(List<Long> bindingIds,
int newIndex)
Given a list of CustomFieldBindings, will reorder them with respect to their project and bound entity. |
void |
removeCustomFieldBindings(List<Long> bindingIds)
removes a batch of custom field bindings using their ids. |
void |
removeCustomFieldBindings(Long projectId)
removes all the custom field bindings defined for a project. |
void |
removeRenderingLocation(long bindingId,
org.squashtest.tm.domain.customfield.RenderingLocation location)
Remove the rendering location from a custom field binding |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CustomFieldBindingModificationServiceImpl()
| Method Detail |
|---|
@Transactional(readOnly=true) public List<org.squashtest.tm.domain.customfield.CustomField> findAvailableCustomFields()
CustomFieldBindingFinderService
findAvailableCustomFields in interface CustomFieldBindingFinderService
@Transactional(readOnly=true)
public List<org.squashtest.tm.domain.customfield.CustomField> findAvailableCustomFields(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
CustomFieldBindingFinderServiceCustomFieldBindingFinderService.findAvailableCustomFields(), restricted to the given project and bindable entity. The only
returned fields are those who aren't already mapped for that project and entity.
findAvailableCustomFields in interface CustomFieldBindingFinderService
@Transactional(readOnly=true)
public List<org.squashtest.tm.domain.customfield.CustomField> findBoundCustomFields(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
CustomFieldBindingFinderServiceCustomFieldBindingFinderService.findAvailableCustomFields(long, BindableEntity)
findBoundCustomFields in interface CustomFieldBindingFinderService@Transactional(readOnly=true) public List<org.squashtest.tm.domain.customfield.CustomFieldBinding> findCustomFieldsForGenericProject(long projectId)
CustomFieldBindingFinderService
findCustomFieldsForGenericProject in interface CustomFieldBindingFinderService
@Transactional(readOnly=true)
public List<org.squashtest.tm.domain.customfield.CustomFieldBinding> findCustomFieldsForProjectAndEntity(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity)
CustomFieldBindingFinderService
findCustomFieldsForProjectAndEntity in interface CustomFieldBindingFinderService@Transactional(readOnly=true) public List<org.squashtest.tm.domain.customfield.CustomFieldBinding> findCustomFieldsForBoundEntity(org.squashtest.tm.domain.customfield.BoundEntity boundEntity)
CustomFieldBindingFinderServiceBindableEntity type
findCustomFieldsForBoundEntity in interface CustomFieldBindingFinderService
@Transactional(readOnly=true)
public org.squashtest.tm.core.foundation.collection.PagedCollectionHolder<List<org.squashtest.tm.domain.customfield.CustomFieldBinding>> findCustomFieldsForProjectAndEntity(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity,
org.squashtest.tm.core.foundation.collection.Paging paging)
CustomFieldBindingFinderService
findCustomFieldsForProjectAndEntity in interface CustomFieldBindingFinderService
@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')")
public void addNewCustomFieldBinding(long projectId,
org.squashtest.tm.domain.customfield.BindableEntity entity,
long customFieldId,
org.squashtest.tm.domain.customfield.CustomFieldBinding newBinding)
CustomFieldBindingModificationServiceCustomField to a Project. The details and conditions of that binding is described
in the CustomFieldBinding newBinding. The new binding will be inserted last.
addNewCustomFieldBinding in interface CustomFieldBindingModificationService
@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')")
public void addRenderingLocation(long bindingId,
org.squashtest.tm.domain.customfield.RenderingLocation location)
CustomFieldBindingModificationService
addRenderingLocation in interface CustomFieldBindingModificationService
@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')")
public void removeRenderingLocation(long bindingId,
org.squashtest.tm.domain.customfield.RenderingLocation location)
CustomFieldBindingModificationService
removeRenderingLocation in interface CustomFieldBindingModificationService@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')") public void removeCustomFieldBindings(List<Long> bindingIds)
CustomFieldBindingModificationService
removeCustomFieldBindings in interface CustomFieldBindingModificationService@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')") public void removeCustomFieldBindings(Long projectId)
CustomFieldBindingModificationService
removeCustomFieldBindings in interface CustomFieldBindingModificationServiceprojectId - the id of the project
@PreAuthorize(value="hasRole(\'ROLE_TM_PROJECT_MANAGER\') or hasRole(\'ROLE_ADMIN\')")
public void moveCustomFieldbindings(List<Long> bindingIds,
int newIndex)
CustomFieldBindingModificationServiceCustomFieldBindings, will reorder them with respect to their project and bound entity.
This method assumes that they all bind the same entity to the same project. If the input list mixes binding for
different projects and/or entities, unexpected behavior may occur.
moveCustomFieldbindings in interface CustomFieldBindingModificationServiceCustomFieldBindingModificationService.copyCustomFieldsSettingsFromTemplate(Project, ProjectTemplate)
@PreAuthorize(value="hasRole(\'ROLE_ADMIN\')")
public void copyCustomFieldsSettingsFromTemplate(org.squashtest.tm.domain.project.Project newProject,
org.squashtest.tm.domain.project.ProjectTemplate projectTemplate)
CustomFieldBindingModificationService
copyCustomFieldsSettingsFromTemplate in interface CustomFieldBindingModificationServiceCustomFieldBindingModificationService.copyCustomFieldsSettingsFromTemplate(Project, ProjectTemplate)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||