Subversion Repositories winbugtracker

Compare Revisions

No changes between revisions

Regard whitespace Rev 2 → Rev 3

/trunk/About.dfm
0,0 → 1,103
object AboutBox: TAboutBox
Left = 200
Top = 108
BorderIcons = [biSystemMenu]
BorderStyle = bsDialog
Caption = 'Info '#252'ber'
ClientHeight = 213
ClientWidth = 298
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = True
Position = poMainFormCenter
PixelsPerInch = 96
TextHeight = 13
object Panel1: TPanel
Left = 8
Top = 8
Width = 281
Height = 161
BevelInner = bvRaised
BevelOuter = bvLowered
ParentColor = True
TabOrder = 0
object ProgramIcon: TImage
Left = 8
Top = 8
Width = 65
Height = 57
Picture.Data = {
07544269746D617076020000424D760200000000000076000000280000002000
0000200000000100040000000000000200000000000000000000100000000000
000000000000000080000080000000808000800000008000800080800000C0C0
C000808080000000FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFF
FF00000000000000000000000000000000000EE8787878EEEEEEE03F30878EEE
EEE00EE8787878EEEEEEE03F30878EEEEEE00EE8787878EEEEEEE03F30878EEE
EEE00EE8787878EEEEEEE03F30878EEEEEE00887787877788888803F3088787E
EEE00788787878878887803F3088887EEEE00788887888878887803F3088887E
EEE00877888887788888703F308887EEEEE00888777778888888037883088888
8EE007777777777777703787883087777EE00888888888888803787FF8830888
888008888888888880378777778830888880077777777788037873F3F3F87808
88E00888888888803787FFFFFFFF8830EEE00887777778800001111111111100
EEE00888888888888899B999B99999EEEEE00888888888888899B9B99BB9B9EE
EEE0088888888888899BB9BB99BB99EEEEE0078888888888899B999B999999EE
EEE0087788888778899B9B9BB9BB99EEEEE00888778778888E9B9B9BB9999EEE
EEE0088888788888EE9B99B9BB9BEEEEEEE00EE8888888EEEEE999B9999EEEEE
EEE00EEEE888EEEEEEEE99BB999EEEEEEEE00EEEEE8EEEEEEEEEE999B9EEEEEE
EEE00EEEEE8EEEEEEEEEEEE999EEEEEEEEE00EEEEE8EEEEEEEEEEEEE99EEEEEE
EEE00EEEEE8EEEEEEEEEEEEE9EEEEEEEEEE00EEEEE8EEEEEEEEEEEEEEEEEEEEE
EEE00EEEEEEEEEEEEEEEEEEEEEEEEEEEEEE00000000000000000000000000000
0000}
Stretch = True
IsControl = True
end
object ProductName: TLabel
Left = 88
Top = 16
Width = 178
Height = 13
Caption = 'ViaThinkSoft Bugtracker f'#252'r Windows'
IsControl = True
end
object Version: TLabel
Left = 88
Top = 40
Width = 53
Height = 13
Caption = 'Version 0.1'
IsControl = True
end
object Copyright: TLabel
Left = 8
Top = 80
Width = 135
Height = 13
Caption = 'Copyright 2016 ViaThinkSoft'
IsControl = True
end
object Comments: TLabel
Left = 8
Top = 104
Width = 258
Height = 52
AutoSize = False
Caption = 'Entwickelt von Daniel Marschall, www.daniel-marschall.de'
WordWrap = True
IsControl = True
end
end
object OKButton: TButton
Left = 111
Top = 180
Width = 75
Height = 25
Caption = 'OK'
Default = True
ModalResult = 1
TabOrder = 1
end
end
/trunk/About.pas
0,0 → 1,31
unit About;
 
interface
 
uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
Buttons, ExtCtrls;
 
type
TAboutBox = class(TForm)
Panel1: TPanel;
ProgramIcon: TImage;
ProductName: TLabel;
Version: TLabel;
Copyright: TLabel;
Comments: TLabel;
OKButton: TButton;
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
 
var
AboutBox: TAboutBox;
 
implementation
 
{$R *.dfm}
 
end.
/trunk/DBDateEdit.txt
0,0 → 1,14
 
