产品 资料 检验
This commit is contained in:
parent
e68b22ec0a
commit
71f1d62a17
|
|
@ -7,7 +7,6 @@ inherited frmTatClothInfo: TfrmTatClothInfo
|
|||
FormStyle = fsMDIChild
|
||||
Position = poScreenCenter
|
||||
Visible = True
|
||||
ExplicitLeft = -271
|
||||
ExplicitWidth = 1460
|
||||
ExplicitHeight = 741
|
||||
PixelsPerInch = 96
|
||||
|
|
|
|||
|
|
@ -854,7 +854,6 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
DataBinding.FieldName = 'Y_Qty'
|
||||
DataBinding.IsNullValueType = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
|
|
@ -1099,7 +1098,6 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
DataBinding.FieldName = 'Y_Qty'
|
||||
DataBinding.IsNullValueType = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object Tv2Column2: TcxGridDBColumn
|
||||
|
|
@ -1199,10 +1197,7 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
object cxTabSheet2: TcxTabSheet
|
||||
Caption = ' '#32441#29256#22270' '
|
||||
ImageIndex = 1
|
||||
ExplicitLeft = 0
|
||||
ExplicitTop = 0
|
||||
ExplicitWidth = 0
|
||||
ExplicitHeight = 0
|
||||
TabVisible = False
|
||||
object Panel7: TPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
|
|
@ -2259,10 +2254,7 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
object cxTabSheet3: TcxTabSheet
|
||||
Caption = ' '#36215#32508#24037#33402#21333' '
|
||||
ImageIndex = 2
|
||||
ExplicitLeft = 0
|
||||
ExplicitTop = 0
|
||||
ExplicitWidth = 0
|
||||
ExplicitHeight = 0
|
||||
TabVisible = False
|
||||
object Panel8: TPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
|
|
@ -2398,10 +2390,6 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
object cxTabSheet4: TcxTabSheet
|
||||
Caption = #31359#31576#27861
|
||||
ImageIndex = 3
|
||||
ExplicitLeft = 0
|
||||
ExplicitTop = 0
|
||||
ExplicitWidth = 0
|
||||
ExplicitHeight = 0
|
||||
object reed_weave_method: TMemo
|
||||
Left = 0
|
||||
Top = 0
|
||||
|
|
@ -2421,15 +2409,11 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
object cxTabSheet5: TcxTabSheet
|
||||
Caption = #32463#32433#25490#21015
|
||||
ImageIndex = 4
|
||||
ExplicitLeft = 0
|
||||
ExplicitTop = 0
|
||||
ExplicitWidth = 0
|
||||
ExplicitHeight = 0
|
||||
object warp_arrange: TMemo
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 600
|
||||
Height = 280
|
||||
Width = 1529
|
||||
Height = 350
|
||||
Align = alClient
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
|
|
@ -2444,15 +2428,11 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
object cxTabSheet6: TcxTabSheet
|
||||
Caption = #32428#25490#21015
|
||||
ImageIndex = 5
|
||||
ExplicitLeft = 0
|
||||
ExplicitTop = 0
|
||||
ExplicitWidth = 0
|
||||
ExplicitHeight = 0
|
||||
object weft_arrange: TMemo
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 600
|
||||
Height = 280
|
||||
Width = 1529
|
||||
Height = 350
|
||||
Align = alClient
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
|
|
@ -2464,6 +2444,100 @@ object frmTatClothInfoInput: TfrmTatClothInfoInput
|
|||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object cxTabSheet7: TcxTabSheet
|
||||
Caption = ' '#31359#32508#27861'/'#36215#32508#27861' '
|
||||
ImageIndex = 6
|
||||
object Splitter1: TSplitter
|
||||
Left = 762
|
||||
Top = 0
|
||||
Width = 5
|
||||
Height = 350
|
||||
end
|
||||
object Panel9: TPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 762
|
||||
Height = 350
|
||||
Align = alLeft
|
||||
BevelOuter = bvNone
|
||||
TabOrder = 0
|
||||
object Label26: TLabel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 762
|
||||
Height = 33
|
||||
Align = alTop
|
||||
AutoSize = False
|
||||
Caption = ' '#31359#32508#27861#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Layout = tlCenter
|
||||
end
|
||||
object threading_method: TMemo
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 762
|
||||
Height = 317
|
||||
Align = alClient
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -14
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
ScrollBars = ssVertical
|
||||
TabOrder = 0
|
||||
ExplicitTop = 16
|
||||
ExplicitHeight = 334
|
||||
end
|
||||
end
|
||||
object Panel10: TPanel
|
||||
Left = 767
|
||||
Top = 0
|
||||
Width = 762
|
||||
Height = 350
|
||||
Align = alClient
|
||||
BevelOuter = bvNone
|
||||
TabOrder = 1
|
||||
object Label27: TLabel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 762
|
||||
Height = 33
|
||||
Align = alTop
|
||||
AutoSize = False
|
||||
Caption = ' '#36215#32508#27861#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Layout = tlCenter
|
||||
end
|
||||
object lifting_method: TMemo
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 762
|
||||
Height = 317
|
||||
Align = alClient
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -14
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
ScrollBars = ssVertical
|
||||
TabOrder = 0
|
||||
ExplicitTop = 16
|
||||
ExplicitHeight = 334
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_ClothInfo.ADOLink
|
||||
|
|
|
|||
|
|
@ -234,6 +234,14 @@ type
|
|||
warp_arrange: TMemo;
|
||||
reed_weave_method: TMemo;
|
||||
weft_arrange: TMemo;
|
||||
cxTabSheet7: TcxTabSheet;
|
||||
Panel9: TPanel;
|
||||
Label26: TLabel;
|
||||
threading_method: TMemo;
|
||||
Splitter1: TSplitter;
|
||||
Panel10: TPanel;
|
||||
Label27: TLabel;
|
||||
lifting_method: TMemo;
|
||||
Label17: TLabel;
|
||||
Label18: TLabel;
|
||||
Label19: TLabel;
|
||||
|
|
@ -374,6 +382,8 @@ begin
|
|||
warp_arrange.Text := Trim(ADOQueryTemp.fieldbyname('warp_arrange').AsString);
|
||||
weft_arrange.Text := Trim(ADOQueryTemp.fieldbyname('weft_arrange').AsString);
|
||||
reed_weave_method.Text := Trim(ADOQueryTemp.fieldbyname('reed_weave_method').AsString);
|
||||
threading_method.Text := Trim(ADOQueryTemp.fieldbyname('threading_method').AsString);
|
||||
lifting_method.Text := Trim(ADOQueryTemp.fieldbyname('lifting_method').AsString);
|
||||
SCSHData(ADOQueryTemp, ScrollBox1, 2);
|
||||
SCSHData(ADOQueryTemp, ScrollBox1, 0);
|
||||
with ADOQueryTemp do
|
||||
|
|
@ -550,6 +560,14 @@ begin
|
|||
ADOQueryCmd.FieldByName('reed_weave_method').Value := null
|
||||
else
|
||||
ADOQueryCmd.FieldByName('reed_weave_method').Value := Trim(reed_weave_method.Text);
|
||||
if Trim(threading_method.Text) = '' then
|
||||
ADOQueryCmd.FieldByName('threading_method').Value := null
|
||||
else
|
||||
ADOQueryCmd.FieldByName('threading_method').Value := Trim(threading_method.Text);
|
||||
if Trim(lifting_method.Text) = '' then
|
||||
ADOQueryCmd.FieldByName('lifting_method').Value := null
|
||||
else
|
||||
ADOQueryCmd.FieldByName('lifting_method').Value := Trim(lifting_method.Text);
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
|
|
@ -796,7 +814,7 @@ begin
|
|||
C_Code.Text := MC_Code;
|
||||
|
||||
end;
|
||||
CALCYarnQty();
|
||||
// CALCYarnQty();
|
||||
if SaveData() then
|
||||
begin
|
||||
Application.MessageBox('±£´æ³É¹¦£¡', 'Ìáʾ', 0);
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ uses
|
|||
U_TrayManage in 'U_TrayManage.pas' {frmTrayManage},
|
||||
U_LabelMapSet in '..\A00通用窗体\U_LabelMapSet.pas' {frmLabelMapSet},
|
||||
U_LabelPrint in '..\A00通用窗体\U_LabelPrint.pas' {frmLabelPrint},
|
||||
U_TatClothInfoSel in '..\A00通用窗体\U_TatClothInfoSel.pas' {frmTatClothInfoSel},
|
||||
U_BaseDataLink in '..\..\..\public10\design\U_BaseDataLink.pas' {BaseDataLink: TDataModule},
|
||||
uSZHN_JSON in '..\..\..\public10\ThreeFun\Fun\uSZHN_JSON.pas';
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ inherited frmMachineManage: TfrmMachineManage
|
|||
Height = 38
|
||||
AutoSize = True
|
||||
ButtonHeight = 38
|
||||
ButtonWidth = 75
|
||||
ButtonWidth = 91
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
DisabledImages = DataLink_BaseInfo.ImageList_new32
|
||||
|
|
@ -84,16 +84,24 @@ inherited frmMachineManage: TfrmMachineManage
|
|||
Visible = False
|
||||
OnClick = tbPauseClick
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
object tbBindProd: TToolButton
|
||||
Left = 497
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #32465#23450#20135#21697
|
||||
ImageIndex = 4
|
||||
OnClick = tbBindProdClick
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 592
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25171#21360
|
||||
ImageIndex = 21
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 568
|
||||
Left = 663
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
|
|
@ -101,7 +109,7 @@ inherited frmMachineManage: TfrmMachineManage
|
|||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 639
|
||||
Left = 734
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
|
|
@ -181,6 +189,14 @@ inherited frmMachineManage: TfrmMachineManage
|
|||
HeaderAlignmentHorz = taCenter
|
||||
Width = 180
|
||||
end
|
||||
object v2Column9: TcxGridDBColumn
|
||||
Caption = #20135#21697#32534#21495
|
||||
DataBinding.FieldName = 'C_CodeName'
|
||||
DataBinding.IsNullValueType = True
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 140
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
|
|
|
|||
|
|
@ -49,6 +49,7 @@ type
|
|||
cxTabControl1: TcxTabControl;
|
||||
tbStart: TToolButton;
|
||||
tbPause: TToolButton;
|
||||
tbBindProd: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
|
|
@ -69,6 +70,7 @@ type
|
|||
procedure Tv2Column1PropertiesChange(Sender: TObject);
|
||||
procedure tbStartClick(Sender: TObject);
|
||||
procedure tbPauseClick(Sender: TObject);
|
||||
procedure tbBindProdClick(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
procedure InitGrid();
|
||||
|
|
@ -86,7 +88,7 @@ var
|
|||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_LabelPrint;
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_LabelPrint, U_TatClothInfoSel;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
|
|
@ -347,6 +349,106 @@ begin
|
|||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmMachineManage.tbBindProdClick(Sender: TObject);
|
||||
var
|
||||
MMCIDS, MCodeName: string;
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
Exit;
|
||||
if not CDS_HZ.Locate('SSel', True, []) then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
|
||||
MMCIDS := '';
|
||||
CDS_HZ.DisableControls;
|
||||
try
|
||||
CDS_HZ.First;
|
||||
while not CDS_HZ.Eof do
|
||||
begin
|
||||
if CDS_HZ.fieldbyname('SSel').AsBoolean then
|
||||
begin
|
||||
if MMCIDS <> '' then
|
||||
MMCIDS := MMCIDS + ',' + QuotedStr(Trim(CDS_HZ.fieldbyname('MCID').AsString))
|
||||
else
|
||||
MMCIDS := QuotedStr(Trim(CDS_HZ.fieldbyname('MCID').AsString));
|
||||
end;
|
||||
CDS_HZ.Next;
|
||||
end;
|
||||
finally
|
||||
CDS_HZ.EnableControls;
|
||||
end;
|
||||
|
||||
if MMCIDS = '' then
|
||||
Exit;
|
||||
|
||||
MCodeName := '';
|
||||
try
|
||||
frmTatClothInfoSel := TfrmTatClothInfoSel.Create(Application);
|
||||
if frmTatClothInfoSel.ShowModal = 1 then
|
||||
begin
|
||||
if not frmTatClothInfoSel.CDS_1.IsEmpty then
|
||||
MCodeName := Trim(frmTatClothInfoSel.CDS_1.fieldbyname('C_Code').AsString);
|
||||
end;
|
||||
finally
|
||||
frmTatClothInfoSel.Free;
|
||||
end;
|
||||
if MCodeName = '' then
|
||||
Exit;
|
||||
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('update BS_Machine set C_CodeName=' + QuotedStr(MCodeName));
|
||||
SQL.Add(' , Editer=''' + Trim(DName) + '''');
|
||||
SQL.Add(' , Edittime=getdate()');
|
||||
SQL.Add(' where MCID in (' + MMCIDS + ')');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('insert into SY_SysLog(operor,opertime,Model,acction,opevent,result) values( ');
|
||||
SQL.Add(' ' + QuotedStr(Trim(DName)));
|
||||
SQL.Add(',getdate() ');
|
||||
SQL.Add(',' + QuotedStr(Trim(self.Caption)));
|
||||
SQL.Add(',' + QuotedStr(Trim('绑定产品')));
|
||||
SQL.Add(',' + QuotedStr(Trim(MMCIDS + ' -> ' + MCodeName)));
|
||||
SQL.Add(',' + QuotedStr(Trim('成功')));
|
||||
SQL.Add(')');
|
||||
ExecSQL;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
|
||||
CDS_HZ.DisableControls;
|
||||
try
|
||||
CDS_HZ.First;
|
||||
while not CDS_HZ.Eof do
|
||||
begin
|
||||
if CDS_HZ.fieldbyname('SSel').AsBoolean then
|
||||
begin
|
||||
CDS_HZ.Edit;
|
||||
CDS_HZ.fieldbyname('C_CodeName').AsString := MCodeName;
|
||||
CDS_HZ.Post;
|
||||
end;
|
||||
CDS_HZ.Next;
|
||||
end;
|
||||
finally
|
||||
CDS_HZ.EnableControls;
|
||||
end;
|
||||
|
||||
Application.MessageBox('绑定成功!', '提示信息');
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox(PChar(Exception(ExceptObject).Message), '提示信息', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmMachineManage.N1Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
|
|
|
|||
|
|
@ -296,8 +296,6 @@ object frmTatInspEdit: TfrmTatInspEdit
|
|||
Height = 340
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
ExplicitTop = 138
|
||||
ExplicitHeight = 323
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
ScrollbarAnnotations.CustomAnnotations = <>
|
||||
|
|
@ -394,10 +392,9 @@ object frmTatInspEdit: TfrmTatInspEdit
|
|||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Caption = #25187#20998
|
||||
DataBinding.FieldName = 'CIFPoints'
|
||||
DataBinding.FieldName = 'Points'
|
||||
DataBinding.IsNullValueType = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
|
|
@ -405,7 +402,6 @@ object frmTatInspEdit: TfrmTatInspEdit
|
|||
DataBinding.FieldName = 'CIFNumber'
|
||||
DataBinding.IsNullValueType = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -447,7 +447,7 @@ type
|
|||
procedure CalcInputLenByWeightKZ;
|
||||
procedure AllocWeaverMeter(AIdx: Integer);
|
||||
function RoundUpToHalf(AValue: Double): Double; //decimal 0.1-0.4 -> 0.5, 0.6-0.9 -> next integer
|
||||
|
||||
function FormatQty2(AValue: Double): string;
|
||||
public
|
||||
fmanage: string;
|
||||
fFlileFlag: string;
|
||||
|
|
@ -465,6 +465,17 @@ uses
|
|||
U_SCPersonColor, U_SCPersonColor5, U_TatConSel;
|
||||
|
||||
{$R *.dfm}
|
||||
function TfrmTatMachInsp.FormatQty2(AValue: Double): string;
|
||||
var
|
||||
S: string;
|
||||
begin
|
||||
S := FormatFloat('0.00', AValue);
|
||||
|
||||
if (Length(S) >= 3) and (Copy(S, Length(S) - 2, 3) = '.00') then
|
||||
Result := Copy(S, 1, Length(S) - 3)
|
||||
else
|
||||
Result := S;
|
||||
end;
|
||||
|
||||
procedure TfrmTatMachInsp.CalcInputLenByWeightKZ;
|
||||
var
|
||||
|
|
@ -863,7 +874,7 @@ end;
|
|||
|
||||
procedure TfrmTatMachInsp.AllocWeaverMeter(AIdx: Integer);
|
||||
const
|
||||
CAdj = 4; //compensation meters, rule confirmed by workshop
|
||||
CAdj = 4;
|
||||
var
|
||||
L, M1, M2, M3: Double;
|
||||
begin
|
||||
|
|
@ -873,26 +884,31 @@ begin
|
|||
Application.MessageBox('Âë±í³¤¶ÈΪ¿Õ!', 'Ìáʾ', 0);
|
||||
Exit;
|
||||
end;
|
||||
|
||||
M1 := StrToFloatdef(Trim(OutPutQty1.Text), 0);
|
||||
M2 := StrToFloatdef(Trim(OutPutQty2.Text), 0);
|
||||
M3 := StrToFloatdef(Trim(OutPutQty3.Text), 0);
|
||||
|
||||
case AIdx of
|
||||
1: //weaver1: meter = code table length
|
||||
OutPutQty1.Text := FloatToStr(L);
|
||||
1:
|
||||
OutPutQty1.Text := FormatQty2(L);
|
||||
|
||||
2:
|
||||
begin //weaver2: meter1+=4; meter2 = L - meter1
|
||||
OutPutQty1.Text := FloatToStr(M1 + CAdj);
|
||||
OutPutQty2.Text := FloatToStr(L - M1 - CAdj);
|
||||
begin
|
||||
OutPutQty1.Text := FormatQty2(M1 + CAdj);
|
||||
OutPutQty2.Text := FormatQty2(L - M1 - CAdj);
|
||||
end;
|
||||
|
||||
3:
|
||||
begin //weaver3: meter2+=4; meter3 = L - meter1 - meter2
|
||||
OutPutQty2.Text := FloatToStr(M2 + CAdj);
|
||||
OutPutQty3.Text := FloatToStr(L - M1 - M2 - CAdj);
|
||||
begin
|
||||
OutPutQty2.Text := FormatQty2(M2 + CAdj);
|
||||
OutPutQty3.Text := FormatQty2(L - M1 - M2 - CAdj);
|
||||
end;
|
||||
|
||||
4:
|
||||
begin //weaver4: meter3+=4; meter4 = L - meter1 - meter2 - meter3
|
||||
OutPutQty3.Text := FloatToStr(M3 + CAdj);
|
||||
OutPutQty4.Text := FloatToStr(L - M1 - M2 - M3 - CAdj);
|
||||
begin
|
||||
OutPutQty3.Text := FormatQty2(M3 + CAdj);
|
||||
OutPutQty4.Text := FormatQty2(L - M1 - M2 - M3 - CAdj);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
|
@ -2717,6 +2733,8 @@ begin
|
|||
end;
|
||||
|
||||
procedure TfrmTatMachInsp.Button9Click(Sender: TObject);
|
||||
var
|
||||
MCode: string;
|
||||
begin
|
||||
|
||||
try
|
||||
|
|
@ -2728,6 +2746,44 @@ begin
|
|||
begin
|
||||
carno.text := trim(fname);
|
||||
|
||||
//带出机台绑定的产品信息,有值直接覆盖
|
||||
MCode := '';
|
||||
with Self.ADOTmp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('SELECT C_CodeName FROM Bs_Machine WHERE MCNO=' + QuotedStr(Trim(fname)));
|
||||
Open;
|
||||
if not IsEmpty then
|
||||
MCode := Trim(FieldByName('C_CodeName').AsString);
|
||||
end;
|
||||
|
||||
if MCode <> '' then
|
||||
begin
|
||||
with Self.ADOTmp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('SELECT A.* FROM Bs_Cloth_Info A WHERE A.C_Code=' + QuotedStr(MCode));
|
||||
Open;
|
||||
end;
|
||||
|
||||
if not Self.ADOTmp.IsEmpty then
|
||||
begin
|
||||
Self.Code.Text := Self.ADOTmp.FieldByName('C_Code').AsString;
|
||||
Self.CodeName.Text := Self.ADOTmp.FieldByName('C_Name').AsString;
|
||||
Self.MF.Text := Self.ADOTmp.FieldByName('C_Width').AsString;
|
||||
Self.KZ.Text := Self.ADOTmp.FieldByName('C_GramWeight').AsString;
|
||||
Self.SPEC.Text := Self.ADOTmp.FieldByName('C_SPEC').AsString;
|
||||
Self.C_LongitudeBatchNo.Text := Self.ADOTmp.fieldbyname('C_LongitudeBatchNo').AsString;
|
||||
Self.C_LatitudeBatchNo.Text := Self.ADOTmp.fieldbyname('C_LatitudeBatchNo').AsString;
|
||||
|
||||
FMainId := '';
|
||||
FSubId := '';
|
||||
Label14.Caption := '订单号';
|
||||
end;
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user