From ca0be7bcfebfe72f348aff6d9745cebe4bdf0374 Mon Sep 17 00:00:00 2001 From: "DESKTOP-E401PHE\\Administrator" Date: Mon, 8 Sep 2025 10:53:41 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=B8=E5=A4=9A=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- A00通用窗体/U_UserSel.dfm | 24 +- A00通用窗体/U_UserSel.pas | 80 +- A01基础公司管理/Company.dpr | 3 +- A01基础公司管理/Company.dproj | 4 + A01基础公司管理/Company.skincfg | 118 +- A01基础公司管理/U_CustInput.dfm | 40 +- A01基础公司管理/U_CustInput.pas | 15 +- A01基础公司管理/U_Customer.dfm | 411 +++-- A01基础公司管理/U_Customer.pas | 126 +- A01基础公司管理/U_EmployeeList.dfm | 6 +- A01基础公司管理/U_GetDllForm.pas | 14 +- A01基础公司管理/U_LargeScreenDisplay.dfm | 465 ++++++ A01基础公司管理/U_LargeScreenDisplay.pas | 211 +++ A01基础公司管理/U_SelectStore.dfm | 42 + A01基础公司管理/U_SelectStore.pas | 40 + A02基础产品管理/ClothInfo.skincfg | 2 +- A02基础产品管理/U_ClothInfo.dfm | 10 + A02基础产品管理/U_ClothInfo.pas | 42 +- A02基础产品管理/U_ClothInfoInput.pas | 76 +- A09财务通用管理/Financial.skincfg | 116 +- A09财务通用管理/U_FinTradePlanSel.dfm | 1 + .../U_FinTradeSalesContractSel.dfm | 4 +- A09财务通用管理/U_ReceivableInput.dfm | 544 +++---- A09财务通用管理/U_ReceivableInput.pas | 350 +++-- T01贸易生产计划/TradePlan.skincfg | 4 +- T01贸易生产计划/U_TradePlanInPut.dfm | 1350 ++++++++++++++--- T01贸易生产计划/U_TradePlanInPut.pas | 95 ++ T01贸易生产计划/U_TradePlanList.pas | 18 +- T02贸易汇总仓库/U_ItemizedListInPut.dfm | 7 +- T02贸易汇总仓库/U_ItemizedListList.dfm | 4 +- T03贸易布匹检验/U_MachRollMain.dfm | 36 +- T03贸易布匹检验/U_MachRollMain.pas | 2 +- T05贸易门市管理/TradeMarket.dpr | 5 +- T05贸易门市管理/TradeMarket.dproj | 6 + T05贸易门市管理/TradeMarket.skincfg | 4 +- T05贸易门市管理/U_GetDllForm.pas | 3 +- T05贸易门市管理/U_TradeMarketInPut.dfm | 107 +- T05贸易门市管理/U_TradeMarketInPut.pas | 168 +- T05贸易门市管理/U_TradeMarketList.dfm | 55 +- T05贸易门市管理/U_TradeMarketList.pas | 311 ++-- T05贸易门市管理/U_TradeMarketQtyInPut.dfm | 261 ++++ T05贸易门市管理/U_TradeMarketQtyInPut.pas | 348 +++++ 42 files changed, 4245 insertions(+), 1283 deletions(-) create mode 100644 A01基础公司管理/U_LargeScreenDisplay.dfm create mode 100644 A01基础公司管理/U_LargeScreenDisplay.pas create mode 100644 A01基础公司管理/U_SelectStore.dfm create mode 100644 A01基础公司管理/U_SelectStore.pas create mode 100644 T05贸易门市管理/U_TradeMarketQtyInPut.dfm create mode 100644 T05贸易门市管理/U_TradeMarketQtyInPut.pas diff --git a/A00通用窗体/U_UserSel.dfm b/A00通用窗体/U_UserSel.dfm index 37f21dc..9994c55 100644 --- a/A00通用窗体/U_UserSel.dfm +++ b/A00通用窗体/U_UserSel.dfm @@ -10,8 +10,8 @@ inherited frmUserSel: TfrmUserSel Font.Name = #24494#36719#38597#40657 Position = poMainFormCenter OnClose = FormClose - ExplicitWidth = 612 - ExplicitHeight = 553 + ExplicitWidth = 620 + ExplicitHeight = 561 PixelsPerInch = 96 TextHeight = 21 object ToolBar1: TToolBar [0] @@ -38,13 +38,13 @@ inherited frmUserSel: TfrmUserSel ImageIndex = 1 OnClick = TBRafreshClick end - object ToolButton2: TToolButton + object TBFind: TToolButton Left = 71 Top = 0 AutoSize = True Caption = #36807#28388 ImageIndex = 0 - OnClick = ToolButton2Click + OnClick = TBFindClick end object btnOK: TToolButton Left = 142 @@ -87,22 +87,24 @@ inherited frmUserSel: TfrmUserSel Height = 21 Caption = #32534#21495 end - object UserName: TcxTextEdit + object EEName: TcxTextEdit Tag = 2 Left = 218 Top = 5 ParentFont = False - Properties.OnChange = UserIDPropertiesChange + Properties.OnChange = EENamePropertiesChange TabOrder = 1 + OnKeyPress = EENameKeyPress Width = 120 end - object UserID: TcxTextEdit + object EECode: TcxTextEdit Tag = 2 Left = 58 Top = 5 ParentFont = False - Properties.OnChange = UserIDPropertiesChange + Properties.OnChange = EENamePropertiesChange TabOrder = 0 + OnKeyPress = EENameKeyPress Width = 120 end end @@ -138,7 +140,7 @@ inherited frmUserSel: TfrmUserSel end object v2Column1: TcxGridDBColumn Caption = #32534#21495 - DataBinding.FieldName = 'UserID' + DataBinding.FieldName = 'EECode' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False @@ -146,7 +148,7 @@ inherited frmUserSel: TfrmUserSel end object v2Column2: TcxGridDBColumn Caption = #21517#31216 - DataBinding.FieldName = 'UserName' + DataBinding.FieldName = 'EEName' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False @@ -154,7 +156,7 @@ inherited frmUserSel: TfrmUserSel end object v2Column3: TcxGridDBColumn Caption = #37096#38376 - DataBinding.FieldName = 'Udept' + DataBinding.FieldName = 'Dept' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False diff --git a/A00通用窗体/U_UserSel.pas b/A00通用窗体/U_UserSel.pas index 4f0e4a1..10380e3 100644 --- a/A00通用窗体/U_UserSel.pas +++ b/A00通用窗体/U_UserSel.pas @@ -13,9 +13,8 @@ uses RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit, cxTextEdit, cxDBLookupComboBox, ComObj, cxLookAndFeels, cxLookAndFeelPainters, - cxNavigator, dxDateRanges, U_BaseHelp, - dxBarBuiltInMenu, System.ImageList, Vcl.ImgList, - dxScrollbarAnnotations, cxImageList, cxContainer, dxSkinsCore, + cxNavigator, dxDateRanges, U_BaseHelp, dxBarBuiltInMenu, System.ImageList, + Vcl.ImgList, dxScrollbarAnnotations, cxImageList, cxContainer, dxSkinsCore, dxSkinsDefaultPainters; type @@ -32,10 +31,10 @@ type ADOQueryTemp: TADOQuery; ADOQueryCmd: TADOQuery; Panel1: TPanel; - ToolButton2: TToolButton; + TBFind: TToolButton; ADOQueryMain: TADOQuery; Label3: TLabel; - UserName: TcxTextEdit; + EEName: TcxTextEdit; cxGrid1: TcxGrid; Tv1: TcxGridDBTableView; cxGridLevel1: TcxGridLevel; @@ -43,7 +42,7 @@ type DS_1: TDataSource; CDS_1: TClientDataSet; Label1: TLabel; - UserID: TcxTextEdit; + EECode: TcxTextEdit; btnOK: TToolButton; v2Column1: TcxGridDBColumn; v2Column2: TcxGridDBColumn; @@ -57,18 +56,19 @@ type procedure TBCloseClick(Sender: TObject); procedure FormShow(Sender: TObject); procedure TBRafreshClick(Sender: TObject); - procedure ToolButton2Click(Sender: TObject); + procedure TBFindClick(Sender: TObject); procedure btnOKClick(Sender: TObject); procedure FormCreate(Sender: TObject); procedure Tv1DblClick(Sender: TObject); - procedure UserIDPropertiesChange(Sender: TObject); + procedure EENamePropertiesChange(Sender: TObject); + procedure EENameKeyPress(Sender: TObject; var Key: Char); private { Private declarations } procedure InitGrid(); procedure CheckGrid(); public - Fdept: string; + Fdept, FPost: string; FMultiple: Boolean; FRTUserID, FRTUserName: string; end; @@ -99,7 +99,7 @@ begin First; while not eof do begin - if FStrs.IndexOf(Trim(FieldByName('UserID').AsString)) >= 0 then + if FStrs.IndexOf(Trim(FieldByName('EECode').AsString)) >= 0 then begin Edit; FieldByName('SSel').Value := true; @@ -121,11 +121,18 @@ begin Filtered := False; Close; SQL.Clear; - sql.Add(' select * from SY_User where 1=1 '); +// sql.Add(' select * from SY_User where 1=1 '); + sql.Add(' select * from SY_Employee where 1=1 '); + if Trim(FPost) <> '' then + begin +// sql.Add('and Udept=' + QuotedStr(Trim(Fdept))); + sql.Add('and Post=' + QuotedStr(Trim(FPost))); + end; if Trim(Fdept) <> '' then begin - sql.Add('and Udept=' + QuotedStr(Trim(Fdept))); + sql.Add('and dept=' + QuotedStr(Trim(Fdept))); + end; Open; end; @@ -177,16 +184,16 @@ procedure TfrmUserSel.FormShow(Sender: TObject); begin inherited; ReadCxGrid(trim(self.Caption), Tv1, '˻ѡ'); - if FMultiple then - begin - VC_SSel.Visible := True; - VC_SSel.Hidden := False; - end - else - begin - VC_SSel.Visible := False; - VC_SSel.Hidden := True; - end; +// if FMultiple then +// begin +// VC_SSel.Visible := True; +// VC_SSel.Hidden := False; +// end +// else +// begin +// VC_SSel.Visible := False; +// VC_SSel.Hidden := True; +// end; InitGrid(); end; @@ -195,7 +202,7 @@ begin InitGrid(); end; -procedure TfrmUserSel.ToolButton2Click(Sender: TObject); +procedure TfrmUserSel.TBFindClick(Sender: TObject); begin if ADOQueryMain.Active then begin @@ -210,24 +217,33 @@ begin btnOK.Click; end; -procedure TfrmUserSel.UserIDPropertiesChange(Sender: TObject); +procedure TfrmUserSel.EENamePropertiesChange(Sender: TObject); begin - ToolButton2.Click; + TBFind.Click; +end; + +procedure TfrmUserSel.EENameKeyPress(Sender: TObject; var Key: Char); +begin + if Key = #13 then + begin + InitGrid(); + end; + end; procedure TfrmUserSel.btnOKClick(Sender: TObject); var RTValues: TArray; begin - if FMultiple then +// if FMultiple then +// begin + if not CDS_1.Locate('SSel', true, []) then begin - if not CDS_1.Locate('SSel', true, []) then - begin - Application.MessageBox('ѡ!', 'ʾ', 0); - Exit; - end; + Application.MessageBox('ѡ!', 'ʾ', 0); + Exit; end; - RTValues := SelCDSKey(CDS_1, ['UserID', 'UserName']); +// end; + RTValues := SelCDSKey(CDS_1, ['EECode', 'EEName']); FRTUserID := RTValues[0]; FRTUserName := RTValues[1]; ModalResult := 1; diff --git a/A01基础公司管理/Company.dpr b/A01基础公司管理/Company.dpr index 0f7439d..1d12c42 100644 --- a/A01基础公司管理/Company.dpr +++ b/A01基础公司管理/Company.dpr @@ -43,7 +43,8 @@ uses FramePagingSel in '..\A00ͨ\FramePagingSel.pas' {frmFramePagingSel: TFrame}, U_VehicleSel in '..\A00ͨô\U_VehicleSel.pas' {frmVehicleSel}, uSZHN_JSON in '..\..\..\public10\ThreeFun\Fun\uSZHN_JSON.pas', - U_UserSel in '..\A00ͨô\U_UserSel.pas' {frmUserSel}; + U_UserSel in '..\A00ͨô\U_UserSel.pas' {frmUserSel}, + U_SelectStore in 'U_SelectStore.pas' {frmSelectStore}; {$R *.res} procedure DllEnterPoint(dwReason: DWORD); far; stdcall; diff --git a/A01基础公司管理/Company.dproj b/A01基础公司管理/Company.dproj index d0c7464..cf264f1 100644 --- a/A01基础公司管理/Company.dproj +++ b/A01基础公司管理/Company.dproj @@ -248,6 +248,10 @@
frmUserSel
dfm + +
frmSelectStore
+ dfm +
Cfg_2 Base diff --git a/A01基础公司管理/Company.skincfg b/A01基础公司管理/Company.skincfg index 97161c0..40f4d64 100644 --- a/A01基础公司管理/Company.skincfg +++ b/A01基础公司管理/Company.skincfg @@ -1,62 +1,62 @@ [ExpressSkins] -Default=0 +Default=1 ShowNotifications=1 -Enabled=1 +Enabled=0 dxSkinsDefaultPainters=1 -dxSkinBasic=1 -dxSkinBlack=1 -dxSkinBlue=1 -dxSkinBlueprint=1 -dxSkinCaramel=1 -dxSkinCoffee=1 -dxSkinDarkroom=1 -dxSkinDarkSide=1 -dxSkinDevExpressDarkStyle=1 -dxSkinDevExpressStyle=1 -dxSkinFoggy=1 -dxSkinGlassOceans=1 -dxSkinHighContrast=1 -dxSkiniMaginary=1 -dxSkinLilian=1 -dxSkinLiquidSky=1 -dxSkinLondonLiquidSky=1 -dxSkinMcSkin=1 -dxSkinMetropolis=1 -dxSkinMetropolisDark=1 -dxSkinMoneyTwins=1 -dxSkinOffice2007Black=1 -dxSkinOffice2007Blue=1 -dxSkinOffice2007Green=1 -dxSkinOffice2007Pink=1 -dxSkinOffice2007Silver=1 -dxSkinOffice2010Black=1 -dxSkinOffice2010Blue=1 -dxSkinOffice2010Silver=1 -dxSkinOffice2013DarkGray=1 -dxSkinOffice2013LightGray=1 -dxSkinOffice2013White=1 -dxSkinOffice2016Colorful=1 -dxSkinOffice2016Dark=1 -dxSkinOffice2019Black=1 -dxSkinOffice2019Colorful=1 -dxSkinOffice2019DarkGray=1 -dxSkinOffice2019White=1 -dxSkinPumpkin=1 -dxSkinSeven=1 -dxSkinSevenClassic=1 -dxSkinSharp=1 -dxSkinSharpPlus=1 -dxSkinSilver=1 -dxSkinSpringtime=1 -dxSkinStardust=1 -dxSkinSummer2008=1 -dxSkinTheAsphaltWorld=1 -dxSkinTheBezier=1 -dxSkinValentine=1 -dxSkinVisualStudio2013Blue=1 -dxSkinVisualStudio2013Dark=1 -dxSkinVisualStudio2013Light=1 -dxSkinVS2010=1 -dxSkinWhiteprint=1 -dxSkinWXI=1 -dxSkinXmas2008Blue=1 +dxSkinBasic=0 +dxSkinBlack=0 +dxSkinBlue=0 +dxSkinBlueprint=0 +dxSkinCaramel=0 +dxSkinCoffee=0 +dxSkinDarkroom=0 +dxSkinDarkSide=0 +dxSkinDevExpressDarkStyle=0 +dxSkinDevExpressStyle=0 +dxSkinFoggy=0 +dxSkinGlassOceans=0 +dxSkinHighContrast=0 +dxSkiniMaginary=0 +dxSkinLilian=0 +dxSkinLiquidSky=0 +dxSkinLondonLiquidSky=0 +dxSkinMcSkin=0 +dxSkinMetropolis=0 +dxSkinMetropolisDark=0 +dxSkinMoneyTwins=0 +dxSkinOffice2007Black=0 +dxSkinOffice2007Blue=0 +dxSkinOffice2007Green=0 +dxSkinOffice2007Pink=0 +dxSkinOffice2007Silver=0 +dxSkinOffice2010Black=0 +dxSkinOffice2010Blue=0 +dxSkinOffice2010Silver=0 +dxSkinOffice2013DarkGray=0 +dxSkinOffice2013LightGray=0 +dxSkinOffice2013White=0 +dxSkinOffice2016Colorful=0 +dxSkinOffice2016Dark=0 +dxSkinOffice2019Black=0 +dxSkinOffice2019Colorful=0 +dxSkinOffice2019DarkGray=0 +dxSkinOffice2019White=0 +dxSkinPumpkin=0 +dxSkinSeven=0 +dxSkinSevenClassic=0 +dxSkinSharp=0 +dxSkinSharpPlus=0 +dxSkinSilver=0 +dxSkinSpringtime=0 +dxSkinStardust=0 +dxSkinSummer2008=0 +dxSkinTheAsphaltWorld=0 +dxSkinTheBezier=0 +dxSkinValentine=0 +dxSkinVisualStudio2013Blue=0 +dxSkinVisualStudio2013Dark=0 +dxSkinVisualStudio2013Light=0 +dxSkinVS2010=0 +dxSkinWhiteprint=0 +dxSkinWXI=0 +dxSkinXmas2008Blue=0 diff --git a/A01基础公司管理/U_CustInput.dfm b/A01基础公司管理/U_CustInput.dfm index 6fac604..8cbbfbd 100644 --- a/A01基础公司管理/U_CustInput.dfm +++ b/A01基础公司管理/U_CustInput.dfm @@ -104,8 +104,8 @@ inherited frmCustInput: TfrmCustInput Visible = False end object Label8: TLabel - Left = 1277 - Top = 180 + Left = 1413 + Top = 181 Width = 32 Height = 21 Caption = #22269#23478 @@ -133,8 +133,8 @@ inherited frmCustInput: TfrmCustInput Caption = #21697#29260#21830 end object Label9: TLabel - Left = 1243 - Top = 196 + Left = 1241 + Top = 204 Width = 16 Height = 21 Caption = #27954 @@ -191,12 +191,26 @@ inherited frmCustInput: TfrmCustInput Caption = #38656#35201#30422#31456 end object Label16: TLabel - Left = 878 + Left = 909 Top = 164 Width = 32 Height = 21 Caption = #38376#24215 end + object Label17: TLabel + Left = 1182 + Top = 164 + Width = 32 + Height = 21 + Caption = #21547#31246 + end + object Label18: TLabel + Left = 1303 + Top = 164 + Width = 14 + Height = 21 + Caption = '%' + end object CoName: TcxTextEdit Tag = 2 Left = 86 @@ -238,8 +252,8 @@ inherited frmCustInput: TfrmCustInput end object cocountry: TcxButtonEdit Tag = 2 - Left = 1315 - Top = 173 + Left = 1469 + Top = 174 Hint = 'CoCountry/'#22269#23478 Properties.Buttons = < item @@ -415,8 +429,8 @@ inherited frmCustInput: TfrmCustInput end object Stores: TcxComboBox Tag = 2 - Left = 950 - Top = 160 + Left = 951 + Top = 164 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( #26684#32654 @@ -425,6 +439,14 @@ inherited frmCustInput: TfrmCustInput TabOrder = 17 Width = 200 end + object IncludeTax: TcxTextEdit + Tag = 2 + Left = 1228 + Top = 160 + TabOrder = 18 + Text = '0' + Width = 69 + end end object Panel1: TPanel [2] Left = 0 diff --git a/A01基础公司管理/U_CustInput.pas b/A01基础公司管理/U_CustInput.pas index 66879c7..17db882 100644 --- a/A01基础公司管理/U_CustInput.pas +++ b/A01基础公司管理/U_CustInput.pas @@ -110,6 +110,9 @@ type SealFlag: TcxComboBox; Label16: TLabel; Stores: TcxComboBox; + Label17: TLabel; + IncludeTax: TcxTextEdit; + Label18: TLabel; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure TBCloseClick(Sender: TObject); @@ -281,12 +284,13 @@ begin frmUserSel := TfrmUserSel.Create(Application); with frmUserSel do begin - Fdept := 'ҵ'; + Fdept := 'ҵ'; if ShowModal = 1 then begin - self.SalesId.Text := Trim(CDS_1.fieldbyname('UserID').AsString); - self.Saleser.Text := Trim(CDS_1.fieldbyname('UserName').AsString); + self.SalesId.Text := Trim(CDS_1.fieldbyname('EECode').AsString); + self.Saleser.Text := Trim(CDS_1.fieldbyname('EEName').AsString); + end; end; finally @@ -623,6 +627,11 @@ begin Application.MessageBox('ȫƲΪ!', 'ʾ', 0); Exit; end; + if Trim(Saleser.Text) = '' then + begin + Application.MessageBox('ҵԱΪ!', 'ʾ', 0); + Exit; + end; with CDS_LXR do begin diff --git a/A01基础公司管理/U_Customer.dfm b/A01基础公司管理/U_Customer.dfm index 99d8f1a..6485200 100644 --- a/A01基础公司管理/U_Customer.dfm +++ b/A01基础公司管理/U_Customer.dfm @@ -2,22 +2,22 @@ inherited frmCustomer: TfrmCustomer Left = 347 Top = 169 Caption = #23458#25143#36164#26009#31649#29702 - ClientHeight = 537 - ClientWidth = 1540 + ClientHeight = 737 + ClientWidth = 1589 Color = clBtnFace Font.Height = -16 FormStyle = fsMDIChild Position = poScreenCenter Visible = True - ExplicitWidth = 1556 - ExplicitHeight = 576 + ExplicitWidth = 1605 + ExplicitHeight = 776 PixelsPerInch = 96 TextHeight = 21 object ToolBar1: TToolBar [0] Tag = 1 Left = 0 Top = 0 - Width = 1540 + Width = 1589 Height = 30 AutoSize = True ButtonHeight = 30 @@ -30,7 +30,7 @@ inherited frmCustomer: TfrmCustomer List = True ParentColor = False ShowCaptions = True - TabOrder = 5 + TabOrder = 4 object TBRafresh: TToolButton Left = 0 Top = 0 @@ -139,14 +139,14 @@ inherited frmCustomer: TfrmCustomer object Panel1: TPanel [1] Left = 0 Top = 30 - Width = 1540 + Width = 1589 Height = 62 Align = alTop BevelInner = bvRaised BevelOuter = bvLowered ParentBackground = False ParentColor = True - TabOrder = 6 + TabOrder = 5 object Label3: TLabel Left = 182 Top = 20 @@ -228,14 +228,207 @@ inherited frmCustomer: TfrmCustomer Width = 120 end end - object cxGrid1: TcxGrid [2] + object Panel2: TPanel [2] + Left = 0 + Top = 534 + Width = 1589 + Height = 203 + Align = alBottom + Caption = 'Panel2' + TabOrder = 2 + object cxGrid2: TcxGrid + Left = 1 + Top = 1 + Width = 1020 + Height = 201 + Align = alClient + TabOrder = 0 + object Tv2: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + Navigator.Buttons.Delete.Enabled = False + Navigator.Buttons.Delete.Visible = False + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_2 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = < + item + Kind = skSum + end + item + Kind = skSum + end + item + Kind = skSum + end> + DataController.Summary.SummaryGroups = <> + OptionsBehavior.GoToNextCellOnEnter = True + OptionsCustomize.ColumnFiltering = False + OptionsData.Deleting = False + OptionsData.DeletingConfirmation = False + OptionsView.GroupByBox = False + object v3Column3: TcxGridDBColumn + Caption = #40664#35748 + DataBinding.FieldName = 'IsDefault' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxCheckBoxProperties' + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 76 + end + object Tv2Column2: TcxGridDBColumn + Caption = #22320#22336 + DataBinding.FieldName = 'mxaddress' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 111 + end + object Tv2Column3: TcxGridDBColumn + Caption = #21306#22495 + DataBinding.FieldName = 'mxarea' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 112 + end + object cxGridDBColumn1: TcxGridDBColumn + Caption = #32852#31995#20154 + DataBinding.FieldName = 'Contacts' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 70 + end + object cxGridDBColumn2: TcxGridDBColumn + Caption = #32844#20301 + DataBinding.FieldName = 'position' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.CharCase = ecUpperCase + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 70 + end + object cxGridDBColumn4: TcxGridDBColumn + Caption = #32852#31995#30005#35805 + DataBinding.FieldName = 'Telephone' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.CharCase = ecUpperCase + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 99 + end + object cxGridDBColumn5: TcxGridDBColumn + Caption = #25163#26426#21495 + DataBinding.FieldName = 'PhoneNumber' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.CharCase = ecUpperCase + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 102 + end + object Tv2Column1: TcxGridDBColumn + Caption = 'EMAIL' + DataBinding.FieldName = 'Email' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.CharCase = ecUpperCase + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 108 + end + object v3Column2: TcxGridDBColumn + Caption = #24494#20449#21495 + DataBinding.FieldName = 'WeChat' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 169 + end + end + object cxGridLevel2: TcxGridLevel + GridView = Tv2 + end + end + object cxGrid3: TcxGrid + Left = 1021 + Top = 1 + Width = 567 + Height = 201 + Align = alRight + TabOrder = 1 + object Tv3: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + Navigator.Buttons.Delete.Enabled = False + Navigator.Buttons.Delete.Visible = False + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_3 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = < + item + Kind = skSum + end + item + Kind = skSum + end + item + Kind = skSum + end> + DataController.Summary.SummaryGroups = <> + OptionsBehavior.GoToNextCellOnEnter = True + OptionsCustomize.ColumnFiltering = False + OptionsData.Deleting = False + OptionsData.DeletingConfirmation = False + OptionsView.GroupByBox = False + object cxGridDBColumn6: TcxGridDBColumn + Caption = #36134#25143 + DataBinding.FieldName = 'BankName' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 358 + end + end + object cxGridLevel3: TcxGridLevel + GridView = Tv3 + end + end + end + object cxTabControl1: TcxTabControl [3] + Left = 0 + Top = 92 + Width = 1589 + Height = 28 + Align = alTop + TabOrder = 3 + Properties.CustomButtons.Buttons = <> + Properties.Style = 9 + Properties.TabIndex = 0 + Properties.Tabs.Strings = ( + #26410#23457#26680 + #24050#23457#26680 + #20840#37096) + LookAndFeel.Kind = lfUltraFlat + OnChange = cxTabControl1Change + ClientRectRight = 0 + ClientRectTop = 0 + end + inherited cxProgressBar2: TcxProgressBar + Left = 363 + Top = 227 + ExplicitLeft = 363 + ExplicitTop = 227 + ExplicitHeight = 29 + end + object cxGrid1: TcxGrid [6] Left = 0 Top = 120 - Width = 1540 - Height = 214 + Width = 1589 + Height = 414 Align = alClient PopupMenu = PopupMenu1 - TabOrder = 2 + TabOrder = 6 object Tv1: TcxGridDBTableView PopupMenu = PopupMenu1 Navigator.Buttons.CustomButtons = <> @@ -419,199 +612,6 @@ inherited frmCustomer: TfrmCustomer GridView = Tv1 end end - object Panel2: TPanel [3] - Left = 0 - Top = 334 - Width = 1540 - Height = 203 - Align = alBottom - Caption = 'Panel2' - TabOrder = 3 - object cxGrid2: TcxGrid - Left = 1 - Top = 1 - Width = 971 - Height = 201 - Align = alClient - TabOrder = 0 - object Tv2: TcxGridDBTableView - Navigator.Buttons.CustomButtons = <> - Navigator.Buttons.Delete.Enabled = False - Navigator.Buttons.Delete.Visible = False - ScrollbarAnnotations.CustomAnnotations = <> - DataController.DataSource = DS_2 - DataController.Summary.DefaultGroupSummaryItems = <> - DataController.Summary.FooterSummaryItems = < - item - Kind = skSum - end - item - Kind = skSum - end - item - Kind = skSum - end> - DataController.Summary.SummaryGroups = <> - OptionsBehavior.GoToNextCellOnEnter = True - OptionsCustomize.ColumnFiltering = False - OptionsData.Deleting = False - OptionsData.DeletingConfirmation = False - OptionsView.GroupByBox = False - object v3Column3: TcxGridDBColumn - Caption = #40664#35748 - DataBinding.FieldName = 'IsDefault' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxCheckBoxProperties' - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 76 - end - object Tv2Column2: TcxGridDBColumn - Caption = #22320#22336 - DataBinding.FieldName = 'mxaddress' - DataBinding.IsNullValueType = True - HeaderAlignmentHorz = taCenter - Width = 111 - end - object Tv2Column3: TcxGridDBColumn - Caption = #21306#22495 - DataBinding.FieldName = 'mxarea' - DataBinding.IsNullValueType = True - HeaderAlignmentHorz = taCenter - Width = 112 - end - object cxGridDBColumn1: TcxGridDBColumn - Caption = #32852#31995#20154 - DataBinding.FieldName = 'Contacts' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxTextEditProperties' - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 70 - end - object cxGridDBColumn2: TcxGridDBColumn - Caption = #32844#20301 - DataBinding.FieldName = 'position' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxTextEditProperties' - Properties.CharCase = ecUpperCase - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 70 - end - object cxGridDBColumn4: TcxGridDBColumn - Caption = #32852#31995#30005#35805 - DataBinding.FieldName = 'Telephone' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxTextEditProperties' - Properties.CharCase = ecUpperCase - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 99 - end - object cxGridDBColumn5: TcxGridDBColumn - Caption = #25163#26426#21495 - DataBinding.FieldName = 'PhoneNumber' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxTextEditProperties' - Properties.CharCase = ecUpperCase - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 102 - end - object Tv2Column1: TcxGridDBColumn - Caption = 'EMAIL' - DataBinding.FieldName = 'Email' - DataBinding.IsNullValueType = True - PropertiesClassName = 'TcxTextEditProperties' - Properties.CharCase = ecUpperCase - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 108 - end - object v3Column2: TcxGridDBColumn - Caption = #24494#20449#21495 - DataBinding.FieldName = 'WeChat' - DataBinding.IsNullValueType = True - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 169 - end - end - object cxGridLevel2: TcxGridLevel - GridView = Tv2 - end - end - object cxGrid3: TcxGrid - Left = 972 - Top = 1 - Width = 567 - Height = 201 - Align = alRight - TabOrder = 1 - object Tv3: TcxGridDBTableView - Navigator.Buttons.CustomButtons = <> - Navigator.Buttons.Delete.Enabled = False - Navigator.Buttons.Delete.Visible = False - ScrollbarAnnotations.CustomAnnotations = <> - DataController.DataSource = DS_3 - DataController.Summary.DefaultGroupSummaryItems = <> - DataController.Summary.FooterSummaryItems = < - item - Kind = skSum - end - item - Kind = skSum - end - item - Kind = skSum - end> - DataController.Summary.SummaryGroups = <> - OptionsBehavior.GoToNextCellOnEnter = True - OptionsCustomize.ColumnFiltering = False - OptionsData.Deleting = False - OptionsData.DeletingConfirmation = False - OptionsView.GroupByBox = False - object cxGridDBColumn6: TcxGridDBColumn - Caption = #36134#25143 - DataBinding.FieldName = 'BankName' - DataBinding.IsNullValueType = True - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 358 - end - end - object cxGridLevel3: TcxGridLevel - GridView = Tv3 - end - end - end - object cxTabControl1: TcxTabControl [4] - Left = 0 - Top = 92 - Width = 1540 - Height = 28 - Align = alTop - TabOrder = 4 - Properties.CustomButtons.Buttons = <> - Properties.Style = 9 - Properties.TabIndex = 0 - Properties.Tabs.Strings = ( - #26410#23457#26680 - #24050#23457#26680 - #20840#37096) - LookAndFeel.Kind = lfUltraFlat - OnChange = cxTabControl1Change - ClientRectRight = 0 - ClientRectTop = 0 - end - inherited cxProgressBar2: TcxProgressBar - Left = 363 - Top = 227 - ExplicitLeft = 363 - ExplicitTop = 227 - ExplicitHeight = 29 - end inherited ADOQueryBaseCmd: TADOQuery Connection = DataLink_Company.ADOLink Left = 297 @@ -643,7 +643,6 @@ inherited frmCustomer: TfrmCustomer Top = 187 end object GPM_1: TcxGridPopupMenu - Grid = cxGrid1 PopupMenus = <> Left = 180 Top = 216 diff --git a/A01基础公司管理/U_Customer.pas b/A01基础公司管理/U_Customer.pas index 800321b..a12fe94 100644 --- a/A01基础公司管理/U_Customer.pas +++ b/A01基础公司管理/U_Customer.pas @@ -17,24 +17,7 @@ uses FireDAC.Stan.Intf, FireDAC.Stan.Option, FireDAC.Stan.Param, FireDAC.Stan.Error, FireDAC.DatS, FireDAC.Phys.Intf, FireDAC.DApt.Intf, FireDAC.Stan.Async, FireDAC.DApt, FireDAC.Comp.DataSet, FireDAC.Comp.Client, cxContainer, - dxScrollbarAnnotations, Vcl.Menus, dxSkinsCore, dxSkinsDefaultPainters, - cxProgressBar, dxSkinOffice2013White, dxSkinSharpPlus, dxSkinWXI, dxSkinBasic, - dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, - dxSkinDarkroom, dxSkinDarkSide, dxSkinDevExpressDarkStyle, - dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, - dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, - dxSkinMcSkin, dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins, - dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green, - dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black, - dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, - dxSkinOffice2013LightGray, dxSkinOffice2016Colorful, dxSkinOffice2016Dark, - dxSkinOffice2019Black, dxSkinOffice2019Colorful, dxSkinOffice2019DarkGray, - dxSkinOffice2019White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic, - dxSkinSharp, dxSkinSilver, dxSkinSpringtime, dxSkinStardust, dxSkinSummer2008, - dxSkinTheAsphaltWorld, dxSkinTheBezier, dxSkinValentine, - dxSkinVisualStudio2013Blue, dxSkinVisualStudio2013Dark, - dxSkinVisualStudio2013Light, dxSkinVS2010, dxSkinWhiteprint, - dxSkinXmas2008Blue; + dxScrollbarAnnotations, Vcl.Menus, cxProgressBar; type TfrmCustomer = class(TfrmBaseList) @@ -48,33 +31,21 @@ type ADOQueryMain: TADOQuery; Label3: TLabel; CoName: TcxTextEdit; - cxGrid1: TcxGrid; - Tv1: TcxGridDBTableView; - cxGridLevel1: TcxGridLevel; GPM_1: TcxGridPopupMenu; DS_1: TDataSource; CDS_1: TClientDataSet; btnAdd: TToolButton; - v2Column6: TcxGridDBColumn; - v2Column1: TcxGridDBColumn; - v2Column2: TcxGridDBColumn; - v2Column7: TcxGridDBColumn; Label1: TLabel; CoCode: TcxTextEdit; - v2Column10: TcxGridDBColumn; btnEdit: TToolButton; Label2: TLabel; Saleser: TcxTextEdit; area: TcxTextEdit; Label4: TLabel; - v2Column15: TcxGridDBColumn; CDS_2: TClientDataSet; DS_2: TDataSource; btnSaleser: TToolButton; OpenDialog1: TOpenDialog; - Tv1Column3: TcxGridDBColumn; - Tv1Column4: TcxGridDBColumn; - Tv1Column2: TcxGridDBColumn; Panel2: TPanel; cxGrid2: TcxGrid; Tv2: TcxGridDBTableView; @@ -90,22 +61,15 @@ type btnChk: TToolButton; btnReChk: TToolButton; btnTallyer: TToolButton; - Tv1Column5: TcxGridDBColumn; - Tv1Column6: TcxGridDBColumn; ToolButton1: TToolButton; GPM_2: TcxGridPopupMenu; ToolButton3: TToolButton; - Tv1Column7: TcxGridDBColumn; - Tv1Column1: TcxGridDBColumn; ToolButton2: TToolButton; - Tv1Column8: TcxGridDBColumn; - Tv1Column10: TcxGridDBColumn; Label5: TLabel; CoAbbrName: TcxTextEdit; PopupMenu1: TPopupMenu; N1: TMenuItem; N2: TMenuItem; - Tv1Column11: TcxGridDBColumn; DS_3: TDataSource; CDS_3: TClientDataSet; cxGrid3: TcxGrid; @@ -114,10 +78,29 @@ type cxGridLevel3: TcxGridLevel; Tv2Column2: TcxGridDBColumn; Tv2Column3: TcxGridDBColumn; + SetupStore: TToolButton; + cxGrid1: TcxGrid; + Tv1: TcxGridDBTableView; + Tv1Column11: TcxGridDBColumn; + v2Column2: TcxGridDBColumn; + v2Column6: TcxGridDBColumn; + v2Column15: TcxGridDBColumn; + v2Column10: TcxGridDBColumn; + v2Column7: TcxGridDBColumn; + v2Column1: TcxGridDBColumn; + Tv1Column2: TcxGridDBColumn; + Tv1Column3: TcxGridDBColumn; + Tv1Column4: TcxGridDBColumn; + Tv1Column5: TcxGridDBColumn; + Tv1Column7: TcxGridDBColumn; + Tv1Column1: TcxGridDBColumn; + Tv1Column10: TcxGridDBColumn; + Tv1Column6: TcxGridDBColumn; + Tv1Column8: TcxGridDBColumn; Tv1Column9: TcxGridDBColumn; Tv1Column12: TcxGridDBColumn; Tv1Column13: TcxGridDBColumn; - SetupStore: TToolButton; + cxGridLevel1: TcxGridLevel; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure TBCloseClick(Sender: TObject); @@ -142,6 +125,7 @@ type procedure N1Click(Sender: TObject); procedure N2Click(Sender: TObject); procedure SetupStoreClick(Sender: TObject); + //procedure btnStoreOKClick(Sender: TObject); private fFlileFlag: string; { Private declarations } @@ -159,7 +143,7 @@ implementation uses U_DataLink, U_RTFun, U_ZDYHelp, U_CustomerInput, U_CustInput, U_UserSel, - U_AttachmentUpload, U_CustImport; + U_AttachmentUpload, U_CustImport, U_SelectStore; {$R *.dfm} procedure TfrmCustomer.SetStatus(); @@ -218,7 +202,7 @@ begin end; if Trim(canshu4) = '' then begin - SetupStore.Visible:=False; + SetupStore.Visible := False; end; end; @@ -528,6 +512,8 @@ end; procedure TfrmCustomer.SetupStoreClick(Sender: TObject); var RTValues: TArray; + StoreName: string; + frmSelectStore: TfrmSelectStore; begin if CDS_1.IsEmpty then exit; @@ -537,20 +523,27 @@ begin Application.MessageBox('ѡ!', 'ʾ', 0); Exit; end; + frmSelectStore := TfrmSelectStore.Create(nil); try - with ADOQueryCmd do + if frmSelectStore.ShowModal = mrOk then begin - close; - sql.Clear; - sql.Add('update BS_Company SET Stores='''' '); - sql.Add('where EXISTS(select X.RTValue from [dbo].[F_Tool_SplitString](' + QuotedStr(RTValues[0]) + ','','') X where BS_Company.CoID=X.RTValue ) '); - execsql; + StoreName := frmSelectStore.SelectedStore; + if StoreName = '' then + Exit; + + ADOQueryCmd.Close; + ADOQueryCmd.SQL.Text := 'UPDATE BS_Company SET Stores = :StoreName ' + 'WHERE EXISTS(SELECT X.RTValue ' + ' FROM [dbo].[F_Tool_SplitString](:COIDList,'','') X ' + ' WHERE BS_Company.CoID = X.RTValue)'; + ADOQueryCmd.Parameters.ParamByName('StoreName').Value := StoreName; + ADOQueryCmd.Parameters.ParamByName('COIDList').Value := RTValues[0]; + ADOQueryCmd.ExecSQL; + + Application.MessageBox('ŵɹ', 'ʾ'); + TBRafresh.Click; end; - application.MessageBox('ŵɹ', 'ʾϢ'); - TBRafresh.Click; - except - application.MessageBox('ŵʧܣ', 'ʾϢ', 0); + finally + frmSelectStore.Free; end; + end; procedure TfrmCustomer.btnAddClick(Sender: TObject); @@ -620,11 +613,12 @@ begin frmUserSel := TfrmUserSel.Create(Application); with frmUserSel do begin - Fdept := 'ҵ'; + //Fdept := 'ҵ'; + FPost := 'ҵԱ'; if ShowModal = 1 then begin - MSalesId := Trim(CDS_1.fieldbyname('UserID').AsString); - MSaleser := Trim(CDS_1.fieldbyname('UserName').AsString); + MSalesId := Trim(CDS_1.fieldbyname('EECode').AsString); + MSaleser := Trim(CDS_1.fieldbyname('EEName').AsString); end; end; finally @@ -647,6 +641,32 @@ begin initgrid(); end; +//procedure TfrmCustomer.btnStoreOKClick(Sender: TObject); +//var +// StoreName: string; +//begin +// StoreName := Trim(cbStore.Text); +// if StoreName = '' then +// Exit; +// +// try +// ADOQueryCmd.Close; +// ADOQueryCmd.SQL.Text := 'UPDATE BS_Company SET Stores = :StoreName ' + 'WHERE EXISTS(SELECT X.RTValue ' + ' FROM [dbo].[F_Tool_SplitString](:COIDList,'','') X ' + ' WHERE BS_Company.CoID = X.RTValue)'; +// ADOQueryCmd.Parameters.ParamByName('StoreName').Value := StoreName; +// ADOQueryCmd.Parameters.ParamByName('COIDList').Value := SelCDSKey(CDS_1, ['COID'])[0]; +// ADOQueryCmd.ExecSQL; +// +// Application.MessageBox('ŵɹ', 'ʾ'); +// TBRafresh.Click; +// except +// Application.MessageBox('ŵʧܣ', 'ʾ', 0); +// end; +// +// // ؿؼ +// cbStore.Visible := False; +// btnStoreOK.Visible := False; +//end; + procedure TfrmCustomer.FormCreate(Sender: TObject); begin inherited; diff --git a/A01基础公司管理/U_EmployeeList.dfm b/A01基础公司管理/U_EmployeeList.dfm index c3faa43..09d1a10 100644 --- a/A01基础公司管理/U_EmployeeList.dfm +++ b/A01基础公司管理/U_EmployeeList.dfm @@ -6,9 +6,8 @@ inherited frmEmployeeList: TfrmEmployeeList Font.Height = -16 FormStyle = fsMDIChild Visible = True - ExplicitLeft = -217 - ExplicitWidth = 1531 - ExplicitHeight = 540 + ExplicitWidth = 1539 + ExplicitHeight = 548 PixelsPerInch = 96 TextHeight = 21 object ToolBar1: TToolBar [0] @@ -340,7 +339,6 @@ inherited frmEmployeeList: TfrmEmployeeList Align = alClient PopupMenu = PopupMenu1 TabOrder = 1 - ExplicitLeft = 6 object Tv1: TcxGridDBTableView Navigator.Buttons.CustomButtons = <> ScrollbarAnnotations.CustomAnnotations = <> diff --git a/A01基础公司管理/U_GetDllForm.pas b/A01基础公司管理/U_GetDllForm.pas index 6dee0bb..a523f97 100644 --- a/A01基础公司管理/U_GetDllForm.pas +++ b/A01基础公司管理/U_GetDllForm.pas @@ -14,7 +14,7 @@ implementation uses U_DataLink, U_Customer, U_Factory, U_Company, U_EmployeeList, U_SYDept, - U_BankList, U_ModulePromptList; + U_BankList, U_ModulePromptList,U_LargeScreenDisplay; ///////////////////////////////////////////////////////////////// // ˵:ȡDllеô // @@ -80,7 +80,7 @@ begin Parameters1 := ''; // DCode := 'L01'; // DCode := 'L02'; - Parameters4 := ''; + //Parameters4 := ''; end else begin @@ -126,6 +126,16 @@ begin //ģ鴰 case FormID of + 123: //ʾ + begin + with TfrmLargeScreenDisplay.Create(Application.MainForm, Title, trim(Parameters1), trim(Parameters2), trim(Parameters3), trim(Parameters4), trim(Parameters5), trim(Parameters10), FormID, Title) do // + begin + fFormID := FormID; + WindowState := mstate; + mnewHandle := Handle; + end; + end; + 100: //ʾ begin with TfrmModulePromptList.Create(Application.MainForm, Title, trim(Parameters1), trim(Parameters2), trim(Parameters3), trim(Parameters4), trim(Parameters5), trim(Parameters10), FormID, Title) do // diff --git a/A01基础公司管理/U_LargeScreenDisplay.dfm b/A01基础公司管理/U_LargeScreenDisplay.dfm new file mode 100644 index 0000000..d76aee5 --- /dev/null +++ b/A01基础公司管理/U_LargeScreenDisplay.dfm @@ -0,0 +1,465 @@ +inherited frmLargeScreenDisplay: TfrmLargeScreenDisplay + Left = 297 + Top = 109 + Caption = #22823#23631#26174#31034 + ClientHeight = 1149 + ClientWidth = 1724 + Color = clBtnFace + Font.Height = -16 + FormStyle = fsMDIChild + KeyPreview = True + Visible = True + OnResize = FormResize + ExplicitWidth = 1740 + ExplicitHeight = 1188 + PixelsPerInch = 96 + TextHeight = 21 + inherited cxProgressBar2: TcxProgressBar + ExplicitHeight = 29 + end + object Panel1: TPanel [2] + Left = 0 + Top = 0 + Width = 1724 + Height = 1149 + Align = alClient + TabOrder = 2 + object Panel10: TPanel + Left = 1 + Top = 1 + Width = 792 + Height = 1147 + Align = alLeft + TabOrder = 0 + object Panel2: TPanel + Left = 1 + Top = 1 + Width = 790 + Height = 560 + Align = alClient + TabOrder = 0 + ExplicitHeight = 570 + object Panel6: TPanel + Left = 1 + Top = 1 + Width = 788 + Height = 41 + Align = alTop + Caption = 'M'#29287#23679#32447 + TabOrder = 0 + end + object cxGrid1: TcxGrid + Left = 1 + Top = 42 + Width = 788 + Height = 517 + Align = alClient + TabOrder = 1 + ExplicitLeft = 3 + ExplicitTop = 48 + ExplicitHeight = 527 + object TV1: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_1 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = <> + DataController.Summary.SummaryGroups = <> + OptionsView.GroupByBox = False + object TV1Column1: TcxGridDBColumn + Caption = #26159#21542#21152#24613 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column2: TcxGridDBColumn + Caption = #21333#25454#32534#21495 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column3: TcxGridDBColumn + Caption = #24320#21333#26085#26399 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column4: TcxGridDBColumn + Caption = #24320#21333#26102#38388 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column5: TcxGridDBColumn + Caption = #23458#25143#21517#31216 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column6: TcxGridDBColumn + Caption = #37197#36135#20154 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column7: TcxGridDBColumn + Caption = #19994#21153#21592 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV1Column8: TcxGridDBColumn + Caption = #22791#27880 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + end + object cxGrid1Level1: TcxGridLevel + GridView = TV1 + end + end + end + object Panel4: TPanel + Left = 1 + Top = 561 + Width = 790 + Height = 585 + Align = alBottom + TabOrder = 1 + object Panel8: TPanel + Left = 1 + Top = 1 + Width = 788 + Height = 41 + Align = alTop + Caption = #28201#23725#32447 + TabOrder = 0 + end + object cxGrid3: TcxGrid + Left = 1 + Top = 42 + Width = 788 + Height = 542 + Align = alClient + TabOrder = 1 + object TV3: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_3 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = <> + DataController.Summary.SummaryGroups = <> + OptionsView.GroupByBox = False + object TV3Column1: TcxGridDBColumn + Caption = #26159#21542#21152#24613 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column2: TcxGridDBColumn + Caption = #21333#25454#32534#21495 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column3: TcxGridDBColumn + Caption = #24320#21333#26085#26399 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column4: TcxGridDBColumn + Caption = #24320#21333#26102#38388 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column5: TcxGridDBColumn + Caption = #23458#25143#21517#31216 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column6: TcxGridDBColumn + Caption = #37197#36135#20154 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column7: TcxGridDBColumn + Caption = #19994#21153#21592 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV3Column8: TcxGridDBColumn + Caption = #22791#27880 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + end + object cxGridLevel2: TcxGridLevel + GridView = TV3 + end + end + end + end + object Panel11: TPanel + Left = 799 + Top = 1 + Width = 924 + Height = 1147 + Align = alRight + TabOrder = 1 + object Panel3: TPanel + Left = 1 + Top = 1 + Width = 922 + Height = 560 + Align = alClient + TabOrder = 0 + ExplicitHeight = 569 + object Panel7: TPanel + Left = 1 + Top = 1 + Width = 920 + Height = 41 + Align = alTop + Caption = 'D'#19996#22836#24037#19994#32447 + TabOrder = 0 + end + object cxGrid2: TcxGrid + Left = 1 + Top = 42 + Width = 920 + Height = 517 + Align = alClient + TabOrder = 1 + ExplicitHeight = 526 + object TV2: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_2 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = <> + DataController.Summary.SummaryGroups = <> + OptionsView.GroupByBox = False + object TV2Column1: TcxGridDBColumn + Caption = #26159#21542#21152#24613 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column2: TcxGridDBColumn + Caption = #21333#25454#32534#21495 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column3: TcxGridDBColumn + Caption = #24320#21333#26085#26399 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column4: TcxGridDBColumn + Caption = #24320#21333#26102#38388 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column5: TcxGridDBColumn + Caption = #23458#25143#21517#31216 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column6: TcxGridDBColumn + Caption = #37197#36135#20154 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column7: TcxGridDBColumn + Caption = #19994#21153#21592 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + object TV2Column8: TcxGridDBColumn + Caption = #22791#27880 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 80 + end + end + object cxGridLevel1: TcxGridLevel + GridView = TV2 + end + end + end + object Panel5: TPanel + Left = 1 + Top = 561 + Width = 922 + Height = 585 + Align = alBottom + TabOrder = 1 + object Panel9: TPanel + Left = 1 + Top = 1 + Width = 920 + Height = 42 + Align = alTop + Caption = #26410#22238#36710#26126#32454 + TabOrder = 0 + end + object cxGrid4: TcxGrid + Left = 1 + Top = 43 + Width = 920 + Height = 541 + Align = alClient + TabOrder = 1 + object TV4: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_4 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = <> + DataController.Summary.SummaryGroups = <> + OptionsView.GroupByBox = False + object TV4Column1: TcxGridDBColumn + Caption = #26159#21542#21152#24613 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column2: TcxGridDBColumn + Caption = #21333#25454#32534#21495 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column3: TcxGridDBColumn + Caption = #24320#21333#26085#26399 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column4: TcxGridDBColumn + Caption = #24320#21333#26102#38388 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column5: TcxGridDBColumn + Caption = #23458#25143#21517#31216 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column6: TcxGridDBColumn + Caption = #37197#36135#20154 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column7: TcxGridDBColumn + Caption = #19994#21153#21592 + DataBinding.IsNullValueType = True + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + object TV4Column8: TcxGridDBColumn + Caption = #22791#27880 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 80 + end + end + object cxGridLevel3: TcxGridLevel + GridView = TV4 + end + end + end + end + end + inherited ADOQueryBaseCmd: TADOQuery + Connection = DataLink_Company.ADOLink + Left = 233 + Top = 208 + end + inherited ADOQueryBaseTemp: TADOQuery + Connection = DataLink_Company.ADOLink + Left = 81 + Top = 209 + end + object ADOQueryTemp: TADOQuery + Connection = DataLink_Company.ADOLink + LockType = ltReadOnly + Parameters = <> + Left = 347 + Top = 385 + end + object ADOQueryCmd: TADOQuery + Connection = DataLink_Company.ADOLink + Parameters = <> + Left = 245 + Top = 385 + end + object ADOQueryMain: TADOQuery + Connection = DataLink_Company.ADOLink + LockType = ltReadOnly + Parameters = <> + Left = 149 + Top = 385 + end + object DS_1: TDataSource + DataSet = CDS_1 + Left = 467 + Top = 211 + end + object CDS_1: TClientDataSet + Aggregates = <> + Params = <> + Left = 360 + Top = 208 + end + object CDS_2: TClientDataSet + Aggregates = <> + Params = <> + Left = 400 + Top = 296 + end + object CDS_4: TClientDataSet + Aggregates = <> + Params = <> + Left = 544 + Top = 368 + end + object CDS_3: TClientDataSet + Aggregates = <> + Params = <> + Left = 432 + Top = 400 + end + object DS_2: TDataSource + DataSet = CDS_2 + Left = 563 + Top = 235 + end + object DS_3: TDataSource + DataSet = CDS_3 + Left = 619 + Top = 267 + end + object DS_4: TDataSource + DataSet = CDS_4 + Left = 675 + Top = 339 + end +end diff --git a/A01基础公司管理/U_LargeScreenDisplay.pas b/A01基础公司管理/U_LargeScreenDisplay.pas new file mode 100644 index 0000000..8f895dd --- /dev/null +++ b/A01基础公司管理/U_LargeScreenDisplay.pas @@ -0,0 +1,211 @@ +unit U_LargeScreenDisplay; + +interface + + +uses + Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, + Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB, + cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls, + cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient, + cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls, + cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid, + cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common, + RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection, + IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit, + cxTextEdit, cxPC, cxCheckComboBox, cxDropDownEdit, Menus, RM_e_Xls, + cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxDateRanges, + dxBarBuiltInMenu, U_BaseList, dxScrollbarAnnotations, cxContainer, dxSkinsCore, + dxSkinsDefaultPainters, cxProgressBar, dxSkinBasic, dxSkinBlack, dxSkinBlue, + dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkroom, dxSkinDarkSide, + dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy, + dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, + dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis, + dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black, + dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink, + dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue, + dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray, + dxSkinOffice2013White, dxSkinOffice2016Colorful, dxSkinOffice2016Dark, + dxSkinOffice2019Black, dxSkinOffice2019Colorful, dxSkinOffice2019DarkGray, + dxSkinOffice2019White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic, + dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringtime, dxSkinStardust, + dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinTheBezier, dxSkinValentine, + dxSkinVisualStudio2013Blue, dxSkinVisualStudio2013Dark, + dxSkinVisualStudio2013Light, dxSkinVS2010, dxSkinWhiteprint, dxSkinWXI, + dxSkinXmas2008Blue; + +type + TfrmLargeScreenDisplay = class(TfrmBaseList) + ADOQueryTemp: TADOQuery; + ADOQueryCmd: TADOQuery; + ADOQueryMain: TADOQuery; + DS_1: TDataSource; + CDS_1: TClientDataSet; + Panel1: TPanel; + Panel10: TPanel; + Panel2: TPanel; + Panel6: TPanel; + cxGrid1: TcxGrid; + TV1: TcxGridDBTableView; + TV1Column1: TcxGridDBColumn; + TV1Column2: TcxGridDBColumn; + TV1Column3: TcxGridDBColumn; + TV1Column4: TcxGridDBColumn; + TV1Column5: TcxGridDBColumn; + TV1Column6: TcxGridDBColumn; + TV1Column7: TcxGridDBColumn; + TV1Column8: TcxGridDBColumn; + cxGrid1Level1: TcxGridLevel; + Panel4: TPanel; + Panel8: TPanel; + cxGrid3: TcxGrid; + TV3: TcxGridDBTableView; + TV3Column1: TcxGridDBColumn; + TV3Column2: TcxGridDBColumn; + TV3Column3: TcxGridDBColumn; + TV3Column4: TcxGridDBColumn; + TV3Column5: TcxGridDBColumn; + TV3Column6: TcxGridDBColumn; + TV3Column7: TcxGridDBColumn; + TV3Column8: TcxGridDBColumn; + cxGridLevel2: TcxGridLevel; + Panel11: TPanel; + Panel3: TPanel; + Panel7: TPanel; + cxGrid2: TcxGrid; + TV2: TcxGridDBTableView; + TV2Column1: TcxGridDBColumn; + TV2Column2: TcxGridDBColumn; + TV2Column3: TcxGridDBColumn; + TV2Column4: TcxGridDBColumn; + TV2Column5: TcxGridDBColumn; + TV2Column6: TcxGridDBColumn; + TV2Column7: TcxGridDBColumn; + TV2Column8: TcxGridDBColumn; + cxGridLevel1: TcxGridLevel; + Panel5: TPanel; + Panel9: TPanel; + cxGrid4: TcxGrid; + TV4: TcxGridDBTableView; + TV4Column1: TcxGridDBColumn; + TV4Column2: TcxGridDBColumn; + TV4Column3: TcxGridDBColumn; + TV4Column4: TcxGridDBColumn; + TV4Column5: TcxGridDBColumn; + TV4Column6: TcxGridDBColumn; + TV4Column7: TcxGridDBColumn; + TV4Column8: TcxGridDBColumn; + cxGridLevel3: TcxGridLevel; + CDS_2: TClientDataSet; + CDS_4: TClientDataSet; + CDS_3: TClientDataSet; + DS_2: TDataSource; + DS_3: TDataSource; + DS_4: TDataSource; + procedure FormDestroy(Sender: TObject); + procedure FormClose(Sender: TObject; var Action: TCloseAction); + procedure TBCloseClick(Sender: TObject); + procedure FormShow(Sender: TObject); + procedure FormResize(Sender: TObject); + + + private + { Private declarations } + procedure InitGrid(); + public + fFlag: integer; + { Public declarations } + RKFlag, FCYID, fmanage: string; + end; + +var + frmLargeScreenDisplay: TfrmLargeScreenDisplay; + +implementation + +uses + U_DataLink, U_RTFun, U_ZDYHelp; + +{$R *.dfm} + +procedure TfrmLargeScreenDisplay.InitGrid(); +begin + try + ADOQueryMain.DisableControls; + with ADOQueryMain do + begin + Close; + SQL.Clear; + sql.Add(' select * from BS_Bank order by SerialNo '); + Open; + end; + SCreateCDS(ADOQueryMain, CDS_1); + SInitCDSData(ADOQueryMain, CDS_1); + finally + ADOQueryMain.EnableControls; + + end; +end; + +procedure TfrmLargeScreenDisplay.FormDestroy(Sender: TObject); +begin + inherited; + frmLargeScreenDisplay := nil; +end; + + +procedure TfrmLargeScreenDisplay.FormResize(Sender: TObject); +begin + inherited; + Panel10.Width := ClientWidth div 2; + Panel11.Width := ClientWidth div 2; + Panel2.Height := ClientHeight div 2; + Panel4.Height := ClientHeight div 2; + Panel3.Height := ClientHeight div 2; + Panel5.Height := ClientHeight div 2; +end; + +procedure TfrmLargeScreenDisplay.FormClose(Sender: TObject; var Action: TCloseAction); +begin + inherited; + Action := caFree; +end; + +procedure TfrmLargeScreenDisplay.TBCloseClick(Sender: TObject); +begin + + Close; +end; + +procedure TfrmLargeScreenDisplay.FormShow(Sender: TObject); +begin + inherited; + ReadCxGrid(Trim(Self.Caption), Tv1, ''); + ReadCxGrid(Trim(Self.Caption), Tv2, ''); + ReadCxGrid(Trim(Self.Caption), Tv3, ''); + ReadCxGrid(Trim(Self.Caption), Tv4, ''); + InitGrid(); + +end; + + + + + + + + + + + + + + + + + + + + +end. + diff --git a/A01基础公司管理/U_SelectStore.dfm b/A01基础公司管理/U_SelectStore.dfm new file mode 100644 index 0000000..cc38e2b --- /dev/null +++ b/A01基础公司管理/U_SelectStore.dfm @@ -0,0 +1,42 @@ +inherited frmSelectStore: TfrmSelectStore + Caption = #36873#25321#38376#24215 + ClientHeight = 121 + ClientWidth = 509 + Position = poScreenCenter + ExplicitWidth = 525 + ExplicitHeight = 160 + PixelsPerInch = 96 + TextHeight = 17 + object btnOK: TButton [0] + Left = 308 + Top = 42 + Width = 75 + Height = 25 + Caption = #30830#23450 + ModalResult = 1 + TabOrder = 0 + end + object cbStore: TComboBox [1] + Left = 47 + Top = 42 + Width = 216 + Height = 25 + TabOrder = 1 + Items.Strings = ( + #26684#32654 + #26032#20313 + #32654#25289) + end + object btnCancel: TButton [2] + Left = 389 + Top = 42 + Width = 75 + Height = 25 + Caption = #21462#28040 + ModalResult = 2 + TabOrder = 2 + end + inherited cxImageList_bar: TcxImageList + FormatVersion = 1 + end +end diff --git a/A01基础公司管理/U_SelectStore.pas b/A01基础公司管理/U_SelectStore.pas new file mode 100644 index 0000000..fbbc8a4 --- /dev/null +++ b/A01基础公司管理/U_SelectStore.pas @@ -0,0 +1,40 @@ +unit U_SelectStore; + +interface + +uses + Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics, + Vcl.Controls, Vcl.Forms, Vcl.Dialogs, U_BaseInput, cxImageList, cxGraphics, + System.ImageList, Vcl.ImgList, Data.DB, Data.Win.ADODB, Vcl.StdCtrls; + +type + TfrmSelectStore = class(TfrmBaseInput) + btnOK: TButton; + cbStore: TComboBox; + btnCancel: TButton; + procedure FormCreate(Sender: TObject); + private + { Private declarations } + public + { Public declarations } + function SelectedStore: string; + end; + +var + frmSelectStore: TfrmSelectStore; + +implementation + +{$R *.dfm} + +procedure TfrmSelectStore.FormCreate(Sender: TObject); +begin + inherited; + cbStore.ItemIndex := 0; +end; +function TfrmSelectStore.SelectedStore: string; +begin + Result := Trim(cbStore.Text); +end; + +end. diff --git a/A02基础产品管理/ClothInfo.skincfg b/A02基础产品管理/ClothInfo.skincfg index 97161c0..c7314d5 100644 --- a/A02基础产品管理/ClothInfo.skincfg +++ b/A02基础产品管理/ClothInfo.skincfg @@ -1,7 +1,7 @@ [ExpressSkins] Default=0 ShowNotifications=1 -Enabled=1 +Enabled=0 dxSkinsDefaultPainters=1 dxSkinBasic=1 dxSkinBlack=1 diff --git a/A02基础产品管理/U_ClothInfo.dfm b/A02基础产品管理/U_ClothInfo.dfm index 684d1c7..66c1dd9 100644 --- a/A02基础产品管理/U_ClothInfo.dfm +++ b/A02基础产品管理/U_ClothInfo.dfm @@ -506,6 +506,13 @@ inherited frmClothInfo: TfrmClothInfo Options.Editing = False Width = 112 end + object Tv1Column13: TcxGridDBColumn + Caption = #21333#20215 + DataBinding.FieldName = 'CostPrice' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end object v1Column3: TcxGridDBColumn Caption = #26377#25928#38376#24133 DataBinding.FieldName = 'C_Width' @@ -664,18 +671,21 @@ inherited frmClothInfo: TfrmClothInfo DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False + Width = 70 end object Tv1Column20: TcxGridDBColumn Caption = #23454#27979#36879#28287 DataBinding.FieldName = 'Test_Soggy' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter + Width = 70 end object Tv1Column21: TcxGridDBColumn Caption = #23454#27979#27700#21387 DataBinding.FieldName = 'Test_WaterPressure' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter + Width = 70 end end object cxGrid1Level1: TcxGridLevel diff --git a/A02基础产品管理/U_ClothInfo.pas b/A02基础产品管理/U_ClothInfo.pas index d529fa4..66bb799 100644 --- a/A02基础产品管理/U_ClothInfo.pas +++ b/A02基础产品管理/U_ClothInfo.pas @@ -16,24 +16,7 @@ uses dxBarBuiltInMenu, cxPC, Math, RM_BarCode, dxDateRanges, IdExplicitTLSClientServerBase, U_BaseList, cxContainer, dxDBBarCode, dxBarCode, Vcl.Clipbrd, cxTextEdit, BtnEdit, StrUtils, Vcl.Buttons, - dxScrollbarAnnotations, cxProgressBar, dxSkinsCore, dxSkinsDefaultPainters, - dxSkinWXI, dxSkinBasic, dxSkinBlack, dxSkinBlue, dxSkinBlueprint, - dxSkinCaramel, dxSkinCoffee, dxSkinDarkroom, dxSkinDarkSide, - dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy, - dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, - dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis, - dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black, - dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink, - dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue, - dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray, - dxSkinOffice2013White, dxSkinOffice2016Colorful, dxSkinOffice2016Dark, - dxSkinOffice2019Black, dxSkinOffice2019Colorful, dxSkinOffice2019DarkGray, - dxSkinOffice2019White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic, - dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringtime, dxSkinStardust, - dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinTheBezier, dxSkinValentine, - dxSkinVisualStudio2013Blue, dxSkinVisualStudio2013Dark, - dxSkinVisualStudio2013Light, dxSkinVS2010, dxSkinWhiteprint, - dxSkinXmas2008Blue; + dxScrollbarAnnotations, cxProgressBar; type FdDy = record @@ -153,6 +136,7 @@ type cxGridDBColumn1: TcxGridDBColumn; cxGridDBColumn2: TcxGridDBColumn; cxGridLevel2: TcxGridLevel; + Tv1Column13: TcxGridDBColumn; procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure TBCloseClick(Sender: TObject); procedure TBDelClick(Sender: TObject); @@ -348,11 +332,9 @@ end; // cxDBTreeList1.Items[0].Expand(false); // end; // - //end; procedure TfrmClothInfo.InitTree(); - begin try cxDBTreeList1.BeginUpdate; @@ -362,14 +344,14 @@ begin begin SQL.Clear; - if canshu4= 'μӹ' then - begin - SQL.Add('SELECT * FROM dbo.F_BS_CloType(''CT2505100001'') A ORDER BY CTName '); - end - else - begin - SQL.Add('SELECT * FROM dbo.F_BS_CloType(''CT2412300003'') A ORDER BY CTName '); - end; + if canshu4 = 'μӹ' then + begin + SQL.Add('SELECT * FROM dbo.F_BS_CloType(''CT2505100001'') A ORDER BY CTName '); + end + else + begin + SQL.Add('SELECT * FROM dbo.F_BS_CloType(''CT2412300003'') A ORDER BY CTName '); + end; Open; end; @@ -381,9 +363,9 @@ begin CDS_Tree.EnableControls; cxDBTreeList1.EndUpdate; - cxDBTreeList1.Items[0].Expand(False); + cxDBTreeList1.Items[0].Expand(False); end; - Self.cds_tree.Locate('CTName', 'Ʒ', []); + Self.cds_tree.Locate('CTName', 'Ʒ', []); end; procedure TfrmClothInfo.InitGrid(); diff --git a/A02基础产品管理/U_ClothInfoInput.pas b/A02基础产品管理/U_ClothInfoInput.pas index 69095b2..68b6a9f 100644 --- a/A02基础产品管理/U_ClothInfoInput.pas +++ b/A02基础产品管理/U_ClothInfoInput.pas @@ -173,7 +173,6 @@ type procedure C_FromName4PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure C_FromName5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure CostPriceClick(Sender: TObject); - private canshu1: string; Fint: Integer; @@ -372,11 +371,40 @@ procedure TfrmClothInfoInput.InitGrid1(); var SqlStr: string; begin - SqlStr := 'select A.* from BS_Cloth_Info_Sub A '; - SqlStr := SqlStr + ' where A.BCIID=''' + Trim(FBCIID) + ''''; - SqlStr := SqlStr + ' ORDER BY CASE WHEN C_COLORNO NOT LIKE ''%[^0-9]%'' THEN dbo.getNum(C_Colorno) ELSE 9999999999 '; - SqlStr := SqlStr + ' END ,C_ColorNo'; +// SqlStr := 'select A.* from BS_Cloth_Info_Sub A '; +// SqlStr := SqlStr + ' where A.BCIID=''' + Trim(FBCIID) + ''''; +// SqlStr := SqlStr + ' ORDER BY CASE WHEN C_COLORNO NOT LIKE ''%[^0-9]%'' THEN dbo.getNum(C_Colorno) ELSE 9999999999 '; +// SqlStr := SqlStr + ' END ,C_ColorNo'; + SqlStr := 'SELECT A.* FROM BS_Cloth_Info_Sub A '; + SqlStr := SqlStr + 'WHERE A.BCIID = ''' + Trim(FBCIID) + ''' '; + SqlStr := SqlStr + 'ORDER BY '; + SqlStr := SqlStr + ' CASE '; + SqlStr := SqlStr + ' WHEN C_ColorNo NOT LIKE ''%[^0-9]%'' THEN 0 '; + SqlStr := SqlStr + ' ELSE 1 '; + SqlStr := SqlStr + ' END, '; + SqlStr := SqlStr + ' CASE '; + SqlStr := SqlStr + ' WHEN C_ColorNo NOT LIKE ''%[^0-9]%'' THEN CAST(C_ColorNo AS INT) '; + SqlStr := SqlStr + ' ELSE 999999999 '; + SqlStr := SqlStr + ' END, '; + SqlStr := SqlStr + ' CASE '; + SqlStr := SqlStr + ' WHEN C_ColorNo LIKE ''[A-Za-z]%'' THEN '; + SqlStr := SqlStr + ' LEFT(C_ColorNo, PATINDEX(''%[0-9]%'', C_ColorNo + ''0'') - 1) '; + SqlStr := SqlStr + ' ELSE '; + SqlStr := SqlStr + ' '''' '; + SqlStr := SqlStr + ' END, '; + SqlStr := SqlStr + ' CASE '; + SqlStr := SqlStr + ' WHEN PATINDEX(''%[0-9]%'', C_ColorNo) > 0 THEN '; + SqlStr := SqlStr + ' CASE '; + SqlStr := SqlStr + ' WHEN ISNUMERIC(SUBSTRING(C_ColorNo, PATINDEX(''%[0-9]%'', C_ColorNo), LEN(C_ColorNo))) = 1 '; + SqlStr := SqlStr + ' THEN CAST(SUBSTRING(C_ColorNo, PATINDEX(''%[0-9]%'', C_ColorNo), LEN(C_ColorNo)) AS INT) '; + SqlStr := SqlStr + ' ELSE 0 '; + SqlStr := SqlStr + ' END '; + SqlStr := SqlStr + ' ELSE '; + SqlStr := SqlStr + ' 0 '; + SqlStr := SqlStr + ' END, '; + SqlStr := SqlStr + ' C_ColorNo'; + // ShowMessage(sqlstr); InitCDSData(ADO_1, CDS_1, Tv1, SqlStr, '', ''); SqlStr := 'select A.* from BS_Cloth_Info_GYSCP A '; @@ -532,14 +560,14 @@ begin // SCSHData(ADOQueryTemp, panel2, 2); // SCSHData(ADOQueryTemp, panel6, 2); if FCTID = 'CT2412300005' then - begin - SCSHData(ADOQueryTemp, panel2, 2); - SCSHData(ADOQueryTemp, panel6, 2); - end - else - begin - SCSHData(ADOQueryTemp, panel2, 2); - end; + begin + SCSHData(ADOQueryTemp, panel2, 2); + SCSHData(ADOQueryTemp, panel6, 2); + end + else + begin + SCSHData(ADOQueryTemp, panel2, 2); + end; StkPosition.Text := ADOQueryTemp.FieldByName('StkPosition').AsString; qtyunit.Text := ADOQueryTemp.FieldByName('qtyunit').AsString; // SCSHData(ADOQueryTemp, ScrollBox1, 0); @@ -755,7 +783,7 @@ begin C_Name.Enabled := True; C_FromName.Enabled := False; C_FromName2.Enabled := False; - Panel6.Visible:=False; + Panel6.Visible := False; end; with ADOQueryTemp do begin @@ -894,7 +922,7 @@ begin if FCTID = 'CT2412300005' then begin RTSetsavedata(ADOQueryCmd, 'BS_Cloth_Info', panel2, 2); - RTSetsavedata(ADOQueryCmd, 'BS_Cloth_Info', panel6, 2) ; + RTSetsavedata(ADOQueryCmd, 'BS_Cloth_Info', panel6, 2); end else begin @@ -1318,7 +1346,7 @@ begin begin if Trim(C_FromName.Text) = '' then begin - Application.MessageBox('Ʒ!', 'ʾ', 0); + Application.MessageBox('ɫ!', 'ʾ', 0); Exit; end; @@ -1329,11 +1357,21 @@ begin begin if Trim(C_Name.Text) = '' then begin - Application.MessageBox('Ʒ!', 'ʾ', 0); + Application.MessageBox('ɫ!', 'ʾ', 0); Exit; end; end; + if Trim(StkPosition.Text) = '' then + begin + Application.MessageBox('λ!', 'ʾ', 0); + Exit; + end; + if Trim(qtyunit.Text) = '' then + begin + Application.MessageBox('Ƽ۵λ!', 'ʾ', 0); + Exit; + end; // if CDS_1.Locate('C_Color', null, []) = True then // begin @@ -1464,11 +1502,9 @@ begin // Panel6.Visible := False; end; - - procedure TfrmClothInfoInput.CostPriceClick(Sender: TObject); begin - CostPrice.text:=''; + CostPrice.text := ''; end; procedure TfrmClothInfoInput.CostPricePropertiesEditValueChanged(Sender: TObject); diff --git a/A09财务通用管理/Financial.skincfg b/A09财务通用管理/Financial.skincfg index 0849faf..dde317f 100644 --- a/A09财务通用管理/Financial.skincfg +++ b/A09财务通用管理/Financial.skincfg @@ -1,62 +1,62 @@ [ExpressSkins] -Default=1 +Default=0 ShowNotifications=1 -Enabled=1 -dxSkinBasic=0 -dxSkinBlack=0 -dxSkinBlue=0 -dxSkinBlueprint=0 -dxSkinCaramel=0 -dxSkinCoffee=0 -dxSkinDarkroom=0 -dxSkinDarkSide=0 -dxSkinDevExpressDarkStyle=0 -dxSkinDevExpressStyle=0 -dxSkinFoggy=0 -dxSkinGlassOceans=0 -dxSkinHighContrast=0 -dxSkiniMaginary=0 -dxSkinLilian=0 -dxSkinLiquidSky=0 -dxSkinLondonLiquidSky=0 -dxSkinMcSkin=0 -dxSkinMetropolis=0 -dxSkinMetropolisDark=0 -dxSkinMoneyTwins=0 -dxSkinOffice2007Black=0 -dxSkinOffice2007Blue=0 -dxSkinOffice2007Green=0 -dxSkinOffice2007Pink=0 -dxSkinOffice2007Silver=0 -dxSkinOffice2010Black=0 -dxSkinOffice2010Blue=0 -dxSkinOffice2010Silver=0 -dxSkinOffice2013DarkGray=0 -dxSkinOffice2013LightGray=0 -dxSkinOffice2013White=0 -dxSkinOffice2016Colorful=0 -dxSkinOffice2016Dark=0 -dxSkinOffice2019Black=0 -dxSkinOffice2019Colorful=0 -dxSkinOffice2019DarkGray=0 -dxSkinOffice2019White=0 -dxSkinPumpkin=0 -dxSkinSeven=0 -dxSkinSevenClassic=0 -dxSkinSharp=0 -dxSkinSharpPlus=0 -dxSkinSilver=0 -dxSkinSpringtime=0 -dxSkinStardust=0 -dxSkinSummer2008=0 -dxSkinTheAsphaltWorld=0 -dxSkinTheBezier=0 +Enabled=0 +dxSkinBasic=1 +dxSkinBlack=1 +dxSkinBlue=1 +dxSkinBlueprint=1 +dxSkinCaramel=1 +dxSkinCoffee=1 +dxSkinDarkroom=1 +dxSkinDarkSide=1 +dxSkinDevExpressDarkStyle=1 +dxSkinDevExpressStyle=1 +dxSkinFoggy=1 +dxSkinGlassOceans=1 +dxSkinHighContrast=1 +dxSkiniMaginary=1 +dxSkinLilian=1 +dxSkinLiquidSky=1 +dxSkinLondonLiquidSky=1 +dxSkinMcSkin=1 +dxSkinMetropolis=1 +dxSkinMetropolisDark=1 +dxSkinMoneyTwins=1 +dxSkinOffice2007Black=1 +dxSkinOffice2007Blue=1 +dxSkinOffice2007Green=1 +dxSkinOffice2007Pink=1 +dxSkinOffice2007Silver=1 +dxSkinOffice2010Black=1 +dxSkinOffice2010Blue=1 +dxSkinOffice2010Silver=1 +dxSkinOffice2013DarkGray=1 +dxSkinOffice2013LightGray=1 +dxSkinOffice2013White=1 +dxSkinOffice2016Colorful=1 +dxSkinOffice2016Dark=1 +dxSkinOffice2019Black=1 +dxSkinOffice2019Colorful=1 +dxSkinOffice2019DarkGray=1 +dxSkinOffice2019White=1 +dxSkinPumpkin=1 +dxSkinSeven=1 +dxSkinSevenClassic=1 +dxSkinSharp=1 +dxSkinSharpPlus=1 +dxSkinSilver=1 +dxSkinSpringtime=1 +dxSkinStardust=1 +dxSkinSummer2008=1 +dxSkinTheAsphaltWorld=1 +dxSkinTheBezier=1 dxSkinsDefaultPainters=1 -dxSkinValentine=0 -dxSkinVisualStudio2013Blue=0 -dxSkinVisualStudio2013Dark=0 -dxSkinVisualStudio2013Light=0 -dxSkinVS2010=0 -dxSkinWhiteprint=0 +dxSkinValentine=1 +dxSkinVisualStudio2013Blue=1 +dxSkinVisualStudio2013Dark=1 +dxSkinVisualStudio2013Light=1 +dxSkinVS2010=1 +dxSkinWhiteprint=1 dxSkinWXI=1 -dxSkinXmas2008Blue=0 +dxSkinXmas2008Blue=1 diff --git a/A09财务通用管理/U_FinTradePlanSel.dfm b/A09财务通用管理/U_FinTradePlanSel.dfm index 6c85a6e..414689d 100644 --- a/A09财务通用管理/U_FinTradePlanSel.dfm +++ b/A09财务通用管理/U_FinTradePlanSel.dfm @@ -265,6 +265,7 @@ inherited frmFinTradePlanSel: TfrmFinTradePlanSel DataBinding.FieldName = 'Technics' DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter + Width = 70 end object Tv1Column2: TcxGridDBColumn Caption = #21152#24037#21378 diff --git a/A09财务通用管理/U_FinTradeSalesContractSel.dfm b/A09财务通用管理/U_FinTradeSalesContractSel.dfm index 5cf3929..2f8ac07 100644 --- a/A09财务通用管理/U_FinTradeSalesContractSel.dfm +++ b/A09财务通用管理/U_FinTradeSalesContractSel.dfm @@ -226,7 +226,7 @@ inherited frmFinTradeSalesContractSel: TfrmFinTradeSalesContractSel DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False - Width = 72 + Width = 118 end object VC_SCSCode: TcxGridDBColumn Caption = #20135#21697#32534#21495 @@ -249,7 +249,7 @@ inherited frmFinTradeSalesContractSel: TfrmFinTradeSalesContractSel DataBinding.IsNullValueType = True HeaderAlignmentHorz = taCenter Options.Editing = False - Width = 70 + Width = 104 end object cxGridDBColumn3: TcxGridDBColumn Caption = #20135#21697#33521#25991#21517 diff --git a/A09财务通用管理/U_ReceivableInput.dfm b/A09财务通用管理/U_ReceivableInput.dfm index 32231ba..06c14cd 100644 --- a/A09财务通用管理/U_ReceivableInput.dfm +++ b/A09财务通用管理/U_ReceivableInput.dfm @@ -2,8 +2,8 @@ object frmReceivableInput: TfrmReceivableInput Left = 261 Top = 149 Caption = #24212#25910#27454#30331#35760 - ClientHeight = 488 - ClientWidth = 1324 + ClientHeight = 757 + ClientWidth = 1353 Color = clWhite Font.Charset = GB2312_CHARSET Font.Color = clWindowText @@ -21,7 +21,7 @@ object frmReceivableInput: TfrmReceivableInput Tag = 1 Left = 0 Top = 0 - Width = 1324 + Width = 1353 Height = 30 AutoSize = True ButtonHeight = 30 @@ -51,11 +51,232 @@ object frmReceivableInput: TfrmReceivableInput OnClick = TBCloseClick end end + object cxGroupBox1: TcxGroupBox + Left = 0 + Top = 310 + Align = alBottom + Caption = #20986#20179#26126#32454 + TabOrder = 1 + Height = 447 + Width = 1353 + object cxGrid1: TcxGrid + Left = 4 + Top = 23 + Width = 1345 + Height = 408 + Align = alClient + TabOrder = 0 + object Tv1: TcxGridDBTableView + Navigator.Buttons.CustomButtons = <> + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_1 + DataController.Summary.DefaultGroupSummaryItems = <> + DataController.Summary.FooterSummaryItems = <> + DataController.Summary.SummaryGroups = <> + OptionsView.GroupByBox = False + OptionsView.Indicator = True + OptionsView.IndicatorWidth = 50 + OnCustomDrawIndicatorCell = Tv1CustomDrawIndicatorCell + object Tv1Column1: TcxGridDBColumn + Caption = #33394#24067#21517#31216 + DataBinding.FieldName = 'F_Name' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 94 + end + object Tv1Column2: TcxGridDBColumn + Caption = #33394#21495 + DataBinding.FieldName = 'F_ColorNo' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column3: TcxGridDBColumn + Caption = #39068#33394 + DataBinding.FieldName = 'F_Color' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column6: TcxGridDBColumn + Caption = #35745#20215#21333#20301 + DataBinding.FieldName = 'Currency' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxComboBoxProperties' + Properties.Items.Strings = ( + 'CNY' + 'USD' + 'EUR') + HeaderAlignmentHorz = taCenter + Width = 105 + end + object v1Qty: TcxGridDBColumn + Caption = #25968#37327 + DataBinding.FieldName = 'Qty' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.OnEditValueChanged = v1QtyPropertiesEditValueChanged + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column16: TcxGridDBColumn + Caption = #21333#20301 + DataBinding.FieldName = 'QtyUnit' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxComboBoxProperties' + Properties.Items.Strings = ( + 'Kg' + 'M' + 'Y' + #20010 + #20214) + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column11: TcxGridDBColumn + Caption = #20214#25968 + DataBinding.FieldName = 'TMSQty' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column12: TcxGridDBColumn + Caption = #21333#20215 + DataBinding.FieldName = 'Price' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.OnEditValueChanged = v1QtyPropertiesEditValueChanged + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column13: TcxGridDBColumn + Caption = #21442#32771#23450#20215 + DataBinding.FieldName = 'referencePrice' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 106 + end + object Tv1Column15: TcxGridDBColumn + Caption = #37329#39069 + DataBinding.FieldName = 'Amount' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column17: TcxGridDBColumn + Caption = #22791#27880 + DataBinding.FieldName = 'Note' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column21: TcxGridDBColumn + Caption = #38376#24133 + DataBinding.FieldName = 'F_Width' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column22: TcxGridDBColumn + Caption = #20811#37325 + DataBinding.FieldName = 'F_GramWeight' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column23: TcxGridDBColumn + Caption = #33457#22411 + DataBinding.FieldName = 'F_Pattern' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column24: TcxGridDBColumn + Caption = #27454#21495 + DataBinding.FieldName = 'F_StyleNo' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column25: TcxGridDBColumn + Caption = #21305#25968 + DataBinding.FieldName = 'Piece' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column26: TcxGridDBColumn + Caption = #20943#20813 + DataBinding.FieldName = 'Deduction' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column27: TcxGridDBColumn + Caption = #23567#32568#36153 + DataBinding.FieldName = 'OtherFee1' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 70 + end + object Tv1Column28: TcxGridDBColumn + Caption = #20854#20182#36153 + DataBinding.FieldName = 'OtherFee' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + HeaderGlyphAlignmentHorz = taCenter + Width = 70 + end + end + object cxGrid1Level1: TcxGridLevel + GridView = Tv1 + end + end + end + object ToolBar2: TToolBar + Tag = 1 + Left = 0 + Top = 280 + Width = 1353 + Height = 30 + Align = alBottom + AutoSize = True + ButtonHeight = 30 + ButtonWidth = 67 + Caption = 'ToolBar1' + Color = clWhite + DisabledImages = DataLink_Financial.ImageList_new32 + Images = DataLink_Financial.cxImageList_bar + List = True + ParentColor = False + ShowCaptions = True + TabOrder = 2 + object ToolButton1: TToolButton + Left = 0 + Top = 0 + AutoSize = True + Caption = #22686#34892 + ImageIndex = 2 + OnClick = ToolButton1Click + end + object ToolButton2: TToolButton + Left = 71 + Top = 0 + AutoSize = True + Caption = #21024#34892 + ImageIndex = 6 + OnClick = ToolButton2Click + end + end object ScrollBox1: TScrollBox Left = 0 Top = 30 - Width = 1324 - Height = 458 + Width = 1353 + Height = 250 Align = alClient BevelInner = bvNone BevelOuter = bvNone @@ -64,8 +285,7 @@ object frmReceivableInput: TfrmReceivableInput Ctl3D = False ParentColor = False ParentCtl3D = False - TabOrder = 1 - OnClick = ScrollBox1Click + TabOrder = 3 object Label2: TLabel Left = 262 Top = 15 @@ -81,19 +301,12 @@ object frmReceivableInput: TfrmReceivableInput Caption = #32534' '#21495 end object Label7: TLabel - Left = 28 - Top = 264 + Left = 27 + Top = 143 Width = 62 Height = 21 Caption = #22791' '#27880 end - object Label1: TLabel - Left = 262 - Top = 100 - Width = 62 - Height = 21 - Caption = #21697' '#21517 - end object Label8: TLabel Left = 762 Top = 57 @@ -115,76 +328,6 @@ object frmReceivableInput: TfrmReceivableInput Height = 21 Caption = #19978#32423#21333#20301 end - object Label3: TLabel - Left = 262 - Top = 228 - Width = 62 - Height = 21 - Caption = #37329' '#39069 - end - object Label10: TLabel - Left = 28 - Top = 185 - Width = 62 - Height = 21 - Caption = #21305' '#25968 - end - object Label11: TLabel - Left = 262 - Top = 185 - Width = 62 - Height = 21 - Caption = #25968' '#37327 - end - object Label12: TLabel - Left = 504 - Top = 185 - Width = 62 - Height = 21 - Caption = #21333' '#20215 - end - object Label13: TLabel - Left = 28 - Top = 143 - Width = 62 - Height = 21 - Caption = #38376' '#24133 - end - object Label14: TLabel - Left = 262 - Top = 143 - Width = 62 - Height = 21 - Caption = #20811' '#37325 - end - object Label15: TLabel - Left = 504 - Top = 143 - Width = 62 - Height = 21 - Caption = #33457' '#22411 - end - object Label16: TLabel - Left = 504 - Top = 100 - Width = 62 - Height = 21 - Caption = #39068' '#33394 - end - object Label17: TLabel - Left = 762 - Top = 100 - Width = 62 - Height = 21 - Caption = #33394' '#21495 - end - object Label4: TLabel - Left = 762 - Top = 185 - Width = 68 - Height = 21 - Caption = #20854' '#20182' '#36153 - end object Label20: TLabel Left = 762 Top = 15 @@ -192,13 +335,6 @@ object frmReceivableInput: TfrmReceivableInput Height = 21 Caption = #26085' '#26399 end - object Label21: TLabel - Left = 28 - Top = 228 - Width = 62 - Height = 21 - Caption = #20943' '#20813 - end object Label22: TLabel Left = 262 Top = 57 @@ -221,26 +357,12 @@ object frmReceivableInput: TfrmReceivableInput Caption = #25688' '#35201 end object Label18: TLabel - Left = 504 - Top = 228 + Left = 263 + Top = 99 Width = 64 Height = 21 Caption = #26159#21542#21547#31246 end - object Label19: TLabel - Left = 762 - Top = 228 - Width = 48 - Height = 21 - Caption = #23567#32568#36153 - end - object Label25: TLabel - Left = 762 - Top = 143 - Width = 62 - Height = 21 - Caption = #27454' '#21495 - end object Label26: TLabel Left = 1006 Top = 15 @@ -255,89 +377,6 @@ object frmReceivableInput: TfrmReceivableInput Height = 21 Caption = #27719' '#29575 end - object F_Name: TcxTextEdit - Left = 337 - Top = 96 - TabOrder = 0 - Width = 159 - end - object Amount: TcxCurrencyEdit - Left = 337 - Top = 224 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 1 - OnExit = QtyExit - Width = 84 - end - object Price: TcxCurrencyEdit - Left = 578 - Top = 182 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 2 - OnExit = QtyExit - Width = 150 - end - object Qty: TcxCurrencyEdit - Left = 337 - Top = 182 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 3 - OnExit = QtyExit - Width = 101 - end - object Piece: TcxCurrencyEdit - Left = 99 - Top = 182 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 4 - Width = 150 - end - object F_Width: TcxTextEdit - Left = 99 - Top = 139 - TabOrder = 5 - Width = 150 - end - object F_GramWeight: TcxTextEdit - Left = 337 - Top = 139 - TabOrder = 6 - Width = 159 - end - object F_Pattern: TcxTextEdit - Left = 578 - Top = 139 - TabOrder = 7 - Width = 150 - end - object F_Color: TcxTextEdit - Left = 579 - Top = 96 - TabOrder = 8 - Width = 150 - end - object F_ColorNo: TcxTextEdit - Left = 835 - Top = 96 - TabOrder = 9 - Width = 150 - end - object OtherFee: TcxCurrencyEdit - Left = 835 - Top = 182 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 10 - OnExit = QtyExit - Width = 150 - end - object Deduction: TcxCurrencyEdit - Left = 99 - Top = 224 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 11 - OnExit = QtyExit - Width = 150 - end object OurCoName: TcxButtonEdit Left = 99 Top = 11 @@ -349,7 +388,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = OurCoNamePropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 12 + TabOrder = 0 OnDblClick = OurCoNameDblClick Width = 151 end @@ -364,7 +403,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = OppCoNamePropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 13 + TabOrder = 1 OnDblClick = OurCoNameDblClick Width = 159 end @@ -379,7 +418,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = OppParentCoNamePropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 14 + TabOrder = 2 OnDblClick = OurCoNameDblClick Width = 151 end @@ -387,7 +426,7 @@ object frmReceivableInput: TfrmReceivableInput Left = 835 Top = 11 Properties.ShowTime = False - TabOrder = 15 + TabOrder = 3 Width = 151 end object ConNo: TcxButtonEdit @@ -400,8 +439,9 @@ object frmReceivableInput: TfrmReceivableInput end> Properties.ReadOnly = True Properties.OnButtonClick = ConNoPropertiesButtonClick + Properties.OnChange = ConNoPropertiesChange Style.ButtonStyle = btsDefault - TabOrder = 16 + TabOrder = 4 OnDblClick = OurCoNameDblClick Width = 151 end @@ -416,7 +456,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = OrderNoPropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 17 + TabOrder = 5 OnDblClick = OurCoNameDblClick Width = 159 end @@ -432,7 +472,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = FFAbstractPropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 18 + TabOrder = 6 OnDblClick = OurCoNameDblClick Width = 151 end @@ -448,73 +488,33 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = FFAbstractPropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 19 + TabOrder = 7 OnDblClick = OurCoNameDblClick Width = 151 end - object QtyUnit: TcxComboBox - Left = 440 - Top = 182 - Properties.DropDownListStyle = lsEditFixedList - Properties.Items.Strings = ( - 'Kg' - 'M' - 'Y' - #20010 - #20214) - TabOrder = 20 - Text = 'Kg' - Width = 57 - end - object Currency: TcxComboBox - Left = 424 - Top = 224 - Properties.DropDownListStyle = lsEditFixedList - Properties.Items.Strings = ( - 'CNY' - 'USD' - 'EUR') - TabOrder = 21 - Text = 'CNY' - Width = 73 - end object IsInvoice: TcxComboBox - Left = 578 - Top = 224 + Left = 337 + Top = 95 Properties.DropDownListStyle = lsEditFixedList Properties.Items.Strings = ( #26159 #21542) - TabOrder = 22 + TabOrder = 8 Text = #26159 - Width = 151 + Width = 159 end object Note: TcxMemo - Left = 99 - Top = 265 - TabOrder = 23 - Height = 127 - Width = 886 - end - object OtherFee1: TcxCurrencyEdit - Left = 835 - Top = 224 - Properties.AssignedValues.DisplayFormat = True - TabOrder = 24 - OnExit = QtyExit - Width = 150 - end - object F_StyleNo: TcxTextEdit - Left = 835 - Top = 139 - TabOrder = 25 - Width = 150 + Left = 95 + Top = 146 + TabOrder = 9 + Height = 79 + Width = 1128 end object ReconciliationDate: TcxDateEdit Left = 1076 Top = 11 Properties.ShowTime = False - TabOrder = 26 + TabOrder = 10 Width = 151 end object F_Code: TcxButtonEdit @@ -528,7 +528,7 @@ object frmReceivableInput: TfrmReceivableInput Properties.ReadOnly = True Properties.OnButtonClick = F_CodePropertiesButtonClick Style.ButtonStyle = btsDefault - TabOrder = 27 + TabOrder = 11 OnDblClick = OurCoNameDblClick Width = 151 end @@ -536,7 +536,7 @@ object frmReceivableInput: TfrmReceivableInput Left = 1074 Top = 53 Properties.AssignedValues.DisplayFormat = True - TabOrder = 28 + TabOrder = 12 Width = 150 end end @@ -544,20 +544,48 @@ object frmReceivableInput: TfrmReceivableInput Connection = DataLink_Financial.ADOLink LockType = ltReadOnly Parameters = <> - Left = 498 - Top = 372 + Left = 648 + Top = 321 end object ADOQueryCmd: TADOQuery Connection = DataLink_Financial.ADOLink Parameters = <> - Left = 397 - Top = 369 + Left = 512 + Top = 321 end object ADOQueryMain: TADOQuery Connection = DataLink_Financial.ADOLink LockType = ltReadOnly Parameters = <> - Left = 549 - Top = 313 + Left = 580 + Top = 321 + end + object CDS_1: TClientDataSet + Aggregates = <> + Params = <> + Left = 716 + Top = 321 + end + object DS_1: TDataSource + DataSet = CDS_1 + Left = 784 + Top = 321 + end + object CDS_2: TClientDataSet + Aggregates = <> + Params = <> + Left = 992 + Top = 462 + end + object DS_2: TDataSource + DataSet = CDS_2 + Left = 872 + Top = 430 + end + object ADO2: TADOQuery + Connection = DataLink_Financial.ADOLink + Parameters = <> + Left = 920 + Top = 518 end end diff --git a/A09财务通用管理/U_ReceivableInput.pas b/A09财务通用管理/U_ReceivableInput.pas index 0a6770f..d280c38 100644 --- a/A09财务通用管理/U_ReceivableInput.pas +++ b/A09财务通用管理/U_ReceivableInput.pas @@ -15,7 +15,7 @@ uses cxTextEdit, cxDropDownEdit, BtnEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxDateRanges, dxBarBuiltInMenu, U_BaseList, cxContainer, cxCurrencyEdit, dxCore, cxDateUtils, cxMemo, dxSkinsCore, - dxSkinsDefaultPainters; + dxSkinsDefaultPainters, dxScrollbarAnnotations, cxGroupBox; type TfrmReceivableInput = class(TForm) @@ -24,42 +24,49 @@ type ADOQueryTemp: TADOQuery; ADOQueryCmd: TADOQuery; ToolButton3: TToolButton; + ADOQueryMain: TADOQuery; + cxGroupBox1: TcxGroupBox; + cxGrid1: TcxGrid; + Tv1: TcxGridDBTableView; + cxGrid1Level1: TcxGridLevel; + Tv1Column1: TcxGridDBColumn; + Tv1Column2: TcxGridDBColumn; + Tv1Column3: TcxGridDBColumn; + Tv1Column6: TcxGridDBColumn; + v1Qty: TcxGridDBColumn; + Tv1Column11: TcxGridDBColumn; + Tv1Column12: TcxGridDBColumn; + Tv1Column13: TcxGridDBColumn; + Tv1Column15: TcxGridDBColumn; + Tv1Column16: TcxGridDBColumn; + Tv1Column17: TcxGridDBColumn; + ToolBar2: TToolBar; + ToolButton1: TToolButton; + ToolButton2: TToolButton; + CDS_1: TClientDataSet; + DS_1: TDataSource; + Tv1Column21: TcxGridDBColumn; + Tv1Column22: TcxGridDBColumn; + Tv1Column23: TcxGridDBColumn; + Tv1Column24: TcxGridDBColumn; + Tv1Column25: TcxGridDBColumn; + Tv1Column26: TcxGridDBColumn; + Tv1Column27: TcxGridDBColumn; + Tv1Column28: TcxGridDBColumn; ScrollBox1: TScrollBox; Label2: TLabel; Label6: TLabel; Label7: TLabel; - Label1: TLabel; - F_Name: TcxTextEdit; Label8: TLabel; Label5: TLabel; Label9: TLabel; - Amount: TcxCurrencyEdit; - Label3: TLabel; - Price: TcxCurrencyEdit; - Qty: TcxCurrencyEdit; - Piece: TcxCurrencyEdit; - Label10: TLabel; - Label11: TLabel; - Label12: TLabel; - Label13: TLabel; - Label14: TLabel; - F_Width: TcxTextEdit; - F_GramWeight: TcxTextEdit; - Label15: TLabel; - Label16: TLabel; - F_Pattern: TcxTextEdit; - F_Color: TcxTextEdit; - Label17: TLabel; - F_ColorNo: TcxTextEdit; - OtherFee: TcxCurrencyEdit; - Label4: TLabel; Label20: TLabel; - Deduction: TcxCurrencyEdit; - Label21: TLabel; Label22: TLabel; Label23: TLabel; Label24: TLabel; Label18: TLabel; + Label26: TLabel; + Label27: TLabel; OurCoName: TcxButtonEdit; OppCoName: TcxButtonEdit; OppParentCoName: TcxButtonEdit; @@ -68,20 +75,14 @@ type OrderNo: TcxButtonEdit; FFAbstract: TcxButtonEdit; PayMent: TcxButtonEdit; - QtyUnit: TcxComboBox; - Currency: TcxComboBox; IsInvoice: TcxComboBox; Note: TcxMemo; - Label19: TLabel; - OtherFee1: TcxCurrencyEdit; - F_StyleNo: TcxTextEdit; - Label25: TLabel; - Label26: TLabel; ReconciliationDate: TcxDateEdit; F_Code: TcxButtonEdit; - ADOQueryMain: TADOQuery; - Label27: TLabel; ExchangeRate: TcxCurrencyEdit; + CDS_2: TClientDataSet; + DS_2: TDataSource; + ADO2: TADOQuery; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure TBCloseClick(Sender: TObject); @@ -90,8 +91,8 @@ type procedure ToolButton3Click(Sender: TObject); procedure PayMentBtnDnClick(Sender: TObject); procedure PayMentBtnUpClick(Sender: TObject); - procedure QtyExit(Sender: TObject); - procedure ScrollBox1Click(Sender: TObject); + //procedure QtyExit(Sender: TObject); + //procedure ScrollBox1Click(Sender: TObject); procedure OrderNoBtnUpClick(Sender: TObject); procedure ConNoBtnUpClick(Sender: TObject); procedure OurCoNamePropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); @@ -102,10 +103,16 @@ type procedure OrderNoPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure FFAbstractPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure F_CodePropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); + procedure ToolButton1Click(Sender: TObject); + procedure ToolButton2Click(Sender: TObject); + procedure v1QtyPropertiesEditValueChanged(Sender: TObject); + procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean); + procedure ConNoPropertiesChange(Sender: TObject); + private { Private declarations } procedure InitGrid(); - procedure HJJE(); +// procedure HJJE(); function SaveData(): Boolean; public { Public declarations } @@ -123,27 +130,27 @@ uses {$R *.dfm} -procedure TfrmReceivableInput.HJJE(); -var - MPrice, MQty, MOtherFee, MOtherFee1, MDeduction, MAmount: double; -begin - MPrice := Strtofloatdef(Price.Text, 0); - MQty := Strtofloatdef(Qty.Text, 0); - MOtherFee := Strtofloatdef(OtherFee.Text, 0); - MOtherFee1 := Strtofloatdef(OtherFee1.Text, 0); - MDeduction := Strtofloatdef(Deduction.Text, 0); - MAmount := Strtofloatdef(Amount.Text, 0); - -// if MQty * MPrice >= 0 then - begin - MAmount := RoundFloat((MQty * MPrice + MOtherFee + MOtherFee1 - MDeduction), 2); - end; -// Price.Text := FloatToStr(MPrice); -// Qty.Text := FloatToStr(MQty); -// OtherFee.Text := FloatToStr(MOtherFee); -// Deduction.Text := FloatToStr(MDeduction); - Amount.Text := FloatToStr(MAmount); -end; +//procedure TfrmReceivableInput.HJJE(); +//var +// MPrice, MQty, MOtherFee, MOtherFee1, MDeduction, MAmount: double; +//begin +// MPrice := Strtofloatdef(price.Text, 0); +// MQty := Strtofloatdef(Qty.Text, 0); +// MOtherFee := Strtofloatdef(OtherFee.Text, 0); +// MOtherFee1 := Strtofloatdef(OtherFee1.Text, 0); +// MDeduction := Strtofloatdef(Deduction.Text, 0); +// MAmount := Strtofloatdef(Amount.Text, 0); +// +//// if MQty * MPrice >= 0 then +// begin +// MAmount := RoundFloat((MQty * MPrice + MOtherFee + MOtherFee1 - MDeduction), 2); +// end; +//// Price.Text := FloatToStr(MPrice); +//// Qty.Text := FloatToStr(MQty); +//// OtherFee.Text := FloatToStr(MOtherFee); +//// Deduction.Text := FloatToStr(MDeduction); +// Amount.Text := FloatToStr(MAmount); +//end; procedure TfrmReceivableInput.InitGrid(); begin @@ -158,6 +165,9 @@ begin sql.Add(' select * from Finance_Flow where FFID=''' + Trim(FFFID) + ''''); Open; end; + SCreateCDS(ADOQueryMain, CDS_1); + SInitCDSData(ADOQueryMain, CDS_1); + if not ADOQueryMain.IsEmpty then begin SCSHData(ADOQueryMain, ScrollBox1, 0); @@ -252,17 +262,40 @@ begin begin with frmFinTradePlanSel.CDS_1 do begin + self.ConNo.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('ConNo').AsString); self.OrderNo.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('OrderNo').AsString); self.F_Code.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Code').AsString); - self.F_Name.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Name').AsString); - self.F_Pattern.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Pattern').AsString); - self.F_Color.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Color').AsString); - self.F_ColorNo.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_ColorNo').AsString); - self.F_Width.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Width').AsString); - self.F_GramWeight.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_GramWeight').AsString); + with ADO2 do + begin + Filtered := False; + Close; + SQL.Clear; + sql.Add(' select * from Finance_Flow where OrderNo=''' + Trim(OrderNo.Text) + ''''); + Open; + end; + SCreateCDS(ADO2, CDS_2); + SInitCDSData(ADO2, CDS_2); + if CDS_2.IsEmpty then + begin + with CDS_2 do + begin + while not eof do + begin + CDS_1.Append; + CDS_1.FieldByName('F_Name').AsString := FieldByName('F_Name').AsString; + CDS_1.FieldByName('F_ColorNo').AsString := FieldByName('F_ColorNo').AsString; + CDS_1.FieldByName('F_Color').AsString := FieldByName('F_Color').AsString; + CDS_1.FieldByName('Currency').AsString := FieldByName('Currency').AsString; + CDS_1.FieldByName('Qty').AsString := FieldByName('Qty').AsString; + CDS_1.FieldByName('QtyUnit').AsString := FieldByName('QtyUnit').AsString; + CDS_1.post; + Next; + end; + end; + end; end; end; @@ -332,10 +365,10 @@ begin end; end; -procedure TfrmReceivableInput.QtyExit(Sender: TObject); -begin - HJJE(); -end; +//procedure TfrmReceivableInput.QtyExit(Sender: TObject); +//begin +// HJJE(); +//end; procedure TfrmReceivableInput.ConNoBtnUpClick(Sender: TObject); begin @@ -365,14 +398,19 @@ begin FAuthority := 'ӵ'; if ShowModal = 1 then begin - self.ConNo.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('ConNo').AsString); - self.F_Code.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Code').AsString); - self.F_Name.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Name').AsString); - self.F_Pattern.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Pattern').AsString); - self.F_Color.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Color').AsString); - self.F_ColorNo.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_ColorNo').AsString); - self.F_Width.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Width').AsString); - self.F_GramWeight.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_GramWeight').AsString); + with frmFinTradePlanSel.CDS_1 do + begin + self.ConNo.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('ConNo').AsString); + self.F_Code.Text := Trim(frmFinTradeSalesContractSel.CDS_1.fieldbyname('C_Code').AsString); + + Fieldbyname('F_Name').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Name').AsString); + Fieldbyname('F_Pattern').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Pattern').AsString); + Fieldbyname('F_ColorNo').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_ColorNo').AsString); + Fieldbyname('F_Width').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Width').AsString); + Fieldbyname('F_GramWeight').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_GramWeight').AsString); + Fieldbyname('F_Color').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Color').AsString); + end; + end; end; finally @@ -380,6 +418,39 @@ begin end; end; +procedure TfrmReceivableInput.ConNoPropertiesChange(Sender: TObject); +begin + with ADO2 do + begin + Filtered := False; + Close; + SQL.Clear; + sql.Add(' select * from Finance_Flow where ConNo=''' + Trim(ConNo.Text) + ''''); + Open; + end; + SCreateCDS(ADO2, CDS_2); + SInitCDSData(ADO2, CDS_2); + if CDS_2.IsEmpty then + begin + with CDS_2 do + begin + while not eof do + begin + CDS_1.Append; + CDS_1.FieldByName('F_Name').AsString := FieldByName('F_Name').AsString; + CDS_1.FieldByName('F_ColorNo').AsString := FieldByName('F_ColorNo').AsString; + CDS_1.FieldByName('F_Color').AsString := FieldByName('F_Color').AsString; + CDS_1.FieldByName('Currency').AsString := FieldByName('Currency').AsString; + CDS_1.FieldByName('Qty').AsString := FieldByName('Qty').AsString; + CDS_1.FieldByName('QtyUnit').AsString := FieldByName('QtyUnit').AsString; + CDS_1.post; + Next; + end; + end; + end; + +end; + procedure TfrmReceivableInput.FFAbstractPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); var fsj: string; @@ -442,13 +513,20 @@ begin FCTType := 'ͨ'; if ShowModal = 1 then begin - self.F_Code.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_Code').AsString); - self.F_Name.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_Name').AsString); - self.F_Pattern.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_Pattern').AsString); - self.F_Color.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_Color').AsString); - self.F_ColorNo.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_ColorNo').AsString); - self.F_Width.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_Width').AsString); - self.F_GramWeight.Text := Trim(frmClothInfoSel.CDS_1.fieldbyname('C_GramWeight').AsString); + with frmFinTradePlanSel.CDS_1 do + begin + + self.F_Code.Text := Trim(frmFinTradePlanSel.CDS_1.fieldbyname('C_Code').AsString); + + Fieldbyname('F_Name').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Name').AsString); + Fieldbyname('F_Pattern').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Pattern').AsString); + Fieldbyname('F_ColorNo').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_ColorNo').AsString); + Fieldbyname('F_Width').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Width').AsString); + Fieldbyname('F_GramWeight').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_GramWeight').AsString); + Fieldbyname('F_Color').value := trim(frmFinTradePlanSel.CDS_1.Fieldbyname('F_Color').AsString); + + end; + end; end; finally @@ -509,6 +587,8 @@ begin FieldByName('OppParentCoNo').Value := Trim(OppParentCoName.Properties.LookupItems.Text); FieldByName('FFID').Value := Trim(MaxId); RTSetsavedata(ADOQueryCmd, 'Finance_Flow', ScrollBox1, 0); + + RTSetSaveDataCDS(ADOQueryCmd, Tv1, CDS_1, 'Finance_Flow', 0); Post; end; @@ -522,9 +602,41 @@ begin end; end; -procedure TfrmReceivableInput.ScrollBox1Click(Sender: TObject); +//procedure TfrmReceivableInput.ScrollBox1Click(Sender: TObject); +//begin +// HJJE(); +//end; + +procedure TfrmReceivableInput.ToolButton1Click(Sender: TObject); begin - HJJE(); + with CDS_1 do + begin + Append; + + FieldByName('QtyUnit').Value := 'Kg'; + FieldByName('Amount').Value := 0; + FieldByName('Qty').Value := 0; + FieldByName('Price').Value := 0; + FieldByName('Currency').Value := 'CNY'; + Post; + end; + +end; + +procedure TfrmReceivableInput.ToolButton2Click(Sender: TObject); +begin + if CDS_1.IsEmpty then + exit; + if application.MessageBox('ȷҪɾ', 'ʾ', 1) = 2 then + exit; + with ADOQueryTemp do + begin + close; + sql.clear; + sql.add('delete from Finance_Flow where FFID=''' + trim(CDS_1.fieldbyname('FFID').asstring) + ''' '); + execsql; + end; + CDS_1.delete; end; procedure TfrmReceivableInput.ToolButton3Click(Sender: TObject); @@ -540,10 +652,11 @@ begin Application.MessageBox('ҷλΪ!', 'ʾ', 0); Exit; end; - if Trim(Currency.Text) = '' then + + if CDS_1.Locate('Currency', null, []) then begin - Application.MessageBox('ֲΪ!', 'ʾ', 0); - Exit; + application.MessageBox('ֲΪ', 'ʾ'); + exit; end; if SaveData() then begin @@ -552,5 +665,66 @@ begin end; end; + + +procedure TfrmReceivableInput.Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean); +var + FValue: string; + FBounds: TRect; +begin + if not (AViewInfo is TcxGridIndicatorRowItemViewInfo) then + Exit; + + // кţ 1 ʼ + FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1); + + // Ʊͱ߿ + FBounds := AViewInfo.ContentBounds; + ACanvas.FillRect(FBounds); + ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bLeft, bBottom, bRight], 1); + + // ı + InflateRect(FBounds, -3, -2); + ACanvas.Font.Color := clWhite; + ACanvas.Brush.Style := bsClear; + ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop); + + ADone := True; +end; + +procedure TfrmReceivableInput.v1QtyPropertiesEditValueChanged(Sender: TObject); +var + mvalue, FFieldName: string; + FQty, FPrice, FAmount: double; +begin + FFieldName := Trim(Tv1.Controller.FocusedColumn.DataBinding.FilterFieldName); + mvalue := TcxTextEdit(Sender).EditingText; + if Trim(mvalue) = '' then + begin + mvalue := '0'; + end; + with CDS_1 do + begin + Edit; + FieldByName(FFieldName).Value := Trim(mvalue); + Post; + FQty := FieldbyName('Qty').AsFloat; + FPrice := FieldByName('price').AsFloat; + end; + + FAmount := strtofloat(format('%.2f', [FQty * FPrice])); + + with CDS_1 do + begin + Edit; + + FieldByName('Amount').Value := FAmount; + + Post; + end; + tv1.Controller.EditingController.ShowEdit(); + +end; + end. diff --git a/T01贸易生产计划/TradePlan.skincfg b/T01贸易生产计划/TradePlan.skincfg index 13b0969..878993d 100644 --- a/T01贸易生产计划/TradePlan.skincfg +++ b/T01贸易生产计划/TradePlan.skincfg @@ -1,7 +1,7 @@ [ExpressSkins] -Default=0 +Default=1 ShowNotifications=1 -Enabled=1 +Enabled=0 dxSkinBasic=1 dxSkinBlack=1 dxSkinBlue=1 diff --git a/T01贸易生产计划/U_TradePlanInPut.dfm b/T01贸易生产计划/U_TradePlanInPut.dfm index 530d5a8..103b072 100644 --- a/T01贸易生产计划/U_TradePlanInPut.dfm +++ b/T01贸易生产计划/U_TradePlanInPut.dfm @@ -2,16 +2,16 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Left = 143 Top = 4 Caption = #29983#20135#35745#21010#21333#24405#20837 - ClientHeight = 808 - ClientWidth = 1722 + ClientHeight = 1118 + ClientWidth = 1809 Font.Charset = GB2312_CHARSET Font.Height = -16 Position = poMainFormCenter WindowState = wsMaximized OnClose = FormClose OnResize = FormResize - ExplicitWidth = 1738 - ExplicitHeight = 847 + ExplicitWidth = 1825 + ExplicitHeight = 1157 PixelsPerInch = 96 TextHeight = 21 object Label51: TLabel [0] @@ -44,7 +44,7 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Tag = 1 Left = 0 Top = 0 - Width = 1722 + Width = 1809 Height = 30 AutoSize = True ButtonHeight = 30 @@ -86,8 +86,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut object ScrollBox1: TScrollBox [3] Left = 0 Top = 30 - Width = 1722 - Height = 335 + Width = 1809 + Height = 203 Align = alTop BevelInner = bvNone BevelOuter = bvNone @@ -96,193 +96,216 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut ParentCtl3D = False TabOrder = 1 object Label3: TLabel - Left = 1410 - Top = -1 + Left = 2604 + Top = 7 Width = 64 Height = 21 Caption = #21046#21333#26085#26399 Visible = False end object Label25: TLabel - Left = 600 - Top = 96 + Left = 1816 + Top = 110 Width = 64 Height = 21 Caption = #23436#24037#26085#26399 + Visible = False end object Label1: TLabel - Left = 13 - Top = 96 + Left = 1229 + Top = 110 Width = 64 Height = 21 Caption = #35745#21010#21333#21495 + Visible = False end object Label2: TLabel - Left = 329 - Top = 96 + Left = 1545 + Top = 110 Width = 48 Height = 21 Caption = #21512#21516#21495 + Visible = False end object Label4: TLabel - Left = 329 - Top = 57 + Left = 1545 + Top = 71 Width = 64 Height = 21 Caption = #23458#25143#21333#21495 + Visible = False end object Label6: TLabel - Left = 329 - Top = 135 + Left = 1545 + Top = 149 Width = 64 Height = 21 Caption = #33394#24067#21517#31216 + Visible = False end object Label8: TLabel - Left = 600 - Top = 174 + Left = 1816 + Top = 188 Width = 32 Height = 21 Caption = #35268#26684 + Visible = False end object Label9: TLabel - Left = 13 - Top = 174 + Left = 1229 + Top = 188 Width = 32 Height = 21 Caption = #25104#20998 + Visible = False end object Label10: TLabel - Left = 879 - Top = 212 + Left = 2095 + Top = 226 Width = 32 Height = 21 Caption = #20811#37325 + Visible = False end object Label11: TLabel - Left = 600 - Top = 212 + Left = 1816 + Top = 226 Width = 64 Height = 21 Caption = #26377#25928#38376#24133 + Visible = False end object Label27: TLabel - Left = 876 - Top = 96 + Left = 2092 + Top = 110 Width = 64 Height = 21 Caption = #25968#37327#21333#20301 + Visible = False end object Label14: TLabel - Left = 329 - Top = 17 + Left = 1545 + Top = 31 Width = 32 Height = 21 Caption = #23458#25143 + Visible = False end object Label20: TLabel - Left = 13 - Top = 14 + Left = 1229 + Top = 28 Width = 64 Height = 21 Caption = #20844#21496#25260#22836 + Visible = False end object lbl17: TLabel - Left = 600 - Top = 57 + Left = 1816 + Top = 71 Width = 48 Height = 21 Caption = #23436#25104#24230 + Visible = False end object Label16: TLabel - Left = 1193 - Top = 245 + Left = 2387 + Top = 259 Width = 32 Height = 21 Caption = #24067#31181 Visible = False end object Label17: TLabel - Left = 1509 - Top = 249 + Left = 2703 + Top = 257 Width = 48 Height = 21 Caption = #21152#24037#21035 Visible = False end object Label18: TLabel - Left = 13 - Top = 212 + Left = 1229 + Top = 226 Width = 80 Height = 21 Caption = #21518#25972#29702#20013#25991 + Visible = False end object Label15: TLabel - Left = 13 - Top = 53 + Left = 1229 + Top = 67 Width = 64 Height = 21 Caption = #35745#21010#31867#22411 + Visible = False end object Label38: TLabel - Left = 876 - Top = 57 + Left = 2092 + Top = 71 Width = 48 Height = 21 Caption = #36319#21333#21592 + Visible = False end object Label37: TLabel - Left = 600 - Top = 18 + Left = 1816 + Top = 32 Width = 48 Height = 21 Caption = #19994#21153#21592 + Visible = False end object lbl24: TLabel - Left = 876 - Top = 18 + Left = 2092 + Top = 32 Width = 32 Height = 21 Caption = #29702#21333 + Visible = False end object Label21: TLabel - Left = 329 - Top = 252 + Left = 1545 + Top = 266 Width = 32 Height = 21 Caption = #32553#25439 + Visible = False end object Label22: TLabel - Left = 13 - Top = 252 + Left = 1229 + Top = 266 Width = 80 Height = 21 Caption = #21518#25972#29702#33521#25991 + Visible = False end object Label29: TLabel - Left = 600 - Top = 252 + Left = 1816 + Top = 266 Width = 64 Height = 21 Caption = #26159#21542#21547#31246 + Visible = False end object Label30: TLabel - Left = 879 - Top = 252 + Left = 2095 + Top = 266 Width = 64 Height = 21 Caption = #20184#27454#26041#24335 + Visible = False end object lbl23: TLabel - Left = 13 - Top = 295 + Left = 1229 + Top = 309 Width = 80 Height = 21 Caption = #19979#21333#31867#22411#65306 + Visible = False end object Label12: TLabel - Left = 1166 - Top = 47 + Left = 2360 + Top = 61 Width = 80 Height = 21 AutoSize = False @@ -290,8 +313,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Visible = False end object Label13: TLabel - Left = 1166 - Top = 86 + Left = 2360 + Top = 100 Width = 80 Height = 21 AutoSize = False @@ -299,79 +322,191 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Visible = False end object Label19: TLabel - Left = 567 - Top = 252 + Left = 1783 + Top = 266 Width = 14 Height = 21 Caption = '%' + Visible = False end object Label23: TLabel - Left = 13 - Top = 135 + Left = 1229 + Top = 149 Width = 64 Height = 21 Caption = #20135#21697#32534#21495 + Visible = False + end + object Label26: TLabel + Left = 15 + Top = 52 + Width = 32 + Height = 21 + Caption = #26631#35782 + Visible = False + end + object Label31: TLabel + Left = 265 + Top = 52 + Width = 48 + Height = 21 + Caption = #35746#21333#21495 + Visible = False + end + object Label32: TLabel + Left = 5 + Top = 94 + Width = 48 + Height = 21 + Caption = #21152#24037#21378 + Visible = False + end + object Label33: TLabel + Left = 262 + Top = 94 + Width = 64 + Height = 21 + Caption = #21152#24037#31867#22411 + Visible = False + end + object Label34: TLabel + Left = 561 + Top = 94 + Width = 78 + Height = 21 + Caption = #25237#22383#19979#38480'%' + Visible = False + end + object Label35: TLabel + Left = 15 + Top = 139 + Width = 32 + Height = 21 + Caption = #22791#27880 + Visible = False + end + object Label36: TLabel + Left = 663 + Top = 139 + Width = 74 + Height = 21 + Caption = #20179#24211'('#22383#24067')' + Visible = False + end + object Label45: TLabel + Left = 877 + Top = 6 + Width = 64 + Height = 21 + Caption = #21333#25454#29366#24577 + Visible = False + end + object Label46: TLabel + Left = 1049 + Top = 6 + Width = 70 + Height = 21 + Caption = #29256#26412#21495'1.1' + Visible = False + end + object Label47: TLabel + Left = 877 + Top = 48 + Width = 64 + Height = 21 + Caption = #21333#25454#32534#21495 + Visible = False + end + object Label48: TLabel + Left = 877 + Top = 89 + Width = 64 + Height = 21 + Caption = #21046#21333#26085#26399 + Visible = False + end + object Label49: TLabel + Left = 693 + Top = 6 + Width = 145 + Height = 38 + Caption = #26579#25972#36890#30693#21333 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -29 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False end object OrderNo: TcxTextEdit Tag = 1 - Left = 123 - Top = 92 + Left = 1339 + Top = 106 TabOrder = 0 + Visible = False Width = 200 end object BuyConNo: TcxTextEdit Tag = 2 - Left = 396 - Top = 51 + Left = 1612 + Top = 65 TabOrder = 1 + Visible = False Width = 200 end object C_Name: TcxTextEdit Tag = 2 - Left = 396 - Top = 129 + Left = 1612 + Top = 143 TabOrder = 2 + Visible = False Width = 475 end object C_Spec: TcxTextEdit Tag = 2 - Left = 673 - Top = 168 + Left = 1889 + Top = 182 TabOrder = 3 + Visible = False Width = 475 end object C_Composition: TcxTextEdit Tag = 2 - Left = 123 - Top = 168 + Left = 1339 + Top = 182 TabOrder = 4 + Visible = False Width = 471 end object C_GramWeight: TcxTextEdit Tag = 2 - Left = 946 - Top = 206 + Left = 2162 + Top = 220 TabOrder = 5 + Visible = False Width = 200 end object C_Width: TcxTextEdit Tag = 2 - Left = 673 - Top = 206 + Left = 1889 + Top = 220 TabOrder = 6 + Visible = False Width = 200 end object ConNo: TcxTextEdit Tag = 2 - Left = 396 - Top = 92 + Left = 1612 + Top = 106 TabOrder = 7 + Visible = False Width = 200 end object OrdDate: TcxDateEdit Tag = 1 - Left = 1480 - Top = 0 + Left = 2674 + Top = 8 Enabled = False ParentFont = False Properties.ShowTime = False @@ -381,16 +516,17 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object DlyDate: TcxDateEdit Tag = 1 - Left = 673 - Top = 92 + Left = 1889 + Top = 106 Properties.ShowTime = False TabOrder = 9 + Visible = False Width = 200 end object CustName: TcxButtonEdit Tag = 1 - Left = 396 - Top = 12 + Left = 1612 + Top = 26 Properties.Buttons = < item Default = True @@ -400,13 +536,14 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Properties.OnButtonClick = CustNamePropertiesButtonClick Style.ButtonStyle = btsDefault TabOrder = 10 + Visible = False OnDblClick = CustNameDblClick Width = 200 end object OurCoName: TcxButtonEdit Tag = 1 - Left = 123 - Top = 12 + Left = 1339 + Top = 26 Properties.Buttons = < item Default = True @@ -416,13 +553,14 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Properties.OnButtonClick = OurCoNamePropertiesButtonClick Style.ButtonStyle = btsDefault TabOrder = 11 + Visible = False OnDblClick = CustNameDblClick Width = 200 end object OrdUnit: TcxComboBox Tag = 2 - Left = 946 - Top = 92 + Left = 2162 + Top = 106 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( 'M' @@ -430,47 +568,50 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut 'Kg') TabOrder = 12 Text = 'M' + Visible = False Width = 200 end object C_Degree: TcxComboBox Tag = 2 - Left = 673 - Top = 51 + Left = 1889 + Top = 65 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( #21322#25104#21697 #25104#21697) TabOrder = 13 Text = #21322#25104#21697 + Visible = False Width = 200 end object GC_Name: TcxTextEdit Tag = 2 - Left = 1303 - Top = 243 + Left = 2497 + Top = 257 TabOrder = 14 Visible = False Width = 200 end object CraftCode: TcxTextEdit Tag = 2 - Left = 1576 - Top = 243 + Left = 2770 + Top = 251 TabOrder = 15 Visible = False Width = 200 end object CraftName: TcxTextEdit Tag = 2 - Left = 123 - Top = 206 + Left = 1339 + Top = 220 TabOrder = 16 + Visible = False Width = 470 end object OrdType: TcxComboBox Tag = 1 - Left = 123 - Top = 51 + Left = 1339 + Top = 65 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( #22823#36135#21333 @@ -478,12 +619,13 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut #24320#21457#21333) TabOrder = 17 Text = #22823#36135#21333 + Visible = False Width = 200 end object Follower: TcxButtonEdit Tag = 4 - Left = 946 - Top = 51 + Left = 2162 + Top = 65 Properties.Buttons = < item Default = True @@ -493,72 +635,76 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Properties.OnButtonClick = FollowerPropertiesButtonClick Style.ButtonStyle = btsDefault TabOrder = 18 + Visible = False OnDblClick = CustNameDblClick Width = 200 end object Saleser: TcxTextEdit Tag = 1 - Left = 673 - Top = 12 + Left = 1889 + Top = 26 Properties.ReadOnly = False TabOrder = 19 + Visible = False Width = 200 end object CraftEName: TcxTextEdit Tag = 2 - Left = 123 - Top = 248 + Left = 1339 + Top = 262 TabOrder = 20 + Visible = False Width = 200 end object SalesId: TcxTextEdit Tag = 1 - Left = 1385 - Top = 84 + Left = 2579 + Top = 92 TabOrder = 21 Visible = False Width = 200 end object TallyId: TcxTextEdit Tag = 1 - Left = 1385 - Top = 123 + Left = 2579 + Top = 131 TabOrder = 22 Visible = False Width = 200 end object DlyNote: TcxTextEdit Tag = 1 - Left = 1385 - Top = 168 + Left = 2579 + Top = 176 TabOrder = 23 Visible = False Width = 200 end object ConDate: TcxTextEdit Tag = 1 - Left = 1385 - Top = 207 + Left = 2579 + Top = 215 TabOrder = 24 Visible = False Width = 200 end object ISTax: TcxComboBox Tag = 1 - Left = 673 - Top = 248 + Left = 1889 + Top = 262 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( #26159 #21542) TabOrder = 25 Text = #26159 + Visible = False Width = 197 end object PayMent: TcxButtonEdit Tag = 1 - Left = 946 - Top = 248 + Left = 2162 + Top = 262 Hint = 'PayMent/'#20184#27454#26041#24335 Properties.Buttons = < item @@ -569,48 +715,51 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Properties.OnButtonClick = QtyNotePropertiesButtonClick Style.ButtonStyle = btsDefault TabOrder = 26 + Visible = False OnDblClick = CustNameDblClick Width = 200 end object OrdReason: TcxComboBox Tag = 1 - Left = 123 - Top = 289 + Left = 1339 + Top = 303 Properties.Items.Strings = ( #27491#24120#29983#20135 #23458#35785#34917#25237) TabOrder = 27 Text = #27491#24120#29983#20135 + Visible = False Width = 200 end object C_EComposition: TcxTextEdit Tag = 2 - Left = 1250 - Top = 41 + Left = 2444 + Top = 55 TabOrder = 28 Visible = False Width = 133 end object C_EName: TcxTextEdit Tag = 2 - Left = 1250 - Top = 80 + Left = 2444 + Top = 94 TabOrder = 29 Visible = False Width = 133 end object ShrinkageRate: TcxCurrencyEdit Tag = 2 - Left = 396 - Top = 248 + Left = 1612 + Top = 262 Properties.AssignedValues.DisplayFormat = True TabOrder = 30 + Visible = False Width = 165 end object Tallyer: TcxButtonEdit Tag = 1 - Left = 946 - Top = 12 + Left = 2162 + Top = 26 Properties.Buttons = < item Default = True @@ -620,29 +769,132 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Properties.OnButtonClick = TallyerPropertiesButtonClick Style.ButtonStyle = btsDefault TabOrder = 31 + Visible = False OnDblClick = TallyerDblClick Width = 200 end object C_Code: TcxTextEdit Tag = 2 - Left = 123 - Top = 129 + Left = 1339 + Top = 143 TabOrder = 32 + Visible = False Width = 200 end + object cxTextEdit1: TcxTextEdit + Tag = 1 + Left = 59 + Top = 47 + Properties.ReadOnly = False + TabOrder = 33 + Visible = False + Width = 200 + end + object cxTextEdit2: TcxTextEdit + Tag = 1 + Left = 335 + Top = 51 + Properties.ReadOnly = False + TabOrder = 34 + Visible = False + Width = 200 + end + object cxTextEdit3: TcxTextEdit + Tag = 1 + Left = 55 + Top = 134 + Properties.ReadOnly = False + TabOrder = 35 + Visible = False + Width = 586 + end + object cxTextEdit4: TcxTextEdit + Tag = 1 + Left = 59 + Top = 89 + Properties.ReadOnly = False + TabOrder = 36 + Visible = False + Width = 200 + end + object cxTextEdit5: TcxTextEdit + Tag = 1 + Left = 335 + Top = 90 + Properties.ReadOnly = False + TabOrder = 37 + Visible = False + Width = 200 + end + object cxTextEdit6: TcxTextEdit + Tag = 1 + Left = 645 + Top = 89 + Properties.ReadOnly = False + TabOrder = 38 + Visible = False + Width = 200 + end + object cxTextEdit7: TcxTextEdit + Tag = 1 + Left = 743 + Top = 134 + Properties.ReadOnly = False + TabOrder = 39 + Visible = False + Width = 200 + end + object cxDateEdit1: TcxDateEdit + Tag = 1 + Left = 965 + Top = 95 + Enabled = False + ParentFont = False + Properties.ShowTime = False + TabOrder = 40 + Visible = False + Width = 236 + end + object cxTextEdit8: TcxTextEdit + Tag = 1 + Left = 963 + Top = 2 + Properties.ReadOnly = False + TabOrder = 41 + Visible = False + Width = 80 + end + object cxTextEdit9: TcxTextEdit + Tag = 1 + Left = 1125 + Top = 2 + Properties.ReadOnly = False + TabOrder = 42 + Visible = False + Width = 58 + end + object cxTextEdit10: TcxTextEdit + Tag = 1 + Left = 963 + Top = 43 + Properties.ReadOnly = False + TabOrder = 43 + Visible = False + Width = 238 + end end object cxPageControl3: TcxPageControl [4] Left = 0 - Top = 365 - Width = 1722 - Height = 443 + Top = 233 + Width = 1809 + Height = 607 Align = alClient TabOrder = 2 Properties.ActivePage = cxTabSheet2 Properties.CustomButtons.Buttons = <> Properties.Style = 9 - ClientRectBottom = 443 - ClientRectRight = 1722 + ClientRectBottom = 607 + ClientRectRight = 1809 ClientRectTop = 28 object cxTabSheet2: TcxTabSheet Caption = ' '#20135#21697#35814#24773' ' @@ -651,7 +903,7 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Tag = 1 Left = 0 Top = 0 - Width = 1722 + Width = 1809 Height = 30 AutoSize = True ButtonHeight = 30 @@ -736,8 +988,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut object cxGrid1: TcxGrid Left = 0 Top = 30 - Width = 1722 - Height = 385 + Width = 1809 + Height = 549 Align = alClient PopupMenu = PM_1 TabOrder = 1 @@ -977,174 +1229,424 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut object ScrollBox2: TScrollBox Left = 0 Top = 30 - Width = 1722 - Height = 385 + Width = 1809 + Height = 549 Align = alClient TabOrder = 0 + ExplicitLeft = 1 + ExplicitTop = 28 object Label5: TLabel - Left = 30 - Top = 62 + Left = 1515 + Top = 159 Width = 87 Height = 21 AutoSize = False Caption = #23545#33394#20809#28304 end object Label52: TLabel - Left = 30 - Top = 23 + Left = 1515 + Top = 120 Width = 87 Height = 21 AutoSize = False Caption = #21152#24037#21378 end object Label53: TLabel - Left = 325 - Top = 23 + Left = 1810 + Top = 120 Width = 87 Height = 21 AutoSize = False Caption = #24037#33402 end object Label54: TLabel - Left = 620 - Top = 23 + Left = 2105 + Top = 120 Width = 87 Height = 21 AutoSize = False Caption = #25163#24863#35201#27714 end object Label55: TLabel - Left = 939 - Top = 23 + Left = 2424 + Top = 120 Width = 87 Height = 21 AutoSize = False Caption = #21387#20809 end object Label56: TLabel - Left = 620 - Top = 62 + Left = 2105 + Top = 159 Width = 87 Height = 21 AutoSize = False Caption = #21442#21333#21495 end object Label57: TLabel - Left = 325 - Top = 62 + Left = 1810 + Top = 159 Width = 87 Height = 21 AutoSize = False Caption = #23545#33394#26041#24335 end object Label58: TLabel - Left = 939 - Top = 62 + Left = 2424 + Top = 159 Width = 87 Height = 21 AutoSize = False Caption = #29615#20445#35201#27714 end object Label59: TLabel - Left = 30 - Top = 101 + Left = 1515 + Top = 198 Width = 87 Height = 21 AutoSize = False Caption = #26159#21542#36215#30385 end object Label60: TLabel - Left = 325 - Top = 101 + Left = 1810 + Top = 198 Width = 87 Height = 21 AutoSize = False Caption = #26579#26426#31867#21035 end object Label61: TLabel - Left = 620 - Top = 101 + Left = 2105 + Top = 198 Width = 87 Height = 21 AutoSize = False Caption = #19981#21547#20598#27694 end object Label62: TLabel - Left = 30 - Top = 216 + Left = 1515 + Top = 313 Width = 80 Height = 21 AutoSize = False Caption = #22791#27880 end object Label63: TLabel - Left = 30 - Top = 140 + Left = 1515 + Top = 237 Width = 87 Height = 21 AutoSize = False Caption = #26641#33026 end object Label64: TLabel - Left = 30 - Top = 179 + Left = 1515 + Top = 276 Width = 87 Height = 21 AutoSize = False Caption = #27700#21387 end object Label65: TLabel - Left = 325 - Top = 179 + Left = 1810 + Top = 276 Width = 87 Height = 21 AutoSize = False Caption = #27700#27927#33394#29282#24230 end object Label66: TLabel - Left = 620 - Top = 140 + Left = 2105 + Top = 237 Width = 87 Height = 21 AutoSize = False Caption = #26580#36719 end object Label67: TLabel - Left = 325 - Top = 140 + Left = 1810 + Top = 237 Width = 87 Height = 21 AutoSize = False Caption = #24179#38754 end object Label68: TLabel - Left = 620 - Top = 179 + Left = 2105 + Top = 276 Width = 87 Height = 21 AutoSize = False Caption = #32553#27700 end object Label69: TLabel - Left = 937 - Top = 140 + Left = 2422 + Top = 237 Width = 87 Height = 21 AutoSize = False Caption = #38450#27700 end object Label70: TLabel - Left = 939 - Top = 179 + Left = 2424 + Top = 276 Width = 87 Height = 21 AutoSize = False Caption = #28034#23618 end + object Label77: TLabel + Left = 56 + Top = 29 + Width = 77 + Height = 21 + Caption = '1.'#23545#33394#20809#28304 + Visible = False + end + object Label78: TLabel + Left = 56 + Top = 79 + Width = 77 + Height = 21 + Caption = '2.'#29282#24230#35201#27714 + Visible = False + end + object Label79: TLabel + Left = 363 + Top = 29 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label80: TLabel + Left = 645 + Top = 29 + Width = 48 + Height = 21 + Caption = #27491#21453#38754 + Visible = False + end + object Label81: TLabel + Left = 363 + Top = 79 + Width = 32 + Height = 21 + Caption = #25163#24863 + Visible = False + end + object Label82: TLabel + Left = 56 + Top = 124 + Width = 77 + Height = 21 + Caption = '3.'#21518#25972#35201#27714 + Visible = False + end + object Label83: TLabel + Left = 163 + Top = 127 + Width = 47 + Height = 21 + Caption = 'A.'#38450#27700 + Visible = False + end + object Label84: TLabel + Left = 295 + Top = 127 + Width = 16 + Height = 21 + Caption = #32423 + Visible = False + end + object Label85: TLabel + Left = 164 + Top = 175 + Width = 46 + Height = 21 + Caption = 'B.'#28034#23618 + Visible = False + end + object Label86: TLabel + Left = 164 + Top = 221 + Width = 79 + Height = 21 + Caption = 'C.'#27700#21387#35201#27714 + Visible = False + end + object Label87: TLabel + Left = 163 + Top = 270 + Width = 48 + Height = 21 + Caption = 'D.'#21387#20809 + Visible = False + end + object Label88: TLabel + Left = 57 + Top = 403 + Width = 32 + Height = 21 + Caption = #22791#27880 + Visible = False + end + object Label89: TLabel + Left = 56 + Top = 312 + Width = 77 + Height = 21 + Caption = '4.'#26579#26009#35201#27714 + Visible = False + end + object Label90: TLabel + Left = 57 + Top = 360 + Width = 45 + Height = 21 + Caption = '5.'#21253#35013 + Visible = False + end + object Label91: TLabel + Left = 159 + Top = 360 + Width = 32 + Height = 21 + Caption = #21253#35013 + Visible = False + end + object Label92: TLabel + Left = 363 + Top = 173 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label94: TLabel + Left = 350 + Top = 219 + Width = 57 + Height = 21 + AutoSize = False + Caption = 'M/H2O' + end + object Label95: TLabel + Left = 454 + Top = 219 + Width = 87 + Height = 21 + AutoSize = False + Caption = #36879#28287#24230#35201#27714 + end + object Label96: TLabel + Left = 295 + Top = 313 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label97: TLabel + Left = 381 + Top = 270 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label98: TLabel + Left = 349 + Top = 127 + Width = 56 + Height = 21 + AutoSize = False + Caption = #25239#25749#35010 + end + object Label99: TLabel + Left = 623 + Top = 127 + Width = 14 + Height = 21 + AutoSize = False + Caption = 'N' + end + object Label100: TLabel + Left = 661 + Top = 79 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label101: TLabel + Left = 454 + Top = 360 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label103: TLabel + Left = 661 + Top = 124 + Width = 32 + Height = 21 + Caption = #20854#20182 + Visible = False + end + object Label93: TLabel + Left = 1094 + Top = 424 + Width = 79 + Height = 21 + Caption = 'A.'#33394#21345#27880#26126 + Visible = False + end + object Label102: TLabel + Left = 1403 + Top = 424 + Width = 32 + Height = 21 + Caption = #23458#25143 + Visible = False + end + object Label104: TLabel + Left = 1102 + Top = 472 + Width = 30 + Height = 21 + Caption = 'B.'#25171 + Visible = False + end + object Label105: TLabel + Left = 1219 + Top = 472 + Width = 16 + Height = 21 + Caption = #33394 + Visible = False + end + object Label106: TLabel + Left = 1269 + Top = 471 + Width = 47 + Height = 21 + Caption = 'C.'#19968#24335 + Visible = False + end + object Label107: TLabel + Left = 1417 + Top = 472 + Width = 16 + Height = 21 + Caption = #20221 + Visible = False + end object OrdNote: TcxMemo Tag = 1 - Left = 120 - Top = 213 + Left = 1605 + Top = 310 TabOrder = 0 OnDblClick = OrdNoteDblClick Height = 83 @@ -1152,8 +1654,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object LightNote: TcxButtonEdit Tag = 1 - Left = 119 - Top = 56 + Left = 1604 + Top = 153 Hint = 'LightNote/'#23545#33394#20809#28304 Properties.Buttons = < item @@ -1169,8 +1671,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object FtyName: TcxButtonEdit Tag = 4 - Left = 119 - Top = 17 + Left = 1604 + Top = 114 Properties.Buttons = < item Default = True @@ -1185,8 +1687,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object OtherProcess1: TcxComboBox Tag = 1 - Left = 117 - Top = 95 + Left = 1602 + Top = 192 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( '' @@ -1197,8 +1699,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object Resin: TcxButtonEdit Tag = 1 - Left = 119 - Top = 134 + Left = 1604 + Top = 231 Hint = 'Resin/'#26641#33026 Properties.Buttons = < item @@ -1214,8 +1716,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object WaterPressure: TcxButtonEdit Tag = 1 - Left = 119 - Top = 173 + Left = 1604 + Top = 270 Hint = 'WaterPressure/'#27700#21387 Properties.Buttons = < item @@ -1231,8 +1733,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object LightType: TcxButtonEdit Tag = 1 - Left = 414 - Top = 56 + Left = 1899 + Top = 153 Hint = 'LightType/'#23545#33394#26041#24335 Properties.Buttons = < item @@ -1248,8 +1750,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object DyeingMach: TcxButtonEdit Tag = 1 - Left = 414 - Top = 95 + Left = 1899 + Top = 192 Hint = 'DyeingMach/'#26579#26426#31867#21035 Properties.Buttons = < item @@ -1265,8 +1767,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object Technics: TcxComboBox Tag = 4 - Left = 412 - Top = 17 + Left = 1897 + Top = 114 Properties.DropDownListStyle = lsFixedList Properties.Items.Strings = ( #26579#33394 @@ -1276,8 +1778,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object plane: TcxButtonEdit Tag = 1 - Left = 412 - Top = 135 + Left = 1897 + Top = 232 Hint = 'plane/'#24179#38754 Properties.Buttons = < item @@ -1293,8 +1795,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object ColourFastness: TcxButtonEdit Tag = 1 - Left = 414 - Top = 174 + Left = 1899 + Top = 271 Hint = 'ColourFastness/'#27700#27927#33394#29282#24230 Properties.Buttons = < item @@ -1310,8 +1812,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object Feel: TcxButtonEdit Tag = 1 - Left = 715 - Top = 17 + Left = 2200 + Top = 114 Hint = 'Feel/'#25163#24863 Properties.Buttons = < item @@ -1327,8 +1829,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object OtherProcess8: TcxButtonEdit Tag = 1 - Left = 713 - Top = 95 + Left = 2198 + Top = 192 Hint = 'OtherProcess8/'#19981#21547#20598#27694 Properties.Buttons = < item @@ -1344,8 +1846,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object ReferenceNumber: TcxButtonEdit Tag = 1 - Left = 713 - Top = 56 + Left = 2198 + Top = 153 Hint = 'ReferenceNumber/'#21442#21333#21495 Properties.Buttons = < item @@ -1361,8 +1863,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object shrink: TcxButtonEdit Tag = 1 - Left = 713 - Top = 174 + Left = 2198 + Top = 271 Hint = 'shrink/'#32553#27700 Properties.Buttons = < item @@ -1378,8 +1880,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object soft: TcxButtonEdit Tag = 1 - Left = 713 - Top = 135 + Left = 2198 + Top = 232 Hint = 'soft/'#26580#36719 Properties.Buttons = < item @@ -1395,8 +1897,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object OtherProcess6: TcxButtonEdit Tag = 1 - Left = 1007 - Top = 17 + Left = 2492 + Top = 114 Hint = 'OtherProcess6/'#36215#30385 Properties.Buttons = < item @@ -1412,8 +1914,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object EnvironmentalProtection: TcxButtonEdit Tag = 1 - Left = 1007 - Top = 56 + Left = 2492 + Top = 153 Hint = 'EnvironmentalProtection/'#29615#20445#35201#27714 Properties.Buttons = < item @@ -1429,8 +1931,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object waterProof: TcxButtonEdit Tag = 1 - Left = 1007 - Top = 134 + Left = 2492 + Top = 231 Hint = 'waterProof/'#38450#27700 Properties.Buttons = < item @@ -1446,8 +1948,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end object coating: TcxButtonEdit Tag = 1 - Left = 1007 - Top = 173 + Left = 2492 + Top = 270 Hint = 'coating/'#28034#23618 Properties.Buttons = < item @@ -1461,12 +1963,215 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut OnDblClick = CustNameDblClick Width = 200 end + object cxComboBox1: TcxComboBox + Left = 172 + Top = 24 + TabOrder = 20 + Width = 121 + end + object cxComboBox2: TcxComboBox + Left = 172 + Top = 74 + TabOrder = 21 + Width = 121 + end + object cxTextEdit14: TcxTextEdit + Tag = 1 + Left = 401 + Top = 24 + Properties.ReadOnly = False + TabOrder = 22 + Visible = False + Width = 200 + end + object cxTextEdit15: TcxTextEdit + Tag = 1 + Left = 699 + Top = 24 + Properties.ReadOnly = False + TabOrder = 23 + Visible = False + Width = 200 + end + object cxTextEdit16: TcxTextEdit + Tag = 1 + Left = 401 + Top = 74 + Properties.ReadOnly = False + TabOrder = 24 + Visible = False + Width = 200 + end + object cxTextEdit17: TcxTextEdit + Tag = 1 + Left = 216 + Top = 122 + Properties.ReadOnly = False + TabOrder = 25 + Visible = False + Width = 73 + end + object cxTextEdit18: TcxTextEdit + Tag = 1 + Left = 216 + Top = 170 + Properties.ReadOnly = False + TabOrder = 26 + Visible = False + Width = 95 + end + object Memo2: TMemo + Left = 57 + Top = 422 + Width = 997 + Height = 89 + Font.Charset = GB2312_CHARSET + Font.Color = clRed + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + Lines.Strings = ( + 'Memo1') + ParentFont = False + TabOrder = 27 + end + object cxTextEdit19: TcxTextEdit + Tag = 1 + Left = 699 + Top = 74 + Properties.ReadOnly = False + TabOrder = 28 + Visible = False + Width = 200 + end + object cxTextEdit20: TcxTextEdit + Tag = 1 + Left = 419 + Top = 265 + Properties.ReadOnly = False + TabOrder = 29 + Visible = False + Width = 200 + end + object cxTextEdit21: TcxTextEdit + Tag = 1 + Left = 333 + Top = 308 + Properties.ReadOnly = False + TabOrder = 30 + Visible = False + Width = 200 + end + object cxTextEdit22: TcxTextEdit + Tag = 1 + Left = 547 + Top = 214 + Properties.ReadOnly = False + TabOrder = 31 + Visible = False + Width = 200 + end + object cxTextEdit23: TcxTextEdit + Tag = 1 + Left = 401 + Top = 168 + Properties.ReadOnly = False + TabOrder = 32 + Visible = False + Width = 200 + end + object cxTextEdit24: TcxTextEdit + Tag = 1 + Left = 207 + Top = 355 + Properties.ReadOnly = False + TabOrder = 33 + Visible = False + Width = 200 + end + object cxTextEdit25: TcxTextEdit + Tag = 1 + Left = 253 + Top = 216 + Properties.ReadOnly = False + TabOrder = 34 + Visible = False + Width = 91 + end + object cxComboBox3: TcxComboBox + Left = 216 + Top = 262 + TabOrder = 35 + Width = 121 + end + object CheckBox1: TCheckBox + Left = 163 + Top = 316 + Width = 97 + Height = 17 + Caption = #19981#21547'AZO' + TabOrder = 36 + end + object cxTextEdit26: TcxTextEdit + Tag = 1 + Left = 401 + Top = 122 + Properties.ReadOnly = False + TabOrder = 37 + Visible = False + Width = 200 + end + object cxTextEdit28: TcxTextEdit + Tag = 1 + Left = 509 + Top = 355 + Properties.ReadOnly = False + TabOrder = 38 + Visible = False + Width = 200 + end + object cxTextEdit30: TcxTextEdit + Tag = 1 + Left = 699 + Top = 119 + Properties.ReadOnly = False + TabOrder = 39 + Visible = False + Width = 200 + end + object cxTextEdit27: TcxTextEdit + Tag = 1 + Left = 1197 + Top = 419 + Properties.ReadOnly = False + TabOrder = 40 + Visible = False + Width = 200 + end + object cxTextEdit29: TcxTextEdit + Tag = 1 + Left = 1138 + Top = 467 + Properties.ReadOnly = False + TabOrder = 41 + Visible = False + Width = 75 + end + object cxTextEdit31: TcxTextEdit + Tag = 1 + Left = 1322 + Top = 465 + Properties.ReadOnly = False + TabOrder = 42 + Visible = False + Width = 75 + end end object ToolBar3: TToolBar Tag = 1 Left = 0 Top = 0 - Width = 1722 + Width = 1809 Height = 30 AutoSize = True ButtonHeight = 30 @@ -1496,8 +2201,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut object cxGrid2: TcxGrid Left = 0 Top = 30 - Width = 1722 - Height = 385 + Width = 1809 + Height = 549 Align = alClient PopupMenu = PM_1 TabOrder = 0 @@ -1622,7 +2327,7 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Tag = 1 Left = 0 Top = 0 - Width = 1722 + Width = 1809 Height = 30 AutoSize = True ButtonHeight = 30 @@ -1664,8 +2369,8 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut Caption = #21367#26631#31614 ParentFont = False TabOrder = 0 - Height = 415 - Width = 937 + Height = 579 + Width = 1024 object cxDBImage4: TcxDBImage Left = 4 Top = 15 @@ -1683,15 +2388,15 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut StyleHot.LookAndFeel.NativeStyle = True TabOrder = 0 OnDblClick = cxDBImage1DblClick - Height = 384 - Width = 929 + Height = 548 + Width = 1016 end end object Panel1: TPanel Left = 0 Top = 0 Width = 785 - Height = 415 + Height = 579 Align = alLeft TabOrder = 1 object lbl1: TLabel @@ -2067,6 +2772,187 @@ inherited frmTradePlanInPut: TfrmTradePlanInPut end end end + object Panel2: TPanel [5] + Left = 0 + Top = 840 + Width = 1809 + Height = 278 + Align = alBottom + TabOrder = 3 + object Label50: TLabel + Left = 22 + Top = 22 + Width = 96 + Height = 21 + Caption = #36136#37327#26816#27979#26631#20934 + Font.Charset = GB2312_CHARSET + Font.Color = clRed + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label71: TLabel + Left = 22 + Top = 166 + Width = 48 + Height = 21 + Caption = #21019#24314#20154 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label72: TLabel + Left = 22 + Top = 214 + Width = 64 + Height = 21 + Caption = #21019#24314#26102#38388 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label73: TLabel + Left = 311 + Top = 166 + Width = 48 + Height = 21 + Caption = #20462#25913#20154 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label74: TLabel + Left = 591 + Top = 166 + Width = 48 + Height = 21 + Caption = #23457#26680#20154 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label75: TLabel + Left = 351 + Top = 214 + Width = 64 + Height = 21 + Caption = #20462#25913#26102#38388 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Label76: TLabel + Left = 673 + Top = 214 + Width = 64 + Height = 21 + Caption = #23457#26680#26102#38388 + Font.Charset = GB2312_CHARSET + Font.Color = clBlack + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + ParentFont = False + Visible = False + end + object Memo1: TMemo + Left = 22 + Top = 57 + Width = 1763 + Height = 89 + Font.Charset = GB2312_CHARSET + Font.Color = clRed + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [] + Lines.Strings = ( + 'Memo1') + ParentFont = False + TabOrder = 0 + end + object cxDateEdit2: TcxDateEdit + Tag = 1 + Left = 92 + Top = 215 + Enabled = False + ParentFont = False + Properties.ShowTime = False + TabOrder = 1 + Visible = False + Width = 236 + end + object cxDateEdit3: TcxDateEdit + Tag = 1 + Left = 421 + Top = 215 + Enabled = False + ParentFont = False + Properties.ShowTime = False + TabOrder = 2 + Visible = False + Width = 236 + end + object cxDateEdit4: TcxDateEdit + Tag = 1 + Left = 751 + Top = 215 + Enabled = False + ParentFont = False + Properties.ShowTime = False + TabOrder = 3 + Visible = False + Width = 236 + end + object cxTextEdit11: TcxTextEdit + Tag = 1 + Left = 76 + Top = 163 + Properties.ReadOnly = False + TabOrder = 4 + Visible = False + Width = 200 + end + object cxTextEdit12: TcxTextEdit + Tag = 1 + Left = 365 + Top = 163 + Properties.ReadOnly = False + TabOrder = 5 + Visible = False + Width = 200 + end + object cxTextEdit13: TcxTextEdit + Tag = 1 + Left = 645 + Top = 163 + Properties.ReadOnly = False + TabOrder = 6 + Visible = False + Width = 200 + end + end inherited ADOQueryBaseCmd: TADOQuery Connection = DataLink_TradePlan.ADOLink Left = 128 diff --git a/T01贸易生产计划/U_TradePlanInPut.pas b/T01贸易生产计划/U_TradePlanInPut.pas index 3f9b577..3ed3465 100644 --- a/T01贸易生产计划/U_TradePlanInPut.pas +++ b/T01贸易生产计划/U_TradePlanInPut.pas @@ -263,6 +263,98 @@ type ToolButton9: TToolButton; Label23: TLabel; C_Code: TcxTextEdit; + cxTextEdit1: TcxTextEdit; + cxTextEdit2: TcxTextEdit; + cxTextEdit3: TcxTextEdit; + cxTextEdit4: TcxTextEdit; + cxTextEdit5: TcxTextEdit; + cxTextEdit6: TcxTextEdit; + cxTextEdit7: TcxTextEdit; + cxDateEdit1: TcxDateEdit; + cxTextEdit8: TcxTextEdit; + cxTextEdit9: TcxTextEdit; + cxTextEdit10: TcxTextEdit; + Label26: TLabel; + Label31: TLabel; + Label32: TLabel; + Label33: TLabel; + Label34: TLabel; + Label35: TLabel; + Label36: TLabel; + Label45: TLabel; + Label46: TLabel; + Label47: TLabel; + Label48: TLabel; + Label49: TLabel; + Panel2: TPanel; + Memo1: TMemo; + Label50: TLabel; + cxDateEdit2: TcxDateEdit; + cxDateEdit3: TcxDateEdit; + cxDateEdit4: TcxDateEdit; + cxTextEdit11: TcxTextEdit; + cxTextEdit12: TcxTextEdit; + cxTextEdit13: TcxTextEdit; + Label71: TLabel; + Label72: TLabel; + Label73: TLabel; + Label74: TLabel; + Label75: TLabel; + Label76: TLabel; + Label77: TLabel; + cxComboBox1: TcxComboBox; + Label78: TLabel; + cxComboBox2: TcxComboBox; + cxTextEdit14: TcxTextEdit; + Label79: TLabel; + Label80: TLabel; + cxTextEdit15: TcxTextEdit; + Label81: TLabel; + cxTextEdit16: TcxTextEdit; + Label82: TLabel; + Label83: TLabel; + cxTextEdit17: TcxTextEdit; + Label84: TLabel; + Label85: TLabel; + cxTextEdit18: TcxTextEdit; + Memo2: TMemo; + Label86: TLabel; + Label87: TLabel; + Label88: TLabel; + cxTextEdit19: TcxTextEdit; + cxTextEdit20: TcxTextEdit; + cxTextEdit21: TcxTextEdit; + cxTextEdit22: TcxTextEdit; + cxTextEdit23: TcxTextEdit; + Label89: TLabel; + Label90: TLabel; + Label91: TLabel; + cxTextEdit24: TcxTextEdit; + Label92: TLabel; + cxTextEdit25: TcxTextEdit; + Label94: TLabel; + Label95: TLabel; + cxComboBox3: TcxComboBox; + Label96: TLabel; + Label97: TLabel; + CheckBox1: TCheckBox; + Label98: TLabel; + cxTextEdit26: TcxTextEdit; + Label99: TLabel; + Label100: TLabel; + Label101: TLabel; + Label103: TLabel; + cxTextEdit28: TcxTextEdit; + cxTextEdit30: TcxTextEdit; + Label93: TLabel; + cxTextEdit27: TcxTextEdit; + Label102: TLabel; + Label104: TLabel; + Label105: TLabel; + Label106: TLabel; + Label107: TLabel; + cxTextEdit29: TcxTextEdit; + cxTextEdit31: TcxTextEdit; procedure TBCloseClick(Sender: TObject); procedure FormShow(Sender: TObject); procedure TBSaveClick(Sender: TObject); @@ -314,6 +406,7 @@ type procedure TallyerPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure TallyerDblClick(Sender: TObject); procedure ToolButton9Click(Sender: TObject); + private FSCXDH: string; procedure InitData(); @@ -1500,6 +1593,8 @@ begin end; end; + + procedure TfrmTradePlanInPut.cxDBImage1DblClick(Sender: TObject); begin if TcxDBImage(Sender).Picture.Height = 0 then diff --git a/T01贸易生产计划/U_TradePlanList.pas b/T01贸易生产计划/U_TradePlanList.pas index beecec5..46337f2 100644 --- a/T01贸易生产计划/U_TradePlanList.pas +++ b/T01贸易生产计划/U_TradePlanList.pas @@ -15,23 +15,7 @@ uses IdFTP, ShellAPI, cxDropDownEdit, cxCheckBox, RM_e_Graphic, RM_e_Jpeg, U_BaseList, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxDateRanges, dxScrollbarAnnotations, dxBarBuiltInMenu, IdExplicitTLSClientServerBase, - FrameDateSel, cxProgressBar, dxSkinsDefaultPainters, dxSkinsCore, dxSkinBasic, - dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, - dxSkinDarkroom, dxSkinDarkSide, dxSkinDevExpressDarkStyle, - dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, - dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, - dxSkinMcSkin, dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins, - dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green, - dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black, - dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, - dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinOffice2016Colorful, - dxSkinOffice2016Dark, dxSkinOffice2019Black, dxSkinOffice2019Colorful, - dxSkinOffice2019DarkGray, dxSkinOffice2019White, dxSkinPumpkin, dxSkinSeven, - dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, - dxSkinSpringtime, dxSkinStardust, dxSkinSummer2008, dxSkinTheAsphaltWorld, - dxSkinTheBezier, dxSkinValentine, dxSkinVisualStudio2013Blue, - dxSkinVisualStudio2013Dark, dxSkinVisualStudio2013Light, dxSkinVS2010, - dxSkinWhiteprint, dxSkinWXI, dxSkinXmas2008Blue; + FrameDateSel, cxProgressBar; type TfrmTradePlanList = class(TfrmBaseList) diff --git a/T02贸易汇总仓库/U_ItemizedListInPut.dfm b/T02贸易汇总仓库/U_ItemizedListInPut.dfm index 82dfa2d..bcccc22 100644 --- a/T02贸易汇总仓库/U_ItemizedListInPut.dfm +++ b/T02贸易汇总仓库/U_ItemizedListInPut.dfm @@ -7,8 +7,8 @@ inherited frmItemizedListInPut: TfrmItemizedListInPut Font.Charset = GB2312_CHARSET Font.Height = -16 Position = poMainFormCenter - ExplicitWidth = 1248 - ExplicitHeight = 624 + ExplicitWidth = 1256 + ExplicitHeight = 632 PixelsPerInch = 96 TextHeight = 21 object ToolBar1: TToolBar [0] @@ -133,6 +133,8 @@ inherited frmItemizedListInPut: TfrmItemizedListInPut Align = alClient PopupMenu = PopupMenu2 TabOrder = 0 + ExplicitLeft = 2 + ExplicitTop = 5 object Tv1: TcxGridDBTableView OnDblClick = Tv1DblClick OnMouseDown = Tv1MouseDown @@ -353,7 +355,6 @@ inherited frmItemizedListInPut: TfrmItemizedListInPut Ctl3D = False ParentCtl3D = False TabOrder = 3 - ExplicitTop = 24 object Label3: TLabel Left = 377 Top = 11 diff --git a/T02贸易汇总仓库/U_ItemizedListList.dfm b/T02贸易汇总仓库/U_ItemizedListList.dfm index 8122820..71241a4 100644 --- a/T02贸易汇总仓库/U_ItemizedListList.dfm +++ b/T02贸易汇总仓库/U_ItemizedListList.dfm @@ -9,8 +9,8 @@ inherited frmItemizedListList: TfrmItemizedListList FormStyle = fsMDIChild Position = poScreenCenter Visible = True - ExplicitWidth = 1548 - ExplicitHeight = 767 + ExplicitWidth = 1556 + ExplicitHeight = 775 PixelsPerInch = 96 TextHeight = 21 object ToolBar1: TToolBar [0] diff --git a/T03贸易布匹检验/U_MachRollMain.dfm b/T03贸易布匹检验/U_MachRollMain.dfm index 6aa668d..120a320 100644 --- a/T03贸易布匹检验/U_MachRollMain.dfm +++ b/T03贸易布匹检验/U_MachRollMain.dfm @@ -559,6 +559,15 @@ inherited frmMachRollMain: TfrmMachRollMain TabOrder = 31 OnClick = Button1Click end + object ToolButton2: TButton + Left = 309 + Top = 388 + Width = 150 + Height = 68 + Caption = #25171#21360#24211#23384#26631#31614 + TabOrder = 32 + OnClick = ToolButton2Click + end end object Panel_right: TPanel [1] Left = 499 @@ -886,7 +895,7 @@ inherited frmMachRollMain: TfrmMachRollMain Height = 30 AutoSize = True ButtonHeight = 30 - ButtonWidth = 131 + ButtonWidth = 83 Caption = 'ToolBar1' DoubleBuffered = False EdgeInner = esNone @@ -905,23 +914,15 @@ inherited frmMachRollMain: TfrmMachRollMain OnClick = ToolButton3Click end object Trolldel: TToolButton - Left = 71 + Left = 63 Top = 0 AutoSize = True Caption = #21024#38500 ImageIndex = 5 OnClick = TrolldelClick end - object ToolButton2: TToolButton - Left = 142 - Top = 0 - AutoSize = True - Caption = #25171#21360#24211#23384#26631#31614 - ImageIndex = 21 - OnClick = ToolButton2Click - end object ToolButton1: TToolButton - Left = 277 + Left = 126 Top = 0 AutoSize = True Caption = #25171#21367#35774#32622 @@ -929,14 +930,14 @@ inherited frmMachRollMain: TfrmMachRollMain OnClick = ToolButton1Click end object Tlog: TToolButton - Left = 380 + Left = 213 Top = 0 AutoSize = True Caption = #26085#24535 ImageIndex = 30 end object ToolButton8: TToolButton - Left = 451 + Left = 276 Top = 0 AutoSize = True Caption = #20851#38381 @@ -966,14 +967,13 @@ inherited frmMachRollMain: TfrmMachRollMain TabOrder = 0 ExplicitLeft = 4 ExplicitTop = 23 - ExplicitWidth = 311 - ExplicitHeight = 206 + ExplicitWidth = 319 + ExplicitHeight = 246 inherited dxPanel1: TdxPanel Width = 319 Height = 246 - ExplicitTop = -8 - ExplicitWidth = 311 - ExplicitHeight = 261 + ExplicitWidth = 319 + ExplicitHeight = 246 inherited SpeedButton1: TSpeedButton OnClick = FrameKeyBoard1SpeedButton1Click end diff --git a/T03贸易布匹检验/U_MachRollMain.pas b/T03贸易布匹检验/U_MachRollMain.pas index f7dac8e..9a9c9e3 100644 --- a/T03贸易布匹检验/U_MachRollMain.pas +++ b/T03贸易布匹检验/U_MachRollMain.pas @@ -152,10 +152,10 @@ type ToolBar2: TToolBar; ToolButton3: TToolButton; Trolldel: TToolButton; - ToolButton2: TToolButton; ToolButton1: TToolButton; Tlog: TToolButton; ToolButton8: TToolButton; + ToolButton2: TButton; procedure FormCreate(Sender: TObject); procedure FormShow(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); diff --git a/T05贸易门市管理/TradeMarket.dpr b/T05贸易门市管理/TradeMarket.dpr index ab7fdd0..c648721 100644 --- a/T05贸易门市管理/TradeMarket.dpr +++ b/T05贸易门市管理/TradeMarket.dpr @@ -41,7 +41,10 @@ uses U_TradeDispatchedList in 'U_TradeDispatchedList.pas' {frmTradeDispatchedList}, U_TradeMarketDisSel in 'U_TradeMarketDisSel.pas' {frmTradeMarketDisSel}, U_ComContactSel in '..\A00ͨô\U_ComContactSel.pas' {frmComContactSel}, - U_ProgressUpdate in '..\A00ͨ÷\U_ProgressUpdate.pas'; + U_ProgressUpdate in '..\A00ͨ÷\U_ProgressUpdate.pas', + U_RPFun in '..\..\..\public10\ThreeFun\Fun\U_RPFun.pas', + U_TradeMarketQtyInPut in 'U_TradeMarketQtyInPut.pas', + U_ItemizedListQtyInPut in '..\T02ó׻ֿܲ\U_ItemizedListQtyInPut.pas' {frmItemizedListQtyInPut}; {$R *.res} diff --git a/T05贸易门市管理/TradeMarket.dproj b/T05贸易门市管理/TradeMarket.dproj index b2dc92a..04b894e 100644 --- a/T05贸易门市管理/TradeMarket.dproj +++ b/T05贸易门市管理/TradeMarket.dproj @@ -233,6 +233,12 @@ dfm + + + +
frmItemizedListQtyInPut
+ dfm +
Cfg_2 Base diff --git a/T05贸易门市管理/TradeMarket.skincfg b/T05贸易门市管理/TradeMarket.skincfg index 97161c0..0cb7585 100644 --- a/T05贸易门市管理/TradeMarket.skincfg +++ b/T05贸易门市管理/TradeMarket.skincfg @@ -1,7 +1,7 @@ [ExpressSkins] -Default=0 +Default=1 ShowNotifications=1 -Enabled=1 +Enabled=0 dxSkinsDefaultPainters=1 dxSkinBasic=1 dxSkinBlack=1 diff --git a/T05贸易门市管理/U_GetDllForm.pas b/T05贸易门市管理/U_GetDllForm.pas index 2bca3ba..4218911 100644 --- a/T05贸易门市管理/U_GetDllForm.pas +++ b/T05贸易门市管理/U_GetDllForm.pas @@ -75,7 +75,8 @@ begin pswd := 'rightsoft@5740'; DConString := 'Provider=SQLOLEDB.1;Password=' + pswd + ';Persist Security Info=True;User ID=' + user + ';Initial Catalog=' + dtbase + ';Data Source=' + server; // DParameters1:='Ȩ'; - Parameters1 := ''; + //Parameters1 := ''; + Parameters1 := 'ѯ'; // Parameters2 := '֯'; Parameters4 := ''; DCode := 'ADMIN'; diff --git a/T05贸易门市管理/U_TradeMarketInPut.dfm b/T05贸易门市管理/U_TradeMarketInPut.dfm index 95afb8e..9cc96e2 100644 --- a/T05贸易门市管理/U_TradeMarketInPut.dfm +++ b/T05贸易门市管理/U_TradeMarketInPut.dfm @@ -8,6 +8,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Font.Height = -16 Position = poMainFormCenter WindowState = wsMaximized + OnClose = FormClose ExplicitWidth = 1937 ExplicitHeight = 775 PixelsPerInch = 96 @@ -54,15 +55,37 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut ImageIndex = 7 OnClick = TBCloseClick end + object TBAdd: TToolButton + Left = 268 + Top = 0 + AutoSize = True + Caption = #26032#22686 + ImageIndex = 2 + OnClick = TBAddClick + end + object ToolButton6: TToolButton + Left = 339 + Top = 0 + AutoSize = True + Caption = #21024#38500 + ImageIndex = 6 + end + object TBEdit: TToolButton + Left = 410 + Top = 0 + AutoSize = True + Caption = #20462#25913 + ImageIndex = 3 + end end object ToolBar2: TToolBar [1] Tag = 1 Left = 0 Top = 193 Width = 1921 - Height = 24 + Height = 30 ButtonHeight = 30 - ButtonWidth = 67 + ButtonWidth = 99 Caption = 'ToolBar1' EdgeInner = esNone EdgeOuter = esNone @@ -86,12 +109,19 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut ImageIndex = 6 OnClick = ToolButton2Click end + object ToolButton5: TToolButton + Left = 142 + Top = 0 + Caption = #19968#38190#26367#25442 + ImageIndex = 30 + OnClick = ToolButton5Click + end end object Panel2: TPanel [2] Left = 0 - Top = 217 + Top = 223 Width = 1921 - Height = 519 + Height = 513 Align = alClient Caption = 'Panel2' TabOrder = 2 @@ -99,7 +129,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Left = 1 Top = 1 Width = 1633 - Height = 517 + Height = 511 Align = alClient Caption = 'Panel2' TabOrder = 0 @@ -107,13 +137,17 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Left = 1 Top = 1 Width = 1631 - Height = 515 + Height = 509 Align = alClient TabOrder = 0 + ExplicitLeft = -4 + ExplicitTop = -1 object Tv1: TcxGridDBTableView + OnDblClick = Tv1DblClick OnMouseDown = Tv1MouseDown Navigator.Buttons.CustomButtons = <> ScrollbarAnnotations.CustomAnnotations = <> + OnCellDblClick = Tv1CellDblClick OnFocusedRecordChanged = Tv1FocusedRecordChanged DataController.DataSource = DS_1 DataController.Filter.AutoDataSetFilter = True @@ -201,7 +235,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Properties.ListSource = DS_PM Properties.OnEditValueChanged = Tv1Column7PropertiesEditValueChanged HeaderAlignmentHorz = taCenter - Width = 77 + Width = 149 end object v1PRTColor: TcxGridDBColumn Caption = #39068#33394 @@ -238,7 +272,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Properties.ListSource = DS_YS Properties.OnEditValueChanged = Tv1Column12PropertiesEditValueChanged HeaderAlignmentHorz = taCenter - Width = 77 + Width = 168 end object Tv1Column9: TcxGridDBColumn Caption = #35268#26684 @@ -290,14 +324,6 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut HeaderAlignmentHorz = taCenter Width = 77 end - object Tv1Column8: TcxGridDBColumn - Caption = #24211#23384#21333#20301 - DataBinding.FieldName = 'TMSUnit' - DataBinding.IsNullValueType = True - HeaderAlignmentHorz = taCenter - Options.Editing = False - Width = 77 - end object Tv1Column4: TcxGridDBColumn Caption = #21333#20215 DataBinding.FieldName = 'Price' @@ -305,6 +331,35 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut HeaderAlignmentHorz = taCenter Width = 77 end + object Tv1Column21: TcxGridDBColumn + Caption = #21442#32771#20215#26684 + DataBinding.FieldName = 'referencePrice' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 98 + end + object Tv1Column22: TcxGridDBColumn + Caption = #21382#21490#20215#26684 + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 83 + end + object Tv1Column8: TcxGridDBColumn + Caption = #22791#36135#21333#20301 + DataBinding.FieldName = 'TMSUnit' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 77 + end + object Tv1Column20: TcxGridDBColumn + Tag = 22 + Caption = #24403#21069#24211#23384 + DataBinding.FieldName = 'StkQty' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Width = 98 + end object Tv1Column6: TcxGridDBColumn Caption = #21253#32568#36153 DataBinding.FieldName = 'GangFee' @@ -360,6 +415,15 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut HeaderAlignmentHorz = taCenter Width = 77 end + object Tv1Column19: TcxGridDBColumn + Tag = 2 + Caption = #20986#24211#25968#37327 + DataBinding.FieldName = 'Qty' + DataBinding.IsNullValueType = True + HeaderAlignmentHorz = taCenter + Options.Editing = False + Width = 89 + end end object cxGrid1Level1: TcxGridLevel GridView = Tv1 @@ -370,7 +434,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Left = 1634 Top = 1 Width = 286 - Height = 517 + Height = 511 Align = alRight Caption = 'Panel4' TabOrder = 1 @@ -407,7 +471,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Left = 1 Top = 42 Width = 284 - Height = 474 + Height = 468 Align = alClient Caption = #21452#20987#21024#38500#26126#32454#20449#24687 TabOrder = 1 @@ -415,7 +479,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Left = 2 Top = 23 Width = 280 - Height = 449 + Height = 443 Align = alClient TabOrder = 0 object TvMX: TcxGridDBTableView @@ -460,7 +524,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut OptionsView.IndicatorWidth = 33 object cxGridDBColumn8: TcxGridDBColumn Caption = #25968#37327 - DataBinding.FieldName = 'Qty' + DataBinding.FieldName = 'Qty1' DataBinding.IsNullValueType = True PropertiesClassName = 'TcxTextEditProperties' Properties.Alignment.Horz = taCenter @@ -666,6 +730,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut Width = 200 end object CustName: TcxMRUEdit + Tag = 2 Left = 122 Top = 15 Properties.ImmediatePost = True @@ -876,7 +941,7 @@ inherited frmTradeMarketInPut: TfrmTradeMarketInPut OnClick = N5Click end object N1: TMenuItem - Caption = #20445#23384#21518#31435#21363#23457#26680 + Caption = #20445#23384#21518#31435#21363#23436#25104#13#10 OnClick = N1Click end object N2: TMenuItem diff --git a/T05贸易门市管理/U_TradeMarketInPut.pas b/T05贸易门市管理/U_TradeMarketInPut.pas index 770835e..77cdaa3 100644 --- a/T05贸易门市管理/U_TradeMarketInPut.pas +++ b/T05贸易门市管理/U_TradeMarketInPut.pas @@ -130,6 +130,14 @@ type N5: TMenuItem; Label19: TLabel; CONTACT: TcxButtonEdit; + Tv1Column19: TcxGridDBColumn; + Tv1Column20: TcxGridDBColumn; + ToolButton5: TToolButton; + Tv1Column21: TcxGridDBColumn; + Tv1Column22: TcxGridDBColumn; + TBAdd: TToolButton; + ToolButton6: TToolButton; + TBEdit: TToolButton; procedure TBCloseClick(Sender: TObject); procedure FormShow(Sender: TObject); procedure TBSaveClick(Sender: TObject); @@ -170,6 +178,11 @@ type procedure N5Click(Sender: TObject); procedure CustNameMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); procedure CustNamePropertiesCloseUp(Sender: TObject); + procedure Tv1DblClick(Sender: TObject); + procedure ToolButton5Click(Sender: TObject); + procedure FormClose(Sender: TObject; var Action: TCloseAction); + procedure Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean); + procedure TBAddClick(Sender: TObject); private FSCXDH: string; procedure InitData(); @@ -184,12 +197,14 @@ type { Private declarations } public PState, CopyInt, PriceFlag: Integer; - FTMMID, FFTMMID, FTMMNo, MTMSId: string; + FTMMID, FTMMNo, MTMSId: string; FXS: Integer; btnFlag: Integer; canshu1, canshu4: string; fFlileFlag: string; fordtype: string; + FName, FColor, FColorNo: string; + FTIMID: string; { Public declarations } end; @@ -202,7 +217,7 @@ implementation uses U_DataLink, U_ZDYHelp, U_ZDYHelpSel, U_RTFun, U_CompanySel, U_PictureUpload, U_ProgressUpdate, U_ClothInfoSel, U_ComContactSel, U_TradeMarketList, - U_LabelPrint; + U_LabelPrint, U_TradeMarketQtyInPut; {$R *.dfm} @@ -274,6 +289,19 @@ begin result := str1; end; +procedure TfrmTradeMarketInPut.TBAddClick(Sender: TObject); +begin + CDS_1.Close; + InitData(); + SClearData(ScrollBox1, 2); //пؼ + CustName.Text := ''; + if CDS_1.IsEmpty then + begin + AddLine(); + end; + +end; + procedure TfrmTradeMarketInPut.TBCloseClick(Sender: TObject); begin @@ -308,16 +336,20 @@ begin begin Close; SQL.Clear; - sql.Add(' select * from Trade_Market_Sub where 1=1 '); + sql.Add(' select A.*,StkQty = isnull(B.StkQty,0),C.QTY from Trade_Market_Sub A left join Bs_Cloth_IO B on A.C_Code=B.C_Code '); + SQL.ADD('left join Trade_Market_Sub_Qty C on A.TMSID=C.TMSID'); + SQL.adD('where 1=1 '); if PState = 1 then begin - sql.Add(' and TMMID=''' + Trim(FTMMID) + ''''); + sql.Add(' and C.TMMID=''' + Trim(FTMMID) + ''''); end; if PState = 0 then begin sql.Add(' and 1<>1'); end; + ShowMessage(SQL.TEXT); Open; + end; SCreateCDS(ADO_1, CDS_1); SInitCDSData(ADO_1, CDS_1); @@ -368,6 +400,12 @@ var begin end; +procedure TfrmTradeMarketInPut.FormClose(Sender: TObject; var Action: TCloseAction); +begin + inherited; + Action := CAFREE; +end; + procedure TfrmTradeMarketInPut.FormCreate(Sender: TObject); begin inherited; @@ -429,14 +467,17 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,A.C_Name,A.qtyunit,B.Price FROM Bs_Cloth_Info A left join Trade_Market_Sub B on A.C_Code=B.C_Code order by HotQty desc '); + sql.Add(' SELECT distinct A.C_Code,A.C_Name,A.qtyunit,A.HotQty,StkQty = SUM(B.StkQty) '); + SQL.ADD(' FROM Bs_Cloth_Info A LEFT JOIN Bs_Cloth_Io B on A.C_Code=B.C_Code'); + SQL.add('group by A.C_Code,A.C_Name,A.qtyunit,A.HotQty'); + SQL.ADD('order by A.C_Code '); Open; end; with ADO_YS do begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.C_Color,B.C_ColorNo FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' SELECT distinct A.C_Code,B.C_Color,B.C_ColorNo,B.referencePrice AS Price FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); sql.Add(' where 1=2 '); Open; end; @@ -445,14 +486,14 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT C_GYSNAME FROM BS_Cloth_Info_GYSCP '); + sql.Add(' SELECT distinct C_GYSNAME FROM BS_Cloth_Info_GYSCP '); Open; end; with ADO_DanWei do begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.CICUnit FROM Bs_Cloth_Info A inner join Bs_Cloth_Info_Coefficient B on A.BCIID=B.BCIID '); + sql.Add(' SELECT distinct A.C_Code,B.CICUnit FROM Bs_Cloth_Info A inner join Bs_Cloth_Info_Coefficient B on A.BCIID=B.BCIID '); sql.Add(' where 2=1 '); Open; end; @@ -501,8 +542,8 @@ begin Append; FieldByName('FillId').Value := Trim(DCode); FieldByName('Filler').Value := Trim(DName); - if btnFlag = 1 then // - FieldByName('status').Value := Trim('9'); + if btnFlag = 1 then // + FieldByName('status').Value := Trim('10'); if btnFlag = 5 then //ύ FieldByName('status').Value := Trim('1'); end @@ -554,8 +595,8 @@ begin else Edit; RTSetSaveDataCDS(ADOCmd, Tv1, CDS_1, 'Trade_Market_Sub', 0); - - RTSetsavedata(ADOCmd, 'Trade_Market_Sub', ScrollBox1, 7); + //RTSetSaveDataCDS(ADOCmd, Tv1, CDS_1, 'Trade_Market_Sub_Qty', 2); + //RTSetsavedata(ADOCmd, 'Trade_Market_Sub', ScrollBox1, 7); FieldByName('TMMID').Value := Trim(maxno); FieldByName('TMSId').Value := Trim(Smaxno); Post; @@ -565,6 +606,7 @@ begin end; ///////////////////// ӱ /////////////////////////// + with ADOCmd do begin Close; @@ -682,6 +724,21 @@ begin Application.MessageBox('ɫΪ!', 'ʾ', 0); Exit; end; + if CDS_1.Locate('OrderQty', null, []) then + begin + Application.MessageBox('Ϊ!', 'ʾ', 0); + Exit; + end; + if CDS_1.Locate('OrderUnit', null, []) then + begin + Application.MessageBox('λΪ!', 'ʾ', 0); + Exit; + end; + if CDS_1.Locate('Price', null, []) then + begin + Application.MessageBox('۲Ϊ!', 'ʾ', 0); + Exit; + end; if not CDS_KH.Locate('CoAbbrName', self.CustName.Text, []) then begin Application.MessageBox('ͻ!', 'ʾ', 0); @@ -854,6 +911,13 @@ begin end; +procedure TfrmTradeMarketInPut.ToolButton5Click(Sender: TObject); +begin + if CDS_1.IsEmpty then + Exit; + OneKeyPost(Tv1, CDS_1); +end; + procedure TfrmTradeMarketInPut.edtGYBtnUpClick(Sender: TObject); var fsj: string; @@ -935,8 +999,10 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.C_Color,B.C_ColorNo FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' SELECT DISTINCT A.C_Code,B.C_Color,B.C_ColorNo,B.referencePrice AS Price FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); sql.Add(' where A.C_Code= ' + QuotedStr(CDS_1.FieldByName('C_Code').AsString)); + SQL.ADD(' order by B.C_ColorNo'); + //ShowMessage(sql.text); Open; end; end; @@ -947,8 +1013,9 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.C_Color,B.C_ColorNo FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' SELECT DISTINCT A.C_Code,B.C_Color,B.C_ColorNo,B.referencePrice AS Price FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); sql.Add(' where A.C_Code= ' + QuotedStr(CDS_1.FieldByName('C_Code').AsString)); + SQL.ADD(' order by B.C_ColorNo'); Open; end; end; @@ -1371,6 +1438,45 @@ begin end; end; +procedure TfrmTradeMarketInPut.Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean); +var + AColumn: TcxGridColumn; +begin + // ȡ˫ + AColumn := ACellViewInfo.Item as TcxGridColumn; + + // Ƿ˫ Qty Уͨжϣ + if AColumn.Name = 'Tv1Column19' then + begin + + if not CDS_1.IsEmpty then + begin + // ȡǰеID + Self.MTMSId := CDS_1.FieldByName('TMSId').AsString; + Self.FTMMID := CDS_1.FieldByName('TMMId').AsString; + + try + frmTradeMarketQtyInPut := TfrmTradeMarketQtyInPut.Create(Application); + with frmTradeMarketQtyInPut do + begin + MTMSId := Self.MTMSId; + FTMMID := Self.FTMMID; + + if ShowModal = 1 then + begin + Self.InitMXGrid(Self.MTMSID); + + end; + end; + finally + FreeAndNil(frmTradeMarketQtyInPut); + end; + + AHandled := True; + end; + end; +end; + procedure TfrmTradeMarketInPut.Tv1Column12PropertiesEditValueChanged(Sender: TObject); var mvalue, FFieldName: string; @@ -1386,6 +1492,7 @@ begin ADO_YS.Locate('C_ColorNo', mvalue, []); Edit; FieldByName('C_Color').Value := ADO_YS.FieldByName('C_Color').Value; + FieldByName('price').Value := ADO_YS.FieldByName('price').Value; Post; end; end; @@ -1470,7 +1577,8 @@ begin Edit; FieldByName('C_Code').Value := ADO_PM.FieldByName('C_Code').Value; FieldByName('TMSUnit').Value := ADO_PM.FieldByName('qtyunit').Value; - FieldByName('price').Value := ADO_PM.FieldByName('price').Value; + + FieldByName('StkQty').Value := ADO_PM.FieldByName('StkQty').Value; Post; end; @@ -1497,6 +1605,28 @@ begin end; +procedure TfrmTradeMarketInPut.Tv1DblClick(Sender: TObject); +var + MTMSQID: string; +begin + +// try +// frmTradeMarketQtyInPut := TfrmTradeMarketQtyInPut.Create(Application); +// with frmTradeMarketQtyInPut do +// begin +// MTMSId := self.MTMSId; +// FTMMID := Self.FTMMID; +// if ShowModal = 1 then +// begin +//// Self.InitMXGrid(Self.MTMSQID); +// end; +// end; +// finally +// frmTradeMarketQtyInPut.Free; +// end; + +end; + procedure TfrmTradeMarketInPut.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean); begin inherited; @@ -1516,8 +1646,10 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.C_Color,B.C_ColorNo FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' SELECT DISTINCT A.C_Code,B.C_Color,B.C_ColorNo,B.referencePrice AS Price FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' where A.C_Code= ' + QuotedStr(CDS_1.FieldByName('C_Code').AsString)); + SQL.ADD(' order by B.C_ColorNo'); Open; end; end; @@ -1528,8 +1660,10 @@ begin begin Close; sql.Clear; - sql.Add(' SELECT A.C_Code,B.C_Color,B.C_ColorNo FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' SELECT DISTINCT A.C_Code,B.C_Color,B.C_ColorNo,B.referencePrice AS Price FROM Bs_Cloth_Info A inner join BS_Cloth_Info_Sub B on A.BCIID=B.BCIID '); + sql.Add(' where A.C_Code= ' + QuotedStr(CDS_1.FieldByName('C_Code').AsString)); + SQL.ADD(' order by B.C_ColorNo'); Open; end; end; diff --git a/T05贸易门市管理/U_TradeMarketList.dfm b/T05贸易门市管理/U_TradeMarketList.dfm index 75538f1..53497c5 100644 --- a/T05贸易门市管理/U_TradeMarketList.dfm +++ b/T05贸易门市管理/U_TradeMarketList.dfm @@ -103,28 +103,12 @@ inherited frmTradeMarketList: TfrmTradeMarketList Left = 639 Top = 0 AutoSize = True - Caption = #25552#20132#25764#38144 + Caption = #25764#38144#25552#20132 ImageIndex = 11 OnClick = TBTJCXClick end - object Tchk: TToolButton - Left = 742 - Top = 0 - AutoSize = True - Caption = #23457#26680 - ImageIndex = 12 - OnClick = TchkClick - end - object Tnochk: TToolButton - Left = 813 - Top = 0 - AutoSize = True - Caption = #25764#38144#23457#26680 - ImageIndex = 11 - OnClick = TnochkClick - end object TWC: TToolButton - Left = 916 + Left = 742 Top = 0 AutoSize = True Caption = #23436#25104 @@ -132,7 +116,7 @@ inherited frmTradeMarketList: TfrmTradeMarketList OnClick = TWCClick end object TNowc: TToolButton - Left = 987 + Left = 813 Top = 0 AutoSize = True Caption = #25764#38144#23436#25104 @@ -140,7 +124,7 @@ inherited frmTradeMarketList: TfrmTradeMarketList OnClick = TNowcClick end object ToolButton2: TToolButton - Left = 1090 + Left = 916 Top = 0 AutoSize = True Caption = #20445#23384#26684#24335 @@ -148,7 +132,7 @@ inherited frmTradeMarketList: TfrmTradeMarketList OnClick = ToolButton2Click end object ToolButton1: TToolButton - Left = 1193 + Left = 1019 Top = 0 AutoSize = True Caption = #23548#20986 @@ -156,13 +140,29 @@ inherited frmTradeMarketList: TfrmTradeMarketList OnClick = ToolButton1Click end object TBClose: TToolButton - Left = 1264 + Left = 1090 Top = 0 AutoSize = True Caption = #20851#38381 ImageIndex = 7 OnClick = TBCloseClick end + object TBZF: TToolButton + Left = 1161 + Top = 0 + AutoSize = True + Caption = #20316#24223 + ImageIndex = 31 + OnClick = TBZFClick + end + object TBNOZF: TToolButton + Left = 1232 + Top = 0 + AutoSize = True + Caption = #25764#38144#20316#24223 + ImageIndex = 11 + OnClick = TBNOZFClick + end end object Panel1: TPanel [1] Left = 0 @@ -265,6 +265,7 @@ inherited frmTradeMarketList: TfrmTradeMarketList PopupMenu = PM_1 TabOrder = 3 object Tv1: TcxGridDBTableView + OnDblClick = Tv1DblClick Navigator.Buttons.CustomButtons = <> ScrollbarAnnotations.CustomAnnotations = <> OnCellDblClick = Tv1CellDblClick @@ -512,12 +513,12 @@ inherited frmTradeMarketList: TfrmTradeMarketList TabOrder = 2 Properties.CustomButtons.Buttons = <> Properties.Style = 9 - Properties.TabIndex = 0 + Properties.TabIndex = 2 Properties.Tabs.Strings = ( - ' '#24453#25552#20132' ' - ' '#24453#23457#26680' ' - ' '#24050#23457#26680' ' - ' '#24050#23436#25104' ' + ' '#24453#25552#20132' ' + ' '#24453#23457#26680' ' + ' '#24050#23436#25104' ' + ' '#24050#20316#24223' ' ' '#20840#37096' ') OnChange = cxTabControl1Change ClientRectBottom = 31 diff --git a/T05贸易门市管理/U_TradeMarketList.pas b/T05贸易门市管理/U_TradeMarketList.pas index 0d331d3..ac493b2 100644 --- a/T05贸易门市管理/U_TradeMarketList.pas +++ b/T05贸易门市管理/U_TradeMarketList.pas @@ -15,24 +15,7 @@ uses IdFTP, ShellAPI, cxDropDownEdit, cxCheckBox, RM_e_Graphic, RM_e_Jpeg, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxBarBuiltInMenu, Math, dxDateRanges, IdExplicitTLSClientServerBase, U_BaseList, Vcl.Clipbrd, - dxScrollbarAnnotations, cxProgressBar, FrameDateSel, dxSkinsCore, - dxSkinsDefaultPainters, Vcl.DBCtrls, dxSkinBasic, dxSkinBlack, dxSkinBlue, - dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkroom, dxSkinDarkSide, - dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy, - dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, - dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis, - dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black, - dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink, - dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue, - dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray, - dxSkinOffice2013White, dxSkinOffice2016Colorful, dxSkinOffice2016Dark, - dxSkinOffice2019Black, dxSkinOffice2019Colorful, dxSkinOffice2019DarkGray, - dxSkinOffice2019White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic, - dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringtime, dxSkinStardust, - dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinTheBezier, dxSkinValentine, - dxSkinVisualStudio2013Blue, dxSkinVisualStudio2013Dark, - dxSkinVisualStudio2013Light, dxSkinVS2010, dxSkinWhiteprint, dxSkinWXI, - dxSkinXmas2008Blue; + dxScrollbarAnnotations, cxProgressBar, FrameDateSel; type TfrmTradeMarketList = class(TfrmBaseList) @@ -63,8 +46,6 @@ type DataSource2: TDataSource; ToolButton4: TToolButton; cxTabControl1: TcxTabControl; - Tchk: TToolButton; - Tnochk: TToolButton; TWC: TToolButton; TNowc: TToolButton; ADOQueryImage: TADOQuery; @@ -118,6 +99,8 @@ type Tv1Column22: TcxGridDBColumn; Tv1Column23: TcxGridDBColumn; Tv1Column24: TcxGridDBColumn; + TBZF: TToolButton; + TBNOZF: TToolButton; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure FormCreate(Sender: TObject); @@ -139,8 +122,8 @@ type procedure TMMNoKeyPress(Sender: TObject; var Key: Char); procedure ToolButton4Click(Sender: TObject); procedure cxTabControl1Change(Sender: TObject); - procedure TchkClick(Sender: TObject); - procedure TnochkClick(Sender: TObject); +// procedure TchkClick(Sender: TObject); +// procedure TnochkClick(Sender: TObject); procedure TWCClick(Sender: TObject); procedure TNowcClick(Sender: TObject); procedure TBTJClick(Sender: TObject); @@ -157,6 +140,9 @@ type procedure ToolButton1Click(Sender: TObject); procedure N5Click(Sender: TObject); procedure N6Click(Sender: TObject); + procedure TBZFClick(Sender: TObject); + procedure TBNOZFClick(Sender: TObject); + procedure Tv1DblClick(Sender: TObject); private DQdate: TDateTime; procedure InitGrid(); @@ -209,8 +195,8 @@ begin TBDel.Enabled := False; TBTJ.Enabled := False; TBTJCX.Enabled := False; - tchk.Enabled := false; - tnochk.Enabled := false; +// tchk.Enabled := false; +// tnochk.Enabled := false; TWC.Enabled := False; TNowc.Enabled := False; TBDel.Enabled := False; @@ -221,7 +207,6 @@ begin tbadd.Enabled := True; TBEdit.Enabled := True; TBDel.Enabled := True; - TBDel.Enabled := True; TBTJ.Enabled := True; btnCopy.Enabled := True; end; @@ -230,16 +215,17 @@ begin TBTJCX.Enabled := True; btnCopy.Enabled := True; TBDel.Enabled := True; - tchk.Enabled := True; - - end; - 2: - begin + //tchk.Enabled := True; TWC.Enabled := True; btnCopy.Enabled := True; - tnochk.Enabled := True; end; - 3: +// 2: +// begin +// +// +// //tnochk.Enabled := True; +// end; + 2: begin TNowc.Enabled := True; btnCopy.Enabled := True; @@ -297,20 +283,21 @@ begin case cxTabControl1.TabIndex of 0: begin - SqlStr := SqlStr + ' , @Status=''0'' '; + SqlStr := SqlStr + ' , @Status=''0'' '; //ύ end; 1: begin - SqlStr := SqlStr + ' , @Status=''1'' '; + SqlStr := SqlStr + ' , @Status=''1'' '; // end; 2: begin - SqlStr := SqlStr + ' , @Status=''9'' '; + SqlStr := SqlStr + ' , @Status=''10'' '; // end; 3: begin - SqlStr := SqlStr + ' , @Status=''10'' '; + SqlStr := SqlStr + ' , @Status=''11'' '; // end; + end; // ShowMessage(SqlStr); InitCDSData(ADOQueryMain, Order_Main, Tv1, SqlStr, FilterStr, 'TMMId'); @@ -410,6 +397,51 @@ begin end; +procedure TfrmTradeMarketList.TBNOZFClick(Sender: TObject); +begin + if Order_Main.IsEmpty then + exit; + if Trim(Order_Main.fieldbyname('Filler').AsString) <> Trim(DName) then + begin + Application.MessageBox('ܲ˵!', 'ʾ', 0); + Exit; + end; + if Application.MessageBox('Ƿʵݣ', 'ʾ', 32 + 4) <> IDYES then + Exit; + try + with ADOQueryCmd do + begin + close; + sql.Clear; + sql.Add('update Trade_Market_Main SET status=''10'' '); + sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + + sql.Add('insert into Finance_Need_Up(UType,UDataId,UOperation,UOperator,UModule,UDetails) '); + sql.Add('values(''óײ'' '); + sql.Add(',' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + sql.Add(','''' '); + sql.Add(',' + quotedstr(DName)); + sql.Add(',' + quotedstr(trim(self.Caption))); + sql.Add(',' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + sql.Add(') '); + + sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); + sql.Add(' ' + quotedstr(trim(DName))); + sql.Add(',getdate() '); + sql.Add(',' + quotedstr(trim(self.Caption))); + sql.Add(',' + quotedstr(trim('ƻ'))); + sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); + sql.Add(',' + quotedstr(trim('ɹ'))); + sql.Add(')'); + execsql; + end; + application.MessageBox('ƻϳɹ', 'ʾϢ'); + TBRafresh.Click; + except + application.MessageBox('ƻʧܣ', 'ʾϢ', 0); + end; +end; + procedure TfrmTradeMarketList.TBDelClick(Sender: TObject); begin if Order_Main.IsEmpty then @@ -685,6 +717,35 @@ begin Clipboard.SetTextBuf(PChar(Trim(Order_Main.fieldbyname(TV1.Controller.FocusedColumn.DataBinding.FilterFieldName).AsString))); end; +procedure TfrmTradeMarketList.Tv1DblClick(Sender: TObject); +begin + if Order_Main.IsEmpty then + Exit; + + try + frmTradeMarketInPut := TfrmTradeMarketInPut.Create(Application); + with frmTradeMarketInPut do + begin + PState := 1; + FTMMId := Trim(Self.Order_Main.fieldbyname('TMMId').AsString); + ToolBar2.Enabled := False; + TBSave.Enabled := False; + ScrollBox1.Enabled := False; + N2.Visible := False; + frmTradeMarketInPut.fordtype := self.fordtype; + TvMX.OnCellDblClick := nil; + Panel5.Enabled := False; + if ShowModal = 1 then + begin + + end; + end; + finally + frmTradeMarketInPut.Free; + end; + +end; + procedure TfrmTradeMarketList.ToolButton4Click(Sender: TObject); begin if Order_Main.IsEmpty then @@ -713,72 +774,72 @@ begin InitGrid(); end; -procedure TfrmTradeMarketList.TchkClick(Sender: TObject); -begin - if Order_Main.IsEmpty then - exit; - if cxTabControl1.TabIndex <> 1 then - begin - Application.MessageBox('ֻڴ״̬½˲!', 'ʾ', 0); - Exit; - end; - if Application.MessageBox('Ƿʵݣ', 'ʾ', 32 + 4) <> IDYES then - Exit; - try - with ADOQueryCmd do - begin - close; - sql.Clear; - sql.Add('update Trade_Market_Main SET status=''9'',chker=''' + trim(DName) + ''',Chktime=getdate() '); - sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); - sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); - sql.Add(' ' + quotedstr(trim(DName))); - sql.Add(',getdate() '); - sql.Add(',' + quotedstr(trim(self.Caption))); - sql.Add(',' + quotedstr(trim('ƻ'))); - sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); - sql.Add(',' + quotedstr(trim('ɹ'))); - sql.Add(')'); - execsql; - end; +//procedure TfrmTradeMarketList.TchkClick(Sender: TObject); +//begin +// if Order_Main.IsEmpty then +// exit; +// if cxTabControl1.TabIndex <> 1 then +// begin +// Application.MessageBox('ֻڴ״̬½˲!', 'ʾ', 0); +// Exit; +// end; +// if Application.MessageBox('Ƿʵݣ', 'ʾ', 32 + 4) <> IDYES then +// Exit; +// try +// with ADOQueryCmd do +// begin +// close; +// sql.Clear; +// sql.Add('update Trade_Market_Main SET status=''9'',chker=''' + trim(DName) + ''',Chktime=getdate() '); +// sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); +// sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); +// sql.Add(' ' + quotedstr(trim(DName))); +// sql.Add(',getdate() '); +// sql.Add(',' + quotedstr(trim(self.Caption))); +// sql.Add(',' + quotedstr(trim('ƻ'))); +// sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); +// sql.Add(',' + quotedstr(trim('ɹ'))); +// sql.Add(')'); +// execsql; +// end; +// +// except +// application.MessageBox('ƻʧܣ', 'ʾϢ', 0); +// end; +// TBRafresh.Click; +//end; - except - application.MessageBox('ƻʧܣ', 'ʾϢ', 0); - end; - TBRafresh.Click; -end; - -procedure TfrmTradeMarketList.TnochkClick(Sender: TObject); -begin - if Order_Main.IsEmpty then - exit; - if cxTabControl1.TabIndex <> 2 then - begin - Application.MessageBox('ֻ״̬½˲!', 'ʾ', 0); - Exit; - end; - try - with ADOQueryCmd do - begin - close; - sql.Clear; - sql.Add('update Trade_Market_Main SET status=''1'',chker=null,Chktime=null '); - sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); - sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); - sql.Add(' ' + quotedstr(trim(DName))); - sql.Add(',getdate() '); - sql.Add(',' + quotedstr(trim(self.Caption))); - sql.Add(',' + quotedstr(trim('ƻ'))); - sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); - sql.Add(',' + quotedstr(trim('ɹ'))); - sql.Add(')'); - execsql; - end; - TBRafresh.Click; - except - application.MessageBox('ƻʧܣ', 'ʾϢ', 0); - end; -end; +//procedure TfrmTradeMarketList.TnochkClick(Sender: TObject); +//begin +// if Order_Main.IsEmpty then +// exit; +// if cxTabControl1.TabIndex <> 2 then +// begin +// Application.MessageBox('ֻ״̬½˲!', 'ʾ', 0); +// Exit; +// end; +// try +// with ADOQueryCmd do +// begin +// close; +// sql.Clear; +// sql.Add('update Trade_Market_Main SET status=''1'',chker=null,Chktime=null '); +// sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); +// sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); +// sql.Add(' ' + quotedstr(trim(DName))); +// sql.Add(',getdate() '); +// sql.Add(',' + quotedstr(trim(self.Caption))); +// sql.Add(',' + quotedstr(trim('ƻ'))); +// sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); +// sql.Add(',' + quotedstr(trim('ɹ'))); +// sql.Add(')'); +// execsql; +// end; +// TBRafresh.Click; +// except +// application.MessageBox('ƻʧܣ', 'ʾϢ', 0); +// end; +//end; procedure TfrmTradeMarketList.TWCClick(Sender: TObject); begin @@ -842,7 +903,7 @@ begin begin close; sql.Clear; - sql.Add('update Trade_Market_Main SET status=''9'' '); + sql.Add('update Trade_Market_Main SET status=''1'' '); sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); sql.Add('insert into Finance_Need_Up(UType,UDataId,UOperation,UOperator,UModule,UDetails) '); @@ -1032,5 +1093,51 @@ begin WriteCxGrid('ָʾбFF1', Tv1, 'ָʾ'); end; +procedure TfrmTradeMarketList.TBZFClick(Sender: TObject); +begin + if Order_Main.IsEmpty then + exit; + if Trim(Order_Main.fieldbyname('Filler').AsString) <> Trim(DName) then + begin + Application.MessageBox('ܲ˵!', 'ʾ', 0); + Exit; + end; + if Application.MessageBox('Ƿʵݣ', 'ʾ', 32 + 4) <> IDYES then + Exit; + try + with ADOQueryCmd do + begin + close; + sql.Clear; + sql.Add('update Trade_Market_Main SET status=''11'' '); + sql.Add('where TMMId=' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + + sql.Add('insert into Finance_Need_Up(UType,UDataId,UOperation,UOperator,UModule,UDetails) '); + sql.Add('values(''óײ'' '); + sql.Add(',' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + sql.Add(','''' '); + sql.Add(',' + quotedstr(DName)); + sql.Add(',' + quotedstr(trim(self.Caption))); + sql.Add(',' + quotedstr(trim(Order_Main.fieldbyname('TMMId').AsString))); + sql.Add(') '); + + sql.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( '); + sql.Add(' ' + quotedstr(trim(DName))); + sql.Add(',getdate() '); + sql.Add(',' + quotedstr(trim(self.Caption))); + sql.Add(',' + quotedstr(trim('ƻ'))); + sql.Add(',' + quotedstr(trim('ƻţ' + trim(Order_Main.FieldByName('TMMNO').AsString)))); + sql.Add(',' + quotedstr(trim('ɹ'))); + sql.Add(')'); + execsql; + end; + + application.MessageBox('ƻϳɹ', 'ʾϢ'); + TBRafresh.Click; + except + application.MessageBox('ƻʧܣ', 'ʾϢ', 0); + end; +end; + end. diff --git a/T05贸易门市管理/U_TradeMarketQtyInPut.dfm b/T05贸易门市管理/U_TradeMarketQtyInPut.dfm new file mode 100644 index 0000000..d93a50a --- /dev/null +++ b/T05贸易门市管理/U_TradeMarketQtyInPut.dfm @@ -0,0 +1,261 @@ +inherited frmTradeMarketQtyInPut: TfrmTradeMarketQtyInPut + Left = 67 + Top = 126 + Caption = #26126#32454#20837#24211#30331#35760 + ClientHeight = 676 + ClientWidth = 1081 + Font.Charset = GB2312_CHARSET + Font.Height = -16 + Position = poScreenCenter + OnClose = FormClose + ExplicitWidth = 1097 + ExplicitHeight = 715 + PixelsPerInch = 96 + TextHeight = 21 + object pnl1: TPanel [0] + Left = 0 + Top = 0 + Width = 1081 + Height = 676 + Align = alClient + Caption = 'pnl1' + TabOrder = 0 + object tlb1: TToolBar + Tag = 1 + Left = 1 + Top = 1 + Width = 1079 + Height = 30 + AutoSize = True + ButtonHeight = 30 + ButtonWidth = 83 + Caption = 'ToolBar1' + Color = clSkyBlue + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -12 + Font.Name = #23435#20307 + Font.Style = [] + Images = DataLink_TradeMarket.cxImageList_bar + List = True + ParentColor = False + ParentFont = False + ShowCaptions = True + TabOrder = 0 + object TBSave: TToolButton + Left = 0 + Top = 0 + AutoSize = True + Caption = #20445#23384 + ImageIndex = 16 + OnClick = TBSaveClick + end + object btnAdd: TToolButton + Left = 63 + Top = 0 + AutoSize = True + Caption = #26032#22686 + ImageIndex = 2 + OnClick = btnAddClick + end + object TBClose: TToolButton + Left = 126 + Top = 0 + AutoSize = True + Caption = #20851#38381 + ImageIndex = 7 + OnClick = TBCloseClick + end + object btn4: TToolButton + Left = 189 + Top = 0 + AutoSize = True + Caption = #20445#23384#26684#24335 + ImageIndex = 16 + end + end + object pnl2: TPanel + Left = 1 + Top = 31 + Width = 1079 + Height = 41 + Align = alTop + TabOrder = 1 + object Label9: TLabel + Left = 33 + Top = 7 + Width = 32 + Height = 21 + Caption = #21305#25968 + end + object Label13: TLabel + Left = 193 + Top = 7 + Width = 32 + Height = 21 + Caption = #25968#37327 + end + object Label1: TLabel + Left = 377 + Top = 6 + Width = 5 + Height = 22 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + end + object inPiece: TcxCurrencyEdit + Left = 71 + Top = 3 + Properties.AssignedValues.DisplayFormat = True + TabOrder = 0 + Width = 98 + end + object inQty: TcxCurrencyEdit + Left = 231 + Top = 6 + Properties.AssignedValues.DisplayFormat = True + TabOrder = 1 + OnKeyPress = inQtyKeyPress + Width = 98 + end + end + object GroupBox1: TGroupBox + Left = 1 + Top = 72 + Width = 1079 + Height = 603 + Align = alClient + Caption = #21452#20987#21024#38500#26126#32454#20449#24687 + TabOrder = 2 + object cxGrid1: TcxGrid + Left = 2 + Top = 23 + Width = 1075 + Height = 578 + Align = alClient + TabOrder = 0 + object Tv1: TcxGridDBTableView + OnDblClick = Tv1DblClick + Navigator.Buttons.CustomButtons = <> + Navigator.Buttons.Delete.Enabled = False + Navigator.Buttons.Delete.Visible = False + ScrollbarAnnotations.CustomAnnotations = <> + DataController.DataSource = DS_1 + DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost] + DataController.Summary.DefaultGroupSummaryItems = < + item + Kind = skCount + Position = spFooter + end + item + Kind = skSum + Position = spFooter + Column = cxGridDBColumn8 + end + item + Kind = skCount + end + item + Kind = skSum + Column = cxGridDBColumn8 + end> + DataController.Summary.FooterSummaryItems = < + item + Kind = skSum + Column = cxGridDBColumn8 + end + item + Kind = skCount + Column = cxGridDBColumn8 + end> + DataController.Summary.SummaryGroups = <> + OptionsCustomize.ColumnFiltering = False + OptionsView.Footer = True + OptionsView.GroupByBox = False + OptionsView.Indicator = True + OptionsView.IndicatorWidth = 33 + object cxGridDBColumn8: TcxGridDBColumn + Caption = #25968#37327 + DataBinding.FieldName = 'Qty' + DataBinding.IsNullValueType = True + PropertiesClassName = 'TcxTextEditProperties' + Properties.Alignment.Horz = taCenter + HeaderAlignmentHorz = taCenter + Options.Editing = False + Options.Sorting = False + Width = 66 + end + end + object cxGridLevel1: TcxGridLevel + GridView = Tv1 + end + end + end + end + inherited ADOQueryBaseCmd: TADOQuery + Connection = DataLink_TradeMarket.ADOLink + Left = 268 + Top = 159 + end + inherited ADOQueryBaseTemp: TADOQuery + Connection = DataLink_TradeMarket.ADOLink + Left = 368 + Top = 119 + end + inherited ImageList_new32: TImageList + Left = 376 + Top = 303 + end + inherited cxImageList_bar: TcxImageList + FormatVersion = 1 + Left = 580 + Top = 235 + DesignInfo = 15401540 + end + object DS_1: TDataSource + DataSet = CDS_1 + Left = 292 + Top = 423 + end + object CDS_1: TClientDataSet + Aggregates = <> + Params = <> + Left = 340 + Top = 415 + end + object ADOQueryCmd: TADOQuery + Connection = DataLink_TradeMarket.ADOLink + Parameters = <> + Left = 512 + Top = 135 + end + object ADOQueryMain: TADOQuery + Connection = DataLink_TradeMarket.ADOLink + LockType = ltReadOnly + Parameters = <> + Left = 580 + Top = 167 + end + object ADOQueryTemp: TADOQuery + Connection = DataLink_TradeMarket.ADOLink + LockType = ltReadOnly + Parameters = <> + Left = 308 + Top = 235 + end + object GPM_1: TcxGridPopupMenu + PopupMenus = <> + Left = 512 + Top = 235 + end + object CDS_LM: TClientDataSet + Aggregates = <> + Params = <> + Left = 536 + Top = 435 + end +end diff --git a/T05贸易门市管理/U_TradeMarketQtyInPut.pas b/T05贸易门市管理/U_TradeMarketQtyInPut.pas new file mode 100644 index 0000000..54d4e87 --- /dev/null +++ b/T05贸易门市管理/U_TradeMarketQtyInPut.pas @@ -0,0 +1,348 @@ +unit U_TradeMarketQtyInPut; + +interface + +uses + Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, + System.Types, Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, + cxDataStorage, cxEdit, DB, cxDBData, cxCalendar, cxDropDownEdit, ComCtrls, + ToolWin, cxGridLevel, cxGridCustomTableView, cxGridTableView, + cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid, + cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient, cxButtonEdit, + cxTextEdit, StdCtrls, ExtCtrls, cxLookAndFeels, cxLookAndFeelPainters, + cxNavigator, dxDateRanges, dxBarBuiltInMenu, U_BaseInput, System.ImageList, + Vcl.ImgList, ComObj, dxScrollbarAnnotations, cxContainer, dxCore, cxDateUtils, + cxMaskEdit, cxImageList, cxCurrencyEdit, Vcl.Menus, Clipbrd; + +type + TfrmTradeMarketQtyInPut = class(TfrmBaseInput) + DS_1: TDataSource; + CDS_1: TClientDataSet; + ADOQueryCmd: TADOQuery; + ADOQueryMain: TADOQuery; + ADOQueryTemp: TADOQuery; + GPM_1: TcxGridPopupMenu; + CDS_LM: TClientDataSet; + pnl1: TPanel; + tlb1: TToolBar; + btn4: TToolButton; + pnl2: TPanel; + inPiece: TcxCurrencyEdit; + Label9: TLabel; + inQty: TcxCurrencyEdit; + Label13: TLabel; + TBSave: TToolButton; + TBClose: TToolButton; + Label1: TLabel; + GroupBox1: TGroupBox; + cxGrid1: TcxGrid; + Tv1: TcxGridDBTableView; + cxGridDBColumn8: TcxGridDBColumn; + cxGridLevel1: TcxGridLevel; + btnAdd: TToolButton; + procedure FormClose(Sender: TObject; var Action: TCloseAction); + procedure FormShow(Sender: TObject); + procedure FromCoNameDblClick(Sender: TObject); + procedure inQtyKeyPress(Sender: TObject; var Key: Char); + procedure TBCloseClick(Sender: TObject); + procedure TBSaveClick(Sender: TObject); + procedure btnAddClick(Sender: TObject); + procedure Tv1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); + procedure Tv1DblClick(Sender: TObject); + private + { Private declarations } + function SaveData(): Boolean; + function Split(const s: string; Separator: char): TStringDynArray; + public + { Public declarations } + PMTMSId, PFTMMID: string; + FName, FColor, FColorNo: string; + MTMSId, FTMMID: string; + end; + +var + frmTradeMarketQtyInPut: TfrmTradeMarketQtyInPut; + +implementation + +uses + U_DataLink, U_RTFun, U_RPFun; + +{$R *.dfm} + +// ַָ +function TfrmTradeMarketQtyInPut.Split(const s: string; Separator: char): TStringDynArray; +var + i, ItemIndex: Integer; + len: Integer; + SeparatorCount: Integer; + Start: Integer; +begin + len := Length(s); + if len = 0 then + begin + Result := nil; + Exit; + end; + + // ָ + SeparatorCount := 0; + for i := 1 to len do + if s[i] = Separator then + Inc(SeparatorCount); + + SetLength(Result, SeparatorCount + 1); + ItemIndex := 0; + Start := 1; + + // ַ + for i := 1 to len do + begin + if s[i] = Separator then + begin + Result[ItemIndex] := Copy(s, Start, i - Start); + Inc(ItemIndex); + Start := i + 1; + end; + end; + + Result[ItemIndex] := Copy(s, Start, len - Start + 1); +end; + +procedure TfrmTradeMarketQtyInPut.btnAddClick(Sender: TObject); +begin + if CDS_1.IsEmpty = False then + begin + CopyAddRowCDS(CDS_1); + with CDS_1 do + begin + Edit; + FieldByName('TMSQID').Value := null; + + post; + end; + end + else + begin + with CDS_1 do + begin + Append; + + + //FieldByName('QtyUnit').Value := 'M'; + Post; + end; + end; +end; + +procedure TfrmTradeMarketQtyInPut.FormClose(Sender: TObject; var Action: TCloseAction); +begin + inherited; + Action := caFree; +end; + +function TfrmTradeMarketQtyInPut.SaveData(): Boolean; +var + Maxno, PTMSQID: string; +begin + try + ADOQueryCmd.Connection.BeginTrans; + CDS_1.DisableControls; + with CDS_1 do + begin + First; + while not eof do + begin + with ADOQueryTemp do + begin + + Close; + sql.Clear; + sql.Add('select * from Trade_Market_Sub_Qty where TMSQID=''' + Trim(CDS_1.fieldbyname('TMSQID').AsString) + ''''); + open; + end; + + PTMSQID := Trim(ADOQueryTemp.fieldbyname('TMSQID').AsString); + if Trim(PTMSQID) = '' then + begin + if GetLSNo(ADOQueryTemp, Maxno, 'MX', 'Trade_Market_Sub_Qty', 4, 1) = False then + begin + Application.MessageBox('ȡʧ!', 'ʾ', 0); + Exit; + end; + end + else + begin + Maxno := Trim(PTMSQID); + end; + + with ADOQueryCmd do + begin + Close; + sql.Clear; + SQL.Add('select * from Trade_Market_Sub_Qty where TMSQID=''' + Trim(Maxno) + ''''); + Open; + end; + + with ADOQueryCmd do + begin + if Trim(PTMSQID) = '' then + begin + Append; + FieldByName('FillId').Value := Trim(DCode); + FieldByName('Filler').Value := Trim(DName); + FieldByName('TMSQID').Value := Trim(Maxno); + + end + else + begin + Edit; + FieldByName('EditId').Value := Trim(DCode); + FieldByName('Editer').Value := Trim(DName); + FieldByName('EditTime').Value := SGetServerDateTime(ADOQueryTemp); + end; + RTSetSaveDataCDS(ADOQueryCmd, Tv1, CDS_1, 'Trade_Market_Sub_Qty', 0); + FieldByName('TMSQID').AsString := FieldByName('TMSQID').AsString; + FieldByName('TMSId').AsString := FieldByName('TMSId').AsString; + FieldByName('TMMId').AsString := FieldByName('TMMId').AsString; + FieldByName('Qty').value := StrTofloatDef(inQty.Text, 0); + Post; + end; + Next; + end; + end; + + CDS_1.EnableControls; +// with ADOQueryCmd do +// begin +// Close; +// Sql.Clear; +// +// Sql.Add('exec P_BS_Cloth_UpdateByTradeMarket '); +// Sql.Add(' @TIMId=' + quotedstr(Trim(FTMMID))); +// Sql.Add(',@DCode=' + quotedstr(Trim(DCode))); +// Sql.Add(',@DName=' + quotedstr(Trim(DName))); +// Open; +// end; + ADOQueryCmd.Connection.CommitTrans; + Result := True; + + except + Result := False; + ADOQueryCmd.Connection.RollbackTrans; + application.MessageBox(PChar(Exception(ExceptObject).Message), 'ʾϢ', 0); + end; + +end; + +procedure TfrmTradeMarketQtyInPut.FormShow(Sender: TObject); +begin + inherited; + ReadCxGrid('', Tv1, 'óй'); + + + with ADOQueryTemp do + begin + Close; + SQL.Clear; + sql.Add(' select A.* from Trade_Market_Sub_Qty A'); + sql.Add('where TMSId=''' + Trim(PMTMSId) + ''''); + Open; + end; + SCreateCDS(ADOQueryTemp, CDS_1); + SInitCDSData(ADOQueryTemp, CDS_1); +end; + +procedure TfrmTradeMarketQtyInPut.FromCoNameDblClick(Sender: TObject); +begin + TcxButtonEdit(Sender).Text := ''; + TcxButtonEdit(Sender).Properties.LookupItems.Text := ''; +end; + +procedure TfrmTradeMarketQtyInPut.inQtyKeyPress(Sender: TObject; var Key: Char); +var + i: Integer; + MaxNo: string; +begin + if Key = #13 then + begin + + with CDS_1 do + begin + DisableControls; + for i := 1 to StrToIntDef(inPiece.Text, 1) do + begin + Append; + FieldByName('Qty').Value := StrTofloatDef(inQty.Text, 0); +// FieldByName('TMSQID').Value := MaxNo; +// FieldByName('TMSId').Value := PMTMSId; +// FieldByName('TMMId').Value := PFTMMId; + Post; + + end; + EnableControls; + end; + inPiece.Text := '1'; + inQty.Text := ''; + end; +end; + +procedure TfrmTradeMarketQtyInPut.TBSaveClick(Sender: TObject); +var + Maxno: string; +begin + + if CDS_1.Locate('Qty', null, []) = True then + begin + Application.MessageBox('Ϊ!', 'ʾ', 0); + Exit; + end; + if CDS_1.Locate('Qty', 0, []) = True then + begin + Application.MessageBox('Ϊ0!', 'ʾ', 0); + Exit; + end; + if SaveData() then + begin + Application.MessageBox('ɹ!', 'ʾ', 0); + ModalResult := 1; + + end; +end; + + + +procedure TfrmTradeMarketQtyInPut.TBCloseClick(Sender: TObject); +begin + inherited; + Close; +end; + +procedure TfrmTradeMarketQtyInPut.Tv1DblClick(Sender: TObject); +begin + + with ADOQueryTemp do + begin + Close; + SQL.Clear; + sql.Add('delete Trade_Market_Sub_Qty where TMSQID=' + quotedstr(Trim(CDS_1.FieldByName('TMSQID').AsString))); + ExecSQL; + end; + CDS_1.Delete; + +end; + +procedure TfrmTradeMarketQtyInPut.Tv1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); +begin + + // Ƿ Ctrl+V + if (Key = Ord('V')) and (Shift = [ssCtrl]) then + begin + pasteDatatTocxGrid(Tv1); + + end; + +end; + +end. +