From a7e6fb4bb575be0c1c800e8f3f46dd564ecfe672 Mon Sep 17 00:00:00 2001 From: funa <1559646174@qq.com> Date: Mon, 9 Nov 2026 17:24:37 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E6=96=99=20=E5=9D=AF=E5=B8=83?= =?UTF-8?q?=E4=BB=93=E5=BA=93=20=E8=B4=A2=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- A05基础资料管理/BaseInfo.dproj | 6 ++++++ A05基础资料管理/U_MachineManage.dfm | 25 +++++++++++++++++----- A05基础资料管理/U_MachineManage.pas | 13 +++++++++++- A09财务通用管理/U_ReceivableInput.pas | 26 ++++++++++++++++++++++- E04梭织坯布仓库/U_TatClothCKHZList.dfm | 10 +++++++++ E04梭织坯布仓库/U_TatClothCKHZList.pas | 9 +++++--- E04梭织坯布仓库/U_TatClothJXCList.dfm | 6 ++++++ E04梭织坯布仓库/U_TatClothJXCList.pas | 4 +++- E04梭织坯布仓库/U_TatClothRKHZList.dfm | 29 ++++++++++++++++++++++++-- E04梭织坯布仓库/U_TatClothRKHZList.pas | 24 ++++++++++++++++----- E04梭织坯布仓库/U_TatDRList.dfm | 12 +++++++++++ E04梭织坯布仓库/U_TatDRList.pas | 3 ++- E04梭织坯布仓库/U_TatDRtInPut.dfm | 11 ++++++++++ E04梭织坯布仓库/U_TatDRtInPut.pas | 3 ++- 14 files changed, 161 insertions(+), 20 deletions(-) diff --git a/A05基础资料管理/BaseInfo.dproj b/A05基础资料管理/BaseInfo.dproj index 91264e4..f97bd26 100644 --- a/A05基础资料管理/BaseInfo.dproj +++ b/A05基础资料管理/BaseInfo.dproj @@ -141,6 +141,12 @@
frmLabelPrint
dfm + +
frmTatClothInfoSel
+
+ +
frmSalesContractSel
+
BaseDataLink
dfm diff --git a/A05基础资料管理/U_MachineManage.dfm b/A05基础资料管理/U_MachineManage.dfm index 45e020a..0afaac3 100644 --- a/A05基础资料管理/U_MachineManage.dfm +++ b/A05基础资料管理/U_MachineManage.dfm @@ -93,7 +93,7 @@ inherited frmMachineManage: TfrmMachineManage OnClick = tbBindProdClick end object tbBindProd2: TToolButton - Left = 699 + Left = 598 Top = 0 AutoSize = True Caption = #32465#23450#20135#21697'2' @@ -101,7 +101,7 @@ inherited frmMachineManage: TfrmMachineManage OnClick = tbBindProd2Click end object ToolButton3: TToolButton - Left = 901 + Left = 699 Top = 0 AutoSize = True Caption = #25171#21360 @@ -109,7 +109,7 @@ inherited frmMachineManage: TfrmMachineManage OnClick = ToolButton3Click end object ToolButton1: TToolButton - Left = 972 + Left = 770 Top = 0 AutoSize = True Caption = #23548#20986 @@ -117,7 +117,7 @@ inherited frmMachineManage: TfrmMachineManage OnClick = ToolButton1Click end object TbSaveFormat: TToolButton - Left = 1043 + Left = 841 Top = 0 AutoSize = True Caption = #20445#23384#26684#24335 @@ -125,7 +125,7 @@ inherited frmMachineManage: TfrmMachineManage OnClick = TbSaveFormatClick end object TBClose: TToolButton - Left = 1138 + Left = 936 Top = 0 AutoSize = True Caption = #20851#38381 @@ -275,6 +275,13 @@ inherited frmMachineManage: TfrmMachineManage Height = 12 Caption = #26426#21488#21495 end + object Label2: TLabel + Left = 220 + Top = 20 + Width = 48 + Height = 12 + Caption = #20135#21697#21517#31216 + end object MCNO: TEdit Tag = 2 Left = 105 @@ -284,6 +291,14 @@ inherited frmMachineManage: TfrmMachineManage TabOrder = 0 OnChange = CustomerChange end + object CName: TEdit + Left = 272 + Top = 16 + Width = 140 + Height = 20 + TabOrder = 1 + OnChange = CustomerChange + end end object cxTabControl1: TcxTabControl [3] Left = 0 diff --git a/A05基础资料管理/U_MachineManage.pas b/A05基础资料管理/U_MachineManage.pas index 7b4ac91..4aaeb81 100644 --- a/A05基础资料管理/U_MachineManage.pas +++ b/A05基础资料管理/U_MachineManage.pas @@ -40,6 +40,8 @@ type N4: TMenuItem; Panel1: TPanel; MCNO: TEdit; + Label2: TLabel; + CName: TEdit; v2Column8: TcxGridDBColumn; Label1: TLabel; v2Column12: TcxGridDBColumn; @@ -179,11 +181,20 @@ end; procedure TfrmMachineManage.ToolButton2Click(Sender: TObject); var - sql: string; + sql, MCName: string; begin if ADOQueryMain.Active then begin sql := SGetFilters(Panel1, 1, 2); + //²úƷÃû³ÆͬʱƥÅä²úƷ1/²úƷ2£»SGetFiltersΪ¿մ®ʱ²»ÄÜƴand¿ªͷ£¬·ñÔòADO¹ýÂ˱í´ïʽ·Ƿ¨ + MCName := Trim(CName.Text); + if MCName <> '' then + begin + if sql <> '' then + sql := sql + ' and'; + sql := sql + ' (C_Name like ' + QuotedStr('%' + MCName + '%') + + ' or C_Name2 like ' + QuotedStr('%' + MCName + '%') + ')'; + end; SDofilter(ADOQueryMain, sql); SCreateCDS(ADOQueryMain, CDS_HZ); SInitCDSData(ADOQueryMain, CDS_HZ); diff --git a/A09财务通用管理/U_ReceivableInput.pas b/A09财务通用管理/U_ReceivableInput.pas index 0286444..68c85ed 100644 --- a/A09财务通用管理/U_ReceivableInput.pas +++ b/A09财务通用管理/U_ReceivableInput.pas @@ -14,7 +14,7 @@ uses IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit, cxTextEdit, cxDropDownEdit, BtnEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges, - dxBarBuiltInMenu, U_BaseList, cxContainer, cxCurrencyEdit; + dxBarBuiltInMenu, U_BaseList, cxContainer, cxCurrencyEdit, dxSkinWXI; type TfrmReceivableInput = class(TForm) @@ -292,6 +292,30 @@ begin begin self.ConNo.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('ConNo').AsString); + with frmFinTradeSalesContractSel.CDS_1 do + begin + if Trim(fieldbyname('BuyName').AsString) <> '' then + begin + self.OppCoName.Text := Trim(fieldbyname('BuyName').AsString); + self.OppCoName.TxtCode := Trim(fieldbyname('BuyNo').AsString); + end; + if Trim(fieldbyname('Payment').AsString) <> '' then + self.PayMent.Text := Trim(fieldbyname('Payment').AsString); + if Trim(fieldbyname('C_Code').AsString) <> '' then + self.F_Code.Text := Trim(fieldbyname('C_Code').AsString); + if Trim(fieldbyname('C_Name').AsString) <> '' then + self.F_Name.Text := Trim(fieldbyname('C_Name').AsString); + if Trim(fieldbyname('C_Width').AsString) <> '' then + self.F_Width.Text := Trim(fieldbyname('C_Width').AsString); + if Trim(fieldbyname('C_GramWeight').AsString) <> '' then + self.F_GramWeight.Text := Trim(fieldbyname('C_GramWeight').AsString); + if not fieldbyname('ConPrice').IsNull then + self.Price.Value := fieldbyname('ConPrice').AsFloat; + if Trim(fieldbyname('IsTax').AsString) = 'ÊÇ' then + self.IsInvoice.ItemIndex := 0 + else if Trim(fieldbyname('IsTax').AsString) = '·ñ' then + self.IsInvoice.ItemIndex := 1; + end; end; end; diff --git a/E04梭织坯布仓库/U_TatClothCKHZList.dfm b/E04梭织坯布仓库/U_TatClothCKHZList.dfm index 4394cb6..8f3abc6 100644 --- a/E04梭织坯布仓库/U_TatClothCKHZList.dfm +++ b/E04梭织坯布仓库/U_TatClothCKHZList.dfm @@ -295,6 +295,16 @@ inherited frmTatClothCKHZList: TfrmTatClothCKHZList Options.Editing = False Width = 100 end + object Tv1UnitPrice: TcxGridDBColumn + Caption = #21333#20215 + DataBinding.FieldName = 'unit_price' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxCurrencyEditProperties' + Properties.DisplayFormat = '0.00' + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 66 + end object v1Column23: TcxGridDBColumn Caption = #21367#25968 DataBinding.FieldName = 'js' diff --git a/E04梭织坯布仓库/U_TatClothCKHZList.pas b/E04梭织坯布仓库/U_TatClothCKHZList.pas index f7737bc..851c5e4 100644 --- a/E04梭织坯布仓库/U_TatClothCKHZList.pas +++ b/E04梭织坯布仓库/U_TatClothCKHZList.pas @@ -11,9 +11,10 @@ uses ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common, RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus, cxCalendar, MovePanel, Math, Clipbrd, - cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, cxTextEdit, dxSkinsCore, + cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, cxTextEdit, cxCurrencyEdit, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges, dxBarBuiltInMenu, U_BaseList, cxPC, - System.StrUtils, dxSkinWXI, dxScrollbarAnnotations; + System.StrUtils, dxSkinWXI, + dxScrollbarAnnotations; type TfrmTatClothCKHZList = class(TfrmBaseList) @@ -45,6 +46,7 @@ type v1Column25: TcxGridDBColumn; v1Column26: TcxGridDBColumn; v1Column27: TcxGridDBColumn; + Tv1UnitPrice: TcxGridDBColumn; cxGrid1Level1: TcxGridLevel; Label5: TLabel; C_Name: TEdit; @@ -145,7 +147,7 @@ begin end else begin - sql.Add('select ContractBuyName,IONo,C_NAME,COUNT(*)JS,SUM(Meter)stkMeter,SUM(Yardage)StkYardage,SUM(NetWeight)StkWeight'); + sql.Add('select ContractBuyName,IONo,C_NAME,MAX(A.DR_unit_price) unit_price,COUNT(*)JS,SUM(Meter)stkMeter,SUM(Yardage)StkYardage,SUM(NetWeight)StkWeight'); sql.Add(' FROM V_Tat_Cloth_IO A where A.IOFlag = ''³ö¿â'' ' + WSql); sql.Add(' group by ContractBuyName,IONo,C_NAME'); end; @@ -156,6 +158,7 @@ begin Tv1carno.Visible := cxTabControl1.TabIndex = 0; v1Column25.Visible := cxTabControl1.TabIndex = 1; v1Column26.Visible := cxTabControl1.TabIndex = 1; + Tv1UnitPrice.Visible := cxTabControl1.TabIndex = 1; SCreateCDS(ADOQueryMain, CDS_1); SInitCDSData(ADOQueryMain, CDS_1); diff --git a/E04梭织坯布仓库/U_TatClothJXCList.dfm b/E04梭织坯布仓库/U_TatClothJXCList.dfm index d66dac3..2c228b8 100644 --- a/E04梭织坯布仓库/U_TatClothJXCList.dfm +++ b/E04梭织坯布仓库/U_TatClothJXCList.dfm @@ -363,4 +363,10 @@ inherited frmTatClothJXCList: TfrmTatClothJXCList Left = 776 Top = 284 end + object GPM_1: TcxGridPopupMenu + Grid = cxGrid1 + PopupMenus = <> + Left = 728 + Top = 288 + end end diff --git a/E04梭织坯布仓库/U_TatClothJXCList.pas b/E04梭织坯布仓库/U_TatClothJXCList.pas index c83ff58..22ec60c 100644 --- a/E04梭织坯布仓库/U_TatClothJXCList.pas +++ b/E04梭织坯布仓库/U_TatClothJXCList.pas @@ -9,7 +9,8 @@ uses cxGridCustomView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls, cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, ADODB, DBClient, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore, - dxScrollbarAnnotations, U_BaseList, dxSkinWXI, dxDateRanges; + dxScrollbarAnnotations, U_BaseList, dxSkinWXI, dxDateRanges, dxBarBuiltInMenu, + cxGridCustomPopupMenu, cxGridPopupMenu; type TfrmTatClothJXCList = class(TfrmBaseList) @@ -45,6 +46,7 @@ type ADOQueryTemp: TADOQuery; DS_1: TDataSource; CDS_1: TClientDataSet; + GPM_1: TcxGridPopupMenu; procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure FormCreate(Sender: TObject); procedure FormShow(Sender: TObject); diff --git a/E04梭织坯布仓库/U_TatClothRKHZList.dfm b/E04梭织坯布仓库/U_TatClothRKHZList.dfm index 1fc2b18..2a64c45 100644 --- a/E04梭织坯布仓库/U_TatClothRKHZList.dfm +++ b/E04梭织坯布仓库/U_TatClothRKHZList.dfm @@ -164,11 +164,34 @@ inherited frmTatClothRKHZList: TfrmTatClothRKHZList OnKeyPress = C_NameKeyPress end end - object cxGrid1: TcxGrid [2] + object cxTabControl1: TcxTabControl [2] Left = 0 Top = 105 Width = 1540 - Height = 495 + Height = 19 + Align = alTop + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -12 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 3 + Properties.CustomButtons.Buttons = <> + Properties.Style = 9 + Properties.TabIndex = 0 + Properties.Tabs.Strings = ( + #26426#21488#27719#24635 + #20135#21697#27719#24635) + OnChange = cxTabControl1Change + ClientRectRight = 0 + ClientRectTop = 0 + end + object cxGrid1: TcxGrid [3] + Left = 0 + Top = 124 + Width = 1540 + Height = 476 Align = alClient BorderStyle = cxcbsNone Font.Charset = GB2312_CHARSET @@ -179,6 +202,8 @@ inherited frmTatClothRKHZList: TfrmTatClothRKHZList ParentFont = False PopupMenu = PM_1 TabOrder = 2 + ExplicitTop = 137 + ExplicitHeight = 463 object Tv1: TcxGridDBTableView Navigator.Buttons.CustomButtons = <> ScrollbarAnnotations.CustomAnnotations = <> diff --git a/E04梭织坯布仓库/U_TatClothRKHZList.pas b/E04梭织坯布仓库/U_TatClothRKHZList.pas index 4559b9d..53379e5 100644 --- a/E04梭织坯布仓库/U_TatClothRKHZList.pas +++ b/E04梭织坯布仓库/U_TatClothRKHZList.pas @@ -50,6 +50,7 @@ type Tv1Column1: TcxGridDBColumn; Tv1carno: TcxGridDBColumn; Tv1StkNetWeight: TcxGridDBColumn; + cxTabControl1: TcxTabControl; procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure FormCreate(Sender: TObject); procedure TBRafreshClick(Sender: TObject); @@ -63,7 +64,7 @@ type procedure TCBNORChange(Sender: TObject); procedure JYTypeChange(Sender: TObject); procedure ToolButton2Click(Sender: TObject); - procedure cxPageControl1Change(Sender: TObject); + procedure cxTabControl1Change(Sender: TObject); procedure CDS_1BeforeOpen(DataSet: TDataSet); procedure Tv1DataControllerFilterBeforeChange(Sender: TcxDBDataFilterCriteria; ADataSet: TDataSet; const AFilterText: string); @@ -134,12 +135,25 @@ begin Close; sql.Clear; - sql.Add('select C_NAME,carno,COUNT(*)JS,SUM(Meter)stkMeter,SUM(Yardage)StkYardage,SUM(NetWeight)StkNetWeight from V_Tat_Cloth_IO A where A.IOFlag = ''Èë¿â'' ' + WSql); - sql.Add('group by C_NAME,carno'); + if cxTabControl1.TabIndex = 0 then + begin + sql.Add('select C_NAME,carno,COUNT(*)JS,SUM(Meter)stkMeter,SUM(Yardage)StkYardage,SUM(NetWeight)StkNetWeight'); + sql.Add(' from V_Tat_Cloth_IO A where A.IOFlag = ''Èë¿â'' ' + WSql); + sql.Add(' group by C_NAME,carno order by C_NAME,carno'); + end + else + begin + sql.Add('select C_NAME,COUNT(*)JS,SUM(Meter)stkMeter,SUM(NetWeight)StkNetWeight'); + sql.Add(' from V_Tat_Cloth_IO A where A.IOFlag = ''Èë¿â'' ' + WSql); + sql.Add(' group by C_NAME order by C_NAME'); + end; // showmessage(sql.text); Open; end; + v1Column22.Visible := cxTabControl1.TabIndex = 0; + Tv1carno.Visible := cxTabControl1.TabIndex = 0; + Tv1Column1.Visible := cxTabControl1.TabIndex = 0; SCreateCDS(ADOQueryMain, CDS_1); SInitCDSData(ADOQueryMain, CDS_1); @@ -176,10 +190,10 @@ begin end; end; -procedure TfrmTatClothRKHZList.cxPageControl1Change(Sender: TObject); +procedure TfrmTatClothRKHZList.cxTabControl1Change(Sender: TObject); begin + inherited; CurrentPage := 1; - SetStatus(); InitGrid(); end; diff --git a/E04梭织坯布仓库/U_TatDRList.dfm b/E04梭织坯布仓库/U_TatDRList.dfm index debdcbe..b15c209 100644 --- a/E04梭织坯布仓库/U_TatDRList.dfm +++ b/E04梭织坯布仓库/U_TatDRList.dfm @@ -605,6 +605,18 @@ inherited frmTatDRList: TfrmTatDRList Options.Editing = False Width = 90 end + object TV2UnitPrice: TcxGridDBColumn + Caption = #21333#20215 + DataBinding.FieldName = 'unit_price' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxCurrencyEditProperties' + Properties.AssignedValues.DisplayFormat = True + Properties.DisplayFormat = '0.00' + Properties.UseThousandSeparator = False + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 70 + end object TV2Column1: TcxGridDBColumn Caption = #25968#37327#21333#20301 DataBinding.FieldName = 'QtyUnit' diff --git a/E04梭织坯布仓库/U_TatDRList.pas b/E04梭织坯布仓库/U_TatDRList.pas index c5e02bd..48539bd 100644 --- a/E04梭织坯布仓库/U_TatDRList.pas +++ b/E04梭织坯布仓库/U_TatDRList.pas @@ -10,7 +10,7 @@ uses cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView, cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter, RM_Dataset, RM_System, RM_Common, RM_Class, RM_GridReport, RM_e_Xls, Menus, cxPC, cxButtonEdit, - cxDropDownEdit, cxTextEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, + cxDropDownEdit, cxCurrencyEdit, cxTextEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxBarBuiltInMenu, dxSkinsCore, dxSkinsDefaultPainters, U_BaseList, dxDateRanges, dxScrollbarAnnotations, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, IdHTTP, dxSkinWXI; @@ -89,6 +89,7 @@ type IdHTTP1: TIdHTTP; TV2DR_LongitudeBatchNo: TcxGridDBColumn; TV2DR_LatitudeBatchNo: TcxGridDBColumn; + TV2UnitPrice: TcxGridDBColumn; //RMllPDFExport1: TRMllPDFExport; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); diff --git a/E04梭织坯布仓库/U_TatDRtInPut.dfm b/E04梭织坯布仓库/U_TatDRtInPut.dfm index aba587a..21b7ba2 100644 --- a/E04梭织坯布仓库/U_TatDRtInPut.dfm +++ b/E04梭织坯布仓库/U_TatDRtInPut.dfm @@ -376,6 +376,17 @@ object frmTatDRtInPut: TfrmTatDRtInPut HeaderAlignmentHorz = taCenter Width = 90 end + object Tv1UnitPrice: TcxGridDBColumn + Caption = #21333#20215 + DataBinding.FieldName = 'unit_price' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxCurrencyEditProperties' + Properties.AssignedValues.DisplayFormat = True + Properties.DisplayFormat = '0.00' + Properties.UseThousandSeparator = False + HeaderAlignmentHorz = taCenter + Width = 70 + end object Tv1Column3: TcxGridDBColumn Caption = #35745#21010#21333#21495 DataBinding.FieldName = 'orderno' diff --git a/E04梭织坯布仓库/U_TatDRtInPut.pas b/E04梭织坯布仓库/U_TatDRtInPut.pas index eb34d7e..ae38e18 100644 --- a/E04梭织坯布仓库/U_TatDRtInPut.pas +++ b/E04梭织坯布仓库/U_TatDRtInPut.pas @@ -9,7 +9,7 @@ uses cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid, cxMemo, cxRichEdit, ComCtrls, cxContainer, cxTextEdit, cxMaskEdit, cxButtonEdit, StdCtrls, ToolWin, DBClient, ADODB, ExtCtrls, BtnEdit, cxCalendar, StrUtils, - cxDropDownEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels, + cxDropDownEdit, cxCurrencyEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges, dxBarBuiltInMenu, U_BaseList, dxSkinWXI, dxScrollbarAnnotations; @@ -58,6 +58,7 @@ type Tv1C_code: TcxGridDBColumn; Tv1DR_LongitudeBatchNo: TcxGridDBColumn; Tv1DR_LatitudeBatchNo: TcxGridDBColumn; + Tv1UnitPrice: TcxGridDBColumn; ToolButton7: TToolButton; procedure TBCloseClick(Sender: TObject); procedure FormShow(Sender: TObject);