Examples of Leave


Examples of me.kafeitu.demo.activiti.entity.oa.Leave

  public void setUp() throws Exception {
  }

  @Test
  public void testSave() {
    Leave leave = new Leave();
    leave.setApplyTime(new Date());
    leave.setStartTime(new jodd.datetime.JDateTime("2012-05-22").convertToSqlDate());
    leave.setEndTime(new jodd.datetime.JDateTime("2012-05-23").convertToSqlDate());
    leave.setLeaveType("公休");
    leave.setUserId("kafeitu");
    leave.setReason("no reason");
    leaveManager.saveLeave(leave);
   
    assertNotNull(leave.getId());
   
    Leave newLeave = leaveManager.getLeave(leave.getId());
    assertNotNull(newLeave);
  }
View Full Code Here

Examples of me.kafeitu.demo.activiti.entity.oa.Leave

  //如果你需要真正插入数据库,将Rollback设为false
  //@Rollback(false)
  public void crudEntity() {

    // 保存请假
    Leave leave = new Leave();
    leave.setApplyTime(new Date());
    leave.setStartTime(new jodd.datetime.JDateTime("2012-05-22").convertToSqlDate());
    leave.setEndTime(new jodd.datetime.JDateTime("2012-05-23").convertToSqlDate());
    leave.setLeaveType("公休");
    leave.setUserId("kafeitu");
    leave.setReason("no reason");
    entityDao.save(leave);
    em.flush();

    // 获取用户
    leave = entityDao.findOne(leave.getId());
    assertNotNull(leave);

    // 删除请假
    entityDao.delete(leave);
    em.flush();

    // 获取用户
    leave = entityDao.findOne(leave.getId());
    assertNull(leave);
  }
View Full Code Here

Examples of org.mcsg.survivalgames.commands.Leave

    commands.put("getcount", new ListArenas());
    commands.put("disable", new Disable());
    commands.put("start", new ForceStart());
    commands.put("enable", new Enable());
    commands.put("vote", new Vote());
    commands.put("leave", new Leave());
    commands.put("setlobbyspawn", new SetLobbySpawn());
    commands.put("setlobbywall", new SetLobbyWall());
    commands.put("resetspawns", new ResetSpawns());
    commands.put("delarena", new DelArena());
    commands.put("flag", new Flag());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.