Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -191,9 +191,53 @@ page 20405 "Qlty. Inspection Gen. Rules"
actionref(CreateNewGenerationRuleForProdWizard_Promoted; CreateNewGenerationRuleForProdWizard)
{
}
actionref(CreateNewGenerationRuleForAsmWizard_Promoted; CreateNewGenerationRuleForAsmWizard)
{
}
}
area(Processing)
{
action(CreateNewGenerationRuleForAsmWizard)
{
Caption = 'Create Assembly Rule';
ToolTip = 'Specifies to create a rule for assembly.';
Image = Receipt;
ApplicationArea = Assembly;

trigger OnAction()
var
NewQltyInspectionGenRule: Record "Qlty. Inspection Gen. Rule";
RecQltyAsmGenRuleWizard: Page "Qlty. Asm. Gen. Rule Wizard";
begin
NewQltyInspectionGenRule.CopyFilters(Rec);
RecQltyAsmGenRuleWizard.RunModalWithGenerationRule(NewQltyInspectionGenRule);
CurrPage.Update(false);
end;
}
action(EditGenerationRuleForAsmWizard)
{
ApplicationArea = Assembly;
Caption = 'Edit Assembly Rule';
ToolTip = 'Edit a Rule for assembly.';
Image = Receipt;
Scope = Repeater;
Visible = ShowEditWizardAssemblyRule;

trigger OnAction()
var
QltyAsmGenRuleWizard: Page "Qlty. Asm. Gen. Rule Wizard";
PreviousEntryNo: Integer;
begin
PreviousEntryNo := Rec."Entry No.";
QltyAsmGenRuleWizard.RunModalWithGenerationRule(Rec);

CurrPage.Update(false);
Rec.Reset();
Rec.SetRange("Entry No.", PreviousEntryNo);
if Rec.FindSet() then;
Rec.SetRange("Entry No.");
end;
}
action(CreateNewGenerationRuleForProdWizard)
{
Caption = 'Create Production Rule';
Expand All @@ -203,9 +247,11 @@ page 20405 "Qlty. Inspection Gen. Rules"

trigger OnAction()
var
NewQltyInspectionGenRule: Record "Qlty. Inspection Gen. Rule";
RecQltyProdGenRuleWizard: Page "Qlty. Prod. Gen. Rule Wizard";
begin
RecQltyProdGenRuleWizard.RunModalWithGenerationRule(Rec);
NewQltyInspectionGenRule.CopyFilters(Rec);
RecQltyProdGenRuleWizard.RunModalWithGenerationRule(NewQltyInspectionGenRule);
CurrPage.Update(false);
end;
}
Expand Down Expand Up @@ -242,9 +288,11 @@ page 20405 "Qlty. Inspection Gen. Rules"

trigger OnAction()
var
NewQltyInspectionGenRule: Record "Qlty. Inspection Gen. Rule";
QltyRecGenRuleWizard: Page "Qlty. Rec. Gen. Rule Wizard";
begin
QltyRecGenRuleWizard.RunModalWithGenerationRule(Rec);
NewQltyInspectionGenRule.CopyFilters(Rec);
QltyRecGenRuleWizard.RunModalWithGenerationRule(NewQltyInspectionGenRule);
CurrPage.Update(false);
end;
}
Expand Down Expand Up @@ -281,9 +329,11 @@ page 20405 "Qlty. Inspection Gen. Rules"

trigger OnAction()
var
RecQltyWhseGenRuleWizard: Page "Qlty. Whse. Gen. Rule Wizard";
NewQltyInspectionGenRule: Record "Qlty. Inspection Gen. Rule";
QltyWhseGenRuleWizard: Page "Qlty. Whse. Gen. Rule Wizard";
begin
RecQltyWhseGenRuleWizard.RunModalWithGenerationRule(Rec);
NewQltyInspectionGenRule.CopyFilters(Rec);
QltyWhseGenRuleWizard.RunModalWithGenerationRule(NewQltyInspectionGenRule);
CurrPage.Update(false);
end;
}
Expand Down Expand Up @@ -365,6 +415,7 @@ page 20405 "Qlty. Inspection Gen. Rules"
ShowEditWizardMovementRule: Boolean;
ShowEditWizardReceivingRule: Boolean;
ShowEditWizardProductionRule: Boolean;
ShowEditWizardAssemblyRule: Boolean;
TemplateCode: Code[20];
ShowAssemblyTrigger: Boolean;
ShowProductionTrigger: Boolean;
Expand Down Expand Up @@ -459,6 +510,7 @@ page 20405 "Qlty. Inspection Gen. Rules"
ShowEditWizardProductionRule := true;
ShowEditWizardReceivingRule := true;
ShowEditWizardMovementRule := true;
ShowEditWizardAssemblyRule := true;
EditAssemblyTrigger := true;
EditProductionTrigger := true;
EditPurchaseTrigger := true;
Expand All @@ -480,7 +532,7 @@ page 20405 "Qlty. Inspection Gen. Rules"
case KnownOrInferredIntent of
Rec.Intent::Assembly:
begin
ShowEditWizardProductionRule := true;
ShowEditWizardAssemblyRule := true;
EditAssemblyTrigger := true;
AssemblyStyle := Format(RowStyle::Standard);
end;
Expand Down Expand Up @@ -527,6 +579,7 @@ page 20405 "Qlty. Inspection Gen. Rules"
begin
ShowEditWizardReceivingRule := false;
ShowEditWizardProductionRule := false;
ShowEditWizardAssemblyRule := false;
ShowEditWizardMovementRule := false;
EditProductionTrigger := false;
EditAssemblyTrigger := false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,8 @@ codeunit 20404 "Qlty. Inspection - Create"
if IsNewlyCreatedInspection then
QltyStartWorkflow.StartWorkflowInspectionCreated(QltyInspectionHeader);

if GuiAllowed() and not PreventShowingGeneratedInspectionEvenIfConfigured then
if GuiAllowed() and not PreventShowingGeneratedInspectionEvenIfConfigured
and (QltyInspectionHeader."No." <> '') then
if IsManualCreation then
Page.Run(Page::"Qlty. Inspection", QltyInspectionHeader)
else
Expand Down
Loading
Loading