private void addProcessPropertiesToQuery(Map<QName, Object> processCustomProps, HistoricTaskInstanceQuery taskQuery) { for(Entry<QName, Object> customProperty : processCustomProps.entrySet()) { String name =factory.mapQNameToName(customProperty.getKey()); // Exclude the special "VAR_TENANT_DOMAIN" variable, this cannot be queried by users if(name != ActivitiConstants.VAR_TENANT_DOMAIN) { // Perform minimal property conversions Object converted = propertyConverter.convertPropertyToValue(customProperty.getValue()); taskQuery.processVariableValueEquals(name, converted); } } }
taskInstanceQuery.processVariableValueEquals(variable.getName(), actualValue); break;
private void addProcessPropertiesToQuery(Map<QName, Object> processCustomProps, HistoricTaskInstanceQuery taskQuery) { for(Entry<QName, Object> customProperty : processCustomProps.entrySet()) { String name =factory.mapQNameToName(customProperty.getKey()); // Exclude the special "VAR_TENANT_DOMAIN" variable, this cannot be queried by users if(name != ActivitiConstants.VAR_TENANT_DOMAIN) { // Perform minimal property conversions Object converted = propertyConverter.convertPropertyToValue(customProperty.getValue()); taskQuery.processVariableValueEquals(name, converted); } } }
/** * @param localId String * @return HistoricTaskInstance */ public HistoricTaskInstance getHistoricTaskInstance(String localId) { HistoricTaskInstanceQuery taskQuery = historyService.createHistoricTaskInstanceQuery() .taskId(localId); if(!deployWorkflowsInTenant) { taskQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain()); } return taskQuery.singleResult(); }
/** * @param localId String * @return HistoricTaskInstance */ public HistoricTaskInstance getHistoricTaskInstance(String localId) { HistoricTaskInstanceQuery taskQuery = historyService.createHistoricTaskInstanceQuery() .taskId(localId); if(!deployWorkflowsInTenant) { taskQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain()); } return taskQuery.singleResult(); }
taskQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain());
taskQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain());
taskQuery = taskQuery.processVariableValueEquals("applyUserId", getApplyUserId()); taskQuery = taskQuery.processVariableValueEquals("auditResult", "1".equals(getAuditResult()));
historicQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain()); } else if(tenantService.isEnabled() && !TenantUtil.isCurrentDomainDefault() && !StringUtils.isEmpty(TenantUtil.getCurrentDomain())) {
historicQuery.processVariableValueEquals(ActivitiConstants.VAR_TENANT_DOMAIN, TenantUtil.getCurrentDomain()); } else if(tenantService.isEnabled() && !TenantUtil.isCurrentDomainDefault() && !StringUtils.isEmpty(TenantUtil.getCurrentDomain())) {