From 3951198256252b8691ff43e4512e7a7df282d76b Mon Sep 17 00:00:00 2001 From: kric_jspark Date: Fri, 24 Oct 2025 10:24:44 +0900 Subject: [PATCH] firts commit --- .gitignore | 31 + README.md | 73 + package.json | 59 + public/favicon.ico | Bin 0 -> 15406 bytes public/favicon_kart.png | Bin 0 -> 381 bytes public/index.html | 19 + public/manifest.json | 15 + public/robots.txt | 3 + server/config/db.js | 9 + server/server.js | 23 + src/App.js | 47 + src/components/AuthRoute.js | 50 + src/components/Bookmark.js | 130 + src/components/BookmarkArea.js | 151 + src/components/Chart.js | 210 + src/components/ChildBox.js | 1012 +++++ src/components/FilterChild.js | 141 + src/components/FilterPopup.js | 140 + src/components/Header.js | 164 + src/components/Icon.js | 75 + src/components/Img.js | 238 ++ src/components/LeftToggle.js | 28 + src/components/Loading.js | 36 + src/components/Select.js | 285 ++ src/components/SpecialEffect.js | 86 + src/components/Table.js | 288 ++ src/index.js | 38 + src/modules/Axios.js | 107 + src/modules/Functions.js | 40 + src/modules/Log.js | 21 + src/modules/SelectProject.js | 50 + src/resources/css/custom.css | 3587 +++++++++++++++++ src/resources/css/guide.css | 229 ++ src/resources/css/media.css | 1653 ++++++++ src/resources/css/reset.css | 97 + src/resources/css/style.css | 5 + src/resources/font/Century Gothic.ttf | Bin 0 -> 137568 bytes src/resources/font/CenturyGothic-Black.TTF | Bin 0 -> 129676 bytes src/resources/font/CenturyGothic-Bold.TTF | Bin 0 -> 55128 bytes src/resources/font/CenturyGothic-Regular.ttf | Bin 0 -> 137568 bytes src/resources/font/GOTHIC.TTF | Bin 0 -> 61280 bytes src/resources/font/GOTHICBI.TTF | Bin 0 -> 139084 bytes src/resources/font/GOTHICI.TTF | Bin 0 -> 62860 bytes src/resources/font/NotoSans-Black.ttf | Bin 0 -> 556500 bytes src/resources/font/NotoSans-Bold.ttf | Bin 0 -> 557380 bytes src/resources/font/NotoSans-Medium.ttf | Bin 0 -> 555264 bytes src/resources/font/NotoSans-Regular.ttf | Bin 0 -> 556216 bytes .../font/centurygothic-bold-webfont.woff | Bin 0 -> 22260 bytes .../font/centurygothic-bold-webfont.woff2 | Bin 0 -> 16432 bytes src/resources/images/acc_arrow_close.png | Bin 0 -> 289 bytes src/resources/images/acc_arrow_close_s.png | Bin 0 -> 238 bytes src/resources/images/acc_arrow_open.png | Bin 0 -> 317 bytes src/resources/images/acc_arrow_open_s.png | Bin 0 -> 331 bytes src/resources/images/arrow_l.png | Bin 0 -> 303 bytes src/resources/images/arrow_r.png | Bin 0 -> 311 bytes src/resources/images/bg/bg_login_1920.svg | 14 + src/resources/images/bg/drop_word.svg | 9 + src/resources/images/btn_left.png | Bin 0 -> 758 bytes src/resources/images/btn_right.png | Bin 0 -> 1907 bytes src/resources/images/ic_banner_36.png | Bin 0 -> 681 bytes src/resources/images/ic_bookmark_14.png | Bin 0 -> 284 bytes src/resources/images/ic_close.png | Bin 0 -> 256 bytes src/resources/images/ic_close_w.png | Bin 0 -> 240 bytes src/resources/images/ic_exports.png | Bin 0 -> 356 bytes src/resources/images/ic_exports_s.png | Bin 0 -> 306 bytes src/resources/images/ic_filter_36.png | Bin 0 -> 618 bytes src/resources/images/ic_filter_pop.png | Bin 0 -> 613 bytes src/resources/images/ic_gnb1_20-1.png | Bin 0 -> 364 bytes src/resources/images/ic_gnb1_20.png | Bin 0 -> 332 bytes src/resources/images/ic_gnb2_20-1.png | Bin 0 -> 550 bytes src/resources/images/ic_gnb2_20.png | Bin 0 -> 517 bytes src/resources/images/ic_gnb3_20-1.png | Bin 0 -> 441 bytes src/resources/images/ic_gnb3_20.png | Bin 0 -> 418 bytes src/resources/images/ic_gnb4_20-1.png | Bin 0 -> 344 bytes src/resources/images/ic_gnb4_20.png | Bin 0 -> 326 bytes src/resources/images/ic_gnb5_20-1.png | Bin 0 -> 399 bytes src/resources/images/ic_gnb5_20.png | Bin 0 -> 387 bytes src/resources/images/ic_gnb6_20-1.png | Bin 0 -> 656 bytes src/resources/images/ic_gnb6_20.png | Bin 0 -> 610 bytes src/resources/images/ic_imports.png | Bin 0 -> 363 bytes src/resources/images/ic_imports_s.png | Bin 0 -> 252 bytes src/resources/images/ic_minus.png | Bin 0 -> 415 bytes src/resources/images/ic_plus.png | Bin 0 -> 233 bytes src/resources/images/ic_plus_bl.png | Bin 0 -> 291 bytes src/resources/images/ic_plus_filter.png | Bin 0 -> 512 bytes src/resources/images/ic_plus_s.png | Bin 0 -> 228 bytes src/resources/images/ic_re.png | Bin 0 -> 527 bytes src/resources/images/ic_reset_16.png | Bin 0 -> 412 bytes src/resources/images/ic_return.png | Bin 0 -> 618 bytes src/resources/images/ico/bx_menu.svg | 3 + src/resources/images/ico/c.svg | 4 + src/resources/images/ico/checkbox_img.svg | 3 + src/resources/images/ico/ic_banner_36-1.svg | 4 + src/resources/images/ico/ic_banner_36-2.svg | 4 + src/resources/images/ico/ic_banner_36.svg | 4 + src/resources/images/ico/ic_copy.svg | 11 + src/resources/images/ico/ic_copy_page.svg | 11 + src/resources/images/ico/ic_copy_url.svg | 11 + src/resources/images/ico/ic_daily_36_new.svg | 6 + src/resources/images/ico/ic_daily_36_old.svg | 6 + src/resources/images/ico/ic_document_36-1.svg | 5 + src/resources/images/ico/ic_document_36-2.svg | 5 + src/resources/images/ico/ic_document_36.svg | 5 + src/resources/images/ico/ic_drop.svg | 3 + src/resources/images/ico/ic_export.svg | 4 + src/resources/images/ico/ic_export2.svg | 4 + src/resources/images/ico/ic_filter_36.svg | 4 + src/resources/images/ico/ic_handle.svg | 8 + src/resources/images/ico/ic_handle_1.svg | 8 + src/resources/images/ico/ic_import.svg | 4 + src/resources/images/ico/ic_pc.svg | 5 + src/resources/images/ico/ic_quota.svg | 5 + src/resources/images/ico/icon_circle.svg | 6 + src/resources/images/ico/icon_circle_old.svg | 6 + .../images/ico/icon_none_bookmark.svg | 5 + src/resources/images/ico/icon_pc.svg | 5 + src/resources/images/ico/old_ic_daily_36.svg | 6 + src/resources/images/ico/word_img.svg | 9 + src/resources/images/kring/boom.png | Bin 0 -> 303275 bytes src/resources/images/kring/kring_1.png | Bin 0 -> 73875 bytes src/resources/images/kring/kring_10.png | Bin 0 -> 75529 bytes src/resources/images/kring/kring_11.png | Bin 0 -> 80209 bytes src/resources/images/kring/kring_2.png | Bin 0 -> 96808 bytes src/resources/images/kring/kring_3.png | Bin 0 -> 78187 bytes src/resources/images/kring/kring_4.png | Bin 0 -> 80977 bytes src/resources/images/kring/kring_5.png | Bin 0 -> 88479 bytes src/resources/images/kring/kring_6.png | Bin 0 -> 76733 bytes src/resources/images/kring/kring_7.png | Bin 0 -> 73050 bytes src/resources/images/kring/kring_8.png | Bin 0 -> 76499 bytes src/resources/images/kring/kring_9.png | Bin 0 -> 97326 bytes src/resources/images/loading.gif | Bin 0 -> 24400 bytes src/resources/images/logo/logo_kart.png | Bin 0 -> 960 bytes src/resources/images/logo/logo_kart.svg | 44 + src/resources/images/logo/logo_kart@2x.png | Bin 0 -> 1706 bytes .../images/logo/logo_kart_vertical.png | Bin 0 -> 959 bytes .../images/logo/logo_kart_vertical.svg | 44 + .../images/logo/logo_kart_vertical@2x.png | Bin 0 -> 1701 bytes src/resources/images/logo_kart.png | Bin 0 -> 973 bytes src/resources/images/select_arrow.png | Bin 0 -> 216 bytes src/resources/images/trash_icon.png | Bin 0 -> 578 bytes src/resources/images/trash_icon_w.png | Bin 0 -> 566 bytes src/resources/images/update_icon.png | Bin 0 -> 373 bytes src/states/Format.js | 46 + src/states/Token.js | 41 + src/views/External.js | 84 + src/views/Login.js | 97 + src/views/Logout.js | 37 + src/views/Main.js | 121 + src/views/Management/Derived.js | 524 +++ src/views/Management/Exim.js | 219 + src/views/Report/Crosstab.js | 494 +++ src/views/Report/Current.js | 320 ++ src/views/Report/Quota.js | 219 + src/views/Report/Tabulation.js | 476 +++ 154 files changed, 12093 insertions(+) create mode 100644 .gitignore create mode 100644 README.md create mode 100644 package.json create mode 100644 public/favicon.ico create mode 100644 public/favicon_kart.png create mode 100644 public/index.html create mode 100644 public/manifest.json create mode 100644 public/robots.txt create mode 100644 server/config/db.js create mode 100644 server/server.js create mode 100644 src/App.js create mode 100644 src/components/AuthRoute.js create mode 100644 src/components/Bookmark.js create mode 100644 src/components/BookmarkArea.js create mode 100644 src/components/Chart.js create mode 100644 src/components/ChildBox.js create mode 100644 src/components/FilterChild.js create mode 100644 src/components/FilterPopup.js create mode 100644 src/components/Header.js create mode 100644 src/components/Icon.js create mode 100644 src/components/Img.js create mode 100644 src/components/LeftToggle.js create mode 100644 src/components/Loading.js create mode 100644 src/components/Select.js create mode 100644 src/components/SpecialEffect.js create mode 100644 src/components/Table.js create mode 100644 src/index.js create mode 100644 src/modules/Axios.js create mode 100644 src/modules/Functions.js create mode 100644 src/modules/Log.js create mode 100644 src/modules/SelectProject.js create mode 100644 src/resources/css/custom.css create mode 100644 src/resources/css/guide.css create mode 100644 src/resources/css/media.css create mode 100644 src/resources/css/reset.css create mode 100644 src/resources/css/style.css create mode 100644 src/resources/font/Century Gothic.ttf create mode 100644 src/resources/font/CenturyGothic-Black.TTF create mode 100644 src/resources/font/CenturyGothic-Bold.TTF create mode 100644 src/resources/font/CenturyGothic-Regular.ttf create mode 100644 src/resources/font/GOTHIC.TTF create mode 100644 src/resources/font/GOTHICBI.TTF create mode 100644 src/resources/font/GOTHICI.TTF create mode 100644 src/resources/font/NotoSans-Black.ttf create mode 100644 src/resources/font/NotoSans-Bold.ttf create mode 100644 src/resources/font/NotoSans-Medium.ttf create mode 100644 src/resources/font/NotoSans-Regular.ttf create mode 100644 src/resources/font/centurygothic-bold-webfont.woff create mode 100644 src/resources/font/centurygothic-bold-webfont.woff2 create mode 100644 src/resources/images/acc_arrow_close.png create mode 100644 src/resources/images/acc_arrow_close_s.png create mode 100644 src/resources/images/acc_arrow_open.png create mode 100644 src/resources/images/acc_arrow_open_s.png create mode 100644 src/resources/images/arrow_l.png create mode 100644 src/resources/images/arrow_r.png create mode 100644 src/resources/images/bg/bg_login_1920.svg create mode 100644 src/resources/images/bg/drop_word.svg create mode 100644 src/resources/images/btn_left.png create mode 100644 src/resources/images/btn_right.png create mode 100644 src/resources/images/ic_banner_36.png create mode 100644 src/resources/images/ic_bookmark_14.png create mode 100644 src/resources/images/ic_close.png create mode 100644 src/resources/images/ic_close_w.png create mode 100644 src/resources/images/ic_exports.png create mode 100644 src/resources/images/ic_exports_s.png create mode 100644 src/resources/images/ic_filter_36.png create mode 100644 src/resources/images/ic_filter_pop.png create mode 100644 src/resources/images/ic_gnb1_20-1.png create mode 100644 src/resources/images/ic_gnb1_20.png create mode 100644 src/resources/images/ic_gnb2_20-1.png create mode 100644 src/resources/images/ic_gnb2_20.png create mode 100644 src/resources/images/ic_gnb3_20-1.png create mode 100644 src/resources/images/ic_gnb3_20.png create mode 100644 src/resources/images/ic_gnb4_20-1.png create mode 100644 src/resources/images/ic_gnb4_20.png create mode 100644 src/resources/images/ic_gnb5_20-1.png create mode 100644 src/resources/images/ic_gnb5_20.png create mode 100644 src/resources/images/ic_gnb6_20-1.png create mode 100644 src/resources/images/ic_gnb6_20.png create mode 100644 src/resources/images/ic_imports.png create mode 100644 src/resources/images/ic_imports_s.png create mode 100644 src/resources/images/ic_minus.png create mode 100644 src/resources/images/ic_plus.png create mode 100644 src/resources/images/ic_plus_bl.png create mode 100644 src/resources/images/ic_plus_filter.png create mode 100644 src/resources/images/ic_plus_s.png create mode 100644 src/resources/images/ic_re.png create mode 100644 src/resources/images/ic_reset_16.png create mode 100644 src/resources/images/ic_return.png create mode 100644 src/resources/images/ico/bx_menu.svg create mode 100644 src/resources/images/ico/c.svg create mode 100644 src/resources/images/ico/checkbox_img.svg create mode 100644 src/resources/images/ico/ic_banner_36-1.svg create mode 100644 src/resources/images/ico/ic_banner_36-2.svg create mode 100644 src/resources/images/ico/ic_banner_36.svg create mode 100644 src/resources/images/ico/ic_copy.svg create mode 100644 src/resources/images/ico/ic_copy_page.svg create mode 100644 src/resources/images/ico/ic_copy_url.svg create mode 100644 src/resources/images/ico/ic_daily_36_new.svg create mode 100644 src/resources/images/ico/ic_daily_36_old.svg create mode 100644 src/resources/images/ico/ic_document_36-1.svg create mode 100644 src/resources/images/ico/ic_document_36-2.svg create mode 100644 src/resources/images/ico/ic_document_36.svg create mode 100644 src/resources/images/ico/ic_drop.svg create mode 100644 src/resources/images/ico/ic_export.svg create mode 100644 src/resources/images/ico/ic_export2.svg create mode 100644 src/resources/images/ico/ic_filter_36.svg create mode 100644 src/resources/images/ico/ic_handle.svg create mode 100644 src/resources/images/ico/ic_handle_1.svg create mode 100644 src/resources/images/ico/ic_import.svg create mode 100644 src/resources/images/ico/ic_pc.svg create mode 100644 src/resources/images/ico/ic_quota.svg create mode 100644 src/resources/images/ico/icon_circle.svg create mode 100644 src/resources/images/ico/icon_circle_old.svg create mode 100644 src/resources/images/ico/icon_none_bookmark.svg create mode 100644 src/resources/images/ico/icon_pc.svg create mode 100644 src/resources/images/ico/old_ic_daily_36.svg create mode 100644 src/resources/images/ico/word_img.svg create mode 100644 src/resources/images/kring/boom.png create mode 100644 src/resources/images/kring/kring_1.png create mode 100644 src/resources/images/kring/kring_10.png create mode 100644 src/resources/images/kring/kring_11.png create mode 100644 src/resources/images/kring/kring_2.png create mode 100644 src/resources/images/kring/kring_3.png create mode 100644 src/resources/images/kring/kring_4.png create mode 100644 src/resources/images/kring/kring_5.png create mode 100644 src/resources/images/kring/kring_6.png create mode 100644 src/resources/images/kring/kring_7.png create mode 100644 src/resources/images/kring/kring_8.png create mode 100644 src/resources/images/kring/kring_9.png create mode 100644 src/resources/images/loading.gif create mode 100644 src/resources/images/logo/logo_kart.png create mode 100644 src/resources/images/logo/logo_kart.svg create mode 100644 src/resources/images/logo/logo_kart@2x.png create mode 100644 src/resources/images/logo/logo_kart_vertical.png create mode 100644 src/resources/images/logo/logo_kart_vertical.svg create mode 100644 src/resources/images/logo/logo_kart_vertical@2x.png create mode 100644 src/resources/images/logo_kart.png create mode 100644 src/resources/images/select_arrow.png create mode 100644 src/resources/images/trash_icon.png create mode 100644 src/resources/images/trash_icon_w.png create mode 100644 src/resources/images/update_icon.png create mode 100644 src/states/Format.js create mode 100644 src/states/Token.js create mode 100644 src/views/External.js create mode 100644 src/views/Login.js create mode 100644 src/views/Logout.js create mode 100644 src/views/Main.js create mode 100644 src/views/Management/Derived.js create mode 100644 src/views/Management/Exim.js create mode 100644 src/views/Report/Crosstab.js create mode 100644 src/views/Report/Current.js create mode 100644 src/views/Report/Quota.js create mode 100644 src/views/Report/Tabulation.js diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4b98026 --- /dev/null +++ b/.gitignore @@ -0,0 +1,31 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +.cursor/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? + +# lock 파일 업데이트 방지 +pnpm-lock.yaml +package-lock.json +yarn.lock +tsconfig.node.tsbuildinfo \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..92c9a93 --- /dev/null +++ b/README.md @@ -0,0 +1,73 @@ +# Getting Started with Create React App + +This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app). + +## Available Scripts + +In the project directory, you can run: + +### `npm start` + +Runs the app in the development mode.\ +Open [http://localhost:3000](http://localhost:3000) to view it in your browser. + +The page will reload when you make changes.\ +You may also see any lint errors in the console. + +### `npm test` + +Launches the test runner in the interactive watch mode.\ +See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information. + +### `npm run build` + +Builds the app for production to the `build` folder.\ +It correctly bundles React in production mode and optimizes the build for the best performance. + +The build is minified and the filenames include the hashes.\ +Your app is ready to be deployed! + +See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information. + +### `npm run eject` + +**Note: this is a one-way operation. Once you `eject`, you can't go back!** + +If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. + +Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own. + +You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it. + +## Learn More + +You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started). + +To learn React, check out the [React documentation](https://reactjs.org/). + +### Code Splitting + +This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting) + +### Analyzing the Bundle Size + +This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size) + +### Making a Progressive Web App + +This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app) + +### Advanced Configuration + +This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration) + +### Deployment + +This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment) + +### `npm run build` fails to minify + +This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify) + + +# 2022-07-19 hwkim start \ No newline at end of file diff --git a/package.json b/package.json new file mode 100644 index 0000000..24b0b39 --- /dev/null +++ b/package.json @@ -0,0 +1,59 @@ +{ + "name": "start-areact-app", + "version": "0.1.0", + "private": true, + "dependencies": { + "@testing-library/jest-dom": "^5.16.1", + "@testing-library/react": "^12.1.2", + "@testing-library/user-event": "^13.5.0", + "axios": "^0.27.2", + "chart.js": "^3.9.1", + "chartjs-plugin-zoom": "^1.2.1", + "cors": "^2.8.5", + "echarts": "^5.4.0", + "echarts-for-react": "^3.0.2", + "express": "^4.18.1", + "immutability-helper": "^3.1.1", + "mssql": "^7.3.5", + "react": "^17.0.2", + "react-beautiful-dnd": "^13.1.0", + "react-chartjs-2": "^4.3.1", + "react-device-detect": "^2.2.2", + "react-dnd": "^16.0.1", + "react-dnd-html5-backend": "^16.0.1", + "react-dom": "^17.0.2", + "react-router-dom": "^5.3.3", + "react-scripts": "^5.0.1", + "react-slide-toggle": "^0.3.5", + "react-spinners": "^0.13.4", + "react-wordcloud": "^1.2.7", + "recoil": "^0.7.4", + "recoil-persist": "^4.2.0", + "redux": "^4.1.2", + "web-vitals": "^2.1.4" + }, + "scripts": { + "start": "react-scripts start", + "build": "react-scripts build", + "test": "react-scripts test", + "eject": "react-scripts eject" + }, + "eslintConfig": { + "extends": [ + "react-app", + "react-app/jest" + ] + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" + ], + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + } +} diff --git a/public/favicon.ico b/public/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..9f3d37d1d99a5ea7af78d9885cbd6d012539fcdb GIT binary patch literal 15406 zcmeHNeQZ=!7Jq&u#=nF=NLFU3^^2gJRdl1fn@!YcbhB%W(fE=5V>cQ_H?F%$qs_X> zqSHbJu_}-i5k$e2MQb~SLTOo{l>()fioik(h*c@2#go)->v4a00!tpv=Z~Kqs!U3 zu_0OS^^b02Bj*O$(XOqOH$&!wMzNL5SLsVOT*bQkTiL)+H+y;0b+V4Ys@PeUne@Z_ ze@pv&EFK?cYj!*=%LT3V7HuTUL67IFo+kcoIJ{JrCD9^Zw6ClK`tkS}i;aBC21oi> z$@(j0nT8%1WF4XZs*mqwqhm4l>6ibOWokX^oA)aDXscVZZ!YzzC|g|nOEsVOAJAvoe-$2SjUUj9 zN9mKIZ=j7m$FHCd`o=tyPw6&Fn4dCz{#G{ilA_A#zb}r4R~AJ>Erh+7zQ>U8jXYjP zbx=1`d4fLjerRSS8eT;*VwBW&cKeQj2DE}t(D$pDH!DM>By%)?++<9n-~nDi2K*skrn;lG`(3vJ-9A1Kw^JxZc^3E$q>wvjcB$2b*J_Eo*v$ zr**p@6?`1uE9!nH>weJmI4iEqORYyToce>+*HY@2R^Pza3;Ya?^rw`Ib`tBMsJy*x zv9>N`sqKJqLVO(ixgYsrJr%N#_cpV6m6z$|lPq;?TI1WXz90EmkHr%s8!fK+g(ELv zE4(2SHsJG`%iQ86zxQaZf$zQtV*KBxnK+11v|Ce9cW<5Ed z>*rOS{Q2vzU?=y}cSyCnpjG9g{Xg%nlMuT453z++v(lDNGPvI&WI4T6`Ivtf zY?#SToZc%jw12acVJtY&dgoa_Q(}!w;gc*MJQr>H8T)47sKjvS#3nf|yk#bAE&Me% z8YlUvk2!WA)+I4Cf3YS7yBl9#X8DTrt@Z76@{ zB>5kZuk*h!w$?R1%G26if6()!{_rmC$3@-M4G%ci)%ah)Fq!@*jZMBK5|Fk&4R@4=5x&8|dBXIKFk`-puc`XbZs$JhKd&vwxv%dY-kecaUuz_qKs_ zF?n==CwON=2gZ!^{$BQzX+;&GX9(LsAbjp^kUTFBKn7$%=0xc-HyXZ`Y+XxpROa^f z(1*()S&*4AezF1CdJc`fZhFg@br$U}+Jj_qnRARZ+hOVEt1coQ1!VWL-veHO+y3UV zLj}MRs4ckN341hrdeX2b`Waye6$EJq!aQeE?ViAHwujjV=6JOM#ylUZX5X{7rQ|t- z@9kf!xrvGN%H|t2byNL5#Q#uV(2BSBem&F;Y;N&xuanKqf) zPwn)He+FAa`b?+2DF^$oZRdYv>s#{8;-4gXh|mF8+Cy`E2KrWq@mYPWByO zFH-EqkN#Gjf#h|X`!lqD`{9ue{$e_ZuKKi);sK*J?0sjyVsF*o69hZ23tvO^mn>hb zBU||2*?vFkAMCVYM{Kob-}7Gae4TC`z>IzbADD0#(%A6j8w9m~Y4vP=7r+Ld{E%zP){P!UE z*S8eV-Hc%y_QBy^_RjYEeA&tkKb3WgeUnE$n=F6$XRwuZce67}91}_)o>$kph|ODn zxs7KK`L?>&p3jyi*V)vy6ZQPyUqp9T4xij2V}GInKJVJb&y9k}bE}KJsJUNt#_B}t zgnw}4v@KTNaCk||T!}k5N%uK2ZUben?VFbqe%SX|cRgED`z!Xr?#IaP_VpEKacg(| z(YFjIyE*4saRQG%qtfc|$0I`o}A&i?tITe7Hw8Pm%ge;1!W>kcg<9foW=;QZax z!FCsNLUfYxNR6$X^m4Ypxqn%>@fy}h_Zj1CT>lb3FYM$4( z8-CDYFVb}EEr}l=ID3N*>7NH{#wYv-#EvJ}f5X}RA-aEyH9>uFr*h%OYbUB5xc|m| z&@A}R=<{FpG^+5qFN(EnK~btUB*}w2T zm>J8@%KmZL*4tU{cV7_lgii$j2={#Fr|(D0{UgVZ^N1|%-*HzD_nP5g}5IaJ?=m@e|<3lkNCb)!t|6ZvR=e z85s7HZ`S>W?hJXaZ*K7`;P)Fp+;(swJNfManc(~T=>sp)J-Dq07qAn3pGjKq+5dGp zkB55j@Qfe&jo)Gpe|7WEWx`z=581LDI>4V+>G9t?e&`*)MH}EDEIAoJH__8?j-OvZ zkDNX~5)HxIAve$OgbH})?D?ss1m-1kZq3c}Yqc$~PFuc4&fFhR@#8y}?{BEO$oPAX P-Jel)`0@My+XDXssfrWs literal 0 HcmV?d00001 diff --git a/public/favicon_kart.png b/public/favicon_kart.png new file mode 100644 index 0000000000000000000000000000000000000000..165f6e3fb5858f4920453e64858f1c7c0d4fc56e GIT binary patch literal 381 zcmV-@0fPRCP)TlD%!iFc5`52OdBpcm%cVJc36^CWzdyWFmD|6K@c0 z5M_d>vRZipI~#Zd1!o)$hN6G~&I3+7PKy%IWyVYNa|m8X&T@ui2zSy&Hdx~>N}k96 zt#Lx$SmWA-hzU3)Dtv1f?=u}d`BATn)#uHkAkoLU?yGf*LAA4zm{2E0MC5m}*0V@( zwbr=7zfP`F58+=&mi`F5BuFH0^M5)C5y)T0@tycF<^Jl6+V bj|2Pwor#?&A?DFW00000NkvXXu0mjf1Q4Z8 literal 0 HcmV?d00001 diff --git a/public/index.html b/public/index.html new file mode 100644 index 0000000..bb61bcc --- /dev/null +++ b/public/index.html @@ -0,0 +1,19 @@ + + + + + + + + + + + KART + + +
+ + diff --git a/public/manifest.json b/public/manifest.json new file mode 100644 index 0000000..15d513d --- /dev/null +++ b/public/manifest.json @@ -0,0 +1,15 @@ +{ + "short_name": "KART", + "name": "KRI Analysis Report Tool", + "icons": [ + { + "src": "favicon_kart.png", + "sizes": "64x64 32x32 24x24 16x16", + "type": "image/x-icon" + } + ], + "start_url": ".", + "display": "standalone", + "theme_color": "#1CAE81", + "background_color": "#ffffff" +} diff --git a/public/robots.txt b/public/robots.txt new file mode 100644 index 0000000..e9e57dc --- /dev/null +++ b/public/robots.txt @@ -0,0 +1,3 @@ +# https://www.robotstxt.org/robotstxt.html +User-agent: * +Disallow: diff --git a/server/config/db.js b/server/config/db.js new file mode 100644 index 0000000..1a71cc5 --- /dev/null +++ b/server/config/db.js @@ -0,0 +1,9 @@ +var mssql = require('mssql'); +const db = mssql.createPool({ + host : '10.10.11.7:20022', + user : 'kri', + password : 'kri#51304', + database : 'kon_db' +}); + +module.exports = db; \ No newline at end of file diff --git a/server/server.js b/server/server.js new file mode 100644 index 0000000..55d843e --- /dev/null +++ b/server/server.js @@ -0,0 +1,23 @@ +const express = require('express'); +const app = express(); +const PORT = process.env.PORT || 4000; +const db = require('./config/db'); + +app.listen(PORT, () => { + console.log(`Server On : http://localhost:${PORT}/`); +}) + +//const express = require('express'); +//const path = require('path'); +//const app = express(); +// +//const http = require('http').createServer(app); +//http.listen(8080, function () { +// console.log('listening on 8080') +//}); +// +//app.use(express.static( path.join(__dirname, 'public'))) +// +//app.get('/',function(request, response){ +// response.sendFile( path.join(__dirname, 'public/main.html')) +//}) \ No newline at end of file diff --git a/src/App.js b/src/App.js new file mode 100644 index 0000000..769e67d --- /dev/null +++ b/src/App.js @@ -0,0 +1,47 @@ +import React, {useEffect} from 'react'; +import { Switch, Route, useLocation } from 'react-router-dom'; +import { useSetRecoilState } from 'recoil'; +import { pageState } from './states/Token'; + +import {AuthRoute} from './components/AuthRoute' +import Main from './views/Main'; +import Current from './views/Report/Current'; +import Quota from './views/Report/Quota'; +import Tabulation from './views/Report/Tabulation'; +import Crosstab from './views/Report/Crosstab'; +import Derived from './views/Management/Derived'; +import Exim from './views/Management/Exim'; +import Login from './views/Login'; +import Logout from './views/Logout'; +import External from './views/External'; +import { PageLoading } from './components/Loading'; + +import './resources/css/style.css'; +import { Suspense } from 'react'; + +function App(props) { + const location = useLocation(); + const setIsLoading = useSetRecoilState(pageState); + + useEffect(() => { + setIsLoading(true); + }, [location]); + + return ( + + + + + + + + + + + + + + ) +} + +export default App; \ No newline at end of file diff --git a/src/components/AuthRoute.js b/src/components/AuthRoute.js new file mode 100644 index 0000000..b9afdcf --- /dev/null +++ b/src/components/AuthRoute.js @@ -0,0 +1,50 @@ +import React, { useEffect, useState } from 'react'; +import {Redirect, Route, useHistory, } from 'react-router-dom'; +import { useRecoilValue } from 'recoil'; +import { tokenState, ptokenState } from '../states/Token'; +import {SetOption,SyncAxios,URL_KART_NS} from '../modules/Axios'; + + +export const AuthRoute = (props) => { + const history = useHistory(); + const [isAuth, setIsAuth] = useState(null); + const token = useRecoilValue(tokenState); + const pToken = useRecoilValue(ptokenState); + + useEffect(() =>{ + const url = URL_KART_NS + '/encrypt/authentication'; + const method = 'GET'; + const headers = {'Accept':'application/json', 'Content-Type': 'application/json;charset=UTP-8', "token":token.token}; + const body = {}; + + const options = SetOption(false, url, method, headers, body); + SyncAxios(options).then(response => { + if(response.status === 200){ + setIsAuth(true); + } + else{ + setIsAuth(false); + } + }); + }); + + if(isAuth === null) return null; + if(isAuth === false){ + return ; + } + if(props.useSkey && (pToken.skey === null || pToken.skey === '')){ + history.push("/Logout"); + return + } + else if(props.path === "/" || pToken.onlyPage === 0){ + return + } + else if(pToken.onlyPage === 1){ + if(pToken.path.toLowerCase() === props.path.toLowerCase()){ + return + } + else{ + history.goBack(); + } + } +} \ No newline at end of file diff --git a/src/components/Bookmark.js b/src/components/Bookmark.js new file mode 100644 index 0000000..76e25ca --- /dev/null +++ b/src/components/Bookmark.js @@ -0,0 +1,130 @@ +import React, { useEffect, useState } from 'react'; +import { useRecoilValue } from 'recoil'; +import { tokenState, ptokenState } from '../states/Token'; +import { bookmarkFormat } from '../states/Format'; +import {SetOption,SyncAxios, URL_KART_NS} from '../modules/Axios'; +import Slider from 'react-slick'; +import Img from '../components/Img'; +import 'slick-carousel/slick/slick.css'; +import 'slick-carousel/slick/slick-theme.css'; + +const NextArrow = (props) => { + const { className, style } = props; + return ( +
+ ); + }; + + const PrevArrow = (props) => { + const { className, style } = props; + return ( +
+ ); + }; + +export const BookmarkList = (props) => { + const sliderRef = React.createRef(); + const token = useRecoilValue(tokenState); + const pToken = useRecoilValue(ptokenState); + const [dataList, setdataList] = useState([]); + + let settings = { + className:"slick_width", + infinite: false, + speed: 500, + initialSlide: 0, + slidesToScroll: 2, + variableWidth: true, + prevArrow:, + nextArrow: + }; + + const setBookMarkList = () => { + const url = URL_KART_NS + '/project/bookmark/'+ props.page.toUpperCase(); + const method = 'GET'; + const headers = {'Accept':'application/json', 'Content-Type': 'application/json;charset=UTP-8', "token":token.token, "skey":pToken.skey}; + const body = {}; + const options = SetOption(true, url, method, headers, body); + SyncAxios(options).then(response => { + let responseData = []; + if(response.data.length > 0){ + for(let i = 0; i < response.data.length; i++){ + responseData.push({ + 'id': response.data[i].BOOKMARK_ID, + 'title': response.data[i].BOOKMARK_TITLE, + 'json' : response.data[i].BOOKMARK_JSON, + 'info' : response.data[i].BOOKMARK_INFO, + 'ismine' : response.data[i].IS_MINE, + 'isopen' : response.data[i].IS_OPEN + }); + } + } + + settings["slidesToShow"] = response.data.length; + setdataList(responseData); + }); + } + + useEffect(() => { + if(props.isMobile && dataList.length > 0){ + props.setSelectedBookMark(dataList[0]); + } + },[pToken.skey,dataList]) + + useEffect(() => { + setBookMarkList(); + },[pToken.skey]) + + useEffect(() => { + if(props.isViewBookMark){ + setBookMarkList(); + } + },[props.isViewBookMark]) + + return ( + props.isMobile==false? +
+
+ { + dataList.length < 9 ? null : + {sliderRef.current.slickPrev()}} > + + + } +
+ + + { + dataList.map((data, i) => ( +
{props.setSelectedBookMark(data)}} >{data.title}
+ )) + } + +
+
+ { + dataList.length < 9 ? null : + {sliderRef.current.slickNext()}} > + + + } +
+
+ : +
+
    + { + dataList.map((data, i) => ( +
  • {props.setSelectedBookMark(data)}} >{data.title}
  • + )) + } +
+
+ ); +} diff --git a/src/components/BookmarkArea.js b/src/components/BookmarkArea.js new file mode 100644 index 0000000..51e765e --- /dev/null +++ b/src/components/BookmarkArea.js @@ -0,0 +1,151 @@ +import React, { useEffect, useState } from 'react'; +import { useRecoilValue } from 'recoil'; +import { tokenState, ptokenState } from '../states/Token'; +import { bookmarkFormat,bookmarkJsonFormat } from '../states/Format'; +import {SetOption,SyncAxios,URL_KART_NS} from '../modules/Axios'; +import Img from './Img'; + +export const BookMarkArea = (props) => { + const token = useRecoilValue(tokenState); + const pToken = useRecoilValue(ptokenState); + const [titleValue, setTitleValue] = useState(props.selectedBookMark.title); + const [isChecked, setIsChecked] = useState(false); + const [infoValue, setInfoValue] = useState(props.selectedBookMark.info); + + const changeTitleValue = (e) => { + setTitleValue(e.target.value) + } + + const changeTextValue = (e) => { + setInfoValue(e.target.value) + } + + const updateBookMark = (isCreate) => { + let mode = 'update'; + let bookmarkID = props.selectedBookMark.id; + let bookmarkJson = JSON.parse(JSON.stringify(bookmarkJsonFormat)); + let isOpen = '1'; + let tempBannerArray = []; + + if(bookmarkID ==='' || isCreate){ + mode = 'create'; + bookmarkID = ''; + } + + //banner 정리 + props.selectedBanner.forEach((ele,i)=>{ + if(ele.length > 0){ + tempBannerArray.push(ele.join('|')); + } + }); + + bookmarkJson.INDEX = props.selectedIndex.join(','); + bookmarkJson.BANNER = tempBannerArray.join(','); + bookmarkJson.FILTER_CONDITION = props.filterCondition; + bookmarkJson.REAL_FILTER_CONDITION = props.realFilterCondition; + bookmarkJson.FILTER_ARRAY = props.filterArray; + bookmarkJson.OPTION = JSON.parse(props.optionString); + + if(isChecked){ + isOpen = '0'; + } + + const url = URL_KART_NS + '/project/bookmark/'+mode; + const method = 'POST'; + const headers = {'Accept':'application/json', 'Content-Type': 'application/json;charset=UTP-8', "token":token.token, "skey":pToken.skey}; + const body = { + bookmarkPage: props.page.toUpperCase(), + bookmarkID: bookmarkID, + bookmarkTitle: titleValue, + bookmarkInfo: infoValue, + bookmarkJson: JSON.stringify(bookmarkJson), + isOpen: isOpen + }; + const options = SetOption(true, url, method, headers, body); + SyncAxios(options).then(response => { + if(response.status === 200){ + props.setSelectedBookMark({ + id: response.data, + title: titleValue, + json : JSON.stringify(bookmarkJson), + ismine : "1", + isopen : isOpen, + info : infoValue + }) + props.onClose(false); + } + }); + } + + const deleteBookmark = () => { + if (window.confirm("정말 삭제 하시겠습니까?")) { + let bookmarkID = props.selectedBookMark.id; + const url = URL_KART_NS + '/project/bookmark/delete/'+bookmarkID; + const method = 'POST'; + const headers = {'Accept':'application/json', 'Content-Type': 'application/json;charset=UTP-8', "token":token.token, "skey":pToken.skey}; + const body = {}; + const options = SetOption(true, url, method, headers, body); + SyncAxios(options).then(response => { + if(response.status === 200){ + props.setSelectedBookMark(JSON.parse(JSON.stringify(bookmarkFormat))); + props.onClose(false); + } + }); + } + } + + useEffect(()=>{ + if(props.selectedBookMark.isopen === 1 || props.selectedBookMark.isopen === "1"){ + setIsChecked(false) + } + else{ + setIsChecked(true) + } + },[]) + + return ( +