Package org.zkoss.zul

Examples of org.zkoss.zul.Datebox


                r.setChecked(true);
            }
        }


        Datebox birthdayDB = (Datebox) getFellow("birthday");
        Textbox homePhoneTB = (Textbox) getFellow("homePhone");
        Textbox mobileTB = (Textbox) getFellow("mobile");
        Textbox informPeopleTB = (Textbox) getFellow("informPeople");
        Textbox relationTB = (Textbox) getFellow("relation");

        birthdayDB.setValue(form.getBirthday());
        homePhoneTB.setText(form.getHomePhone());
        mobileTB.setText(form.getMobile());
        informPeopleTB.setText(form.getInformPeople());
        relationTB.setText(form.getRelation());
View Full Code Here


            var.setCompany((Org) companyCB.getSelectedItem().getValue());
        }
        var.setSex(sexRG.getSelectedItem().getValue());


        Datebox birthdayDB = (Datebox) getFellow("birthday");
        Textbox homePhoneTB = (Textbox) getFellow("homePhone");
        Textbox mobileTB = (Textbox) getFellow("mobile");
        Textbox informPeopleTB = (Textbox) getFellow("informPeople");
        Textbox relationTB = (Textbox) getFellow("relation");

        var.setBirthday(birthdayDB.getValue());
        var.setHomePhone(homePhoneTB.getText());
        var.setMobile(mobileTB.getText());
        var.setInformPeople(informPeopleTB.getText());
        var.setRelation(relationTB.getText());
View Full Code Here

    public void objToView(Object obj) {
        RequestMaintainForm form = (RequestMaintainForm) obj;

        Textbox requestByTB = (Textbox) getFellow("requestBy");
        Datebox requestAtDate = (Datebox) getFellow("requestAtDate");
        Timebox requestAtTime = (Timebox) getFellow("requestAtTime");
        Combobox statusCB = (Combobox) getFellow("status");
        Textbox requestMobilePhoneTB = (Textbox) getFellow("requestMobilePhone");
        Combobox urgentLevelCB = (Combobox) getFellow("urgentLevel");

        requestByTB.setText(form.getRequestBy());
        requestAtDate.setValue(form.getRequestAt());
        requestAtTime.setValue(form.getRequestAt());
        Iterator statusCBItr = statusCB.getItems().iterator();
        while (statusCBItr.hasNext()) {
            Comboitem item = (Comboitem) statusCBItr.next();
            if (item.getValue().toString().equals(form.getStatus())) {
                statusCB.setSelectedItem(item);
            }
        }
        requestMobilePhoneTB.setText(form.getRequestMobilePhone());

        Textbox requestMaintainNoTB = (Textbox) getFellow("requestMaintainNo");
        Combobox buildingCB = (Combobox) getFellow("building");
        Textbox requestReasonTB = (Textbox) getFellow("requestReason");
        Datebox firstResponseAtDate = (Datebox) getFellow("firstResponseAtDate");
        Timebox firstResponseAtTime = (Timebox) getFellow("firstResponseAtTime");
        Textbox responseMessageTB = (Textbox) getFellow("responseMessage");

        requestMaintainNoTB.setText(form.getRequestMaintainNo());
        Iterator buildingCBItr = buildingCB.getItems().iterator();
        while (buildingCBItr.hasNext()) {
            Comboitem item = (Comboitem) buildingCBItr.next();
            Building building = (Building) item.getValue();
            if (building.getBuildingId().toString().equals(form.getBuildingId().toString())) {
                buildingCB.setSelectedItem(item);
            }
        }
        requestReasonTB.setText(form.getRequestReason());
        firstResponseAtDate.setValue(form.getFirstResponseAt());
        firstResponseAtTime.setValue(form.getFirstResponseAt());
        responseMessageTB.setText(form.getResponseMessage());

        Datebox responseSolutionAtDate = (Datebox) getFellow("responseSolutionAtDate");
        Timebox responseSolutionAtTime = (Timebox) getFellow("responseSolutionAtTime");
        Textbox solutionMessageTB = (Textbox) getFellow("solutionMessage");

        responseSolutionAtDate.setValue(form.getResponseSolutionAt());
        responseSolutionAtTime.setValue(form.getResponseSolutionAt());
        solutionMessageTB.setText(form.getSolutionMessage());


View Full Code Here

                iae.printStackTrace();
            }
        }

        Textbox requestByTB = (Textbox) getFellow("requestBy");
        Datebox requestAtDate = (Datebox) getFellow("requestAtDate");
        Timebox requestAtTime = (Timebox) getFellow("requestAtTime");
        Combobox statusCB = (Combobox) getFellow("status");
        Textbox requestMobilePhoneTB = (Textbox) getFellow("requestMobilePhone");
        Combobox urgentLevelCB = (Combobox) getFellow("urgentLevel");

        var.setRequestBy(requestByTB.getText());
        if (requestAtDate.getValue() != null
                && requestAtTime.getValue() != null) {
            Timestamp requestAt = new Timestamp(requestAtDate.getValue().getTime());
            requestAt.setHours(requestAtTime.getValue().getHours());
            requestAt.setMinutes(requestAtTime.getValue().getMinutes());
            var.setRequestAt(requestAt);
        }
        var.setStatus(statusCB.getSelectedItem().getValue().toString());
        var.setRequestMobilePhone(requestMobilePhoneTB.getText());
        var.setUrgentLevel(urgentLevelCB.getSelectedItem().getValue().toString());

        Textbox requestMaintainNoTB = (Textbox) getFellow("requestMaintainNo");
        Combobox buildingCB = (Combobox) getFellow("building");
        Textbox requestReasonTB = (Textbox) getFellow("requestReason");
        Datebox firstResponseAtDate = (Datebox) getFellow("firstResponseAtDate");
        Timebox firstResponseAtTime = (Timebox) getFellow("firstResponseAtTime");
        Textbox responseMessageTB = (Textbox) getFellow("responseMessage");

        var.setRequestMaintainNo(requestMaintainNoTB.getText());
        var.setBuilding((Building) buildingCB.getSelectedItem().getValue());
        var.setRequestReason(requestReasonTB.getText());
        if (firstResponseAtDate.getValue() != null
                && firstResponseAtTime.getValue() != null) {
            Timestamp firstResponseAt = new Timestamp(firstResponseAtDate.getValue().getTime());
            firstResponseAt.setHours(firstResponseAtTime.getValue().getHours());
            firstResponseAt.setMinutes(firstResponseAtTime.getValue().getMinutes());
            var.setFirstResponseAt(firstResponseAt);
        }


        var.setResponseMessage(responseMessageTB.getText());

        Datebox responseSolutionAtDate = (Datebox) getFellow("responseSolutionAtDate");
        Timebox responseSolutionAtTime = (Timebox) getFellow("responseSolutionAtTime");
        Textbox solutionMessageTB = (Textbox) getFellow("solutionMessage");

        if (responseSolutionAtDate.getValue() != null
                && responseSolutionAtTime.getValue() != null) {
            Timestamp responseSolutionAt = new Timestamp(responseSolutionAtDate.getValue().getTime());
            responseSolutionAt.setHours(responseSolutionAtTime.getValue().getHours());
            responseSolutionAt.setMinutes(responseSolutionAtTime.getValue().getMinutes());
            var.setResponseSolutionAt(responseSolutionAt);
        }
        var.setSolutionMessage(solutionMessageTB.getText());
