⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 demand_enter.pas

📁 delphi的一个开发实例
💻 PAS
📖 第 1 页 / 共 5 页
字号:
                Application.MessageBox('【审核】操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end
    else if Flag1=2 then
    begin
        if Application.MessageBox('确定需要【反审核】该单据吗?'+#13#10+'如果【反审核】你将使后面级别的人的【审核】作废,'+#13#10+'后面级别的人必须重新【审核】,才能够生效,请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man1='''',Examine_Man2='''',Examine_Man3='''',Examine_Man4='''',Examine_Man5='''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;

                    L1.Caption:=LevelName1+':'+Handle_Man;
                    L2.Caption:=LevelName2+':'+Handle_Man;
                    L3.Caption:=LevelName3+':'+Handle_Man;
                    L4.Caption:=LevelName4+':'+Handle_Man;
                    L5.Caption:=LevelName5+':'+Handle_Man;
                    Flag2:=1; Flag3:=1; Flag4:=1; Flag5:=1;
                    L1.Visible:=True;
                    Flag1:=1;
                    Application.MessageBox('【反审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('【反审核】操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end;
end;
procedure Tfrm_Demand_Enter.Cmd2Click(Sender: TObject);

begin
    if Flag2=1 then
    begin
        if Application.MessageBox('确定需要【审核】该单据吗?请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man2='''+Trim(Handle_Man)+''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L2.Caption:='';
                    L2.Caption:=LevelName2+'【已审】';
                    Flag2:=2;
                    Application.MessageBox('【审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end
    else if Flag2=2 then
    begin
        if Application.MessageBox('确定需要【反审核】该单据吗?'+#13#10+'如果【反审核】你将使后面级别的人的【审核】作废,'+#13#10+'后面级别的人必须重新【审核】,才能够生效,请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man2='''',Examine_Man3='''',Examine_Man4='''',Examine_Man5='''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L2.Caption:='';
                    L2.Caption:=LevelName2+':'+Handle_Man;
                    L2.Visible:=True;
                    L3.Caption:=LevelName3+':'+Handle_Man;
                    L4.Caption:=LevelName4+':'+Handle_Man;
                    L5.Caption:=LevelName5+':'+Handle_Man;
                    Flag2:=1;Flag3:=1; Flag4:=1; Flag5:=1;
                    Application.MessageBox('【反审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end;
end;
procedure Tfrm_Demand_Enter.Cmd3Click(Sender: TObject);
begin
    if Flag3=1 then
    begin
        if Application.MessageBox('确定需要【审核】该单据吗?请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man3='''+Trim(Handle_Man)+''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L3.Caption:='';
                    L3.Caption:=LevelName2+'【已审】';
                    Flag3:=2;
                    Application.MessageBox('【审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end
    else if Flag3=2 then
    begin
        if Application.MessageBox('确定需要【反审核】该单据吗?'+#13#10+'如果【反审核】你将使后面级别的人的【审核】作废,'+#13#10+'后面级别的人必须重新【审核】,才能够生效,请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man3='''',Examine_Man3='''',Examine_Man4='''',Examine_Man5='''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L3.Caption:='';
                    L3.Caption:=LevelName2+':'+Handle_Man;
                    L3.Visible:=True;
                    L3.Caption:=LevelName3+':'+Handle_Man;
                    L4.Caption:=LevelName4+':'+Handle_Man;
                    L5.Caption:=LevelName5+':'+Handle_Man;
                    Flag3:=1;Flag3:=1; Flag4:=1; Flag5:=1;
                    Application.MessageBox('【反审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end;
end;

procedure Tfrm_Demand_Enter.Cmd4Click(Sender: TObject);
begin
    if Flag4=1 then
    begin
        if Application.MessageBox('确定需要【审核】该单据吗?请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man4='''+Trim(Handle_Man)+''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L4.Caption:='';
                    L4.Caption:=LevelName4+'【已审】';
                    Flag4:=2;
                    Application.MessageBox('【审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end
    else if Flag4=2 then
    begin
        if Application.MessageBox('确定需要【反审核】该单据吗?'+#13#10+'如果【反审核】你将使后面级别的人的【审核】作废,'+#13#10+'后面级别的人必须重新【审核】,才能够生效,请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man4='''',Examine_Man5='''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;

                    L4.Caption:=LevelName4+':'+Handle_Man;
                    L4.Visible:=True;
                    L5.Caption:=LevelName5+':'+Handle_Man;
                    Flag4:=1;Flag5:=1;
                    Application.MessageBox('【反审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end;
end;

procedure Tfrm_Demand_Enter.Cmd5Click(Sender: TObject);
begin
    if Flag5=1 then
    begin
        if Application.MessageBox('确定需要【审核】该单据吗?请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man5='''+Trim(Handle_Man)+''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;
                    L5.Caption:='';
                    L5.Caption:=LevelName5+'【已审】';
                    Flag5:=2;
                    Application.MessageBox('【审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end
    else if Flag5=2 then
    begin
        if Application.MessageBox('确定需要【反审核】该单据吗?'+#13#10+'如果【反审核】你将使后面级别的人的【审核】作废,'+#13#10+'后面级别的人必须重新【审核】,才能够生效,请确认!',pchar(application.Title),mb_okcancel)=idok then
        begin
            try
                with frm_data.ClientDataSet_Receipt do
                begin
                    Close;
                    Commandtext:='';
                    Commandtext:='Update [Receipt] set Examine_Man5='''' where Receipt_No='''+Trim(Edit_Submit_adopt_NO.Text)+''' and Receipt_Name=''受托代销入库单''';
                    Execute;

                    L5.Caption:=LevelName5+':'+Handle_Man;
                    L5.Visible:=True;
                    Flag5:=1;
                    Application.MessageBox('【反审核】操作成功!请确认',Pchar(application.Title),MB_ICONwarning);
                    Cmd_Check_Filsh;
                end;
            except
                Application.MessageBox('操作失败!,请确认!',pchar(application.Title),mb_iconwarning);
                Exit;
            end;
        end;
    end;
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -