JeeSite主要定位于企业信息化领域。网址:http://www.oschina.net/p/jeesite

从描述来看,各种NB,下来看的最主要原因是最近还在更新,觉得有问题可以有一批人一起研究研究。

下来后发现文档还挺多,简单看了一遍,没什么概念,先编译通过然后跑起来才是王道,然后,就是各种坑。

我的环境(win7 64bit, myeclipse10.7.1, jdk1.7,maven-3.3.9)

先来看其中有一个maven压缩包,估计是有一些设置需要在maven中设置,这句话很关键

<;activeProfiles>

  <;activeProfile>thinkgem</activeProfile>

</activeProfiles>

将之加入当前maven中

 

然后修改pom.xml中的jdk版本:

<jdk.version>1.7</jdk.version>

然后发现某些jar包不存在,手动添加如下内容到pom.xml中

 

<restlet-version>2.3.6</restlet-version>

 

 

<repository> 

    <id>maven-restlet</id> 

    <name>Restlet repository</name> 

    <url>https://maven.restlet.com</url> 

</repository>

 

<dependency>

    <groupId>org.apache.commons</groupId>

    <artifactId>commons-email</artifactId>

    <version>1.3.2</version>

</dependency>

<dependency>

    <groupId>org.codehaus.jackson</groupId>

    <artifactId>jackson-mapper-asl</artifactId>

    <version>1.5.0</version>

</dependency>

 

<dependency> 

    <groupId>org.restlet.jse</groupId> 

    <artifactId>org.restlet</artifactId> 

    <version>${restlet-version}</version> 

</dependency> 

<dependency> 

    <groupId>org.restlet.jse</groupId> 

    <artifactId>org.restlet.ext.jackson</artifactId> 

    <version>${restlet-version}</version> 

</dependency> 

 

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-json-converter</artifactId>

    <version>${activiti.version}</version>

</dependency>

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-bpmn-layout</artifactId>

    <version>${activiti.version}</version>

</dependency>

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-bpmn-converter</artifactId>

    <version>${activiti.version}</version>

</dependency>

 

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-common-rest</artifactId>

    <version>${activiti.version}</version>

</dependency>

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-rest</artifactId>

    <version>${activiti.version}</version>

</dependency>

<dependency>

    <groupId>org.activiti</groupId>

    <artifactId>activiti-bpmn-model</artifactId>

    <version>${activiti.version}</version>

</dependency>

 
然后屏蔽如下代码:
/**

 * 根据Model部署流程

 */

@Transactional(readOnly = false)

public String deploy(String id) {

    String message = "";

      try {

        org.activiti.engine.repository.Model modelData = repositoryService.getModel(id);

        BpmnJsonConverter jsonConverter = new BpmnJsonConverter();

        JsonNode editorNode = new ObjectMapper().readTree(repositoryService.getModelEditorSource(modelData.getId()));

        BpmnModel bpmnModel = jsonConverter.convertToBpmnModel(editorNode);

        BpmnXMLConverter xmlConverter = new BpmnXMLConverter();

        byte[] bpmnBytes = xmlConverter.convertToXML(bpmnModel);

        

        String processName = modelData.getName();

        if (!StringUtils.endsWith(processName, ".bpmn20.xml")){

            processName += ".bpmn20.xml";

        }

          System.out.println("========="+processName+"============"+modelData.getName());

        ByteArrayInputStream in = new ByteArrayInputStream(bpmnBytes);

        Deployment deployment = repositoryService.createDeployment().name(modelData.getName())

                .addInputStream(processName, in).deploy();

                  .addString(processName, new String(bpmnBytes)).deploy();

        

        // 设置流程分类

        List<ProcessDefinition> list = repositoryService.createProcessDefinitionQuery().deploymentId(deployment.getId()).list();

        for (ProcessDefinition processDefinition : list) {

            repositoryService.setProcessDefinitionCategory(processDefinition.getId(), modelData.getCategory());

            message = "部署成功,流程ID=" + processDefinition.getId();

        }

        if (list.size() == 0){

            message = "部署失败,没有流程。";

        }

    } catch (Exception e) {

        throw new ActivitiException("设计模型图不正确,检查模型正确性,模型ID="+id, e);

    }*/

    return message;

}

 

/**

 * 导出model的xml文件

 * @throws IOException 

 * @throws JsonProcessingException 

 */

public void export(String id, HttpServletResponse response) {

    try {

/*        org.activiti.engine.repository.Model modelData = repositoryService.getModel(id);

        BpmnJsonConverter jsonConverter = new BpmnJsonConverter();

        JsonNode editorNode = new ObjectMapper().readTree(repositoryService.getModelEditorSource(modelData.getId()));

        BpmnModel bpmnModel = jsonConverter.convertToBpmnModel(editorNode);

        BpmnXMLConverter xmlConverter = new BpmnXMLConverter();

        byte[] bpmnBytes = xmlConverter.convertToXML(bpmnModel);


        ByteArrayInputStream in = new ByteArrayInputStream(bpmnBytes);

        IOUtils.copy(in, response.getOutputStream());

        String filename = bpmnModel.getMainProcess().getId() + ".bpmn20.xml";

        response.setHeader("Content-Disposition", "attachment; filename=" + filename);

        response.flushBuffer();*/

    } catch (Exception e) {

        throw new ActivitiException("导出model的xml文件失败,模型ID="+id, e);

    }

    

}

 

