index.ts 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. /** ================================= 现货报表 ================================**/
  2. import APP from '@/services';
  3. import * as type from './interface';
  4. import { commonSearch_go } from '@/services/go/index';
  5. import { QuerySpotDayReportReq } from './interface';
  6. import { QuerySpotDayReportDetailReq } from './interface';
  7. import { QuerySpotMonthReportReq } from './interface';
  8. import { QuerySpotMonthReportDetailReq } from './interface';
  9. import { QuerySpotPLReportReq } from './interface';
  10. /**
  11. * 查询现货损益报表
  12. * @param queryInfo 查询条件
  13. * @returns 现货损益报表
  14. */
  15. export async function QuerySpotPLReport(queryInfo: QuerySpotPLReportReq): Promise<type.QuerySpotPLReportRsp[]> {
  16. try {
  17. return commonSearch_go('/Ermcp3/QryReportAreaSpotPL', queryInfo);
  18. } catch (err) {
  19. throw new Error(`查询现货损益报表: ${err.message}`);
  20. }
  21. }
  22. /**
  23. * 查询现货报表
  24. * @param queryInfo 查询信息
  25. * @returns 现货报表
  26. */
  27. export async function QuerySpotDayReport(queryInfo: QuerySpotDayReportReq): Promise<type.QuerySpotDayReportRsp[]> {
  28. try {
  29. return commonSearch_go('/Ermcp3/QryReportDaySpot', queryInfo);
  30. } catch (err) {
  31. throw new Error(`查询现货报表: ${err.message}`);
  32. }
  33. }
  34. /**
  35. * 查询现货明细报表
  36. * @param queryInfo 查询信息
  37. * @returns 现货明细报表
  38. */
  39. export async function QuerySpotDayReportDetail(queryInfo: QuerySpotDayReportDetailReq): Promise<type.QuerySpotDayReportDetailRsp[]> {
  40. try {
  41. return commonSearch_go('/Ermcp3/QryReportDaySpotDetail', queryInfo);
  42. } catch (err) {
  43. throw new Error(`查询现货明细报表: ${err.message}`);
  44. }
  45. }
  46. /**
  47. * 查询现货月报表
  48. * @param queryInfo 查询信息
  49. * @returns 现货月报表数据
  50. */
  51. export async function QuerySpotMonthReport(queryInfo: QuerySpotMonthReportReq): Promise<type.QuerySpotMonthReportRsp[]> {
  52. try {
  53. return commonSearch_go('/Ermcp3/QryReportMonthSpot', { queryInfo });
  54. } catch (err) {
  55. throw new Error(`查询现货月报表: ${err.message}`);
  56. }
  57. }
  58. /**
  59. * 查询现货月报表明细
  60. * @param queryInfo 查询信息
  61. * @returns 现货月报表明细
  62. */
  63. export async function QuerySpotMonthReportDetail(queryInfo: QuerySpotMonthReportDetailReq): Promise<type.QuerySpotMonthReportDetailRsp[]> {
  64. try {
  65. return commonSearch_go('/Ermcp3/QryReportMonthSpotDetail', { queryInfo });
  66. } catch (err) {
  67. throw new Error(`查询现货月报表明细: ${err.message}`);
  68. }
  69. }