Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,4 @@ compile_commands.json
# QtCreator local machine specific files for imported projects
*creator.user*
.DS_Store
/build
3 changes: 3 additions & 0 deletions QLog.pro
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@ SOURCES += \
ui/AlertSettingDialog.cpp \
ui/AlertWidget.cpp \
ui/AwardsDialog.cpp \
ui/DXCCSubmissionDialog.cpp \
ui/BandmapWidget.cpp \
ui/CWConsoleWidget.cpp \
ui/ChatWidget.cpp \
Expand Down Expand Up @@ -313,6 +314,7 @@ HEADERS += \
ui/AlertSettingDialog.h \
ui/AlertWidget.h \
ui/AwardsDialog.h \
ui/DXCCSubmissionDialog.h \
ui/BandmapWidget.h \
ui/CWConsoleWidget.h \
ui/ChatWidget.h \
Expand Down Expand Up @@ -377,6 +379,7 @@ FORMS += \
ui/AlertSettingDialog.ui \
ui/AlertWidget.ui \
ui/AwardsDialog.ui \
ui/DXCCSubmissionDialog.ui \
ui/BandmapWidget.ui \
ui/CWConsoleWidget.ui \
ui/ChatWidget.ui \
Expand Down
543 changes: 543 additions & 0 deletions ui/DXCCSubmissionDialog.cpp

Large diffs are not rendered by default.

56 changes: 56 additions & 0 deletions ui/DXCCSubmissionDialog.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
#ifndef QLOG_UI_DXCCSUBMISSIONDIALOG_H
#define QLOG_UI_DXCCSUBMISSIONDIALOG_H

#include <QDialog>
#include <QSqlQueryModel>
#include <QCheckBox>
#include <QList>
#include <QSqlRecord>
#include "models/SqlListModel.h"
#include "data/Band.h"

namespace Ui {
class DXCCSubmissionDialog;
}

// DXCC band scope presets
enum class DXCCBandScope {
EntityLevel, // Any band — one entry per entity (basic DXCC)
FiveBand, // 80/40/20/15/10m preset
AllDXCCBands, // All enabled DXCC bands, per band
Custom // User-selected bands
};

class DXCCSubmissionDialog : public QDialog
{
Q_OBJECT

public:
explicit DXCCSubmissionDialog(QWidget *parent = nullptr);
~DXCCSubmissionDialog();

public slots:
void refreshTable();
void onBandScopeChanged(int index);
void onFiveBandClicked();
void onAllBandsClicked();
void exportAsADIF();

private:
Ui::DXCCSubmissionDialog *ui;
QSqlQueryModel *tableModel;
SqlListModel *entityCallsignModel;

// Band checkboxes added dynamically
QList<QCheckBox*> bandCheckBoxes;
QList<Band> dxccBands;

// Helpers
const QString getSelectedEntity() const;
QStringList getSelectedBands() const;
QString buildModeGroupFilter() const;
void selectBandPreset(const QStringList &bands);
void updateStatusLabel(int count);
};

#endif // QLOG_UI_DXCCSUBMISSIONDIALOG_H
Loading