import { ContentType, HttpClient, RequestParams } from "/@/api/admin/http-client";
import { AxiosResponse } from 'axios'
export class MoreOilEngineDetailsApi<SecurityDataType = unknown> extends HttpClient<SecurityDataType>{

  timer = 400
  /**
   * No description
   *
   * @tags data
   * @name getOilListData
   * @summary  获取油机列表详情数据
   * @request POST:/api/app/fuel-dispenser/get-nozzlecontrol
   * @secure
   */
  getOilListData = (data: any, params: RequestParams = {}) =>
    this.request<AxiosResponse, any>({
      path: `/api/app/fuel-dispenser/get-nozzlecontrol`,
      method: 'POST',
      query: data,
      secure: true,
      type: ContentType.Json,
      ...params,
    })
  // getOilListData = () =>
  //   new Promise(resolve => {
  //     setTimeout(() => {
  //       resolve(
  //         {
  //           success: true,
  //           code: null,
  //           msg: null,
  //           data:
  //             [
  //               {
  //                 oilEngineName: "17",
  //                 oilEngineStatus: "离线",
  //                 oilSpecifications: "1主板1枪",
  //                 oils: "95号车用汽油",
  //                 selfLockingState: "关闭",
  //                 ECQSCode: "200023204009",
  //               },
  //               {
  //                 oilEngineName: "18",
  //                 oilEngineStatus: "离线",
  //                 oilSpecifications: "1主板2枪",
  //                 oils: "95号车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204015",
  //               },
  //               {
  //                 oilEngineName: "19",
  //                 oilEngineStatus: "离线",
  //                 oilSpecifications: "1主板3枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204036",
  //               },
  //               {
  //                 oilEngineName: "20",
  //                 oilEngineStatus: "离线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "21",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "22",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "23",
  //                 oilEngineStatus: "离线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "24",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "25",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "26",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               },
  //               {
  //                 oilEngineName: "27",
  //                 oilEngineStatus: "在线",
  //                 oilSpecifications: "1主板4枪",
  //                 oils: "98车用汽油",
  //                 selfLockingState: "已启动",
  //                 ECQSCode: "200023204059",
  //               }
  //             ]
  //         }
  //       )
  //     },this.timer)
  //   })

  /**
   * No description
   *
   * @tags data
   * @name getTableData
   * @summary  获取表格数据对象
   * @request POST:/api/app/fuel-dispenser/get-last-five-alarm-history
   * @secure
   */
  getTableData = (data: any, params: RequestParams = {}) =>
    this.request<AxiosResponse, any>({
      path: `/api/app/fuel-dispenser/get-last-five-alarm-history`,
      method: 'POST',
      query: data,
      secure: true,
      type: ContentType.Json,
      ...params,
    })
  // getTableData = () =>
  //   new Promise(resolve => {
  //     setTimeout(() => {
  //       resolve({
  //         success: true,
  //         code: null,
  //         msg: null,
  //         data:[{
  //           time: "string",
  //           refuelingGun: "string",
  //           alarmSource: "string",
  //           alarmDescription: "string",
  //           alarmType: "string"
  //         },{
  //           time: "string",
  //           refuelingGun: "string",
  //           alarmSource: "string",
  //           alarmDescription: "string",
  //           alarmType: "string"
  //         },{
  //           time: "string",
  //           refuelingGun: "string",
  //           alarmSource: "string",
  //           alarmDescription: "string",
  //           alarmType: "string"
  //         },{
  //           time: "string",
  //           refuelingGun: "string",
  //           alarmSource: "string",
  //           alarmDescription: "string",
  //           alarmType: "string"
  //         },
  //         {
  //           time: "string",
  //           refuelingGun: "string",
  //           alarmSource: "string",
  //           alarmDescription: "string",
  //           alarmType: "string"
  //         }]
  //       })
  //     },this.timer)
  //   })
}