procedure TForm1.qryBugsAfterScroll(DataSet: TDataSet);
begin
DateTimePicker1.DateTime := qryBugs.FieldByName('fixdatum').AsDateTime;
end;
 
procedure TForm1.DateTimePicker1CloseUp(Sender: TObject);
begin
LockWindowUpdate(DBGrid1.Handle);
if not (qryBugs.State in [dsEdit, dsInsert]) then qryBugs.Edit;
qryBugs.FieldByName('fixdatum').AsDateTime := DateTimePicker1.DateTime;
LockWindowUpdate(0);
end;
 
/trunk/Login.dfm
0,0 → 1,110
object frmLogin: TfrmLogin
Left = 0
Top = 0
BorderIcons = [biSystemMenu]
BorderStyle = bsDialog
Caption = 'ViaThinkSoft Bugtracker f'#252'r Windows'
ClientHeight = 385
ClientWidth = 298
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
OldCreateOrder = False
Position = poMainFormCenter
PixelsPerInch = 96
TextHeight = 13
object Label1: TLabel
Left = 32
Top = 24
Width = 233
Height = 33
AutoSize = False
Caption = 'Wilkommen'
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -27
Font.Name = 'Tahoma'
Font.Style = [fsBold, fsItalic]
ParentFont = False
end
object GroupBox1: TGroupBox
Left = 32
Top = 80
Width = 233
Height = 105
Caption = 'Wer sind Sie?'
TabOrder = 0
object Label2: TLabel
Left = 98
Top = 59
Width = 103
Height = 13
Cursor = crHandPoint
Alignment = taRightJustify
Caption = 'Mitarbeiter verwalten'
Font.Charset = DEFAULT_CHARSET
Font.Color = clHotLight
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = [fsUnderline]
ParentFont = False
OnClick = Label2Click
end
object cbxMitarbeiter: TDBLookupComboBox
Left = 24
Top = 32
Width = 177
Height = 21
KeyField = 'id'
ListField = 'name'
ListSource = frmBugtracker.dsMitarbeiter
TabOrder = 0
end
end
object GroupBox2: TGroupBox
Left = 32
Top = 200
Width = 233
Height = 105
Caption = 'An was m'#246'chten Sie arbeiten?'
TabOrder = 1
object Label3: TLabel
Left = 110
Top = 59
Width = 91
Height = 13
Cursor = crHandPoint
Alignment = taRightJustify
Caption = 'Projekte verwalten'
Font.Charset = DEFAULT_CHARSET
Font.Color = clHotLight
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = [fsUnderline]
ParentFont = False
OnClick = Label3Click
end
object cbxProjekt: TDBLookupComboBox
Left = 24
Top = 32
Width = 177
Height = 21
KeyField = 'id'
ListField = 'projekt'
ListSource = frmBugtracker.dsProjekte
TabOrder = 0
end
end
object Button1: TButton
Left = 94
Top = 327
Width = 115
Height = 36
Caption = 'Los geht'#39's'
TabOrder = 2
OnClick = Button1Click
end
end
/trunk/Login.pas
0,0 → 1,68
unit Login;
 
interface
 
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, DBCtrls, DB, DBClient;
 
