diff --git a/复合检验管理/U_ClothHCList.dfm b/复合检验管理/U_ClothHCList.dfm index 9977459..fe16f49 100644 --- a/复合检验管理/U_ClothHCList.dfm +++ b/复合检验管理/U_ClothHCList.dfm @@ -115,9 +115,9 @@ object frmClothHCList: TfrmClothHCList object Label9: TLabel Left = 384 Top = 22 - Width = 53 + Width = 47 Height = 12 - Caption = #21512' '#21516' '#21495 + Caption = #23458' '#25143 Font.Charset = GB2312_CHARSET Font.Color = clWindowText Font.Height = -12 @@ -230,7 +230,7 @@ object frmClothHCList: TfrmClothHCList TabOrder = 4 OnChange = OrderNoMChange end - object conNo: TEdit + object CustomerNoName: TEdit Tag = 2 Left = 440 Top = 18 diff --git a/复合检验管理/U_ClothHCList.pas b/复合检验管理/U_ClothHCList.pas index 4767899..369e4d7 100644 --- a/复合检验管理/U_ClothHCList.pas +++ b/复合检验管理/U_ClothHCList.pas @@ -1,8 +1,8 @@ unit U_ClothHCList; interface - -uses + +uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB, @@ -11,7 +11,20 @@ uses cxGridDBTableView, cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxDropDownEdit, cxCheckBox, cxLookAndFeels, - cxLookAndFeelPainters, cxNavigator; + cxLookAndFeelPainters, cxNavigator, dxSkinsCore, 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, dxSkinPumpkin, + dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus, + dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008, + dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine, + dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter; type TfrmClothHCList = class(TForm) @@ -43,7 +56,7 @@ type V2KHOrderNo: TcxGridDBColumn; V2Column14: TcxGridDBColumn; SubID: TEdit; - conNo: TEdit; + CustomerNoName: TEdit; Label9: TLabel; V2Column15: TcxGridDBColumn; V2Column16: TcxGridDBColumn; diff --git a/复合检验管理/U_GetDllForm.pas b/复合检验管理/U_GetDllForm.pas index 892a838..a71b0e6 100644 --- a/复合检验管理/U_GetDllForm.pas +++ b/复合检验管理/U_GetDllForm.pas @@ -1,7 +1,7 @@ unit U_GetDllForm; interface - + uses Windows, Messages, forms, OleCtnrs, DateUtils, SysUtils, ADODB, inifiles, dxCore, ActiveX; diff --git a/复合检验管理/U_JYOrderCDOne.dfm b/复合检验管理/U_JYOrderCDOne.dfm index 0b7fca4..0f5e5b7 100644 --- a/复合检验管理/U_JYOrderCDOne.dfm +++ b/复合检验管理/U_JYOrderCDOne.dfm @@ -243,13 +243,14 @@ object frmJYOrderCDOne: TfrmJYOrderCDOne object ToolButton12: TToolButton Left = 785 Top = 30 + AutoSize = True Caption = #20462#25913#30721#21333 ImageIndex = 54 Visible = False OnClick = ToolButton12Click end object ToolButton9: TToolButton - Left = 904 + Left = 872 Top = 30 AutoSize = True Caption = #24322#24120#25968#25454 @@ -257,7 +258,7 @@ object frmJYOrderCDOne: TfrmJYOrderCDOne OnClick = ToolButton9Click end object TBExport: TToolButton - Left = 991 + Left = 959 Top = 30 AutoSize = True Caption = #23548#20986 @@ -265,13 +266,21 @@ object frmJYOrderCDOne: TfrmJYOrderCDOne OnClick = TBExportClick end object TBClose: TToolButton - Left = 1054 + Left = 1022 Top = 30 AutoSize = True Caption = #20851#38381 ImageIndex = 55 OnClick = TBCloseClick end + object ToolButton15: TToolButton + Left = 1085 + Top = 30 + AutoSize = True + Caption = #25209#37327#20462#25913 + ImageIndex = 56 + OnClick = ToolButton15Click + end end object Panel1: TPanel Left = 0 @@ -1173,6 +1182,12 @@ object frmJYOrderCDOne: TfrmJYOrderCDOne HeaderAlignmentHorz = taCenter Width = 70 end + object Tv1Column8: TcxGridDBColumn + Caption = #24037#33402 + DataBinding.FieldName = 'GY' + HeaderAlignmentHorz = taCenter + Width = 60 + end end object cxGrid1Level1: TcxGridLevel GridView = Tv1 @@ -2006,6 +2021,240 @@ object frmJYOrderCDOne: TfrmJYOrderCDOne OnClick = Edit6Click end end + object Panel15: TPanel + Left = 784 + Top = 208 + Width = 425 + Height = 305 + Color = clSkyBlue + TabOrder = 15 + Visible = False + object Label40: TLabel + Left = 45 + Top = 37 + Width = 34 + Height = 16 + Caption = #23458#25143 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + Visible = False + end + object Label41: TLabel + Left = 45 + Top = 76 + Width = 34 + Height = 16 + Caption = #21697#21517 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + end + object Label42: TLabel + Left = 53 + Top = 117 + Width = 34 + Height = 16 + Caption = #39068#33394 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + end + object Label44: TLabel + Left = 54 + Top = 156 + Width = 34 + Height = 16 + Caption = #24037#33402 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + end + object Label45: TLabel + Left = 51 + Top = 200 + Width = 34 + Height = 16 + Caption = #33394#21495 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + end + object Button17: TButton + Left = 64 + Top = 246 + Width = 76 + Height = 41 + Caption = #30830#23450 + TabOrder = 0 + OnClick = Button17Click + end + object Button18: TButton + Left = 264 + Top = 246 + Width = 81 + Height = 41 + Caption = #20851#38381 + TabOrder = 1 + OnClick = Button18Click + end + object FKH: TEdit + Left = 93 + Top = 32 + Width = 187 + Height = 24 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 2 + Visible = False + end + object FPM: TEdit + Left = 93 + Top = 71 + Width = 187 + Height = 24 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 3 + end + object FYS: TEdit + Left = 93 + Top = 113 + Width = 187 + Height = 24 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 4 + end + object Button19: TButton + Left = 283 + Top = 27 + Width = 101 + Height = 35 + Caption = #36873#25321#23458#25143 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 5 + Visible = False + end + object Button20: TButton + Left = 283 + Top = 68 + Width = 101 + Height = 35 + Caption = #36873#25321#21697#21517 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 6 + OnClick = Button20Click + end + object Button21: TButton + Left = 283 + Top = 108 + Width = 101 + Height = 35 + Caption = #36873#25321#39068#33394 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 7 + OnClick = Button21Click + end + object FGY: TEdit + Left = 93 + Top = 152 + Width = 187 + Height = 24 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 8 + end + object Button22: TButton + Left = 283 + Top = 147 + Width = 101 + Height = 35 + Caption = #36873#25321#24037#33402 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 9 + OnClick = Button22Click + end + object FSH: TEdit + Left = 90 + Top = 196 + Width = 187 + Height = 24 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -16 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 10 + end + object Button23: TButton + Left = 280 + Top = 191 + Width = 101 + Height = 35 + Caption = #36873#25321#33394#21495 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 11 + OnClick = Button23Click + end + end object cxGridPopupMenu1: TcxGridPopupMenu Grid = cxGrid1 PopupMenus = <> diff --git a/复合检验管理/U_JYOrderCDOne.pas b/复合检验管理/U_JYOrderCDOne.pas index 1137427..75e1ce5 100644 --- a/复合检验管理/U_JYOrderCDOne.pas +++ b/复合检验管理/U_JYOrderCDOne.pas @@ -238,6 +238,26 @@ type Tv1Column5: TcxGridDBColumn; Tv1Column6: TcxGridDBColumn; Tv1Column7: TcxGridDBColumn; + Tv1Column8: TcxGridDBColumn; + ToolButton15: TToolButton; + Panel15: TPanel; + Label40: TLabel; + Label41: TLabel; + Label42: TLabel; + Label44: TLabel; + Label45: TLabel; + Button17: TButton; + Button18: TButton; + FKH: TEdit; + FPM: TEdit; + FYS: TEdit; + Button19: TButton; + Button20: TButton; + Button21: TButton; + FGY: TEdit; + Button22: TButton; + FSH: TEdit; + Button23: TButton; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure FormCreate(Sender: TObject); @@ -303,6 +323,13 @@ type procedure Button16Click(Sender: TObject); procedure Button15Click(Sender: TObject); procedure Edit6Click(Sender: TObject); + procedure ToolButton15Click(Sender: TObject); + procedure Button17Click(Sender: TObject); + procedure Button20Click(Sender: TObject); + procedure Button21Click(Sender: TObject); + procedure Button22Click(Sender: TObject); + procedure Button23Click(Sender: TObject); + procedure Button18Click(Sender: TObject); // procedure Edit5Click(Sender: TObject); // procedure CheckBox3Click(Sender: TObject); private @@ -328,7 +355,7 @@ var implementation uses - U_DataLink, U_OrderInPut, U_Fun, U_MJEdit, U_CPDBAO, U_MJSJFX; + U_DataLink, U_OrderInPut, U_Fun, U_MJEdit, U_CPDBAO, U_MJSJFX, U_SCPersonColor; {$R *.dfm} procedure TfrmJYOrderCDOne.JSbaoNum(); @@ -1643,7 +1670,7 @@ begin with ADOQueryTemp do begin Close; - sql.Clear; + sql.Clear; sql.add('exec P_Print_CKMDYDL_L '); sql.add('@DName=' + quotedstr(Trim(DCode))); Open; @@ -2370,5 +2397,151 @@ begin end; end; +procedure TfrmJYOrderCDOne.ToolButton15Click(Sender: TObject); +begin + Panel15.Left := (self.Width - Panel15.Width) div 2; + Panel15.Visible := true; +end; + +procedure TfrmJYOrderCDOne.Button17Click(Sender: TObject); +begin + if Order_Main.IsEmpty then + Exit; + if Order_Main.Locate('SSel', True, []) = False then + begin + Application.MessageBox('ûѡ!', 'ʾ', 0); + Exit; + end; + try + Order_Main.DisableControls; + ADOQueryCmd.Connection.BeginTrans; + with Order_Main do + begin + First; + while not Eof do + begin + if Order_Main.FieldByName('SSel').AsBoolean = True then + begin + with ADOQueryCmd do + begin + Close; + sql.Clear; +// if trim(Fkh.text) <> '' then +// begin +// sql.Add('Update WFB_MJJY Set CustomerNoName=''' + trim(FKH.Text) + ''' '); +// sql.Add('where MJID=''' + Trim(Order_Main.fieldbyname('MJID').AsString) + ''''); +// end; + if trim(FPM.text) <> '' then + begin + sql.Add('Update WFB_MJJY Set PRTCodeName=''' + trim(FPM.Text) + ''' '); + sql.Add('where MJID=''' + Trim(Order_Main.fieldbyname('MJID').AsString) + ''''); + end; + if trim(FYS.text) <> '' then + begin + sql.Add('Update WFB_MJJY Set PRTColor=''' + trim(FYS.Text) + ''' '); + sql.Add('where MJID=''' + Trim(Order_Main.fieldbyname('MJID').AsString) + ''''); + end; + if trim(FGY.text) <> '' then + begin + sql.Add('Update WFB_MJJY Set GY=''' + trim(FGY.Text) + ''' '); + sql.Add('where MJID=''' + Trim(Order_Main.fieldbyname('MJID').AsString) + ''''); + end; + if trim(FSH.text) <> '' then + begin + sql.Add('Update WFB_MJJY Set SH=''' + trim(FSH.Text) + ''' '); + sql.Add('where MJID=''' + Trim(Order_Main.fieldbyname('MJID').AsString) + ''''); + end; + + ExecSQL; + end; + end; + Next; + end; + end; + ADOQueryCmd.Connection.CommitTrans; + Order_Main.EnableControls; + application.MessageBox('ݱɹ', 'ʾϢ'); + Panel15.Visible := false; + TBRafresh.Click; + except + ADOQueryCmd.Connection.RollbackTrans; + Order_Main.EnableControls; + application.MessageBox('ݱʧܣ', 'ʾϢ', 0); + end; +end; + +procedure TfrmJYOrderCDOne.Button20Click(Sender: TObject); +begin + try + frmSCPersonColor := TfrmSCPersonColor.Create(self); + with frmSCPersonColor do + begin + FTYPE := 'PM'; + if ShowModal = 1 then + begin + FPM.Text := FName; + end; + end; + finally + frmSCPersonColor.close; + end; +end; + +procedure TfrmJYOrderCDOne.Button21Click(Sender: TObject); +begin + try + frmSCPersonColor := TfrmSCPersonColor.Create(self); + with frmSCPersonColor do + begin + FTYPE := 'YS'; + if ShowModal = 1 then + begin + FYS.Text := FName; + end; + end; + finally + frmSCPersonColor.close; + end; +end; + +procedure TfrmJYOrderCDOne.Button22Click(Sender: TObject); +begin + try + frmSCPersonColor := TfrmSCPersonColor.Create(self); + with frmSCPersonColor do + begin + FTYPE := 'GY'; + if ShowModal = 1 then + begin + FGY.Text := FName; + end; + end; + finally + frmSCPersonColor.close; + end; +end; + +procedure TfrmJYOrderCDOne.Button23Click(Sender: TObject); +begin + try + frmSCPersonColor := TfrmSCPersonColor.Create(self); + with frmSCPersonColor do + begin + FTYPE := 'SH'; + if ShowModal = 1 then + begin + FSH.Text := FName; + end; + end; + finally + frmSCPersonColor.close; + end; +end; + +procedure TfrmJYOrderCDOne.Button18Click(Sender: TObject); +begin + Panel15.Visible := false; +end; + end. diff --git a/复合检验管理/U_MJManageNewFDNew.dfm b/复合检验管理/U_MJManageNewFDNew.dfm index be3a558..d655779 100644 --- a/复合检验管理/U_MJManageNewFDNew.dfm +++ b/复合检验管理/U_MJManageNewFDNew.dfm @@ -1,6 +1,6 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF - Left = 540 - Top = 169 + Left = 143 + Top = 200 Width = 1368 Height = 754 Caption = #25104#21697#26816#39564 @@ -1177,8 +1177,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF Visible = False end object Label14: TLabel - Left = 291 - Top = 426 + Left = 395 + Top = 362 Width = 60 Height = 23 Caption = #21407#25968#37327 @@ -1205,7 +1205,7 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF end object Label22: TLabel Left = 144 - Top = 424 + Top = 416 Width = 36 Height = 22 Caption = 'g/'#13217 @@ -1218,7 +1218,7 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF end object Label23: TLabel Left = 8 - Top = 423 + Top = 415 Width = 42 Height = 20 Caption = #20811#37325 @@ -1230,8 +1230,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label27: TLabel - Left = 227 - Top = 549 + Left = 331 + Top = 381 Width = 40 Height = 23 Caption = #36192#36865 @@ -1257,8 +1257,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label29: TLabel - Left = 300 - Top = 414 + Left = 404 + Top = 350 Width = 58 Height = 23 Caption = #26588' '#21495 @@ -1375,8 +1375,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label40: TLabel - Left = 216 - Top = 487 + Left = 320 + Top = 423 Width = 80 Height = 22 Caption = #26579#21378#32568#21495 @@ -1389,8 +1389,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF Visible = False end object Label28: TLabel - Left = 202 - Top = 404 + Left = 354 + Top = 572 Width = 42 Height = 20 Caption = #21253#21495 @@ -1403,8 +1403,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF Visible = False end object Label53: TLabel - Left = 151 - Top = 8 + Left = 165 + Top = 14 Width = 105 Height = 20 Caption = #25351#31034#21333#23458#25143 @@ -1416,8 +1416,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label55: TLabel - Left = 208 - Top = 175 + Left = 223 + Top = 213 Width = 42 Height = 20 Caption = #39068#33394 @@ -1429,8 +1429,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label57: TLabel - Left = 208 - Top = 83 + Left = 222 + Top = 89 Width = 42 Height = 20 Caption = #24037#33402 @@ -1442,8 +1442,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label58: TLabel - Left = 208 - Top = 131 + Left = 223 + Top = 174 Width = 42 Height = 20 Caption = #27454#21495 @@ -1455,8 +1455,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label59: TLabel - Left = 208 - Top = 263 + Left = 223 + Top = 296 Width = 42 Height = 20 Caption = #26631#31614 @@ -1468,8 +1468,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label60: TLabel - Left = 208 - Top = 223 + Left = 223 + Top = 256 Width = 42 Height = 20 Caption = #33394#21495 @@ -1507,8 +1507,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF ParentFont = False end object Label45: TLabel - Left = 160 - Top = 47 + Left = 174 + Top = 53 Width = 84 Height = 20 Caption = #26631#31614#23458#25143 @@ -1519,11 +1519,25 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF Font.Style = [fsBold] ParentFont = False end + object Label62: TLabel + Left = 223 + Top = 130 + Width = 42 + Height = 20 + Caption = #21697#21517 + Font.Charset = ANSI_CHARSET + Font.Color = clBlue + Font.Height = -20 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + end object MJFK: TEdit Left = 51 Top = 377 Width = 90 - Height = 41 + Height = 33 + AutoSize = False Font.Charset = GB2312_CHARSET Font.Color = clWindowText Font.Height = -32 @@ -1568,10 +1582,10 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object BTPrint: TButton - Left = 10 - Top = 460 - Width = 171 - Height = 93 + Left = 6 + Top = 443 + Width = 163 + Height = 56 Caption = #25552#20132 Font.Charset = GB2312_CHARSET Font.Color = clWindowText @@ -1616,8 +1630,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object MJQty1: TEdit - Left = 361 - Top = 417 + Left = 465 + Top = 353 Width = 90 Height = 41 Font.Charset = GB2312_CHARSET @@ -1634,9 +1648,10 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF end object MJSJKZ: TEdit Left = 51 - Top = 418 + Top = 410 Width = 90 - Height = 41 + Height = 33 + AutoSize = False Font.Charset = GB2312_CHARSET Font.Color = clWindowText Font.Height = -32 @@ -1648,8 +1663,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object MJQty2: TEdit - Left = 281 - Top = 548 + Left = 385 + Top = 380 Width = 90 Height = 36 Font.Charset = GB2312_CHARSET @@ -1683,8 +1698,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object MJstr3: TEdit - Left = 369 - Top = 409 + Left = 473 + Top = 345 Width = 90 Height = 41 Font.Charset = GB2312_CHARSET @@ -1805,8 +1820,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object MJstr5: TEdit - Left = 301 - Top = 478 + Left = 405 + Top = 414 Width = 90 Height = 41 Font.Charset = GB2312_CHARSET @@ -1822,8 +1837,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object baoNo: TEdit - Left = 249 - Top = 397 + Left = 393 + Top = 573 Width = 90 Height = 36 Font.Charset = GB2312_CHARSET @@ -1838,8 +1853,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object BaoID: TEdit - Left = 275 - Top = 384 + Left = 395 + Top = 552 Width = 121 Height = 20 TabOrder = 10 @@ -1861,8 +1876,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnClick = Button7Click end object KH: TBtnEditA - Left = 256 - Top = 0 + Left = 270 + Top = 6 Width = 145 Height = 37 AutoSize = False @@ -1875,9 +1890,9 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF TabOrder = 21 OnBtnClick = KHBtnClick end - object PM: TBtnEditA - Left = 256 - Top = 78 + object GY: TBtnEditA + Left = 270 + Top = 84 Width = 145 Height = 37 AutoSize = False @@ -1892,8 +1907,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnBtnClick = V1PRTCodeNameBtnClick end object YS: TBtnEditA - Left = 256 - Top = 166 + Left = 271 + Top = 204 Width = 145 Height = 37 AutoSize = False @@ -1908,8 +1923,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnBtnClick = YSBtnClick end object kuanno: TBtnEditA - Left = 256 - Top = 122 + Left = 271 + Top = 165 Width = 145 Height = 37 AutoSize = False @@ -1924,8 +1939,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnBtnClick = kuannoBtnClick end object SH: TBtnEditA - Left = 256 - Top = 210 + Left = 271 + Top = 243 Width = 145 Height = 37 AutoSize = False @@ -1940,8 +1955,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnBtnClick = SHBtnClick end object SLbName: TFTComboBox - Left = 256 - Top = 254 + Left = 271 + Top = 287 Width = 185 Height = 32 Font.Charset = GB2312_CHARSET @@ -1963,8 +1978,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF #20869#38144#26631#31614'5') end object Button9: TButton - Left = 384 - Top = 0 + Left = 398 + Top = 6 Width = 65 Height = 38 Caption = #36873#25321#23458#25143 @@ -1978,8 +1993,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnClick = Button9Click end object Button10: TButton - Left = 384 - Top = 74 + Left = 398 + Top = 80 Width = 65 Height = 38 Caption = #36873#25321#24037#33402 @@ -1993,8 +2008,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnClick = Button10Click end object Button11: TButton - Left = 384 - Top = 162 + Left = 399 + Top = 203 Width = 65 Height = 38 Caption = #36873#25321#39068#33394 @@ -2008,8 +2023,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnClick = Button11Click end object Button12: TButton - Left = 384 - Top = 210 + Left = 399 + Top = 245 Width = 65 Height = 38 Caption = #36873#25321#33394#21495 @@ -2023,8 +2038,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnClick = Button12Click end object Button13: TButton - Left = 384 - Top = 122 + Left = 399 + Top = 162 Width = 65 Height = 38 Caption = #36873#25321#27454#21495 @@ -2054,8 +2069,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnKeyPress = MJstr3KeyPress end object bqkh: TBtnEditA - Left = 256 - Top = 40 + Left = 270 + Top = 46 Width = 145 Height = 37 AutoSize = False @@ -2069,8 +2084,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF OnBtnClick = KHBtnClick end object Button5: TButton - Left = 384 - Top = 40 + Left = 398 + Top = 46 Width = 65 Height = 38 Caption = #36873#25321#23458#25143 @@ -2083,6 +2098,67 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF TabOrder = 34 OnClick = Button5Click end + object PM: TBtnEditA + Left = 271 + Top = 125 + Width = 145 + Height = 37 + AutoSize = False + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -28 + Font.Name = #23435#20307 + Font.Style = [] + ParentFont = False + TabOrder = 35 + OnKeyPress = MJstr3KeyPress + OnBtnClick = V1PRTCodeNameBtnClick + end + object Button14: TButton + Left = 399 + Top = 121 + Width = 65 + Height = 38 + Caption = #36873#25321#21697#21517 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = 20 + Font.Name = #24494#36719#38597#40657 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 36 + OnClick = Button14Click + end + object Button15: TButton + Left = 98 + Top = 500 + Width = 88 + Height = 53 + Caption = #25552#20132#37325#37327 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -19 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 37 + OnClick = Button15Click + end + object Button16: TButton + Left = 4 + Top = 501 + Width = 86 + Height = 50 + Caption = #25552#20132#31859#25968 + Font.Charset = GB2312_CHARSET + Font.Color = clWindowText + Font.Height = -19 + Font.Name = #23435#20307 + Font.Style = [fsBold] + ParentFont = False + TabOrder = 38 + OnClick = Button16Click + end end object MovePanel1: TMovePanel Left = 910 @@ -2486,8 +2562,8 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF end end object Panel3: TPanel - Left = 610 - Top = 332 + Left = 595 + Top = 308 Width = 353 Height = 334 BevelInner = bvRaised @@ -3890,4 +3966,11 @@ object frmMJManageNewFDNewSF: TfrmMJManageNewFDNewSF Top = 544 ReportData = {} end + object ADOQuery1: TADOQuery + Connection = DataLink_TradeManage.ADOLink + LockType = ltReadOnly + Parameters = <> + Left = 224 + Top = 372 + end end diff --git a/复合检验管理/U_MJManageNewFDNew.pas b/复合检验管理/U_MJManageNewFDNew.pas index 05fb6f5..92b2597 100644 --- a/复合检验管理/U_MJManageNewFDNew.pas +++ b/复合检验管理/U_MJManageNewFDNew.pas @@ -265,7 +265,7 @@ type KH: TBtnEditA; Label54: TLabel; Label55: TLabel; - PM: TBtnEditA; + GY: TBtnEditA; Label56: TLabel; Label57: TLabel; YS: TBtnEditA; @@ -320,6 +320,12 @@ type bqkh: TBtnEditA; Button5: TButton; Tv3Column6: TcxGridDBColumn; + Label62: TLabel; + PM: TBtnEditA; + Button14: TButton; + Button15: TButton; + Button16: TButton; + ADOQuery1: TADOQuery; procedure FormDestroy(Sender: TObject); procedure FormClose(Sender: TObject; var Action: TCloseAction); procedure TBCloseClick(Sender: TObject); @@ -394,12 +400,15 @@ type procedure SpeedButton19DblClick(Sender: TObject); procedure Button13Click(Sender: TObject); procedure Button5Click(Sender: TObject); + procedure Button14Click(Sender: TObject); + procedure Button15Click(Sender: TObject); + procedure Button16Click(Sender: TObject); private { Private declarations } FInt, PState, PrintInt, SCInitGrid, FState, FCK: Integer; - FColumn, FBanZu, FAPID, FMainId, FSubId, FFFMJID: string; + FColumn, FBanZu, FAPID, FMainId, FSubId, FFFMJID, FFFMJID1, Fzlmjid, Fzlmjxh: string; FJZ, FJC, FDC: Double; - fRollType, fRollType1, fbaotype, fbaosx: string; + fRollType, fRollType1, fbaotype, fbaosx, Ftj: string; isCommopen, IsJsMessage: boolean; MValue, FCDName, MggCDFalg: string; fxsws, fxsws1: string; @@ -680,7 +689,7 @@ procedure TfrmMJManageNewFDNewSF.InitCDGridID(); begin with ADOQueryMain do begin - Close; + Close; SQL.Clear; sql.Add('select '); //sql.Add('Case when isnull(MJType,'''')=''Ʒ'' then ''B''+RTrim(Cast(MJXH as varchar(20))) else Cast(MJXH as varchar(20)) end as MJXH ,'); @@ -979,6 +988,8 @@ begin FMJID := '' else if PState = 2 then FMJID := Trim(CDS_MJID.fieldbyname('MJID').AsString) + else if PState = 33 then + FMJID := Trim(Fzlmjid) else if PState < 1 then Exit; @@ -1108,11 +1119,21 @@ begin FieldByName('MJstr3').Value := Trim(MJstr3.Text); FieldByName('MJstr4').Value := Trim(MJstr4.Text); FieldByName('MJstr5').Value := Trim(MJstr5.Text); - FieldByName('mjxh').Value := Trim(mjxh.Text); +// FieldByName('mjxh').Value := Trim(mjxh.Text); + if (PState = 33) then + begin + FieldByName('mjxh').value := Trim(Fzlmjxh); + end + else + begin + FieldByName('mjxh').value := Trim(mjxh.Text); + end; + + // FieldByName('BaoNO').Value := Trim(BaoNO.Text); FieldByName('MJTypeOther').Value := Trim(Label9.Caption); FieldByName('MJStr1').Value := Trim(Label13.Caption); - + FieldByName('GY').Value := Trim(GY.Text); FieldByName('PM').Value := Trim(PM.Text); FieldByName('KH').Value := Trim(KH.Text); FieldByName('BQKH').Value := Trim(bqkh.Text); @@ -1142,15 +1163,23 @@ begin FieldByName('MJQty1').Value := StrToFloatdef(trim(MJQty1.Text), 0); FieldByName('MJQty2').Value := StrToFloatdef(trim(MJQty2.Text), 0); FieldByName('MJQty3').Value := StrToFloatdef(trim(MJQty3.Text), 0); - FieldByName('MJQty4').Value := StrToFloatdef(trim(MJQty4.Text), 0) + fjZ; + if (PState = 2) or (Ftj = 'ύ') or (PState = 33) then + begin + FieldByName('MJQty4').value := StrToFloatdef(trim(MJQty4.Text), 0) + fjZ; + if Trim(MJMaoZ.Text) <> '' then + begin + FieldByName('MJMaoZ').value := StrToFloat(MJMaoZ.Text) + fjz; + end; + end; +// FieldByName('MJQty4').Value := StrToFloatdef(trim(MJQty4.Text), 0) + fjZ; if Trim(MJFK.Text) <> '' then begin FieldByName('MJFK').Value := MJFK.Text; end; - if Trim(MJMaoZ.Text) <> '' then - begin - FieldByName('MJMaoZ').Value := StrToFloat(MJMaoZ.Text) + fjz; - end; +// if Trim(MJMaoZ.Text) <> '' then +// begin +// FieldByName('MJMaoZ').Value := StrToFloat(MJMaoZ.Text) + fjz; +// end; if Trim(MJSJKZ.Text) <> '' then begin FieldByName('MJSJKZ').Value := MJSJKZ.Text; @@ -1638,6 +1667,7 @@ begin ADOCmd.Connection.RollbackTrans; Application.MessageBox('ʧܣ', 'ʾ', 0); end; + Ftj := ''; end; procedure TfrmMJManageNewFDNewSF.BTAddClick(Sender: TObject); @@ -1666,7 +1696,7 @@ var mvalue1: integer; i: Integer; begin - + Ftj := 'ύ'; if (strtofloatdef(trim(MJLen.Text), 0) = 0) and (strtofloatdef(trim(mjqty4.Text), 0) = 0) then begin application.MessageBox('ȻܶΪ㣡', 'ʾϢ', 0); @@ -1843,7 +1873,7 @@ var Moudle: THandle; Makebar: TMakebar; Mixtext: TMixtext; -begin +begin with ADOQueryPrint do begin @@ -2543,6 +2573,7 @@ begin Label2.Caption := ':' + Trim(ADOTmp.fieldbyname('PRTHX').AsString); end; PM.Text := Trim(ADOTmp.fieldbyname('PRTCodeName').AsString); + GY.Text := Trim(ADOTmp.fieldbyname('PRTgy').AsString); KH.Text := Trim(ADOTmp.fieldbyname('CustomerNoName').AsString); bqkh.Text := Trim(ADOTmp.fieldbyname('BQCustomer').AsString); YS.Text := Trim(ADOTmp.fieldbyname('PRTColor').AsString); @@ -3194,10 +3225,10 @@ begin frmSCPersonColor := TfrmSCPersonColor.Create(self); with frmSCPersonColor do begin - FTYPE := 'PM'; + FTYPE := 'GY'; if ShowModal = 1 then begin - PM.Text := FName; + GY.Text := FName; end; end; finally @@ -3403,5 +3434,270 @@ begin end; end; +procedure TfrmMJManageNewFDNewSF.Button14Click(Sender: TObject); +begin + try + frmSCPersonColor := TfrmSCPersonColor.Create(self); + with frmSCPersonColor do + begin + FTYPE := 'PM'; + if ShowModal = 1 then + begin + PM.Text := FName; + end; + end; + finally + frmSCPersonColor.close; + end; +end; + +procedure TfrmMJManageNewFDNewSF.Button15Click(Sender: TObject); +var + FMJID1: string; + mzlen, jzlen: Double; + fPrintFile: string; + mvalue: Double; + mvalue1: integer; + i: Integer; +begin + begin +// Y1 := false; + PState := 33; + if Edit9.text <> '' then + begin + if (strtofloatdef(trim(MJMaoZ.Text), 0) = 0) then + begin + application.MessageBox('Ϊ㣡', 'ʾϢ', 0); + exit; + end; + end; + + with ADOQuery1 do + begin + Close; + sql.Clear; +// SQL.Add('select mjid from WFB_MJJY where mainID=''' + Trim(FmainID) + ''' and subID=''' + Trim(FAPID) + ''' and MJQTY4=0 and mjstr4=''' + Trim(mjstr4.text) + ''' and MJxh= (select DISTINCT min(MJXH) from WFB_MJJY where mainID=''' + Trim(FmainID) + ''' and subID=''' + Trim(FAPID) + ''' and MJQTY4=0 and mjstr4=''' + Trim(mjstr4.text) + ''')'); + SQL.Add('select mjid,mjxh from WFB_MJJY where mainID=''' + Trim(FmainID) + ''' and subID=''' + Trim(FAPID) + ''' and MJQTY4=0 '); + SQL.Add('and isnull(mjstr4,'''')=''' + Trim(mjstr4.text) + ''' '); + if Trim(Edit13.Text) <> '' then + begin + sql.Add('and FillTime>=getdate()-1'); + end; + SQL.Add(' and MJxh= (select DISTINCT min(MJXH) from WFB_MJJY where mainID=''' + Trim(FmainID) + ''' and subID=''' + Trim(FAPID) + ''' '); + if Trim(Edit13.Text) <> '' then + begin + sql.Add('and FillTime>=getdate()-1'); + end; + SQL.Add(' and MJQTY4=0 and isnull(mjstr4,'''')=''' + Trim(mjstr4.text) + ''')'); + Open; +// showmessage(sql.text); + end; + if Trim(ADOQuery1.fieldbyname('MJID').AsString) = '' then + begin + PState := 1; + application.MessageBox('ûоΪ0ݣ', 'ʾ'); + exit; + end; + FMJID1 := Trim(ADOQuery1.fieldbyname('MJID').AsString); + FFFMJID1 := Trim(ADOQuery1.fieldbyname('MJID').AsString); + Fzlmjid := Trim(ADOQuery1.fieldbyname('MJID').AsString); + Fzlmjxh := Trim(ADOQuery1.fieldbyname('MJXH').AsString); + + Button16.Click; + end; +end; + +procedure TfrmMJManageNewFDNewSF.Button16Click(Sender: TObject); +var + fPrintFile: string; + mvalue: Double; + mvalue1: integer; + i: Integer; +begin + if Trim(FAPID) = '' then + Exit; + if (strtofloatdef(trim(MJLen.Text), 0) = 0) and (strtofloatdef(trim(mjqty4.Text), 0) = 0) then + begin + application.MessageBox('ȻܶΪ㣡', 'ʾϢ', 0); + exit; + end; + + if trim(MJXH.text) = '' then + begin + application.MessageBox('ŲΪ', 'ʾ'); + exit; + end; + + if trim(MJXH.text) = '0' then + begin + application.MessageBox('ŲΪ0', 'ʾ'); + exit; + end; + if trim(Label9.Caption) = '' then + begin + Application.MessageBox('ȵλΪ!', 'ʾ', 0); + Exit; + end; + + if Trim(MJQty1.Text) <> '' then + begin + if TryStrToFloat(MJQty1.Text, mvalue) = False then + begin + Application.MessageBox('ԭ¼!', 'ʾ', 0); + Exit; + end; + end; + if Trim(MJMaoZ.Text) <> '' then + begin + if TryStrToFloat(MJMaoZ.Text, mvalue) = False then + begin + Application.MessageBox('¼!', 'ʾ', 0); + Exit; + end; + end; + + if Trim(MJQty2.Text) <> '' then + begin + if TryStrToFloat(MJQty2.Text, mvalue) = False then + begin + Application.MessageBox('¼!', 'ʾ', 0); + Exit; + end; + end; +// if (strtofloatdef(trim(MJLen.Text), 0) > 200) then +// begin +// application.MessageBox('Ȳܴ200', 'ʾϢ', 0); +// exit; +// end; + if Trim(Edit6.Text) <> '' then + begin + with ADOTmp do + begin + Close; + sql.Clear; + sql.Add('select * from JYorder_Sub where Subid=''' + Trim(FSubId) + ''' and isnull(Slbname,'''')<>'''' '); + Open; + end; + if ADOTmp.IsEmpty then + begin + PlaySound('wav\ûñǩ.wav', 0, SND_FILENAME or SND_ASYNC); + Application.MessageBox('ûñǩ', 'ʾ', 0); + Exit; + end + else + begin + fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\' + Trim(ADOTmp.fieldbyname('Slbname').AsString); + if FileExists(fPrintFile) then + begin + + end + else + begin + PlaySound('wav\ǩûҵ.wav', 0, SND_FILENAME or SND_ASYNC); + Application.MessageBox('ǩûҵ볢µ¼пܱǩûϴ', 'ʾ', 0); + Exit; + end; + end; + end; + + BTPrint.Enabled := False; + Timer1.Enabled := True; + if SaveData() then + begin + MJMaoZ.Text := ''; + MJQty1.Text := ''; +// MJQty2.Text := ''; +// MJQty5.Text := ''; + Label15.Caption := ''; + MJQty4.Text := ''; + + if edit10.Text = '' then + begin + MJXH.Text := inttostr(strTointdef(trim(MJXH.Text), 0) - 1); + end + else + begin + MJXH.Text := inttostr(strTointdef(trim(MJXH.Text), 0) + 1); + end; + if PState = 1 then + begin + PlaySound('wav\ȷ.wav', 0, SND_FILENAME or SND_ASYNC); + end + else if PState = 2 then + begin + PlaySound('wav\޸ijɹ.wav', 0, SND_FILENAME or SND_ASYNC); + end; + if PState = 2 then + begin + apid.Text := FAPID; + Button3.Click; + end; + + end + else + exit; + if ((Trim(Edit7.text) = '') and (Trim(Edit9.text) = '')) or (PState = 2) or (PState = 33) then + begin + if Trim(Edit6.Text) = '' then + begin + PrtData(FFFMJID); + end; + end; +// if (Trim(Edit6.Text) = '') and (PState='33') then +// begin +// PrtData(FFFMJID); +// end; + + if Trim(Edit6.Text) = '' then + begin + if (fbaotype = 'ֶ') or (fbaotype = '') then + begin + + end + else + begin + with ADOCmd do + begin + Close; + sql.Clear; + sql.Add('exec P_View_Baoid ''' + trim(FFFMJID) + ''' '); + sql.Add(',''' + trim(FMainId) + ''' ,''' + trim(FSubId) + ''' '); + if fbaotype = '' then + begin + sql.Add(' ,1 '); + end; + if fbaotype = 'ɫ' then + begin + sql.Add(' ,2 '); + end; + if fbaotype = 'ɫ' then + begin + sql.Add(' ,3 '); + end; + Open; + end; + + if ADOCmd.FieldByName('baoid').AsString <> '' then + begin + baoNo.Text := inttostr(ADOCmd.fieldbyname('baoNo').AsInteger + 1); + PrtBaoData(ADOCmd.fieldbyname('baoid').AsString); + end; + end; + + end; + + Label16.Caption := ''; +// if (PState <> 33) then +// begin +// if trim(JCYDLL) <> '' then +// clearCom(JCYDLL); +// end; + + BTAdd.Click; + MJLen.SetFocus; + MJQty4.OnClick(MJQty4); + +end; + end. diff --git a/复合检验管理/U_OrderInPut.dfm b/复合检验管理/U_OrderInPut.dfm index 230274a..a13b291 100644 --- a/复合检验管理/U_OrderInPut.dfm +++ b/复合检验管理/U_OrderInPut.dfm @@ -1717,6 +1717,19 @@ object frmOrderInPut: TfrmOrderInPut HeaderAlignmentHorz = taCenter Width = 79 end + object Tv1Column2: TcxGridDBColumn + Caption = #24037#33402 + DataBinding.FieldName = 'PRTgy' + PropertiesClassName = 'TcxButtonEditProperties' + Properties.Buttons = < + item + Default = True + Kind = bkEllipsis + end> + Properties.OnButtonClick = Tv1Column2PropertiesButtonClick + HeaderAlignmentHorz = taCenter + Width = 60 + end object v1Column4: TcxGridDBColumn Caption = #21697#21517#33521#25991 DataBinding.FieldName = 'Sorddefstr5' diff --git a/复合检验管理/U_OrderInPut.pas b/复合检验管理/U_OrderInPut.pas index 372df17..227ffa4 100644 --- a/复合检验管理/U_OrderInPut.pas +++ b/复合检验管理/U_OrderInPut.pas @@ -192,6 +192,7 @@ type Tv1Column1: TcxGridDBColumn; Label56: TLabel; BQCustomer: TBtnEditC; + Tv1Column2: TcxGridDBColumn; procedure TBCloseClick(Sender: TObject); procedure FormShow(Sender: TObject); procedure TBSaveClick(Sender: TObject); @@ -225,6 +226,7 @@ type procedure v1PRTHXPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure v1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); procedure BQCustomerBtnUpClick(Sender: TObject); + procedure Tv1Column2PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); private procedure InitData(); procedure ZDYHelp(FButn: TcxButtonEdit; LType: string); @@ -1799,5 +1801,24 @@ begin end; end; +procedure TfrmOrderInPut.Tv1Column2PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer); +begin + try + frmZDYHelp := TfrmZDYHelp.Create(Application); + with frmZDYHelp do + begin + flag := 'PRTgy'; + flagname := ''; + if ShowModal = 1 then + begin + Self.Order_Sub.Edit; + Self.Order_Sub.FieldByName('PRTgy').Value := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString); + end; + end; + finally + frmZDYHelp.Free; + end; +end; + end. diff --git a/复合检验管理/U_SCPersonColor.pas b/复合检验管理/U_SCPersonColor.pas index 789fd27..5fc54b0 100644 --- a/复合检验管理/U_SCPersonColor.pas +++ b/复合检验管理/U_SCPersonColor.pas @@ -76,9 +76,9 @@ var i, j: Integer; begin with ADOTmp do - begin + begin Close; - sql.Clear; + sql.Clear; if FTYPE = 'KH' then begin sql.Add('select AA.*,row_number () over (order by name) as keyNo from(select DISTINCT zdyname as name,note from kh_zdy where type=''CustomerNoName'')AA'); @@ -92,6 +92,10 @@ begin begin sql.Add('select AA.*,row_number () over (order by name) as keyNo from(select DISTINCT zdyname as name,note from kh_zdy where type=''PRTCodeName'')AA'); end + else if FTYPE = 'GY' then + begin + sql.Add('select AA.*,row_number () over (order by name) as keyNo from(select DISTINCT zdyname as name,note from kh_zdy where type=''PRTgy'')AA'); + end else if FTYPE = 'YS' then begin sql.Add('select AA.*,row_number () over (order by name) as keyNo from(select DISTINCT zdyname as name,note from kh_zdy where type=''PRTColor'')AA');