All Downloads are FREE. Search and download functionalities are using the official Maven repository.

web-interface.assets.325e2d4b-8585.fb3b52cc087d367cf00d.js.map Maven / Gradle / Ivy

There is a newer version: 6.0.1
Show newest version
{"version":3,"file":"325e2d4b-8585.fb3b52cc087d367cf00d.js","mappings":"maAiCA,MAkGA,EAlG8BA,IAAiB,CAE7CC,YAAa,wBACbC,OAAQ,CAACC,IAAAA,QAAeC,EAAAA,IAExBC,gBAAe,KACN,CACLC,YAAaC,EAAAA,EAAAA,UAAsBC,QACnCC,iBAAkB,CAAC,EACnBC,iBAAkB,CAAC,EACnBC,iBAAaC,IAIjBC,oBACEC,EAAAA,EAAAA,iBACD,EAEDC,gBAAgBC,GACd,MAAM,YAAEV,EAAF,iBAAeI,EAAf,iBAAiCD,GAAqBQ,KAAKC,MAEjED,KAAKE,SAAS,CACZb,YAAaU,EAASV,aAAeA,EACrCI,iBAAkBM,EAASN,kBAAoBA,EAC/CD,iBAAkBO,EAASP,kBAAoBA,GAElD,EAEDW,UACE,MAAM,YAAEd,GAAgBW,KAAKC,MAE7BG,EAAAA,EAAAA,OAAAA,eAA0Cf,EAAYgB,UACnDC,MACC,KACEC,EAAAA,EAAAA,QAAyB,qCAAsC,YAC/DC,EAAAA,EAAAA,KAAaC,EAAAA,GAAAA,OAAAA,aAAAA,KAAb,IAEDC,IAIC,IAAIC,EAAe,GAEfD,EAASE,YAAcF,EAASE,WAAWC,MAAQH,EAASE,WAAWC,KAAKC,UAC9EH,EAAgB,gBAAeD,EAASE,WAAWC,KAAKC,mBAG1DP,EAAAA,EAAAA,MATgB,qHASiBI,EAPnB,gCAOd,GAGP,EAEDI,aAAatB,GACX,MAAM,YAAEJ,GAAgBW,KAAKC,MAE7BJ,EAAAA,EAAAA,oBAAmCJ,GAAkBa,MAAMU,IACzD,MAAMC,EAAiB5B,EAAY6B,YAEhCC,SAASH,EAAOG,SAASC,KAAKC,GAAMC,EAAAA,EAAAA,SAAgBD,GAAG,EAAMhC,EAAYkC,eACzEhC,QACGiC,EAAkBR,EAAOG,SAASC,KAAKC,GAAMC,EAAAA,EAAAA,SAAgBD,GAAG,EAAOhC,EAAYkC,cAEzFvB,KAAKE,SAAS,CAAEb,YAAa4B,EAAgBO,mBAA7C,GAEH,EAEDC,SACE,MAAM,YAAEpC,EAAF,gBAAemC,EAAf,iBAAgC/B,EAAhC,iBAAkDD,EAAlD,YAAoEE,GAAgBM,KAAKC,MAE/F,OACE,gBAAC,KAAD,CAAeyB,MAAM,iBACnB,4BACE,gBAAC,KAAD,CAAYA,MAAM,uBACNC,WACE,gBAAC,IAAD,CAAeC,GAAInB,EAAAA,GAAAA,OAAAA,aAAAA,MACjB,gBAAC,KAAD,CAAQoB,QAAQ,QAAhB,mBAGd,6KAEE,2BAFF,8BAG8B,IAH9B,IAGmC,qBAAGC,KAAK,mCAAmCC,OAAO,SAASC,IAAI,uBAA/D,2BAHnC,MAMF,gBAAC,IAAD,CAAiB3C,YAAaA,EACb4C,cAAejC,KAAKe,aACpBmB,cAAelC,KAAKF,gBACpB0B,gBAAiBA,EACjB/B,iBAAkBA,EAClBD,iBAAkBA,EAClBE,YAAaA,EACbyC,OAAQnC,KAAKG,WAIrC,G","sources":["webpack://graylog-web-interface/./src/pages/CreateContentPackPage.jsx"],"sourcesContent":["/*\n * Copyright (C) 2020 Graylog, Inc.\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the Server Side Public License, version 1,\n * as published by MongoDB, Inc.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * Server Side Public License for more details.\n *\n * You should have received a copy of the Server Side Public License\n * along with this program. If not, see\n * .\n */\nimport React from 'react';\nimport Reflux from 'reflux';\n// eslint-disable-next-line no-restricted-imports\nimport createReactClass from 'create-react-class';\n\nimport { LinkContainer } from 'components/common/router';\nimport Routes from 'routing/Routes';\nimport { Button } from 'components/bootstrap';\nimport history from 'util/History';\nimport UserNotification from 'util/UserNotification';\nimport { DocumentTitle, PageHeader } from 'components/common';\nimport ContentPackEdit from 'components/content-packs/ContentPackEdit';\nimport ContentPack from 'logic/content-packs/ContentPack';\nimport Entity from 'logic/content-packs/Entity';\nimport { CatalogStore, CatalogActions } from 'stores/content-packs/CatalogStore';\nimport { ContentPacksActions } from 'stores/content-packs/ContentPacksStore';\n\nconst CreateContentPackPage = createReactClass({\n  // eslint-disable-next-line react/no-unused-class-component-methods\n  displayName: 'CreateContentPackPage',\n  mixins: [Reflux.connect(CatalogStore)],\n\n  getInitialState() {\n    return {\n      contentPack: ContentPack.builder().build(),\n      appliedParameter: {},\n      selectedEntities: {},\n      entityIndex: undefined,\n    };\n  },\n\n  componentDidMount() {\n    CatalogActions.showEntityIndex();\n  },\n\n  _onStateChanged(newState) {\n    const { contentPack, selectedEntities, appliedParameter } = this.state;\n\n    this.setState({\n      contentPack: newState.contentPack || contentPack,\n      selectedEntities: newState.selectedEntities || selectedEntities,\n      appliedParameter: newState.appliedParameter || appliedParameter,\n    });\n  },\n\n  _onSave() {\n    const { contentPack } = this.state;\n\n    ContentPacksActions.create.triggerPromise(contentPack.toJSON())\n      .then(\n        () => {\n          UserNotification.success('Content pack imported successfully', 'Success!');\n          history.push(Routes.SYSTEM.CONTENTPACKS.LIST);\n        },\n        (response) => {\n          const message = 'Error importing content pack, please ensure it is a valid JSON file. Check your '\n            + 'Graylog logs for more information.';\n          const title = 'Could not import content pack';\n          let smallMessage = '';\n\n          if (response.additional && response.additional.body && response.additional.body.message) {\n            smallMessage = `
${response.additional.body.message}`;\n }\n\n UserNotification.error(message + smallMessage, title);\n },\n );\n },\n\n _getEntities(selectedEntities) {\n const { contentPack } = this.state;\n\n CatalogActions.getSelectedEntities(selectedEntities).then((result) => {\n const newContentPack = contentPack.toBuilder()\n /* Mark entities from server */\n .entities(result.entities.map((e) => Entity.fromJSON(e, true, contentPack.parameters)))\n .build();\n const fetchedEntities = result.entities.map((e) => Entity.fromJSON(e, false, contentPack.parameters));\n\n this.setState({ contentPack: newContentPack, fetchedEntities });\n });\n },\n\n render() {\n const { contentPack, fetchedEntities, selectedEntities, appliedParameter, entityIndex } = this.state;\n\n return (\n \n \n \n \n \n )}>\n \n Content packs accelerate the set up process for a specific data source. A content pack can include inputs/extractors, streams, and dashboards.\n
\n Find more content packs in {' '} the Graylog Marketplace.\n
\n
\n \n
\n
\n );\n },\n});\n\nexport default CreateContentPackPage;\n"],"names":["createReactClass","displayName","mixins","Reflux","CatalogStore","getInitialState","contentPack","ContentPack","build","appliedParameter","selectedEntities","entityIndex","undefined","componentDidMount","CatalogActions","_onStateChanged","newState","this","state","setState","_onSave","ContentPacksActions","toJSON","then","UserNotification","history","Routes","response","smallMessage","additional","body","message","_getEntities","result","newContentPack","toBuilder","entities","map","e","Entity","parameters","fetchedEntities","render","title","topActions","to","bsStyle","href","target","rel","onGetEntities","onStateChange","onSave"],"sourceRoot":""}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy