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

📄 updacpta.pas

📁 拥有全套神州数码马易飞ERP源码,现上传部分源码
💻 PAS
字号:
unit updACPTA;

interface

uses sysUtils, dbtables, Bde, updBase, ComObj, CONSTDEF,LibStrs, Messages, Dialogs;

type
  TUpdateACPTA = class(TBaseUpdateUnit)
  private
    FOtherVar: variant;
    function update_byPURI11(xQrySource: TQuery): Boolean;
    function update_byPURI09(xQrySource: TQuery): Boolean;
    function update_byMOCI06(xQrySource: TQuery): Boolean;
    function update_byACPI03(xQrySource: TQuery): Boolean;
    function update_byMOCI07(xQrySource: TQuery): Boolean;
    function update_byACPI02(xQrySource: TQuery): Boolean;
    function update_byRMAI15(xQrySource: TQuery): Boolean;
    function Add1(xValue: string): string;
    function ZeroATfirst64(xValue: Int64; xLen: Integer): string;
  public
    function update(xQrySource: TQuery; xAction: string;
       var xMsg: variant; xOtherVar: variant; xUserData: variant): Boolean;
  end;

implementation

function TUpdateACPTA.update(xQrySource: TQuery; xAction: string;
           var xMsg: variant; xOtherVar: variant; xUserData: variant): Boolean;
begin
  Result := True;
  self.saveVar(xAction, xOtherVar, xUserData);
  FOtherVar:= xOtherVar;
  try
    setDBName(xQrySource.databaseName);
    if compareText(self.SourceTxnCode, 'TXNACPI02') = 0 then
      Result := update_byACPI02(xQrySource)
    else
    if compareText(self.SourceTxnCode, 'TXNACPI03') = 0 then
      Result := update_byACPI03(xQrySource)
    else
    if compareText(self.SourceTxnCode, 'TXNPURI11') = 0 then
      Result := update_byPURI11(xQrySource)
    else
    if ((compareText(self.SourceTxnCode, 'TXNPURI09') = 0) OR (compareText(self.SourceTxnCode, 'TXNPURI13') = 0)) then
      Result := update_byPURI09(xQrySource)
    else
    if ((compareText(self.SourceTxnCode, 'TXNMOCI06') = 0) OR (compareText(self.SourceTxnCode, 'TXNMOCI11') = 0)) then
      Result := update_byMOCI06(xQrySource)
    else
    if compareText(self.SourceTxnCode, 'TXNMOCI07') = 0 then
      Result := update_byMOCI07(xQrySource)
    else
    if compareText(self.SourceTxnCode, 'TXNRMAI15') = 0 then
      Result := update_byRMAI15(xQrySource)
    else
    begin
    end;
  finally
    self.Query1.close;
    self.Query1.UnPrepare;
  end;
  xMsg := self.Msg;
end;

function TUpdateACPTA.update_byACPI03(xQrySource: TQuery): Boolean;
var
  mTA026,mACPTASeqNo,mDBNAME : string ;
  mexist : Boolean ;
  mSign:Integer;
  mBit,mMONEY,mResult,mDate : string;
  vValidator:OleVariant;
  mTA037,mRate,mTA030,mm:Double;
begin
  Result := True;
  self.Msg[0] := 'skip';
  self.Msg[1] := 'ACPTA:ACPTB';
  with xQrySOurce do
    self.Msg[2] := fieldByName('TD001').asString+' '+FieldByName('TD002').asString+' '+
                   fieldByName('TD003').asString;

  mDBNAME:=FOtherVar[1]; // dbname
  mDate:=FOtherVar[2]; // 

⌨️ 快捷键说明

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