*/
public ServisePriceData getContractService() throws ClipsException {
//чтобы не создавались копии контрактов, загнал их в мап
//в течении сеанса цены на услуги не будут обновляться
int contractID = getPolisData().getDetails().contractID;
ContractLocal contract;
if (contractMap.containsKey(contractID)) {
contract = contractMap.get(contractID);
} else {
contract = getPolisData().getContract();
contractMap.put(contractID, contract);
}
DirectoryServiceItem service = getService();
ServisePriceData contractService = null;
DirectoryReceptionTypeItem nullItem = DirectoryLocator.getDirectory(DirectoryReceptionType.class).getNullItem();
DirectoryReceptionTypeItem recType = nullItem;
if (getCollaboratorFunctions() != null){
recType = getCollaboratorFunctions().getReceptionType();
}
contractService = contract.getContractService(new Pair<DirectoryServiceItem, DirectoryReceptionTypeItem>(service, recType));
if (contractService == null){
contractService = contract.getContractService(new Pair<DirectoryServiceItem, DirectoryReceptionTypeItem>(service, nullItem));
}
return contractService;
// return getPolis().getContract().getContractService(getService());
}