Package utils

Examples of utils.WeekIndex


        }

        ReceptionDayDTO dto = (ReceptionDayDTO) command;
        HashMap model = new HashMap();

        WeekIndex weekIndex = new WeekIndex(new WeekIndex(new Date()).getIndex() + dto.getWeek());
        ReceptionHelper rh = new ReceptionHelper(getDao(), dto,
                weekIndex.getBegin().getTime(), weekIndex.getEnd().getTime());
        List<WeekDay> weekDays = rh.getModel();

        int day = dto.getDay();
        WeekDay weekDay = weekDays.get(day-1 < 0 ? 0 : (day-1) % 7);
View Full Code Here


    protected Map referenceData(HttpServletRequest request, Object command, Errors errors) throws Exception {
        ReceptionWeekDTO dto = (ReceptionWeekDTO) command;

        HashMap model = new HashMap();

        WeekIndex weekIndex = new WeekIndex();
        weekIndex = new WeekIndex(weekIndex.getIndex() + dto.getWeek());
        ReceptionHelper rh = new ReceptionHelper(getDao(), dto,
                weekIndex.getBegin().getTime(), weekIndex.getEnd().getTime());

        model.put("weekdays", rh.getModel());
        model.put("pageBreadcrumb", initBreadCrumb(dto.getClient(), dto.getType(), dto.getLpu(), dto.getCollaborator()));
       
        return model;
View Full Code Here

     */
    private List<SheduleIndividualWork> getPlanWorks(Day day) {
        if(plWorks == null) {
            plWorks = getPlanWorks();
        }
        WeekIndex weekIndex = new WeekIndex(day);
        int weekPeriod = dto.getCollaborator().getWeekPeriod();
        int planWeekIndex = weekIndex.getIndex() % (weekPeriod + 1);
        int dayOfWeek = day.getDayOfWeek().getEuropean();
        int hash = planWeekIndex*7 + dayOfWeek + 1;
        return plWorks.get(hash);
    }
View Full Code Here

TOP

Related Classes of utils.WeekIndex

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.