Ananas Library  0.9.5
Public Types | Public Slots | Public Member Functions | Public Attributes | Protected Member Functions | List of all members
aReport Class Reference
Inheritance diagram for aReport:
aObject

Public Types

enum  RT_type {
  RT_text, RT_office_writer, RT_office_calc, RT_msoffice_word,
  RT_msoffice_excel
}
 

Public Slots

void setTable (const QString &name)
 
void setValue (const QString &name, const QString &value)
 
QString value (const QString &name)
 
void clear ()
 
void exec (const QString &section)
 
void close ()
 
void show ()
 
void save (const QString &)
 
- Public Slots inherited from aObject
virtual QString Uid ()
 
virtual bool IsSelected ()
 Checks if object selected. More...
 
virtual bool IsMarkDeleted (const QString &tname="")
 Checks "Deleted" marker. More...
 
virtual bool IsMarked ()
 Checks "Marked" marker. More...
 
virtual int SetMarkDeleted (bool Deleted, const QString &tablename="")
 Устанавливает признак логического удаления объекта (записи SQL таблицы) More...
 
virtual int SetMarked (bool Marked)
 Выставляет отметку на объекте. More...
 
virtual int New ()
 Add new object record in database. More...
 
virtual int Copy ()
 
virtual int Delete ()
 
virtual int Update ()
 Update curent selected object record to database. More...
 
virtual int Conduct ()
 Conducts document. More...
 
virtual int UnConduct ()
 Unconducts document. More...
 
virtual bool IsConducted ()
 Checks if document has been conducted. More...
 
virtual QString Kind (const QString &name=QString::null)
 
virtual QVariant Value (const QString &name, const QString &tableName="")
 Return field value of the primary object database table. More...
 
virtual int SetValue (const QString &name, const QVariant &value, const QString &tableName="")
 Set field value of the primary object database table. More...
 
virtual QVariant sysValue (const QString &name, const QString &tableName="")
 Gets system field value. More...
 
virtual int setSysValue (const QString &name, QVariant value, const QString &tableName="")
 Sets system field value. More...
 
virtual int SetFilter (const QString &valname, const QVariant &value)
 Задает фильтр записей/объектов
 
virtual int ClearFilter ()
 Чистит фильтр записей/объектов. More...
 
virtual int TableSetFilter (const QString &tname, const QString &valname, const QVariant &value)
 Устанавливает вильтр записей табличной части объекта. More...
 
virtual int TableClearFilter (const QString &tname)
 Чистит фильтр записей указанной табличной части объекта. More...
 
virtual bool IsFiltred ()
 Показывает наличие активного фильтра
 
virtual int TableUpdate (const QString &tablename)
 
virtual QString displayString ()
 Возвращает строку, предназначенную для отображения пользователю объекта сложного типа. More...
 
virtual int LastErrorCode ()
 
virtual QString LastErrorMessage ()
 

Public Member Functions

 aReport (aCfgItem context, RT_type r_type=RT_text, aEngine *e=0)
 
 aReport (QString name, RT_type r_type=RT_text, aEngine *e=0)
 
virtual ~aReport ()
 
virtual ERR_Code initObject ()
 
QString path2workdir ()
 
- Public Member Functions inherited from aObject
 aObject (QObject *parent=0, const char *name=0)
 
 aObject (const QString &oname, aDatabase *adb, QObject *parent=0, const char *name=0)
 
 aObject (aCfgItem context, aDatabase *adb, QObject *parent=0, const char *name=0)
 Creates aObject, inited by md object. More...
 
virtual ~aObject ()
 Virtual destructor.
 
virtual bool checkStructure ()
 Not implemented. More...
 
ERR_Code init ()
 Tune on metadata object and it's database tables. More...
 
ERR_Code decodeDocNum (QString nm, QString &pref, int &num)
 Осуществляет выделение символьного префикса из строки. More...
 
virtual ERR_Code select (Q_ULLONG id)
 
Q_ULLONG getUid ()
 Возвращает уникальный идентификатор объекта из базы данных. More...
 
bool selected (const QString &tablename="")
 Показывает задан ли текущий объект или запись в его табличной части. More...
 
ERR_Code select (const QString &query, const QString &tableName="")
 Осуществляет SQL запрос. More...
 
aDataTabletable (const QString &name="")
 Return the table of object by it's name. More...
 
virtual Q_ULLONG docId ()
 Returns document database id. More...
 
virtual bool Next (const QString &tableName="")
 Перемещает указатель на следующую запись SQL таблицы. More...
 