终于编译通过,晚上开始试运行,看看是啥东西

JeeSite试用的更多相关文章

  1. SharePoint Online 申请试用链接地址

    SharePoint Online 申请试用链接地址: https://products.office.com/en-us/business/compare-office-365-for-busine ...

  2. 活动助手Beta用户试用报告

    用户试用报告 1.面向参与者用户 1.1 日常参加各类学习(水综测)活动中,有没有遇到以下问题: (1) 信息来源混乱,不知道靠不靠谱 (2) 每次报名都要重新填写自己的学号手机号,有时候填错了就没综 ...

  3. 创建WP8试用应用

    参考资料: 创建 Windows Phone 的试用应用 如何在 Windows Phone 应用中实现试用体验 Windows Phone 7 开发 31 日谈——第23日:提供试用版应用程序 对资 ...

  4. JeeSite学习笔记~代码生成原理

    1.建立数据模型[单表,一对多表,树状结构表] 用ERMaster建立数据模型,并设定对应表,建立关联关系 2.系统获取对应表原理 1.怎样获取数据库的表 genTableForm.jsp: < ...

  5. 达梦7的试用 与SQLSERVER的简单技术对比

    达梦7的试用 与SQLSERVER的简单技术对比 达梦数据库公司推出了他们的数据库服务管理平台,可以在该平台使用达梦数据库而无须安装达梦7数据库 地址:http://online.dameng.com ...

  6. Beta版本——用户试用与调研报告

    1 引言 1.1 系统概述 ​ 毕设导师智能分配系统是一个用来简化传统手工匹配繁琐操作的系统.本系统将学生报志愿.系负责人收集整理数据.相关人员进行手工分配.反馈选择结果等繁琐的操作转移到线上.把毕设 ...

  7. 【记录】尝试用android-logging-log4j去实现log输出内容到sd卡中的文件的功能

    [背景] 折腾: [记录]给Android中添加log日志输出到文件 期间,已经试了: [记录]尝试用android中microlog4android实现log输出到文件的功能 但是不好用. 然后就是 ...

  8. 代码阅读分析工具Understand 2.0试用

    Understand 2.0是一款源代码阅读分析软件,功能强大.试用过一段时间后,感觉相当不错,确实可以大大提高代码阅读效率.由于Understand功能十分强大,本文不可能详尽地介绍它的所有功能,所 ...

  9. 如何申请国际版Office365和Azure的试用账号

    关键字:国际版.Office365.Azure.试用账号.1美元.信用卡 待续

随机推荐

  1. 博弈论(二分图匹配):NOI 2011 兔兔与蛋蛋游戏

    Description Input 输入的第一行包含两个正整数 n.m. 接下来 n行描述初始棋盘.其中第i 行包含 m个字符,每个字符都是大写英文字母"X".大写英文字母&quo ...

  2. UVa 10029 hash + dp

    题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem& ...

  3. 解放程序猿宝贵的右手(或者是左手) ——Android自动化测试技巧

    解放双手--Android自动化测试 - eclipse_xu - 博客频道 - CSDN.NET 解放程序猿宝贵的右手(或者是左手) --Android自动化测试技巧

  4. CENTOS 7 开放端口设置

    CentOS 7 默认没有使用iptables,所以通过编辑iptables的配置文件来开启80端口是不可以的 CentOS 7 采用了 firewalld 防火墙 如要查询是否开启80端口则: [r ...

  5. java.lang.ClassCastException: Ljava.lang.Object; cannot be cast to com.entity.Advertisem异常

    今天一不小心就碰到了这样的问题,以前从来没有碰到过,在网上搜了很多办法,思路正确,但是还是要根据自己的程序改变. 一开始写的是hql语句进行统计每个月的数据,但是试了很久,程序一直提醒hql语句异常, ...

  6. [置顶] Android布局管理器 - 详细解析布局实现

    布局管理器都是以ViewGroup为基类派生出来的; 使用布局管理器可以适配不同手机屏幕的分辨率,尺寸大小; 布局管理器之间的继承关系 : 在上面的UML图中可以看出, 绝对布局 帧布局 网格布局 相 ...

  7. 如何优化cocos2d程序的内存使用和程序大小:第二部分_(转)

    减少你的程序的大小 把纹理的颜色位深度减少到16位,不仅可以减少内存压力,还可以有效地减少程序的体积.但是,我们还有其它方法可以更进一步地减少程序的大小. TexturePacker PNG 图片优化 ...

  8. php开发工具zendstudio13破解补丁

    io?  Intelligent Code Editor Robust Debugging Capabilities Eclipse Ecosystem Mobile: AngularJS, Ioni ...

  9. ZEDBOARD启动自启配置(加载镜像) 分类: OpenCV ubuntu shell ZedBoard Eye_Detection 2014-11-08 18:53 167人阅读 评论(0) 收藏

    参考:陆书14.2.8 1)备份ramdisk8M.image.gz 2)加载rootfs镜像文件: 3)在镜像目录下建立自己所需文件夹(挂载目录): 我需要的挂载目录有两个: root/qt/ins ...

  10. [置顶] Linux 流量控制

    在如今的网络界,也许TC知道的人并不多了,这篇文章做留恋吧. 以前研究TC时记录下的讲解与配置文件. eth1:192.168.1.1,内网口  业务需求:保证正常的网页浏览,FTP,SMTP,POP ...