Package com.mossle.bpm.persistence.domain

Examples of com.mossle.bpm.persistence.domain.BpmMailTemplate


    @RequestMapping("bpm-mail-template-input")
    public String input(@RequestParam(value = "id", required = false) Long id,
            Model model) {
        if (id != null) {
            BpmMailTemplate bpmMailTemplate = bpmMailTemplateManager.get(id);
            model.addAttribute("model", bpmMailTemplate);
        }

        return "bpm/bpm-mail-template-input";
    }
View Full Code Here


    }

    @RequestMapping("bpm-mail-template-save")
    public String save(@ModelAttribute BpmMailTemplate bpmMailTemplate,
            RedirectAttributes redirectAttributes) {
        BpmMailTemplate dest = null;
        Long id = bpmMailTemplate.getId();

        if (id != null) {
            dest = bpmMailTemplateManager.get(id);
            beanMapper.copy(bpmMailTemplate, dest);
View Full Code Here

    @RequestMapping("bpm-mail-template-input")
    public String input(@RequestParam(value = "id", required = false) Long id,
            Model model) {
        if (id != null) {
            BpmMailTemplate bpmMailTemplate = bpmMailTemplateManager.get(id);
            model.addAttribute("model", bpmMailTemplate);
        }

        return "bpm/bpm-mail-template-input";
    }
View Full Code Here

    }

    @RequestMapping("bpm-mail-template-save")
    public String save(@ModelAttribute BpmMailTemplate bpmMailTemplate,
            RedirectAttributes redirectAttributes) {
        BpmMailTemplate dest = null;
        Long id = bpmMailTemplate.getId();

        if (id != null) {
            dest = bpmMailTemplateManager.get(id);
            beanMapper.copy(bpmMailTemplate, dest);
View Full Code Here

                getInitiator(userConnector, delegateTask));
        logger.debug("initiator : {}", delegateTask.getVariable("initator"));
        logger.debug("variables : {}", delegateTask.getVariables());

        String receiver = bpmConfNotice.getReceiver();
        BpmMailTemplate bpmMailTemplate = bpmConfNotice.getBpmMailTemplate();
        ExpressionManager expressionManager = Context
                .getProcessEngineConfiguration().getExpressionManager();
        UserDTO userDto = null;
        String subject = expressionManager
                .createExpression(bpmMailTemplate.getSubject())
                .getValue(taskEntity).toString();

        String content = expressionManager
                .createExpression(bpmMailTemplate.getContent())
                .getValue(taskEntity).toString();

        if ("任务接收人".equals(receiver)) {
            userDto = userConnector.findById(delegateTask.getAssignee());
        } else if ("流程发起人".equals(receiver)) {
View Full Code Here

                        delegateTask.getAssignee()).getDisplayName());
                taskEntity.setVariableLocal("initiator",
                        getInitiator(userConnector, delegateTask));

                String receiver = bpmConfNotice.getReceiver();
                BpmMailTemplate bpmMailTemplate = bpmConfNotice
                        .getBpmMailTemplate();
                ExpressionManager expressionManager = Context
                        .getProcessEngineConfiguration().getExpressionManager();

                UserDTO userDto = null;

                if ("任务接收人".equals(receiver)) {
                    userDto = userConnector
                            .findById(delegateTask.getAssignee());
                } else if ("流程发起人".equals(receiver)) {
                    userDto = userConnector.findById((String) delegateTask
                            .getVariables().get("initiator"));
                } else {
                    HistoricProcessInstanceEntity historicProcessInstanceEntity = Context
                            .getCommandContext()
                            .getHistoricProcessInstanceEntityManager()
                            .findHistoricProcessInstance(
                                    delegateTask.getProcessInstanceId());
                    userDto = userConnector
                            .findById(historicProcessInstanceEntity
                                    .getStartUserId());
                }

                String subject = expressionManager
                        .createExpression(bpmMailTemplate.getSubject())
                        .getValue(taskEntity).toString();

                String content = expressionManager
                        .createExpression(bpmMailTemplate.getContent())
                        .getValue(taskEntity).toString();

                this.sendMail(userDto, subject, content);
                this.sendSiteMessage(userDto, subject, content);
            }
View Full Code Here

                delegateTask.getAssignee()).getDisplayName());
        taskEntity.setVariableLocal("initiator",
                getInitiator(userConnector, delegateTask));

        String receiver = bpmConfNotice.getReceiver();
        BpmMailTemplate bpmMailTemplate = bpmConfNotice.getBpmMailTemplate();
        ExpressionManager expressionManager = Context
                .getProcessEngineConfiguration().getExpressionManager();
        UserDTO userDto = null;

        if ("任务接收人".equals(receiver)) {
            userDto = userConnector.findById(delegateTask.getAssignee());
        } else if ("流程发起人".equals(receiver)) {
            userDto = userConnector.findById((String) delegateTask
                    .getVariables().get("initiator"));
        } else {
            HistoricProcessInstanceEntity historicProcessInstanceEntity = Context
                    .getCommandContext()
                    .getHistoricProcessInstanceEntityManager()
                    .findHistoricProcessInstance(
                            delegateTask.getProcessInstanceId());
            userDto = userConnector.findById(historicProcessInstanceEntity
                    .getStartUserId());
        }

        String subject = expressionManager
                .createExpression(bpmMailTemplate.getSubject())
                .getValue(taskEntity).toString();

        String content = expressionManager
                .createExpression(bpmMailTemplate.getContent())
                .getValue(taskEntity).toString();
        this.sendMail(userDto, subject, content);
        this.sendSiteMessage(userDto, subject, content);
    }
View Full Code Here

TOP

Related Classes of com.mossle.bpm.persistence.domain.BpmMailTemplate

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.