type
TfrmLogin = class(TForm)
Label1: TLabel;
GroupBox1: TGroupBox;
GroupBox2: TGroupBox;
Label2: TLabel;
Label3: TLabel;
Button1: TButton;
cbxMitarbeiter: TDBLookupComboBox;
cbxProjekt: TDBLookupComboBox;
procedure Label2Click(Sender: TObject);
procedure Label3Click(Sender: TObject);
procedure Button1Click(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
 
var
frmLogin: TfrmLogin;
 
implementation
 
uses
WuLiMain, Mitarbeiter, Projekte;
 
{$R *.dfm}
 
procedure TfrmLogin.Button1Click(Sender: TObject);
begin
if VarIsNull(cbxMitarbeiter.KeyValue) then
begin
ShowMessage('Bitte Mitarbeiter auswählen.');
cbxMitarbeiter.SetFocus;
Exit;
end;
if VarIsNull(cbxProjekt.KeyValue) then
begin
ShowMessage('Bitte Projekt auswählen.');
cbxProjekt.SetFocus;
Exit;
end;
frmBugtracker.eingeloggtMitarbeiter := cbxMitarbeiter.KeyValue;
frmBugtracker.aktuellesProjekt := cbxProjekt.KeyValue;
frmBugtracker.NeuFiltern;
ModalResult := mrOk; // Das schließt den Dialog
end;
 
procedure TfrmLogin.Label2Click(Sender: TObject);
begin
frmMitarbeiter.ShowModal;
end;
 
procedure TfrmLogin.Label3Click(Sender: TObject);
begin
frmProjekte.ShowModal;
end;
 
end.
/trunk/Mitarbeiter.dfm
21,7 → 21,7
Top = 8
Width = 257
Height = 233
DataSource = Form1.dsMitarbeiter
DataSource = frmBugtracker.dsMitarbeiter
TabOrder = 0
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
/trunk/Module.dfm
21,7 → 21,7
Top = 8
Width = 257
Height = 233
DataSource = Form1.dsModule
DataSource = frmBugtracker.dsModule
TabOrder = 0
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
/trunk/Projekte.dfm
21,7 → 21,7
Top = 8
Width = 257
Height = 233
DataSource = Form1.dsProjekte
DataSource = frmBugtracker.dsProjekte
TabOrder = 0
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
/trunk/Versionen.dfm
21,7 → 21,7
Top = 8
Width = 257
Height = 233
DataSource = Form1.dsVersionen
DataSource = frmBugtracker.dsVersionen
TabOrder = 0
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
/trunk/WuLi.dpr
2,20 → 2,24
 
uses
Forms,
WuLiMain in 'WuLiMain.pas' {Form1},
WuLiMain in 'WuLiMain.pas' {frmBugtracker},
Mitarbeiter in 'Mitarbeiter.pas' {frmMitarbeiter},
Versionen in 'Versionen.pas' {frmVersionen},
Module in 'Module.pas' {frmModule},
Projekte in 'Projekte.pas' {frmProdukte};
Projekte in 'Projekte.pas' {frmProjekte},
Login in 'Login.pas' {frmLogin},
ABOUT in 'About.pas' {AboutBox};
 
{$R *.res}
 
begin
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.CreateForm(TfrmBugtracker, frmBugtracker);
Application.CreateForm(TfrmMitarbeiter, frmMitarbeiter);
Application.CreateForm(TfrmVersionen, frmVersionen);
Application.CreateForm(TfrmModule, frmModule);
Application.CreateForm(TfrmProdukte, frmProdukte);
Application.CreateForm(TfrmProjekte, frmProjekte);
Application.CreateForm(TfrmLogin, frmLogin);
Application.CreateForm(TAboutBox, AboutBox);
Application.Run;
end.
/trunk/WuLiMain.dfm
1,9 → 1,9
object Form1: TForm1
object frmBugtracker: TfrmBugtracker
Left = 0
Top = 0
Caption = 'ViaThinkSoft Bugtracker f'#252'r Windows'
ClientHeight = 440
ClientWidth = 691
ClientHeight = 498
ClientWidth = 751
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
13,10 → 13,108
Menu = MainMenu1
OldCreateOrder = False
Position = poScreenCenter
OnCreate = FormCreate
PixelsPerInch = 96
TextHeight = 13
object Splitter1: TSplitter
Left = 249
Top = 0
Height = 498
ExplicitLeft = 0
ExplicitTop = 136
ExplicitHeight = 100
end
object Panel1: TPanel
Left = 0
Top = 0
Width = 249
Height = 498
Align = alLeft
TabOrder = 0
ExplicitLeft = 256
ExplicitTop = 448
DesignSize = (
249
498)
object DBGrid1: TDBGrid
Left = 8
Top = 35
Width = 233
Height = 406
Anchors = [akLeft, akTop, akRight, akBottom]
DataSource = dsBugs
ReadOnly = True
TabOrder = 0
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
TitleFont.Height = -11
TitleFont.Name = 'Tahoma'
TitleFont.Style = []
Columns = <
item
Expanded = False
FieldName = 'id'
Width = 46
Visible = True
end
item
Expanded = False
FieldName = 'titel'
Width = 111
Visible = True
end
item
Expanded = False
FieldName = 'wichtigkeit'
Width = 36
Visible = True
end>
end
object ComboBox1: TComboBox
Left = 8
Top = 8
Width = 233
Height = 21
Style = csDropDownList
Anchors = [akLeft, akTop, akRight]
ItemHeight = 13
ItemIndex = 0
TabOrder = 1
Text = 'Meine offenen Bugs (nach Wichtigkeit)'
OnChange = ComboBox1Change
Items.Strings = (
'Meine offenen Bugs (nach Wichtigkeit)'
'Alle offenen Bugs (nach Wichtigkeit)'
'Gel'#246'st ohne Ver'#246'ffentlichung (nach L'#246'sungsdatum)'
'Gel'#246'st und Ver'#246'ffentlicht (nach Version und L'#246'sungsdatum)'
'Alle Bugs (nach Er'#246'ffnungsdatum)')
end
object DBNavigator2: TDBNavigator
Left = 11
Top = 456
Width = 232
Height = 25
DataSource = dsBugs
VisibleButtons = [nbFirst, nbPrior, nbNext, nbLast]
Anchors = [akLeft, akRight, akBottom]
TabOrder = 2
end
end
object Panel2: TPanel
Left = 252
Top = 0
Width = 499
Height = 498
Align = alClient
TabOrder = 1
ExplicitLeft = 320
ExplicitTop = 8
ExplicitWidth = 441
DesignSize = (
499
498)
object Label1: TLabel
Left = 247
Left = 15
Top = 53
Width = 50
Height = 13
23,7 → 121,7
Caption = 'Bearbeiter'
end
object Label2: TLabel
Left = 247
Left = 15
Top = 149
Width = 20
Height = 13
30,7 → 128,7
Caption = 'Titel'
end
object Label3: TLabel
Left = 472
Left = 240
Top = 53
Width = 33
Height = 13
37,7 → 135,7
Caption = 'Erstellt'
end
object Label4: TLabel
Left = 472
Left = 240
Top = 101
Width = 29
Height = 13
44,7 → 142,7
Caption = 'Gefixt'
end
object Label5: TLabel
Left = 247
Left = 15
Top = 101
Width = 28
Height = 13
51,7 → 149,7
Caption = 'Modul'
end
object Label6: TLabel
Left = 472
Left = 240
Top = 149
Width = 119
Height = 13
58,7 → 156,7
Caption = 'Ver'#246'ffentlicht als Version'
end
object DBNavigator1: TDBNavigator
Left = 247
Left = 15
Top = 16
Width = 224
Height = 25
67,57 → 165,26
TabOrder = 0
end
object DBRichEdit1: TDBRichEdit
Left = 247
Top = 208
Width = 402
Height = 209
Left = 15
Top = 248
Width = 471
Height = 233
Anchors = [akLeft, akTop, akRight, akBottom]
DataField = 'beschreibung'
DataSource = dsBugs
TabOrder = 1
TabOrder = 9
end
object DBGrid1: TDBGrid
Left = 8
Top = 47
Width = 233
Height = 370
DataSource = dsBugs
TabOrder = 2
TitleFont.Charset = DEFAULT_CHARSET
TitleFont.Color = clWindowText
TitleFont.Height = -11
TitleFont.Name = 'Tahoma'
TitleFont.Style = []
Columns = <
item
Expanded = False
FieldName = 'id'
Width = 46
Visible = True
end
item
Expanded = False
FieldName = 'titel'
Width = 111
Visible = True
end
item
Expanded = False
FieldName = 'wichtigkeit'
Width = 36
Visible = True
end>
end
object DBEdit1: TDBEdit
Left = 247
Left = 15
Top = 168
Width = 186
Height = 21
DataField = 'titel'
DataSource = dsBugs
TabOrder = 3
TabOrder = 5
end
object DBLookupComboBox1: TDBLookupComboBox
Left = 247
Left = 15
Top = 72
Width = 186
Height = 21
126,32 → 193,35
KeyField = 'id'
ListField = 'name'
ListSource = dsMitarbeiter
TabOrder = 4
NullValueKey = 46
TabOrder = 1
end
object DBEdit2: TDBEdit
Left = 472
Left = 240
Top = 72
Width = 121
Width = 155
Height = 21
TabStop = False
Color = clBtnFace
DataField = 'erstellt'
DataSource = dsBugs
ReadOnly = True
TabOrder = 5
TabOrder = 2
end
object DBEdit3: TDBEdit
Left = 472
Left = 240
Top = 120
Width = 121
Width = 155
Height = 21
TabStop = False
Color = clBtnFace
DataField = 'fixdatum'
DataSource = dsBugs
ReadOnly = True
TabOrder = 6
TabOrder = 4
end
object DBLookupComboBox2: TDBLookupComboBox
Left = 247
Left = 15
Top = 120
Width = 186
Height = 21
160,12 → 230,13
KeyField = 'id'
ListField = 'modul'
ListSource = dsModule
TabOrder = 7
NullValueKey = 46
TabOrder = 3
end
object DBLookupComboBox3: TDBLookupComboBox
Left = 472
Left = 240
Top = 168
Width = 121
Width = 155
Height = 21
DataField = 'version_release'
DataSource = dsBugs
172,33 → 243,35
KeyField = 'id'
ListField = 'version'
ListSource = dsVersionen
TabOrder = 8
TabOrder = 6
end
object TrackBar1: TTrackBar
Left = 477
Left = 245
Top = 8
Width = 150
Width = 164
Height = 45
Position = 5
TabOrder = 9
TabOrder = 10
OnChange = TrackBar1Change
end
object ComboBox1: TComboBox
Left = 8
Top = 8
Width = 233
Height = 21
Style = csDropDownList
ItemHeight = 13
ItemIndex = 0
TabOrder = 10
Text = 'Meine offene Bugs (nach Wichtigkeit)'
Items.Strings = (
'Meine offene Bugs (nach Wichtigkeit)'
'Alle ofene Bugs (nach Wichtigkeit)'
'Gel'#246'st ohne Ver'#246'ffentlichung (nach L'#246'sungsdatum)'
'Gel'#246'st und Ver'#246'ffentlicht (nach Version und L'#246'sungsdatum)')
object btnFixedToggle: TButton
Left = 401
Top = 118
Width = 72
Height = 25
Caption = 'Umschalten'
TabOrder = 8
OnClick = btnFixedToggleClick
end
object btnBearbeitungsnotiz: TButton
Left = 16
Top = 208
Width = 185
Height = 25
Caption = 'Bearbeitungsnotiz hinzuf'#252'gen'
TabOrder = 7
end
end
object ADOConnection1: TADOConnection
Connected = True
ConnectionString =
205,12 → 278,12
'Provider=MSDASQL.1;Persist Security Info=False;Data Source=MySQL' +
' RAS;Initial Catalog=bugtracker'
LoginPrompt = False
Left = 336
Left = 104
Top = 344
end
object dsBugs: TDataSource
DataSet = qryBugs
Left = 400
Left = 168
Top = 312
end
object tblMitarbeiter: TADOTable
218,17 → 291,17
Connection = ADOConnection1
CursorType = ctStatic
TableName = 'mitarbeiter'
Left = 440
Left = 208
Top = 344
end
object dsMitarbeiter: TDataSource
DataSet = tblMitarbeiter
Left = 440
Left = 208
Top = 312
end
object MainMenu1: TMainMenu
Left = 640
Top = 48
Left = 88
Top = 216
object Stammdaten1: TMenuItem
Caption = 'Stammdaten'
object Mitarbeiter1: TMenuItem
248,33 → 321,79
OnClick = Versionen1Click
end
end
object Projektwechseln1: TMenuItem
Caption = 'Projekt wechseln'
OnClick = Projektwechseln1Click
end
object Hilfe1: TMenuItem
Caption = 'Hilfe'
object ber1: TMenuItem
Caption = #220'ber'
OnClick = ber1Click
end
end
end
object XPManifest1: TXPManifest
Left = 640
Top = 8
Left = 48
Top = 216
end
object qryBugs: TADOQuery
Active = True
Connection = ADOConnection1
CursorType = ctStatic
AfterInsert = qryBugsAfterInsert
AfterScroll = qryBugsAfterScroll
Parameters = <>
SQL.Strings = (
'SELECT * FROM bugs order by wichtigkeit')
Left = 400
Left = 168
Top = 344
object qryBugsid: TAutoIncField
FieldName = 'id'
ReadOnly = True
end
object qryBugstitel: TStringField
FieldName = 'titel'
Size = 255
end
object qryBugsbeschreibung: TMemoField
FieldName = 'beschreibung'
BlobType = ftMemo
end
object qryBugserstellt: TDateTimeField
FieldName = 'erstellt'
end
object qryBugswichtigkeit: TIntegerField
FieldName = 'wichtigkeit'
end
object qryBugsbearbeiter: TIntegerField
FieldName = 'bearbeiter'
end
object qryBugsfixdatum: TDateTimeField
FieldName = 'fixdatum'
end
object qryBugsversion_release: TIntegerField
FieldName = 'version_release'
OnValidate = qryBugsversion_releaseValidate
end
object qryBugsmodul: TIntegerField
FieldName = 'modul'
end
object qryBugsprojekt: TIntegerField
FieldName = 'projekt'
end
end
object tblVersionen: TADOTable
Active = True
Connection = ADOConnection1
CursorType = ctStatic
TableName = 'versionen'
Left = 472
Left = 240
Top = 344
end
object dsVersionen: TDataSource
DataSet = tblVersionen
Left = 472
Left = 240
Top = 312
end
object tblProjekte: TADOTable
282,12 → 401,12
Connection = ADOConnection1
CursorType = ctStatic
TableName = 'projekte'
Left = 504
Left = 272
Top = 344
end
object dsProjekte: TDataSource
DataSet = tblProjekte
Left = 504
Left = 272
Top = 312
end
object tblModule: TADOTable
295,12 → 414,17
Connection = ADOConnection1
CursorType = ctStatic
TableName = 'module'
Left = 536
Left = 304
Top = 344
end
object dsModule: TDataSource
DataSet = tblModule
Left = 536
Left = 304
Top = 312
end
object Timer1: TTimer
OnTimer = Timer1Timer
Left = 128
Top = 216
end
end
/trunk/WuLiMain.pas
1,5 → 1,17
unit WuLiMain;
 
(*
* TODO:
* - fertigstellen
* ... multi user/projekt testen
* ... bearbeitungsnotiz-button (rtf-farben usw)
* ...
* - abfragen ob speichern wenn fenster geschlossen wird
* - filtern nach modul
* - verbinden mit ticketsystem von HS
* - rtf controls?
*)
 
interface
 
uses
8,29 → 20,40
ADODB, ComCtrls, Grids, DBGrids, Mask, Menus, XPMan;
 
type
TForm1 = class(TForm)
ADOConnection1: TADOConnection;
dsBugs: TDataSource;
TfrmBugtracker = class(TForm)
Panel1: TPanel;
DBGrid1: TDBGrid;
ComboBox1: TComboBox;
DBNavigator2: TDBNavigator;
Panel2: TPanel;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Label6: TLabel;
DBNavigator1: TDBNavigator;
DBRichEdit1: TDBRichEdit;
DBGrid1: TDBGrid;
DBEdit1: TDBEdit;
DBLookupComboBox1: TDBLookupComboBox;
DBEdit2: TDBEdit;
DBEdit3: TDBEdit;
DBLookupComboBox2: TDBLookupComboBox;
DBLookupComboBox3: TDBLookupComboBox;
TrackBar1: TTrackBar;
ADOConnection1: TADOConnection;
dsBugs: TDataSource;
tblMitarbeiter: TADOTable;
dsMitarbeiter: TDataSource;
Label1: TLabel;
Label2: TLabel;
MainMenu1: TMainMenu;
Stammdaten1: TMenuItem;
Mitarbeiter1: TMenuItem;
Projekte1: TMenuItem;
Module1: TMenuItem;
Versionen1: TMenuItem;
Projektwechseln1: TMenuItem;
XPManifest1: TXPManifest;
qryBugs: TADOQuery;
DBEdit2: TDBEdit;
DBEdit3: TDBEdit;
Label3: TLabel;
Label4: TLabel;
tblVersionen: TADOTable;
dsVersionen: TDataSource;
tblProjekte: TADOTable;
37,75 → 60,188
dsProjekte: TDataSource;
tblModule: TADOTable;
dsModule: TDataSource;
Versionen1: TMenuItem;
DBLookupComboBox2: TDBLookupComboBox;
Label5: TLabel;
DBLookupComboBox3: TDBLookupComboBox;
Label6: TLabel;
TrackBar1: TTrackBar;
ComboBox1: TComboBox;
Timer1: TTimer;
Splitter1: TSplitter;
Hilfe1: TMenuItem;
ber1: TMenuItem;
btnFixedToggle: TButton;
btnBearbeitungsnotiz: TButton;
qryBugsid: TAutoIncField;
qryBugstitel: TStringField;
qryBugsbeschreibung: TMemoField;
qryBugserstellt: TDateTimeField;
qryBugswichtigkeit: TIntegerField;
qryBugsbearbeiter: TIntegerField;
qryBugsfixdatum: TDateTimeField;
qryBugsversion_release: TIntegerField;
qryBugsmodul: TIntegerField;
qryBugsprojekt: TIntegerField;
procedure Mitarbeiter1Click(Sender: TObject);
procedure DateTimePicker1CloseUp(Sender: TObject);
procedure qryBugsAfterScroll(DataSet: TDataSet);
procedure Module1Click(Sender: TObject);
procedure Projekte1Click(Sender: TObject);
procedure Versionen1Click(Sender: TObject);
procedure TrackBar1Change(Sender: TObject);
procedure Timer1Timer(Sender: TObject);
procedure ComboBox1Change(Sender: TObject);
procedure Projektwechseln1Click(Sender: TObject);
procedure qryBugsAfterInsert(DataSet: TDataSet);
procedure ber1Click(Sender: TObject);
procedure btnFixedToggleClick(Sender: TObject);
procedure qryBugsversion_releaseValidate(Sender: TField);
procedure FormCreate(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
eingeloggtMitarbeiter: integer;
aktuellesProjekt: integer;
procedure NeuFiltern;
end;
 
var
Form1: TForm1;
frmBugtracker: TfrmBugtracker;
 
implementation
 
uses Mitarbeiter, Module, Versionen, Projekte;
uses Mitarbeiter, Module, Versionen, Projekte, Login, About, inifiles;
 
{$R *.dfm}
 
procedure TForm1.qryBugsAfterScroll(DataSet: TDataSet);
procedure TfrmBugtracker.qryBugsAfterInsert(DataSet: TDataSet);
begin
// DateTimePicker1.DateTime := qryBugs.FieldByName('fixdatum').AsDateTime;
// TrackBar1.Position := qryBugs.FieldByName('wichtigkeit').AsInteger;
// Standardwerte für einen neuen Bug
qryBugs.FieldByName('wichtigkeit').AsInteger := 5;
// qryBugs.FieldByName('bearbeiter').AsInteger := eingeloggtMitarbeiter;
qryBugs.FieldByName('projekt').AsInteger := aktuellesProjekt;
end;
 
procedure TForm1.TrackBar1Change(Sender: TObject);
procedure TfrmBugtracker.qryBugsAfterScroll(DataSet: TDataSet);
var
bakEvent: TNotifyEvent;
begin
bakEvent := TrackBar1.OnChange;
TrackBar1.OnChange := nil;
try
TrackBar1.Position := qryBugs.FieldByName('wichtigkeit').AsInteger;
finally
TrackBar1.OnChange := bakEvent;
end;
end;
 
procedure TfrmBugtracker.qryBugsversion_releaseValidate(Sender: TField);
begin
if qryBugs.FieldByName('fixdatum').IsNull then
begin
raise Exception.Create('Vor einer Veröffentlichung muss der Bugfix erst als gefixt markiert werden.');
end;
end;
 
procedure TfrmBugtracker.Timer1Timer(Sender: TObject);
begin
Timer1.Enabled := false;
if frmLogin.ShowModal = mrCancel then Close;
end;
 
procedure TfrmBugtracker.TrackBar1Change(Sender: TObject);
begin
if not (qryBugs.State in [dsEdit, dsInsert]) then qryBugs.Edit;
qryBugs.FieldByName('wichtigkeit').AsInteger := TrackBar1.Position;
end;
 
procedure TForm1.Versionen1Click(Sender: TObject);
procedure TfrmBugtracker.Versionen1Click(Sender: TObject);
begin
frmVersionen.ShowModal;
end;
 
procedure TForm1.DateTimePicker1CloseUp(Sender: TObject);
procedure TfrmBugtracker.ber1Click(Sender: TObject);
begin
(*
LockWindowUpdate(DBGrid1.Handle);
AboutBox.ShowModal;
end;
 
procedure TfrmBugtracker.btnFixedToggleClick(Sender: TObject);
begin
if not (qryBugs.State in [dsEdit, dsInsert]) then qryBugs.Edit;
qryBugs.FieldByName('fixdatum').AsDateTime := DateTimePicker1.DateTime;
LockWindowUpdate(0);
*)
if qryBugs.FieldByName('fixdatum').IsNull then
qryBugs.FieldByName('fixdatum').AsDateTime := Now
else
qryBugs.FieldByName('fixdatum').Clear;
end;
 
procedure TForm1.Mitarbeiter1Click(Sender: TObject);
procedure TfrmBugtracker.ComboBox1Change(Sender: TObject);
begin
case ComboBox1.ItemIndex of
0:
begin
// Meine offenen Bugs (nach Wichtigkeit)
qryBugs.SQL.Text := 'SELECT * FROM bugs WHERE projekt = '+IntToStr(aktuellesProjekt)+' AND fixdatum IS NULL AND bearbeiter = '+IntToStr(eingeloggtMitarbeiter)+' ORDER BY wichtigkeit DESC';
end;
1:
begin
// Alle offenen Bugs (nach Wichtigkeit)
qryBugs.SQL.Text := 'SELECT * FROM bugs WHERE projekt = '+IntToStr(aktuellesProjekt)+' AND fixdatum IS NULL ORDER BY wichtigkeit DESC';
end;
2:
begin
// Gelöst ohne Veröffentlichung (nach Lösungsdatum)
qryBugs.SQL.Text := 'SELECT * FROM bugs WHERE projekt = '+IntToStr(aktuellesProjekt)+' AND fixdatum IS NOT NULL ORDER BY fixdatum DESC';
end;
3:
begin
// Gelöst und Veröffentlicht (nach Version und Lösungsdatum)
qryBugs.SQL.Text := 'SELECT * FROM bugs WHERE projekt = '+IntToStr(aktuellesProjekt)+' AND fixdatum IS NOT NULL ORDER BY version_release DESC, fixdatum DESC';
end;
4:
begin
// Alle Bugs (nach Eröffnungsdatum)
qryBugs.SQL.Text := 'SELECT * FROM bugs WHERE projekt = '+IntToStr(aktuellesProjekt)+' ORDER BY erstellt DESC';
end;
end;
qryBugs.Active := true;
end;
 
procedure TfrmBugtracker.FormCreate(Sender: TObject);
var
ini: TMemIniFile;
begin
ini := TMemIniFile.Create('bugtracker.ini');
try
ADOConnection1.ConnectionString := ini.ReadString('Database', 'ConnectionString', '');
finally
ini.Free;
end;
 
ADOConnection1.Connected := true;
qryBugs.Active := true;
tblMitarbeiter.Active := true;
tblVersionen.Active := true;
tblProjekte.Active := true;
tblModule.Active := true;
end;
 
procedure TfrmBugtracker.Mitarbeiter1Click(Sender: TObject);
begin
frmMitarbeiter.ShowModal;
end;
 
procedure TForm1.Module1Click(Sender: TObject);
procedure TfrmBugtracker.Module1Click(Sender: TObject);
begin
frmModule.ShowModal;
end;
 
procedure TForm1.Projekte1Click(Sender: TObject);
procedure TfrmBugtracker.NeuFiltern;
begin
ComboBox1Change(ComboBox1);
end;
 
procedure TfrmBugtracker.Projekte1Click(Sender: TObject);
begin
frmProjekte.ShowModal;
end;
 
procedure TfrmBugtracker.Projektwechseln1Click(Sender: TObject);
begin
frmLogin.ShowModal;
end;
 
end.
/trunk/bugtracker.ini
0,0 → 1,2
[Database]
ConnectionString=Provider=MSDASQL.1;Persist Security Info=False;Data Source=MySQL RAS;Initial Catalog=bugtracker;
/trunk
Property changes:
Modified: svn:ignore
*.exe
__history
*.local
+*.identcache