Class ContractDAO
java.lang.Object
ru.bgcrm.plugin.bgbilling.dao.BillingDAO
ru.bgcrm.plugin.bgbilling.proto.dao.ContractDAO
- Direct Known Subclasses:
ContractNoteDAO
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from class ru.bgcrm.plugin.bgbilling.dao.BillingDAO
dbInfo, jsonMapper, jsonTypeFactory, transferData, user -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadditionalActionList(int contractId) voidaddSearchResult(Pageable<Contract> result, Page page, Request req) voidbgbillingOpenContract(int contractId) voidbgbillingUpdateContractTitleAndComment(int contractId, String comment, int patid) voidcopyObjectParamsToContract(Connection con, String copyParamsMapping, int objectId, int contractId, Customer customer) static voidcopyParametersToAllContracts(Connection con, User user, int customerId) voidcopyParametersToBilling(Connection con, int customerId, int contractId, String title) createContract(int patternId, Date date, String title, String customTitle, int superId) voiddeleteLimitTask(int contractId, int id) executeAdditionalAction(int contractId, int actionId) voidfaceLog(Pageable<ContractFace> result, int contractId) getContractAddress(int contractId) getContractById(int contractId) byte[]getContractCard2Pdf(int contractId, String type) getContractCardDoc(int contractId) getContractCardTypes(int contractId) getContractFullCard(int contractId) getContractInfo(int contractId) getContractLabelTreeItemList(int contractId) getContractStatisticPassword(int contractId) static ContractDAOgetInstance(User user, String billingId) Deprecated.getParameterList(int parameterTypeId) getStreetsByCity(int cityId) groupsGet(int contractId) limit(int contractId, Pageable<LimitLogItem> log, List<LimitChangeTask> taskList) voidmodeLog(Pageable<ContractMode> result, int contractId) moduleList(int contractId) voidsearchContractByAddressParam(Pageable<ParameterSearchedObject<Contract>> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, int streetId, int houseId, String house, String flat, String room) voidsearchContractByDateParam(Pageable<Contract> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, Date dateFrom, Date dateTo) voidsearchContractByEmailParam(Pageable<Contract> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, String email) voidsearchContractByObjectAddressParam(Pageable<ParameterSearchedObject<Contract>> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, int streetId, String house, String flat, String room) Осуществляет поиск договоров по адресным параметам объекта, либо заданным аргументом, либо, если таковых нет, определяет адресный параметр объекта в конфигурции биллинга.voidsearchContractByPhoneParam(Pageable<Contract> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, String phone) voidsearchContractByTextParam(Pageable<Contract> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, String value) voidsearchContractByTitleComment(Pageable<IdTitle> searchResult, String title, String comment, ContractDAO.SearchOptions searchOptions) voidupdateContractDateTo(int contractId, Date date) voidupdateContractPassword(int contractId, String value, boolean generate) voidupdateFace(int contractId, int face) voidupdateLabels(int contractId, Set<Integer> labelIds) voidupdateLimit(int contractId, BigDecimal limit, int days, String comment) voidupdateMode(int contractId, int mode) voidupdateModule(int contractId, int moduleId, String command) Methods inherited from class ru.bgcrm.plugin.bgbilling.dao.BillingDAO
doRequest, getDbInfo, getPage, getParameterId, getVersion, linesToString, readJsonValue, setPage
-
Field Details
-
KERNEL_CONTRACT_API
- See Also:
-
KERNEL_CONTRACT_LIMIT
- See Also:
-
-
Constructor Details
-
ContractDAO
-
-
Method Details
-
getInstance
Deprecated. -
getContractById
-
searchContractByTitleComment
public void searchContractByTitleComment(Pageable<IdTitle> searchResult, String title, String comment, ContractDAO.SearchOptions searchOptions) -
updateContractDateTo
-
searchContractByObjectAddressParam
public void searchContractByObjectAddressParam(Pageable<ParameterSearchedObject<Contract>> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, int streetId, String house, String flat, String room) Осуществляет поиск договоров по адресным параметам объекта, либо заданным аргументом, либо, если таковых нет, определяет адресный параметр объекта в конфигурции биллинга.- Parameters:
result-options-paramIds- - необязательный параметр, коды адресных параметровstreetId-house-flat-room-
-
searchContractByAddressParam
public void searchContractByAddressParam(Pageable<ParameterSearchedObject<Contract>> result, ContractDAO.SearchOptions options, Set<Integer> paramIds, int streetId, int houseId, String house, String flat, String room) -
searchContractByTextParam
-
searchContractByPhoneParam
-
searchContractByDateParam
-
searchContractByEmailParam
-
addSearchResult
-
createContract
public Contract createContract(int patternId, Date date, String title, String customTitle, int superId) throws BGMessageException - Throws:
BGMessageException
-
faceLog
-
updateFace
public void updateFace(int contractId, int face) -
modeLog
-
updateMode
public void updateMode(int contractId, int mode) -
getContractLabelTreeItemList
-
groupsGet
-
updateLabels
-
additionalActionList
-
executeAdditionalAction
-
moduleList
-
updateModule
- Throws:
BGMessageException
-
limit
-
updateLimit
-
deleteLimitTask
public void deleteLimitTask(int contractId, int id) -
getContractStatisticPassword
-
getContractAddress
-
updateContractPassword
-
getContractFullCard
-
getContractCardDoc
-
getContractCardTypes
-
getContractCard2Pdf
-
bgbillingOpenContract
public void bgbillingOpenContract(int contractId) -
bgbillingUpdateContractTitleAndComment
-
bgbillingGetContractPatternList
-
getStreetsByCity
-
openContract
-
getParameterList
-
getContractInfo
-
getList
-
getList
-
copyParametersToBilling
public void copyParametersToBilling(Connection con, int customerId, int contractId, String title) throws Exception - Throws:
Exception
-
copyObjectParamsToContract
public void copyObjectParamsToContract(Connection con, String copyParamsMapping, int objectId, int contractId, Customer customer) throws SQLException, BGMessageException - Throws:
SQLExceptionBGMessageException
-
copyParametersToAllContracts
public static void copyParametersToAllContracts(Connection con, User user, int customerId) throws Exception - Throws:
Exception
-