注释掉‘不受理’和‘当场颁发许可’行还是有错!我把这个功能页面的代码发上来你看下吧!谢谢
unit SQZCT;
interface
uses
Business.System, Business.Model, Business.Forms, Business.Data,
Business.Model.Flow;
type
TSQZCT = class(TForm)
FuncBroker: TFuncBroker;
InfoBrokerXKSQXX: TInfoBroker;
InfoBrokerJTXZXKSQSXSCYJXX: TInfoBroker;
InfoBrokerJTXZXKSQBYSLTZXX: TInfoBroker;
InfoBrokerLNGCSGXKZXX: TInfoBroker;
InfoBrokerJTXZXKSQBZTZXX: TInfoBroker;
InfoBrokerJTXZXKSQSLTZXX: TInfoBroker;
ControlBar: TControlBar;
DataNavigator: TDataNavigator;
DocViewBar: TDocViewBar;
PageControl: TPageControl;
TabSheet: TTabSheet;
DocViewXKSQXX_SQXK: TDocView;
TabSheet2: TTabSheet;
DocViewJTXZXKSQBYSLTZXX_JTXZXKSQBYSLTZS: TDocView;
TabSheet4: TTabSheet;
DocViewJTXZXKSQBZTZXX_JTXZXKSQBZTZS: TDocView;
TabSheet5: TTabSheet;
TabSheet1: TTabSheet;
DocViewJTXZXKSQSXSCYJXX_JTXZXKSQSXSCYJB: TDocView;
TabSheet3: TTabSheet;
DocViewLNGCSGXKZXX_LNXZSGXKZ: TDocView;
RadioButton1: TRadioButton;
RadioButton2: TRadioButton;
RadioButton3: TRadioButton;
RadioButton4: TRadioButton;
DataSetBroker1: TDataSetBroker;
DocViewJTXZXKSQSLTZXX_JTXZXKSQSLTZS: TDocView;
Panel1: TPanel;
SpeedButton1: TSpeedButton;
FlowBroker1: TFlowBroker;
procedure RadioButton1Click(Sender: TObject);
procedure RadioButton2Click(Sender: TObject);
procedure RadioButton3Click(Sender: TObject);
procedure RadioButton4Click(Sender: TObject);
procedure SpeedButton1Click(Sender: TObject);
procedure FlowBroker1CreateFlowOutFlowTasks(Sender: TObject; Command: TFlowOutCommand);
procedure FlowBroker1AfterFlowOut(Sender: TObject; Command: TFlowOutCommand);
private
{private declarations}
public
{public declarations}
end;
implementation
procedure TSQZCT.RadioButton1Click(Sender: TObject);
begin
if TRadioButton(Sender).Checked then
Begin
// PageControl.ActivePage := TabSheet5;
TabSheet2.Show;
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('DJANHZT').AsString :='不受理';
DataSetBroker1.DataSet.ApplyUpdates;
end;
end;
procedure TSQZCT.RadioButton2Click(Sender: TObject);
begin
if TRadioButton(Sender).Checked then
Begin
// PageControl.ActivePage := TabSheet5;
TabSheet4.Show;
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('DJANHZT').AsString :='补正';
DataSetBroker1.DataSet.ApplyUpdates;
end;
end;
procedure TSQZCT.RadioButton3Click(Sender: TObject);
begin
if TRadioButton(Sender).Checked then
Begin
// PageControl.ActivePage := TabSheet5;
TabSheet5.Show;
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('DJANHZT').AsString :='受理';
DataSetBroker1.DataSet.ApplyUpdates;
end;
end;
procedure TSQZCT.RadioButton4Click(Sender: TObject);
begin
if TRadioButton(Sender).Checked then
Begin
TabSheet3.Show;
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('DJANHZT').AsString :='当场颁发许可';
DataSetBroker1.DataSet.ApplyUpdates;
end;
end;
procedure TSQZCT.SpeedButton1Click(Sender: TObject);
begin
TabSheet1.Show;
end;
procedure TSQZCT.FlowBroker1CreateFlowOutFlowTasks(Sender: TObject; Command: TFlowOutCommand);
begin
if command.FlowTasks[0].ProcUnit.ID = 'JTXZXKSQSXSCDDYJGN' then
begin
command.FlowTasks[0].Subject := '大队审查意见:' + DataSetBroker1.DataSet.FieldByName('JTXZXKSQSXJNR').AsString;
end;
if command.FlowTasks[0].ProcUnit.ID = 'SQGN' then
begin
command.FlowTasks[0].Subject := '等待补正:' + DataSetBroker1.DataSet.FieldByName('JTXZXKSQSXJNR').AsString;
end;
{
if command.FlowTasks[0].ProcUnit.ID = 'FINISH3' then
begin
command.FlowTasks[0].Subject := '不予受理:' + DataSetBroker1.DataSet.FieldByName('JTXZXKSQSXJNR').AsString;
end;
if command.FlowTasks[0].ProcUnit.ID = 'FINISH4' then
begin
command.FlowTasks[0].Subject := '当场颁发许可证:' + DataSetBroker1.DataSet.FieldByName('JTXZXKSQSXJNR').AsString;
end;
}
end;
procedure TSQZCT.FlowBroker1AfterFlowOut(Sender: TObject; Command: TFlowOutCommand);
begin
if command.FlowTasks[0].ProcUnit.ID = 'JTXZXKSQSXSCDDYJGN' then
begin
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('XZXKZT').AsString :='4';
DataSetBroker1.DataSet.ApplyUpdates;
end;
if command.FlowTasks[0].ProcUnit.ID = 'FINISH3' then
begin
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('XZXKZT').AsString :='0';
DataSetBroker1.DataSet.ApplyUpdates;
end;
if command.FlowTasks[0].ProcUnit.ID = 'FINISH4' then
begin
DataSetBroker1.DataSet.Edit;
DataSetBroker1.DataSet.FieldByName('XZXKZT').AsString :='2';
DataSetBroker1.DataSet.ApplyUpdates;
end;
end;
end. |