virtual bool Prev (const QString &tableName="")
 Перемещает указатель на предыдующую запись SQL таблицы. More...
 
virtual bool First (const QString &tableName="")
 Перемещает указатель на первую запись SQL таблицы. More...
 
virtual bool Last (const QString &tableName="")
 Перемещает указатель на последнюю запись SQL таблицы. More...
 

Public Attributes

aEngineengine
 
iTemplatetpl
 
aReportBrowserbrowser
 
RT_type type
 
- Public Attributes inherited from aObject
aCfgmd
 
aCfgItem obj
 
aDatabasedb
 

Protected Member Functions

QString getName4NewTemplate ()
 
- Protected Member Functions inherited from aObject
virtual aCfgItem displayStringContext ()
 Возвращает контекст (узел дерева) метаданных для вычисления строкового представления сложного типа.
 
virtual ERR_Code setObject (aCfgItem newobject)
 Sets new object type after create. More...
 
bool isInited ()
 
void setInited (bool flag)
 
ERR_Code tableInsert (const QString &dbname, aCfgItem obj, const QString &name="")
 Insert table name and its link into internal buffer. More...
 
ERR_Code tableInsert (const QString &dbname, const QString &name="")
 Insert table name and its link into internal buffer. More...
 
ERR_Code tableRemove (const QString &name="")
 Remove table from buffer. More...
 
virtual QVariant tValue (const QString &tablename, const QString &name)
 Return field value of the secondary object database table.
 
virtual ERR_Code setTValue (const QString &tablename, const QString &name, const QVariant &value)
 Set field value of the secondary object database table.
 
virtual QString trSysName (const QString &sname)
 Not implemented. More...
 
void setSelected (bool sel, const QString &tablename="")
 Явно задает состояние выбранности объекта или записи его табличной части.
 
virtual ERR_Code setTFilter (const QString &tname, const QString &valname, const QVariant &value)
 Устанавливает вильтр записей табличной части объекта.
 
virtual ERR_Code clearTFilter (const QString &tname)
 Чистит фильтр записей указанной табличной части объекта.
 
void setLastError (int, QString)
 Задает значения свойствам lastErrorCode и lastErrorMessage класса More...
 

Additional Inherited Members

- Protected Attributes inherited from aObject
bool concrete
 

Member Enumeration Documentation

Enumerator
RT_text 

отчет в формате HTML

RT_office_writer 

отчет в формате OpenOffice Writer

RT_office_calc 

отчет в формате OpenOffice Calc

RT_msoffice_word 

отчет в формате Microsoft Office Word

RT_msoffice_excel 

отчет в формате Microsoft Office Word

Constructor & Destructor Documentation

aReport::aReport ( aCfgItem  context,
RT_type  report_type = RT_text,
aEngine e = 0 
)
aReport::aReport ( QString  name,
RT_type  report_type = RT_text,
aEngine e = 0 
)
aReport::~aReport ( )
virtual

Destructor

Member Function Documentation

void aReport::clear ( )
slot

Clear browser content.

References aReportBrowser::clear().

void aReport::close ( )
slot

Close report.

References iTemplate::close().

void aReport::exec ( const QString &  section)
slot

Update report value.

References iTemplate::exec().

QString aReport::getName4NewTemplate ( )
protected

Gets name for new template. Need for OpenOffice v2.

References iTemplate::getDir(), aLog::print(), RT_msoffice_excel, RT_msoffice_word, and RT_office_calc.

Referenced by show().

ERR_Code aReport::initObject ( )
virtual

Init object.

Reimplemented from aObject.

References aObject::initObject().

QString aReport::path2workdir ( )

Return path to working dir.

See Also
setTable( const QString &name )

References aLog::print().

Referenced by setTable().

void aReport::save ( const QString &  fileName)
slot

Saves report to file.

References iTemplate::save(), and aObject::setLastError().

void aReport::setTable ( const QString &  name)
slot

Set template.

Parameters
name- template name
See Also
path2workdir()

References iTemplate::open(), path2workdir(), and iTemplate::setDir().

void aReport::setValue ( const QString &  name,
const QString &  value 
)
slot

Sets tag value.

Parameters
name- tag name
value- tag value

References iTemplate::setValue().

void aReport::show ( )
slot
QString aReport::value ( const QString &  name)
slot

Gets tag value.

Parameters
name- tag name
Returns
tag value

References iTemplate::getValue().


The documentation for this class was generated from the following files: