update login sso address
This commit is contained in:
84
src/App.js
84
src/App.js
@ -1,42 +1,42 @@
|
||||
import React, { Component } from 'react';
|
||||
import { BrowserRouter, Route, Switch } from 'react-router-dom';
|
||||
import './scss/style.scss';
|
||||
|
||||
|
||||
const loading = (
|
||||
<div className="pt-3 text-center">
|
||||
<div className="sk-spinner sk-spinner-pulse"></div>
|
||||
</div>
|
||||
)
|
||||
|
||||
// Containers
|
||||
const TheLayout = React.lazy(() => import('./containers/TheLayout'));
|
||||
|
||||
// Pages
|
||||
const Login = React.lazy(() => import('./views/pages/login/Login'));
|
||||
const Register = React.lazy(() => import('./views/pages/register/Register'));
|
||||
const Page404 = React.lazy(() => import('./views/pages/page404/Page404'));
|
||||
const Page500 = React.lazy(() => import('./views/pages/page500/Page500'));
|
||||
const Sso = React.lazy(() => import('./views/sso/index'));
|
||||
|
||||
class App extends Component {
|
||||
|
||||
render() {
|
||||
return (
|
||||
<BrowserRouter>
|
||||
<React.Suspense fallback={loading}>
|
||||
<Switch>
|
||||
<Route exact path="/sso" name="SSO Login" render={props => <Sso {...props}/>} />
|
||||
<Route exact path="/login" name="Login Page" render={props => <Login {...props}/>} />
|
||||
<Route exact path="/register" name="Register Page" render={props => <Register {...props}/>} />
|
||||
<Route exact path="/404" name="Page 404" render={props => <Page404 {...props}/>} />
|
||||
<Route exact path="/500" name="Page 500" render={props => <Page500 {...props}/>} />
|
||||
<Route path="/" name="Home" render={props => <TheLayout {...props}/>} />
|
||||
</Switch>
|
||||
</React.Suspense>
|
||||
</BrowserRouter>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default App;
|
||||
import React, { Component } from 'react';
|
||||
import { BrowserRouter, Route, Switch } from 'react-router-dom';
|
||||
import './scss/style.scss';
|
||||
|
||||
|
||||
const loading = (
|
||||
<div className="pt-3 text-center">
|
||||
<div className="sk-spinner sk-spinner-pulse"></div>
|
||||
</div>
|
||||
)
|
||||
|
||||
// Containers
|
||||
const TheLayout = React.lazy(() => import('./containers/TheLayout'));
|
||||
|
||||
// Pages
|
||||
const Login = React.lazy(() => import('./views/pages/login/Login'));
|
||||
const Register = React.lazy(() => import('./views/pages/register/Register'));
|
||||
const Page404 = React.lazy(() => import('./views/pages/page404/Page404'));
|
||||
const Page500 = React.lazy(() => import('./views/pages/page500/Page500'));
|
||||
const Sso = React.lazy(() => import('./views/sso/index'));
|
||||
|
||||
class App extends Component {
|
||||
|
||||
render() {
|
||||
return (
|
||||
<BrowserRouter>
|
||||
<React.Suspense fallback={loading}>
|
||||
<Switch>
|
||||
<Route exact path="/sso" name="SSO Login" render={props => <Sso {...props}/>} />
|
||||
<Route exact path="/login" name="Login Page" render={props => <Login {...props}/>} />
|
||||
<Route exact path="/register" name="Register Page" render={props => <Register {...props}/>} />
|
||||
<Route exact path="/404" name="Page 404" render={props => <Page404 {...props}/>} />
|
||||
<Route exact path="/500" name="Page 500" render={props => <Page500 {...props}/>} />
|
||||
<Route path="/" name="Home" render={props => <TheLayout {...props}/>} />
|
||||
</Switch>
|
||||
</React.Suspense>
|
||||
</BrowserRouter>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default App;
|
||||
|
||||
@ -1,21 +1,21 @@
|
||||
import React from 'react'
|
||||
import { shallow } from 'enzyme/build'
|
||||
import App from './App'
|
||||
import ChartLineSimple from './views/charts/ChartLineSimple'
|
||||
import Dashboard from './views/dashboard/Dashboard.js'
|
||||
|
||||
|
||||
it('mounts App without crashing', () => {
|
||||
const wrapper = shallow(<App/>)
|
||||
wrapper.unmount()
|
||||
})
|
||||
|
||||
it('mounts Dashboard without crashing', () => {
|
||||
const wrapper = shallow(<Dashboard/>)
|
||||
wrapper.unmount()
|
||||
})
|
||||
|
||||
it('mounts Charts without crashing', () => {
|
||||
const wrapper = shallow(<ChartLineSimple/> )
|
||||
wrapper.unmount()
|
||||
})
|
||||
import React from 'react'
|
||||
import { shallow } from 'enzyme/build'
|
||||
import App from './App'
|
||||
import ChartLineSimple from './views/charts/ChartLineSimple'
|
||||
import Dashboard from './views/dashboard/Dashboard.js'
|
||||
|
||||
|
||||
it('mounts App without crashing', () => {
|
||||
const wrapper = shallow(<App/>)
|
||||
wrapper.unmount()
|
||||
})
|
||||
|
||||
it('mounts Dashboard without crashing', () => {
|
||||
const wrapper = shallow(<Dashboard/>)
|
||||
wrapper.unmount()
|
||||
})
|
||||
|
||||
it('mounts Charts without crashing', () => {
|
||||
const wrapper = shallow(<ChartLineSimple/> )
|
||||
wrapper.unmount()
|
||||
})
|
||||
|
||||
@ -1,263 +1,263 @@
|
||||
import { sygnet } from './sygnet'
|
||||
import { logo } from './logo'
|
||||
import { logoNegative } from './logo-negative'
|
||||
|
||||
import {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackoverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilArrowTop,
|
||||
cilAsterisk,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilGraph,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilScrubber,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilX,
|
||||
cilXCircle,
|
||||
cilWarning,
|
||||
cilEyedropper
|
||||
} from '@coreui/icons'
|
||||
|
||||
export const icons = Object.assign({}, {
|
||||
sygnet,
|
||||
logo,
|
||||
logoNegative
|
||||
}, {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilArrowTop,
|
||||
cilAsterisk,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilGraph,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilScrubber,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilX,
|
||||
cilXCircle,
|
||||
cilWarning
|
||||
}, {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
}, {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackoverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex,
|
||||
cilEyedropper
|
||||
import { sygnet } from './sygnet'
|
||||
import { logo } from './logo'
|
||||
import { logoNegative } from './logo-negative'
|
||||
|
||||
import {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackoverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
} from '@coreui/icons'
|
||||
import {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilArrowTop,
|
||||
cilAsterisk,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilGraph,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilScrubber,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilX,
|
||||
cilXCircle,
|
||||
cilWarning,
|
||||
cilEyedropper
|
||||
} from '@coreui/icons'
|
||||
|
||||
export const icons = Object.assign({}, {
|
||||
sygnet,
|
||||
logo,
|
||||
logoNegative
|
||||
}, {
|
||||
cilAlignCenter,
|
||||
cilAlignLeft,
|
||||
cilAlignRight,
|
||||
cilApplicationsSettings,
|
||||
cilArrowRight,
|
||||
cilArrowTop,
|
||||
cilAsterisk,
|
||||
cilBan,
|
||||
cilBasket,
|
||||
cilBell,
|
||||
cilBold,
|
||||
cilBookmark,
|
||||
cilCalculator,
|
||||
cilCalendar,
|
||||
cilCloudDownload,
|
||||
cilChartPie,
|
||||
cilCheck,
|
||||
cilChevronBottom,
|
||||
cilChevronLeft,
|
||||
cilChevronRight,
|
||||
cilChevronTop,
|
||||
cilCircle,
|
||||
cilCheckCircle,
|
||||
cilCode,
|
||||
cilCommentSquare,
|
||||
cilCreditCard,
|
||||
cilCursor,
|
||||
cilCursorMove,
|
||||
cilDrop,
|
||||
cilDollar,
|
||||
cilEnvelopeClosed,
|
||||
cilEnvelopeLetter,
|
||||
cilEnvelopeOpen,
|
||||
cilEuro,
|
||||
cilGlobeAlt,
|
||||
cilGrid,
|
||||
cilFile,
|
||||
cilFullscreen,
|
||||
cilFullscreenExit,
|
||||
cilGraph,
|
||||
cilHome,
|
||||
cilInbox,
|
||||
cilIndentDecrease,
|
||||
cilIndentIncrease,
|
||||
cilInputPower,
|
||||
cilItalic,
|
||||
cilJustifyCenter,
|
||||
cilJustifyLeft,
|
||||
cilLaptop,
|
||||
cilLayers,
|
||||
cilLightbulb,
|
||||
cilList,
|
||||
cilListNumbered,
|
||||
cilListRich,
|
||||
cilLocationPin,
|
||||
cilLockLocked,
|
||||
cilMagnifyingGlass,
|
||||
cilMap,
|
||||
cilMoon,
|
||||
cilNotes,
|
||||
cilOptions,
|
||||
cilPaperclip,
|
||||
cilPaperPlane,
|
||||
cilPencil,
|
||||
cilPeople,
|
||||
cilPhone,
|
||||
cilPrint,
|
||||
cilPuzzle,
|
||||
cilSave,
|
||||
cilScrubber,
|
||||
cilSettings,
|
||||
cilShare,
|
||||
cilShareAll,
|
||||
cilShareBoxed,
|
||||
cilShieldAlt,
|
||||
cilSpeech,
|
||||
cilSpeedometer,
|
||||
cilSpreadsheet,
|
||||
cilStar,
|
||||
cilSun,
|
||||
cilTags,
|
||||
cilTask,
|
||||
cilTrash,
|
||||
cilUnderline,
|
||||
cilUser,
|
||||
cilUserFemale,
|
||||
cilUserFollow,
|
||||
cilUserUnfollow,
|
||||
cilX,
|
||||
cilXCircle,
|
||||
cilWarning
|
||||
}, {
|
||||
cifUs,
|
||||
cifBr,
|
||||
cifIn,
|
||||
cifFr,
|
||||
cifEs,
|
||||
cifPl
|
||||
}, {
|
||||
cibSkype,
|
||||
cibFacebook,
|
||||
cibTwitter,
|
||||
cibLinkedin,
|
||||
cibFlickr,
|
||||
cibTumblr,
|
||||
cibXing,
|
||||
cibGithub,
|
||||
cibStackoverflow,
|
||||
cibYoutube,
|
||||
cibDribbble,
|
||||
cibInstagram,
|
||||
cibPinterest,
|
||||
cibVk,
|
||||
cibYahoo,
|
||||
cibBehance,
|
||||
cibReddit,
|
||||
cibVimeo,
|
||||
cibCcMastercard,
|
||||
cibCcVisa,
|
||||
cibStripe,
|
||||
cibPaypal,
|
||||
cibGooglePay,
|
||||
cibCcAmex,
|
||||
cilEyedropper
|
||||
})
|
||||
@ -1,30 +1,30 @@
|
||||
export const logoNegative = ['608 134', `
|
||||
<title>coreui react pro logo</title>
|
||||
<g>
|
||||
<g style="fill:#80d0ff;">
|
||||
<path d="M362.0177,90.1512,353.25,69.4149a.2507.2507,0,0,0-.2559-.1914H343.01a.2263.2263,0,0,0-.2559.2559V90.0233a.5657.5657,0,0,1-.64.64h-1.2163a.5652.5652,0,0,1-.64-.64V46.5028a.5655.5655,0,0,1,.64-.64H353.442a9.9792,9.9792,0,0,1,7.7437,3.2324A12.2,12.2,0,0,1,364.13,57.64a12.4389,12.4389,0,0,1-2.24,7.584,9.37,9.37,0,0,1-6.08,3.7441c-.1709.086-.2139.1915-.128.3194l8.7041,20.6084.064.2558q0,.5127-.5757.5118h-1.1523A.703.703,0,0,1,362.0177,90.1512ZM342.754,48.3593v18.496a.2259.2259,0,0,0,.2559.2559h10.3037a7.6713,7.6713,0,0,0,6.0166-2.5918,9.8807,9.8807,0,0,0,2.3037-6.8164,10.2875,10.2875,0,0,0-2.272-6.9756,7.6033,7.6033,0,0,0-6.0483-2.624H343.01A.2263.2263,0,0,0,342.754,48.3593Z"/>
|
||||
<path d="M401.3263,48.1034H381.2945a.2262.2262,0,0,0-.2558.2559v18.496a.2259.2259,0,0,0,.2558.2559h13.8238a.5664.5664,0,0,1,.6406.64v.96a.5663.5663,0,0,1-.6406.6406H381.2945a.2263.2263,0,0,0-.2558.2559v18.56a.2258.2258,0,0,0,.2558.2558h20.0318a.5671.5671,0,0,1,.6406.6407v.96a.566.566,0,0,1-.6406.64H379.1827a.5653.5653,0,0,1-.64-.64V46.5028a.5656.5656,0,0,1,.64-.64h22.1436a.5664.5664,0,0,1,.6406.64v.96A.5663.5663,0,0,1,401.3263,48.1034Z"/>
|
||||
<path d="M439.047,90.1512l-2.4317-8.832a.2971.2971,0,0,0-.32-.1924H419.5274a.2957.2957,0,0,0-.32.1924l-2.3681,8.7676a.6577.6577,0,0,1-.7036.5762H414.919a.5385.5385,0,0,1-.5756-.7041l12.0317-43.584a.6436.6436,0,0,1,.7041-.5117h1.6a.6442.6442,0,0,1,.7041.5117l12.16,43.584.0644.1923q0,.5127-.64.5118h-1.2163A.6428.6428,0,0,1,439.047,90.1512ZM419.9435,78.9188a.3031.3031,0,0,0,.2236.0967h15.4883a.3048.3048,0,0,0,.2236-.0967c.0645-.0635.0742-.1162.0322-.1592l-7.872-28.9287c-.043-.0849-.086-.1279-.128-.1279s-.0859.043-.1279.1279L419.9112,78.76C419.8683,78.8026,419.879,78.8553,419.9435,78.9188Z"/>
|
||||
<path d="M456.6017,87.911a11.6372,11.6372,0,0,1-3.3277-8.7041V57.1913a11.4158,11.4158,0,0,1,3.36-8.5762,12.0941,12.0941,0,0,1,8.8-3.2637,12.2566,12.2566,0,0,1,8.8643,3.2315,11.3927,11.3927,0,0,1,3.36,8.6084v.64a.5663.5663,0,0,1-.6406.6407l-1.28.0634q-.6408,0-.64-.5761v-.8321a9.289,9.289,0,0,0-2.6558-6.9121,10.6734,10.6734,0,0,0-14.0161,0,9.2854,9.2854,0,0,0-2.6563,6.9121V79.3993a9.2808,9.2808,0,0,0,2.6563,6.9121,10.67,10.67,0,0,0,14.0161,0,9.2843,9.2843,0,0,0,2.6558-6.9121v-.7686q0-.5757.64-.5752l1.28.0635a.5667.5667,0,0,1,.6406.6406v.5118a11.4952,11.4952,0,0,1-3.36,8.64,13.6227,13.6227,0,0,1-17.6963,0Z"/>
|
||||
<path d="M514.4376,46.5028v.96a.5658.5658,0,0,1-.64.6406H503.046a.2263.2263,0,0,0-.2559.2559v41.664a.566.566,0,0,1-.6406.64h-1.2158a.5652.5652,0,0,1-.64-.64V48.3593a.2266.2266,0,0,0-.2558-.2559H489.8619a.5656.5656,0,0,1-.64-.6406v-.96a.5656.5656,0,0,1,.64-.64H513.798A.5658.5658,0,0,1,514.4376,46.5028Z"/>
|
||||
<path d="M522.0665,89.5116a2.8385,2.8385,0,0,1-.8-2.0488,2.9194,2.9194,0,0,1,.8-2.1114,2.7544,2.7544,0,0,1,2.08-.832,2.8465,2.8465,0,0,1,2.9438,2.9434,2.7541,2.7541,0,0,1-.832,2.08,2.9221,2.9221,0,0,1-2.1118.8008A2.754,2.754,0,0,1,522.0665,89.5116Z"/>
|
||||
<path d="M542.4054,88.0077a11.3123,11.3123,0,0,1-3.2-8.416v-5.44a.5656.5656,0,0,1,.64-.64h1.2158a.5661.5661,0,0,1,.64.64v5.5039a9.1424,9.1424,0,0,0,2.5283,6.72,8.9745,8.9745,0,0,0,6.6875,2.5605,8.7908,8.7908,0,0,0,9.28-9.28V46.5028a.5655.5655,0,0,1,.64-.64h1.2163a.566.566,0,0,1,.64.64V79.5917a11.2545,11.2545,0,0,1-3.2325,8.416,13.0618,13.0618,0,0,1-17.0556,0Z"/>
|
||||
<path d="M580.35,88.1034a10.4859,10.4859,0,0,1-3.36-8.1279v-1.792a.5663.5663,0,0,1,.64-.6407h1.0884a.5668.5668,0,0,1,.64.6407v1.6a8.5459,8.5459,0,0,0,2.752,6.6562,10.5353,10.5353,0,0,0,7.36,2.4961,9.8719,9.8719,0,0,0,6.9761-2.3681,8.2161,8.2161,0,0,0,2.56-6.336,8.4,8.4,0,0,0-1.12-4.416,11.3812,11.3812,0,0,0-3.3281-3.3926,71.6714,71.6714,0,0,0-6.1763-3.7119,71.0479,71.0479,0,0,1-6.24-3.84,12.1711,12.1711,0,0,1-3.4238-3.68,10.2614,10.2614,0,0,1-1.28-5.3438,9.8579,9.8579,0,0,1,3.0718-7.7441,12.0122,12.0122,0,0,1,8.32-2.752q5.6954,0,8.96,3.1036a10.8251,10.8251,0,0,1,3.2642,8.2246v1.6a.5658.5658,0,0,1-.64.64h-1.1519a.5652.5652,0,0,1-.64-.64V56.8075a8.8647,8.8647,0,0,0-2.624-6.6885,9.9933,9.9933,0,0,0-7.232-2.5273,9.37,9.37,0,0,0-6.5278,2.1435,7.8224,7.8224,0,0,0-2.3682,6.1123,7.8006,7.8006,0,0,0,1.0244,4.16,10.387,10.387,0,0,0,3.0078,3.0391,62.8714,62.8714,0,0,0,5.9522,3.4882,71.0575,71.0575,0,0,1,6.72,4.2559,13.4674,13.4674,0,0,1,3.648,3.9365,10.049,10.049,0,0,1,1.28,5.1836,10.7177,10.7177,0,0,1-3.2637,8.1924q-3.2637,3.0717-8.832,3.0723Q583.71,91.1757,580.35,88.1034Z"/>
|
||||
</g>
|
||||
|
||||
<g style="fill:#fff;">
|
||||
<g>
|
||||
<path d="M99.835,36.0577l-39-22.5167a12,12,0,0,0-12,0l-39,22.5166a12.0339,12.0339,0,0,0-6,10.3924V91.4833a12.0333,12.0333,0,0,0,6,10.3923l39,22.5167a12,12,0,0,0,12,0l39-22.5167a12.0331,12.0331,0,0,0,6-10.3923V46.45A12.0334,12.0334,0,0,0,99.835,36.0577Zm-2,55.4256a4,4,0,0,1-2,3.4641l-39,22.5167a4.0006,4.0006,0,0,1-4,0l-39-22.5167a4,4,0,0,1-2-3.4641V46.45a4,4,0,0,1,2-3.4642l39-22.5166a4,4,0,0,1,4,0l39,22.5166a4,4,0,0,1,2,3.4642Z"/>
|
||||
<path d="M77.8567,82.0046h-2.866a4,4,0,0,0-1.9247.4934L55.7852,91.9833,35.835,80.4648V57.4872l19.95-11.5185,17.2893,9.4549a3.9993,3.9993,0,0,0,1.9192.4906h2.8632a2,2,0,0,0,2-2V51.2024a2,2,0,0,0-1.04-1.7547L59.628,38.9521a8.0391,8.0391,0,0,0-7.8428.09L31.8346,50.56a8.0246,8.0246,0,0,0-4,6.9287v22.976a8,8,0,0,0,4,6.9283l19.95,11.5186a8.0429,8.0429,0,0,0,7.8433.0879l19.19-10.5312a2,2,0,0,0,1.0378-1.7533v-2.71A2,2,0,0,0,77.8567,82.0046Z"/>
|
||||
</g>
|
||||
<g>
|
||||
<path d="M172.58,45.3618a15.0166,15.0166,0,0,0-15,14.9995V77.6387a15,15,0,0,0,30,0V60.3613A15.0166,15.0166,0,0,0,172.58,45.3618Zm7,32.2769a7,7,0,0,1-14,0V60.3613a7,7,0,0,1,14,0Z"/>
|
||||
<path d="M135.9138,53.4211a7.01,7.01,0,0,1,7.8681,6.0752.9894.9894,0,0,0,.9843.865h6.03a1.0108,1.0108,0,0,0,.9987-1.0971,15.0182,15.0182,0,0,0-15.7162-13.8837,15.2881,15.2881,0,0,0-14.2441,15.4163V77.2037A15.288,15.288,0,0,0,136.0792,92.62a15.0183,15.0183,0,0,0,15.7162-13.8842,1.0107,1.0107,0,0,0-.9987-1.0971h-6.03a.9894.9894,0,0,0-.9843.865,7.01,7.01,0,0,1-7.8679,6.0757,7.1642,7.1642,0,0,1-6.0789-7.1849V60.6057A7.1638,7.1638,0,0,1,135.9138,53.4211Z"/>
|
||||
<path d="M218.7572,72.9277a12.1585,12.1585,0,0,0,7.1843-11.0771V58.1494A12.1494,12.1494,0,0,0,213.7921,46H196.835a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h6a1,1,0,0,0,1-1V74h6.6216l7.9154,17.4138a1,1,0,0,0,.91.5862h6.5911a1,1,0,0,0,.91-1.4138Zm-.8157-11.0771A4.1538,4.1538,0,0,1,213.7926,66h-9.8511V54h9.8511a4.1538,4.1538,0,0,1,4.1489,4.1494Z"/>
|
||||
<path d="M260.835,46h-26a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h26a1,1,0,0,0,1-1V85a1,1,0,0,0-1-1h-19V72h13a1,1,0,0,0,1-1V65a1,1,0,0,0-1-1h-13V54h19a1,1,0,0,0,1-1V47A1,1,0,0,0,260.835,46Z"/>
|
||||
<path d="M298.835,46h-6a1,1,0,0,0-1,1V69.6475a7.0066,7.0066,0,1,1-14,0V47a1,1,0,0,0-1-1h-6a1,1,0,0,0-1,1V69.6475a15.0031,15.0031,0,1,0,30,0V47A1,1,0,0,0,298.835,46Z"/>
|
||||
<rect x="307.835" y="46" width="8" height="38" rx="1"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
export const logoNegative = ['608 134', `
|
||||
<title>coreui react pro logo</title>
|
||||
<g>
|
||||
<g style="fill:#80d0ff;">
|
||||
<path d="M362.0177,90.1512,353.25,69.4149a.2507.2507,0,0,0-.2559-.1914H343.01a.2263.2263,0,0,0-.2559.2559V90.0233a.5657.5657,0,0,1-.64.64h-1.2163a.5652.5652,0,0,1-.64-.64V46.5028a.5655.5655,0,0,1,.64-.64H353.442a9.9792,9.9792,0,0,1,7.7437,3.2324A12.2,12.2,0,0,1,364.13,57.64a12.4389,12.4389,0,0,1-2.24,7.584,9.37,9.37,0,0,1-6.08,3.7441c-.1709.086-.2139.1915-.128.3194l8.7041,20.6084.064.2558q0,.5127-.5757.5118h-1.1523A.703.703,0,0,1,362.0177,90.1512ZM342.754,48.3593v18.496a.2259.2259,0,0,0,.2559.2559h10.3037a7.6713,7.6713,0,0,0,6.0166-2.5918,9.8807,9.8807,0,0,0,2.3037-6.8164,10.2875,10.2875,0,0,0-2.272-6.9756,7.6033,7.6033,0,0,0-6.0483-2.624H343.01A.2263.2263,0,0,0,342.754,48.3593Z"/>
|
||||
<path d="M401.3263,48.1034H381.2945a.2262.2262,0,0,0-.2558.2559v18.496a.2259.2259,0,0,0,.2558.2559h13.8238a.5664.5664,0,0,1,.6406.64v.96a.5663.5663,0,0,1-.6406.6406H381.2945a.2263.2263,0,0,0-.2558.2559v18.56a.2258.2258,0,0,0,.2558.2558h20.0318a.5671.5671,0,0,1,.6406.6407v.96a.566.566,0,0,1-.6406.64H379.1827a.5653.5653,0,0,1-.64-.64V46.5028a.5656.5656,0,0,1,.64-.64h22.1436a.5664.5664,0,0,1,.6406.64v.96A.5663.5663,0,0,1,401.3263,48.1034Z"/>
|
||||
<path d="M439.047,90.1512l-2.4317-8.832a.2971.2971,0,0,0-.32-.1924H419.5274a.2957.2957,0,0,0-.32.1924l-2.3681,8.7676a.6577.6577,0,0,1-.7036.5762H414.919a.5385.5385,0,0,1-.5756-.7041l12.0317-43.584a.6436.6436,0,0,1,.7041-.5117h1.6a.6442.6442,0,0,1,.7041.5117l12.16,43.584.0644.1923q0,.5127-.64.5118h-1.2163A.6428.6428,0,0,1,439.047,90.1512ZM419.9435,78.9188a.3031.3031,0,0,0,.2236.0967h15.4883a.3048.3048,0,0,0,.2236-.0967c.0645-.0635.0742-.1162.0322-.1592l-7.872-28.9287c-.043-.0849-.086-.1279-.128-.1279s-.0859.043-.1279.1279L419.9112,78.76C419.8683,78.8026,419.879,78.8553,419.9435,78.9188Z"/>
|
||||
<path d="M456.6017,87.911a11.6372,11.6372,0,0,1-3.3277-8.7041V57.1913a11.4158,11.4158,0,0,1,3.36-8.5762,12.0941,12.0941,0,0,1,8.8-3.2637,12.2566,12.2566,0,0,1,8.8643,3.2315,11.3927,11.3927,0,0,1,3.36,8.6084v.64a.5663.5663,0,0,1-.6406.6407l-1.28.0634q-.6408,0-.64-.5761v-.8321a9.289,9.289,0,0,0-2.6558-6.9121,10.6734,10.6734,0,0,0-14.0161,0,9.2854,9.2854,0,0,0-2.6563,6.9121V79.3993a9.2808,9.2808,0,0,0,2.6563,6.9121,10.67,10.67,0,0,0,14.0161,0,9.2843,9.2843,0,0,0,2.6558-6.9121v-.7686q0-.5757.64-.5752l1.28.0635a.5667.5667,0,0,1,.6406.6406v.5118a11.4952,11.4952,0,0,1-3.36,8.64,13.6227,13.6227,0,0,1-17.6963,0Z"/>
|
||||
<path d="M514.4376,46.5028v.96a.5658.5658,0,0,1-.64.6406H503.046a.2263.2263,0,0,0-.2559.2559v41.664a.566.566,0,0,1-.6406.64h-1.2158a.5652.5652,0,0,1-.64-.64V48.3593a.2266.2266,0,0,0-.2558-.2559H489.8619a.5656.5656,0,0,1-.64-.6406v-.96a.5656.5656,0,0,1,.64-.64H513.798A.5658.5658,0,0,1,514.4376,46.5028Z"/>
|
||||
<path d="M522.0665,89.5116a2.8385,2.8385,0,0,1-.8-2.0488,2.9194,2.9194,0,0,1,.8-2.1114,2.7544,2.7544,0,0,1,2.08-.832,2.8465,2.8465,0,0,1,2.9438,2.9434,2.7541,2.7541,0,0,1-.832,2.08,2.9221,2.9221,0,0,1-2.1118.8008A2.754,2.754,0,0,1,522.0665,89.5116Z"/>
|
||||
<path d="M542.4054,88.0077a11.3123,11.3123,0,0,1-3.2-8.416v-5.44a.5656.5656,0,0,1,.64-.64h1.2158a.5661.5661,0,0,1,.64.64v5.5039a9.1424,9.1424,0,0,0,2.5283,6.72,8.9745,8.9745,0,0,0,6.6875,2.5605,8.7908,8.7908,0,0,0,9.28-9.28V46.5028a.5655.5655,0,0,1,.64-.64h1.2163a.566.566,0,0,1,.64.64V79.5917a11.2545,11.2545,0,0,1-3.2325,8.416,13.0618,13.0618,0,0,1-17.0556,0Z"/>
|
||||
<path d="M580.35,88.1034a10.4859,10.4859,0,0,1-3.36-8.1279v-1.792a.5663.5663,0,0,1,.64-.6407h1.0884a.5668.5668,0,0,1,.64.6407v1.6a8.5459,8.5459,0,0,0,2.752,6.6562,10.5353,10.5353,0,0,0,7.36,2.4961,9.8719,9.8719,0,0,0,6.9761-2.3681,8.2161,8.2161,0,0,0,2.56-6.336,8.4,8.4,0,0,0-1.12-4.416,11.3812,11.3812,0,0,0-3.3281-3.3926,71.6714,71.6714,0,0,0-6.1763-3.7119,71.0479,71.0479,0,0,1-6.24-3.84,12.1711,12.1711,0,0,1-3.4238-3.68,10.2614,10.2614,0,0,1-1.28-5.3438,9.8579,9.8579,0,0,1,3.0718-7.7441,12.0122,12.0122,0,0,1,8.32-2.752q5.6954,0,8.96,3.1036a10.8251,10.8251,0,0,1,3.2642,8.2246v1.6a.5658.5658,0,0,1-.64.64h-1.1519a.5652.5652,0,0,1-.64-.64V56.8075a8.8647,8.8647,0,0,0-2.624-6.6885,9.9933,9.9933,0,0,0-7.232-2.5273,9.37,9.37,0,0,0-6.5278,2.1435,7.8224,7.8224,0,0,0-2.3682,6.1123,7.8006,7.8006,0,0,0,1.0244,4.16,10.387,10.387,0,0,0,3.0078,3.0391,62.8714,62.8714,0,0,0,5.9522,3.4882,71.0575,71.0575,0,0,1,6.72,4.2559,13.4674,13.4674,0,0,1,3.648,3.9365,10.049,10.049,0,0,1,1.28,5.1836,10.7177,10.7177,0,0,1-3.2637,8.1924q-3.2637,3.0717-8.832,3.0723Q583.71,91.1757,580.35,88.1034Z"/>
|
||||
</g>
|
||||
|
||||
<g style="fill:#fff;">
|
||||
<g>
|
||||
<path d="M99.835,36.0577l-39-22.5167a12,12,0,0,0-12,0l-39,22.5166a12.0339,12.0339,0,0,0-6,10.3924V91.4833a12.0333,12.0333,0,0,0,6,10.3923l39,22.5167a12,12,0,0,0,12,0l39-22.5167a12.0331,12.0331,0,0,0,6-10.3923V46.45A12.0334,12.0334,0,0,0,99.835,36.0577Zm-2,55.4256a4,4,0,0,1-2,3.4641l-39,22.5167a4.0006,4.0006,0,0,1-4,0l-39-22.5167a4,4,0,0,1-2-3.4641V46.45a4,4,0,0,1,2-3.4642l39-22.5166a4,4,0,0,1,4,0l39,22.5166a4,4,0,0,1,2,3.4642Z"/>
|
||||
<path d="M77.8567,82.0046h-2.866a4,4,0,0,0-1.9247.4934L55.7852,91.9833,35.835,80.4648V57.4872l19.95-11.5185,17.2893,9.4549a3.9993,3.9993,0,0,0,1.9192.4906h2.8632a2,2,0,0,0,2-2V51.2024a2,2,0,0,0-1.04-1.7547L59.628,38.9521a8.0391,8.0391,0,0,0-7.8428.09L31.8346,50.56a8.0246,8.0246,0,0,0-4,6.9287v22.976a8,8,0,0,0,4,6.9283l19.95,11.5186a8.0429,8.0429,0,0,0,7.8433.0879l19.19-10.5312a2,2,0,0,0,1.0378-1.7533v-2.71A2,2,0,0,0,77.8567,82.0046Z"/>
|
||||
</g>
|
||||
<g>
|
||||
<path d="M172.58,45.3618a15.0166,15.0166,0,0,0-15,14.9995V77.6387a15,15,0,0,0,30,0V60.3613A15.0166,15.0166,0,0,0,172.58,45.3618Zm7,32.2769a7,7,0,0,1-14,0V60.3613a7,7,0,0,1,14,0Z"/>
|
||||
<path d="M135.9138,53.4211a7.01,7.01,0,0,1,7.8681,6.0752.9894.9894,0,0,0,.9843.865h6.03a1.0108,1.0108,0,0,0,.9987-1.0971,15.0182,15.0182,0,0,0-15.7162-13.8837,15.2881,15.2881,0,0,0-14.2441,15.4163V77.2037A15.288,15.288,0,0,0,136.0792,92.62a15.0183,15.0183,0,0,0,15.7162-13.8842,1.0107,1.0107,0,0,0-.9987-1.0971h-6.03a.9894.9894,0,0,0-.9843.865,7.01,7.01,0,0,1-7.8679,6.0757,7.1642,7.1642,0,0,1-6.0789-7.1849V60.6057A7.1638,7.1638,0,0,1,135.9138,53.4211Z"/>
|
||||
<path d="M218.7572,72.9277a12.1585,12.1585,0,0,0,7.1843-11.0771V58.1494A12.1494,12.1494,0,0,0,213.7921,46H196.835a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h6a1,1,0,0,0,1-1V74h6.6216l7.9154,17.4138a1,1,0,0,0,.91.5862h6.5911a1,1,0,0,0,.91-1.4138Zm-.8157-11.0771A4.1538,4.1538,0,0,1,213.7926,66h-9.8511V54h9.8511a4.1538,4.1538,0,0,1,4.1489,4.1494Z"/>
|
||||
<path d="M260.835,46h-26a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h26a1,1,0,0,0,1-1V85a1,1,0,0,0-1-1h-19V72h13a1,1,0,0,0,1-1V65a1,1,0,0,0-1-1h-13V54h19a1,1,0,0,0,1-1V47A1,1,0,0,0,260.835,46Z"/>
|
||||
<path d="M298.835,46h-6a1,1,0,0,0-1,1V69.6475a7.0066,7.0066,0,1,1-14,0V47a1,1,0,0,0-1-1h-6a1,1,0,0,0-1,1V69.6475a15.0031,15.0031,0,1,0,30,0V47A1,1,0,0,0,298.835,46Z"/>
|
||||
<rect x="307.835" y="46" width="8" height="38" rx="1"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
|
||||
@ -1,29 +1,29 @@
|
||||
export const logo = ['608 134', `
|
||||
<title>coreui react pro</title>
|
||||
<g>
|
||||
<g style="fill:#00a1ff">
|
||||
<path d="M362.0177,90.1512,353.25,69.4149a.2507.2507,0,0,0-.2559-.1914H343.01a.2263.2263,0,0,0-.2559.2559V90.0233a.5657.5657,0,0,1-.64.64h-1.2163a.5652.5652,0,0,1-.64-.64V46.5028a.5655.5655,0,0,1,.64-.64H353.442a9.9792,9.9792,0,0,1,7.7437,3.2324A12.2,12.2,0,0,1,364.13,57.64a12.4389,12.4389,0,0,1-2.24,7.584,9.37,9.37,0,0,1-6.08,3.7441c-.1709.086-.2139.1915-.128.3194l8.7041,20.6084.064.2558q0,.5127-.5757.5118h-1.1523A.703.703,0,0,1,362.0177,90.1512ZM342.754,48.3593v18.496a.2259.2259,0,0,0,.2559.2559h10.3037a7.6713,7.6713,0,0,0,6.0166-2.5918,9.8807,9.8807,0,0,0,2.3037-6.8164,10.2875,10.2875,0,0,0-2.272-6.9756,7.6033,7.6033,0,0,0-6.0483-2.624H343.01A.2263.2263,0,0,0,342.754,48.3593Z"/>
|
||||
<path d="M401.3263,48.1034H381.2945a.2262.2262,0,0,0-.2558.2559v18.496a.2259.2259,0,0,0,.2558.2559h13.8238a.5664.5664,0,0,1,.6406.64v.96a.5663.5663,0,0,1-.6406.6406H381.2945a.2263.2263,0,0,0-.2558.2559v18.56a.2258.2258,0,0,0,.2558.2558h20.0318a.5671.5671,0,0,1,.6406.6407v.96a.566.566,0,0,1-.6406.64H379.1827a.5653.5653,0,0,1-.64-.64V46.5028a.5656.5656,0,0,1,.64-.64h22.1436a.5664.5664,0,0,1,.6406.64v.96A.5663.5663,0,0,1,401.3263,48.1034Z"/>
|
||||
<path d="M439.047,90.1512l-2.4317-8.832a.2971.2971,0,0,0-.32-.1924H419.5274a.2957.2957,0,0,0-.32.1924l-2.3681,8.7676a.6577.6577,0,0,1-.7036.5762H414.919a.5385.5385,0,0,1-.5756-.7041l12.0317-43.584a.6436.6436,0,0,1,.7041-.5117h1.6a.6442.6442,0,0,1,.7041.5117l12.16,43.584.0644.1923q0,.5127-.64.5118h-1.2163A.6428.6428,0,0,1,439.047,90.1512ZM419.9435,78.9188a.3031.3031,0,0,0,.2236.0967h15.4883a.3048.3048,0,0,0,.2236-.0967c.0645-.0635.0742-.1162.0322-.1592l-7.872-28.9287c-.043-.0849-.086-.1279-.128-.1279s-.0859.043-.1279.1279L419.9112,78.76C419.8683,78.8026,419.879,78.8553,419.9435,78.9188Z"/>
|
||||
<path d="M456.6017,87.911a11.6372,11.6372,0,0,1-3.3277-8.7041V57.1913a11.4158,11.4158,0,0,1,3.36-8.5762,12.0941,12.0941,0,0,1,8.8-3.2637,12.2566,12.2566,0,0,1,8.8643,3.2315,11.3927,11.3927,0,0,1,3.36,8.6084v.64a.5663.5663,0,0,1-.6406.6407l-1.28.0634q-.6408,0-.64-.5761v-.8321a9.289,9.289,0,0,0-2.6558-6.9121,10.6734,10.6734,0,0,0-14.0161,0,9.2854,9.2854,0,0,0-2.6563,6.9121V79.3993a9.2808,9.2808,0,0,0,2.6563,6.9121,10.67,10.67,0,0,0,14.0161,0,9.2843,9.2843,0,0,0,2.6558-6.9121v-.7686q0-.5757.64-.5752l1.28.0635a.5667.5667,0,0,1,.6406.6406v.5118a11.4952,11.4952,0,0,1-3.36,8.64,13.6227,13.6227,0,0,1-17.6963,0Z"/>
|
||||
<path d="M514.4376,46.5028v.96a.5658.5658,0,0,1-.64.6406H503.046a.2263.2263,0,0,0-.2559.2559v41.664a.566.566,0,0,1-.6406.64h-1.2158a.5652.5652,0,0,1-.64-.64V48.3593a.2266.2266,0,0,0-.2558-.2559H489.8619a.5656.5656,0,0,1-.64-.6406v-.96a.5656.5656,0,0,1,.64-.64H513.798A.5658.5658,0,0,1,514.4376,46.5028Z"/>
|
||||
<path d="M522.0665,89.5116a2.8385,2.8385,0,0,1-.8-2.0488,2.9194,2.9194,0,0,1,.8-2.1114,2.7544,2.7544,0,0,1,2.08-.832,2.8465,2.8465,0,0,1,2.9438,2.9434,2.7541,2.7541,0,0,1-.832,2.08,2.9221,2.9221,0,0,1-2.1118.8008A2.754,2.754,0,0,1,522.0665,89.5116Z"/>
|
||||
<path d="M542.4054,88.0077a11.3123,11.3123,0,0,1-3.2-8.416v-5.44a.5656.5656,0,0,1,.64-.64h1.2158a.5661.5661,0,0,1,.64.64v5.5039a9.1424,9.1424,0,0,0,2.5283,6.72,8.9745,8.9745,0,0,0,6.6875,2.5605,8.7908,8.7908,0,0,0,9.28-9.28V46.5028a.5655.5655,0,0,1,.64-.64h1.2163a.566.566,0,0,1,.64.64V79.5917a11.2545,11.2545,0,0,1-3.2325,8.416,13.0618,13.0618,0,0,1-17.0556,0Z"/>
|
||||
<path d="M580.35,88.1034a10.4859,10.4859,0,0,1-3.36-8.1279v-1.792a.5663.5663,0,0,1,.64-.6407h1.0884a.5668.5668,0,0,1,.64.6407v1.6a8.5459,8.5459,0,0,0,2.752,6.6562,10.5353,10.5353,0,0,0,7.36,2.4961,9.8719,9.8719,0,0,0,6.9761-2.3681,8.2161,8.2161,0,0,0,2.56-6.336,8.4,8.4,0,0,0-1.12-4.416,11.3812,11.3812,0,0,0-3.3281-3.3926,71.6714,71.6714,0,0,0-6.1763-3.7119,71.0479,71.0479,0,0,1-6.24-3.84,12.1711,12.1711,0,0,1-3.4238-3.68,10.2614,10.2614,0,0,1-1.28-5.3438,9.8579,9.8579,0,0,1,3.0718-7.7441,12.0122,12.0122,0,0,1,8.32-2.752q5.6954,0,8.96,3.1036a10.8251,10.8251,0,0,1,3.2642,8.2246v1.6a.5658.5658,0,0,1-.64.64h-1.1519a.5652.5652,0,0,1-.64-.64V56.8075a8.8647,8.8647,0,0,0-2.624-6.6885,9.9933,9.9933,0,0,0-7.232-2.5273,9.37,9.37,0,0,0-6.5278,2.1435,7.8224,7.8224,0,0,0-2.3682,6.1123,7.8006,7.8006,0,0,0,1.0244,4.16,10.387,10.387,0,0,0,3.0078,3.0391,62.8714,62.8714,0,0,0,5.9522,3.4882,71.0575,71.0575,0,0,1,6.72,4.2559,13.4674,13.4674,0,0,1,3.648,3.9365,10.049,10.049,0,0,1,1.28,5.1836,10.7177,10.7177,0,0,1-3.2637,8.1924q-3.2637,3.0717-8.832,3.0723Q583.71,91.1757,580.35,88.1034Z"/>
|
||||
</g>
|
||||
<g style="fill:#3c4b64">
|
||||
<g>
|
||||
<path d="M99.835,36.0577l-39-22.5167a12,12,0,0,0-12,0l-39,22.5166a12.0339,12.0339,0,0,0-6,10.3924V91.4833a12.0333,12.0333,0,0,0,6,10.3923l39,22.5167a12,12,0,0,0,12,0l39-22.5167a12.0331,12.0331,0,0,0,6-10.3923V46.45A12.0334,12.0334,0,0,0,99.835,36.0577Zm-2,55.4256a4,4,0,0,1-2,3.4641l-39,22.5167a4.0006,4.0006,0,0,1-4,0l-39-22.5167a4,4,0,0,1-2-3.4641V46.45a4,4,0,0,1,2-3.4642l39-22.5166a4,4,0,0,1,4,0l39,22.5166a4,4,0,0,1,2,3.4642Z"/>
|
||||
<path d="M77.8567,82.0046h-2.866a4,4,0,0,0-1.9247.4934L55.7852,91.9833,35.835,80.4648V57.4872l19.95-11.5185,17.2893,9.4549a3.9993,3.9993,0,0,0,1.9192.4906h2.8632a2,2,0,0,0,2-2V51.2024a2,2,0,0,0-1.04-1.7547L59.628,38.9521a8.0391,8.0391,0,0,0-7.8428.09L31.8346,50.56a8.0246,8.0246,0,0,0-4,6.9287v22.976a8,8,0,0,0,4,6.9283l19.95,11.5186a8.0429,8.0429,0,0,0,7.8433.0879l19.19-10.5312a2,2,0,0,0,1.0378-1.7533v-2.71A2,2,0,0,0,77.8567,82.0046Z"/>
|
||||
</g>
|
||||
<g>
|
||||
<path d="M172.58,45.3618a15.0166,15.0166,0,0,0-15,14.9995V77.6387a15,15,0,0,0,30,0V60.3613A15.0166,15.0166,0,0,0,172.58,45.3618Zm7,32.2769a7,7,0,0,1-14,0V60.3613a7,7,0,0,1,14,0Z"/>
|
||||
<path d="M135.9138,53.4211a7.01,7.01,0,0,1,7.8681,6.0752.9894.9894,0,0,0,.9843.865h6.03a1.0108,1.0108,0,0,0,.9987-1.0971,15.0182,15.0182,0,0,0-15.7162-13.8837,15.2881,15.2881,0,0,0-14.2441,15.4163V77.2037A15.288,15.288,0,0,0,136.0792,92.62a15.0183,15.0183,0,0,0,15.7162-13.8842,1.0107,1.0107,0,0,0-.9987-1.0971h-6.03a.9894.9894,0,0,0-.9843.865,7.01,7.01,0,0,1-7.8679,6.0757,7.1642,7.1642,0,0,1-6.0789-7.1849V60.6057A7.1638,7.1638,0,0,1,135.9138,53.4211Z"/>
|
||||
<path d="M218.7572,72.9277a12.1585,12.1585,0,0,0,7.1843-11.0771V58.1494A12.1494,12.1494,0,0,0,213.7921,46H196.835a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h6a1,1,0,0,0,1-1V74h6.6216l7.9154,17.4138a1,1,0,0,0,.91.5862h6.5911a1,1,0,0,0,.91-1.4138Zm-.8157-11.0771A4.1538,4.1538,0,0,1,213.7926,66h-9.8511V54h9.8511a4.1538,4.1538,0,0,1,4.1489,4.1494Z"/>
|
||||
<path d="M260.835,46h-26a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h26a1,1,0,0,0,1-1V85a1,1,0,0,0-1-1h-19V72h13a1,1,0,0,0,1-1V65a1,1,0,0,0-1-1h-13V54h19a1,1,0,0,0,1-1V47A1,1,0,0,0,260.835,46Z"/>
|
||||
<path d="M298.835,46h-6a1,1,0,0,0-1,1V69.6475a7.0066,7.0066,0,1,1-14,0V47a1,1,0,0,0-1-1h-6a1,1,0,0,0-1,1V69.6475a15.0031,15.0031,0,1,0,30,0V47A1,1,0,0,0,298.835,46Z"/>
|
||||
<rect x="307.835" y="46" width="8" height="38" rx="1"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
export const logo = ['608 134', `
|
||||
<title>coreui react pro</title>
|
||||
<g>
|
||||
<g style="fill:#00a1ff">
|
||||
<path d="M362.0177,90.1512,353.25,69.4149a.2507.2507,0,0,0-.2559-.1914H343.01a.2263.2263,0,0,0-.2559.2559V90.0233a.5657.5657,0,0,1-.64.64h-1.2163a.5652.5652,0,0,1-.64-.64V46.5028a.5655.5655,0,0,1,.64-.64H353.442a9.9792,9.9792,0,0,1,7.7437,3.2324A12.2,12.2,0,0,1,364.13,57.64a12.4389,12.4389,0,0,1-2.24,7.584,9.37,9.37,0,0,1-6.08,3.7441c-.1709.086-.2139.1915-.128.3194l8.7041,20.6084.064.2558q0,.5127-.5757.5118h-1.1523A.703.703,0,0,1,362.0177,90.1512ZM342.754,48.3593v18.496a.2259.2259,0,0,0,.2559.2559h10.3037a7.6713,7.6713,0,0,0,6.0166-2.5918,9.8807,9.8807,0,0,0,2.3037-6.8164,10.2875,10.2875,0,0,0-2.272-6.9756,7.6033,7.6033,0,0,0-6.0483-2.624H343.01A.2263.2263,0,0,0,342.754,48.3593Z"/>
|
||||
<path d="M401.3263,48.1034H381.2945a.2262.2262,0,0,0-.2558.2559v18.496a.2259.2259,0,0,0,.2558.2559h13.8238a.5664.5664,0,0,1,.6406.64v.96a.5663.5663,0,0,1-.6406.6406H381.2945a.2263.2263,0,0,0-.2558.2559v18.56a.2258.2258,0,0,0,.2558.2558h20.0318a.5671.5671,0,0,1,.6406.6407v.96a.566.566,0,0,1-.6406.64H379.1827a.5653.5653,0,0,1-.64-.64V46.5028a.5656.5656,0,0,1,.64-.64h22.1436a.5664.5664,0,0,1,.6406.64v.96A.5663.5663,0,0,1,401.3263,48.1034Z"/>
|
||||
<path d="M439.047,90.1512l-2.4317-8.832a.2971.2971,0,0,0-.32-.1924H419.5274a.2957.2957,0,0,0-.32.1924l-2.3681,8.7676a.6577.6577,0,0,1-.7036.5762H414.919a.5385.5385,0,0,1-.5756-.7041l12.0317-43.584a.6436.6436,0,0,1,.7041-.5117h1.6a.6442.6442,0,0,1,.7041.5117l12.16,43.584.0644.1923q0,.5127-.64.5118h-1.2163A.6428.6428,0,0,1,439.047,90.1512ZM419.9435,78.9188a.3031.3031,0,0,0,.2236.0967h15.4883a.3048.3048,0,0,0,.2236-.0967c.0645-.0635.0742-.1162.0322-.1592l-7.872-28.9287c-.043-.0849-.086-.1279-.128-.1279s-.0859.043-.1279.1279L419.9112,78.76C419.8683,78.8026,419.879,78.8553,419.9435,78.9188Z"/>
|
||||
<path d="M456.6017,87.911a11.6372,11.6372,0,0,1-3.3277-8.7041V57.1913a11.4158,11.4158,0,0,1,3.36-8.5762,12.0941,12.0941,0,0,1,8.8-3.2637,12.2566,12.2566,0,0,1,8.8643,3.2315,11.3927,11.3927,0,0,1,3.36,8.6084v.64a.5663.5663,0,0,1-.6406.6407l-1.28.0634q-.6408,0-.64-.5761v-.8321a9.289,9.289,0,0,0-2.6558-6.9121,10.6734,10.6734,0,0,0-14.0161,0,9.2854,9.2854,0,0,0-2.6563,6.9121V79.3993a9.2808,9.2808,0,0,0,2.6563,6.9121,10.67,10.67,0,0,0,14.0161,0,9.2843,9.2843,0,0,0,2.6558-6.9121v-.7686q0-.5757.64-.5752l1.28.0635a.5667.5667,0,0,1,.6406.6406v.5118a11.4952,11.4952,0,0,1-3.36,8.64,13.6227,13.6227,0,0,1-17.6963,0Z"/>
|
||||
<path d="M514.4376,46.5028v.96a.5658.5658,0,0,1-.64.6406H503.046a.2263.2263,0,0,0-.2559.2559v41.664a.566.566,0,0,1-.6406.64h-1.2158a.5652.5652,0,0,1-.64-.64V48.3593a.2266.2266,0,0,0-.2558-.2559H489.8619a.5656.5656,0,0,1-.64-.6406v-.96a.5656.5656,0,0,1,.64-.64H513.798A.5658.5658,0,0,1,514.4376,46.5028Z"/>
|
||||
<path d="M522.0665,89.5116a2.8385,2.8385,0,0,1-.8-2.0488,2.9194,2.9194,0,0,1,.8-2.1114,2.7544,2.7544,0,0,1,2.08-.832,2.8465,2.8465,0,0,1,2.9438,2.9434,2.7541,2.7541,0,0,1-.832,2.08,2.9221,2.9221,0,0,1-2.1118.8008A2.754,2.754,0,0,1,522.0665,89.5116Z"/>
|
||||
<path d="M542.4054,88.0077a11.3123,11.3123,0,0,1-3.2-8.416v-5.44a.5656.5656,0,0,1,.64-.64h1.2158a.5661.5661,0,0,1,.64.64v5.5039a9.1424,9.1424,0,0,0,2.5283,6.72,8.9745,8.9745,0,0,0,6.6875,2.5605,8.7908,8.7908,0,0,0,9.28-9.28V46.5028a.5655.5655,0,0,1,.64-.64h1.2163a.566.566,0,0,1,.64.64V79.5917a11.2545,11.2545,0,0,1-3.2325,8.416,13.0618,13.0618,0,0,1-17.0556,0Z"/>
|
||||
<path d="M580.35,88.1034a10.4859,10.4859,0,0,1-3.36-8.1279v-1.792a.5663.5663,0,0,1,.64-.6407h1.0884a.5668.5668,0,0,1,.64.6407v1.6a8.5459,8.5459,0,0,0,2.752,6.6562,10.5353,10.5353,0,0,0,7.36,2.4961,9.8719,9.8719,0,0,0,6.9761-2.3681,8.2161,8.2161,0,0,0,2.56-6.336,8.4,8.4,0,0,0-1.12-4.416,11.3812,11.3812,0,0,0-3.3281-3.3926,71.6714,71.6714,0,0,0-6.1763-3.7119,71.0479,71.0479,0,0,1-6.24-3.84,12.1711,12.1711,0,0,1-3.4238-3.68,10.2614,10.2614,0,0,1-1.28-5.3438,9.8579,9.8579,0,0,1,3.0718-7.7441,12.0122,12.0122,0,0,1,8.32-2.752q5.6954,0,8.96,3.1036a10.8251,10.8251,0,0,1,3.2642,8.2246v1.6a.5658.5658,0,0,1-.64.64h-1.1519a.5652.5652,0,0,1-.64-.64V56.8075a8.8647,8.8647,0,0,0-2.624-6.6885,9.9933,9.9933,0,0,0-7.232-2.5273,9.37,9.37,0,0,0-6.5278,2.1435,7.8224,7.8224,0,0,0-2.3682,6.1123,7.8006,7.8006,0,0,0,1.0244,4.16,10.387,10.387,0,0,0,3.0078,3.0391,62.8714,62.8714,0,0,0,5.9522,3.4882,71.0575,71.0575,0,0,1,6.72,4.2559,13.4674,13.4674,0,0,1,3.648,3.9365,10.049,10.049,0,0,1,1.28,5.1836,10.7177,10.7177,0,0,1-3.2637,8.1924q-3.2637,3.0717-8.832,3.0723Q583.71,91.1757,580.35,88.1034Z"/>
|
||||
</g>
|
||||
<g style="fill:#3c4b64">
|
||||
<g>
|
||||
<path d="M99.835,36.0577l-39-22.5167a12,12,0,0,0-12,0l-39,22.5166a12.0339,12.0339,0,0,0-6,10.3924V91.4833a12.0333,12.0333,0,0,0,6,10.3923l39,22.5167a12,12,0,0,0,12,0l39-22.5167a12.0331,12.0331,0,0,0,6-10.3923V46.45A12.0334,12.0334,0,0,0,99.835,36.0577Zm-2,55.4256a4,4,0,0,1-2,3.4641l-39,22.5167a4.0006,4.0006,0,0,1-4,0l-39-22.5167a4,4,0,0,1-2-3.4641V46.45a4,4,0,0,1,2-3.4642l39-22.5166a4,4,0,0,1,4,0l39,22.5166a4,4,0,0,1,2,3.4642Z"/>
|
||||
<path d="M77.8567,82.0046h-2.866a4,4,0,0,0-1.9247.4934L55.7852,91.9833,35.835,80.4648V57.4872l19.95-11.5185,17.2893,9.4549a3.9993,3.9993,0,0,0,1.9192.4906h2.8632a2,2,0,0,0,2-2V51.2024a2,2,0,0,0-1.04-1.7547L59.628,38.9521a8.0391,8.0391,0,0,0-7.8428.09L31.8346,50.56a8.0246,8.0246,0,0,0-4,6.9287v22.976a8,8,0,0,0,4,6.9283l19.95,11.5186a8.0429,8.0429,0,0,0,7.8433.0879l19.19-10.5312a2,2,0,0,0,1.0378-1.7533v-2.71A2,2,0,0,0,77.8567,82.0046Z"/>
|
||||
</g>
|
||||
<g>
|
||||
<path d="M172.58,45.3618a15.0166,15.0166,0,0,0-15,14.9995V77.6387a15,15,0,0,0,30,0V60.3613A15.0166,15.0166,0,0,0,172.58,45.3618Zm7,32.2769a7,7,0,0,1-14,0V60.3613a7,7,0,0,1,14,0Z"/>
|
||||
<path d="M135.9138,53.4211a7.01,7.01,0,0,1,7.8681,6.0752.9894.9894,0,0,0,.9843.865h6.03a1.0108,1.0108,0,0,0,.9987-1.0971,15.0182,15.0182,0,0,0-15.7162-13.8837,15.2881,15.2881,0,0,0-14.2441,15.4163V77.2037A15.288,15.288,0,0,0,136.0792,92.62a15.0183,15.0183,0,0,0,15.7162-13.8842,1.0107,1.0107,0,0,0-.9987-1.0971h-6.03a.9894.9894,0,0,0-.9843.865,7.01,7.01,0,0,1-7.8679,6.0757,7.1642,7.1642,0,0,1-6.0789-7.1849V60.6057A7.1638,7.1638,0,0,1,135.9138,53.4211Z"/>
|
||||
<path d="M218.7572,72.9277a12.1585,12.1585,0,0,0,7.1843-11.0771V58.1494A12.1494,12.1494,0,0,0,213.7921,46H196.835a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h6a1,1,0,0,0,1-1V74h6.6216l7.9154,17.4138a1,1,0,0,0,.91.5862h6.5911a1,1,0,0,0,.91-1.4138Zm-.8157-11.0771A4.1538,4.1538,0,0,1,213.7926,66h-9.8511V54h9.8511a4.1538,4.1538,0,0,1,4.1489,4.1494Z"/>
|
||||
<path d="M260.835,46h-26a1,1,0,0,0-1,1V91a1,1,0,0,0,1,1h26a1,1,0,0,0,1-1V85a1,1,0,0,0-1-1h-19V72h13a1,1,0,0,0,1-1V65a1,1,0,0,0-1-1h-13V54h19a1,1,0,0,0,1-1V47A1,1,0,0,0,260.835,46Z"/>
|
||||
<path d="M298.835,46h-6a1,1,0,0,0-1,1V69.6475a7.0066,7.0066,0,1,1-14,0V47a1,1,0,0,0-1-1h-6a1,1,0,0,0-1,1V69.6475a15.0031,15.0031,0,1,0,30,0V47A1,1,0,0,0,298.835,46Z"/>
|
||||
<rect x="307.835" y="46" width="8" height="38" rx="1"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
export const sygnet = ['160 160', `
|
||||
<title>coreui logo</title>
|
||||
<g>
|
||||
<g style="fill:#fff;">
|
||||
<path d="M125,47.091,86,24.5743a12,12,0,0,0-12,0L35,47.091a12.0336,12.0336,0,0,0-6,10.3923v45.0334a12.0335,12.0335,0,0,0,6,10.3923l39,22.5166a11.9993,11.9993,0,0,0,12,0l39-22.5166a12.0335,12.0335,0,0,0,6-10.3923V57.4833A12.0336,12.0336,0,0,0,125,47.091Zm-2,55.4257a4,4,0,0,1-2,3.464L82,128.4974a4,4,0,0,1-4,0L39,105.9807a4,4,0,0,1-2-3.464V57.4833a4,4,0,0,1,2-3.4641L78,31.5025a4,4,0,0,1,4,0l39,22.5167a4,4,0,0,1,2,3.4641Z"/>
|
||||
<path d="M103.0216,93.0379h-2.866a4,4,0,0,0-1.9246.4935L80.95,103.0167,61,91.4981V68.5206L80.95,57.002l17.2894,9.455a4,4,0,0,0,1.9192.4905h2.8632a2,2,0,0,0,2-2V62.2357a2,2,0,0,0-1.04-1.7547L84.793,49.9854a8.0391,8.0391,0,0,0-7.8428.09L57,61.5929A8.0243,8.0243,0,0,0,53,68.5216v22.976a8,8,0,0,0,4,6.9283l19.95,11.5185a8.0422,8.0422,0,0,0,7.8433.0879l19.19-10.5311a2,2,0,0,0,1.0378-1.7534v-2.71A2,2,0,0,0,103.0216,93.0379Z"/>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
export const sygnet = ['160 160', `
|
||||
<title>coreui logo</title>
|
||||
<g>
|
||||
<g style="fill:#fff;">
|
||||
<path d="M125,47.091,86,24.5743a12,12,0,0,0-12,0L35,47.091a12.0336,12.0336,0,0,0-6,10.3923v45.0334a12.0335,12.0335,0,0,0,6,10.3923l39,22.5166a11.9993,11.9993,0,0,0,12,0l39-22.5166a12.0335,12.0335,0,0,0,6-10.3923V57.4833A12.0336,12.0336,0,0,0,125,47.091Zm-2,55.4257a4,4,0,0,1-2,3.464L82,128.4974a4,4,0,0,1-4,0L39,105.9807a4,4,0,0,1-2-3.464V57.4833a4,4,0,0,1,2-3.4641L78,31.5025a4,4,0,0,1,4,0l39,22.5167a4,4,0,0,1,2,3.4641Z"/>
|
||||
<path d="M103.0216,93.0379h-2.866a4,4,0,0,0-1.9246.4935L80.95,103.0167,61,91.4981V68.5206L80.95,57.002l17.2894,9.455a4,4,0,0,0,1.9192.4905h2.8632a2,2,0,0,0,2-2V62.2357a2,2,0,0,0-1.04-1.7547L84.793,49.9854a8.0391,8.0391,0,0,0-7.8428.09L57,61.5929A8.0243,8.0243,0,0,0,53,68.5216v22.976a8,8,0,0,0,4,6.9283l19.95,11.5185a8.0422,8.0422,0,0,0,7.8433.0879l19.19-10.5311a2,2,0,0,0,1.0378-1.7534v-2.71A2,2,0,0,0,103.0216,93.0379Z"/>
|
||||
</g>
|
||||
</g>
|
||||
`]
|
||||
|
||||
@ -1,185 +1,185 @@
|
||||
import React, { Suspense, useState, useEffect } from 'react'
|
||||
import axios from 'axios';
|
||||
//import Cookies from 'js-cookie';
|
||||
import Cookies from 'universal-cookie';
|
||||
import {
|
||||
Redirect,
|
||||
Route,
|
||||
useLocation,
|
||||
Switch
|
||||
} from 'react-router-dom'
|
||||
import { CContainer, CFade } from '@coreui/react'
|
||||
|
||||
// routes config
|
||||
import routes from '../routes'
|
||||
import Sso from 'src/views/sso';
|
||||
|
||||
const loading = ( <
|
||||
div className = "pt-3 text-center" >
|
||||
<div className = "sk-spinner sk-spinner-pulse" > </div>
|
||||
</div>
|
||||
)
|
||||
|
||||
const TheContent = () => {
|
||||
|
||||
const [SsoSession, setSsoSession] = useState('');
|
||||
const [UserData, setUserData] = useState('');
|
||||
const [UserId, setUserId] = useState('');
|
||||
|
||||
async function fetchSession() {
|
||||
|
||||
//setSsoSession('{ "expiration": 468, "client_address": "111.223.144.163", "protocol": "urn:oasis:names:tc:SAML:2.0:protocol", "identity_provider": "https://sso.ts.bizside.biz/idp/shibboleth", "authn_instant": "2021-09-03T08:26:41.248Z", "authncontext_class": "urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport", "attributes": [ { "name": "mail", "values": [ "akira.miyata@mobilous.com" ] } ] }')
|
||||
const result = await axios('https://fbssso.ts.bizside.biz/Shibboleth.sso/Session');
|
||||
if(JSON.stringify(SsoSession) !== JSON.stringify(result.data)) {
|
||||
console.log(result.data);
|
||||
setSsoSession(result.data);
|
||||
}
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
fetchSession()
|
||||
}, []);
|
||||
|
||||
async function postUserData(data) {
|
||||
|
||||
let axiosConfig = {
|
||||
headers: {
|
||||
'Content-Type': 'application/json;charset=UTF-8',
|
||||
"Access-Control-Allow-Origin": "*",
|
||||
}
|
||||
};
|
||||
|
||||
const result = await axios.post('https://fbssso.ts.bizside.biz/csv', data, axiosConfig)
|
||||
.catch((err) => {
|
||||
console.log("AXIOS ERROR: ", err);
|
||||
});
|
||||
console.log("user data posted");
|
||||
}
|
||||
|
||||
async function fetchUser() {
|
||||
if(SsoSession.attributes == null || SsoSession.attributes[0] === undefined) {
|
||||
return false;
|
||||
}
|
||||
const user_email = SsoSession.attributes[0].values[0]
|
||||
//console.log(user_email);
|
||||
const company_code = "FBS";
|
||||
const key = "api"
|
||||
const pwd = "c558a56c63c44f65956adde8863ecc3558f3e55a465d4338bb2e7d2692866fd8";
|
||||
|
||||
const result = await axios.get('https://fbssso.ts.bizside.biz/users?email=' + user_email, {
|
||||
auth: {
|
||||
username: key,
|
||||
password: pwd
|
||||
}
|
||||
}).catch((err) => {
|
||||
console.log(err);
|
||||
return false;
|
||||
});
|
||||
//console.log(result.data);
|
||||
if(JSON.stringify(UserData) !== JSON.stringify(result.data[0])) {
|
||||
setUserData(result.data[0]);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
function isCSVPath(){
|
||||
const url =window.location.href;
|
||||
if(url.includes('dashboard')) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
function get_token_from_storage_or_cookie() {
|
||||
//return true;
|
||||
const cookies = new Cookies();
|
||||
const shib = cookies.get('_shibsession_64656661756c7468747470733a2f2f66627373736f2e74732e62697a736964652e62697a2f73686962626f6c657468')
|
||||
if (shib !== undefined) {
|
||||
fetchSession().then(() => {
|
||||
if (SsoSession !== null) {
|
||||
console.log(shib);
|
||||
fetchUser().then(() => {
|
||||
if(UserId === ''){
|
||||
let id = Math.floor(100000 + Math.random() * 900000)
|
||||
setUserId(id);
|
||||
}
|
||||
const _firstname = UserData.firstname;
|
||||
const _lastname = UserData.lastname;
|
||||
const _email = UserData.email;
|
||||
const _empcode = UserData.employee_code;
|
||||
|
||||
const json_str = `[
|
||||
{
|
||||
"mailadress": "${_email}",
|
||||
"name": "${_lastname} ${_firstname}",
|
||||
"jsessionid": ${UserId},
|
||||
"_idp_session": "",
|
||||
"_opensaml_key": "_shibsession_64656661756c7468747470733a2f2f66627373736f2e74732e62697a736964652e62697a2f73686962626f6c657468",
|
||||
"_opensaml_value": "${shib}"
|
||||
}
|
||||
]`;
|
||||
|
||||
|
||||
//const json_str = '[{"jsessonid": "' + UserId + '" , "name": "' + _firstname + ' ' +_lastname+ '", "mailadress":" ' + _email + '", "empcode": "' + _empcode + '"}]';
|
||||
if(_empcode !== null && _empcode !== undefined){
|
||||
if(isCSVPath()){
|
||||
postUserData(json_str);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<main className = "c-main">
|
||||
<CContainer fluid >
|
||||
<Suspense fallback = { loading }>
|
||||
<Switch > {
|
||||
routes.map((route, idx) => {
|
||||
return route.component && (
|
||||
<Route key = { idx }
|
||||
path = { route.path }
|
||||
exact = { route.exact }
|
||||
name = { route.name }
|
||||
|
||||
|
||||
|
||||
// render = {
|
||||
// props =>
|
||||
// ( <route.component {...props} userid={1} email={"akira.miyata@mobilous.com"}/>
|
||||
// )
|
||||
// }
|
||||
|
||||
|
||||
|
||||
render = {
|
||||
props =>
|
||||
get_token_from_storage_or_cookie() !== null ?
|
||||
( <route.component {...props} userid={UserId} email={UserData.email}/>
|
||||
) : ( <Redirect to = {
|
||||
{ pathname: "/sso" }
|
||||
}
|
||||
/>
|
||||
)
|
||||
}
|
||||
/>
|
||||
)
|
||||
})
|
||||
}
|
||||
<Redirect
|
||||
from = "/"
|
||||
to = "/dashboard" / >
|
||||
</Switch> </Suspense >
|
||||
</CContainer> </main >
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheContent)
|
||||
import React, { Suspense, useState, useEffect } from 'react'
|
||||
import axios from 'axios';
|
||||
//import Cookies from 'js-cookie';
|
||||
import Cookies from 'universal-cookie';
|
||||
import {
|
||||
Redirect,
|
||||
Route,
|
||||
useLocation,
|
||||
Switch
|
||||
} from 'react-router-dom'
|
||||
import { CContainer, CFade } from '@coreui/react'
|
||||
|
||||
// routes config
|
||||
import routes from '../routes'
|
||||
import Sso from 'src/views/sso';
|
||||
|
||||
const loading = ( <
|
||||
div className = "pt-3 text-center" >
|
||||
<div className = "sk-spinner sk-spinner-pulse" > </div>
|
||||
</div>
|
||||
)
|
||||
|
||||
const TheContent = () => {
|
||||
|
||||
const [SsoSession, setSsoSession] = useState('');
|
||||
const [UserData, setUserData] = useState('');
|
||||
const [UserId, setUserId] = useState('');
|
||||
|
||||
async function fetchSession() {
|
||||
|
||||
//setSsoSession('{ "expiration": 468, "client_address": "111.223.144.163", "protocol": "urn:oasis:names:tc:SAML:2.0:protocol", "identity_provider": "https://sso.ts.bizside.biz/idp/shibboleth", "authn_instant": "2021-09-03T08:26:41.248Z", "authncontext_class": "urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport", "attributes": [ { "name": "mail", "values": [ "akira.miyata@mobilous.com" ] } ] }')
|
||||
const result = await axios('https://fbssso.ts.bizside.biz/Shibboleth.sso/Session');
|
||||
if(JSON.stringify(SsoSession) !== JSON.stringify(result.data)) {
|
||||
console.log(result.data);
|
||||
setSsoSession(result.data);
|
||||
}
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
fetchSession()
|
||||
}, []);
|
||||
|
||||
async function postUserData(data) {
|
||||
|
||||
let axiosConfig = {
|
||||
headers: {
|
||||
'Content-Type': 'application/json;charset=UTF-8',
|
||||
"Access-Control-Allow-Origin": "*",
|
||||
}
|
||||
};
|
||||
|
||||
const result = await axios.post('https://fbssso.ts.bizside.biz/csv', data, axiosConfig)
|
||||
.catch((err) => {
|
||||
console.log("AXIOS ERROR: ", err);
|
||||
});
|
||||
console.log("user data posted");
|
||||
}
|
||||
|
||||
async function fetchUser() {
|
||||
if(SsoSession.attributes == null || SsoSession.attributes[0] === undefined) {
|
||||
return false;
|
||||
}
|
||||
const user_email = SsoSession.attributes[0].values[0]
|
||||
//console.log(user_email);
|
||||
const company_code = "FBS";
|
||||
const key = "api"
|
||||
const pwd = "c558a56c63c44f65956adde8863ecc3558f3e55a465d4338bb2e7d2692866fd8";
|
||||
|
||||
const result = await axios.get('https://fbssso.ts.bizside.biz/users?email=' + user_email, {
|
||||
auth: {
|
||||
username: key,
|
||||
password: pwd
|
||||
}
|
||||
}).catch((err) => {
|
||||
console.log(err);
|
||||
return false;
|
||||
});
|
||||
//console.log(result.data);
|
||||
if(JSON.stringify(UserData) !== JSON.stringify(result.data[0])) {
|
||||
setUserData(result.data[0]);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
function isCSVPath(){
|
||||
const url =window.location.href;
|
||||
if(url.includes('dashboard')) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
function get_token_from_storage_or_cookie() {
|
||||
//return true;
|
||||
const cookies = new Cookies();
|
||||
const shib = cookies.get('_shibsession_64656661756c7468747470733a2f2f66627373736f2e74732e62697a736964652e62697a2f73686962626f6c657468')
|
||||
if (shib !== undefined) {
|
||||
fetchSession().then(() => {
|
||||
if (SsoSession !== null) {
|
||||
console.log(shib);
|
||||
fetchUser().then(() => {
|
||||
if(UserId === ''){
|
||||
let id = Math.floor(100000 + Math.random() * 900000)
|
||||
setUserId(id);
|
||||
}
|
||||
const _firstname = UserData.firstname;
|
||||
const _lastname = UserData.lastname;
|
||||
const _email = UserData.email;
|
||||
const _empcode = UserData.employee_code;
|
||||
|
||||
const json_str = `[
|
||||
{
|
||||
"mailadress": "${_email}",
|
||||
"name": "${_lastname} ${_firstname}",
|
||||
"jsessionid": ${UserId},
|
||||
"_idp_session": "",
|
||||
"_opensaml_key": "_shibsession_64656661756c7468747470733a2f2f66627373736f2e74732e62697a736964652e62697a2f73686962626f6c657468",
|
||||
"_opensaml_value": "${shib}"
|
||||
}
|
||||
]`;
|
||||
|
||||
|
||||
//const json_str = '[{"jsessonid": "' + UserId + '" , "name": "' + _firstname + ' ' +_lastname+ '", "mailadress":" ' + _email + '", "empcode": "' + _empcode + '"}]';
|
||||
if(_empcode !== null && _empcode !== undefined){
|
||||
if(isCSVPath()){
|
||||
postUserData(json_str);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<main className = "c-main">
|
||||
<CContainer fluid >
|
||||
<Suspense fallback = { loading }>
|
||||
<Switch > {
|
||||
routes.map((route, idx) => {
|
||||
return route.component && (
|
||||
<Route key = { idx }
|
||||
path = { route.path }
|
||||
exact = { route.exact }
|
||||
name = { route.name }
|
||||
|
||||
|
||||
|
||||
// render = {
|
||||
// props =>
|
||||
// ( <route.component {...props} userid={1} email={"akira.miyata@mobilous.com"}/>
|
||||
// )
|
||||
// }
|
||||
|
||||
|
||||
|
||||
render = {
|
||||
props =>
|
||||
get_token_from_storage_or_cookie() !== null ?
|
||||
( <route.component {...props} userid={UserId} email={UserData.email}/>
|
||||
) : ( <Redirect to = {
|
||||
{ pathname: "/sso" }
|
||||
}
|
||||
/>
|
||||
)
|
||||
}
|
||||
/>
|
||||
)
|
||||
})
|
||||
}
|
||||
<Redirect
|
||||
from = "/"
|
||||
to = "/dashboard" / >
|
||||
</Switch> </Suspense >
|
||||
</CContainer> </main >
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheContent)
|
||||
|
||||
@ -1,19 +1,19 @@
|
||||
import React from 'react'
|
||||
import { CFooter } from '@coreui/react'
|
||||
|
||||
const TheFooter = () => {
|
||||
return (
|
||||
<CFooter fixed={false}>
|
||||
<div>
|
||||
<a href="sumasen.net" target="_blank" rel="noopener noreferrer">FBS</a>
|
||||
<span className="ml-1">© 2021 DigitalVox.</span>
|
||||
</div>
|
||||
<div className="mfs-auto">
|
||||
<span className="mr-1">搭載</span>
|
||||
<a href="#" target="_blank" rel="noopener noreferrer">DigitalVox</a>
|
||||
</div>
|
||||
</CFooter>
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheFooter)
|
||||
import React from 'react'
|
||||
import { CFooter } from '@coreui/react'
|
||||
|
||||
const TheFooter = () => {
|
||||
return (
|
||||
<CFooter fixed={false}>
|
||||
<div>
|
||||
<a href="sumasen.net" target="_blank" rel="noopener noreferrer">FBS</a>
|
||||
<span className="ml-1">© 2021 DigitalVox.</span>
|
||||
</div>
|
||||
<div className="mfs-auto">
|
||||
<span className="mr-1">搭載</span>
|
||||
<a href="#" target="_blank" rel="noopener noreferrer">DigitalVox</a>
|
||||
</div>
|
||||
</CFooter>
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheFooter)
|
||||
|
||||
@ -1,77 +1,77 @@
|
||||
import React from 'react'
|
||||
import { useSelector, useDispatch } from 'react-redux'
|
||||
import {
|
||||
CHeader,
|
||||
CToggler,
|
||||
CHeaderBrand,
|
||||
CHeaderNav,
|
||||
CHeaderNavItem,
|
||||
CHeaderNavLink,
|
||||
CSubheader,
|
||||
CBreadcrumbRouter,
|
||||
CLink
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
// routes config
|
||||
import routes from '../routes'
|
||||
|
||||
import {
|
||||
TheHeaderDropdown,
|
||||
TheHeaderDropdownMssg,
|
||||
TheHeaderDropdownNotif,
|
||||
TheHeaderDropdownTasks
|
||||
} from './index'
|
||||
|
||||
const TheHeader = () => {
|
||||
const dispatch = useDispatch()
|
||||
const sidebarShow = useSelector(state => state.sidebarShow)
|
||||
|
||||
const toggleSidebar = () => {
|
||||
const val = [true, 'responsive'].includes(sidebarShow) ? false : 'responsive'
|
||||
dispatch({type: 'set', sidebarShow: val})
|
||||
}
|
||||
|
||||
const toggleSidebarMobile = () => {
|
||||
const val = [false, 'responsive'].includes(sidebarShow) ? true : 'responsive'
|
||||
dispatch({type: 'set', sidebarShow: val})
|
||||
}
|
||||
|
||||
return (
|
||||
<CHeader withSubheader>
|
||||
<CToggler
|
||||
inHeader
|
||||
className="ml-md-3 d-lg-none"
|
||||
onClick={toggleSidebarMobile}
|
||||
/>
|
||||
<CToggler
|
||||
inHeader
|
||||
className="ml-3 d-md-down-none"
|
||||
onClick={toggleSidebar}
|
||||
/>
|
||||
<CHeaderBrand className="mx-auto d-lg-none" to="/">
|
||||
{/* <CIcon name="logo" height="48" alt="Logo"/> */}
|
||||
<h2>FBS</h2>
|
||||
</CHeaderBrand>
|
||||
|
||||
<CHeaderNav className="d-md-down-none mr-auto">
|
||||
<CHeaderNavItem className="px-3" >
|
||||
<CHeaderNavLink to="/dashboard">ダッシュボード</CHeaderNavLink>
|
||||
</CHeaderNavItem>
|
||||
</CHeaderNav>
|
||||
|
||||
<CHeaderNav className="px-3">
|
||||
<TheHeaderDropdown/>
|
||||
</CHeaderNav>
|
||||
|
||||
<CSubheader className="px-3 justify-content-between">
|
||||
<CBreadcrumbRouter
|
||||
className="border-0 c-subheader-nav m-0 px-0 px-md-3"
|
||||
routes={routes}
|
||||
/>
|
||||
</CSubheader>
|
||||
</CHeader>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeader
|
||||
import React from 'react'
|
||||
import { useSelector, useDispatch } from 'react-redux'
|
||||
import {
|
||||
CHeader,
|
||||
CToggler,
|
||||
CHeaderBrand,
|
||||
CHeaderNav,
|
||||
CHeaderNavItem,
|
||||
CHeaderNavLink,
|
||||
CSubheader,
|
||||
CBreadcrumbRouter,
|
||||
CLink
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
// routes config
|
||||
import routes from '../routes'
|
||||
|
||||
import {
|
||||
TheHeaderDropdown,
|
||||
TheHeaderDropdownMssg,
|
||||
TheHeaderDropdownNotif,
|
||||
TheHeaderDropdownTasks
|
||||
} from './index'
|
||||
|
||||
const TheHeader = () => {
|
||||
const dispatch = useDispatch()
|
||||
const sidebarShow = useSelector(state => state.sidebarShow)
|
||||
|
||||
const toggleSidebar = () => {
|
||||
const val = [true, 'responsive'].includes(sidebarShow) ? false : 'responsive'
|
||||
dispatch({type: 'set', sidebarShow: val})
|
||||
}
|
||||
|
||||
const toggleSidebarMobile = () => {
|
||||
const val = [false, 'responsive'].includes(sidebarShow) ? true : 'responsive'
|
||||
dispatch({type: 'set', sidebarShow: val})
|
||||
}
|
||||
|
||||
return (
|
||||
<CHeader withSubheader>
|
||||
<CToggler
|
||||
inHeader
|
||||
className="ml-md-3 d-lg-none"
|
||||
onClick={toggleSidebarMobile}
|
||||
/>
|
||||
<CToggler
|
||||
inHeader
|
||||
className="ml-3 d-md-down-none"
|
||||
onClick={toggleSidebar}
|
||||
/>
|
||||
<CHeaderBrand className="mx-auto d-lg-none" to="/">
|
||||
{/* <CIcon name="logo" height="48" alt="Logo"/> */}
|
||||
<h2>FBS</h2>
|
||||
</CHeaderBrand>
|
||||
|
||||
<CHeaderNav className="d-md-down-none mr-auto">
|
||||
<CHeaderNavItem className="px-3" >
|
||||
<CHeaderNavLink to="/dashboard">ダッシュボード</CHeaderNavLink>
|
||||
</CHeaderNavItem>
|
||||
</CHeaderNav>
|
||||
|
||||
<CHeaderNav className="px-3">
|
||||
<TheHeaderDropdown/>
|
||||
</CHeaderNav>
|
||||
|
||||
<CSubheader className="px-3 justify-content-between">
|
||||
<CBreadcrumbRouter
|
||||
className="border-0 c-subheader-nav m-0 px-0 px-md-3"
|
||||
routes={routes}
|
||||
/>
|
||||
</CSubheader>
|
||||
</CHeader>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeader
|
||||
|
||||
@ -1,46 +1,46 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CImg
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdown = () => {
|
||||
|
||||
function launchsso() {
|
||||
console.log("launch sso");
|
||||
window.open("https://fbssso.ts.bizside.biz/Shibboleth.sso/Login", "_self");
|
||||
}
|
||||
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-items mx-2"
|
||||
direction="down"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
アカウント
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu className="pt-0" placement="bottom-end">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
className="text-center"
|
||||
>
|
||||
<strong>アカウント</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem onClick={launchsso}>
|
||||
<CIcon name="cil-bell" className="mfe-2" />
|
||||
SSO ログイン
|
||||
</CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeaderDropdown
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CImg
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdown = () => {
|
||||
|
||||
function launchsso() {
|
||||
console.log("launch sso");
|
||||
window.open("https://fbssso.ts.bizside.biz/Shibboleth.sso/Login", "_self");
|
||||
}
|
||||
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-items mx-2"
|
||||
direction="down"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
アカウント
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu className="pt-0" placement="bottom-end">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
className="text-center"
|
||||
>
|
||||
<strong>アカウント</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem onClick={launchsso}>
|
||||
<CIcon name="cil-bell" className="mfe-2" />
|
||||
SSO ログイン
|
||||
</CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeaderDropdown
|
||||
|
||||
@ -1,127 +1,127 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CImg
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownMssg = () => {
|
||||
const itemsCount = 4
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
direction="down"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-envelope-open" /><CBadge shape="pill" color="info">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu className="pt-0" placement="bottom-end">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} messages</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/7.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-success"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">John Doe</small>
|
||||
<small className="text-muted float-right mt-1">Just now</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">
|
||||
<span className="fa fa-exclamation text-danger"></span> Important message
|
||||
</div>
|
||||
<div className="small text-muted text-truncate">
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/6.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-warning"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Jane Dovve</small>
|
||||
<small className="text-muted float-right mt-1">5 minutes ago</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/5.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-danger"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Janet Doe</small>
|
||||
<small className="text-muted float-right mt-1">1:52 PM</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/4.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-info"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Joe Doe</small>
|
||||
<small className="text-muted float-right mt-1">4:03 AM</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem href="#" className="text-center border-top"><strong>View all messages</strong></CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CImg
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownMssg = () => {
|
||||
const itemsCount = 4
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
direction="down"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-envelope-open" /><CBadge shape="pill" color="info">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu className="pt-0" placement="bottom-end">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} messages</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/7.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-success"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">John Doe</small>
|
||||
<small className="text-muted float-right mt-1">Just now</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">
|
||||
<span className="fa fa-exclamation text-danger"></span> Important message
|
||||
</div>
|
||||
<div className="small text-muted text-truncate">
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/6.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-warning"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Jane Dovve</small>
|
||||
<small className="text-muted float-right mt-1">5 minutes ago</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/5.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-danger"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Janet Doe</small>
|
||||
<small className="text-muted float-right mt-1">1:52 PM</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
|
||||
<CDropdownItem href="#">
|
||||
<div className="message">
|
||||
<div className="pt-3 mr-3 float-left">
|
||||
<div className="c-avatar">
|
||||
<CImg
|
||||
src={'avatars/4.jpg'}
|
||||
className="c-avatar-img"
|
||||
alt="admin@bootstrapmaster.com"
|
||||
/>
|
||||
<span className="c-avatar-status bg-info"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<small className="text-muted">Joe Doe</small>
|
||||
<small className="text-muted float-right mt-1">4:03 AM</small>
|
||||
</div>
|
||||
<div className="text-truncate font-weight-bold">Lorem ipsum dolor sit amet</div>
|
||||
<div className="small text-muted text-truncate">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt...
|
||||
</div>
|
||||
</div>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem href="#" className="text-center border-top"><strong>View all messages</strong></CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeaderDropdownMssg
|
||||
@ -1,70 +1,70 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CProgress
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownNotif = () => {
|
||||
const itemsCount = 5
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-bell"/>
|
||||
<CBadge shape="pill" color="danger">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu placement="bottom-end" className="pt-0">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
className="text-center"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} notifications</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-user-follow" className="mr-2 text-success" /> New user registered</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-user-unfollow" className="mr-2 text-danger" /> User deleted</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-chart-pie" className="mr-2 text-info" /> Sales report is ready</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-basket" className="mr-2 text-primary" /> New client</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-speedometer" className="mr-2 text-warning" /> Server overloaded</CDropdownItem>
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
>
|
||||
<strong>Server</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>CPU Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="info" value={25} />
|
||||
<small className="text-muted">348 Processes. 1/4 Cores.</small>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>Memory Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="warning" value={70} />
|
||||
<small className="text-muted">11444GB/16384MB</small>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>SSD 1 Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="danger" value={90} />
|
||||
<small className="text-muted">243GB/256GB</small>
|
||||
</CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CProgress
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownNotif = () => {
|
||||
const itemsCount = 5
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-bell"/>
|
||||
<CBadge shape="pill" color="danger">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu placement="bottom-end" className="pt-0">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
className="text-center"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} notifications</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-user-follow" className="mr-2 text-success" /> New user registered</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-user-unfollow" className="mr-2 text-danger" /> User deleted</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-chart-pie" className="mr-2 text-info" /> Sales report is ready</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-basket" className="mr-2 text-primary" /> New client</CDropdownItem>
|
||||
<CDropdownItem><CIcon name="cil-speedometer" className="mr-2 text-warning" /> Server overloaded</CDropdownItem>
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
color="light"
|
||||
>
|
||||
<strong>Server</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>CPU Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="info" value={25} />
|
||||
<small className="text-muted">348 Processes. 1/4 Cores.</small>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>Memory Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="warning" value={70} />
|
||||
<small className="text-muted">11444GB/16384MB</small>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="text-uppercase mb-1">
|
||||
<small><b>SSD 1 Usage</b></small>
|
||||
</div>
|
||||
<CProgress size="xs" color="danger" value={90} />
|
||||
<small className="text-muted">243GB/256GB</small>
|
||||
</CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeaderDropdownNotif
|
||||
@ -1,59 +1,59 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CProgress
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownTasks = () => {
|
||||
const itemsCount = 5
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-list" />
|
||||
<CBadge shape="pill" color="warning">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu placement="bottom-end" className="pt-0">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
className="text-center"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} pending tasks</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Upgrade NPM & Bower <span
|
||||
className="float-right"><strong>0%</strong></span></div>
|
||||
<CProgress size="xs" color="info" value={0} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">ReactJS Version <span className="float-right"><strong>25%</strong></span></div>
|
||||
<CProgress size="xs" color="danger" value={25} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">VueJS Version <span className="float-right"><strong>50%</strong></span></div>
|
||||
<CProgress size="xs" color="warning" value={50} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Add new layouts <span className="float-right"><strong>75%</strong></span></div>
|
||||
<CProgress size="xs" color="info" value={75} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Angular 2 Cli Version <span className="float-right"><strong>100%</strong></span></div>
|
||||
<CProgress size="xs" color="success" value={100} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="text-center border-top"><strong>View all tasks</strong></CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
import React from 'react'
|
||||
import {
|
||||
CBadge,
|
||||
CDropdown,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
CProgress
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const TheHeaderDropdownTasks = () => {
|
||||
const itemsCount = 5
|
||||
return (
|
||||
<CDropdown
|
||||
inNav
|
||||
className="c-header-nav-item mx-2"
|
||||
>
|
||||
<CDropdownToggle className="c-header-nav-link" caret={false}>
|
||||
<CIcon name="cil-list" />
|
||||
<CBadge shape="pill" color="warning">{itemsCount}</CBadge>
|
||||
</CDropdownToggle>
|
||||
<CDropdownMenu placement="bottom-end" className="pt-0">
|
||||
<CDropdownItem
|
||||
header
|
||||
tag="div"
|
||||
className="text-center"
|
||||
color="light"
|
||||
>
|
||||
<strong>You have {itemsCount} pending tasks</strong>
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Upgrade NPM & Bower <span
|
||||
className="float-right"><strong>0%</strong></span></div>
|
||||
<CProgress size="xs" color="info" value={0} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">ReactJS Version <span className="float-right"><strong>25%</strong></span></div>
|
||||
<CProgress size="xs" color="danger" value={25} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">VueJS Version <span className="float-right"><strong>50%</strong></span></div>
|
||||
<CProgress size="xs" color="warning" value={50} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Add new layouts <span className="float-right"><strong>75%</strong></span></div>
|
||||
<CProgress size="xs" color="info" value={75} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="d-block">
|
||||
<div className="small mb-1">Angular 2 Cli Version <span className="float-right"><strong>100%</strong></span></div>
|
||||
<CProgress size="xs" color="success" value={100} />
|
||||
</CDropdownItem>
|
||||
<CDropdownItem className="text-center border-top"><strong>View all tasks</strong></CDropdownItem>
|
||||
</CDropdownMenu>
|
||||
</CDropdown>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheHeaderDropdownTasks
|
||||
@ -1,25 +1,25 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
TheContent,
|
||||
TheSidebar,
|
||||
TheFooter,
|
||||
TheHeader
|
||||
} from './index'
|
||||
|
||||
const TheLayout = () => {
|
||||
|
||||
return (
|
||||
<div className="c-app c-default-layout">
|
||||
<TheSidebar/>
|
||||
<div className="c-wrapper">
|
||||
<TheHeader/>
|
||||
<div className="c-body">
|
||||
<TheContent/>
|
||||
</div>
|
||||
<TheFooter/>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheLayout
|
||||
import React from 'react'
|
||||
import {
|
||||
TheContent,
|
||||
TheSidebar,
|
||||
TheFooter,
|
||||
TheHeader
|
||||
} from './index'
|
||||
|
||||
const TheLayout = () => {
|
||||
|
||||
return (
|
||||
<div className="c-app c-default-layout">
|
||||
<TheSidebar/>
|
||||
<div className="c-wrapper">
|
||||
<TheHeader/>
|
||||
<div className="c-body">
|
||||
<TheContent/>
|
||||
</div>
|
||||
<TheFooter/>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default TheLayout
|
||||
|
||||
@ -1,54 +1,54 @@
|
||||
import React from 'react'
|
||||
import { useSelector, useDispatch } from 'react-redux'
|
||||
import {
|
||||
CCreateElement,
|
||||
CSidebar,
|
||||
CSidebarBrand,
|
||||
CSidebarNav,
|
||||
CSidebarNavDivider,
|
||||
CSidebarNavTitle,
|
||||
CSidebarMinimizer,
|
||||
CSidebarNavDropdown,
|
||||
CSidebarNavItem,
|
||||
} from '@coreui/react'
|
||||
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
// sidebar nav config
|
||||
import navigation from './_nav'
|
||||
|
||||
const TheSidebar = () => {
|
||||
const dispatch = useDispatch()
|
||||
const show = useSelector(state => state.sidebarShow)
|
||||
|
||||
return (
|
||||
<CSidebar
|
||||
show={show}
|
||||
onShowChange={(val) => dispatch({type: 'set', sidebarShow: val })}
|
||||
>
|
||||
<CSidebarBrand className="d-md-down-none" to="/">
|
||||
<h2>FBS</h2>
|
||||
<CIcon
|
||||
className="c-sidebar-brand-minimized"
|
||||
name="sygnet"
|
||||
height={35}
|
||||
/>
|
||||
</CSidebarBrand>
|
||||
<CSidebarNav>
|
||||
|
||||
<CCreateElement
|
||||
items={navigation}
|
||||
components={{
|
||||
CSidebarNavDivider,
|
||||
CSidebarNavDropdown,
|
||||
CSidebarNavItem,
|
||||
CSidebarNavTitle
|
||||
}}
|
||||
/>
|
||||
</CSidebarNav>
|
||||
<CSidebarMinimizer className="c-d-md-down-none"/>
|
||||
</CSidebar>
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheSidebar)
|
||||
import React from 'react'
|
||||
import { useSelector, useDispatch } from 'react-redux'
|
||||
import {
|
||||
CCreateElement,
|
||||
CSidebar,
|
||||
CSidebarBrand,
|
||||
CSidebarNav,
|
||||
CSidebarNavDivider,
|
||||
CSidebarNavTitle,
|
||||
CSidebarMinimizer,
|
||||
CSidebarNavDropdown,
|
||||
CSidebarNavItem,
|
||||
} from '@coreui/react'
|
||||
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
// sidebar nav config
|
||||
import navigation from './_nav'
|
||||
|
||||
const TheSidebar = () => {
|
||||
const dispatch = useDispatch()
|
||||
const show = useSelector(state => state.sidebarShow)
|
||||
|
||||
return (
|
||||
<CSidebar
|
||||
show={show}
|
||||
onShowChange={(val) => dispatch({type: 'set', sidebarShow: val })}
|
||||
>
|
||||
<CSidebarBrand className="d-md-down-none" to="/">
|
||||
<h2>FBS</h2>
|
||||
<CIcon
|
||||
className="c-sidebar-brand-minimized"
|
||||
name="sygnet"
|
||||
height={35}
|
||||
/>
|
||||
</CSidebarBrand>
|
||||
<CSidebarNav>
|
||||
|
||||
<CCreateElement
|
||||
items={navigation}
|
||||
components={{
|
||||
CSidebarNavDivider,
|
||||
CSidebarNavDropdown,
|
||||
CSidebarNavItem,
|
||||
CSidebarNavTitle
|
||||
}}
|
||||
/>
|
||||
</CSidebarNav>
|
||||
<CSidebarMinimizer className="c-d-md-down-none"/>
|
||||
</CSidebar>
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(TheSidebar)
|
||||
|
||||
@ -1,51 +1,51 @@
|
||||
import React from 'react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const _nav = [{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: 'ダッシュボード',
|
||||
to: '/dashboard',
|
||||
icon: < CIcon name = "cil-speedometer"
|
||||
customClasses = "c-sidebar-nav-icon" / >
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavTitle',
|
||||
_children: ['レポート']
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: '報告書',
|
||||
to: '/reports',
|
||||
icon: 'cil-drop',
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: 'アップロード',
|
||||
to: '/uploader',
|
||||
icon: 'cil-drop',
|
||||
},
|
||||
// {
|
||||
// _tag: 'CSidebarNavTitle',
|
||||
// _children: ['Components']
|
||||
// },
|
||||
// {
|
||||
// _tag: 'CSidebarNavDropdown',
|
||||
// name: 'Base',
|
||||
// route: '/base',
|
||||
// icon: 'cil-puzzle',
|
||||
// _children: [
|
||||
// {
|
||||
// _tag: 'CSidebarNavItem',
|
||||
// name: 'Breadcrumb',
|
||||
// to: '/base/breadcrumbs',
|
||||
// },
|
||||
// {
|
||||
// _tag: 'CSidebarNavItem',
|
||||
// name: 'Tooltips',
|
||||
// to: '/base/tooltips',
|
||||
// },
|
||||
// ],
|
||||
// }
|
||||
]
|
||||
|
||||
import React from 'react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const _nav = [{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: 'ダッシュボード',
|
||||
to: '/dashboard',
|
||||
icon: < CIcon name = "cil-speedometer"
|
||||
customClasses = "c-sidebar-nav-icon" / >
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavTitle',
|
||||
_children: ['レポート']
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: '報告書',
|
||||
to: '/reports',
|
||||
icon: 'cil-drop',
|
||||
},
|
||||
{
|
||||
_tag: 'CSidebarNavItem',
|
||||
name: 'アップロード',
|
||||
to: '/uploader',
|
||||
icon: 'cil-drop',
|
||||
},
|
||||
// {
|
||||
// _tag: 'CSidebarNavTitle',
|
||||
// _children: ['Components']
|
||||
// },
|
||||
// {
|
||||
// _tag: 'CSidebarNavDropdown',
|
||||
// name: 'Base',
|
||||
// route: '/base',
|
||||
// icon: 'cil-puzzle',
|
||||
// _children: [
|
||||
// {
|
||||
// _tag: 'CSidebarNavItem',
|
||||
// name: 'Breadcrumb',
|
||||
// to: '/base/breadcrumbs',
|
||||
// },
|
||||
// {
|
||||
// _tag: 'CSidebarNavItem',
|
||||
// name: 'Tooltips',
|
||||
// to: '/base/tooltips',
|
||||
// },
|
||||
// ],
|
||||
// }
|
||||
]
|
||||
|
||||
export default _nav
|
||||
@ -1,21 +1,21 @@
|
||||
import TheContent from './TheContent'
|
||||
import TheFooter from './TheFooter'
|
||||
import TheHeader from './TheHeader'
|
||||
import TheHeaderDropdown from './TheHeaderDropdown'
|
||||
import TheHeaderDropdownMssg from './TheHeaderDropdownMssg'
|
||||
import TheHeaderDropdownNotif from './TheHeaderDropdownNotif'
|
||||
import TheHeaderDropdownTasks from './TheHeaderDropdownTasks'
|
||||
import TheLayout from './TheLayout'
|
||||
import TheSidebar from './TheSidebar'
|
||||
|
||||
export {
|
||||
TheContent,
|
||||
TheFooter,
|
||||
TheHeader,
|
||||
TheHeaderDropdown,
|
||||
TheHeaderDropdownMssg,
|
||||
TheHeaderDropdownNotif,
|
||||
TheHeaderDropdownTasks,
|
||||
TheLayout,
|
||||
TheSidebar
|
||||
}
|
||||
import TheContent from './TheContent'
|
||||
import TheFooter from './TheFooter'
|
||||
import TheHeader from './TheHeader'
|
||||
import TheHeaderDropdown from './TheHeaderDropdown'
|
||||
import TheHeaderDropdownMssg from './TheHeaderDropdownMssg'
|
||||
import TheHeaderDropdownNotif from './TheHeaderDropdownNotif'
|
||||
import TheHeaderDropdownTasks from './TheHeaderDropdownTasks'
|
||||
import TheLayout from './TheLayout'
|
||||
import TheSidebar from './TheSidebar'
|
||||
|
||||
export {
|
||||
TheContent,
|
||||
TheFooter,
|
||||
TheHeader,
|
||||
TheHeaderDropdown,
|
||||
TheHeaderDropdownMssg,
|
||||
TheHeaderDropdownNotif,
|
||||
TheHeaderDropdownTasks,
|
||||
TheLayout,
|
||||
TheSidebar
|
||||
}
|
||||
|
||||
54
src/index.js
54
src/index.js
@ -1,27 +1,27 @@
|
||||
import 'react-app-polyfill/ie11'; // For IE 11 support
|
||||
import 'react-app-polyfill/stable';
|
||||
import 'core-js';
|
||||
import './polyfill'
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import App from './App';
|
||||
import * as serviceWorker from './serviceWorker';
|
||||
|
||||
import { icons } from './assets/icons'
|
||||
|
||||
import { Provider } from 'react-redux'
|
||||
import store from './store'
|
||||
|
||||
React.icons = icons
|
||||
|
||||
ReactDOM.render(
|
||||
<Provider store={store}>
|
||||
<App/>
|
||||
</Provider>,
|
||||
document.getElementById('root')
|
||||
);
|
||||
|
||||
// If you want your app to work offline and load faster, you can change
|
||||
// unregister() to register() below. Note this comes with some pitfalls.
|
||||
// Learn more about service workers: http://bit.ly/CRA-PWA
|
||||
serviceWorker.unregister();
|
||||
import 'react-app-polyfill/ie11'; // For IE 11 support
|
||||
import 'react-app-polyfill/stable';
|
||||
import 'core-js';
|
||||
import './polyfill'
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import App from './App';
|
||||
import * as serviceWorker from './serviceWorker';
|
||||
|
||||
import { icons } from './assets/icons'
|
||||
|
||||
import { Provider } from 'react-redux'
|
||||
import store from './store'
|
||||
|
||||
React.icons = icons
|
||||
|
||||
ReactDOM.render(
|
||||
<Provider store={store}>
|
||||
<App/>
|
||||
</Provider>,
|
||||
document.getElementById('root')
|
||||
);
|
||||
|
||||
// If you want your app to work offline and load faster, you can change
|
||||
// unregister() to register() below. Note this comes with some pitfalls.
|
||||
// Learn more about service workers: http://bit.ly/CRA-PWA
|
||||
serviceWorker.unregister();
|
||||
|
||||
126
src/polyfill.js
126
src/polyfill.js
@ -1,63 +1,63 @@
|
||||
/*
|
||||
* required polyfills
|
||||
*/
|
||||
|
||||
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
|
||||
// import "core-js";
|
||||
// import 'core-js/features/symbol'
|
||||
// import 'core-js/features/object'
|
||||
// import 'core-js/features/function'
|
||||
// import 'core-js/features/parse-int'
|
||||
// import 'core-js/features/parse-float'
|
||||
// import 'core-js/features/number'
|
||||
// import 'core-js/features/math'
|
||||
// import 'core-js/features/string'
|
||||
// import 'core-js/features/date'
|
||||
// import 'core-js/features/array'
|
||||
// import 'core-js/features/regexp'
|
||||
// import 'core-js/features/map'
|
||||
// import 'core-js/features/weak-map'
|
||||
// import 'core-js/features/set'
|
||||
// import 'core-js/features/set/map';
|
||||
|
||||
/** IE10 and IE11 requires the following for the Reflect API. */
|
||||
// import 'core-js/features/reflect';
|
||||
|
||||
/** Evergreen browsers require these. **/
|
||||
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
|
||||
// import 'core-js/features/reflect'
|
||||
|
||||
// CustomEvent() constructor functionality in IE9, IE10, IE11
|
||||
(function () {
|
||||
|
||||
if ( typeof window.CustomEvent === "function" ) return false
|
||||
|
||||
function CustomEvent ( event, params ) {
|
||||
params = params || { bubbles: false, cancelable: false, detail: undefined }
|
||||
var evt = document.createEvent( 'CustomEvent' )
|
||||
evt.initCustomEvent( event, params.bubbles, params.cancelable, params.detail )
|
||||
return evt
|
||||
}
|
||||
|
||||
CustomEvent.prototype = window.Event.prototype
|
||||
|
||||
window.CustomEvent = CustomEvent
|
||||
})()
|
||||
|
||||
if (!Element.prototype.matches) {
|
||||
Element.prototype.matches =
|
||||
Element.prototype.msMatchesSelector ||
|
||||
Element.prototype.webkitMatchesSelector;
|
||||
}
|
||||
|
||||
if (!Element.prototype.closest) {
|
||||
Element.prototype.closest = function(s) {
|
||||
var el = this;
|
||||
|
||||
do {
|
||||
if (Element.prototype.matches.call(el, s)) return el;
|
||||
el = el.parentElement || el.parentNode;
|
||||
} while (el !== null && el.nodeType === 1);
|
||||
return null;
|
||||
};
|
||||
}
|
||||
/*
|
||||
* required polyfills
|
||||
*/
|
||||
|
||||
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
|
||||
// import "core-js";
|
||||
// import 'core-js/features/symbol'
|
||||
// import 'core-js/features/object'
|
||||
// import 'core-js/features/function'
|
||||
// import 'core-js/features/parse-int'
|
||||
// import 'core-js/features/parse-float'
|
||||
// import 'core-js/features/number'
|
||||
// import 'core-js/features/math'
|
||||
// import 'core-js/features/string'
|
||||
// import 'core-js/features/date'
|
||||
// import 'core-js/features/array'
|
||||
// import 'core-js/features/regexp'
|
||||
// import 'core-js/features/map'
|
||||
// import 'core-js/features/weak-map'
|
||||
// import 'core-js/features/set'
|
||||
// import 'core-js/features/set/map';
|
||||
|
||||
/** IE10 and IE11 requires the following for the Reflect API. */
|
||||
// import 'core-js/features/reflect';
|
||||
|
||||
/** Evergreen browsers require these. **/
|
||||
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
|
||||
// import 'core-js/features/reflect'
|
||||
|
||||
// CustomEvent() constructor functionality in IE9, IE10, IE11
|
||||
(function () {
|
||||
|
||||
if ( typeof window.CustomEvent === "function" ) return false
|
||||
|
||||
function CustomEvent ( event, params ) {
|
||||
params = params || { bubbles: false, cancelable: false, detail: undefined }
|
||||
var evt = document.createEvent( 'CustomEvent' )
|
||||
evt.initCustomEvent( event, params.bubbles, params.cancelable, params.detail )
|
||||
return evt
|
||||
}
|
||||
|
||||
CustomEvent.prototype = window.Event.prototype
|
||||
|
||||
window.CustomEvent = CustomEvent
|
||||
})()
|
||||
|
||||
if (!Element.prototype.matches) {
|
||||
Element.prototype.matches =
|
||||
Element.prototype.msMatchesSelector ||
|
||||
Element.prototype.webkitMatchesSelector;
|
||||
}
|
||||
|
||||
if (!Element.prototype.closest) {
|
||||
Element.prototype.closest = function(s) {
|
||||
var el = this;
|
||||
|
||||
do {
|
||||
if (Element.prototype.matches.call(el, s)) return el;
|
||||
el = el.parentElement || el.parentNode;
|
||||
} while (el !== null && el.nodeType === 1);
|
||||
return null;
|
||||
};
|
||||
}
|
||||
|
||||
@ -1,28 +1,28 @@
|
||||
import React from 'react'
|
||||
import { CLink } from '@coreui/react'
|
||||
|
||||
const DocsLink = props => {
|
||||
const {
|
||||
name,
|
||||
text,
|
||||
...rest
|
||||
} = props
|
||||
|
||||
const href = name ? `https://coreui.io/react/docs/components/${name}` : props.href
|
||||
|
||||
return (
|
||||
<div className="card-header-actions">
|
||||
<CLink
|
||||
{...rest}
|
||||
href={href}
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
className="card-header-action"
|
||||
>
|
||||
<small className="text-muted">{ text || 'docs' }</small>
|
||||
</CLink>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
import React from 'react'
|
||||
import { CLink } from '@coreui/react'
|
||||
|
||||
const DocsLink = props => {
|
||||
const {
|
||||
name,
|
||||
text,
|
||||
...rest
|
||||
} = props
|
||||
|
||||
const href = name ? `https://coreui.io/react/docs/components/${name}` : props.href
|
||||
|
||||
return (
|
||||
<div className="card-header-actions">
|
||||
<CLink
|
||||
{...rest}
|
||||
href={href}
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
className="card-header-action"
|
||||
>
|
||||
<small className="text-muted">{ text || 'docs' }</small>
|
||||
</CLink>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default React.memo(DocsLink)
|
||||
@ -1,5 +1,5 @@
|
||||
import DocsLink from './DocsLink'
|
||||
|
||||
export {
|
||||
DocsLink
|
||||
import DocsLink from './DocsLink'
|
||||
|
||||
export {
|
||||
DocsLink
|
||||
}
|
||||
@ -1,18 +1,18 @@
|
||||
import React from 'react';
|
||||
|
||||
const Dashboard = React.lazy(() => import('./views/dashboard/Dashboard'));
|
||||
const BoxDisplacemen = React.lazy(() => import('./views/BoxDisplacemen/index'));
|
||||
const Uploader = React.lazy(() => import('./views/Uploader/index'));
|
||||
const Secret = React.lazy(() => import('./views/secret/index'));
|
||||
const Sso = React.lazy(() => import('./views/sso/index'));
|
||||
|
||||
|
||||
const routes = [
|
||||
{ path: '/', exact: true, name: 'Home' },
|
||||
{ path: '/dashboard', name: 'ダッシュボード', component: Dashboard },
|
||||
{ path: '/reports', exact: true, name: 'レポート', component: BoxDisplacemen },
|
||||
{ path: '/uploader', exact: true, name: 'アップロード', component: Uploader },
|
||||
{ path: '/secret', exact: true, name: 'アップロード', component: Secret },
|
||||
];
|
||||
|
||||
export default routes;
|
||||
import React from 'react';
|
||||
|
||||
const Dashboard = React.lazy(() => import('./views/dashboard/Dashboard'));
|
||||
const BoxDisplacemen = React.lazy(() => import('./views/BoxDisplacemen/index'));
|
||||
const Uploader = React.lazy(() => import('./views/Uploader/index'));
|
||||
const Secret = React.lazy(() => import('./views/secret/index'));
|
||||
const Sso = React.lazy(() => import('./views/sso/index'));
|
||||
|
||||
|
||||
const routes = [
|
||||
{ path: '/', exact: true, name: 'Home' },
|
||||
{ path: '/dashboard', name: 'ダッシュボード', component: Dashboard },
|
||||
{ path: '/reports', exact: true, name: 'レポート', component: BoxDisplacemen },
|
||||
{ path: '/uploader', exact: true, name: 'アップロード', component: Uploader },
|
||||
{ path: '/secret', exact: true, name: 'アップロード', component: Secret },
|
||||
];
|
||||
|
||||
export default routes;
|
||||
|
||||
@ -1 +1 @@
|
||||
// Here you can add other styles
|
||||
// Here you can add other styles
|
||||
|
||||
@ -1,16 +1,16 @@
|
||||
// todo: disabled button styles
|
||||
button {
|
||||
&:disabled {
|
||||
cursor: default;
|
||||
}
|
||||
&.disabled {
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
|
||||
// todo: brand button icon margin
|
||||
.btn-brand:not(:only-child) {
|
||||
.c-icon {
|
||||
margin-top: 0 !important;
|
||||
}
|
||||
}
|
||||
// todo: disabled button styles
|
||||
button {
|
||||
&:disabled {
|
||||
cursor: default;
|
||||
}
|
||||
&.disabled {
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
|
||||
// todo: brand button icon margin
|
||||
.btn-brand:not(:only-child) {
|
||||
.c-icon {
|
||||
margin-top: 0 !important;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1 +1 @@
|
||||
// Variable overrides
|
||||
// Variable overrides
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
// If you want to override variables do it here
|
||||
@import "variables";
|
||||
|
||||
// Import CoreUI styles
|
||||
@import "~@coreui/coreui/scss/coreui.scss";
|
||||
|
||||
// Some temp fixes
|
||||
@import "fixes";
|
||||
|
||||
// If you want to add something do it here
|
||||
@import "custom";
|
||||
// If you want to override variables do it here
|
||||
@import "variables";
|
||||
|
||||
// Import CoreUI styles
|
||||
@import "~@coreui/coreui/scss/coreui.scss";
|
||||
|
||||
// Some temp fixes
|
||||
@import "fixes";
|
||||
|
||||
// If you want to add something do it here
|
||||
@import "custom";
|
||||
|
||||
@ -1,127 +1,127 @@
|
||||
// In production, we register a service worker to serve assets from local cache.
|
||||
|
||||
// This lets the app load faster on subsequent visits in production, and gives
|
||||
// it offline capabilities. However, it also means that developers (and users)
|
||||
// will only see deployed updates on the "N+1" visit to a page, since previously
|
||||
// cached resources are updated in the background.
|
||||
|
||||
// To learn more about the benefits of this model, read https://goo.gl/KwvDNy.
|
||||
// This link also includes instructions on opting out of this behavior.
|
||||
|
||||
const isLocalhost = Boolean(
|
||||
window.location.hostname === 'localhost' ||
|
||||
// [::1] is the IPv6 localhost address.
|
||||
window.location.hostname === '[::1]' ||
|
||||
// 127.0.0.1/8 is considered localhost for IPv4.
|
||||
window.location.hostname.match(
|
||||
/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/
|
||||
)
|
||||
);
|
||||
|
||||
export function register(config) {
|
||||
if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {
|
||||
// The URL constructor is available in all browsers that support SW.
|
||||
const publicUrl = new URL(process.env.PUBLIC_URL, window.location);
|
||||
if (publicUrl.origin !== window.location.origin) {
|
||||
// Our service worker won't work if PUBLIC_URL is on a different origin
|
||||
// from what our page is served on. This might happen if a CDN is used to
|
||||
// serve assets; see https://github.com/facebook/create-react-app/issues/2374
|
||||
return;
|
||||
}
|
||||
|
||||
window.addEventListener('load', () => {
|
||||
const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;
|
||||
|
||||
if (isLocalhost) {
|
||||
// This is running on localhost. Let's check if a service worker still exists or not.
|
||||
checkValidServiceWorker(swUrl, config);
|
||||
|
||||
// Add some additional logging to localhost, pointing developers to the
|
||||
// service worker/PWA documentation.
|
||||
navigator.serviceWorker.ready.then(() => {
|
||||
console.log(
|
||||
'This web app is being served cache-first by a service ' +
|
||||
'worker. To learn more, visit https://goo.gl/SC7cgQ'
|
||||
);
|
||||
});
|
||||
} else {
|
||||
// Is not local host. Just register service worker
|
||||
registerValidSW(swUrl, config);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function registerValidSW(swUrl, config) {
|
||||
navigator.serviceWorker
|
||||
.register(swUrl)
|
||||
.then(registration => {
|
||||
registration.onupdatefound = () => {
|
||||
const installingWorker = registration.installing;
|
||||
installingWorker.onstatechange = () => {
|
||||
if (installingWorker.state === 'installed') {
|
||||
if (navigator.serviceWorker.controller) {
|
||||
// At this point, the old content will have been purged and
|
||||
// the fresh content will have been added to the cache.
|
||||
// It's the perfect time to display a "New content is
|
||||
// available; please refresh." message in your web app.
|
||||
console.log('New content is available; please refresh.');
|
||||
|
||||
// Execute callback
|
||||
if (config.onUpdate) {
|
||||
config.onUpdate(registration);
|
||||
}
|
||||
} else {
|
||||
// At this point, everything has been precached.
|
||||
// It's the perfect time to display a
|
||||
// "Content is cached for offline use." message.
|
||||
console.log('Content is cached for offline use.');
|
||||
|
||||
// Execute callback
|
||||
if (config.onSuccess) {
|
||||
config.onSuccess(registration);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
})
|
||||
.catch(error => {
|
||||
console.error('Error during service worker registration:', error);
|
||||
});
|
||||
}
|
||||
|
||||
function checkValidServiceWorker(swUrl, config) {
|
||||
// Check if the service worker can be found. If it can't reload the page.
|
||||
fetch(swUrl)
|
||||
.then(response => {
|
||||
// Ensure service worker exists, and that we really are getting a JS file.
|
||||
if (
|
||||
response.status === 404 ||
|
||||
response.headers.get('content-type').indexOf('javascript') === -1
|
||||
) {
|
||||
// No service worker found. Probably a different app. Reload the page.
|
||||
navigator.serviceWorker.ready.then(registration => {
|
||||
registration.unregister().then(() => {
|
||||
window.location.reload();
|
||||
});
|
||||
});
|
||||
} else {
|
||||
// Service worker found. Proceed as normal.
|
||||
registerValidSW(swUrl, config);
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
console.log(
|
||||
'No internet connection found. App is running in offline mode.'
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
export function unregister() {
|
||||
if ('serviceWorker' in navigator) {
|
||||
navigator.serviceWorker.ready.then(registration => {
|
||||
registration.unregister();
|
||||
});
|
||||
}
|
||||
}
|
||||
// In production, we register a service worker to serve assets from local cache.
|
||||
|
||||
// This lets the app load faster on subsequent visits in production, and gives
|
||||
// it offline capabilities. However, it also means that developers (and users)
|
||||
// will only see deployed updates on the "N+1" visit to a page, since previously
|
||||
// cached resources are updated in the background.
|
||||
|
||||
// To learn more about the benefits of this model, read https://goo.gl/KwvDNy.
|
||||
// This link also includes instructions on opting out of this behavior.
|
||||
|
||||
const isLocalhost = Boolean(
|
||||
window.location.hostname === 'localhost' ||
|
||||
// [::1] is the IPv6 localhost address.
|
||||
window.location.hostname === '[::1]' ||
|
||||
// 127.0.0.1/8 is considered localhost for IPv4.
|
||||
window.location.hostname.match(
|
||||
/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/
|
||||
)
|
||||
);
|
||||
|
||||
export function register(config) {
|
||||
if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {
|
||||
// The URL constructor is available in all browsers that support SW.
|
||||
const publicUrl = new URL(process.env.PUBLIC_URL, window.location);
|
||||
if (publicUrl.origin !== window.location.origin) {
|
||||
// Our service worker won't work if PUBLIC_URL is on a different origin
|
||||
// from what our page is served on. This might happen if a CDN is used to
|
||||
// serve assets; see https://github.com/facebook/create-react-app/issues/2374
|
||||
return;
|
||||
}
|
||||
|
||||
window.addEventListener('load', () => {
|
||||
const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;
|
||||
|
||||
if (isLocalhost) {
|
||||
// This is running on localhost. Let's check if a service worker still exists or not.
|
||||
checkValidServiceWorker(swUrl, config);
|
||||
|
||||
// Add some additional logging to localhost, pointing developers to the
|
||||
// service worker/PWA documentation.
|
||||
navigator.serviceWorker.ready.then(() => {
|
||||
console.log(
|
||||
'This web app is being served cache-first by a service ' +
|
||||
'worker. To learn more, visit https://goo.gl/SC7cgQ'
|
||||
);
|
||||
});
|
||||
} else {
|
||||
// Is not local host. Just register service worker
|
||||
registerValidSW(swUrl, config);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function registerValidSW(swUrl, config) {
|
||||
navigator.serviceWorker
|
||||
.register(swUrl)
|
||||
.then(registration => {
|
||||
registration.onupdatefound = () => {
|
||||
const installingWorker = registration.installing;
|
||||
installingWorker.onstatechange = () => {
|
||||
if (installingWorker.state === 'installed') {
|
||||
if (navigator.serviceWorker.controller) {
|
||||
// At this point, the old content will have been purged and
|
||||
// the fresh content will have been added to the cache.
|
||||
// It's the perfect time to display a "New content is
|
||||
// available; please refresh." message in your web app.
|
||||
console.log('New content is available; please refresh.');
|
||||
|
||||
// Execute callback
|
||||
if (config.onUpdate) {
|
||||
config.onUpdate(registration);
|
||||
}
|
||||
} else {
|
||||
// At this point, everything has been precached.
|
||||
// It's the perfect time to display a
|
||||
// "Content is cached for offline use." message.
|
||||
console.log('Content is cached for offline use.');
|
||||
|
||||
// Execute callback
|
||||
if (config.onSuccess) {
|
||||
config.onSuccess(registration);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
})
|
||||
.catch(error => {
|
||||
console.error('Error during service worker registration:', error);
|
||||
});
|
||||
}
|
||||
|
||||
function checkValidServiceWorker(swUrl, config) {
|
||||
// Check if the service worker can be found. If it can't reload the page.
|
||||
fetch(swUrl)
|
||||
.then(response => {
|
||||
// Ensure service worker exists, and that we really are getting a JS file.
|
||||
if (
|
||||
response.status === 404 ||
|
||||
response.headers.get('content-type').indexOf('javascript') === -1
|
||||
) {
|
||||
// No service worker found. Probably a different app. Reload the page.
|
||||
navigator.serviceWorker.ready.then(registration => {
|
||||
registration.unregister().then(() => {
|
||||
window.location.reload();
|
||||
});
|
||||
});
|
||||
} else {
|
||||
// Service worker found. Proceed as normal.
|
||||
registerValidSW(swUrl, config);
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
console.log(
|
||||
'No internet connection found. App is running in offline mode.'
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
export function unregister() {
|
||||
if ('serviceWorker' in navigator) {
|
||||
navigator.serviceWorker.ready.then(registration => {
|
||||
registration.unregister();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,15 +1,15 @@
|
||||
import {configure} from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
|
||||
configure({adapter: new Adapter()});
|
||||
|
||||
if (global.document) {
|
||||
document.createRange = () => ({
|
||||
setStart: () => {},
|
||||
setEnd: () => {},
|
||||
commonAncestorContainer: {
|
||||
nodeName: 'BODY',
|
||||
ownerDocument: document,
|
||||
},
|
||||
});
|
||||
}
|
||||
import {configure} from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
|
||||
configure({adapter: new Adapter()});
|
||||
|
||||
if (global.document) {
|
||||
document.createRange = () => ({
|
||||
setStart: () => {},
|
||||
setEnd: () => {},
|
||||
commonAncestorContainer: {
|
||||
nodeName: 'BODY',
|
||||
ownerDocument: document,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
32
src/store.js
32
src/store.js
@ -1,17 +1,17 @@
|
||||
import { createStore } from 'redux'
|
||||
|
||||
const initialState = {
|
||||
sidebarShow: 'responsive'
|
||||
}
|
||||
|
||||
const changeState = (state = initialState, { type, ...rest }) => {
|
||||
switch (type) {
|
||||
case 'set':
|
||||
return {...state, ...rest }
|
||||
default:
|
||||
return state
|
||||
}
|
||||
}
|
||||
|
||||
const store = createStore(changeState)
|
||||
import { createStore } from 'redux'
|
||||
|
||||
const initialState = {
|
||||
sidebarShow: 'responsive'
|
||||
}
|
||||
|
||||
const changeState = (state = initialState, { type, ...rest }) => {
|
||||
switch (type) {
|
||||
case 'set':
|
||||
return {...state, ...rest }
|
||||
default:
|
||||
return state
|
||||
}
|
||||
}
|
||||
|
||||
const store = createStore(changeState)
|
||||
export default store
|
||||
@ -1,300 +1,300 @@
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import axios from 'axios';
|
||||
import {
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardHeader,
|
||||
CCol,
|
||||
CRow,
|
||||
CDropdown,
|
||||
CDropdownDivider,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
/////
|
||||
CButton,
|
||||
CCardFooter,
|
||||
CForm,
|
||||
CFormGroup,
|
||||
CFormText,
|
||||
CTextarea,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CInputCheckbox,
|
||||
CInputRadio,
|
||||
CLabel,
|
||||
CSelect,
|
||||
CSwitch,
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
import DatePicker from "react-datepicker";
|
||||
import "react-datepicker/dist/react-datepicker.css";
|
||||
|
||||
function Index() {
|
||||
|
||||
const baseUrl = "https://natnats.mobilous.com/";
|
||||
|
||||
|
||||
const [data, setData] = useState([]);
|
||||
const [report, setReport] = useState('');
|
||||
const [selectedcons, setSelectedCons] = useState('');
|
||||
const [graph, setGraph] = useState(false);
|
||||
|
||||
const [startDate, setStartDate] = useState(null);
|
||||
const [validDates, setValidDates] = useState([]);
|
||||
const [downloadUrl, setDownloadUrl] = useState('');
|
||||
|
||||
useEffect(() => {
|
||||
async function fetchData() {
|
||||
// You can await here
|
||||
const result = await axios('https://natnats.mobilous.com/getConstructionList');
|
||||
setData(result.data);
|
||||
}
|
||||
fetchData();
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
async function fetchData() {
|
||||
// You can await here
|
||||
if(selectedcons !== "" && report !== "" && isDate() == true) {
|
||||
const result = await axios('https://fbssso.ts.bizside.biz/getDateToHaveData?construction_id=' + selectedcons + '&sheetname=' + report);
|
||||
setValidDates(result.data.record);
|
||||
}
|
||||
}
|
||||
fetchData();
|
||||
}, [report, selectedcons]);
|
||||
|
||||
function getDateWithFormat(date) {
|
||||
var thisDate = date;
|
||||
var dd = String(date.getDate()).padStart(2, '0');
|
||||
var mm = String(date.getMonth() + 1).padStart(2, '0'); //January is 0!
|
||||
var yyyy = date.getFullYear();
|
||||
|
||||
thisDate = yyyy + '-' + mm + '-' + dd
|
||||
return thisDate;
|
||||
}
|
||||
|
||||
function setingReport(e){
|
||||
setReport(e.target.value);
|
||||
setStartDate(null);
|
||||
setDownloadUrl('');
|
||||
}
|
||||
|
||||
function setingSelectedCons(e) {
|
||||
setSelectedCons(e.target.value);
|
||||
setStartDate(null);
|
||||
setDownloadUrl('');
|
||||
}
|
||||
|
||||
function setingGraph(e){
|
||||
console.log("setting report" + downloadUrl);
|
||||
setGraph(e.target.checked);
|
||||
setDownloadUrl('');
|
||||
|
||||
}
|
||||
|
||||
function doGetReport(){
|
||||
console.log(isDownload());
|
||||
console.log(downloadUrl);
|
||||
if(report == "" || selectedcons == ""){
|
||||
alert("建設とレポートの両方を選択してください");
|
||||
return;
|
||||
}
|
||||
var url = "";
|
||||
if(startDate !== null){
|
||||
if(graph){
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+ "&construction_date="+getDateWithFormat(startDate)+"&graph=true";
|
||||
}
|
||||
else{
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+ "&construction_date="+getDateWithFormat(startDate);
|
||||
}
|
||||
setDownloadUrl(url);
|
||||
//downloadReport(url);
|
||||
}
|
||||
else {
|
||||
if(graph){
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+"&graph=true";
|
||||
}
|
||||
else{
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons;
|
||||
}
|
||||
setDownloadUrl(url);
|
||||
//downloadReport(url);
|
||||
}
|
||||
}
|
||||
|
||||
// function downloadReport(url) {
|
||||
// console.log(url);
|
||||
// fetch(url)
|
||||
// .then(response => {
|
||||
// console.log(response)
|
||||
// const filename = response.headers.get('Content-Disposition').split('filename=')[1];
|
||||
// response.blob().then(blob => {
|
||||
// let url = window.URL.createObjectURL(blob);
|
||||
// let a = document.createElement('a');
|
||||
// a.href = url;
|
||||
// a.download = filename;
|
||||
// a.click();
|
||||
// });
|
||||
// });
|
||||
// }
|
||||
|
||||
// function downloadReport(url) {
|
||||
// axios({
|
||||
// url: url, //your url
|
||||
// method: 'GET',
|
||||
// responseType: 'blob', // important
|
||||
// }).then((response) => {
|
||||
// // const url = window.URL.createObjectURL(new Blob([response.data]));
|
||||
// // const link = document.createElement('a');
|
||||
// // link.href = url;
|
||||
// // //link.setAttribute('download', 'file.xls'); //or any other extension
|
||||
// // //document.body.appendChild(link);
|
||||
// // link.click();
|
||||
|
||||
// const filename = response.headers
|
||||
// .get("content-disposition")
|
||||
// .split('"')[1];
|
||||
// const text = response.text();
|
||||
// console.log(filename)
|
||||
// console.log(text)
|
||||
// //return { filename, text };
|
||||
|
||||
// });
|
||||
|
||||
// }
|
||||
|
||||
const checkAvilable = (date) => {
|
||||
if(validDates === undefined){
|
||||
return false;
|
||||
}
|
||||
var thisDate = getDateWithFormat(date);
|
||||
if(validDates.includes(thisDate)){
|
||||
return true;
|
||||
}
|
||||
else{
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
function isDownload() {
|
||||
if(isDate() === false && report !== '' && selectedcons !== '') {
|
||||
return true;
|
||||
}
|
||||
else{
|
||||
if(startDate !== null) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function isDate() {
|
||||
if(report === 'BoxDisplacement' || report === 'MachineControl' || report === 'MachineSheet'){
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol xs="12" sm="12" md="12">
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
レポート
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
|
||||
<CSelect custom name="cons_select" id="cons_select" onChange={setingSelectedCons}>
|
||||
" <option value=''>-- 工事名 --</option>"+
|
||||
{
|
||||
data.map((cc, index) => {
|
||||
return(
|
||||
<option key={cc.construction_id} value={cc.construction_id}>{cc.construction_name}</option>
|
||||
)
|
||||
})
|
||||
}
|
||||
</CSelect>
|
||||
|
||||
<CCard>
|
||||
<CCardBody>
|
||||
<CForm action="" method="post" encType="multipart/form-data" className="form-horizontal">
|
||||
<CFormGroup row>
|
||||
<CCol md="3">
|
||||
<CLabel htmlFor="select">レポート種類</CLabel>
|
||||
</CCol>
|
||||
<CCol xs="12" md="9">
|
||||
<CSelect custom name="select" id="select" onChange={setingReport} value={report}>
|
||||
<option value="">-- レポート種類 --</option>
|
||||
<option value="BoxDisplacement">函体変位表</option>
|
||||
<option value="MachineControl">オープンシールドマシン管理日報</option>
|
||||
<option value="Measurement">函底高・偏位量測定一覧表</option>
|
||||
<option value="CheckSheet">工程内検査表</option>
|
||||
<option value="Injection">裏込注入材料受払い簿</option>
|
||||
</CSelect>
|
||||
</CCol>
|
||||
</CFormGroup>
|
||||
{isDate() === true ?
|
||||
<CFormGroup row>
|
||||
<CCol md="3">
|
||||
<CLabel htmlFor="select">報告日</CLabel>
|
||||
</CCol>
|
||||
<CCol xs="12" md="9">
|
||||
<DatePicker
|
||||
dateFormat="yyyy/MM/dd"
|
||||
selected={startDate}
|
||||
onChange={(date) => setStartDate(date)}
|
||||
filterDate={checkAvilable}
|
||||
placeholderText='日付を選択'
|
||||
/>
|
||||
</CCol>
|
||||
</CFormGroup>
|
||||
:
|
||||
<div></div>
|
||||
}
|
||||
|
||||
{report == 'MachineControl' ?
|
||||
<CFormGroup variant="checkbox" className="checkbox">
|
||||
<CInputCheckbox
|
||||
id="checkbox1"
|
||||
name="checkbox1"
|
||||
checked = {graph}
|
||||
value='graph'
|
||||
onChange={setingGraph}
|
||||
/>
|
||||
<CLabel variant="checkbox" className="form-check-label" htmlFor="checkbox1">グラフの有無</CLabel>
|
||||
</CFormGroup>
|
||||
:
|
||||
("")}
|
||||
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
<CCardFooter>
|
||||
{isDownload() === true ?
|
||||
<p>
|
||||
<CButton type="submit" size="sm" color="primary" onClick={doGetReport}><CIcon name="cil-scrubber" /> ダウンロード</CButton>
|
||||
<br/>
|
||||
{downloadUrl === '' ?
|
||||
<p></p>
|
||||
:
|
||||
<a href={downloadUrl}>Download</a>
|
||||
}
|
||||
</p>
|
||||
:
|
||||
<CButton disabled type="submit" size="sm" color="primary" onClick={doGetReport}><CIcon name="cil-scrubber" /> ダウンロード</CButton>
|
||||
}
|
||||
</CCardFooter>
|
||||
</CCard>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
<CCol xs="1" sm="1" md="1">
|
||||
</CCol>
|
||||
</CRow>
|
||||
);
|
||||
}
|
||||
|
||||
export default Index
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import axios from 'axios';
|
||||
import {
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardHeader,
|
||||
CCol,
|
||||
CRow,
|
||||
CDropdown,
|
||||
CDropdownDivider,
|
||||
CDropdownItem,
|
||||
CDropdownMenu,
|
||||
CDropdownToggle,
|
||||
/////
|
||||
CButton,
|
||||
CCardFooter,
|
||||
CForm,
|
||||
CFormGroup,
|
||||
CFormText,
|
||||
CTextarea,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CInputCheckbox,
|
||||
CInputRadio,
|
||||
CLabel,
|
||||
CSelect,
|
||||
CSwitch,
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
import DatePicker from "react-datepicker";
|
||||
import "react-datepicker/dist/react-datepicker.css";
|
||||
|
||||
function Index() {
|
||||
|
||||
const baseUrl = "https://natnats.mobilous.com/";
|
||||
|
||||
|
||||
const [data, setData] = useState([]);
|
||||
const [report, setReport] = useState('');
|
||||
const [selectedcons, setSelectedCons] = useState('');
|
||||
const [graph, setGraph] = useState(false);
|
||||
|
||||
const [startDate, setStartDate] = useState(null);
|
||||
const [validDates, setValidDates] = useState([]);
|
||||
const [downloadUrl, setDownloadUrl] = useState('');
|
||||
|
||||
useEffect(() => {
|
||||
async function fetchData() {
|
||||
// You can await here
|
||||
const result = await axios('https://natnats.mobilous.com/getConstructionList');
|
||||
setData(result.data);
|
||||
}
|
||||
fetchData();
|
||||
}, []);
|
||||
|
||||
useEffect(() => {
|
||||
async function fetchData() {
|
||||
// You can await here
|
||||
if(selectedcons !== "" && report !== "" && isDate() == true) {
|
||||
const result = await axios('https://fbssso.ts.bizside.biz/getDateToHaveData?construction_id=' + selectedcons + '&sheetname=' + report);
|
||||
setValidDates(result.data.record);
|
||||
}
|
||||
}
|
||||
fetchData();
|
||||
}, [report, selectedcons]);
|
||||
|
||||
function getDateWithFormat(date) {
|
||||
var thisDate = date;
|
||||
var dd = String(date.getDate()).padStart(2, '0');
|
||||
var mm = String(date.getMonth() + 1).padStart(2, '0'); //January is 0!
|
||||
var yyyy = date.getFullYear();
|
||||
|
||||
thisDate = yyyy + '-' + mm + '-' + dd
|
||||
return thisDate;
|
||||
}
|
||||
|
||||
function setingReport(e){
|
||||
setReport(e.target.value);
|
||||
setStartDate(null);
|
||||
setDownloadUrl('');
|
||||
}
|
||||
|
||||
function setingSelectedCons(e) {
|
||||
setSelectedCons(e.target.value);
|
||||
setStartDate(null);
|
||||
setDownloadUrl('');
|
||||
}
|
||||
|
||||
function setingGraph(e){
|
||||
console.log("setting report" + downloadUrl);
|
||||
setGraph(e.target.checked);
|
||||
setDownloadUrl('');
|
||||
|
||||
}
|
||||
|
||||
function doGetReport(){
|
||||
console.log(isDownload());
|
||||
console.log(downloadUrl);
|
||||
if(report == "" || selectedcons == ""){
|
||||
alert("建設とレポートの両方を選択してください");
|
||||
return;
|
||||
}
|
||||
var url = "";
|
||||
if(startDate !== null){
|
||||
if(graph){
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+ "&construction_date="+getDateWithFormat(startDate)+"&graph=true";
|
||||
}
|
||||
else{
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+ "&construction_date="+getDateWithFormat(startDate);
|
||||
}
|
||||
setDownloadUrl(url);
|
||||
//downloadReport(url);
|
||||
}
|
||||
else {
|
||||
if(graph){
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons+"&graph=true";
|
||||
}
|
||||
else{
|
||||
url = baseUrl + "/generate" + report + "?construction_id=" +selectedcons;
|
||||
}
|
||||
setDownloadUrl(url);
|
||||
//downloadReport(url);
|
||||
}
|
||||
}
|
||||
|
||||
// function downloadReport(url) {
|
||||
// console.log(url);
|
||||
// fetch(url)
|
||||
// .then(response => {
|
||||
// console.log(response)
|
||||
// const filename = response.headers.get('Content-Disposition').split('filename=')[1];
|
||||
// response.blob().then(blob => {
|
||||
// let url = window.URL.createObjectURL(blob);
|
||||
// let a = document.createElement('a');
|
||||
// a.href = url;
|
||||
// a.download = filename;
|
||||
// a.click();
|
||||
// });
|
||||
// });
|
||||
// }
|
||||
|
||||
// function downloadReport(url) {
|
||||
// axios({
|
||||
// url: url, //your url
|
||||
// method: 'GET',
|
||||
// responseType: 'blob', // important
|
||||
// }).then((response) => {
|
||||
// // const url = window.URL.createObjectURL(new Blob([response.data]));
|
||||
// // const link = document.createElement('a');
|
||||
// // link.href = url;
|
||||
// // //link.setAttribute('download', 'file.xls'); //or any other extension
|
||||
// // //document.body.appendChild(link);
|
||||
// // link.click();
|
||||
|
||||
// const filename = response.headers
|
||||
// .get("content-disposition")
|
||||
// .split('"')[1];
|
||||
// const text = response.text();
|
||||
// console.log(filename)
|
||||
// console.log(text)
|
||||
// //return { filename, text };
|
||||
|
||||
// });
|
||||
|
||||
// }
|
||||
|
||||
const checkAvilable = (date) => {
|
||||
if(validDates === undefined){
|
||||
return false;
|
||||
}
|
||||
var thisDate = getDateWithFormat(date);
|
||||
if(validDates.includes(thisDate)){
|
||||
return true;
|
||||
}
|
||||
else{
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
function isDownload() {
|
||||
if(isDate() === false && report !== '' && selectedcons !== '') {
|
||||
return true;
|
||||
}
|
||||
else{
|
||||
if(startDate !== null) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function isDate() {
|
||||
if(report === 'BoxDisplacement' || report === 'MachineControl' || report === 'MachineSheet'){
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol xs="12" sm="12" md="12">
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
レポート
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
|
||||
<CSelect custom name="cons_select" id="cons_select" onChange={setingSelectedCons}>
|
||||
" <option value=''>-- 工事名 --</option>"+
|
||||
{
|
||||
data.map((cc, index) => {
|
||||
return(
|
||||
<option key={cc.construction_id} value={cc.construction_id}>{cc.construction_name}</option>
|
||||
)
|
||||
})
|
||||
}
|
||||
</CSelect>
|
||||
|
||||
<CCard>
|
||||
<CCardBody>
|
||||
<CForm action="" method="post" encType="multipart/form-data" className="form-horizontal">
|
||||
<CFormGroup row>
|
||||
<CCol md="3">
|
||||
<CLabel htmlFor="select">レポート種類</CLabel>
|
||||
</CCol>
|
||||
<CCol xs="12" md="9">
|
||||
<CSelect custom name="select" id="select" onChange={setingReport} value={report}>
|
||||
<option value="">-- レポート種類 --</option>
|
||||
<option value="BoxDisplacement">函体変位表</option>
|
||||
<option value="MachineControl">オープンシールドマシン管理日報</option>
|
||||
<option value="Measurement">函底高・偏位量測定一覧表</option>
|
||||
<option value="CheckSheet">工程内検査表</option>
|
||||
<option value="Injection">裏込注入材料受払い簿</option>
|
||||
</CSelect>
|
||||
</CCol>
|
||||
</CFormGroup>
|
||||
{isDate() === true ?
|
||||
<CFormGroup row>
|
||||
<CCol md="3">
|
||||
<CLabel htmlFor="select">報告日</CLabel>
|
||||
</CCol>
|
||||
<CCol xs="12" md="9">
|
||||
<DatePicker
|
||||
dateFormat="yyyy/MM/dd"
|
||||
selected={startDate}
|
||||
onChange={(date) => setStartDate(date)}
|
||||
filterDate={checkAvilable}
|
||||
placeholderText='日付を選択'
|
||||
/>
|
||||
</CCol>
|
||||
</CFormGroup>
|
||||
:
|
||||
<div></div>
|
||||
}
|
||||
|
||||
{report == 'MachineControl' ?
|
||||
<CFormGroup variant="checkbox" className="checkbox">
|
||||
<CInputCheckbox
|
||||
id="checkbox1"
|
||||
name="checkbox1"
|
||||
checked = {graph}
|
||||
value='graph'
|
||||
onChange={setingGraph}
|
||||
/>
|
||||
<CLabel variant="checkbox" className="form-check-label" htmlFor="checkbox1">グラフの有無</CLabel>
|
||||
</CFormGroup>
|
||||
:
|
||||
("")}
|
||||
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
<CCardFooter>
|
||||
{isDownload() === true ?
|
||||
<p>
|
||||
<CButton type="submit" size="sm" color="primary" onClick={doGetReport}><CIcon name="cil-scrubber" /> ダウンロード</CButton>
|
||||
<br/>
|
||||
{downloadUrl === '' ?
|
||||
<p></p>
|
||||
:
|
||||
<a href={downloadUrl}>Download</a>
|
||||
}
|
||||
</p>
|
||||
:
|
||||
<CButton disabled type="submit" size="sm" color="primary" onClick={doGetReport}><CIcon name="cil-scrubber" /> ダウンロード</CButton>
|
||||
}
|
||||
</CCardFooter>
|
||||
</CCard>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
<CCol xs="1" sm="1" md="1">
|
||||
</CCol>
|
||||
</CRow>
|
||||
);
|
||||
}
|
||||
|
||||
export default Index
|
||||
|
||||
@ -1,17 +1,17 @@
|
||||
import React from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
|
||||
function Injecttion(props) {
|
||||
return (
|
||||
<div>
|
||||
Injection
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Injecttion.propTypes = {
|
||||
|
||||
}
|
||||
|
||||
export default Injecttion
|
||||
|
||||
import React from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
|
||||
function Injecttion(props) {
|
||||
return (
|
||||
<div>
|
||||
Injection
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Injecttion.propTypes = {
|
||||
|
||||
}
|
||||
|
||||
export default Injecttion
|
||||
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import React from 'react'
|
||||
|
||||
function MachineControl() {
|
||||
return (
|
||||
<div>
|
||||
Machine Control
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default MachineControl
|
||||
import React from 'react'
|
||||
|
||||
function MachineControl() {
|
||||
return (
|
||||
<div>
|
||||
Machine Control
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default MachineControl
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import React from 'react'
|
||||
|
||||
function MachineSheet() {
|
||||
return (
|
||||
<div>
|
||||
Machine Sheet
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default MachineSheet
|
||||
import React from 'react'
|
||||
|
||||
function MachineSheet() {
|
||||
return (
|
||||
<div>
|
||||
Machine Sheet
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default MachineSheet
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import React from 'react'
|
||||
|
||||
function index() {
|
||||
return (
|
||||
<div>
|
||||
Measurement
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default index
|
||||
import React from 'react'
|
||||
|
||||
function index() {
|
||||
return (
|
||||
<div>
|
||||
Measurement
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default index
|
||||
|
||||
@ -1,86 +1,86 @@
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import axios from 'axios';
|
||||
import {
|
||||
CCol,
|
||||
CFormGroup,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CLabel,
|
||||
CButton,
|
||||
CCard,
|
||||
CCardHeader,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
|
||||
function Uploader(props) {
|
||||
|
||||
const [file, setFile] = useState(null);
|
||||
|
||||
function onChangeHandler(e) {
|
||||
setFile(e.target.files[0])
|
||||
}
|
||||
|
||||
function onClickHandler(e) {
|
||||
let data = new FormData()
|
||||
data.append('file', file);
|
||||
const chk = file.name.trim();
|
||||
const collator = new Intl.Collator('ja');
|
||||
const order1 = collator.compare('ini_工程内検査票.xlsx', chk);
|
||||
const order2 = collator.compare('ini_データ入力シート.xlsx', chk);
|
||||
if(order1 === 0 || order2 === 0)
|
||||
{
|
||||
// axios.post("https://fsbsso.sumasen.net/upload?email=" + props.email, {
|
||||
// body: data,
|
||||
// headers: {'Content-Type': 'multipart/form-data' }
|
||||
// })
|
||||
axios.post("https://fbssso.ts.bizside.biz/upload?email=" + props.email, data)
|
||||
.then(res => { // then print response status
|
||||
console.log(res.statusText)
|
||||
if (res.statusText == 'OK') {
|
||||
alert("正常にアップロードされました");
|
||||
}
|
||||
else if(res.status == 204){
|
||||
alert("初期設定の読み込みに失敗しました");
|
||||
}
|
||||
});
|
||||
}
|
||||
else {
|
||||
alert("指定されたファイル名" + file.name + "が間違っています。ini_工程内検査表.xlsx または ini_データ入力シート.xlsx のどちらかに名前を変更してください。");
|
||||
return
|
||||
}
|
||||
//console.log(file.name);
|
||||
//console.log('calling upload');
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CCard >
|
||||
<CCardHeader>
|
||||
アップロード
|
||||
</CCardHeader>
|
||||
<CCardBody >
|
||||
<CFormGroup row>
|
||||
<CCol md = "3">
|
||||
<CLabel htmlFor = "date-input" > アップロードするファイルを選んでください < /CLabel>
|
||||
</CCol >
|
||||
<CCol xs = "12"md = "9" >
|
||||
<CInputFile type = "file"onChange = { onChangeHandler } id = "file-input" name = "file-input" / >
|
||||
</CCol>
|
||||
</CFormGroup >
|
||||
<CCardFooter >
|
||||
<CButton type = "submit"
|
||||
onClick = { onClickHandler }
|
||||
size = "sm"
|
||||
color = "primary" > < CIcon name = "cil-scrubber" / > アップロード </CButton>
|
||||
</CCardFooter>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Uploader
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import axios from 'axios';
|
||||
import {
|
||||
CCol,
|
||||
CFormGroup,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CLabel,
|
||||
CButton,
|
||||
CCard,
|
||||
CCardHeader,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
|
||||
function Uploader(props) {
|
||||
|
||||
const [file, setFile] = useState(null);
|
||||
|
||||
function onChangeHandler(e) {
|
||||
setFile(e.target.files[0])
|
||||
}
|
||||
|
||||
function onClickHandler(e) {
|
||||
let data = new FormData()
|
||||
data.append('file', file);
|
||||
const chk = file.name.trim();
|
||||
const collator = new Intl.Collator('ja');
|
||||
const order1 = collator.compare('ini_工程内検査票.xlsx', chk);
|
||||
const order2 = collator.compare('ini_データ入力シート.xlsx', chk);
|
||||
if(order1 === 0 || order2 === 0)
|
||||
{
|
||||
// axios.post("https://fsbsso.sumasen.net/upload?email=" + props.email, {
|
||||
// body: data,
|
||||
// headers: {'Content-Type': 'multipart/form-data' }
|
||||
// })
|
||||
axios.post("https://fbssso.ts.bizside.biz/upload?email=" + props.email, data)
|
||||
.then(res => { // then print response status
|
||||
console.log(res.statusText)
|
||||
if (res.statusText == 'OK') {
|
||||
alert("正常にアップロードされました");
|
||||
}
|
||||
else if(res.status == 204){
|
||||
alert("初期設定の読み込みに失敗しました");
|
||||
}
|
||||
});
|
||||
}
|
||||
else {
|
||||
alert("指定されたファイル名" + file.name + "が間違っています。ini_工程内検査表.xlsx または ini_データ入力シート.xlsx のどちらかに名前を変更してください。");
|
||||
return
|
||||
}
|
||||
//console.log(file.name);
|
||||
//console.log('calling upload');
|
||||
|
||||
}
|
||||
|
||||
return (
|
||||
<div>
|
||||
<CCard >
|
||||
<CCardHeader>
|
||||
アップロード
|
||||
</CCardHeader>
|
||||
<CCardBody >
|
||||
<CFormGroup row>
|
||||
<CCol md = "3">
|
||||
<CLabel htmlFor = "date-input" > アップロードするファイルを選んでください < /CLabel>
|
||||
</CCol >
|
||||
<CCol xs = "12"md = "9" >
|
||||
<CInputFile type = "file"onChange = { onChangeHandler } id = "file-input" name = "file-input" / >
|
||||
</CCol>
|
||||
</CFormGroup >
|
||||
<CCardFooter >
|
||||
<CButton type = "submit"
|
||||
onClick = { onClickHandler }
|
||||
size = "sm"
|
||||
color = "primary" > < CIcon name = "cil-scrubber" / > アップロード </CButton>
|
||||
</CCardFooter>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Uploader
|
||||
|
||||
@ -1,36 +1,36 @@
|
||||
import React, { lazy } from 'react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
import {
|
||||
CCol,
|
||||
CFormGroup,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CLabel,
|
||||
CButton,
|
||||
CCard,
|
||||
CCardHeader,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
} from '@coreui/react'
|
||||
|
||||
const Dashboard = (props) => {
|
||||
return (
|
||||
<div >
|
||||
<CCard className="bg-info">
|
||||
<CCardBody >
|
||||
<div className="text-white text-center card bg-info">
|
||||
<div className="card-body">
|
||||
<blockquote className="card-bodyquote">
|
||||
<h3>ワンタイムパスワード :{props.userid}</h3>
|
||||
<a target="_blank" href="https://natnats.mobilous.com/appexe/natnats/23/bin/mobileweb2/index.html#page_44022"><h1>FBS Web app</h1></a>
|
||||
</blockquote>
|
||||
</div>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</div>
|
||||
)
|
||||
|
||||
}
|
||||
|
||||
export default Dashboard
|
||||
import React, { lazy } from 'react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
import {
|
||||
CCol,
|
||||
CFormGroup,
|
||||
CInput,
|
||||
CInputFile,
|
||||
CLabel,
|
||||
CButton,
|
||||
CCard,
|
||||
CCardHeader,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
} from '@coreui/react'
|
||||
|
||||
const Dashboard = (props) => {
|
||||
return (
|
||||
<div >
|
||||
<CCard className="bg-info">
|
||||
<CCardBody >
|
||||
<div className="text-white text-center card bg-info">
|
||||
<div className="card-body">
|
||||
<blockquote className="card-bodyquote">
|
||||
<h3>ワンタイムパスワード :{props.userid}</h3>
|
||||
<a target="_blank" href="https://natnats.mobilous.com/appexe/natnats/23/bin/mobileweb2/index.html#page_44022"><h1>FBS Web app</h1></a>
|
||||
</blockquote>
|
||||
</div>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</div>
|
||||
)
|
||||
|
||||
}
|
||||
|
||||
export default Dashboard
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
import * as React from 'react';
|
||||
|
||||
function Downloader(props) {
|
||||
return (
|
||||
<div style={{display: 'none'}}>
|
||||
<iframe src={props.iframeSrc} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
export default Downloader
|
||||
import * as React from 'react';
|
||||
|
||||
function Downloader(props) {
|
||||
return (
|
||||
<div style={{display: 'none'}}>
|
||||
<iframe src={props.iframeSrc} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
export default Downloader
|
||||
|
||||
@ -1,78 +1,78 @@
|
||||
import React from 'react'
|
||||
import { Link } from 'react-router-dom'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardGroup,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Login = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="8">
|
||||
<CCardGroup>
|
||||
<CCard className="p-4">
|
||||
<CCardBody>
|
||||
<CForm>
|
||||
<h1>Login</h1>
|
||||
<p className="text-muted">Sign In to your account</p>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-user" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Username" autoComplete="username" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-4">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Password" autoComplete="current-password" />
|
||||
</CInputGroup>
|
||||
<CRow>
|
||||
<CCol xs="6">
|
||||
<CButton color="primary" className="px-4">Login</CButton>
|
||||
</CCol>
|
||||
<CCol xs="6" className="text-right">
|
||||
<CButton color="link" className="px-0">Forgot password?</CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
<CCard className="text-white bg-primary py-5 d-md-down-none" style={{ width: '44%' }}>
|
||||
<CCardBody className="text-center">
|
||||
<div>
|
||||
<h2>Sign up</h2>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut
|
||||
labore et dolore magna aliqua.</p>
|
||||
<Link to="/register">
|
||||
<CButton color="primary" className="mt-3" active tabIndex={-1}>Register Now!</CButton>
|
||||
</Link>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCardGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Login
|
||||
import React from 'react'
|
||||
import { Link } from 'react-router-dom'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardGroup,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Login = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="8">
|
||||
<CCardGroup>
|
||||
<CCard className="p-4">
|
||||
<CCardBody>
|
||||
<CForm>
|
||||
<h1>Login</h1>
|
||||
<p className="text-muted">Sign In to your account</p>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-user" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Username" autoComplete="username" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-4">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Password" autoComplete="current-password" />
|
||||
</CInputGroup>
|
||||
<CRow>
|
||||
<CCol xs="6">
|
||||
<CButton color="primary" className="px-4">Login</CButton>
|
||||
</CCol>
|
||||
<CCol xs="6" className="text-right">
|
||||
<CButton color="link" className="px-0">Forgot password?</CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
<CCard className="text-white bg-primary py-5 d-md-down-none" style={{ width: '44%' }}>
|
||||
<CCardBody className="text-center">
|
||||
<div>
|
||||
<h2>Sign up</h2>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut
|
||||
labore et dolore magna aliqua.</p>
|
||||
<Link to="/register">
|
||||
<CButton color="primary" className="mt-3" active tabIndex={-1}>Register Now!</CButton>
|
||||
</Link>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCardGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Login
|
||||
|
||||
@ -1,44 +1,44 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCol,
|
||||
CContainer,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupAppend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Page404 = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="6">
|
||||
<div className="clearfix">
|
||||
<h1 className="float-left display-3 mr-4">404</h1>
|
||||
<h4 className="pt-3">Oops! You{'\''}re lost.</h4>
|
||||
<p className="text-muted float-left">The page you are looking for was not found.</p>
|
||||
</div>
|
||||
<CInputGroup className="input-prepend">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-magnifying-glass" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput size="16" type="text" placeholder="What are you looking for?" />
|
||||
<CInputGroupAppend>
|
||||
<CButton color="info">Search</CButton>
|
||||
</CInputGroupAppend>
|
||||
</CInputGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Page404
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCol,
|
||||
CContainer,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupAppend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Page404 = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="6">
|
||||
<div className="clearfix">
|
||||
<h1 className="float-left display-3 mr-4">404</h1>
|
||||
<h4 className="pt-3">Oops! You{'\''}re lost.</h4>
|
||||
<p className="text-muted float-left">The page you are looking for was not found.</p>
|
||||
</div>
|
||||
<CInputGroup className="input-prepend">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-magnifying-glass" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput size="16" type="text" placeholder="What are you looking for?" />
|
||||
<CInputGroupAppend>
|
||||
<CButton color="info">Search</CButton>
|
||||
</CInputGroupAppend>
|
||||
</CInputGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Page404
|
||||
|
||||
@ -1,44 +1,44 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCol,
|
||||
CContainer,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupAppend,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Page500 = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="6">
|
||||
<span className="clearfix">
|
||||
<h1 className="float-left display-3 mr-4">500</h1>
|
||||
<h4 className="pt-3">Houston, we have a problem!</h4>
|
||||
<p className="text-muted float-left">The page you are looking for is temporarily unavailable.</p>
|
||||
</span>
|
||||
<CInputGroup className="input-prepend">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-magnifying-glass" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput size="16" type="text" placeholder="What are you looking for?" />
|
||||
<CInputGroupAppend>
|
||||
<CButton color="info">Search</CButton>
|
||||
</CInputGroupAppend>
|
||||
</CInputGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Page500
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCol,
|
||||
CContainer,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupAppend,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Page500 = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="6">
|
||||
<span className="clearfix">
|
||||
<h1 className="float-left display-3 mr-4">500</h1>
|
||||
<h4 className="pt-3">Houston, we have a problem!</h4>
|
||||
<p className="text-muted float-left">The page you are looking for is temporarily unavailable.</p>
|
||||
</span>
|
||||
<CInputGroup className="input-prepend">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-magnifying-glass" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput size="16" type="text" placeholder="What are you looking for?" />
|
||||
<CInputGroupAppend>
|
||||
<CButton color="info">Search</CButton>
|
||||
</CInputGroupAppend>
|
||||
</CInputGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Page500
|
||||
|
||||
@ -1,80 +1,80 @@
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Register = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="9" lg="7" xl="6">
|
||||
<CCard className="mx-4">
|
||||
<CCardBody className="p-4">
|
||||
<CForm>
|
||||
<h1>Register</h1>
|
||||
<p className="text-muted">Create your account</p>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-user" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Username" autoComplete="username" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>@</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Email" autoComplete="email" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Password" autoComplete="new-password" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-4">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Repeat password" autoComplete="new-password" />
|
||||
</CInputGroup>
|
||||
<CButton color="success" block>Create Account</CButton>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
<CCardFooter className="p-4">
|
||||
<CRow>
|
||||
<CCol xs="12" sm="6">
|
||||
<CButton className="btn-facebook mb-1" block><span>facebook</span></CButton>
|
||||
</CCol>
|
||||
<CCol xs="12" sm="6">
|
||||
<CButton className="btn-twitter mb-1" block><span>twitter</span></CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CCardFooter>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Register
|
||||
import React from 'react'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardFooter,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
const Register = () => {
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="9" lg="7" xl="6">
|
||||
<CCard className="mx-4">
|
||||
<CCardBody className="p-4">
|
||||
<CForm>
|
||||
<h1>Register</h1>
|
||||
<p className="text-muted">Create your account</p>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-user" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Username" autoComplete="username" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>@</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="text" placeholder="Email" autoComplete="email" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-3">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Password" autoComplete="new-password" />
|
||||
</CInputGroup>
|
||||
<CInputGroup className="mb-4">
|
||||
<CInputGroupPrepend>
|
||||
<CInputGroupText>
|
||||
<CIcon name="cil-lock-locked" />
|
||||
</CInputGroupText>
|
||||
</CInputGroupPrepend>
|
||||
<CInput type="password" placeholder="Repeat password" autoComplete="new-password" />
|
||||
</CInputGroup>
|
||||
<CButton color="success" block>Create Account</CButton>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
<CCardFooter className="p-4">
|
||||
<CRow>
|
||||
<CCol xs="12" sm="6">
|
||||
<CButton className="btn-facebook mb-1" block><span>facebook</span></CButton>
|
||||
</CCol>
|
||||
<CCol xs="12" sm="6">
|
||||
<CButton className="btn-twitter mb-1" block><span>twitter</span></CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CCardFooter>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Register
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import React from 'react'
|
||||
|
||||
function Secret() {
|
||||
return (
|
||||
<div>
|
||||
This is a protected page
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Secret
|
||||
import React from 'react'
|
||||
|
||||
function Secret() {
|
||||
return (
|
||||
<div>
|
||||
This is a protected page
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Secret
|
||||
|
||||
@ -1,63 +1,68 @@
|
||||
import React from 'react'
|
||||
import axios from 'axios';
|
||||
import { Link } from 'react-router-dom'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardGroup,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
function Sso() {
|
||||
|
||||
function launchsso() {
|
||||
console.log("launch sso");
|
||||
window.open("https://fbssso.ts.bizside.biz/Shibboleth.sso/Login", "_self");
|
||||
}
|
||||
|
||||
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="8">
|
||||
<CCardGroup>
|
||||
<CCard className="p-4">
|
||||
<CCardBody>
|
||||
<CForm>
|
||||
<h1>ログイン</h1>
|
||||
<p className="text-muted">SSOでサインインするには、ここをクリックしてください</p>
|
||||
<CRow>
|
||||
<CCol>
|
||||
<CButton color="primary" className="px-4" onClick={launchsso}>SSOでログイン</CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
<CCard className="text-white bg-primary py-5 d-md-down-none" style={{ width: '44%' }}>
|
||||
<CCardBody className="text-center">
|
||||
<div>
|
||||
<h2>ログイン方法</h2>
|
||||
<p>これはSSOログインを使用します。リンクをクリックすると、SSOログインページにリダイレクトされます。</p>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCardGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Sso
|
||||
import React from 'react'
|
||||
import axios from 'axios';
|
||||
import { Link } from 'react-router-dom'
|
||||
import {
|
||||
CButton,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardGroup,
|
||||
CCol,
|
||||
CContainer,
|
||||
CForm,
|
||||
CInput,
|
||||
CInputGroup,
|
||||
CInputGroupPrepend,
|
||||
CInputGroupText,
|
||||
CRow
|
||||
} from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
function Sso() {
|
||||
|
||||
// function launchsso() {
|
||||
// console.log("launch sso");
|
||||
// window.open("https://fbssso.ts.bizside.biz/Shibboleth.sso/Login", "_self");
|
||||
// }
|
||||
|
||||
function launchsso() {
|
||||
console.log("launch sso");
|
||||
window.open("https://fbssso.bizside.biz/Shibboleth.sso/Login", "_self");
|
||||
}
|
||||
|
||||
|
||||
return (
|
||||
<div className="c-app c-default-layout flex-row align-items-center">
|
||||
<CContainer>
|
||||
<CRow className="justify-content-center">
|
||||
<CCol md="8">
|
||||
<CCardGroup>
|
||||
<CCard className="p-4">
|
||||
<CCardBody>
|
||||
<CForm>
|
||||
<h1>ログイン</h1>
|
||||
<p className="text-muted">SSOでサインインするには、ここをクリックしてください</p>
|
||||
<CRow>
|
||||
<CCol>
|
||||
<CButton color="primary" className="px-4" onClick={launchsso}>SSOでログイン</CButton>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CForm>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
<CCard className="text-white bg-primary py-5 d-md-down-none" style={{ width: '44%' }}>
|
||||
<CCardBody className="text-center">
|
||||
<div>
|
||||
<h2>ログイン方法</h2>
|
||||
<p>これはSSOログインを使用します。リンクをクリックすると、SSOログインページにリダイレクトされます。</p>
|
||||
</div>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCardGroup>
|
||||
</CCol>
|
||||
</CRow>
|
||||
</CContainer>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default Sso
|
||||
|
||||
@ -1,41 +1,41 @@
|
||||
import React from 'react'
|
||||
import { CCard, CCardBody, CCardHeader, CCol, CRow } from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
import usersData from './UsersData'
|
||||
|
||||
const User = ({match}) => {
|
||||
const user = usersData.find( user => user.id.toString() === match.params.id)
|
||||
const userDetails = user ? Object.entries(user) :
|
||||
[['id', (<span><CIcon className="text-muted" name="cui-icon-ban" /> Not found</span>)]]
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol lg={6}>
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
User id: {match.params.id}
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
<table className="table table-striped table-hover">
|
||||
<tbody>
|
||||
{
|
||||
userDetails.map(([key, value], index) => {
|
||||
return (
|
||||
<tr key={index.toString()}>
|
||||
<td>{`${key}:`}</td>
|
||||
<td><strong>{value}</strong></td>
|
||||
</tr>
|
||||
)
|
||||
})
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
)
|
||||
}
|
||||
|
||||
export default User
|
||||
import React from 'react'
|
||||
import { CCard, CCardBody, CCardHeader, CCol, CRow } from '@coreui/react'
|
||||
import CIcon from '@coreui/icons-react'
|
||||
|
||||
import usersData from './UsersData'
|
||||
|
||||
const User = ({match}) => {
|
||||
const user = usersData.find( user => user.id.toString() === match.params.id)
|
||||
const userDetails = user ? Object.entries(user) :
|
||||
[['id', (<span><CIcon className="text-muted" name="cui-icon-ban" /> Not found</span>)]]
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol lg={6}>
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
User id: {match.params.id}
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
<table className="table table-striped table-hover">
|
||||
<tbody>
|
||||
{
|
||||
userDetails.map(([key, value], index) => {
|
||||
return (
|
||||
<tr key={index.toString()}>
|
||||
<td>{`${key}:`}</td>
|
||||
<td><strong>{value}</strong></td>
|
||||
</tr>
|
||||
)
|
||||
})
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
)
|
||||
}
|
||||
|
||||
export default User
|
||||
|
||||
@ -1,86 +1,86 @@
|
||||
import React, { useState, useEffect } from 'react'
|
||||
import { useHistory, useLocation } from 'react-router-dom'
|
||||
import {
|
||||
CBadge,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardHeader,
|
||||
CCol,
|
||||
CDataTable,
|
||||
CRow,
|
||||
CPagination
|
||||
} from '@coreui/react'
|
||||
|
||||
import usersData from './UsersData'
|
||||
|
||||
const getBadge = status => {
|
||||
switch (status) {
|
||||
case 'Active': return 'success'
|
||||
case 'Inactive': return 'secondary'
|
||||
case 'Pending': return 'warning'
|
||||
case 'Banned': return 'danger'
|
||||
default: return 'primary'
|
||||
}
|
||||
}
|
||||
|
||||
const Users = () => {
|
||||
const history = useHistory()
|
||||
const queryPage = useLocation().search.match(/page=([0-9]+)/, '')
|
||||
const currentPage = Number(queryPage && queryPage[1] ? queryPage[1] : 1)
|
||||
const [page, setPage] = useState(currentPage)
|
||||
|
||||
const pageChange = newPage => {
|
||||
currentPage !== newPage && history.push(`/users?page=${newPage}`)
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
currentPage !== page && setPage(currentPage)
|
||||
}, [currentPage, page])
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol xl={6}>
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
Users
|
||||
<small className="text-muted"> example</small>
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
<CDataTable
|
||||
items={usersData}
|
||||
fields={[
|
||||
{ key: 'name', _classes: 'font-weight-bold' },
|
||||
'registered', 'role', 'status'
|
||||
]}
|
||||
hover
|
||||
striped
|
||||
itemsPerPage={5}
|
||||
activePage={page}
|
||||
clickableRows
|
||||
onRowClick={(item) => history.push(`/users/${item.id}`)}
|
||||
scopedSlots = {{
|
||||
'status':
|
||||
(item)=>(
|
||||
<td>
|
||||
<CBadge color={getBadge(item.status)}>
|
||||
{item.status}
|
||||
</CBadge>
|
||||
</td>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
<CPagination
|
||||
activePage={page}
|
||||
onActivePageChange={pageChange}
|
||||
pages={5}
|
||||
doubleArrows={false}
|
||||
align="center"
|
||||
/>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
)
|
||||
}
|
||||
|
||||
export default Users
|
||||
import React, { useState, useEffect } from 'react'
|
||||
import { useHistory, useLocation } from 'react-router-dom'
|
||||
import {
|
||||
CBadge,
|
||||
CCard,
|
||||
CCardBody,
|
||||
CCardHeader,
|
||||
CCol,
|
||||
CDataTable,
|
||||
CRow,
|
||||
CPagination
|
||||
} from '@coreui/react'
|
||||
|
||||
import usersData from './UsersData'
|
||||
|
||||
const getBadge = status => {
|
||||
switch (status) {
|
||||
case 'Active': return 'success'
|
||||
case 'Inactive': return 'secondary'
|
||||
case 'Pending': return 'warning'
|
||||
case 'Banned': return 'danger'
|
||||
default: return 'primary'
|
||||
}
|
||||
}
|
||||
|
||||
const Users = () => {
|
||||
const history = useHistory()
|
||||
const queryPage = useLocation().search.match(/page=([0-9]+)/, '')
|
||||
const currentPage = Number(queryPage && queryPage[1] ? queryPage[1] : 1)
|
||||
const [page, setPage] = useState(currentPage)
|
||||
|
||||
const pageChange = newPage => {
|
||||
currentPage !== newPage && history.push(`/users?page=${newPage}`)
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
currentPage !== page && setPage(currentPage)
|
||||
}, [currentPage, page])
|
||||
|
||||
return (
|
||||
<CRow>
|
||||
<CCol xl={6}>
|
||||
<CCard>
|
||||
<CCardHeader>
|
||||
Users
|
||||
<small className="text-muted"> example</small>
|
||||
</CCardHeader>
|
||||
<CCardBody>
|
||||
<CDataTable
|
||||
items={usersData}
|
||||
fields={[
|
||||
{ key: 'name', _classes: 'font-weight-bold' },
|
||||
'registered', 'role', 'status'
|
||||
]}
|
||||
hover
|
||||
striped
|
||||
itemsPerPage={5}
|
||||
activePage={page}
|
||||
clickableRows
|
||||
onRowClick={(item) => history.push(`/users/${item.id}`)}
|
||||
scopedSlots = {{
|
||||
'status':
|
||||
(item)=>(
|
||||
<td>
|
||||
<CBadge color={getBadge(item.status)}>
|
||||
{item.status}
|
||||
</CBadge>
|
||||
</td>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
<CPagination
|
||||
activePage={page}
|
||||
onActivePageChange={pageChange}
|
||||
pages={5}
|
||||
doubleArrows={false}
|
||||
align="center"
|
||||
/>
|
||||
</CCardBody>
|
||||
</CCard>
|
||||
</CCol>
|
||||
</CRow>
|
||||
)
|
||||
}
|
||||
|
||||
export default Users
|
||||
|
||||
@ -1,29 +1,29 @@
|
||||
const usersData = [
|
||||
{id: 0, name: 'John Doe', registered: '2018/01/01', role: 'Guest', status: 'Pending'},
|
||||
{id: 1, name: 'Samppa Nori', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 2, name: 'Estavan Lykos', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 3, name: 'Chetan Mohamed', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 4, name: 'Derick Maximinus', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 5, name: 'Friderik Dávid', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 6, name: 'Yiorgos Avraamu', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 7, name: 'Avram Tarasios', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 8, name: 'Quintin Ed', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 9, name: 'Enéas Kwadwo', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 10, name: 'Agapetus Tadeáš', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 11, name: 'Carwyn Fachtna', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 12, name: 'Nehemiah Tatius', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 13, name: 'Ebbe Gemariah', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 14, name: 'Eustorgios Amulius', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 15, name: 'Leopold Gáspár', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 16, name: 'Pompeius René', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 17, name: 'Paĉjo Jadon', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 18, name: 'Micheal Mercurius', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 19, name: 'Ganesha Dubhghall', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 20, name: 'Hiroto Šimun', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 21, name: 'Vishnu Serghei', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 22, name: 'Zbyněk Phoibos', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 23, name: 'Aulus Agmundr', registered: '2018/01/01', role: 'Member', status: 'Pending'},
|
||||
{id: 42, name: 'Ford Prefect', registered: '2001/05/25', role: 'Alien', status: 'Don\'t panic!'}
|
||||
]
|
||||
|
||||
export default usersData
|
||||
const usersData = [
|
||||
{id: 0, name: 'John Doe', registered: '2018/01/01', role: 'Guest', status: 'Pending'},
|
||||
{id: 1, name: 'Samppa Nori', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 2, name: 'Estavan Lykos', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 3, name: 'Chetan Mohamed', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 4, name: 'Derick Maximinus', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 5, name: 'Friderik Dávid', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 6, name: 'Yiorgos Avraamu', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 7, name: 'Avram Tarasios', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 8, name: 'Quintin Ed', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 9, name: 'Enéas Kwadwo', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 10, name: 'Agapetus Tadeáš', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 11, name: 'Carwyn Fachtna', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 12, name: 'Nehemiah Tatius', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 13, name: 'Ebbe Gemariah', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 14, name: 'Eustorgios Amulius', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 15, name: 'Leopold Gáspár', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 16, name: 'Pompeius René', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 17, name: 'Paĉjo Jadon', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 18, name: 'Micheal Mercurius', registered: '2018/02/01', role: 'Admin', status: 'Inactive'},
|
||||
{id: 19, name: 'Ganesha Dubhghall', registered: '2018/03/01', role: 'Member', status: 'Pending'},
|
||||
{id: 20, name: 'Hiroto Šimun', registered: '2018/01/21', role: 'Staff', status: 'Active'},
|
||||
{id: 21, name: 'Vishnu Serghei', registered: '2018/01/01', role: 'Member', status: 'Active'},
|
||||
{id: 22, name: 'Zbyněk Phoibos', registered: '2018/02/01', role: 'Staff', status: 'Banned'},
|
||||
{id: 23, name: 'Aulus Agmundr', registered: '2018/01/01', role: 'Member', status: 'Pending'},
|
||||
{id: 42, name: 'Ford Prefect', registered: '2001/05/25', role: 'Alien', status: 'Don\'t panic!'}
|
||||
]
|
||||
|
||||
export default usersData
|
||||
|
||||
Reference in New Issue
Block a user