Commit 25da1a15 authored by Karel Slaný's avatar Karel Slaný Committed by Martin Straka

Updated Gov::SrvcMvRtpoVt.

parent a40d1e07
......@@ -23,38 +23,66 @@
#pragma once
#include "src/datovka_shared/gov_services/service/gov_service.h"
#include <QCoreApplication> /* Q_DECLARE_TR_FUNCTIONS */
/*!
* GOV MV service
* Name: Výpis z Rejstříku trestů právnických osob
* DS: xhzkdqv - Automat CzP (Ministerstvo vnitra)
* XML: czpathome.xml - nutno doplnit IČ subjektu.
* Source DS type: FO, PFO, PO
*/
class GovMvRtpoVt : public GovService {
#include "src/datovka_shared/gov_services/service/gov_service.h"
public:
namespace Gov {
/*!
* @brief Constructor.
* GOV MV service
* Name: Výpis z Rejstříku trestů právnických osob
* DS: xhzkdqv - Automat CzP (Ministerstvo vnitra)
* XML: czpathome.xml - nutno doplnit IČ subjektu.
* Source DS type: FO, PFO, PO
*/
GovMvRtpoVt(void);
class SrvcMvRtpoVt : public Service {
Q_DECLARE_TR_FUNCTIONS(SrvcMvRtpoVt)
/*!
* @brief Destructor.
*/
virtual
~GovMvRtpoVt(void) Q_DECL_OVERRIDE;
public:
/*!
* @brief Constructor.
*/
SrvcMvRtpoVt(void);
/*!
* @brief Create and fill XML attachment content.
*
* @param[in] dbOwnerInfo DS owner info.
* @param[in] reqFields Gov service required information.
* @return XML string for attachment.
*/
virtual
const QByteArray createXmlAttachment(const Isds::DbOwnerInfo &dbOwnerInfo,
XmlRequiredFileds reqFields) Q_DECL_OVERRIDE;
};
virtual
const QString &internalId(void) const Q_DECL_OVERRIDE;
virtual
const QString &fullName(void) const Q_DECL_OVERRIDE;
virtual
const QString &instituteName(void) const Q_DECL_OVERRIDE;
virtual
const QString &boxId(void) const Q_DECL_OVERRIDE;
virtual
const QString &dmAnnotation(void) const Q_DECL_OVERRIDE;
virtual
const QString &dmSenderIdent(void) const Q_DECL_OVERRIDE;
virtual
const QString &dmFileDescr(void) const Q_DECL_OVERRIDE;
virtual
bool canSend(enum Isds::Type::DbType dbType) const Q_DECL_OVERRIDE;
virtual
QList<RequiredInput> requiredFields(void) const Q_DECL_OVERRIDE;
virtual
bool setRequiredField(const QString &key, const QString &val) Q_DECL_OVERRIDE;
virtual
bool haveAllMandatoryFields(void) const Q_DECL_OVERRIDE;
virtual
QByteArray binaryXmlContent(const Isds::DbOwnerInfo &dbOwnerInfo) const Q_DECL_OVERRIDE;
private:
QString m_ic; /*!< Identification number. */
};
}
......@@ -26,10 +26,10 @@
#include "src/datovka_shared/gov_services/service/gov_mv_crr_vbh.h"
#include "src/datovka_shared/gov_services/service/gov_mv_ir_vp.h"
#include "src/datovka_shared/gov_services/service/gov_mv_rt_vt.h"
#include "src/datovka_shared/gov_services/service/gov_mv_rtpo_vt.h"
//#include "src/datovka_shared/gov_services/service/gov_mv_skd_vp.h"
//#include "src/datovka_shared/gov_services/service/gov_mv_vr_vp.h"
//#include "src/datovka_shared/gov_services/service/gov_mv_zr_vp.h"
//#include "src/datovka_shared/gov_services/service/gov_mv_rtpo_vt.h"
#include "src/datovka_shared/gov_services/service/gov_service.h"
#include "src/datovka_shared/gov_services/service/gov_szr_rob_vu.h"
#include "src/datovka_shared/gov_services/service/gov_szr_rob_vvu.h"
......@@ -129,6 +129,20 @@ void GovWrapper::initGovServices(void)
}
}
/* Výpis z Rejstříku trestů právnických osob */
gs = new (std::nothrow) Gov::SrvcMvRtpoVt;
if (gs != Q_NULLPTR) {
const QString &key(gs->internalId());
if (!m_govServices.contains(key)) {
m_govServices.insert(key, gs);
} else {
logError(
"Key '%s' already exists in gov services container.",
key.toUtf8().constData());
delete gs;
}
}
/* Výpis z Registru obyvatel */
gs = new (std::nothrow) Gov::SrvcSzrRobVu;
if (gs != Q_NULLPTR) {
......@@ -161,10 +175,6 @@ void GovWrapper::initGovServices(void)
// GovSzrRosVv *gs3 = new GovSzrRosVv();
// m_govServices.insert(gs3->serviceId(), gs3);
// /* Výpis z Rejstříku trestů právnických osob */
// GovMvRtpoVt *gs5 = new GovMvRtpoVt();
// m_govServices.insert(gs5->serviceId(), gs5);
// /* Výpis z živnostenského rejstříku */
// GovMvZrVp *gs7 = new GovMvZrVp();
// m_govServices.insert(gs7->serviceId(), gs7);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment