Package domain.shedule

Examples of domain.shedule.SheduleReception


    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest hsr, HttpServletResponse hsr1) throws Exception {
        String receptionStr = hsr.getParameter("reception");
        if (receptionStr != null && !receptionStr.isEmpty()) {
            try {
                SheduleReception sheduleReception = CH.get(getDao(), SheduleReception.class, receptionStr);
                sheduleReception.setConfirmed(true);
                getDao().save(sheduleReception);
            } catch (Exception ex) {
            }
        }
        return new ModelAndView("redirect:/operator/reception/receptionsearch.htm");
View Full Code Here


    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest hsr, HttpServletResponse hsr1) throws Exception {
        String receptionStr = hsr.getParameter("reception");
        if (receptionStr != null && !receptionStr.isEmpty()) {
            try {
                SheduleReception sheduleReception = CH.get(getDao(), SheduleReception.class, receptionStr);

                //Ебём мозг, что б с помощю ресепшн хедлпера нарезать тикеты
                //Готови данные
                ReceptionDTO rdto = new ReceptionDTO();
                rdto.setClient(sheduleReception.getClient());
                rdto.setCollaborator(sheduleReception.getCollaborator());
                rdto.setLpu(sheduleReception.getCollaborator().getLpu());
                rdto.setType(sheduleReception.getWorkType());
                Day day = new Day(sheduleReception.getBegin());
                ReceptionHelper rhBefore = new ReceptionHelper(getDao(), rdto, day.getDate(), day.getEndDate());
                WeekDay weekDay = rhBefore.getModel().get(0);
                List<Ticket> ticketsBefore = weekDay.getTickets();

                getDao().delete(sheduleReception);
View Full Code Here

        if (conflictList.size() > 0) {
            autoconfirm = false;
            //т.к. это рабочее место оператора, то посылать сообщение пользователю ненадо
        }

        SheduleReception reception = new SheduleReception();
        reception.setAuthor(getDao().getById(Collaborator.class, getUserInfo().getCurrentCollaboratorId()));
        reception.setCollaborator(dto.getCollaborator());
        reception.setBegin(cal.getTime());
        reception.setClient(dto.getClient());
        reception.setDuration(ticket.getDuration());
        reception.setDescription(dto.getType().getDescription());
        reception.setConfirmed(autoconfirm);
        reception.setRegister(new Date());
        reception.setWorkType(dto.getType());
        getDao().save(reception);

        ticket.setBuzy(true);
        updater.addTicketP(dto.getCollaborator(), dto.getType(), ticket);
View Full Code Here

* @author axe
*/
public class TicketConfirmer extends DaoSupportImpl {

    public String confirm(int recId) {
        SheduleReception rec = getDao().getById(SheduleReception.class, recId);
        if(rec == null) {
            return "Нет такой записи";
        }
        if(rec.getConfirmed()) {
            return "Эта запись уже подтверждена";
        }
        rec.setConfirmed(true);
        try {
            getDao().save(rec);
        } catch(Exception ex) {
            return "Не удалось подтвердить запись";
        }
View Full Code Here

        }
        return null;
    }

    public String reject(int recId) {
        SheduleReception rec = getDao().getById(SheduleReception.class, recId);
        if(rec == null) {
            return "Нет такой записи";
        }
        try {
            getDao().delete(rec);
View Full Code Here

        List<SheduleReception> conflictList = getDao().getList(queryCriteria, 0, 0);
        if (conflictList.size() > 0) {
            autoconfirm = false;
            //т.к. это рабочее место оператора, то посылать сообщение пользователю ненадо
        }
        SheduleReception reception = new SheduleReception();
        //STUB
        reception.setAuthor(getDao().getById(Collaborator.class, UserInfo.CURRENT_COLLABORATOR_ID));
        //reception.setAuthor(dto.getCollaborator());
        //ENDSTUB
        reception.setCollaborator(dto.getCollaborator());
        reception.setBegin(cal.getTime());
        reception.setClient(dto.getClient());
        reception.setDuration(ticket.getDuration());
       
        reception.setDescription(dto.getType().getDescription()== null ? "":dto.getType().getDescription());
        reception.setConfirmed(autoconfirm);
        reception.setRegister(new Date());
        reception.setWorkType(dto.getType());
        getDao().save(reception);

        return new ModelAndView("redirect:/reception/list.htm");
    }
View Full Code Here

    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest hsr, HttpServletResponse hsr1) throws Exception {
        String receptionStr = hsr.getParameter("reception");
        if (receptionStr != null && !receptionStr.isEmpty()) {
            try {
                SheduleReception sheduleReception = CH.get(getDao(), SheduleReception.class, receptionStr);
                getDao().delete(sheduleReception);
            } catch (Exception ex) {
            }
        }
        return new ModelAndView("redirect:list.htm");
View Full Code Here

TOP

Related Classes of domain.shedule.SheduleReception

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.