From fe71701968627f6ee3e1066dbb1ee6d2ab08afcc Mon Sep 17 00:00:00 2001 From: emkael Date: Wed, 24 Oct 2018 14:55:33 +0200 Subject: Grouping tables in sections extended to support teams IMP results --- Aktywator/Bws.cs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'Aktywator/Bws.cs') diff --git a/Aktywator/Bws.cs b/Aktywator/Bws.cs index 4c4586e..e89996f 100644 --- a/Aktywator/Bws.cs +++ b/Aktywator/Bws.cs @@ -126,7 +126,7 @@ namespace Aktywator MessageBox.Show(MainForm.differentRecordsInSections, "Ustawienia grupowania zapisów w sektorach", MessageBoxButtons.OK, MessageBoxIcon.Warning); main.xGroupSections.Checked = false; } - Setting.saveSectionGroups(this.sql, main.xGroupSections.Checked); + Setting.saveSectionGroups(this.sql, main.xGroupSections.Checked, (this.getMySQLDatabaseForSection() != null) ? Convert.ToInt32(main.numTeamsTableOffset.Value) : 0); } main.checkRecordsForSectionGroups(); } @@ -583,7 +583,7 @@ namespace Aktywator Setting.save("BM2NameSource", "2", this, errors, section); Setting.save("BM2PINcode", "'" + main.xPINcode.Text + "'", this, errors, section); Setting.save("BM2ResultsOverview", main.xResultsOverview.SelectedIndex.ToString(), this, errors, section); - Setting.saveSectionGroups(this.sql, main.xGroupSections.Checked); + Setting.saveSectionGroups(this.sql, main.xGroupSections.Checked, (this.getMySQLDatabaseForSection() != null) ? Convert.ToInt32(main.numTeamsTableOffset.Value) : 0); this.loadSettings(); } @@ -613,6 +613,11 @@ namespace Aktywator } private int getBWSNumber(OleDbDataReader reader, int index) + { + return Bws.bwsNumber(reader, index); + } + + public static int bwsNumber(OleDbDataReader reader, int index) { switch (Type.GetTypeCode(reader.GetFieldType(index))) { -- cgit v1.2.3