UNPKG

youzanyun-devtool-worker

Version:

- web - ws - proxy

29 lines (28 loc) 831 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const tslib_1 = require("tslib"); const axios_1 = tslib_1.__importDefault(require("axios")); let dpShowcaseTemplate; class DpShowcaseTemplate { static getInstance() { if (!dpShowcaseTemplate) { dpShowcaseTemplate = new DpShowcaseTemplate(); } return dpShowcaseTemplate; } async run(ctx) { const { templateId, status, appName } = ctx.query; const res = await axios_1.default({ method: "GET", url: "http://127.0.0.1:31240/api/design-platform/local/template/detail", params: { status, templateId, appName, } }); ctx.body = res.data; } } exports.default = DpShowcaseTemplate; ;