Package clips.delegate.directory.complex

Examples of clips.delegate.directory.complex.DirectoryDloDrugSectionItem


                new ArrayList<DirectoryDloDrugSectionItem>();

        ROList<DirectoryDloDrugSectionItem> itemsList = dir.getItemsList();

        for (int i = 0; i < itemsList.size(); i++) {
            DirectoryDloDrugSectionItem item = itemsList.get(i);
            if (item.getID() != 0 && item.getCode() != 0) {
                presentItems.put(item.getCode(), item);
            }
        }

        int recordCount = dbf.getRecordCount();
        for (int c = 0; c < recordCount; c++) {
            try {
                if ((c%500) == 0) {
                    System.out.println("Обновление разделов перечня ЛС выполнено " + (c+1)/((float)recordCount)*100 + "%");
                    out.println("Обновление разделов перечня ЛС выполнено " + (c+1)/((float)recordCount)*100 + "%");
                }
                dbf.read();
                int code = Integer.parseInt(fields.get(Col.C_RLP).get().trim());
                int number = Integer.parseInt(fields.get(Col.N_RAZD).get().trim());
                String title = fields.get(Col.NAME_PRAZD).get().trim();
                String p_number = fields.get(Col.N_PRAZD).get().trim();
                String p_title = fields.get(Col.NAME_PRAZD).get().trim();

                DirectoryDloDrugSectionItem pItem = presentItems.get(code);
                if (pItem != null) {
                    if (!pItem.getTitle().equals(title)) {
                        changeList.put(pItem, title);
                    }
                    presentItems.remove(code);
                } else {
                    //Создать новый
                    DloDrugSectionDetails details = new DloDrugSectionDetails();
                    details.code = code;
                    details.number = number;
                    details.title = title;
                    details.subNumber = p_number;
                    details.subTitle = p_title;

                    DirectoryDloDrugSectionItem newItem = new DirectoryDloDrugSectionItem(details);
                    addList.add(newItem);
                }
               
            } catch (IOException ex) {
                closeDBF(dbf);
View Full Code Here


        try {
            if (treeSection.getSelectionPath() != null) {
                Object obj = treeSection.getSelectionPath().getLastPathComponent();
                items = null;
                if (obj instanceof DirectoryDloDrugSectionItem) {
                    DirectoryDloDrugSectionItem section = (DirectoryDloDrugSectionItem) obj;
                    items = dirDrug.getItemsBySection(section);
                }
                tableDrugListSection.setModel(new TableModelDrugList(items));
            }
        } catch (ClipsException ex) {
View Full Code Here

TOP

Related Classes of clips.delegate.directory.complex.DirectoryDloDrugSectionItem

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.