UNPKG

@choerodon/master

Version:
61 lines (51 loc) 2.39 kB
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } var MasterApis = /*#__PURE__*/function () { function MasterApis() { _classCallCheck(this, MasterApis); } _createClass(MasterApis, null, [{ key: "getGuideUrl", value: function getGuideUrl(menuId, orgId, proId, tab_code) { return "/iam/choerodon/v1/guides?".concat(menuId ? "menu_id=".concat(menuId) : '').concat(orgId ? "&organization_id=".concat(orgId) : '').concat(proId ? "&project_id=".concat(proId) : '').concat(tab_code ? "&tab_code=".concat(tab_code) : ''); } }, { key: "getCheckUserCountUrl", value: function getCheckUserCountUrl(tenantId) { return "/iam/choerodon/v1/register_saas/check_user_count?tenant_id=".concat(tenantId); } }, { key: "getCheckOwnerUrl", value: function getCheckOwnerUrl(tenantId) { return "/iam/choerodon/v1/register_saas/check_owner?tenantId=".concat(tenantId); } }, { key: "getPageMemberUrl", value: function getPageMemberUrl(orgId) { return "/iam/choerodon/v1/register_saas/".concat(orgId, "/page_member"); } }, { key: "getCleanMemberUrl", value: function getCleanMemberUrl(tenantId) { return "/iam/choerodon/v1/register_saas/clean_member?tenant_id=".concat(tenantId); } }, { key: "getHelpDocUrl", value: function getHelpDocUrl(props) { var str = ''; if (props.menuId) { str += "menu_id=".concat(props.menuId); } if (props.menuCode) { str += "&menu_code=".concat(props.menuCode); } if (props.tabCode) { str += "&tab_code=".concat(props.tabCode); } return "/iam/choerodon/v1/help-doc?".concat(str); } }]); return MasterApis; }(); export { MasterApis as default };