本文整理汇总了Java中com.liferay.portal.kernel.search.Document.addTextSortable方法的典型用法代码示例。如果您正苦于以下问题:Java Document.addTextSortable方法的具体用法?Java Document.addTextSortable怎么用?Java Document.addTextSortable使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.liferay.portal.kernel.search.Document
的用法示例。
在下文中一共展示了Document.addTextSortable方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(TaskRecord taskRecord) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, taskRecord);
document.addDateSortable(Field.CREATE_DATE, taskRecord.getCreateDate());
document.addTextSortable("description", taskRecord.getDescription());
document.addNumberSortable("duration", taskRecord.getDuration());
document.addDateSortable("fromDate", taskRecord.getFromDate());
document.addNumberSortable("taskRecordId", taskRecord.getTaskRecordId());
document.addNumberSortable(Field.STATUS, taskRecord.getStatus());
document.addTextSortable("ticketURL", taskRecord.getTicketURL());
document.addKeyword("ownerUserId", taskRecord.getUserId());
document.addDateSortable("modifiedDate", taskRecord.getModifiedDate());
document.addDateSortable("untilDate", taskRecord.getUntilDate());
document.addTextSortable("userName", taskRecord.getUserName());
document.addTextSortable("workPackage", taskRecord.getWorkPackage());
return document;
}
示例2: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(WorkingUnit workingUnit) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, workingUnit);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(workingUnit.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, workingUnit.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(workingUnit.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(workingUnit.getUserName()));
document.addNumberSortable(WorkingUnitTerm.GROUP_ID, workingUnit.getGroupId());
document.addNumberSortable(WorkingUnitTerm.WORKINGUNIT_ID, workingUnit.getWorkingUnitId());
document.addTextSortable(WorkingUnitTerm.NAME, workingUnit.getName());
document.addTextSortable(WorkingUnitTerm.ENNAME, workingUnit.getEnName());
document.addTextSortable(WorkingUnitTerm.GOV_AGENCY_CODE, workingUnit.getGovAgencyCode());
document.addNumberSortable(WorkingUnitTerm.PARENT_WORKING_UNIT_ID, workingUnit.getParentWorkingUnitId());
document.addTextSortable(WorkingUnitTerm.SIBLING, workingUnit.getSibling());
document.addTextSortable(WorkingUnitTerm.TREEINDEX, workingUnit.getTreeIndex());
document.addTextSortable(WorkingUnitTerm.ADDRESS, workingUnit.getAddress());
document.addTextSortable(WorkingUnitTerm.TEL_NO, workingUnit.getTelNo());
document.addTextSortable(WorkingUnitTerm.FAX_NO, workingUnit.getFaxNo());
document.addTextSortable(WorkingUnitTerm.EMAIL, workingUnit.getEmail());
document.addTextSortable(WorkingUnitTerm.WEBSITE, workingUnit.getWebsite());
document.addNumberSortable(WorkingUnitTerm.LOGO_FILE_ENTRY_ID, workingUnit.getLogoFileEntryId());
return document;
}
示例3: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(DictGroup dictGroup) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, dictGroup);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(dictGroup.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, dictGroup.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(dictGroup.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(dictGroup.getUserName()));
document.addNumberSortable(DictGroupTerm.GROUP_ID, dictGroup.getGroupId());
document.addNumberSortable(DictGroupTerm.DICT_GROUPID, dictGroup.getDictGroupId());
document.addNumberSortable(DictGroupTerm.DICT_COLLECTIONID, dictGroup.getDictCollectionId());
document.addTextSortable(DictGroupTerm.GROUP_CODE, dictGroup.getGroupCode());
document.addTextSortable(DictGroupTerm.GROUP_NAME, dictGroup.getGroupName());
document.addTextSortable(DictGroupTerm.GROUP_NAME_EN, dictGroup.getGroupNameEN());
document.addTextSortable(DictGroupTerm.GROUP_DESCRIPTION, dictGroup.getGroupDescription());
DictCollection dictCollection = DictCollectionLocalServiceUtil.fetchDictCollection(dictGroup.getDictCollectionId());
String dictCollectionCode = Validator.isNotNull(dictCollection)?dictCollection.getCollectionCode():StringPool.BLANK;
document.addTextSortable(DictGroupTerm.DICT_COLLECTION_CODE, dictCollectionCode);
return document;
}
示例4: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(JobPos jobPos) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, jobPos);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(jobPos.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, jobPos.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(jobPos.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(jobPos.getUserName()));
document.addNumberSortable(JobPosTerm.GROUP_ID, jobPos.getGroupId());
document.addNumberSortable(JobPosTerm.JOBPOS_ID, jobPos.getJobPosId());
document.addTextSortable(JobPosTerm.TITLE, jobPos.getTitle());
document.addTextSortable(JobPosTerm.DESCRIPTION, jobPos.getDescription());
document.addNumberSortable(JobPosTerm.MAPPING_ROLE_ID, jobPos.getMappingRoleId());
document.addNumberSortable(JobPosTerm.LEADER, jobPos.getLeader());
return document;
}
示例5: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(Contact contact) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, contact);
// Set document field values (in alphabetical order)
document.addTextSortable("city", contact.getAddress().getLocality());
document.addTextSortable("company", contact.getCompany());
document.addNumberSortable("contactId", contact.getContactId());
document.addText(Field.CONTENT, contact.getCard());
document.addTextSortable("country", contact.getAddress().getCountry());
document.addDateSortable(Field.CREATE_DATE, contact.getCreateDate());
document.addText(Field.DESCRIPTION, "TODO: contact description");
document.addTextSortable("email", contact.getEmail().getAddress());
// TODO: add default fax
document.addTextSortable("fullName", contact.getFullName(false));
document.addKeyword(Field.GROUP_ID, getSiteGroupId(contact.getGroupId()));
// TODO add default impp
document.addDateSortable("modifiedDate", contact.getModifiedDate());
document.addTextSortable(Field.NAME, contact.getName());
document.addTextSortable("phone", contact.getPhone().getNumber());
document.addNumber(Field.STATUS, contact.getStatus());
document.addKeyword(Field.SCOPE_GROUP_ID, contact.getGroupId());
document.addText(Field.TITLE, contact.getName());
document.addTextSortable("url", contact.getUrl());
document.addKeyword("vCardUID", contact.getUid());
document.addTextSortable("x-salutation", contact.getSalutation());
return document;
}
示例6: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(DossierAction object) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, object);
// Indexer of audit fields
document.addNumberSortable(Field.COMPANY_ID, object.getCompanyId());
document.addNumberSortable(Field.GROUP_ID, object.getGroupId());
document.addDateSortable(Field.MODIFIED_DATE, object.getCreateDate());
document.addDateSortable(Field.CREATE_DATE, object.getModifiedDate());
document.addNumberSortable(Field.USER_ID, object.getUserId());
document.addKeywordSortable(Field.USER_NAME, String.valueOf(object.getUserName()));
document.addKeywordSortable(Field.ENTRY_CLASS_NAME, CLASS_NAME);
document.addNumberSortable(Field.ENTRY_CLASS_PK, object.getPrimaryKey());
// add number fields
document.addDateSortable(DossierActionTerm.DUE_DATE, object.getDueDate());
// add number fields
document.addNumberSortable(DossierActionTerm.DOSSIER_ID, object.getDossierId());
document.addNumberSortable(DossierActionTerm.SERVICE_PROCESS_ID, object.getServiceProcessId());
document.addNumberSortable(DossierActionTerm.PREVIOUS_ACTION_ID, object.getPreviousActionId());
document.addNumberSortable(DossierActionTerm.ACTION_OVER_DUE, object.getActionOverdue());
document.addNumberSortable(DossierActionTerm.NEXT_ACTION_ID, object.getNextActionId());
// add text fields
document.addTextSortable(DossierActionTerm.ACTION_CODE, object.getActionCode());
document.addTextSortable(DossierActionTerm.ACTION_NAME, object.getActionName());
document.addTextSortable(DossierActionTerm.ACTION_USER, object.getActionUser());
document.addTextSortable(DossierActionTerm.ACTION_NOTE, object.getActionNote());
document.addTextSortable(DossierActionTerm.SYNC_ACTION_CODE, object.getSyncActionCode());
document.addTextSortable(DossierActionTerm.PENDING, Boolean.toString(object.getPending()));
document.addTextSortable(DossierActionTerm.ROLLBACK_ABLE, Boolean.toString(object.getRollbackable()));
document.addTextSortable(DossierActionTerm.STEP_CODE, object.getStepCode());
document.addTextSortable(DossierActionTerm.STEP_NAME, object.getStepName());
document.addTextSortable(DossierActionTerm.STEP_INSTRUCTION, object.getStepInstruction());
document.addTextSortable(DossierActionTerm.PAYLOAD, object.getPayload());
return document;
}
示例7: getUserProfile
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
public Document getUserProfile(long id, long groupId, ServiceContext serviceContext) {
Employee employee = EmployeeLocalServiceUtil.fetchByF_mappingUserId(groupId, id);
//TODO
// PARTER INFO
Document document = new DocumentImpl();
User user = UserLocalServiceUtil.fetchUser(employee.getMappingUserId());
String screenName = StringPool.BLANK;
String email = StringPool.BLANK;
if(Validator.isNotNull(user)){
screenName = user.getScreenName();
email = user.getEmailAddress();
}
document.addTextSortable("className", Employee.class.getName());
document.addTextSortable("classPK", String.valueOf(employee.getEmployeeId()));
document.addTextSortable("screenName", screenName);
document.addTextSortable("email", email);
document.addTextSortable("fullName", employee.getFullName());
document.addTextSortable("contactEmail", employee.getEmail());
document.addTextSortable("contactTelNo", employee.getTelNo());
document.addNumberSortable("gender", employee.getGender());
document.addDateSortable("birthdate", employee.getBirthdate());
return document;
}
示例8: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(PaymentConfig object) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, object);
// Indexer of audit fields
document.addNumberSortable(Field.COMPANY_ID, object.getCompanyId());
document.addNumberSortable(Field.GROUP_ID, object.getGroupId());
document.addDateSortable(Field.MODIFIED_DATE, object.getCreateDate());
document.addDateSortable(Field.CREATE_DATE, object.getModifiedDate());
document.addNumberSortable(Field.USER_ID, object.getUserId());
document.addKeywordSortable(Field.USER_NAME, String.valueOf(object.getUserName()));
document.addKeywordSortable(Field.ENTRY_CLASS_NAME, CLASS_NAME);
document.addNumberSortable(Field.ENTRY_CLASS_PK, object.getPrimaryKey());
// add text fields
document.addTextSortable(PaymentConfigTerm.GOV_AGENCY_CODE, object.getGovAgencyCode());
document.addTextSortable(PaymentConfigTerm.GOV_AGENCY_NAME, object.getGovAgencyName());
document.addTextSortable(PaymentConfigTerm.GOV_AGENCY_TAX_NO, object.getGovAgencyTaxNo());
document.addTextSortable(PaymentConfigTerm.INVOICE_TEMPLATE_NO, object.getInvoiceTemplateNo());
document.addTextSortable(PaymentConfigTerm.INVOICE_ISSUE_NO, object.getInvoiceIssueNo());
document.addTextSortable(PaymentConfigTerm.INVOICE_LAST_NO, object.getInvoiceLastNo());
document.addTextSortable(PaymentConfigTerm.INVOICE_FORM, object.getInvoiceForm());
document.addTextSortable(PaymentConfigTerm.BANK_INFO, object.getBankInfo());
document.addTextSortable(PaymentConfigTerm.EPAYMENT_CONFIG, object.getEpaymentConfig());
return document;
}
示例9: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(ResourceRole resourceRole) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, resourceRole);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(resourceRole.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, resourceRole.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(resourceRole.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(resourceRole.getUserName()));
document.addNumberSortable(ResourceRoleTerm.GROUP_ID, resourceRole.getGroupId());
document.addNumberSortable(ResourceRoleTerm.RESOURCEROLE_ID, resourceRole.getResourceRoleId());
document.addTextSortable(ResourceRoleTerm.CLASS_NAME, resourceRole.getClassName());
document.addTextSortable(ResourceRoleTerm.CLASS_PK, resourceRole.getClassPK());
document.addNumberSortable(ResourceRoleTerm.ROLE_ID, resourceRole.getRoleId());
document.addTextSortable("selected", Boolean.TRUE.toString());
Role role = RoleLocalServiceUtil.fetchRole(resourceRole.getRoleId());
String roleName = StringPool.BLANK;
if (Validator.isNotNull(role)) {
roleName = role.getName();
}
document.addTextSortable(ResourceRoleTerm.ROLE_NAME, roleName);
return document;
}
示例10: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(DossierActionSync object) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, object);
// Indexer of audit fields
document.addNumberSortable(Field.COMPANY_ID, object.getCompanyId());
document.addNumberSortable(Field.GROUP_ID, object.getGroupId());
document.addDateSortable(Field.MODIFIED_DATE, object.getCreateDate());
document.addDateSortable(Field.CREATE_DATE, object.getModifiedDate());
document.addNumberSortable(Field.USER_ID, object.getUserId());
document.addKeywordSortable(Field.USER_NAME, String.valueOf(object.getUserName()));
document.addKeywordSortable(Field.ENTRY_CLASS_NAME, CLASS_NAME);
document.addNumberSortable(Field.ENTRY_CLASS_PK, object.getPrimaryKey());
// add number fields
document.addNumberSortable(DossierActionSyncTerm.DOSSIER_ID, object.getDossierId());
document.addNumberSortable(DossierActionSyncTerm.DOSSIER_ACTION_ID, object.getDossierActionId());
// add text fields
document.addTextSortable(DossierActionSyncTerm.CREATE_DOSSIER, Boolean.toString(object.getCreateDossier()));
document.addTextSortable(DossierActionSyncTerm.REFERENCE_UID, object.getReferenceUid());
document.addTextSortable(DossierActionSyncTerm.ACTION_CODE, object.getActionCode());
document.addTextSortable(DossierActionSyncTerm.ACTION_USER, object.getActionUser());
document.addTextSortable(DossierActionSyncTerm.ACTION_NOTE, object.getActionNote());
return document;
}
示例11: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(FileAttach fileAttach) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, fileAttach);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(fileAttach.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, fileAttach.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(fileAttach.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(fileAttach.getUserName()));
document.addNumberSortable(FileAttachTerm.FILEATTACH_ID, fileAttach.getFileAttachId());
document.addNumberSortable(FileAttachTerm.GROUP_ID, fileAttach.getGroupId());
document.addTextSortable(FileAttachTerm.CLASS_NAME, fileAttach.getClassName());
document.addTextSortable(FileAttachTerm.CLASS_PK, fileAttach.getClassPK());
document.addTextSortable(FileAttachTerm.FULLNAME, fileAttach.getFullName());
document.addTextSortable(FileAttachTerm.EMAIL, fileAttach.getEmail());
document.addNumberSortable(FileAttachTerm.FILE_ENTRY_ID, fileAttach.getFileEntryId());
document.addTextSortable(FileAttachTerm.SOURCE, fileAttach.getSource());
document.addTextSortable(FileAttachTerm.SOURCE_URL, fileAttach.getSourceUrl());
document.addNumberSortable(FileAttachTerm.DOCFILE_ID, fileAttach.getDocFileId());
document.addTextSortable(FileAttachTerm.FILE_NAME, fileAttach.getFileName());
document.setSortableTextFields(new String[] { FileAttachTerm.CREATE_DATE });
return document;
}
示例12: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(ResourceUser resourceUser) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, resourceUser);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(resourceUser.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, resourceUser.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(resourceUser.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(resourceUser.getUserName()));
document.addNumberSortable(ResourceUserTerm.GROUP_ID, resourceUser.getGroupId());
document.addNumberSortable(ResourceUserTerm.RESOURCEUSER_ID, resourceUser.getResourceUserId());
document.addTextSortable(ResourceUserTerm.CLASS_NAME, resourceUser.getClassName());
document.addTextSortable(ResourceUserTerm.CLASS_PK, resourceUser.getClassPK());
document.addNumberSortable(ResourceUserTerm.TO_USERID, resourceUser.getToUserId());
document.addTextSortable("selected", Boolean.TRUE.toString());
User user = UserLocalServiceUtil.fetchUser(resourceUser.getToUserId());
String userName = StringPool.BLANK;
String email = StringPool.BLANK;
if(Validator.isNotNull(user)){
userName = user.getFullName();
email = user.getEmailAddress();
}
document.addTextSortable(ResourceUserTerm.TO_USERNAME, userName);
document.addTextSortable(ResourceUserTerm.EMAIL, email);
document.addTextSortable(ResourceUserTerm.USERCLASS, Employee.class.getName());
return document;
}
示例13: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(EmployeeJobPos employeeJobPos) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, employeeJobPos);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(employeeJobPos.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, employeeJobPos.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(employeeJobPos.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(employeeJobPos.getUserName()));
document.addNumberSortable(EmployeeJobPosTerm.GROUP_ID, employeeJobPos.getGroupId());
document.addNumberSortable(EmployeeJobPosTerm.EMPLOYEE_JOBPOST_ID, employeeJobPos.getEmployeeJobPosId());
document.addNumberSortable(EmployeeJobPosTerm.EMPLOYEE_ID, employeeJobPos.getEmployeeId());
document.addNumberSortable(EmployeeJobPosTerm.JOBPOST_ID, employeeJobPos.getJobPostId());
document.addNumberSortable(EmployeeJobPosTerm.WORKING_UNIT_ID, employeeJobPos.getWorkingUnitId());
WorkingUnit workingUnit = WorkingUnitLocalServiceUtil.fetchWorkingUnit(employeeJobPos.getWorkingUnitId());
document.addTextSortable(EmployeeJobPosTerm.WORKING_UNIT_NAME, Validator.isNotNull(workingUnit)?workingUnit.getName():StringPool.BLANK);
String title = StringPool.BLANK;
int leader = 0;
JobPos jobPos = JobPosLocalServiceUtil.fetchJobPos(employeeJobPos.getJobPostId());
if(Validator.isNotNull(jobPos)){
title = jobPos.getTitle();
leader = jobPos.getLeader();
}
document.addTextSortable(EmployeeJobPosTerm.JOBPOST_TITLE, title);
document.addNumberSortable(EmployeeJobPosTerm.LEADER, leader);
return document;
}
示例14: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(Holiday holiday) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, holiday);
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(holiday.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, holiday.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(holiday.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(holiday.getUserName()));
document.addNumberSortable(HolidayTerm.HOLIDAY_ID, holiday.getHolidayId());
document.addDateSortable(HolidayTerm.HOLIDAY_DATE, holiday.getHolidayDate());
document.addNumberSortable(HolidayTerm.GROUP_ID, holiday.getGroupId());
document.addTextSortable(HolidayTerm.DESCRIPTION, holiday.getDescription());
Calendar cal = Calendar.getInstance();
cal.setTime(holiday.getHolidayDate());
String dateTime = String.valueOf(cal.get(Calendar.YEAR));
document.addTextSortable("year", dateTime);
document.setSortableTextFields(
new String[] { HolidayTerm.CREATE_DATE});
return document;
}
示例15: doGetDocument
import com.liferay.portal.kernel.search.Document; //导入方法依赖的package包/类
@Override
protected Document doGetDocument(Notificationtemplate notificationtemplates) throws Exception {
Document document = getBaseModelDocument(CLASS_NAME, notificationtemplates);
document.addNumberSortable(NotificationTemplateTerm.GROUP_ID, notificationtemplates.getGroupId());
document.addKeywordSortable(Field.COMPANY_ID, String.valueOf(notificationtemplates.getCompanyId()));
document.addDateSortable(Field.MODIFIED_DATE, notificationtemplates.getModifiedDate());
document.addKeywordSortable(Field.USER_ID, String.valueOf(notificationtemplates.getUserId()));
document.addKeywordSortable(Field.USER_NAME, String.valueOf(notificationtemplates.getUserName()));
document.addTextSortable(NotificationTemplateTerm.SEND_EMAIL,
String.valueOf(notificationtemplates.getSendEmail()));
document.addTextSortable(NotificationTemplateTerm.NOTIFICATTION_TYPE,
notificationtemplates.getNotificationType());
document.addNumberSortable(NotificationTemplateTerm.GROUP_ID, notificationtemplates.getGroupId());
document.addNumberSortable(NotificationTemplateTerm.USER_ID, notificationtemplates.getUserId());
document.addNumberSortable(NotificationTemplateTerm.COMPANY_ID, notificationtemplates.getCompanyId());
document.addNumberSortable(NotificationTemplateTerm.NOTIFICATIONTEMPLATE_ID,
notificationtemplates.getNotificationTemplateId());
document.addTextSortable(NotificationTemplateTerm.NOTIFICATION_EMAIL_SUBJECT,
notificationtemplates.getEmailSubject());
document.addTextSortable(NotificationTemplateTerm.NOTIFICATION_EMAIL_BODY,
notificationtemplates.getEmailBody());
document.addTextSortable(NotificationTemplateTerm.NOTIFICATION_TEXT_MESSAGE,
notificationtemplates.getTextMessage());
document.addTextSortable(NotificationTemplateTerm.NOTIFICATION_SEND_SMS,
String.valueOf(notificationtemplates.getSendSMS()));
document.addNumberSortable(NotificationTemplateTerm.EXPIRE_DURATION,
notificationtemplates.getExpireDuration());
document.addTextSortable(NotificationTemplateTerm.USER_URL_PARTTERN,
notificationtemplates.getUserUrlPattern());
document.addTextSortable(NotificationTemplateTerm.GUEST_URL_PARTTERN,
notificationtemplates.getGuestUrlPattern());
document.addTextSortable(NotificationTemplateTerm.INTERVAL,
notificationtemplates.getInterval());
document.addTextSortable(NotificationTemplateTerm.GROUPING,
String.valueOf(notificationtemplates.getGrouping()));
document.setSortableTextFields(new String[] { NotificationTemplateTerm.NOTIFICATTION_TYPE });
return document;
}