~
This commit is contained in:
parent
d94eb90043
commit
a1881aa2b0
185
基础数据/U_CPTypeBM.dfm
Normal file
185
基础数据/U_CPTypeBM.dfm
Normal file
|
@ -0,0 +1,185 @@
|
|||
object frmCPTypeBM: TfrmCPTypeBM
|
||||
Left = 281
|
||||
Top = 184
|
||||
Width = 870
|
||||
Height = 505
|
||||
Caption = #37096#38376#31867#21035
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 854
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 83
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
DisabledImages = BaseData10_DataLink.ThreeImgList
|
||||
Flat = True
|
||||
Images = BaseData10_DataLink.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 9
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBAdd: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686#23376#31867
|
||||
ImageIndex = 3
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 150
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20445#23384
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 213
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 17
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object cxDBTreeList1: TcxDBTreeList
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 249
|
||||
Height = 433
|
||||
Align = alLeft
|
||||
Bands = <
|
||||
item
|
||||
end>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.ParentField = 'CPParent'
|
||||
DataController.KeyField = 'CPID'
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OptionsBehavior.ExpandOnDblClick = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.CellAutoHeight = True
|
||||
OptionsView.Headers = False
|
||||
RootValue = -1
|
||||
TabOrder = 1
|
||||
OnClick = cxDBTreeList1Click
|
||||
object cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn
|
||||
DataBinding.FieldName = 'CPName'
|
||||
Width = 210
|
||||
Position.ColIndex = 0
|
||||
Position.RowIndex = 0
|
||||
Position.BandIndex = 0
|
||||
Summary.FooterSummaryItems = <>
|
||||
Summary.GroupFooterSummaryItems = <>
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 270
|
||||
Top = 54
|
||||
Width = 315
|
||||
Height = 150
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 2
|
||||
object Label1: TLabel
|
||||
Left = 66
|
||||
Top = 24
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #29238' '#31867
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 66
|
||||
Top = 65
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #31867#21035#21517#31216
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 66
|
||||
Top = 105
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #31867#21035#32534#30721
|
||||
end
|
||||
object CPTopName: TEdit
|
||||
Left = 129
|
||||
Top = 21
|
||||
Width = 121
|
||||
Height = 20
|
||||
ReadOnly = True
|
||||
TabOrder = 0
|
||||
end
|
||||
object CPName: TEdit
|
||||
Left = 129
|
||||
Top = 61
|
||||
Width = 121
|
||||
Height = 20
|
||||
TabOrder = 1
|
||||
OnKeyPress = CPNameKeyPress
|
||||
end
|
||||
object CPNo: TEdit
|
||||
Left = 129
|
||||
Top = 101
|
||||
Width = 121
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
end
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = ADOQueryTree
|
||||
Left = 91
|
||||
Top = 147
|
||||
end
|
||||
object ADOQueryTree: TADOQuery
|
||||
Connection = BaseData10_DataLink.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 117
|
||||
Top = 145
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = BaseData10_DataLink.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 709
|
||||
Top = 209
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = BaseData10_DataLink.ADOLink
|
||||
Parameters = <>
|
||||
Left = 677
|
||||
Top = 137
|
||||
end
|
||||
end
|
270
基础数据/U_CPTypeBM.pas
Normal file
270
基础数据/U_CPTypeBM.pas
Normal file
|
@ -0,0 +1,270 @@
|
|||
unit U_CPTypeBM;
|
||||
|
||||
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,
|
||||
ExtCtrls, cxLookAndFeels, cxLookAndFeelPainters, cxTLdxBarBuiltInMenu,
|
||||
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;
|
||||
|
||||
type
|
||||
TfrmCPTypeBM = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBAdd: TToolButton;
|
||||
TBDel: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
cxDBTreeList1: TcxDBTreeList;
|
||||
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
|
||||
DataSource1: TDataSource;
|
||||
ADOQueryTree: TADOQuery;
|
||||
ToolButton1: TToolButton;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
Panel1: TPanel;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
Label3: TLabel;
|
||||
CPTopName: TEdit;
|
||||
CPName: TEdit;
|
||||
CPNo: TEdit;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure TBAddClick(Sender: TObject);
|
||||
procedure cxDBTreeList1Click(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure TBDelClick(Sender: TObject);
|
||||
procedure CPNameKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure FormShow(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
PState: Integer;
|
||||
FCPID, FTopID: string;
|
||||
procedure InitTree();
|
||||
public
|
||||
FState: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmCPTypeBM: TfrmCPTypeBM;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmCPTypeBM.InitTree();
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
with ADOQueryTree do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from BD_Staff_bumen order by CPlevel,CPOrder,CPName');
|
||||
Open;
|
||||
end;
|
||||
cxDBTreeList1.Items[0].Expand(false);
|
||||
//cxDBTreeList1.Items[1].Expand(False);
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmCPTypeBM := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitTree();
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.TBAddClick(Sender: TObject);
|
||||
begin
|
||||
PState := 11;
|
||||
CPTopName.Text := Trim(ADOQueryTree.fieldbyname('CPName').AsString);
|
||||
//FTopID:=Trim(ADOQueryTree.fieldbyname('CPID').AsString);
|
||||
FCPID := '';
|
||||
CPName.Text := '';
|
||||
CPNo.Text := '';
|
||||
CPName.SetFocus;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.cxDBTreeList1Click(Sender: TObject);
|
||||
begin
|
||||
PState := 22;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from BD_Staff_bumen where CPID=''' + Trim(ADOQueryTree.fieldbyname('CPParent').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
FCPID := Trim(ADOQueryTree.fieldbyname('CPID').AsString);
|
||||
CPTopName.Text := Trim(ADOQueryTemp.fieldbyname('CPName').AsString);
|
||||
CPName.Text := Trim(ADOQueryTree.fieldbyname('CPName').AsString);
|
||||
CPNo.Text := Trim(ADOQueryTree.fieldbyname('CPNo').AsString);
|
||||
if FState = '选择' then
|
||||
begin
|
||||
ModalResult := 1;
|
||||
// FCPID := Trim(ADOQueryTree.fieldbyname('CPName').AsString);
|
||||
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.ToolButton1Click(Sender: TObject);
|
||||
var
|
||||
maxId: string;
|
||||
begin
|
||||
if Trim(CPName.Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('类别名称不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(CPNo.Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('类别编码不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
if PState = 11 then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd, maxId, 'CP', 'BD_Staff_bumen', 4, 1) = False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('区最大号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxId := Trim(FCPID);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select * from BD_Staff_bumen where CPID=''' + Trim(FCPID) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if PState = 11 then
|
||||
begin
|
||||
Append;
|
||||
FieldByName('CPID').Value := Trim(maxId);
|
||||
FieldByName('CPName').Value := Trim(CPName.Text);
|
||||
FieldByName('CPNo').Value := Trim(CPNo.Text);
|
||||
FieldByName('CPParent').Value := Trim(ADOQueryTree.fieldbyname('CPID').AsString);
|
||||
FieldByName('CPLevel').Value := ADOQueryTree.fieldbyname('CPLevel').AsInteger + 1;
|
||||
Post;
|
||||
end
|
||||
else if PState = 22 then
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('CPID').Value := Trim(maxId);
|
||||
FieldByName('CPName').Value := Trim(CPName.Text);
|
||||
FieldByName('CPNo').Value := Trim(CPNo.Text);
|
||||
//FieldByName('CPParent').Value:=Trim(ADOQueryTree.fieldbyname('CPID').AsString);
|
||||
//FieldByName('CPOrder').Value:=ADOQueryTree.fieldbyname('CPOrder').AsInteger+1;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Application.MessageBox('保存成功!', '提示', 0);
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存失败!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.TBDelClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryTree.FieldByName('CPLevel').AsInteger = 0 then
|
||||
Exit;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from BD_Staff_bumen where CPParent=''' + Trim(ADOQueryTree.fieldbyname('CPID').AsString) + '''');
|
||||
Open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
Application.MessageBox('已经定义子类不能删除!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from CP_YDang where CYType=''' + Trim(ADOQueryTree.fieldbyname('CPID').AsString) + '''');
|
||||
Open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
Application.MessageBox('已经有产品属于此类不能删除!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('delete BD_Staff_bumen where CPID=''' + Trim(ADOQueryTree.fieldbyname('CPID').AsString) + '''');
|
||||
sql.Add('delete BD_Staff_bumen where CPParent=''' + Trim(ADOQueryTree.fieldbyname('CPID').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
InitTree();
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.CPNameKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
CPNo.SetFocus;
|
||||
end;
|
||||
|
||||
procedure TfrmCPTypeBM.FormShow(Sender: TObject);
|
||||
begin
|
||||
if FState = '选择' then
|
||||
begin
|
||||
TBAdd.Visible := False;
|
||||
TBAdd.Visible := False;
|
||||
TBDel.Visible := False;
|
||||
|
||||
end;
|
||||
InitTree();
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -15,7 +15,7 @@ function GetsysParam(muserId: pchar; fparam1: pchar): Boolean;
|
|||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_getDogServer, U_UserList, U_User_bz_List;
|
||||
U_DataLink, U_getDogServer, U_UserList, U_User_bz_List,U_CPTypeBM;
|
||||
|
||||
/////////////////////////////////////////////////////////////////
|
||||
// 功能说明:取Dll中得窗体 //
|
||||
|
@ -119,6 +119,26 @@ begin
|
|||
mnewHandle := frmUserList.Handle;
|
||||
|
||||
end;
|
||||
3: // ²¿ÃŹÜÀí
|
||||
begin
|
||||
if frmCPTypeBM = nil then
|
||||
begin
|
||||
frmCPTypeBM := TfrmCPTypeBM.Create(application.MainForm);
|
||||
with frmCPTypeBM do
|
||||
begin
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmCPTypeBM.BringToFront;
|
||||
//¾ä±ú
|
||||
mnewHandle := frmCPTypeBM.Handle;
|
||||
|
||||
end;
|
||||
2: // 样品类别
|
||||
begin
|
||||
if frmUser_bz_List = nil then
|
||||
|
|
|
@ -238,22 +238,13 @@ object frmUser10: TfrmUser10
|
|||
TabOrder = 5
|
||||
OnKeyPress = userIDKeyPress
|
||||
end
|
||||
object Udept: TEdit
|
||||
Tag = 2
|
||||
Left = 112
|
||||
Top = 168
|
||||
Width = 120
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnKeyPress = userIDKeyPress
|
||||
end
|
||||
object UType: TEdit
|
||||
Tag = 2
|
||||
Left = 112
|
||||
Top = 196
|
||||
Width = 120
|
||||
Height = 20
|
||||
TabOrder = 7
|
||||
TabOrder = 6
|
||||
OnKeyPress = userIDKeyPress
|
||||
end
|
||||
object cxOK: TcxButton
|
||||
|
@ -262,7 +253,7 @@ object frmUser10: TfrmUser10
|
|||
Width = 75
|
||||
Height = 25
|
||||
Caption = #25552#20132
|
||||
TabOrder = 8
|
||||
TabOrder = 7
|
||||
OnClick = cxOKClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
LookAndFeel.NativeStyle = False
|
||||
|
@ -273,7 +264,7 @@ object frmUser10: TfrmUser10
|
|||
Width = 75
|
||||
Height = 25
|
||||
Caption = #20851#38381
|
||||
TabOrder = 9
|
||||
TabOrder = 8
|
||||
OnClick = cxCloseClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
LookAndFeel.NativeStyle = False
|
||||
|
@ -285,7 +276,7 @@ object frmUser10: TfrmUser10
|
|||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
PasswordChar = '*'
|
||||
TabOrder = 10
|
||||
TabOrder = 9
|
||||
Visible = False
|
||||
OnKeyPress = userIDKeyPress
|
||||
end
|
||||
|
@ -296,7 +287,7 @@ object frmUser10: TfrmUser10
|
|||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
PasswordChar = '*'
|
||||
TabOrder = 11
|
||||
TabOrder = 10
|
||||
Visible = False
|
||||
OnKeyPress = userIDKeyPress
|
||||
end
|
||||
|
@ -306,7 +297,7 @@ object frmUser10: TfrmUser10
|
|||
Top = 116
|
||||
Width = 357
|
||||
Height = 20
|
||||
TabOrder = 12
|
||||
TabOrder = 11
|
||||
end
|
||||
object phone: TEdit
|
||||
Tag = 2
|
||||
|
@ -314,7 +305,7 @@ object frmUser10: TfrmUser10
|
|||
Top = 144
|
||||
Width = 120
|
||||
Height = 20
|
||||
TabOrder = 13
|
||||
TabOrder = 12
|
||||
end
|
||||
object position: TBtnEditC
|
||||
Tag = 2
|
||||
|
@ -324,7 +315,7 @@ object frmUser10: TfrmUser10
|
|||
Height = 20
|
||||
Hint = 'position/'#24037#31181
|
||||
ReadOnly = True
|
||||
TabOrder = 14
|
||||
TabOrder = 13
|
||||
OnBtnUpClick = positionBtnUpClick
|
||||
OnBtnDnClick = positionBtnDnClick
|
||||
end
|
||||
|
@ -334,7 +325,7 @@ object frmUser10: TfrmUser10
|
|||
Top = 168
|
||||
Width = 121
|
||||
Height = 20
|
||||
TabOrder = 15
|
||||
TabOrder = 14
|
||||
end
|
||||
object note: TMemo
|
||||
Tag = 2
|
||||
|
@ -343,7 +334,7 @@ object frmUser10: TfrmUser10
|
|||
Width = 357
|
||||
Height = 61
|
||||
ScrollBars = ssVertical
|
||||
TabOrder = 16
|
||||
TabOrder = 15
|
||||
end
|
||||
object valid: TComboBox
|
||||
Left = 348
|
||||
|
@ -353,7 +344,7 @@ object frmUser10: TfrmUser10
|
|||
Style = csDropDownList
|
||||
ItemHeight = 12
|
||||
ItemIndex = 0
|
||||
TabOrder = 17
|
||||
TabOrder = 16
|
||||
Text = #26159
|
||||
Items.Strings = (
|
||||
#26159
|
||||
|
@ -369,7 +360,7 @@ object frmUser10: TfrmUser10
|
|||
Properties.ReadOnly = True
|
||||
Properties.ShowFocusRect = False
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 18
|
||||
TabOrder = 17
|
||||
Visible = False
|
||||
OnDblClick = Picture4DblClick
|
||||
Height = 220
|
||||
|
@ -382,7 +373,7 @@ object frmUser10: TfrmUser10
|
|||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #36523#20221#35777#27491#38754
|
||||
TabOrder = 19
|
||||
TabOrder = 18
|
||||
Visible = False
|
||||
OnClick = FileNameClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
|
@ -397,7 +388,7 @@ object frmUser10: TfrmUser10
|
|||
Properties.ReadOnly = True
|
||||
Properties.ShowFocusRect = False
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 20
|
||||
TabOrder = 19
|
||||
Visible = False
|
||||
OnDblClick = Picture4DblClick
|
||||
Height = 220
|
||||
|
@ -410,11 +401,32 @@ object frmUser10: TfrmUser10
|
|||
Height = 25
|
||||
Hint = 'Filesother1'
|
||||
Caption = #36523#20221#35777#32972#38754
|
||||
TabOrder = 21
|
||||
TabOrder = 20
|
||||
Visible = False
|
||||
OnClick = FileNameClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object Udept: TBtnEditC
|
||||
Tag = 2
|
||||
Left = 112
|
||||
Top = 170
|
||||
Width = 121
|
||||
Height = 20
|
||||
Hint = 'Udept/'#37096#38376
|
||||
ReadOnly = True
|
||||
TabOrder = 21
|
||||
OnBtnUpClick = UdeptBtnUpClick
|
||||
OnBtnDnClick = UdeptBtnDnClick
|
||||
end
|
||||
object UdeptID: TEdit
|
||||
Tag = 2
|
||||
Left = 160
|
||||
Top = 288
|
||||
Width = 120
|
||||
Height = 20
|
||||
TabOrder = 22
|
||||
Visible = False
|
||||
end
|
||||
end
|
||||
object ADOQueryTmp: TADOQuery
|
||||
Connection = BaseData10_DataLink.ADOLink
|
||||
|
|
|
@ -3,24 +3,23 @@ unit U_User10;
|
|||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, strUtils,Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, Menus, cxLookAndFeelPainters, StdCtrls, cxButtons, DB, ADODB,
|
||||
Windows, Messages, SysUtils, strUtils, Variants, Classes, Graphics, Controls,
|
||||
Forms, Dialogs, Menus, cxLookAndFeelPainters, StdCtrls, cxButtons, DB, ADODB,
|
||||
BtnEdit, ComCtrls, ExtCtrls, cxControls, cxContainer, cxEdit, cxImage,
|
||||
cxDBEdit, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, ShellAPI,
|
||||
IdFTP, cxGraphics, cxLookAndFeels, 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;
|
||||
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;
|
||||
|
||||
type
|
||||
TfrmUser10 = class(TForm)
|
||||
|
@ -39,7 +38,6 @@ type
|
|||
Label8: TLabel;
|
||||
Label2: TLabel;
|
||||
userName: TEdit;
|
||||
Udept: TEdit;
|
||||
Label5: TLabel;
|
||||
Label6: TLabel;
|
||||
UType: TEdit;
|
||||
|
@ -68,6 +66,8 @@ type
|
|||
DataSource1: TDataSource;
|
||||
ADOQueryImage: TADOQuery;
|
||||
IdFTP1: TIdFTP;
|
||||
Udept: TBtnEditC;
|
||||
UdeptID: TEdit;
|
||||
procedure cxCloseClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure cxOKClick(Sender: TObject);
|
||||
|
@ -77,6 +77,8 @@ type
|
|||
procedure positionBtnDnClick(Sender: TObject);
|
||||
procedure FileNameClick(Sender: TObject);
|
||||
procedure Picture4DblClick(Sender: TObject);
|
||||
procedure UdeptBtnDnClick(Sender: TObject);
|
||||
procedure UdeptBtnUpClick(Sender: TObject);
|
||||
private
|
||||
fPassWord: string;
|
||||
fIsYGCodezdsc: Boolean;
|
||||
|
@ -94,7 +96,9 @@ var
|
|||
frmUser10: TfrmUser10;
|
||||
|
||||
implementation
|
||||
uses U_DataLink,U_Fun10,U_ZDYHelp,U_PublicFunction, getpic;
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun10, U_ZDYHelp, U_PublicFunction, getpic, U_CPTypeBM;
|
||||
{$R *.dfm}
|
||||
{procedure TfrmUser10.InitImage();
|
||||
begin
|
||||
|
@ -107,6 +111,7 @@ begin
|
|||
open;
|
||||
end;
|
||||
end;}
|
||||
|
||||
function TfrmUser10.SaveData(): Boolean;
|
||||
begin
|
||||
result := false;
|
||||
|
@ -124,8 +129,10 @@ begin
|
|||
sql.Add(' where userID=' + quotedstr(trim(fuserID)));
|
||||
open;
|
||||
|
||||
if ADO_Cmd.IsEmpty then ADO_Cmd.Append
|
||||
else ADO_Cmd.Edit;
|
||||
if ADO_Cmd.IsEmpty then
|
||||
ADO_Cmd.Append
|
||||
else
|
||||
ADO_Cmd.Edit;
|
||||
SSetsaveSqlNew(ADO_Cmd, 'BD_Staff', Panel1, 2);
|
||||
ADO_Cmd.FieldByName('userID').Value := trim(fuserID);
|
||||
// ADO_Cmd.FieldByName('username').Value:=trim(username.Text);
|
||||
|
@ -158,6 +165,7 @@ begin
|
|||
ADO_Cmd.Connection.RollbackTrans;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmUser10.DoQuery();
|
||||
begin
|
||||
with adoqueryTmp do
|
||||
|
@ -233,7 +241,8 @@ begin
|
|||
begin
|
||||
if fIsYGCodezdsc then
|
||||
begin
|
||||
if not GetMaxBh(ADO_Cmd,fuserID,'BD_Staff','YG','0',3) then exit;
|
||||
if not GetMaxBh(ADO_Cmd, fuserID, 'BD_Staff', 'YG', '0', 3) then
|
||||
exit;
|
||||
end
|
||||
else
|
||||
begin
|
||||
|
@ -266,7 +275,7 @@ end;
|
|||
procedure TfrmUser10.userIDKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
Key := UpCase(Key);
|
||||
if key=#13 then
|
||||
if Key = #13 then
|
||||
begin
|
||||
perform(WM_NEXTDLGCTL, 0, 0);
|
||||
Key := #0;
|
||||
|
@ -303,7 +312,7 @@ begin
|
|||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname:=Copy(fsj,FWZ+1,Length(fsj)-fwz);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if Trim(flag) = 'OrdDefStr2' then
|
||||
begin
|
||||
V1Name.Caption := '中文名称';
|
||||
|
@ -329,7 +338,7 @@ end;
|
|||
|
||||
procedure TfrmUser10.FileNameClick(Sender: TObject);
|
||||
begin
|
||||
IF trim(userID.Text)='' then
|
||||
if trim(userID.Text) = '' then
|
||||
begin
|
||||
application.MessageBox('产品编号不能为空!', '提示信息', MB_ICONERROR);
|
||||
exit;
|
||||
|
@ -345,7 +354,7 @@ begin
|
|||
FTFType := '员工信息';
|
||||
// pat1:='PatFile1';
|
||||
// pic1:='Picture1';
|
||||
IF ShowModal = 1 then
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
// self.Timage(Tbutton(Sender).Hint).Picture.Assign(FormGetPic.Image2.Picture.Bitmap);
|
||||
userID.Enabled := false;
|
||||
|
@ -355,7 +364,8 @@ begin
|
|||
end;
|
||||
// Initimage();
|
||||
except
|
||||
if FormGetPic<>nil then FormGetPic.Release;
|
||||
if FormGetPic <> nil then
|
||||
FormGetPic.Release;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
@ -365,7 +375,8 @@ var
|
|||
fileName: string;
|
||||
begin
|
||||
|
||||
IF TcxDBImage(Sender).Picture.Height=0 then exit;
|
||||
if TcxDBImage(Sender).Picture.Height = 0 then
|
||||
exit;
|
||||
|
||||
sFieldName := LeftBstr(ExtractFilePath(Application.ExeName), 1) + ':\图片查看';
|
||||
|
||||
|
@ -400,9 +411,42 @@ begin
|
|||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
if IdFTP1.Connected then
|
||||
IdFTP1.Quit;
|
||||
ShellExecute(Handle, 'open', PChar(sFieldName), '', '', SW_SHOWNORMAL);
|
||||
end;
|
||||
|
||||
procedure TfrmUser10.UdeptBtnDnClick(Sender: TObject);
|
||||
begin
|
||||
TBtnEditC(Sender).Text := '';
|
||||
TBtnEditC(Sender).TxtCode := '';
|
||||
end;
|
||||
|
||||
procedure TfrmUser10.UdeptBtnUpClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmCPTypeBM := TfrmCPTypeBM.Create(Application);
|
||||
with frmCPTypeBM do
|
||||
begin
|
||||
// flag:=Copy(fsj,1,FWZ-1);
|
||||
// flagname:=Copy(fsj,FWZ+1,Length(fsj)-fwz);
|
||||
// if Trim(flag)='OrdDefStr2' then
|
||||
// begin
|
||||
// V1Name.Caption:='ÖÐÎÄÃû³Æ';
|
||||
// V1Note.Caption:='±¸×¢ÐÅÏ¢';
|
||||
// fnote:=true;
|
||||
// end;
|
||||
FState := 'Ñ¡Ôñ';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ADOQueryTree.fieldbyname('CPName').AsString);
|
||||
UdeptID.Text := Trim(ADOQueryTree.fieldbyname('CPID').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmCPTypeBM.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
|
@ -192,6 +192,30 @@ object frmZdyAttInputPB: TfrmZdyAttInputPB
|
|||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column2: TcxGridDBColumn
|
||||
Caption = #20135#21697#32534#21495
|
||||
DataBinding.FieldName = 'ZdyCode'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column3: TcxGridDBColumn
|
||||
Caption = #38376#24133'(cm)'
|
||||
DataBinding.FieldName = 'DEFstr1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column4: TcxGridDBColumn
|
||||
Caption = #20811#37325'(g/'#13217')'
|
||||
DataBinding.FieldName = 'DEFstr2'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column5: TcxGridDBColumn
|
||||
Caption = #35268#26684
|
||||
DataBinding.FieldName = 'DEFstr4'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
|
|
|
@ -14,19 +14,19 @@ uses
|
|||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||
cxTextEdit, cxDropDownEdit, strutils, cxCurrencyEdit, cxLookAndFeels,
|
||||
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;
|
||||
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
|
||||
TfrmZdyAttInputPB = class(TForm)
|
||||
|
@ -57,6 +57,10 @@ type
|
|||
v2Mrate: TcxGridDBColumn;
|
||||
v2Column15: TcxGridDBColumn;
|
||||
Tv2Column1: TcxGridDBColumn;
|
||||
Tv2Column2: TcxGridDBColumn;
|
||||
Tv2Column3: TcxGridDBColumn;
|
||||
Tv2Column4: TcxGridDBColumn;
|
||||
Tv2Column5: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
|
@ -328,11 +332,11 @@ begin
|
|||
if trim(mvalue) = '' then
|
||||
exit;
|
||||
|
||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
begin
|
||||
mvalue := trim(mvalue) + '#';
|
||||
end;
|
||||
|
||||
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
// begin
|
||||
// mvalue := trim(mvalue) + '#';
|
||||
// end;
|
||||
mvalue := trim(mvalue);
|
||||
with CDS_HZ do
|
||||
begin
|
||||
Edit;
|
||||
|
|
|
@ -338,6 +338,30 @@ object frmZdyAttachPB: TfrmZdyAttachPB
|
|||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column2: TcxGridDBColumn
|
||||
Caption = #20135#21697#32534#21495
|
||||
DataBinding.FieldName = 'ZdyCode'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column3: TcxGridDBColumn
|
||||
Caption = #38376#24133'(cm)'
|
||||
DataBinding.FieldName = 'DEFstr1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column4: TcxGridDBColumn
|
||||
Caption = #20811#37325'(g/'#13217')'
|
||||
DataBinding.FieldName = 'DEFstr2'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv2Column5: TcxGridDBColumn
|
||||
Caption = #35268#26684
|
||||
DataBinding.FieldName = 'DEFstr4'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
|
|
|
@ -85,6 +85,10 @@ type
|
|||
cxButton1: TcxButton;
|
||||
cxButton2: TcxButton;
|
||||
Tv2Column1: TcxGridDBColumn;
|
||||
Tv2Column2: TcxGridDBColumn;
|
||||
Tv2Column3: TcxGridDBColumn;
|
||||
Tv2Column4: TcxGridDBColumn;
|
||||
Tv2Column5: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
object frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList
|
||||
Left = -8
|
||||
Top = -8
|
||||
Left = 389
|
||||
Top = 351
|
||||
Width = 1382
|
||||
Height = 754
|
||||
Caption = #25104#21697#24211#23384#27719#24635#21015#34920
|
||||
|
@ -279,11 +279,11 @@ object frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList
|
|||
Left = 0
|
||||
Top = 77
|
||||
Width = 1366
|
||||
Height = 639
|
||||
Height = 638
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
|
@ -319,8 +319,8 @@ object frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList
|
|||
Width = 144
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20013#25991#21517#31216
|
||||
DataBinding.FieldName = 'C_CodeName_ZW'
|
||||
Caption = #20135#21697#32534#21495
|
||||
DataBinding.FieldName = 'C_Code'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 120
|
||||
end
|
||||
|
@ -333,13 +333,13 @@ object frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList
|
|||
end
|
||||
object v1KCRollNum: TcxGridDBColumn
|
||||
Caption = #24211#23384#21305#25968
|
||||
DataBinding.FieldName = 'KCRollNum'
|
||||
DataBinding.FieldName = 'N_Ps'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 103
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Caption = #24211#23384#25968#37327
|
||||
DataBinding.FieldName = 'KCQty'
|
||||
DataBinding.FieldName = 'N_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 123
|
||||
|
@ -352,6 +352,12 @@ object frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList
|
|||
Options.Focusing = False
|
||||
Width = 83
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #33394#21495
|
||||
DataBinding.FieldName = 'C_COlorNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGrid2Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
|
|
|
@ -4,12 +4,25 @@ interface
|
|||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, MovePanel;
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridBandedTableView, cxGridDBBandedTableView, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridDBTableView, cxGrid, StdCtrls, ComCtrls,
|
||||
ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient,
|
||||
cxDropDownEdit, MovePanel, cxLookAndFeels, cxLookAndFeelPainters, 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, cxNavigator;
|
||||
|
||||
type
|
||||
TfrmCKProductBCPKCHZList = class(TForm)
|
||||
|
@ -58,6 +71,7 @@ type
|
|||
v1Column1: TcxGridDBColumn;
|
||||
C_CodeName_ZW: TEdit;
|
||||
Label11: TLabel;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
|
@ -79,6 +93,7 @@ var
|
|||
frmCKProductBCPKCHZList: TfrmCKProductBCPKCHZList;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun;
|
||||
|
||||
|
@ -89,8 +104,7 @@ begin
|
|||
frmCKProductBCPKCHZList := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCKProductBCPKCHZList.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
procedure TfrmCKProductBCPKCHZList.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
@ -111,10 +125,15 @@ begin
|
|||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' select sum(KCQty) KCQty,Sum(KCKgQty) KCKgQty,Sum(KCRollNum) KCRollNum,C_CodeName,C_Color,KCQtyUnit=''M'', ');
|
||||
sql.Add(' C_CodeName_ZW=(select Top 1 defnote3 from KH_Zdy_Attachment X where X.ZdyName=A.C_CodeName and X.Type=''CP'') ');
|
||||
sql.Add(' from CK_BanCP_KC A ');
|
||||
sql.Add(' where A.KCQty<>0 group by C_CodeName,C_Color');
|
||||
// sql.Add(' select sum(KCQty) KCQty,Sum(KCKgQty) KCKgQty,Sum(KCRollNum) KCRollNum,C_CodeName,C_Color,KCQtyUnit=''M'', ');
|
||||
// sql.Add(' C_CodeName_ZW=(select Top 1 defnote3 from KH_Zdy_Attachment X where X.ZdyName=A.C_CodeName and X.Type=''CP'') ');
|
||||
// sql.Add(' from CK_BanCP_KC A ');
|
||||
// sql.Add(' where A.KCQty<>0 group by C_CodeName,C_Color');
|
||||
sql.Add('exec P_Get_FabricStock');
|
||||
sql.Add('@begdate=''2000-01-01'' ');
|
||||
sql.Add(',@enddate=''2050-01-01'' ');
|
||||
sql.Add(',@conType=''³ÉÆ·Íê³É''');
|
||||
// ShowMessage(SQL.text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
|
@ -158,7 +177,8 @@ end;
|
|||
|
||||
procedure TfrmCKProductBCPKCHZList.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
TcxGridToExcel('¿â´æ»ã×ÜÁбí', cxGrid2);
|
||||
end;
|
||||
|
||||
|
@ -178,3 +198,4 @@ begin
|
|||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
|
@ -137,7 +137,7 @@ object frmClothContractInPut_CG: TfrmClothContractInPut_CG
|
|||
Top = 62
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #36865#36135#22320#22336#65306
|
||||
Caption = #23384#25918#22320#22336#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
|
@ -191,7 +191,7 @@ object frmClothContractInPut_CG: TfrmClothContractInPut_CG
|
|||
Width = 115
|
||||
Height = 18
|
||||
Enabled = False
|
||||
TabOrder = 0
|
||||
TabOrder = 1
|
||||
end
|
||||
object DeliveryDate: TDateTimePicker
|
||||
Left = 85
|
||||
|
@ -203,12 +203,12 @@ object frmClothContractInPut_CG: TfrmClothContractInPut_CG
|
|||
Format = 'yyyy-MM-dd'
|
||||
Time = 40916.000000000000000000
|
||||
ShowCheckbox = True
|
||||
TabOrder = 1
|
||||
TabOrder = 2
|
||||
end
|
||||
object FactoryNoName: TcxButtonEdit
|
||||
Left = 615
|
||||
Top = 10
|
||||
Hint = 'FactoryNo'
|
||||
Hint = 'FactoryNoName'
|
||||
BeepOnEnter = False
|
||||
Properties.Buttons = <
|
||||
item
|
||||
|
@ -218,7 +218,7 @@ object frmClothContractInPut_CG: TfrmClothContractInPut_CG
|
|||
Properties.OnButtonClick = FactoryNoNamePropertiesButtonClick
|
||||
Properties.OnChange = FactoryNoNamePropertiesChange
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 2
|
||||
TabOrder = 0
|
||||
OnKeyDown = PRTCodeNameKeyDown
|
||||
Width = 132
|
||||
end
|
||||
|
|
|
@ -290,7 +290,7 @@ begin
|
|||
Open;
|
||||
end;
|
||||
QDTime.DateTime := SGetServerDate(ADOTemp);
|
||||
DeliveryDate.DateTime := SGetServerDate(ADOTemp);
|
||||
DeliveryDate.DateTime := QDTime.DateTime;
|
||||
QDTime.Checked := True;
|
||||
DeliveryDate.Checked := False;
|
||||
ConNo.Text := '×Ô¶¯Éú³É';
|
||||
|
@ -724,6 +724,9 @@ begin
|
|||
Self.Order_Sub.Edit;
|
||||
Self.Order_Sub.FieldByName('C_Code').Value := Trim(CDS_HZ.fieldbyname('ZdyCode').AsString);
|
||||
Self.Order_Sub.FieldByName('C_CodeName').Value := Trim(CDS_HZ.fieldbyname('ZDYName').AsString);
|
||||
Self.Order_Sub.FieldByName('C_Spec').Value := Trim(CDS_HZ.fieldbyname('DEFstr4').AsString);
|
||||
Self.Order_Sub.FieldByName('KZQty').Value := Trim(CDS_HZ.fieldbyname('DEFstr2').AsString);
|
||||
Self.Order_Sub.FieldByName('MFQty').Value := Trim(CDS_HZ.fieldbyname('DEFstr1').AsString);
|
||||
// Self.Order_Sub.FieldByName('Color').Value:=Trim(CDS_HZ.fieldbyname('DEFstr3').AsString);
|
||||
// Self.Order_Sub.FieldByName('SOrddefstr4').Value:=Trim(ClientDataSet1.fieldbyname('Note').AsString);
|
||||
Self.Order_Sub.Post;
|
||||
|
@ -903,12 +906,12 @@ begin
|
|||
|
||||
if trim(mvalue) = '' then
|
||||
exit;
|
||||
|
||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
begin
|
||||
mvalue := trim(mvalue) + '#';
|
||||
end;
|
||||
|
||||
//
|
||||
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
// begin
|
||||
// mvalue := trim(mvalue) + '#';
|
||||
// end;
|
||||
mvalue := trim(mvalue);
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
|
|
|
@ -418,32 +418,30 @@ object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
|||
end
|
||||
object GxNote1: TEdit
|
||||
Left = 86
|
||||
Top = 59
|
||||
Top = 67
|
||||
Width = 627
|
||||
Height = 18
|
||||
TabOrder = 11
|
||||
end
|
||||
object OrdPerson1: TBtnEditA
|
||||
Tag = 2
|
||||
Left = 572
|
||||
Top = 34
|
||||
Width = 137
|
||||
Height = 20
|
||||
Hint = 'OrdPerson1'
|
||||
TabOrder = 12
|
||||
OnBtnClick = OrdPerson1BtnClick
|
||||
end
|
||||
object CustomerNoName: TBtnEditC
|
||||
Tag = 2
|
||||
Left = 786
|
||||
Top = 9
|
||||
Width = 140
|
||||
Height = 20
|
||||
Hint = 'CustomerNo'
|
||||
Hint = 'CustomerNoname'
|
||||
TabOrder = 13
|
||||
OnBtnUpClick = CustomerNoNameBtnUpClick
|
||||
end
|
||||
object DYer: TBtnEditC
|
||||
Tag = 2
|
||||
Left = 786
|
||||
Top = 34
|
||||
Width = 140
|
||||
|
|
|
@ -540,6 +540,57 @@ begin
|
|||
Edit;
|
||||
end;
|
||||
end
|
||||
else if FConType = '新品开发' then
|
||||
begin
|
||||
if Trim(fMainID) = '' then
|
||||
begin
|
||||
Append;
|
||||
if GetLSNo(ADOTemp, maxno, 'XP', 'Contract_Main', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('生成流水号异常!', '提示', 0);
|
||||
exit;
|
||||
end;
|
||||
conNo.Text := trim(maxno);
|
||||
if GetLSNo(ADOTemp, maxno, 'CM', 'Contract_Main', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('生成流水号异常!', '提示', 0);
|
||||
exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxno := Trim(fMainID);
|
||||
Edit;
|
||||
end;
|
||||
|
||||
end
|
||||
else if FConType = '打样计划' then
|
||||
begin
|
||||
if Trim(fMainID) = '' then
|
||||
begin
|
||||
Append;
|
||||
if GetLSNo(ADOTemp, maxno, 'DY', 'Contract_Main', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('生成流水号异常!', '提示', 0);
|
||||
exit;
|
||||
end;
|
||||
conNo.Text := trim(maxno);
|
||||
if GetLSNo(ADOTemp, maxno, 'CM', 'Contract_Main', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('生成流水号异常!', '提示', 0);
|
||||
exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxno := Trim(fMainID);
|
||||
Edit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
if Trim(fMainID) = '' then
|
||||
|
@ -570,6 +621,11 @@ begin
|
|||
SSetsaveSql(ADOCmd, 'Contract_Main', ScrollBox1, 0);
|
||||
FieldByName('LXPerson').Value := Trim(LXPerson.Text);
|
||||
FieldByName('LXTel').Value := Trim(LXTel.Text);
|
||||
// FieldByName('FactoryNoName').Value := Trim(FactoryNoName.Text);
|
||||
FieldByName('CustomerNoName').Value := Trim(CustomerNoName.Text);
|
||||
FieldByName('DYer').Value := Trim(DYer.Text);
|
||||
FieldByName('OrdPerson1').Value := Trim(OrdPerson1.Text);
|
||||
|
||||
if Trim(fMainID) = '' then
|
||||
begin
|
||||
FieldByName('Filler').Value := Trim(DName);
|
||||
|
@ -670,7 +726,7 @@ begin
|
|||
end;
|
||||
if Trim(FactoryNoName.Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('供方不能为空!', '提示', 0);
|
||||
Application.MessageBox('加工厂不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
if Order_Sub.IsEmpty then
|
||||
|
@ -890,6 +946,9 @@ begin
|
|||
Self.Order_Sub.FieldByName('C_CodeName').Value := Trim(CDS_HZ.fieldbyname('ZDYName').AsString);
|
||||
Self.Order_Sub.FieldByName('C_Color').Value := Trim(CDS_HZ.fieldbyname('DEFstr3').AsString);
|
||||
Self.Order_Sub.FieldByName('C_ColorNo').Value := Trim(CDS_HZ.fieldbyname('DEFstr10').AsString);
|
||||
Self.Order_Sub.FieldByName('C_Spec').Value := Trim(CDS_HZ.fieldbyname('DEFstr4').AsString);
|
||||
Self.Order_Sub.FieldByName('KZQty').Value := Trim(CDS_HZ.fieldbyname('DEFstr2').AsString);
|
||||
Self.Order_Sub.FieldByName('MFQty').Value := Trim(CDS_HZ.fieldbyname('DEFstr1').AsString);
|
||||
Self.Order_Sub.Post;
|
||||
|
||||
end;
|
||||
|
@ -1059,11 +1118,11 @@ begin
|
|||
if trim(mvalue) = '' then
|
||||
exit;
|
||||
|
||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
begin
|
||||
mvalue := trim(mvalue) + '#';
|
||||
end;
|
||||
|
||||
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||
// begin
|
||||
// mvalue := trim(mvalue) + '#';
|
||||
// end;
|
||||
mvalue := trim(mvalue);
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
|
@ -1287,7 +1346,7 @@ begin
|
|||
if ShowModal = 1 then
|
||||
begin
|
||||
CustomerNoName.Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
CustomerNoName.TxtCode := Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString);
|
||||
// CustomerNoName.TxtCode := Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
object frmClothContractList: TfrmClothContractList
|
||||
Left = 173
|
||||
Top = 94
|
||||
Left = 309
|
||||
Top = 284
|
||||
Width = 1222
|
||||
Height = 738
|
||||
Caption = #22383#24067#21040#36135#20449#24687
|
||||
|
@ -340,11 +340,9 @@ object frmClothContractList: TfrmClothContractList
|
|||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column12
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column13
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
|
@ -356,23 +354,18 @@ object frmClothContractList: TfrmClothContractList
|
|||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1T_money
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column22
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column23
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
|
@ -527,26 +520,6 @@ object frmClothContractList: TfrmClothContractList
|
|||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36864#36135#21305#25968
|
||||
DataBinding.FieldName = 'T_Ps'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #36864#36135#25968#37327
|
||||
DataBinding.FieldName = 'T_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1T_money: TcxGridDBColumn
|
||||
Caption = #36864#36135#37329#39069
|
||||
DataBinding.FieldName = 'T_money'
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #21040#36135#22320#28857
|
||||
DataBinding.FieldName = 'JHPlace'
|
||||
|
@ -555,26 +528,6 @@ object frmClothContractList: TfrmClothContractList
|
|||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 101
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #22238#20179#21305#25968
|
||||
DataBinding.FieldName = 'H_PS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclPurple
|
||||
Styles.Footer = cxStyle_fontclPurple
|
||||
Styles.Header = cxStyle_fontclPurple
|
||||
Width = 60
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #22238#20179#25968#37327
|
||||
DataBinding.FieldName = 'H_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclPurple
|
||||
Styles.Footer = cxStyle_fontclPurple
|
||||
Styles.Header = cxStyle_fontclPurple
|
||||
Width = 60
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #24211#23384#21305#25968
|
||||
DataBinding.FieldName = 'N_Ps'
|
||||
|
@ -595,45 +548,6 @@ object frmClothContractList: TfrmClothContractList
|
|||
Styles.Header = cxStyle_fontclFuchsia
|
||||
Width = 60
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #35745#21010#32553#29575'(%)'
|
||||
DataBinding.FieldName = 'Mrate'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 80
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #23454#38469#32553#29575'(%)'
|
||||
DataBinding.FieldName = 'Srate'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = ',0.##%;-,0.##'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclGreen
|
||||
Styles.Footer = cxStyle_fontclGreen
|
||||
Styles.Header = cxStyle_fontclGreen
|
||||
Width = 80
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #26816#39564#21305#25968
|
||||
DataBinding.FieldName = 'J_PS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclTeal
|
||||
Styles.Footer = cxStyle_fontclTeal
|
||||
Styles.Header = cxStyle_fontclTeal
|
||||
Width = 60
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #26816#39564#25968#37327
|
||||
DataBinding.FieldName = 'J_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclTeal
|
||||
Styles.Footer = cxStyle_fontclTeal
|
||||
Styles.Header = cxStyle_fontclTeal
|
||||
Width = 60
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #21046#21333#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
|
|
|
@ -86,9 +86,6 @@ type
|
|||
Label6: TLabel;
|
||||
FactoryNoName: TEdit;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1T_money: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
cxStyleRepository1: TcxStyleRepository;
|
||||
cxStyle1: TcxStyle;
|
||||
cxStyle2: TcxStyle;
|
||||
|
@ -110,20 +107,14 @@ type
|
|||
cxTabControl1: TcxTabControl;
|
||||
tchk: TToolButton;
|
||||
Tnochk: TToolButton;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label7: TLabel;
|
||||
JHPlace: TEdit;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
Tv1Column2: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
|
@ -242,8 +233,8 @@ begin
|
|||
v1Price.Hidden := true;
|
||||
v1money.Visible := false;
|
||||
v1money.Hidden := true;
|
||||
v1T_money.Visible := false;
|
||||
v1T_money.Hidden := true;
|
||||
// v1T_money.Visible := false;
|
||||
// v1T_money.Hidden := true;
|
||||
ToolButton1.Visible := false;
|
||||
end;
|
||||
|
||||
|
@ -942,26 +933,26 @@ var
|
|||
FValue: string;
|
||||
FBounds: TRect;
|
||||
begin
|
||||
FBounds := AViewInfo.Bounds;
|
||||
if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||
begin
|
||||
ACanvas.FillRect(FBounds);
|
||||
ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||
FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1);
|
||||
InflateRect(FBounds, -1, -1);
|
||||
ACanvas.Font.Color := clBlack;
|
||||
ACanvas.Brush.Style := bsClear;
|
||||
ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
ADone := True;
|
||||
end;
|
||||
// FBounds := AViewInfo.Bounds;
|
||||
// if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||
// begin
|
||||
// ACanvas.FillRect(FBounds);
|
||||
// ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||
// FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1);
|
||||
// InflateRect(FBounds, -1, -1);
|
||||
// ACanvas.Font.Color := clBlack;
|
||||
// ACanvas.Brush.Style := bsClear;
|
||||
// ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
// ADone := True;
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList.Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
begin
|
||||
if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('H_PS').Index] >= AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('Qty1').Index] then
|
||||
begin
|
||||
ACanvas.Brush.Color := clSkyBlue;
|
||||
end;
|
||||
// if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('H_PS').Index] >= AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('Qty1').Index] then
|
||||
// begin
|
||||
// ACanvas.Brush.Color := clSkyBlue;
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList.cxTabControl1Change(Sender: TObject);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
object frmClothContractList_CG: TfrmClothContractList_CG
|
||||
Left = 94
|
||||
Top = 29
|
||||
Left = 269
|
||||
Top = 396
|
||||
Width = 1217
|
||||
Height = 738
|
||||
Caption = #22383#24067#37319#36141#35745#21010#20449#24687
|
||||
|
@ -463,7 +463,7 @@ object frmClothContractList_CG: TfrmClothContractList_CG
|
|||
Width = 63
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36865#36135#22320#22336
|
||||
Caption = #23384#25918#22320#28857
|
||||
DataBinding.FieldName = 'QDPalce'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
|
|
846
管理系统/U_ClothContractList_CK.dfm
Normal file
846
管理系统/U_ClothContractList_CK.dfm
Normal file
|
@ -0,0 +1,846 @@
|
|||
object frmClothContractList_CK: TfrmClothContractList_CK
|
||||
Left = 309
|
||||
Top = 284
|
||||
Width = 1222
|
||||
Height = 738
|
||||
Caption = #22383#24067#20986#24211#20449#24687
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1206
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 83
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_TradeManage.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 2
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 59
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TBAdd: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 3
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object TBEdit: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20462#25913
|
||||
ImageIndex = 54
|
||||
Visible = False
|
||||
OnClick = TBEditClick
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 17
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object tchk: TToolButton
|
||||
Left = 315
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #30830#35748#23436#25104
|
||||
ImageIndex = 41
|
||||
OnClick = tchkClick
|
||||
end
|
||||
object Tnochk: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25764#38144#23436#25104
|
||||
Enabled = False
|
||||
ImageIndex = 56
|
||||
OnClick = TnochkClick
|
||||
end
|
||||
object Tth: TToolButton
|
||||
Left = 489
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36864#36135
|
||||
ImageIndex = 129
|
||||
OnClick = TthClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 58
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 615
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 75
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBPrint: TToolButton
|
||||
Left = 678
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25171#21360
|
||||
ImageIndex = 12
|
||||
OnClick = TBPrintClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 741
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1206
|
||||
Height = 53
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 23
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #30331#35760#26085#26399
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 161
|
||||
Top = 22
|
||||
Width = 6
|
||||
Height = 12
|
||||
Caption = '-'
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 271
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #20219#21153#21333#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 420
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #20135#21697#21517#31216
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 572
|
||||
Top = 22
|
||||
Width = 26
|
||||
Height = 12
|
||||
Caption = #35268#26684
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 704
|
||||
Top = 22
|
||||
Width = 26
|
||||
Height = 12
|
||||
Caption = #20379#26041
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 836
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #21040#36135#22320#28857
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 76
|
||||
Top = 18
|
||||
Width = 85
|
||||
Height = 20
|
||||
Date = 40675.464742650460000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40675.464742650460000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 167
|
||||
Top = 18
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40675.464761099540000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40675.464761099540000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object ConNo: TEdit
|
||||
Tag = 2
|
||||
Left = 329
|
||||
Top = 18
|
||||
Width = 81
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = ConNoChange
|
||||
OnKeyPress = conPress
|
||||
end
|
||||
object C_CodeName: TEdit
|
||||
Tag = 2
|
||||
Left = 473
|
||||
Top = 18
|
||||
Width = 83
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = ConNoChange
|
||||
end
|
||||
object C_Spec: TEdit
|
||||
Tag = 2
|
||||
Left = 600
|
||||
Top = 18
|
||||
Width = 83
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnChange = ConNoChange
|
||||
end
|
||||
object FactoryNoName: TEdit
|
||||
Tag = 2
|
||||
Left = 732
|
||||
Top = 18
|
||||
Width = 80
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = ConNoChange
|
||||
end
|
||||
object JHPlace: TEdit
|
||||
Tag = 2
|
||||
Left = 892
|
||||
Top = 18
|
||||
Width = 80
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnChange = ConNoChange
|
||||
end
|
||||
end
|
||||
object ScrollBox1: TScrollBox
|
||||
Left = 0
|
||||
Top = 107
|
||||
Width = 1206
|
||||
Height = 497
|
||||
Align = alTop
|
||||
BorderStyle = bsNone
|
||||
TabOrder = 2
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1206
|
||||
Height = 497
|
||||
Align = alClient
|
||||
TabOrder = 0
|
||||
object Tv1: TcxGridDBTableView
|
||||
OnMouseDown = Tv1MouseDown
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCellDblClick = Tv1CellDblClick
|
||||
OnCustomDrawCell = Tv1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1PRTOrderQty
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Price
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Money
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Qty1
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column16
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column17
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.Indicator = True
|
||||
OptionsView.IndicatorWidth = 20
|
||||
Styles.Inactive = DataLink_TradeManage.SHuangSe
|
||||
Styles.IncSearch = DataLink_TradeManage.SHuangSe
|
||||
Styles.Selection = DataLink_TradeManage.SHuangSe
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
OnCustomDrawIndicatorCell = Tv1CustomDrawIndicatorCell
|
||||
object v1OrderNo: TcxGridDBColumn
|
||||
Caption = #20219#21153#21333#21495
|
||||
DataBinding.FieldName = 'ConNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 65
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #37319#36141#35745#21010#21333#21495
|
||||
DataBinding.FieldName = 'fromConNo'
|
||||
Options.Editing = False
|
||||
Width = 86
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20135#21697#21517#31216
|
||||
DataBinding.FieldName = 'C_CodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 58
|
||||
end
|
||||
object v1DeliveryDate: TcxGridDBColumn
|
||||
Caption = #21040#36135#26085#26399
|
||||
DataBinding.FieldName = 'DeliveryDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #31614#35746#26085#26399
|
||||
DataBinding.FieldName = 'QDTime'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 70
|
||||
end
|
||||
object v1FactoryNo1Name: TcxGridDBColumn
|
||||
Caption = #20379#26041
|
||||
DataBinding.FieldName = 'FactoryNoName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 60
|
||||
end
|
||||
object v1PRTSpec: TcxGridDBColumn
|
||||
Caption = #35268#26684
|
||||
DataBinding.FieldName = 'C_Spec'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 66
|
||||
end
|
||||
object v1PRTMF: TcxGridDBColumn
|
||||
Caption = #38376#24133'(cm)'
|
||||
DataBinding.FieldName = 'MFQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 61
|
||||
end
|
||||
object v1PRTKZ: TcxGridDBColumn
|
||||
Caption = #20811#37325'(g/'#13217')'
|
||||
DataBinding.FieldName = 'KZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 83
|
||||
end
|
||||
object v1Qty1: TcxGridDBColumn
|
||||
Caption = #21305#25968
|
||||
DataBinding.FieldName = 'Qty1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclBlue
|
||||
Styles.Footer = cxStyle_fontclBlue
|
||||
Styles.Header = cxStyle_fontclBlue
|
||||
Width = 46
|
||||
end
|
||||
object v1PRTOrderQty: TcxGridDBColumn
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclBlue
|
||||
Styles.Footer = cxStyle_fontclBlue
|
||||
Styles.Header = cxStyle_fontclBlue
|
||||
Width = 58
|
||||
end
|
||||
object v1OrderUnit: TcxGridDBColumn
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C_Unit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 47
|
||||
end
|
||||
object v1Price: TcxGridDBColumn
|
||||
Caption = #21333#20215
|
||||
DataBinding.FieldName = 'Price'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 57
|
||||
end
|
||||
object v1Money: TcxGridDBColumn
|
||||
Caption = #24635#20215
|
||||
DataBinding.FieldName = 'Money'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 58
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'C_Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 68
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #32852#31995#20154
|
||||
DataBinding.FieldName = 'LXPerson'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #32852#31995#26041#24335
|
||||
DataBinding.FieldName = 'LXTel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #21040#36135#22320#28857
|
||||
DataBinding.FieldName = 'JHPlace'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 101
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #24211#23384#21305#25968
|
||||
DataBinding.FieldName = 'N_Ps'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclFuchsia
|
||||
Styles.Footer = cxStyle_fontclFuchsia
|
||||
Styles.Header = cxStyle_fontclFuchsia
|
||||
Width = 60
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #24211#23384#25968#37327
|
||||
DataBinding.FieldName = 'N_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclFuchsia
|
||||
Styles.Footer = cxStyle_fontclFuchsia
|
||||
Styles.Header = cxStyle_fontclFuchsia
|
||||
Width = 60
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #21046#21333#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #21046#21333#26102#38388
|
||||
DataBinding.FieldName = 'FillTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20462#25913#20154
|
||||
DataBinding.FieldName = 'editer'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 80
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #20462#25913#26102#38388
|
||||
DataBinding.FieldName = 'editTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 80
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #25104#21697#21697#21517
|
||||
DataBinding.FieldName = 'CP_CodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object Tv1Column2: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 85
|
||||
Width = 1206
|
||||
Height = 22
|
||||
Align = alTop
|
||||
TabOrder = 3
|
||||
Properties.CustomButtons.Buttons = <>
|
||||
Properties.Style = 9
|
||||
Properties.TabIndex = 0
|
||||
Properties.Tabs.Strings = (
|
||||
#26410#23436#25104
|
||||
#24050#23436#25104
|
||||
#20840#37096)
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 22
|
||||
ClientRectRight = 1206
|
||||
ClientRectTop = 19
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 1128
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 936
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1000
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1040
|
||||
Top = 8
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Main
|
||||
Left = 1168
|
||||
Top = 8
|
||||
end
|
||||
object Order_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 1096
|
||||
Top = 8
|
||||
end
|
||||
object ClientDataSet3: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 1112
|
||||
Top = 240
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 880
|
||||
Top = 176
|
||||
end
|
||||
object DataSource3: TDataSource
|
||||
DataSet = ClientDataSet3
|
||||
Left = 1112
|
||||
Top = 216
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 920
|
||||
Top = 224
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbExport, pbNavigator]
|
||||
DefaultCollate = False
|
||||
SaveReportOptions.RegistryPath = 'Software\ReportMachine\ReportSettings\'
|
||||
PreviewOptions.RulerUnit = rmutScreenPixels
|
||||
PreviewOptions.RulerVisible = False
|
||||
PreviewOptions.DrawBorder = False
|
||||
PreviewOptions.BorderPen.Color = clGray
|
||||
PreviewOptions.BorderPen.Style = psDash
|
||||
Dataset = RMDBMain
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 352
|
||||
Top = 192
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBMain: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_PRT
|
||||
Left = 400
|
||||
Top = 192
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 1
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 416
|
||||
Top = 248
|
||||
end
|
||||
object CDS_PRT: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 680
|
||||
Top = 32
|
||||
end
|
||||
object cxStyleRepository1: TcxStyleRepository
|
||||
Left = 305
|
||||
Top = 310
|
||||
PixelsPerInch = 96
|
||||
object cxStyle1: TcxStyle
|
||||
AssignedValues = [svColor]
|
||||
Color = clInactiveCaption
|
||||
end
|
||||
object cxStyle2: TcxStyle
|
||||
AssignedValues = [svColor, svTextColor]
|
||||
Color = 4707838
|
||||
TextColor = clBtnText
|
||||
end
|
||||
object cxStyle_gridRow: TcxStyle
|
||||
AssignedValues = [svColor, svFont]
|
||||
Color = 16311512
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
end
|
||||
object cxStyle_gridFoot: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
object cxStyle_gridHead: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
object cxStyle_gridGroupBox: TcxStyle
|
||||
AssignedValues = [svColor, svFont]
|
||||
Color = clMoneyGreen
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
object cxStyle_yellow: TcxStyle
|
||||
AssignedValues = [svColor, svFont]
|
||||
Color = 8454143
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
end
|
||||
object cxStyle_Red: TcxStyle
|
||||
AssignedValues = [svColor, svFont]
|
||||
Color = clRed
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -11
|
||||
Font.Name = 'MS Sans Serif'
|
||||
Font.Style = []
|
||||
end
|
||||
object cxStyle_fontBlack: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
object cxStyle_fontclFuchsia: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clFuchsia
|
||||
end
|
||||
object cxStyle_fontclPurple: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clPurple
|
||||
end
|
||||
object cxStyle_fontclGreen: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clGreen
|
||||
end
|
||||
object cxStyle_fontclBlue: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clBlue
|
||||
end
|
||||
object cxStyle_fontclTeal: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -11
|
||||
Font.Name = 'MS Sans Serif'
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clTeal
|
||||
end
|
||||
object cxStyle_fontclOlive: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -11
|
||||
Font.Name = 'MS Sans Serif'
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clOlive
|
||||
end
|
||||
end
|
||||
end
|
964
管理系统/U_ClothContractList_CK.pas
Normal file
964
管理系统/U_ClothContractList_CK.pas
Normal file
|
@ -0,0 +1,964 @@
|
|||
unit U_ClothContractList_CK;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses, cxControls,
|
||||
cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class,
|
||||
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxPC, cxCheckBox,
|
||||
cxCurrencyEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||
dxBarBuiltInMenu, 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
|
||||
TfrmClothContractList_CK = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBAdd: TToolButton;
|
||||
TBEdit: TToolButton;
|
||||
TBDel: TToolButton;
|
||||
TBPrint: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
Label3: TLabel;
|
||||
ConNo: TEdit;
|
||||
Label5: TLabel;
|
||||
C_CodeName: TEdit;
|
||||
TBExport: TToolButton;
|
||||
Order_Main: TClientDataSet;
|
||||
Label4: TLabel;
|
||||
C_Spec: TEdit;
|
||||
ScrollBox1: TScrollBox;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1OrderNo: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1DeliveryDate: TcxGridDBColumn;
|
||||
v1FactoryNo1Name: TcxGridDBColumn;
|
||||
v1PRTSpec: TcxGridDBColumn;
|
||||
v1PRTMF: TcxGridDBColumn;
|
||||
v1PRTKZ: TcxGridDBColumn;
|
||||
v1PRTOrderQty: TcxGridDBColumn;
|
||||
v1OrderUnit: TcxGridDBColumn;
|
||||
v1Price: TcxGridDBColumn;
|
||||
v1Money: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
ClientDataSet3: TClientDataSet;
|
||||
DataSource2: TDataSource;
|
||||
DataSource3: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Qty1: TcxGridDBColumn;
|
||||
RM1: TRMGridReport;
|
||||
RMDBMain: TRMDBDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
CDS_PRT: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
FactoryNoName: TEdit;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
cxStyleRepository1: TcxStyleRepository;
|
||||
cxStyle1: TcxStyle;
|
||||
cxStyle2: TcxStyle;
|
||||
cxStyle_gridRow: TcxStyle;
|
||||
cxStyle_gridFoot: TcxStyle;
|
||||
cxStyle_gridHead: TcxStyle;
|
||||
cxStyle_gridGroupBox: TcxStyle;
|
||||
cxStyle_yellow: TcxStyle;
|
||||
cxStyle_Red: TcxStyle;
|
||||
cxStyle_fontBlack: TcxStyle;
|
||||
cxStyle_fontclFuchsia: TcxStyle;
|
||||
cxStyle_fontclPurple: TcxStyle;
|
||||
cxStyle_fontclGreen: TcxStyle;
|
||||
cxStyle_fontclBlue: TcxStyle;
|
||||
cxStyle_fontclTeal: TcxStyle;
|
||||
cxStyle_fontclOlive: TcxStyle;
|
||||
ToolButton1: TToolButton;
|
||||
Tth: TToolButton;
|
||||
cxTabControl1: TcxTabControl;
|
||||
tchk: TToolButton;
|
||||
Tnochk: TToolButton;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
Label7: TLabel;
|
||||
JHPlace: TEdit;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
Tv1Column2: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure TBEditClick(Sender: TObject);
|
||||
procedure TBDelClick(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBPrintClick(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure TBAddClick(Sender: TObject);
|
||||
procedure ConNoChange(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure Tv2MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
procedure Tv1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
procedure ToolButton5Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure conPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure TthClick(Sender: TObject);
|
||||
procedure tchkClick(Sender: TObject);
|
||||
procedure TnochkClick(Sender: TObject);
|
||||
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
procedure Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
private
|
||||
FInt, PFInt: Integer;
|
||||
procedure InitGrid();
|
||||
procedure InitForm();
|
||||
function DelData(): Boolean;
|
||||
{ Private declarations }
|
||||
public
|
||||
fDParameters1: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmClothContractList_CK: TfrmClothContractList_CK;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_ClothContractOutPut, U_Fun, U_ProductOrderList, U_ZDYHelp;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmClothContractList_CK.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmClothContractList_CK := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.FormCreate(Sender: TObject);
|
||||
begin
|
||||
ScrollBox1.Align := alClient;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
WriteCxGrid(self.Caption, Tv1, '指示单管理');
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec P_Get_Contract');
|
||||
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||
sql.Add(',@conType=''坯布到货'' ');
|
||||
sql.Add(',@status=''' + inttostr(cxTabControl1.TabIndex) + ''' ');
|
||||
// ShowMessage(SQL.text);
|
||||
{ sql.Add('select *,fromConNo=(select Top 1 conNo from Contract_Main X where X.MainID=A.fromMainID) ');
|
||||
sql.Add('from Contract_Main A');
|
||||
sql.Add('inner join Contract_sub B on B.MainID=A.mainID ');
|
||||
sql.Add('where A.FillTime>= '''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.DateTime))+''' ');
|
||||
sql.Add('and A.FillTime< '''+Trim(FormatDateTime('yyyy-MM-dd',endDate.DateTime+1))+''' ');
|
||||
sql.Add('and A.conType=''坯布到货'' ');
|
||||
IF cxTabControl1.TabIndex<2 then
|
||||
sql.Add('and isnull(B.C_status,''0'')='''+inttostr(cxTabControl1.TabIndex)+''' '); }
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
TBFind.Click;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.InitForm();
|
||||
begin
|
||||
if fDParameters1 = '查询' then
|
||||
begin
|
||||
TBADD.Visible := false;
|
||||
// TBEdit.Visible:=false;
|
||||
TBDel.Visible := false;
|
||||
// Tchk.Visible:=false;
|
||||
// TNochk.Visible:=false;
|
||||
Tth.Visible := false;
|
||||
v1Price.Visible := false;
|
||||
v1Price.Hidden := true;
|
||||
v1money.Visible := false;
|
||||
v1money.Hidden := true;
|
||||
// v1T_money.Visible := false;
|
||||
// v1T_money.Hidden := true;
|
||||
ToolButton1.Visible := false;
|
||||
end;
|
||||
|
||||
TBEdit.Enabled := false;
|
||||
TBDel.Enabled := false;
|
||||
Tchk.Enabled := false;
|
||||
TNochk.Enabled := false;
|
||||
Tth.Enabled := false;
|
||||
if cxTabControl1.TabIndex = 0 then
|
||||
begin
|
||||
// TBEdit.Enabled := true;
|
||||
TBDel.Enabled := true;
|
||||
Tchk.Enabled := true;
|
||||
Tth.Enabled := true;
|
||||
end;
|
||||
if cxTabControl1.TabIndex = 1 then
|
||||
begin
|
||||
TNochk.Enabled := true;
|
||||
end;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active = False then
|
||||
Exit;
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBEditClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select YFID from YF_money_CR ');
|
||||
sql.Add('where mainID=''' + trim(Order_Main.FieldByName('mainID').AsString) + ''' ');
|
||||
sql.Add('and status>0 ');
|
||||
open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
application.MessageBox('财务数据已审核,不能修改!', '提示信息', MB_ICONERROR);
|
||||
exit;
|
||||
end;
|
||||
end;
|
||||
// with ADOQueryTemp do
|
||||
// begin
|
||||
// close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select * from contract_sub ');
|
||||
// sql.Add('where kcsubid=''' + trim(Order_Main.FieldByName('subid').AsString) + ''' ');
|
||||
//// sql.Add(' ');
|
||||
// open;
|
||||
// if not IsEmpty then
|
||||
// begin
|
||||
// application.MessageBox('已出库不能修改!', '提示信息', MB_ICONERROR);
|
||||
// exit;
|
||||
// end;
|
||||
// end;
|
||||
try
|
||||
frmClothContractOutPut := TfrmClothContractOutPut.Create(Application);
|
||||
with frmClothContractOutPut do
|
||||
begin
|
||||
if trim(fDParameters1) = '查询' then
|
||||
begin
|
||||
frmClothContractOutPut.Caption := '到货信息查询';
|
||||
v1Money.Visible := false;
|
||||
v1Price.Visible := false;
|
||||
v1Money.Hidden := true;
|
||||
v1Price.Hidden := true;
|
||||
v1T_money.Visible := false;
|
||||
v1T_money.Hidden := true;
|
||||
v1T_price.Visible := false;
|
||||
v1T_price.Hidden := true;
|
||||
ScrollBox1.Enabled := false;
|
||||
for i := 0 to tv1.ColumnCount - 1 do
|
||||
begin
|
||||
tv1.Columns[i].Options.Editing := false;
|
||||
end;
|
||||
// v1Mrate.Options.Editing := true;
|
||||
ToolBar2.Enabled := false;
|
||||
end;
|
||||
PState := 1;
|
||||
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
// TBRafresh.Click;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmClothContractOutPut.Free;
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBDelClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select YFID from YF_money_CR ');
|
||||
sql.Add('where mainID=''' + trim(Order_Main.FieldByName('mainID').AsString) + ''' ');
|
||||
sql.Add('and status>0 ');
|
||||
open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
application.MessageBox('财务数据已审核,不能删除!', '提示信息', MB_ICONERROR);
|
||||
exit;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from contract_sub ');
|
||||
sql.Add('where kcsubid=''' + trim(Order_Main.FieldByName('subid').AsString) + ''' ');
|
||||
open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
application.MessageBox('已出库不能修改!', '提示信息', MB_ICONERROR);
|
||||
exit;
|
||||
end;
|
||||
end;
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
if trim(Order_Main.FieldByName('mainID').AsString) = 'CM001' then
|
||||
exit;
|
||||
if DelData() then
|
||||
begin
|
||||
Order_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TfrmClothContractList_CK.DelData(): Boolean;
|
||||
begin
|
||||
try
|
||||
Result := false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete YF_Money_CR where MainID=''' + Trim(Order_Main.fieldbyname('MainID').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update YF_Money_KC Set KCMoney=(select isnull(Sum(Money*QtyFlag),0) from YF_Money_CR A where A.CRID=YF_Money_KC.CRID)');
|
||||
sql.Add(',KCBBMoney=(select isnull(Sum(BBMoney*QtyFlag),0) from YF_Money_CR A where A.CRID=YF_Money_KC.CRID)');
|
||||
// sql.Add(' where CRID='+CRID);
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete Contract_Sub where SubId=''' + Trim(Order_Main.fieldbyname('SubId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from Contract_Sub where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete Contract_Main where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
if Trim(Order_Main.fieldbyname('SubId').AsString) = '' then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete Contract_Main where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result := True;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result := False;
|
||||
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
Exit;
|
||||
TcxGridToExcel('坯布合同订单列表', cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBPrintClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile, FConNoM: string;
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\坯布到货单.rmf';
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select *,fromConNo=(select Top 1 conNo from Contract_Main X where X.MainID=A.fromMainID) ');
|
||||
sql.Add('from Contract_Main A');
|
||||
sql.Add('inner join Contract_sub B on B.MainID=A.mainID ');
|
||||
sql.Add('where A.FillTime>= ''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||
sql.Add('and A.FillTime< ''' + Trim(FormatDateTime('yyyy-MM-dd', endDate.DateTime + 1)) + ''' ');
|
||||
sql.Add('and A.mainID=' + quotedstr(trim(Order_Main.fieldbyname('MainID').AsString)));
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp, CDS_PRT);
|
||||
SInitCDSData20(ADOQueryTemp, CDS_PRT);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
RMVariables['dtxz'] := formatdateTime('yyyy-MM-dd', Now);
|
||||
RMVariables['zdr'] := Trim(dName);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\坯布到货单.rmf'), '提示', 0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TBAddClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
try
|
||||
frmClothContractOutPut := TfrmClothContractOutPut.Create(Application);
|
||||
with frmClothContractOutPut do
|
||||
begin
|
||||
if trim(fDParameters1) = '查询' then
|
||||
begin
|
||||
// frmClothContractOutPut.Caption := '到货信息查询';
|
||||
v1Money.Visible := false;
|
||||
v1Price.Visible := false;
|
||||
v1Money.Hidden := true;
|
||||
v1Price.Hidden := true;
|
||||
v1T_money.Visible := false;
|
||||
v1T_money.Hidden := true;
|
||||
ScrollBox1.Enabled := false;
|
||||
for i := 0 to tv1.ColumnCount - 2 do
|
||||
begin
|
||||
tv1.Columns[i].Options.Editing := false;
|
||||
end;
|
||||
// v1Mrate.Options.Editing := true;
|
||||
ToolBar2.Enabled := false;
|
||||
end;
|
||||
PState := 0;
|
||||
FMainId := '';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmClothContractOutPut.Free;
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.ConNoChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active = False then
|
||||
Exit;
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid(self.Caption, Tv1, '指示单管理');
|
||||
BegDate.DateTime := SGetServerDate10(ADOQueryTemp) - 7;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
initForm();
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.Tv2MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
begin
|
||||
FInt := 2;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.Tv1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
begin
|
||||
FInt := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.ToolButton5Click(Sender: TObject);
|
||||
var
|
||||
maxno: string;
|
||||
begin
|
||||
if ClientDataSet3.IsEmpty then
|
||||
Exit;
|
||||
if ClientDataSet2.IsEmpty then
|
||||
Exit;
|
||||
if Trim(ClientDataSet2.fieldbyname('MXId').AsString) = '' then
|
||||
begin
|
||||
Application.MessageBox('到货数量未确定!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
if ClientDataSet3.Locate('OrderNo', null, []) then
|
||||
begin
|
||||
Application.MessageBox('指定订单编号不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
BegDate.SetFocus;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
//保存去向表
|
||||
with ClientDataSet3 do
|
||||
begin
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd, maxno, 'To', 'Contract_Sub_MxTo', 4, 1) = False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取去向流水号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxno := Trim(ClientDataSet3.fieldbyname('ToId').AsString);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from Contract_Sub_MxTo where ToId=''' + Trim(ClientDataSet3.fieldbyname('ToId').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) = '' then
|
||||
Append
|
||||
else
|
||||
Edit;
|
||||
FieldByName('MxId').Value := Trim(ClientDataSet2.fieldbyname('MxId').AsString);
|
||||
FieldByName('ToId').Value := Trim(maxno);
|
||||
FieldByName('OrdSubId').Value := Trim(ClientDataSet3.fieldbyname('OrdSubId').AsString);
|
||||
FieldByName('TPDate').Value := ClientDataSet3.fieldbyname('TPDate').Value;
|
||||
FieldByName('TPPerson').Value := ClientDataSet3.fieldbyname('TPPerson').Value;
|
||||
FieldByName('TPNote').Value := ClientDataSet3.fieldbyname('TPNote').Value;
|
||||
if Trim(ClientDataSet3.fieldbyname('TPQty').AsString) <> '' then
|
||||
FieldByName('TPQty').Value := ClientDataSet3.fieldbyname('TPQty').Value
|
||||
else
|
||||
FieldByName('TPQty').Value := 0;
|
||||
if Trim(ClientDataSet3.fieldbyname('Qty1').AsString) <> '' then
|
||||
FieldByName('Qty1').Value := ClientDataSet3.fieldbyname('Qty1').Value
|
||||
else
|
||||
FieldByName('Qty1').Value := 0;
|
||||
if Trim(ClientDataSet3.fieldbyname('Qty2').AsString) <> '' then
|
||||
FieldByName('Qty2').Value := ClientDataSet3.fieldbyname('Qty2').Value
|
||||
else
|
||||
FieldByName('Qty2').Value := 0;
|
||||
if Trim(ClientDataSet3.fieldbyname('Qty3').AsString) <> '' then
|
||||
FieldByName('Qty3').Value := ClientDataSet3.fieldbyname('Qty3').Value
|
||||
else
|
||||
FieldByName('Qty3').Value := 0;
|
||||
Post;
|
||||
end;
|
||||
with ClientDataSet3 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ToId').Value := Trim(maxno);
|
||||
Post;
|
||||
end;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Application.MessageBox('操作成功!', '提示', 0);
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('操作异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
if FInt = 2 then
|
||||
begin
|
||||
if ClientDataSet2.IsEmpty then
|
||||
Exit;
|
||||
if ClientDataSet3.IsEmpty = false then
|
||||
begin
|
||||
Application.MessageBox('已产生坯布领料数据,不能删除到坯记录!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(ClientDataSet2.fieldbyname('MxId').AsString) <> '' then
|
||||
begin
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete Contract_Sub_Mx where MxId=''' + Trim(ClientDataSet2.fieldbyname('MxId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
ClientDataSet2.Delete;
|
||||
end
|
||||
else if FInt = 3 then
|
||||
begin
|
||||
if ClientDataSet3.IsEmpty then
|
||||
Exit;
|
||||
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) <> '' then
|
||||
begin
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete Contract_Sub_MxTo where ToId=''' + Trim(ClientDataSet3.fieldbyname('ToId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
ClientDataSet3.Delete;
|
||||
with ClientDataSet2 do
|
||||
begin
|
||||
Edit;
|
||||
if ClientDataSet3.IsEmpty = False then
|
||||
// FieldByName('KCSL').Value:=ClientDataSet2.fieldbyname('MxQty').Value-tv3.DataController.Summary.FooterSummaryValues[0]
|
||||
|
||||
else
|
||||
FieldByName('KCSL').Value := ClientDataSet2.fieldbyname('MxQty').Value;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'RKPlace';
|
||||
flagname := '入库地点';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with ClientDataSet2 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('RKPlace').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.conPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
{ if Key=#13 then
|
||||
begin
|
||||
if Length(Trim(ConNoM.Text))<4 then Exit;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec ClothContract_QryList :MainId,:WSql');
|
||||
Parameters.ParamByName('WSql').Value:=' and OM.conNo like '''+'%'+Trim(ConNoM.Text)+'%'+'''';
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,Order_Main);
|
||||
SInitCDSData20(ADOQueryMain,Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end; }
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
try
|
||||
frmClothContractOutPut := TfrmClothContractOutPut.Create(Application);
|
||||
with frmClothContractOutPut do
|
||||
begin
|
||||
PState := 3;
|
||||
TBSave.Enabled := false;
|
||||
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmClothContractOutPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
ToolButton1.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TthClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
try
|
||||
frmClothContractOutPut := TfrmClothContractOutPut.Create(Application);
|
||||
with frmClothContractOutPut do
|
||||
begin
|
||||
Caption := '坯布退货';
|
||||
PState := 1;
|
||||
v1T_money.Visible := true;
|
||||
v1T_ps.Visible := true;
|
||||
v1T_Qty.Visible := true;
|
||||
v1T_Price.Visible := true;
|
||||
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmClothContractOutPut.Free;
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.tchkClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
exit;
|
||||
|
||||
{ try
|
||||
frmClothContractInPut := TfrmClothContractInPut.Create(Application);
|
||||
with frmClothContractInPut do
|
||||
begin
|
||||
PState := 1;
|
||||
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with self.ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('update Contract_sub SET C_status=''1'' ');
|
||||
sql.Add('where mainID =' + quotedstr(trim(self.Order_Main.fieldbyname('mainID').AsString)));
|
||||
sql.Add('and subID =' + quotedstr(trim(self.Order_Main.fieldbyname('subID').AsString)));
|
||||
execsql;
|
||||
end;
|
||||
self.InitGrid();
|
||||
end
|
||||
else
|
||||
begin
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmClothContractInPut.Free;
|
||||
// TBRafresh.Click;
|
||||
end; }
|
||||
|
||||
if Order_Main.Locate('ssel', true, []) = false then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
|
||||
with Order_Main do
|
||||
begin
|
||||
DisableControls;
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
if Fieldbyname('ssel').AsBoolean then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('update Contract_sub SET C_status=''1'' ');
|
||||
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||
execsql;
|
||||
end;
|
||||
end;
|
||||
next;
|
||||
end;
|
||||
First;
|
||||
EnableControls;
|
||||
end;
|
||||
|
||||
InitGrid();
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
application.MessageBox('操作失败!', '提示信息', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.TnochkClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then
|
||||
exit;
|
||||
if Order_Main.Locate('ssel', true, []) = false then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
{with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('update Contract_sub SET C_status=''0'' ');
|
||||
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||
execsql;
|
||||
end; }
|
||||
with Order_Main do
|
||||
begin
|
||||
DisableControls;
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
if Fieldbyname('ssel').AsBoolean then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('update Contract_sub SET C_status=''0'' ');
|
||||
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||
execsql;
|
||||
end;
|
||||
end;
|
||||
next;
|
||||
end;
|
||||
First;
|
||||
EnableControls;
|
||||
end;
|
||||
|
||||
InitGrid();
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
application.MessageBox('操作失败!', '提示信息', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
var
|
||||
FValue: string;
|
||||
FBounds: TRect;
|
||||
begin
|
||||
// FBounds := AViewInfo.Bounds;
|
||||
// if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||
// begin
|
||||
// ACanvas.FillRect(FBounds);
|
||||
// ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||
// FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1);
|
||||
// InflateRect(FBounds, -1, -1);
|
||||
// ACanvas.Font.Color := clBlack;
|
||||
// ACanvas.Brush.Style := bsClear;
|
||||
// ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
// ADone := True;
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
begin
|
||||
// if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('H_PS').Index] >= AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('Qty1').Index] then
|
||||
// begin
|
||||
// ACanvas.Brush.Color := clSkyBlue;
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_CK.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
initForm();
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -565,6 +565,18 @@ object frmClothContractList_DY: TfrmClothContractList_DY
|
|||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv1Column2: TcxGridDBColumn
|
||||
Caption = #25171#26679#20154
|
||||
DataBinding.FieldName = 'DYer'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv1Column3: TcxGridDBColumn
|
||||
Caption = #23458#25143
|
||||
DataBinding.FieldName = 'CustomerNoname'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
|
|
|
@ -115,6 +115,8 @@ type
|
|||
TJj: TToolButton;
|
||||
TnoJj: TToolButton;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
Tv1Column2: TcxGridDBColumn;
|
||||
Tv1Column3: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
|
@ -202,11 +204,11 @@ begin
|
|||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec P_Get_Contract_TG');
|
||||
sql.Add('exec P_Get_Contract');
|
||||
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||
// sql.Add(',@conType= '''+TconType+''' ');
|
||||
sql.Add(',@status=''' + strwhere + ''' ');
|
||||
sql.Add(',@conType=''´òÑù¼Æ»®'' ');
|
||||
sql.Add(',@status=''' + inttostr(cxTabControl1.TabIndex) + ''' ');
|
||||
// ShowMessage(sql.text);
|
||||
Open;
|
||||
end;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
object frmClothContractList_JG: TfrmClothContractList_JG
|
||||
Left = 129
|
||||
Top = 62
|
||||
Left = 353
|
||||
Top = 299
|
||||
Width = 1221
|
||||
Height = 738
|
||||
Caption = #25104#21697#21518#21152#24037
|
||||
|
|
|
@ -217,6 +217,8 @@ begin
|
|||
begin
|
||||
PState := 1;
|
||||
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||
FConType := Trim(Self.Order_Main.fieldbyname('ConType').AsString);
|
||||
caption := 'ºó¼Ó¹¤';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TBRafresh.Click;
|
||||
|
@ -349,6 +351,7 @@ begin
|
|||
PState := 0;
|
||||
FMainId := '';
|
||||
FConType := '成品后加工';
|
||||
caption := 'ºó¼Ó¹¤';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TBRafresh.Click;
|
||||
|
|
|
@ -565,6 +565,12 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
|||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object Tv1Column2: TcxGridDBColumn
|
||||
Caption = #33394#21495
|
||||
DataBinding.FieldName = 'C_ColorNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
|
|
|
@ -115,6 +115,7 @@ type
|
|||
TJj: TToolButton;
|
||||
TnoJj: TToolButton;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
Tv1Column2: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
|
|
|
@ -202,11 +202,12 @@ begin
|
|||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec P_Get_Contract_TG');
|
||||
sql.Add('exec P_Get_Contract');
|
||||
sql.Add('@begdate='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.DateTime))+''' ');
|
||||
sql.Add(',@enddate='''+Trim(FormatDateTime('yyyy-MM-dd',enddate.DateTime+1))+''' ');
|
||||
// sql.Add(',@conType= '''+TconType+''' ');
|
||||
sql.Add(',@status=''' + strwhere + ''' ');
|
||||
sql.Add(',@conType=''新品开发'' ');
|
||||
sql.Add(',@status='''+inttostr(cxTabControl1.TabIndex)+''' ');
|
||||
|
||||
// ShowMessage(sql.text);
|
||||
Open;
|
||||
end;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
object frmClothContractList_Help: TfrmClothContractList_Help
|
||||
Left = 35
|
||||
Top = 105
|
||||
Left = 408
|
||||
Top = 340
|
||||
Width = 1221
|
||||
Height = 738
|
||||
Caption = #36873#25321#22383#24067#21040#36135#20449#24687
|
||||
|
@ -100,7 +100,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 23
|
||||
Left = 37
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
|
@ -113,14 +113,14 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 161
|
||||
Left = 175
|
||||
Top = 22
|
||||
Width = 6
|
||||
Height = 12
|
||||
Caption = '-'
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 271
|
||||
Left = 285
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
|
@ -133,7 +133,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 420
|
||||
Left = 434
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
|
@ -146,7 +146,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 572
|
||||
Left = 586
|
||||
Top = 22
|
||||
Width = 26
|
||||
Height = 12
|
||||
|
@ -159,7 +159,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 704
|
||||
Left = 718
|
||||
Top = 22
|
||||
Width = 26
|
||||
Height = 12
|
||||
|
@ -172,7 +172,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 832
|
||||
Left = 846
|
||||
Top = 22
|
||||
Width = 39
|
||||
Height = 12
|
||||
|
@ -185,7 +185,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
ParentFont = False
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 76
|
||||
Left = 90
|
||||
Top = 18
|
||||
Width = 85
|
||||
Height = 20
|
||||
|
@ -195,7 +195,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 167
|
||||
Left = 181
|
||||
Top = 18
|
||||
Width = 86
|
||||
Height = 20
|
||||
|
@ -206,7 +206,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
object ConNo: TEdit
|
||||
Tag = 2
|
||||
Left = 329
|
||||
Left = 343
|
||||
Top = 18
|
||||
Width = 81
|
||||
Height = 20
|
||||
|
@ -215,7 +215,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
object C_CodeName: TEdit
|
||||
Tag = 2
|
||||
Left = 473
|
||||
Left = 487
|
||||
Top = 18
|
||||
Width = 83
|
||||
Height = 20
|
||||
|
@ -224,7 +224,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
object C_Spec: TEdit
|
||||
Tag = 2
|
||||
Left = 600
|
||||
Left = 614
|
||||
Top = 18
|
||||
Width = 83
|
||||
Height = 20
|
||||
|
@ -233,7 +233,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
object FactoryNoName: TEdit
|
||||
Tag = 2
|
||||
Left = 732
|
||||
Left = 746
|
||||
Top = 18
|
||||
Width = 80
|
||||
Height = 20
|
||||
|
@ -242,13 +242,26 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
object JHPlace: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Left = 882
|
||||
Top = 18
|
||||
Width = 80
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnChange = ConNoChange
|
||||
end
|
||||
object CheckBox2: TCheckBox
|
||||
Left = 17
|
||||
Top = 18
|
||||
Width = 20
|
||||
Height = 17
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 7
|
||||
end
|
||||
end
|
||||
object ScrollBox1: TScrollBox
|
||||
Left = 0
|
||||
|
@ -283,14 +296,12 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column20
|
||||
end
|
||||
item
|
||||
Kind = skCount
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
|
@ -329,11 +340,9 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column17
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column16
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
|
@ -429,21 +438,8 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 47
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36864#36135#21305#25968
|
||||
DataBinding.FieldName = 'T_Ps'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #36864#36135#25968#37327
|
||||
DataBinding.FieldName = 'T_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #22238#20179#21305#25968
|
||||
Caption = #20986#24211#21305#25968
|
||||
DataBinding.FieldName = 'H_PS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
|
@ -454,7 +450,7 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
Width = 60
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #22238#20179#25968#37327
|
||||
Caption = #20986#24211#25968#37327
|
||||
DataBinding.FieldName = 'H_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
|
@ -482,45 +478,6 @@ object frmClothContractList_Help: TfrmClothContractList_Help
|
|||
Styles.Header = cxStyle_fontclFuchsia
|
||||
Width = 60
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #23454#38469#32553#29575'(%)'
|
||||
DataBinding.FieldName = 'Srate'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '0.##%;-,0.##%'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Content = cxStyle_fontclGreen
|
||||
Styles.Footer = cxStyle_fontclGreen
|
||||
Styles.Header = cxStyle_fontclGreen
|
||||
Width = 80
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #35745#21010#32553#29575'(%)'
|
||||
DataBinding.FieldName = 'Mrate'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '0.##%;-,0.##%'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #26816#39564#21305#25968
|
||||
DataBinding.FieldName = 'J_PS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclTeal
|
||||
Styles.Footer = cxStyle_fontclTeal
|
||||
Styles.Header = cxStyle_fontclTeal
|
||||
Width = 60
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #26816#39564#25968#37327
|
||||
DataBinding.FieldName = 'J_Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Content = cxStyle_fontclTeal
|
||||
Styles.Footer = cxStyle_fontclTeal
|
||||
Styles.Header = cxStyle_fontclTeal
|
||||
Width = 60
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
|
|
|
@ -6,12 +6,24 @@ uses
|
|||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter,
|
||||
RM_Common, RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport,
|
||||
cxTextEdit, cxCheckBox, cxCurrencyEdit, cxLookAndFeels,
|
||||
cxLookAndFeelPainters, cxNavigator;
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses, cxControls,
|
||||
cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class,
|
||||
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxCheckBox,
|
||||
cxCurrencyEdit, cxLookAndFeels, 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
|
||||
TfrmClothContractList_Help = class(TForm)
|
||||
|
@ -59,7 +71,6 @@ type
|
|||
Label6: TLabel;
|
||||
FactoryNoName: TEdit;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Ssel: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
|
@ -81,16 +92,12 @@ type
|
|||
cxStyle_fontclOlive: TcxStyle;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label7: TLabel;
|
||||
JHPlace: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
Order_Main: TClientDataSet;
|
||||
ToolButton1: TToolButton;
|
||||
CheckBox2: TCheckBox;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
|
@ -102,13 +109,10 @@ type
|
|||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoChange(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure v2Column3PropertiesButtonClick(Sender: TObject;
|
||||
AButtonIndex: Integer);
|
||||
procedure v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure conPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView;
|
||||
ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo;
|
||||
var ADone: Boolean);
|
||||
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
private
|
||||
FInt, PFInt: Integer;
|
||||
procedure InitGrid();
|
||||
|
@ -123,6 +127,7 @@ var
|
|||
frmClothContractList_Help: TfrmClothContractList_Help;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_ClothContractInPut, U_Fun, U_ProductOrderList, U_ZDYHelp;
|
||||
|
||||
|
@ -133,8 +138,7 @@ begin
|
|||
frmClothContractList_Help := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_Help.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
procedure TfrmClothContractList_Help.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
@ -160,8 +164,18 @@ begin
|
|||
sql.Clear;
|
||||
Filtered := False;
|
||||
sql.Add('exec P_Get_Contract');
|
||||
if CheckBox2.Checked = True then
|
||||
begin
|
||||
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||
end
|
||||
else
|
||||
begin
|
||||
sql.Add('@begdate=''2000-01-01'' ');
|
||||
sql.Add(',@enddate=''2050-01-01'' ');
|
||||
end;
|
||||
// sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||
// sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||
sql.Add(',@conType=''坯布到货'' ');
|
||||
sql.Add(',@status=''' + inttostr(0) + ''' ');
|
||||
Open;
|
||||
|
@ -183,7 +197,8 @@ end;
|
|||
|
||||
procedure TfrmClothContractList_Help.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active=False then Exit;
|
||||
if ADOQueryMain.Active = False then
|
||||
Exit;
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
|
@ -191,7 +206,8 @@ end;
|
|||
|
||||
procedure TfrmClothContractList_Help.TBEditClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
try
|
||||
frmClothContractInPut := TfrmClothContractInPut.Create(Application);
|
||||
with frmClothContractInPut do
|
||||
|
@ -215,16 +231,17 @@ end;
|
|||
|
||||
procedure TfrmClothContractList_Help.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then Exit;
|
||||
if ADOQueryMain.IsEmpty then
|
||||
Exit;
|
||||
TcxGridToExcel('坯布合同订单列表', cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_Help.TBPrintClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile, FConNoM: string;
|
||||
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\坯布订购合同.rmf';
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
|
@ -232,8 +249,7 @@ begin
|
|||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec ClothContract_QryList :MainId,:WSql');
|
||||
Parameters.ParamByName('WSql').Value:=' and FillTime>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.DateTime))+''''
|
||||
+' and FillTime<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.DateTime+1))+'''';
|
||||
Parameters.ParamByName('WSql').Value := ' and FillTime>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + '''' + ' and FillTime<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.DateTime + 1)) + '''';
|
||||
Parameters.ParamByName('MainId').Value := Trim(Order_Main.fieldbyname('MainId').AsString);
|
||||
Parameters.ParamByName('WSql').Value := '';
|
||||
Open;
|
||||
|
@ -252,7 +268,8 @@ begin
|
|||
//RMVariables['printer']:=Trim(gUserName);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\坯布订购合同.rmf'), '提示', 0);
|
||||
end;
|
||||
|
@ -266,7 +283,8 @@ end;
|
|||
|
||||
procedure TfrmClothContractList_Help.ConNoChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active=False then Exit;
|
||||
if ADOQueryMain.Active = False then
|
||||
Exit;
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
|
@ -277,8 +295,7 @@ begin
|
|||
InitForm();
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_Help.v2Column3PropertiesButtonClick(
|
||||
Sender: TObject; AButtonIndex: Integer);
|
||||
procedure TfrmClothContractList_Help.v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
|
@ -300,12 +317,12 @@ begin
|
|||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_Help.conPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
procedure TfrmClothContractList_Help.conPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
if Length(Trim(ConNo.Text))<4 then Exit;
|
||||
if Length(Trim(ConNo.Text)) < 4 then
|
||||
Exit;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
|
@ -327,29 +344,29 @@ end;
|
|||
|
||||
procedure TfrmClothContractList_Help.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
IF Order_Main.IsEmpty then exit;
|
||||
if Order_Main.IsEmpty then
|
||||
exit;
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmClothContractList_Help.Tv1CustomDrawIndicatorCell(
|
||||
Sender: TcxGridTableView; ACanvas: TcxCanvas;
|
||||
AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
procedure TfrmClothContractList_Help.Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
var
|
||||
FValue: string;
|
||||
FBounds: TRect;
|
||||
begin
|
||||
FBounds := AViewInfo.Bounds;
|
||||
if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||
begin
|
||||
ACanvas.FillRect(FBounds);
|
||||
ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||
FValue :=IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index+1);
|
||||
InflateRect(FBounds, -1, -1) ;
|
||||
ACanvas.Font.Color := clBlack;
|
||||
ACanvas.Brush.Style := bsClear;
|
||||
ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
ADone := True;
|
||||
end;
|
||||
// FBounds := AViewInfo.Bounds;
|
||||
// if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||
// begin
|
||||
// ACanvas.FillRect(FBounds);
|
||||
// ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||
// FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1);
|
||||
// InflateRect(FBounds, -1, -1);
|
||||
// ACanvas.Font.Color := clBlack;
|
||||
// ACanvas.Brush.Style := bsClear;
|
||||
// ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
// ADone := True;
|
||||
// end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
618
管理系统/U_ClothContractOutPut.dfm
Normal file
618
管理系统/U_ClothContractOutPut.dfm
Normal file
|
@ -0,0 +1,618 @@
|
|||
object frmClothContractOutPut: TfrmClothContractOutPut
|
||||
Left = 404
|
||||
Top = 253
|
||||
Width = 1046
|
||||
Height = 541
|
||||
Caption = #22383#24067#20986#24211
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1030
|
||||
Height = 29
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
EdgeInner = esNone
|
||||
EdgeOuter = esNone
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_TradeManage.ThreeImgList
|
||||
List = True
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBSave: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20445#23384
|
||||
ImageIndex = 14
|
||||
OnClick = TBSaveClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object ScrollBox1: TScrollBox
|
||||
Left = 0
|
||||
Top = 29
|
||||
Width = 1030
|
||||
Height = 96
|
||||
Align = alTop
|
||||
BevelInner = bvNone
|
||||
BevelOuter = bvNone
|
||||
Ctl3D = False
|
||||
ParentCtl3D = False
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 20
|
||||
Top = 14
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20219#21153#21333#21495#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 290
|
||||
Top = 14
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #21040#36135#26085#26399#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 290
|
||||
Top = 38
|
||||
Width = 67
|
||||
Height = 12
|
||||
Caption = #20379' '#26041#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 28
|
||||
Top = 166
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #31614#35746#26085#26399#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Visible = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 20
|
||||
Top = 38
|
||||
Width = 67
|
||||
Height = 12
|
||||
Caption = #38656' '#26041#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 231
|
||||
Top = 270
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #31614#35746#22320#28857#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Visible = False
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 548
|
||||
Top = 38
|
||||
Width = 66
|
||||
Height = 12
|
||||
Caption = #32852' '#31995' '#20154#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 290
|
||||
Top = 62
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #21040#36135#22320#28857#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label9: TLabel
|
||||
Left = 20
|
||||
Top = 62
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #32852#31995#26041#24335#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label10: TLabel
|
||||
Left = 546
|
||||
Top = 14
|
||||
Width = 91
|
||||
Height = 12
|
||||
Caption = #37319#36141#35745#21010#21333#21495#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object ConNo: TEdit
|
||||
Left = 86
|
||||
Top = 11
|
||||
Width = 137
|
||||
Height = 18
|
||||
TabOrder = 0
|
||||
end
|
||||
object DeliveryDate: TDateTimePicker
|
||||
Left = 353
|
||||
Top = 10
|
||||
Width = 134
|
||||
Height = 20
|
||||
BevelInner = bvNone
|
||||
Date = 40916.000000000000000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40916.000000000000000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object FactoryNoName: TcxButtonEdit
|
||||
Left = 353
|
||||
Top = 34
|
||||
Hint = 'FactoryNo'
|
||||
BeepOnEnter = False
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
Properties.OnButtonClick = FactoryNoNamePropertiesButtonClick
|
||||
Properties.OnChange = FactoryNoNamePropertiesChange
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 2
|
||||
Width = 134
|
||||
end
|
||||
object PanZDY: TPanel
|
||||
Left = 861
|
||||
Top = 128
|
||||
Width = 202
|
||||
Height = 153
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
object CXGridZDY: TcxGrid
|
||||
Left = 3
|
||||
Top = 4
|
||||
Width = 197
|
||||
Height = 113
|
||||
TabOrder = 0
|
||||
object TVZDY: TcxGridDBTableView
|
||||
OnKeyPress = TVZDYKeyPress
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCellDblClick = TVZDYCellDblClick
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.GroupByBox = False
|
||||
object VHelpZDYName: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'ZDYName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.handBlack
|
||||
Width = 163
|
||||
IsCaptionAssigned = True
|
||||
end
|
||||
end
|
||||
object CXGridZDYLevel1: TcxGridLevel
|
||||
GridView = TVZDY
|
||||
end
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 64
|
||||
Top = 120
|
||||
Width = 65
|
||||
Height = 25
|
||||
Caption = #20851#38381
|
||||
TabOrder = 1
|
||||
OnClick = Button1Click
|
||||
end
|
||||
end
|
||||
object QDTime: TDateTimePicker
|
||||
Left = 90
|
||||
Top = 162
|
||||
Width = 140
|
||||
Height = 20
|
||||
BevelInner = bvNone
|
||||
Date = 40916.670856296290000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40916.670856296290000000
|
||||
ShowCheckbox = True
|
||||
TabOrder = 4
|
||||
Visible = False
|
||||
end
|
||||
object CompanyName: TcxButtonEdit
|
||||
Left = 85
|
||||
Top = 34
|
||||
BeepOnEnter = False
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = CompanyNamePropertiesButtonClick
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 5
|
||||
Width = 136
|
||||
end
|
||||
object QDPalce: TEdit
|
||||
Left = 311
|
||||
Top = 271
|
||||
Width = 131
|
||||
Height = 18
|
||||
TabOrder = 6
|
||||
Visible = False
|
||||
end
|
||||
object LXPerson: TEdit
|
||||
Left = 611
|
||||
Top = 35
|
||||
Width = 134
|
||||
Height = 18
|
||||
TabOrder = 7
|
||||
end
|
||||
object LXTel: TEdit
|
||||
Left = 85
|
||||
Top = 59
|
||||
Width = 136
|
||||
Height = 18
|
||||
TabOrder = 8
|
||||
end
|
||||
object JHPlace: TcxButtonEdit
|
||||
Left = 353
|
||||
Top = 58
|
||||
BeepOnEnter = False
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = JHPlacePropertiesButtonClick
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 9
|
||||
Width = 392
|
||||
end
|
||||
object fromConNo: TcxButtonEdit
|
||||
Left = 633
|
||||
Top = 10
|
||||
BeepOnEnter = False
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = fromConNoPropertiesButtonClick
|
||||
Style.BorderStyle = ebsSingle
|
||||
TabOrder = 10
|
||||
OnKeyPress = fromConNoKeyPress
|
||||
Width = 116
|
||||
end
|
||||
end
|
||||
object ToolBar2: TToolBar
|
||||
Left = 0
|
||||
Top = 125
|
||||
Width = 1030
|
||||
Height = 29
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
EdgeInner = esNone
|
||||
EdgeOuter = esNone
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_TradeManage.ThreeImgList
|
||||
List = True
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 2
|
||||
object ToolButton1: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #22686#34892
|
||||
ImageIndex = 103
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#34892
|
||||
ImageIndex = 107
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 126
|
||||
Top = 0
|
||||
Width = 467
|
||||
Height = 30
|
||||
BevelOuter = bvNone
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 154
|
||||
Width = 1030
|
||||
Height = 219
|
||||
Align = alTop
|
||||
TabOrder = 3
|
||||
object Tv1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Format = 'C_Code'
|
||||
Column = v1Column1
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.FocusCellOnTab = True
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsBehavior.FocusCellOnCycle = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsCustomize.ColumnSorting = False
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20135#21697#21517#31216
|
||||
DataBinding.FieldName = 'C_CodeName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = v1Column1PropertiesButtonClick
|
||||
Properties.OnEditValueChanged = v1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 100
|
||||
end
|
||||
object v1PRTSpec: TcxGridDBColumn
|
||||
Caption = #35268#26684#22411#21495
|
||||
DataBinding.FieldName = 'C_Spec'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Styles.Header = DataLink_TradeManage.handBlack
|
||||
Width = 103
|
||||
end
|
||||
object v1PRTColor: TcxGridDBColumn
|
||||
Caption = #20811#37325'(g/'#13217')'
|
||||
DataBinding.FieldName = 'KZQty'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Styles.Header = DataLink_TradeManage.handBlack
|
||||
VisibleForCustomization = False
|
||||
Width = 78
|
||||
end
|
||||
object v1PRTKZ: TcxGridDBColumn
|
||||
Caption = #38376#24133'(cm)'
|
||||
DataBinding.FieldName = 'MFQty'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Styles.Header = DataLink_TradeManage.handBlack
|
||||
VisibleForCustomization = False
|
||||
Width = 80
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #21305#25968
|
||||
DataBinding.FieldName = 'Qty1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 54
|
||||
end
|
||||
object v1ClothUnit: TcxGridDBColumn
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C_Qty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = v1ClothUnitPropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.handBlack
|
||||
Width = 69
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #25968#37327#21333#20301
|
||||
DataBinding.FieldName = 'C_Unit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.DropDownListStyle = lsFixedList
|
||||
Properties.Items.Strings = (
|
||||
'M'
|
||||
'Kg')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 64
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #21305#25968
|
||||
DataBinding.FieldName = 'Qty1'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 46
|
||||
end
|
||||
object v1T_Ps: TcxGridDBColumn
|
||||
Caption = #36864#36135#21305#25968
|
||||
DataBinding.FieldName = 'T_Ps'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object v1T_Qty: TcxGridDBColumn
|
||||
Caption = #36864#36135#25968#37327
|
||||
DataBinding.FieldName = 'T_Qty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = v1Column6PropertiesEditValueChanged
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object v1T_Price: TcxGridDBColumn
|
||||
Caption = #36864#36135#21333#20215
|
||||
DataBinding.FieldName = 'T_Price'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = v1Column6PropertiesEditValueChanged
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object v1T_money: TcxGridDBColumn
|
||||
Caption = #36864#36135#37329#39069
|
||||
DataBinding.FieldName = 'T_money'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'C_Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 177
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #25104#21697#21697#21517
|
||||
DataBinding.FieldName = 'CP_CodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 118
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object ADOTemp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 816
|
||||
Top = 85
|
||||
end
|
||||
object ADOCmd: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 800
|
||||
Top = 109
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Sub
|
||||
Left = 356
|
||||
Top = 192
|
||||
end
|
||||
object Order_Sub: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 424
|
||||
Top = 192
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ADOZDY
|
||||
Left = 240
|
||||
Top = 8
|
||||
end
|
||||
object ADOZDY: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 280
|
||||
Top = 5
|
||||
end
|
||||
object CDS_ZDY: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 208
|
||||
Top = 16
|
||||
end
|
||||
object ADOQueryTmp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 792
|
||||
Top = 125
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 528
|
||||
Top = 200
|
||||
end
|
||||
end
|
1135
管理系统/U_ClothContractOutPut.pas
Normal file
1135
管理系统/U_ClothContractOutPut.pas
Normal file
File diff suppressed because it is too large
Load Diff
|
@ -34,6 +34,7 @@ uses
|
|||
U_ClothContractList_SJDCK, U_KH_XS_YP_list, U_ProductOrderNewList_BH,
|
||||
U_ClothContractList_HZ1, U_ClothContractList_CP, U_ClothContractList_SJD,
|
||||
U_ClothContractList_XPKF, U_ClothContractList_DY, U_ClothContractList_Dp,
|
||||
U_ClothContractList_CK,
|
||||
U_ClothContractList_SJDMX, U_ClothContractList_PBKC;
|
||||
|
||||
/////////////////////////////////////////////////////////////////
|
||||
|
@ -625,6 +626,28 @@ begin
|
|||
//句柄
|
||||
mnewHandle := frmCpRkSaoMNew.Handle;
|
||||
|
||||
end;
|
||||
315: //Å÷²¼³ö¿â
|
||||
begin
|
||||
if frmClothContractList_CK = nil then
|
||||
begin
|
||||
frmClothContractList_CK := TfrmClothContractList_CK.Create(application.MainForm);
|
||||
with frmClothContractList_CK do
|
||||
begin
|
||||
caption := Trim(Title);
|
||||
fDParameters1 := trim(DParameters1);
|
||||
// fDParameters1:=trim('²éѯ');
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmClothContractList_CK.BringToFront;
|
||||
//¾ä±ú
|
||||
mnewHandle := frmClothContractList_CK.Handle;
|
||||
|
||||
end;
|
||||
15: //坯布采购 到货 投匹
|
||||
begin
|
||||
|
|
Loading…
Reference in New Issue
Block a user