#include "shopsettingsform.h" #include "ui_shopsettingsform.h" #include ShopSettingsForm::ShopSettingsForm(QWidget *parent) : FormBinder(parent), ui(new Ui::ShopSettingsForm) { ui->setupUi(this); registerBinding(ui->output); registerBinding(ui->lettersPerLine); registerBinding(ui->byMessage); } ShopSettingsForm::~ShopSettingsForm() { delete ui; } void ShopSettingsForm::loadEntity() { SettingsService srv("SHOP"); ShopSettingsPtr settings = srv.loadSettings(); setEntity(settings); } bool ShopSettingsForm::saveRecord() { bindToData(); SettingsService srv("SHOP"); srv.saveSettings(entity()); return true; }