uf_warebalc.srf 1001 B

123456789101112131415161718192021222324252627282930313233343536
  1. $PBExportHeader$uf_warebalc.srf
  2. global type uf_warebalc from function_object
  3. end type
  4. forward prototypes
  5. global function integer uf_warebalc (integer arg_balctype, long arg_balcdateint, long arg_storageid, datetime arg_balcdate, ref string arg_msg)
  6. end prototypes
  7. global function integer uf_warebalc (integer arg_balctype, long arg_balcdateint, long arg_storageid, datetime arg_balcdate, ref string arg_msg);//uf_warebalc
  8. Long rslt = 1
  9. IF uf_warebalc_storage(arg_balctype,arg_balcdateint,arg_storageid,arg_balcdate,arg_msg) = 1 THEN
  10. IF arg_balctype = 1 THEN
  11. arg_msg = '结存操作成功'
  12. ELSE
  13. arg_msg = '反结存操作成功'
  14. END IF
  15. ELSE
  16. rslt = 0
  17. GOTO ext
  18. END IF
  19. //日志
  20. IF arg_balctype = 1 THEN
  21. f_setsysoplog('结存','结存,仓库ID:'+String(arg_storageid)+',期间:'+String(arg_balcdateint),arg_msg,True)
  22. ELSE
  23. f_setsysoplog('反结存','反结存,仓库ID:'+String(arg_storageid)+',期间:'+String(arg_balcdateint),arg_msg,True)
  24. END IF
  25. //--
  26. ext:
  27. RETURN rslt
  28. end function