📄 pm_oppobalance_h.pas
字号:
unit Pm_OpPoBalance_H;
Interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
Base_Check_Head, Menus, Db, ActnList, AdODB, Grids, DBGridEh, StdCtrls,
ExtCtrls, ComCtrls, ToolWin, jpeg;
Type
TFrm_Pm_OpPoBalance_H = Class(TFrm_Base_Check_Head)
AdoQry_HeadPoTmpFlag: TIntegerField;
AdoQry_HeadPoNo: TStringField;
AdoQry_HeadVendorCode: TStringField;
AdoQry_HeadVendorName: TStringField;
AdoQry_HeadPoDate: TDateTimeField;
procedure Act_LookExecute(Sender: TObject);
private
{ Private declarations }
public
procedure InitForm(AdOConnection:TAdOConnection;ReadOnly:Boolean);OverRide;
{ Public declarations }
end;
var
Frm_Pm_OpPoBalance_H: TFrm_Pm_OpPoBalance_H;
implementation
uses Pm_OpPoBalance_B,Sys_Global;
{$R *.DFM}
procedure TFrm_Pm_OpPoBalance_H.InitForm(AdOConnection: TAdOConnection;
ReadOnly: Boolean);
begin
inherited;
if Param1='PoSpecial' then
begin
Caption:='独立委外加工订单结算';
ConditionUserDefine:='PO.PoSpecial=1';
end
else
begin
Caption:='委外加工订单结算';
ConditionUserDefine:='PO.PoSpecial=0';
end;
Pnl_Title.Caption:=Caption;
SelectFromSql:='Select Po.PoTmpFlag'
+',Po.PoNo'
+',Po.VendorCode'
+',Vendor.VendorName'
+',Po.PoDate'
+' From Po'
+' Join Vendor On Vendor.VendorCode=Po.VendorCode';
ConditionUserDefine:=ConditionUserDefine
+' And Po.PoType=1'
+' And Po.PoNo Not In'
+' (Select Distinct PoNo From PoLine Where PoLineStatus<>7)';
OrderByFields:='VendorCode,PoNo';
GetData;
Frm_Check_Body:=TFrm_Pm_OpPoBalance_B.Create(Self);
Frm_Check_Body.Caption:=Caption;
end;
procedure TFrm_Pm_OpPoBalance_H.Act_LookExecute(Sender: TObject);
begin
{AdoQry_Tmp.Close;
AdoQry_Tmp.SQL.Text:='Select PoNo'
+' From InvInBill'
+' Where InvBillStkChck=0'
+' And BillTypeCode=''0103'''
+' And PoNo='''+AdoQry_Head.fieldbyname('PoNo').AsString+'''';
AdoQry_Tmp.Open;
if not AdoQry_Tmp.IsEmpty then
begin
DispInfo('本订单有未经过核价的单据存在,不允许进行订单结算!',3);
Abort;
end;}
inherited;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -