This commit is contained in:
DESKTOP-E401PHE\Administrator 2024-08-29 17:22:39 +08:00
parent ea48421f76
commit 1b8ba2485d
11 changed files with 91 additions and 19 deletions

View File

@ -71,7 +71,6 @@ object frmCollectInput: TfrmCollectInput
ParentCtl3D = False
ParentFont = False
TabOrder = 1
ExplicitTop = 44
object Label2: TLabel
Left = 245
Top = 20
@ -296,7 +295,7 @@ object frmCollectInput: TfrmCollectInput
OnBtnDnClick = PayMentBtnDnClick
end
object OppCoName: TBtnEditC
Left = 301
Left = 303
Top = 17
Width = 140
Height = 20

View File

@ -165,7 +165,8 @@ begin
Close;
SQL.Clear;
Filtered := False;
sql.Add(' select A.*,Saleser=(select Saleser from BS_Company X where X.CoAbbrName=A.OppCoName)');
sql.Add(' select Amount=(Case when ISNULL(A.RegType,'''')=''ÊÕ¿î'' then -1*Amount else Amount end)');
SQL.Add(',A.*,Saleser=(select Saleser from BS_Company X where X.CoAbbrName=A.OppCoName)');
sql.Add(' from Finance_Flow A where A.FFType=''澗운되션'' ');
case cxTabControl1.TabIndex of
0:

View File

@ -21,7 +21,6 @@ inherited frmCompanySel: TfrmCompanySel
Height = 476
Align = alClient
TabOrder = 0
ExplicitTop = 88
object TV1: TcxGridDBTableView
OnDblClick = TV1DblClick
Navigator.Buttons.CustomButtons = <>

View File

@ -79,7 +79,6 @@ object frmPayInput: TfrmPayInput
ParentCtl3D = False
ParentFont = False
TabOrder = 1
ExplicitTop = 44
object Label2: TLabel
Left = 32
Top = 102
@ -108,7 +107,7 @@ object frmPayInput: TfrmPayInput
end
object Label8: TLabel
Left = 486
Top = 144
Top = 143
Width = 52
Height = 15
Caption = #20184#27454#26041#24335
@ -262,6 +261,19 @@ object frmPayInput: TfrmPayInput
Font.Style = [fsBold]
ParentFont = False
end
object Label6: TLabel
Left = 486
Top = 20
Width = 52
Height = 15
Caption = #30331#35760#31867#22411
Font.Charset = ANSI_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = 'Times New Roman'
Font.Style = [fsBold]
ParentFont = False
end
object Note: TMemo
Left = 92
Top = 237
@ -306,8 +318,8 @@ object frmPayInput: TfrmPayInput
OnBtnDnClick = PayMentBtnDnClick
end
object OppCoName: TBtnEditC
Left = 92
Top = 100
Left = 90
Top = 99
Width = 140
Height = 20
Font.Charset = GB2312_CHARSET
@ -322,7 +334,7 @@ object frmPayInput: TfrmPayInput
OnBtnDnClick = PayMentBtnDnClick
end
object OurCoName: TBtnEditC
Left = 92
Left = 90
Top = 18
Width = 140
Height = 20
@ -473,6 +485,18 @@ object frmPayInput: TfrmPayInput
Time = 0.670856296288548000
TabOrder = 14
end
object RegType: TComboBox
Left = 544
Top = 17
Width = 145
Height = 20
ItemIndex = 0
TabOrder = 15
Text = #20184#27454
Items.Strings = (
#20184#27454
#25910#27454)
end
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Financial.ADOLink

View File

@ -55,6 +55,8 @@ type
Label4: TLabel;
PKDate: TDateTimePicker;
ToolButton1: TToolButton;
RegType: TComboBox;
Label6: TLabel;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
@ -154,8 +156,15 @@ begin
try
frmCompanySel := TfrmCompanySel.Create(Application);
with frmCompanySel do
begin
if RegType.text = '마운' then
begin
FCoType := '묩壇<EBACA9>';
end
else
begin
FCoType := '와빵';
end;
if ShowModal = 1 then
begin
OppCoName.Text := Trim(CDS_1.fieldbyname('CoAbbrName').AsString);
@ -301,8 +310,15 @@ begin
try
frmZDYHelpFY := TfrmZDYHelpFY.Create(Application);
with frmZDYHelpFY do
begin
if RegType.text = '마운' then
begin
MainType := '마운잚謹';
end
else
begin
MainType := '澗운잚謹';
end;
flag := Copy(fsj, 1, FWZ - 1);
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
if ShowModal = 1 then
@ -380,8 +396,16 @@ begin
Append;
FieldByName('FillId').Value := Trim(DCode);
FieldByName('Filler').Value := Trim(DName);
if RegType.text = '마운' then
begin
FieldByName('FFFlag').Value := '壇마마';
FieldByName('FFType').Value := '마운되션';
end
else
begin
FieldByName('FFFlag').Value := '壇澗澗';
FieldByName('FFType').Value := '澗운되션';
end;
FieldByName('status').Value := '0';
FieldByName('FFQtyFlag').Value := -1;
end

View File

@ -6,6 +6,8 @@ inherited frmPayList: TfrmPayList
ClientWidth = 1284
FormStyle = fsMDIChild
Visible = True
ExplicitLeft = -94
ExplicitTop = -42
ExplicitWidth = 1300
ExplicitHeight = 629
PixelsPerInch = 96
@ -304,6 +306,7 @@ inherited frmPayList: TfrmPayList
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
ScrollbarAnnotations.CustomAnnotations = <>
OnCustomDrawCell = Tv1CustomDrawCell
DataController.DataSource = DS_1
DataController.Filter.AutoDataSetFilter = True
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
@ -504,6 +507,11 @@ inherited frmPayList: TfrmPayList
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
end
object Tv1Column12: TcxGridDBColumn
DataBinding.FieldName = 'RegType'
DataBinding.IsNullValueType = True
Visible = False
end
end
object cxGridLevel1: TcxGridLevel
GridView = Tv1

View File

@ -98,6 +98,7 @@ type
Button4: TButton;
ToolButton6: TToolButton;
ToolButton7: TToolButton;
Tv1Column12: TcxGridDBColumn;
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure btnDelClick(Sender: TObject);
@ -125,6 +126,9 @@ type
procedure Button4Click(Sender: TObject);
procedure ToolButton6Click(Sender: TObject);
procedure ToolButton7Click(Sender: TObject);
procedure Tv1CustomDrawCell(Sender: TcxCustomGridTableView;
ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo;
var ADone: Boolean);
private
procedure InitGrid();
procedure SetStatus();
@ -233,6 +237,7 @@ begin
sql.Add(' select IsTP=cast((case when (select COUNT(T.WBID) from TP_File T where T.WBID=A.FFID)=0 then 0 else 1 end) as bit ) ');
sql.ADD(',A.*,B.account,B.OpenBank from Finance_Flow A');
sql.Add(' Left join BS_Company_Bank B on A.OppBankID=B.CBID where A.FFType=''¸¶¿îµÇ¼Ç'' ');
sql.Add(' Or ISNULL(A.RegType,'''')=''ÊÕ¿î''');
case cxTabControl1.TabIndex of
0:
begin
@ -253,6 +258,7 @@ begin
sql.Add(' and A.SQDate<''' + FormatDateTime('yyyy-MM-dd', Enddate.DateTime + 1) + ''' ');
end;
sql.Add(WSql);
// showmessage(sql.text);
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
@ -901,6 +907,17 @@ begin
end;
procedure TfrmPayList.Tv1CustomDrawCell(Sender: TcxCustomGridTableView;
ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo;
var ADone: Boolean);
begin
if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('RegType').Index] = 'ÊÕ¿î' then
begin
ACanvas.Brush.Color := $00FF8080;
end
end;
procedure TfrmPayList.OppCoNameKeyPress(Sender: TObject; var Key: Char);
begin
if Key = #13 then