Changeset 20 for trunk/Forms


Ignore:
Timestamp:
Mar 25, 2013, 10:58:03 PM (12 years ago)
Author:
chronos
Message:
  • Upraveno: Celé číslo účtu rozděleno do samostatných částí jako samotné číslo a kód banky.
Location:
trunk/Forms
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormAccounts.lfm

    r12 r20  
    2828      end   
    2929      item
     30        Caption = 'Bank code'
     31      end   
     32      item
    3033        Caption = 'Balance'
    3134        Width = 80
     
    3942      end>
    4043    OwnerData = True
     44    PopupMenu = PopupMenu1
    4145    ReadOnly = True
    4246    RowSelect = True
     
    7276    Top = 308
    7377    Width = 75
     78    Action = AAdd
    7479    Anchors = [akLeft, akBottom]
    75     Caption = 'Add'
    7680    Color = clScrollBar
    77     OnClick = ButtonAddClick
    7881    TabOrder = 3
    7982  end
     
    8386    Top = 308
    8487    Width = 75
     88    Action = ARemove
    8589    Anchors = [akLeft, akBottom]
    86     Caption = 'Remove'
    8790    Color = clScrollBar
    88     OnClick = ButtonRemoveClick
    8991    TabOrder = 4
    9092  end
     
    127129    OnChange = LabeledEditTokenChange
    128130  end
     131  object ActionList1: TActionList
     132    Images = Core.ImageList1
     133    left = 200
     134    top = 304
     135    object AAdd: TAction
     136      Caption = 'Add'
     137      OnExecute = AAddExecute
     138      ShortCut = 45
     139    end
     140    object ARemove: TAction
     141      Caption = 'Remove'
     142      OnExecute = ARemoveExecute
     143      ShortCut = 46
     144    end
     145  end
     146  object PopupMenu1: TPopupMenu
     147    Images = Core.ImageList1
     148    left = 280
     149    top = 304
     150    object MenuItem1: TMenuItem
     151      Action = AAdd
     152    end
     153    object MenuItem2: TMenuItem
     154      Action = ARemove
     155    end
     156  end
    129157end
  • trunk/Forms/UFormAccounts.lrt

    r12 r20  
    22TFORMACCOUNTS.LISTVIEW1.COLUMNS[0].CAPTION=Name
    33TFORMACCOUNTS.LISTVIEW1.COLUMNS[1].CAPTION=Number
    4 TFORMACCOUNTS.LISTVIEW1.COLUMNS[2].CAPTION=Balance
    5 TFORMACCOUNTS.LISTVIEW1.COLUMNS[3].CAPTION=Date
    6 TFORMACCOUNTS.LISTVIEW1.COLUMNS[4].CAPTION=Token
     4TFORMACCOUNTS.LISTVIEW1.COLUMNS[2].CAPTION=Bank code
     5TFORMACCOUNTS.LISTVIEW1.COLUMNS[3].CAPTION=Balance
     6TFORMACCOUNTS.LISTVIEW1.COLUMNS[4].CAPTION=Date
     7TFORMACCOUNTS.LISTVIEW1.COLUMNS[5].CAPTION=Token
    78TFORMACCOUNTS.BUTTONOK.CAPTION=Ok
    89TFORMACCOUNTS.BUTTONCANCEL.CAPTION=Cancel
    9 TFORMACCOUNTS.BUTTONADD.CAPTION=Add
    10 TFORMACCOUNTS.BUTTONREMOVE.CAPTION=Remove
    1110TFORMACCOUNTS.LABELEDEDITTOKEN.EDITLABEL.CAPTION=Token
    1211TFORMACCOUNTS.LABELEDEDITNAME.EDITLABEL.CAPTION=Name
     12TFORMACCOUNTS.AADD.CAPTION=Add
     13TFORMACCOUNTS.AREMOVE.CAPTION=Remove
  • trunk/Forms/UFormAccounts.pas

    r14 r20  
    77uses
    88  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,
    9   StdCtrls, ExtCtrls, SpecializedList;
     9  StdCtrls, ExtCtrls, ActnList, Menus, SpecializedList;
    1010
    1111type
     
    1414
    1515  TFormAccounts = class(TForm)
     16    AAdd: TAction;
     17    ARemove: TAction;
     18    ActionList1: TActionList;
    1619    ButtonAdd: TButton;
    1720    ButtonRemove: TButton;
     
    2124    LabeledEditName: TLabeledEdit;
    2225    ListView1: TListView;
    23     procedure ButtonAddClick(Sender: TObject);
    24     procedure ButtonRemoveClick(Sender: TObject);
     26    MenuItem1: TMenuItem;
     27    MenuItem2: TMenuItem;
     28    PopupMenu1: TPopupMenu;
     29    procedure AAddExecute(Sender: TObject);
     30    procedure ARemoveExecute(Sender: TObject);
    2531    procedure FormCreate(Sender: TObject);
    2632    procedure FormDestroy(Sender: TObject);
     
    5763    Item.Data := Accounts[Item.Index];
    5864    Item.SubItems.Add(Number);
     65    Item.SubItems.Add(BankCode);
    5966    Item.SubItems.Add(FloatToStr(Balance));
    6067    Item.SubItems.Add(DateToStr(Time));
     
    97104end;
    98105
    99 procedure TFormAccounts.ButtonAddClick(Sender: TObject);
     106procedure TFormAccounts.ARemoveExecute(Sender: TObject);
     107begin
     108  if Assigned(ListView1.Selected) then begin
     109    Accounts.Delete(Accounts.IndexOf(ListView1.Selected.Data));
     110    Reload;
     111  end;
     112end;
     113
     114procedure TFormAccounts.AAddExecute(Sender: TObject);
    100115begin
    101116  with Accounts.AddNew(TAccount.Create) do begin
    102117  end;
    103   Reload;
    104 end;
    105 
    106 procedure TFormAccounts.ButtonRemoveClick(Sender: TObject);
    107 begin
    108   Accounts.Delete(Accounts.IndexOf(ListView1.Selected.Data));
    109118  Reload;
    110119end;
     
    124133procedure TFormAccounts.UpdateInterface;
    125134begin
    126   ButtonRemove.Enabled := Assigned(ListView1.Selected);
     135  ARemove.Enabled := Assigned(ListView1.Selected);
    127136  LabeledEditToken.Enabled := Assigned(ListView1.Selected);
    128137  LabeledEditName.Enabled := Assigned(ListView1.Selected);
  • trunk/Forms/UFormMain.lfm

    r15 r20  
    11object FormMain: TFormMain
    2   Left = 364
    3   Height = 390
    4   Top = 183
    5   Width = 519
     2  Left = 357
     3  Height = 513
     4  Top = 122
     5  Width = 602
    66  Caption = 'FioInfo'
    7   ClientHeight = 390
    8   ClientWidth = 519
     7  ClientHeight = 513
     8  ClientWidth = 602
    99  OnClose = FormClose
    1010  OnCreate = FormCreate
     
    1313  LCLVersion = '1.1'
    1414  object ButtonSettings: TButton
    15     Left = 384
     15    Left = 454
    1616    Height = 25
    17     Top = 358
     17    Top = 481
    1818    Width = 112
    1919    Action = Core.ASettings
     
    2424    Left = 16
    2525    Height = 57
    26     Top = 120
    27     Width = 498
    28     Anchors = [akTop, akLeft, akRight]
     26    Top = 250
     27    Width = 581
     28    Anchors = [akLeft, akRight, akBottom]
    2929    Caption = 'New transaction from last check'
    3030    ClientHeight = 38
    31     ClientWidth = 494
     31    ClientWidth = 577
    3232    TabOrder = 1
    3333    object ButtonNew: TButton
     
    4040      TabOrder = 0
    4141    end
     42    object Label7: TLabel
     43      Left = 6
     44      Height = 17
     45      Top = 12
     46      Width = 47
     47      Caption = 'Last id:'
     48      ParentColor = False
     49    end
     50    object SpinEditLastId: TSpinEdit
     51      Left = 70
     52      Height = 27
     53      Top = 7
     54      Width = 96
     55      MaxValue = 1000000000
     56      TabOrder = 1
     57    end
    4258  end
    4359  object GroupBox2: TGroupBox
    4460    Left = 17
    4561    Height = 72
    46     Top = 184
    47     Width = 498
    48     Anchors = [akTop, akLeft, akRight]
     62    Top = 316
     63    Width = 581
     64    Anchors = [akLeft, akRight, akBottom]
    4965    Caption = 'Transactions from defined time interval'
    5066    ClientHeight = 53
    51     ClientWidth = 494
     67    ClientWidth = 577
    5268    TabOrder = 2
    5369    object ButtonInterval: TButton
     
    112128    Left = 16
    113129    Height = 65
    114     Top = 280
    115     Width = 499
    116     Anchors = [akTop, akLeft, akRight]
     130    Top = 412
     131    Width = 582
     132    Anchors = [akLeft, akRight, akBottom]
    117133    Caption = 'Selected mothly report'
    118134    ClientHeight = 46
    119     ClientWidth = 495
     135    ClientWidth = 578
    120136    TabOrder = 3
    121137    object ButtonMonthly: TButton
     
    168184    Left = 16
    169185    Height = 25
    170     Top = 358
     186    Top = 481
    171187    Width = 112
    172188    Action = Core.AExit
     
    177193    Left = 136
    178194    Height = 25
    179     Top = 358
     195    Top = 481
    180196    Width = 112
    181197    Action = Core.AAbout
     
    195211    Height = 29
    196212    Top = 8
    197     Width = 312
     213    Width = 395
    198214    Anchors = [akTop, akLeft, akRight]
    199215    ItemHeight = 0
     
    203219  end
    204220  object ButtonNew1: TButton
    205     Left = 416
     221    Left = 499
    206222    Height = 25
    207223    Top = 8
     
    214230  object GroupBox4: TGroupBox
    215231    Left = 16
    216     Height = 65
     232    Height = 197
    217233    Top = 48
    218     Width = 498
    219     Anchors = [akTop, akLeft, akRight]
     234    Width = 581
     235    Anchors = [akTop, akLeft, akRight, akBottom]
    220236    Caption = 'Account state'
    221     ClientHeight = 46
    222     ClientWidth = 494
     237    ClientHeight = 178
     238    ClientWidth = 577
    223239    TabOrder = 8
    224240    object Label6: TLabel
     
    241257      Left = 358
    242258      Height = 25
    243       Top = 7
     259      Top = -1
    244260      Width = 112
    245261      Caption = 'Get'
     
    247263      TabOrder = 0
    248264    end
     265    object ListView1: TListView
     266      Left = 6
     267      Height = 144
     268      Top = 31
     269      Width = 561
     270      Anchors = [akTop, akLeft, akRight, akBottom]
     271      Columns = <     
     272        item
     273          Caption = 'Id'
     274        end     
     275        item
     276          Caption = 'Date'
     277          Width = 80
     278        end     
     279        item
     280          Caption = 'Account'
     281          Width = 80
     282        end     
     283        item
     284          Caption = 'Value'
     285          Width = 80
     286        end     
     287        item
     288          Caption = 'Var. sym.'
     289          Width = 70
     290        end     
     291        item
     292          Caption = 'Spec. sym.'
     293        end     
     294        item
     295          Caption = 'Const. sym.'
     296          Width = 134
     297        end>
     298      TabOrder = 1
     299      ViewStyle = vsReport
     300    end
    249301  end
    250302end
  • trunk/Forms/UFormMain.lrt

    r15 r20  
    22TFORMMAIN.GROUPBOX1.CAPTION=New transaction from last check
    33TFORMMAIN.BUTTONNEW.CAPTION=Download
     4TFORMMAIN.LABEL7.CAPTION=Last id:
    45TFORMMAIN.GROUPBOX2.CAPTION=Transactions from defined time interval
    56TFORMMAIN.BUTTONINTERVAL.CAPTION=Download
     
    2021TFORMMAIN.LABELBALANCE.CAPTION=   
    2122TFORMMAIN.BUTTONGETSTATE.CAPTION=Get
     23TFORMMAIN.LISTVIEW1.COLUMNS[0].CAPTION=Id
     24TFORMMAIN.LISTVIEW1.COLUMNS[1].CAPTION=Date
     25TFORMMAIN.LISTVIEW1.COLUMNS[2].CAPTION=Account
     26TFORMMAIN.LISTVIEW1.COLUMNS[3].CAPTION=Value
     27TFORMMAIN.LISTVIEW1.COLUMNS[4].CAPTION=Var. sym.
     28TFORMMAIN.LISTVIEW1.COLUMNS[5].CAPTION=Spec. sym.
     29TFORMMAIN.LISTVIEW1.COLUMNS[6].CAPTION=Const. sym.
  • trunk/Forms/UFormMain.pas

    r16 r20  
    77uses
    88  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls,
    9   ExtCtrls, Menus, ActnList, Spin, EditBtn, UFioAPI, URegistry, Registry,
    10   DateUtils;
     9  ExtCtrls, Menus, ActnList, Spin, EditBtn, ComCtrls, UFioAPI, URegistry,
     10  Registry, DateUtils;
    1111
    1212type
     
    3636    Label5: TLabel;
    3737    Label6: TLabel;
     38    Label7: TLabel;
    3839    LabelBalance: TLabel;
     40    ListView1: TListView;
    3941    SpinEditYear: TSpinEdit;
    4042    SpinEditId: TSpinEdit;
     43    SpinEditLastId: TSpinEdit;
    4144    procedure ButtonGetStateClick(Sender: TObject);
    4245    procedure ButtonIntervalClick(Sender: TObject);
  • trunk/Forms/UFormSettings.lfm

    r18 r20  
    100100    Width = 532
    101101    Anchors = [akTop, akLeft, akRight]
    102     Caption = '%f - data format, %d - date, %t - time, %a - account number, %n - account name, %% - percent symbol'
     102    Caption = '%f - data format, %d - date, %t - time, %a - account number, %n - account name, %b - bank code, %% - percent symbol'
    103103    ParentColor = False
    104104    WordWrap = True
  • trunk/Forms/UFormSettings.lrt

    r18 r20  
    66TFORMSETTINGS.BUTTON1.CAPTION=Select
    77TFORMSETTINGS.LABELEDEDITFILENAMEFORMAT.EDITLABEL.CAPTION=Output file name format:
    8 TFORMSETTINGS.LABEL2.CAPTION=%f - data format, %d - date, %t - time, %a - account number, %n - account name, %% - percent symbol
     8TFORMSETTINGS.LABEL2.CAPTION=%f - data format, %d - date, %t - time, %a - account number, %n - account name, %b - bank code, %% - percent symbol
    99TFORMSETTINGS.LABEL3.CAPTION=Interface language:
Note: See TracChangeset for help on using the changeset viewer.