View Full Code Here

            if (authForm.getAuthId().toString().equals(obj.getAuthId().toString())) {
                authListbox.setSelectedItem(item);
            }
        }

        Datebox validAfterDate = (Datebox) getFellow("validAfterDate");
        Timebox validAfterTime = (Timebox) getFellow("validAfterTime");
        if (obj.getValidAfter() != null) {
            validAfterDate.setValue(obj.getValidAfter());
            validAfterTime.setValue(obj.getValidAfter());
        }

        Datebox validBeforeDate = (Datebox) getFellow("validBeforeDate");
        Timebox validBeforeTime = (Timebox) getFellow("validBeforeTime");
        if (obj.getValidBefore() != null) {
            validBeforeDate.setValue(obj.getValidBefore());
            validBeforeTime.setValue(obj.getValidBefore());
        }

    }
View Full Code Here

        var.setUser(user);
        Listbox authListbox = (Listbox) getFellow("auth");
        var.setAuth((Auth) (authListbox.getSelectedItem()).getValue());

        Datebox validAfterDate = (Datebox) getFellow("validAfterDate");
        Timebox validAfterTime = (Timebox) getFellow("validAfterTime");
        if (validAfterDate.getValue() != null
                && validAfterTime.getValue() != null) {
            Timestamp validAfter = new Timestamp(validAfterDate.getValue().getTime());
            validAfter.setHours(validAfterTime.getValue().getHours());
            validAfter.setMinutes(validAfterTime.getValue().getMinutes());
            var.setValidAfter(validAfter);
        }

        Datebox validBeforeDate = (Datebox) getFellow("validBeforeDate");
        Timebox validBeforeTime = (Timebox) getFellow("validBeforeTime");
        if (validBeforeDate.getValue() != null
                && validBeforeTime.getValue() != null) {
            Timestamp validBefore = new Timestamp(validBeforeDate.getValue().getTime());
            validBefore.setHours(validBeforeTime.getValue().getHours());
            validBefore.setMinutes(validBeforeTime.getValue().getMinutes());
            var.setValidBefore(validBefore);
        }
View Full Code Here

        private void appendValidFromListcell(Listitem item,
                final CalendarAvailability calendarAvailability) {
            Listcell listcell = new Listcell();

            final Datebox datebox = new Datebox();
            Datebox dateboxValidFrom = Util.bind(datebox,
                    new Util.Getter<Date>() {

                        @Override
                        public Date get() {
                            LocalDate startDate = calendarAvailability
View Full Code Here

        private void appendExpirationDateListcell(Listitem item,
                final CalendarAvailability calendarAvailability) {
            Listcell listcell = new Listcell();

            final Datebox datebox = new Datebox();
            Datebox dateboxExpirationDate = Util.bind(datebox,
                    new Util.Getter<Date>() {

                        @Override
                        public Date get() {
                            LocalDate endDate = calendarAvailability
View Full Code Here

    public void setStartAllocationDate(Event event) {
        setStartAllocationDate(getSelectedGap().getStartTime());
    }

    public void highlightCalendar(Event event) {
        Datebox datebox = (Datebox) event.getTarget();
        if (datebox.getValue() == null) {
            final LocalDate startDate = getSelectedGap().getStartTime().getDate();
            datebox.setValue(toDate(startDate));
        }

        if (isAppropriative()) {
            final LimitingResourceQueueElement beingEdited = getBeingEditedElement();
            highlightDaysFromDate(datebox.getUuid(), new LocalDate(beingEdited.getEarliestStartDateBecauseOfGantt()));
        } else {
            highlightDaysInGap(datebox.getUuid(), getSelectedGap());
        }
    }
View Full Code Here

            }
        }
    }

    public void createDateBox(Textbox textbox) {
        openedDateBox = new Datebox();
        openedDateBox.setFormat("short");
        openedDateBox.setButtonVisible(false);

        try {
            openedDateBox.setValue(dateFormat.parse(textbox.getValue()));
View Full Code Here

TOP

Related Classes of org.zkoss.zul.Datebox

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.