"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports["default"] = void 0;
var _utils = require("@vtx/utils");
var _ahooks = require("ahooks");
var VideoService = {
  getChannels: function getChannels(billId, ready) {
    var _useRequest = (0, _ahooks.useRequest)(function () {
        return _utils.request.get("".concat(process.env.PREFIX || '', "/cloud/vis/base/np/videoDevice/loadVideoChannelByBillId.smvc"), {
          data: {
            billId: billId
          }
        });
      }, {
        ready: ready,
        refreshDeps: [billId]
      }),
      channelRes = _useRequest.data;
    var channels = (channelRes === null || channelRes === void 0 ? void 0 : channelRes.data) ? JSON.parse(channelRes.data) : [];
    return {
      channels: channels
    };
  }
};
var _default = exports["default"] = VideoService;
//# sourceMappingURL=api.js.map
