parameters. Some code is also generated but it is not complete yet. minimum still required - field assignments - properly format and escape the query string
33 lines
565 B
C++
33 lines
565 B
C++
#ifndef CODEGENERATOR_H
|
|
#define CODEGENERATOR_H
|
|
|
|
#include <QWidget>
|
|
#include "PlgPage.h"
|
|
#include "Pgsql_declare.h"
|
|
|
|
namespace Ui {
|
|
class CodeGenerator;
|
|
}
|
|
|
|
class CodeGenerator : public PlgPage
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
explicit CodeGenerator(QWidget *parent = nullptr);
|
|
~CodeGenerator();
|
|
|
|
void Init(QString query, std::shared_ptr<const Pgsql::Result> dbres);
|
|
private slots:
|
|
void on_updateCodeButton_clicked();
|
|
|
|
private:
|
|
Ui::CodeGenerator *ui;
|
|
|
|
QString m_query;
|
|
std::shared_ptr<const Pgsql::Result> m_dbres;
|
|
|
|
void generateCode();
|
|
};
|
|
|
|
#endif // CODEGENERATOR_H
|