⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 untoutaccessorymanager.pas

📁 销售软件
💻 PAS
字号:
(*===========================================================*)
(*                                                           *)
(*              Jerk Computer Assembly Manager               *)
(*                                                           *)
(*                    程序作者:杨芹勍                       *)
(*          武汉科技大学 理学院 信息与计算科学031班          *)
(*                  武汉科技大学 莘特工作室                  *)
(*                                                           *)
(*              IDE:Borland Delphi 2006 Update 2            *)
(*                 第三方控件:Raize 4.03                    *)
(*             数据库:Microsoft SQL Server 2000             *)
(*            数据库访问引擎:原生ADO(ADODB_TLB)           *)
(*           数据库管理引擎:JERK DBMANAGER ALPHA            *)
(*                                                           *)
(*           此软件及源代码归 JERK SYSTEM 版权所有           *)
(*            (C)Copyright 2002-2006 Jerk System.            *)
(*                                                           *)
(*===========================================================*)

unit untOutAccessoryManager;

interface

uses
  Windows,
  Messages,
  SysUtils,
  Variants,
  Classes,
  Graphics,
  Controls,
  Forms,
  Dialogs,
  ComCtrls,
  ExtCtrls,
  Menus,
  StdCtrls,
  StrUtils,
  Mask,
  ADODB_TLB,
  RzButton,
  RzBtnEdt,
  RzCmboBx,
  RzCommon,
  RzEdit,
  RzListVw,
  RzRadChk,
  RzSplit,
  RzPanel,
  RzTabs,
  JSDBListView,
  JCAMConsts,
  JCAMUtils,
  JCAMDialogForm,
  JCAMManagerForm,
  JCAMTableViewEditor;

type
  TfrmOutAccessoryManager = class( TfrmJCAMManagerForm )
    Label1: TLabel;
    edtInAccessoryName: TRzEdit;
    Label2: TLabel;
    edtClientName: TRzEdit;
    Label3: TLabel;
    edtMakeDate: TRzDateTimeEdit;
    procedure btnStatInfoClick(Sender: TObject);
  private
    { Private declarations }
  public
    procedure StartSurf; override;
  end;

var
  frmOutAccessoryManager: TfrmOutAccessoryManager;

implementation

{$R *.dfm}

uses
  untStatInfo,
  untTField,
  untTOutAccessory;

{ TfrmOutAccessoryManager }

procedure TfrmOutAccessoryManager.btnStatInfoClick(Sender: TObject);
var
  tf: TTableField;
  toa: TTableOutAccessory;
begin
  { 整机管理的统计信息 }

  if frmStatInfo <> nil then
    FreeAndNil( frmStatInfo );
  tf := TTableField.Create;
  tf.Connection := Self.Connection;
  toa := TTableOutAccessory.Create;
  toa.Connection := Self.Connection;
  frmStatInfo := TfrmStatInfo.Create( Self );
  with frmStatInfo do
  begin
    with StatListView.Items.Add do
    begin
      tf.FieldName := FN_INPRICE;
      Caption := tf.FieldChs;
      ImageIndex := dvwInfoList.DefaultImageIndex;
      SubItems.Add( IntToStr( toa.TotalInPricesByCondition( InfoSearchCondition )
        ) );
    end;
    with StatListView.Items.Add do
    begin
      tf.FieldName := FN_OUTPRICE;
      Caption := tf.FieldChs;
      ImageIndex := dvwInfoList.DefaultImageIndex;
      SubItems.Add( IntToStr( toa.TotalOutPricesByCondition( InfoSearchCondition )
        ) );
    end;
    with StatListView.Items.Add do
    begin
      tf.FieldName := FN_PROFIT;
      Caption := tf.FieldChs;
      ImageIndex := dvwInfoList.DefaultImageIndex;
      SubItems.Add( IntToStr( toa.TotalProfitByCondition( InfoSearchCondition )
        ) );
    end;
    ShowModal;
  end;
  FreeAndNil( toa );
  FreeAndNil( tf );
  FreeAndNil( frmStatInfo );
end;

procedure TfrmOutAccessoryManager.StartSurf;
begin
  inherited;

  // TODO: 设置快速填充的编辑框信息
  SetCustomEditTag( edtInAccessoryName, FN_INACCESSORYNAME );
  SetCustomEditTag( edtClientName, FN_CLIENTNAME );
  SetCustomEditTag( edtMakeDate, FN_OUTDATE );
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -