Package clips.delegate.client

Examples of clips.delegate.client.ClientLocal



    @Override
    public Object getValueAt(int r, int c) {
        try {
            ClientLocal cl = clientList.get(r);
            switch (c) {
                case COL_FIO: {
                    return cl.getSurname() + " " + cl.getName() + " " +
                            cl.getPathron();
                }
                case COL_DATE: {
                    return cl.getBorn();
                }
                case COLCOUNT: {
                    return cl.getID();
                }
                default:
                    throw new IllegalArgumentException("Invalid column : " + c);
            }
        } catch (ClipsException ex) {
View Full Code Here


     * @param evt
     */
    private void btNewClientActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btNewClientActionPerformed
        if (mode == MODE_FIND) {
            try {
                ClientLocal clientLocal = new ClientLocal(getAuditManager());
                CardInfo cardInfo = ((AppMainWindow) MainWindow.getMainWindow()).getCardInfo();
                if (cardInfo != null){
                    DirectorySurname surname = DirectoryLocator.getDirectory(DirectorySurname.class);
                    DirectoryName name = DirectoryLocator.getDirectory(DirectoryName.class);
                    DirectoryPathron pathron = DirectoryLocator.getDirectory(DirectoryPathron.class);
                    clientLocal.setSurname(surname.getItemFromTitle(cardInfo.surname));
                    clientLocal.setName(name.getItemFromTitle(cardInfo.name));
                    clientLocal.setPathron(pathron.getItemFromTitle(cardInfo.patron));
                    clientLocal.setBorn(cardInfo.born);
                    clientLocal.setInn(cardInfo.inn);
                    clientLocal.setSex(dirSex.getItemFromTitle(cardInfo.sex));
                    clientLocal.setSnils(cardInfo.snils);
                }
                PanelClientEdit panel = new PanelClientEdit(getContainer(), clientLocal);
                PageGeneric page = getContainer().addNewPage((PageGeneric) panel, null);
                getContainer().activatePage(page);
            } catch (PageException ex) {
View Full Code Here

@TagToClass(tagName="pacient_name",title="Имя пациента")
public class CertTagPacientName extends TypeTextField {
   
    public CertTagPacientName(CertificateLocal certificateLocal, ReportParam reportParam, DiseaseLocal diseaseLocal) throws ClipsException {
        super(certificateLocal, reportParam, diseaseLocal);
        ClientLocal clientLocal = certificateLocal.getClientLocal();
        if (certificateLocal.isNewlyCreated()) {
            String name = clientLocal.getName().toString();
            setText(name, true);
        }
    }
View Full Code Here

@TagToClass(tagName="pacient_pathron",title="Отчество пациента")
public class CertTagPacientPathron extends TypeTextField {
   
    public CertTagPacientPathron(CertificateLocal certificateLocal, ReportParam reportParam, DiseaseLocal diseaseLocal) throws ClipsException {
        super(certificateLocal, reportParam, diseaseLocal);
        ClientLocal clientLocal = certificateLocal.getClientLocal();
        if (certificateLocal.isNewlyCreated()) {
            String pathron = clientLocal.getPathron().toString();
            setText(pathron, true);
        }
    }
View Full Code Here

        //Фиелды до таблицы
        String fieldName;
        String fieldValue;
        ExtraField extraField;
       
        ClientLocal client = serRen.getPolisData().getClient(getAuditListener());
        fieldName = "Пациент: ";
        fieldValue = client.toString();
        if (isAnalysys) {
            fieldValue += " (" + Converter.dateToString(client.getBorn()) + ")";
        }
        extraField = new ExtraField(fieldValue, fieldName, AlignmentType.left);
        analyseReporter.addField(extraField, false);
               
        if (isAnalysys) {
View Full Code Here

        return new SicklistLocal(details, getAuditListener());
    }


    public void formPrintFields(DirectoryCollaboratorFunctionsItem collab) throws ClipsException {
        ClientLocal client = getEmcLocal().getClient();
        DiseaseFolluwupPrintInfo printInfo = getPrintInfo();
        DirectoryMKB10 mKB10 = DirectoryLocator.getDirectory(DirectoryMKB10.class);

        ArrayList<SerRenLocal> serrensInTap = getSerRensByCollab(collab);

        data = new HashMap<String, Object>();

        String emcNum = getEmcLocal().getClient().getNumberEmc();
        if (emcNum != null) {
            data.put("emc_code", emcNum);
        }
        data.put("tap_date", Converter.dateToString(getCreated(), "dd.MM.yy"));

        DirectoryDistrictItem dist = client.getDistrict();
        if (dist != null && dist.getID() != 0) {
            String district = dist.getTitle();
            data.put("pacient_district", district);
        }
        String snils = client.getSnils();
        if (snils != null) {
            data.put("pacient_snils", snils);
        }

        ClientExemptionData chunk = client.getExemption();
        if (chunk != null) {
            DirectoryExcemptionItem exemp = chunk.getExemption();
            if (exemp != null && exemp.getID() != 0) {
                data.put("exemption_code", exemp.getExtKey());
            }
        }

        data.put("pacient_fio", client.toString());
        data.put("pacient_sex", client.getSex().getID());
        String bornDate = Converter.dateToString(client.getBorn());
        data.put("pacient_born_date", bornDate.isEmpty() ? "          " : bornDate);

        ClientLocal representative = null;
        if (client.getPolisOMS().getNumber().equals(Polis.FICTIVE_POLIS_NUMBER)) {
            representative = client.getRepresentative();
        }

        ClientDocumentData doc;
        PolisData polis;
        if (representative != null) {
            data.put("representative_surname", representative.getSurname().getTitle());
            data.put("representative_name", representative.getName().getTitle());
            data.put("representative_patron", representative.getPathron().getTitle());
            data.put("is_representative_document", Boolean.TRUE);
            DirectoryRepresentativeStatusItem item = client.getRepresStatus();
            if (item != null) {
                data.put("representative_status", item.getID());
            }

            doc = representative.getClientDocument();
            polis = representative.getPolisOMS();
        }
        else {
            doc = client.getClientDocument();
            polis = client.getPolisOMS();
        }
View Full Code Here

                break;
        }
        extraFields.put("directionTitle", "Направление: " + getType().getTitle());       
        extraFields.put("directionDate", Converter.dateToString(getDate()));
       
        ClientLocal cl = getSerrenLocal().getDiseaseLocal().getEmcLocal().getClient();
        String clientInfo = cl.toString();
        if (cl.getBorn() != null) {
            clientInfo += ", " + Converter.dateToString(cl.getBorn());
            clientInfo += " (" + DateTimeUtils.calcAge(cl.getBorn(), TimeLocal.getCurrentTime().getTime()) + ")";
        }
        extraFields.put("clientData", clientInfo);
        extraFields.put("clientAddress", cl.getAddress().toString());
        extraFields.put("directionChoice", dirChoiceItem);
        if (getMkb() != null) {
            extraFields.put("directionMkb", getMkb().toString());
        }
        DirectoryCollaboratorItem collab = getSerrenLocal().getSerRenDirector();
View Full Code Here

    public ArrayList<MedexamLocal> findMedexamLocals(MedexamFilter filter) throws ClipsException {
        ArrayList<MedexamLocal> medexamLocals = new ArrayList<MedexamLocal>();
        try {
            List<MedexamClientChunk> list = bean().getFilteredDetailed(filter);
            for (MedexamClientChunk d : list) {
                ClientLocal client = new ClientLocal(d.getClientDetails(), am);
                MedexamLocal f = new MedexamLocal(client, d.getMedexamDetails(), am);
                medexamLocals.add(f);
            }
        } catch (Exception ex) {
            clearBean();
View Full Code Here

        return PrescriptionBean.class.getSimpleName();
    }
   
    public void itemPrint(PrescriptionItemData itemData) throws ClipsException {
        DirectoryCollaboratorItem collab = getSerrenLocal().getSerRenDirector();
        ClientLocal client = getSerrenLocal().getPolisData().getClient(getAuditListener());
       
        FormReportCreator creater = ReporterFactory.createFormReporter(getClass(), 1);
       
        HashMap<String, Object> data = new HashMap<String, Object>();
        data.put("recipeDate", Converter.dateToString(getDate()));
        data.put("recipeClient", client.toString());
        int age = DateTimeUtils.calcAge(client.getBorn(), TimeLocal.getCurrentTime().getTime());
        data.put("clientAge", age != Integer.MIN_VALUE ? Integer.toString(age) : "Не определен");
        data.put("clientAddress", client.getAddress().toStringShort());
        data.put("clientEMC", client.getEMC().getID());
        data.put("recipeCollab", collab.getTitle());
        data.put("recipeVidal", itemData.getVidal().toString());
        data.put("recipeTake", itemData.getTakeDrug().toString());
        creater.createReport(null, null, data.entrySet(), null);
        creater.finish();
View Full Code Here

        }

    }

    private void setScreenFields() throws ClipsException {
        ClientLocal mother = clientLocal.getMother();
        if (mother != null) {
            editMother.setText(mother.getSurname() + " " + mother.getName() +
                    " " + mother.getPathron());
        } else {
            editMother.setText("");
        }
        ClientLocal father = clientLocal.getFather();
        if (father != null) {
            editFather.setText(father.getSurname() + " " + father.getName() +
                    " " + father.getPathron());
        } else {
            editFather.setText("");
        }

        ClientLocal representative = clientLocal.getRepresentative();
        if (representative != null) {
            editRepresentative.setText(representative.getSurname() + " " + representative.getName() +
                    " " + representative.getPathron());
        } else {
            editRepresentative.setText("");
        }
        cbRepresStatus.setEnabled(clientLocal.getRepresentative() != null);
        cbRepresStatus.setSelectedItem(clientLocal.getRepresStatus());
View Full Code Here

TOP

Related Classes of clips.delegate.client.ClientLocal

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.