From 49d7f733e49f56b1174ca54eda416bda7fc21303 Mon Sep 17 00:00:00 2001 From: "peng.peng" Date: Mon, 3 Jul 2023 15:39:21 +0800 Subject: [PATCH] =?UTF-8?q?(*)=E7=A4=BE=E4=BC=9A=E6=B2=BB=E7=90=86?= =?UTF-8?q?=E4=B8=80=E4=BD=93=E5=8C=96=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- super-screen/.babelrc | 19 + super-screen/.vscode/launch.json | 23 + super-screen/.vscode/settings.json | 4 + super-screen/Dockerfile | 21 + super-screen/client/index.ejs | 25 + super-screen/client/index.html | 28 + super-screen/client/index.js | 19 + super-screen/client/src/app.js | 27 + .../client/src/components/Upload/index.js | 316 + .../src/components/UploadLocal/index.js | 339 + .../client/src/components/Uploads/index.js | 391 + .../src/components/buttonGroup/index.js | 51 + .../client/src/components/export/index.js | 683 + .../client/src/components/export/index.less | 13 + super-screen/client/src/components/index.js | 18 + .../src/components/no-resource/index.js | 21 + super-screen/client/src/index.js | 7 + .../client/src/layout/actions/global.js | 27 + .../src/layout/components/footer/index.js | 15 + .../src/layout/components/footer/style.css | 5 + .../src/layout/components/header/index.js | 100 + .../src/layout/components/header/style.css | 41 + .../src/layout/components/sider/index.js | 95 + .../client/src/layout/containers/index.js | 6 + .../layout/containers/layout/breadcrumb.js | 48 + .../src/layout/containers/layout/index.js | 132 + .../src/layout/containers/layout/index.less | 3 + .../src/layout/containers/no-match/index.js | 18 + super-screen/client/src/layout/index.js | 179 + .../src/layout/reducers/ajaxResponse.js | 28 + .../client/src/layout/reducers/global.js | 36 + .../client/src/layout/reducers/index.js | 15 + super-screen/client/src/layout/store/index.js | 16 + .../client/src/layout/store/store.dev.js | 30 + .../client/src/layout/store/store.prod.js | 20 + .../client/src/sections/auth/actions/auth.js | 62 + .../client/src/sections/auth/actions/index.js | 10 + .../src/sections/auth/containers/index.js | 4 + .../src/sections/auth/containers/login.js | 158 + .../client/src/sections/auth/index.js | 12 + .../client/src/sections/auth/reducers/auth.js | 40 + .../src/sections/auth/reducers/index.js | 6 + .../client/src/sections/auth/routes.js | 12 + .../client/src/sections/auth/style.less | 112 + .../src/sections/homePage/actions/example.js | 15 + .../src/sections/homePage/actions/index.js | 7 + .../homePage/components/abnormalMonitoring.js | 49 + .../homePage/components/accessData.js | 36 + .../sections/homePage/components/alarmList.js | 52 + .../sections/homePage/components/centerTop.js | 19 + .../sections/homePage/components/dataShare.js | 54 + .../sections/homePage/components/dataTop5.js | 262 + .../homePage/components/hotspotData.js | 42 + .../homePage/components/nodeResource.js | 39 + .../components/public/carousel-list.js | 33 + .../homePage/components/public/index.less | 80 + .../homePage/components/public/noData.js | 18 + .../components/public/scrollBoard/index.js | 469 + .../components/public/scrollBoard/style.less | 44 + .../homePage/components/public/table-card.js | 34 + .../sections/homePage/components/style.less | 373 + .../src/sections/homePage/components/util.js | 3 + .../sections/homePage/containers/homePage.js | 74 + .../src/sections/homePage/containers/index.js | 6 + .../sections/homePage/containers/style.less | 224 + .../client/src/sections/homePage/index.js | 15 + .../client/src/sections/homePage/nav-item.js | 11 + .../src/sections/homePage/reducers/index.js | 5 + .../client/src/sections/homePage/routes.js | 13 + .../client/src/sections/homePage/style.less | 0 super-screen/client/src/styles/antd.less | 10 + super-screen/client/src/styles/theme.less | 16 + super-screen/client/src/utils/authCode.js | 5 + super-screen/client/src/utils/func.js | 13 + super-screen/client/src/utils/hooks.js | 30 + super-screen/client/src/utils/index.js | 12 + super-screen/client/src/utils/pinyin.js | 131 + super-screen/client/src/utils/region.js | 13961 ++++++++++++++++ super-screen/client/src/utils/webapi.js | 172 + super-screen/config.js | 145 + super-screen/jsconfig.json | 15 + super-screen/middlewares/attachment.js | 23 + super-screen/middlewares/proxy.js | 16 + super-screen/middlewares/webpack-dev.js | 53 + super-screen/package.json | 101 + super-screen/readme.md | 231 + super-screen/routes/attachment/index.js | 240 + super-screen/routes/index.js | 20 + super-screen/server.js | 8 + super-screen/typings/node/node.d.ts | 2599 +++ super-screen/typings/react/react.d.ts | 2517 +++ super-screen/webpack.config.js | 72 + super-screen/webpack.config.prod.js | 76 + 93 files changed, 25678 insertions(+) create mode 100644 super-screen/.babelrc create mode 100644 super-screen/.vscode/launch.json create mode 100644 super-screen/.vscode/settings.json create mode 100644 super-screen/Dockerfile create mode 100644 super-screen/client/index.ejs create mode 100644 super-screen/client/index.html create mode 100644 super-screen/client/index.js create mode 100644 super-screen/client/src/app.js create mode 100644 super-screen/client/src/components/Upload/index.js create mode 100644 super-screen/client/src/components/UploadLocal/index.js create mode 100644 super-screen/client/src/components/Uploads/index.js create mode 100644 super-screen/client/src/components/buttonGroup/index.js create mode 100644 super-screen/client/src/components/export/index.js create mode 100644 super-screen/client/src/components/export/index.less create mode 100644 super-screen/client/src/components/index.js create mode 100644 super-screen/client/src/components/no-resource/index.js create mode 100644 super-screen/client/src/index.js create mode 100644 super-screen/client/src/layout/actions/global.js create mode 100644 super-screen/client/src/layout/components/footer/index.js create mode 100644 super-screen/client/src/layout/components/footer/style.css create mode 100644 super-screen/client/src/layout/components/header/index.js create mode 100644 super-screen/client/src/layout/components/header/style.css create mode 100644 super-screen/client/src/layout/components/sider/index.js create mode 100644 super-screen/client/src/layout/containers/index.js create mode 100644 super-screen/client/src/layout/containers/layout/breadcrumb.js create mode 100644 super-screen/client/src/layout/containers/layout/index.js create mode 100644 super-screen/client/src/layout/containers/layout/index.less create mode 100644 super-screen/client/src/layout/containers/no-match/index.js create mode 100644 super-screen/client/src/layout/index.js create mode 100644 super-screen/client/src/layout/reducers/ajaxResponse.js create mode 100644 super-screen/client/src/layout/reducers/global.js create mode 100644 super-screen/client/src/layout/reducers/index.js create mode 100644 super-screen/client/src/layout/store/index.js create mode 100644 super-screen/client/src/layout/store/store.dev.js create mode 100644 super-screen/client/src/layout/store/store.prod.js create mode 100644 super-screen/client/src/sections/auth/actions/auth.js create mode 100644 super-screen/client/src/sections/auth/actions/index.js create mode 100644 super-screen/client/src/sections/auth/containers/index.js create mode 100644 super-screen/client/src/sections/auth/containers/login.js create mode 100644 super-screen/client/src/sections/auth/index.js create mode 100644 super-screen/client/src/sections/auth/reducers/auth.js create mode 100644 super-screen/client/src/sections/auth/reducers/index.js create mode 100644 super-screen/client/src/sections/auth/routes.js create mode 100644 super-screen/client/src/sections/auth/style.less create mode 100644 super-screen/client/src/sections/homePage/actions/example.js create mode 100644 super-screen/client/src/sections/homePage/actions/index.js create mode 100644 super-screen/client/src/sections/homePage/components/abnormalMonitoring.js create mode 100644 super-screen/client/src/sections/homePage/components/accessData.js create mode 100644 super-screen/client/src/sections/homePage/components/alarmList.js create mode 100644 super-screen/client/src/sections/homePage/components/centerTop.js create mode 100644 super-screen/client/src/sections/homePage/components/dataShare.js create mode 100644 super-screen/client/src/sections/homePage/components/dataTop5.js create mode 100644 super-screen/client/src/sections/homePage/components/hotspotData.js create mode 100644 super-screen/client/src/sections/homePage/components/nodeResource.js create mode 100644 super-screen/client/src/sections/homePage/components/public/carousel-list.js create mode 100644 super-screen/client/src/sections/homePage/components/public/index.less create mode 100644 super-screen/client/src/sections/homePage/components/public/noData.js create mode 100644 super-screen/client/src/sections/homePage/components/public/scrollBoard/index.js create mode 100644 super-screen/client/src/sections/homePage/components/public/scrollBoard/style.less create mode 100644 super-screen/client/src/sections/homePage/components/public/table-card.js create mode 100644 super-screen/client/src/sections/homePage/components/style.less create mode 100644 super-screen/client/src/sections/homePage/components/util.js create mode 100644 super-screen/client/src/sections/homePage/containers/homePage.js create mode 100644 super-screen/client/src/sections/homePage/containers/index.js create mode 100644 super-screen/client/src/sections/homePage/containers/style.less create mode 100644 super-screen/client/src/sections/homePage/index.js create mode 100644 super-screen/client/src/sections/homePage/nav-item.js create mode 100644 super-screen/client/src/sections/homePage/reducers/index.js create mode 100644 super-screen/client/src/sections/homePage/routes.js create mode 100644 super-screen/client/src/sections/homePage/style.less create mode 100644 super-screen/client/src/styles/antd.less create mode 100644 super-screen/client/src/styles/theme.less create mode 100644 super-screen/client/src/utils/authCode.js create mode 100644 super-screen/client/src/utils/func.js create mode 100644 super-screen/client/src/utils/hooks.js create mode 100644 super-screen/client/src/utils/index.js create mode 100644 super-screen/client/src/utils/pinyin.js create mode 100644 super-screen/client/src/utils/region.js create mode 100644 super-screen/client/src/utils/webapi.js create mode 100644 super-screen/config.js create mode 100644 super-screen/jsconfig.json create mode 100644 super-screen/middlewares/attachment.js create mode 100644 super-screen/middlewares/proxy.js create mode 100644 super-screen/middlewares/webpack-dev.js create mode 100644 super-screen/package.json create mode 100644 super-screen/routes/attachment/index.js create mode 100644 super-screen/routes/index.js create mode 100644 super-screen/server.js create mode 100644 super-screen/typings/node/node.d.ts create mode 100644 super-screen/typings/react/react.d.ts create mode 100644 super-screen/webpack.config.js create mode 100644 super-screen/webpack.config.prod.js diff --git a/super-screen/.babelrc b/super-screen/.babelrc new file mode 100644 index 0000000..f3ae610 --- /dev/null +++ b/super-screen/.babelrc @@ -0,0 +1,19 @@ +{ + "presets": [ + "@babel/preset-react", + "@babel/preset-env" + + ], + "plugins": [ + "@babel/plugin-proposal-class-properties", + "@babel/plugin-proposal-object-rest-spread", + ["import", { + "libraryName": "antd", + "libraryDirectory": "es" + + }] + ], + "env": { + "development": {} + } +} diff --git a/super-screen/.vscode/launch.json b/super-screen/.vscode/launch.json new file mode 100644 index 0000000..c8deee5 --- /dev/null +++ b/super-screen/.vscode/launch.json @@ -0,0 +1,23 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Server", + "type": "node", + "request": "launch", + "program": "${workspaceRoot}/server.js", + "args": [ + "-u http://127.0.0.1:4000", + //阿里OSS + "--aliOssAccessKey LTAI5tNDfn7UhStYQcn3JBtw", + "--aliOssSecretKey rnoXtDWQA1djJ5Xqcdn1OSEol0lVyv", + "--aliOssBucket test-c371", + "--aliOssRegion oss-cn-hangzhou", + ], + "outputCapture": "std", + "env": { + "NODE_ENV": "development" + } + } + ] +} \ No newline at end of file diff --git a/super-screen/.vscode/settings.json b/super-screen/.vscode/settings.json new file mode 100644 index 0000000..f5f67f5 --- /dev/null +++ b/super-screen/.vscode/settings.json @@ -0,0 +1,4 @@ +// 将设置放入此文件中以覆盖默认值和用户设置。 +{ + "editor.fontSize": 16, +} \ No newline at end of file diff --git a/super-screen/Dockerfile b/super-screen/Dockerfile new file mode 100644 index 0000000..08dc512 --- /dev/null +++ b/super-screen/Dockerfile @@ -0,0 +1,21 @@ +FROM repository.anxinyun.cn/base-images/nodejs12:20.10.12.2 + +COPY . /var/app + +WORKDIR /var/app + +EXPOSE 8080 + +RUN npm cache clean -f + +RUN npm install --registry http://10.8.30.22:7000 --legacy-peer-deps +RUN npm run build +RUN rm -rf client/src +RUN rm -rf node_modules + +RUN npm install --production --registry http://10.8.30.22:7000 +#RUN npm cache clean -f && npm install --production --force --registry http://10.8.30.22:7000 + +CMD ["-u", "http://localhost:8088"] + +ENTRYPOINT [ "node", "server.js" ] \ No newline at end of file diff --git a/super-screen/client/index.ejs b/super-screen/client/index.ejs new file mode 100644 index 0000000..540b704 --- /dev/null +++ b/super-screen/client/index.ejs @@ -0,0 +1,25 @@ + + + + + + + + + + + +
+ + + \ No newline at end of file diff --git a/super-screen/client/index.html b/super-screen/client/index.html new file mode 100644 index 0000000..28fcdf6 --- /dev/null +++ b/super-screen/client/index.html @@ -0,0 +1,28 @@ + + + + + + + + + + + + +
+ + + + + \ No newline at end of file diff --git a/super-screen/client/index.js b/super-screen/client/index.js new file mode 100644 index 0000000..08eaef8 --- /dev/null +++ b/super-screen/client/index.js @@ -0,0 +1,19 @@ +/** + * User: liuxinyi/liu.xinyi@free-sun.com.cn + * Date: 2016/2/22 + * Time: 15:29 + * + */ +'use strict'; + +const views = require('koa-view'); +const path = require('path'); +module.exports = { + entry: function (app, router, opt) { + app.use(views(__dirname)); + + router.get('(.*)', async function (ctx){ + await ctx.render(path.join(__dirname, './index')); + }); + } +}; \ No newline at end of file diff --git a/super-screen/client/src/app.js b/super-screen/client/src/app.js new file mode 100644 index 0000000..c917bbc --- /dev/null +++ b/super-screen/client/src/app.js @@ -0,0 +1,27 @@ +'use strict'; + +import React, { useEffect } from 'react'; +import Layout from './layout'; +import Auth from './sections/auth'; +import homePage from './sections/homePage'; + +const App = props => { + const { projectName } = props + + useEffect(() => { + document.title = projectName; + }, []) + + return ( + + ) + +} + +export default App; \ No newline at end of file diff --git a/super-screen/client/src/components/Upload/index.js b/super-screen/client/src/components/Upload/index.js new file mode 100644 index 0000000..b9fa031 --- /dev/null +++ b/super-screen/client/src/components/Upload/index.js @@ -0,0 +1,316 @@ +'use strict'; + +import React, { Component } from 'react'; +import { connect } from 'react-redux'; +import { Spin, Upload, message, Modal, Card, Button } from 'antd'; +import moment from 'moment'; +import { PlusOutlined, UploadOutlined, CloseOutlined } from '@ant-design/icons'; + +class Uploads extends Component { + constructor(props) { + super(props); + this.ApiRoot = FS_API_ROOT + this.state = { + fileUploading: false, + fileList: [], + curPreviewPic: '', + delPicIng: false, + removeFilesList: [] + }; + } + + dealName = (uploaded) => { + let realName = uploaded.split('/')[2] + let x1 = realName.split('.') + let x2 = x1[0].split('_') + let showName = `${x2[0]}.${x1[1]}` + return showName + } + + // setFileList = (value) => { + // let defaultFileList = []; + // defaultFileList = value.map((u, index) => { + // let fileUrl = `${this.ApiRoot}/${u.url}`; + // return { + // uid: -index - 1, + // name: this.dealName(u.url), + // status: 'done', + // storageUrl: u.url, + // url: fileUrl + // }; + // }); + // onChange(defaultFileList) + // this.setState({ + // fileList: defaultFileList + // }); + // }; + + componentDidMount () { + const { value } = this.props; + if (value) { + this.setState(value); + } + } + + componentWillReceiveProps (np) { + const { dispatch, value: thisEditData, onChange } = this.props; + const { value: nextEditData } = np; + + const setFileList = () => { + let defaultFileList = []; + defaultFileList = nextEditData.map((u, index) => { + let fileUrl = `${this.ApiRoot}/${u.storageUrl}`; + return { + uid: -index - 1, + name: this.dealName(u.storageUrl), + status: 'done', + storageUrl: u.storageUrl, + url: fileUrl, + size: u.size || -1 + }; + }); + this.setState({ + fileList: defaultFileList + }); + }; + + if (nextEditData && nextEditData.length) { + if (!thisEditData || !this.state.fileList.length) { + setFileList(); + } else if (nextEditData.length != thisEditData.length) { + setFileList(); + } else { + let repeat = true; + for (let i = 0; i < thisEditData.length; i++) { + if (thisEditData[i] != nextEditData[i]) { + repeat = false; + break; + } + } + if (!repeat) { + setFileList(); + } + } + } + // else{ + // this.setState({ + // fileList:[], + // }) + // } + } + + render () { + const UploadPath = { + project: ['txt', 'dwg', 'doc', 'docx', 'xls', 'xlsx', 'pdf', 'png', 'jpg', 'rar', 'zip'], + report: ['doc', 'docx', 'xls', 'xlsx', 'pdf'], + data: ['txt', 'xls', 'xlsx'], + image: ['png', 'jpg', 'svg', 'jpeg'], + three: ['js'], + video: ['mp4'] + }; + /** + * uploadType 【string】 主要区别文件上传路径 以及类型 以 web/routes/attachment/index.js 中 UploadPath 的 key 值为准;默认 project; + * disabled 【boolean】 上传是否可用 + * maxFilesNum 【number】 最大上传数量 + * fileTypes 【array[string]】 可允许上传的文件类型; + * maxFileSize 【number】 单个文件最大大小 M + * listType 【antd】 upload 组件的属性 + * onChange 【function】 文件数量变化时候回调 返回文件 + * value 【array[obj]】 编辑数据 [{url:'xxx', [size:999]}] + * onStateChange 【function】 文件状态改变回调函数 上传中 return { uploading:true/false } + */ + const { + uploadType, + disabled, + maxFilesNum, + fileTypes, + maxFileSize, + listType, + onChange, + value, + showUploadList, + onStateChange + } = this.props; + const { fileList, curPreviewPic, delPicIng, removeFilesList } = this.state; + const that = this; + let uploadType_ = uploadType || 'project'; + let maxFilesNum_ = maxFilesNum || 1; + let defaultFileTypes = fileTypes || UploadPath[uploadType_]; + const uploadProps = { + name: 'checkFile_', + multiple: false, + showUploadList: showUploadList || true, + action: `${this.ApiRoot}/attachments/${uploadType_}`, + listType: listType || 'text', + disabled: disabled, + beforeUpload: (file) => { + if (fileList.length >= maxFilesNum_) { + message.warning(`最多选择${maxFilesNum_}个文件上传`); + return false; + } + if (file.name.length > 60) { + message.warning(`文件名过长(大于60字符),请修改后上传`); + return false; + } + const extNames = file.name.split('.'); + var reg = /^[\.\s\u4e00-\u9fa5a-zA-Z0-9_-]{0,}$/; + if (!reg.exec(file.name)) { + message.warning(`文件名包含除字母、汉字、数字、中划线、下划线之外的字符,请修改后上传`); + return false; + } + let isDAE = false; + if (extNames.length > 0) { + let fileType = extNames[extNames.length - 1].toLowerCase(); + isDAE = defaultFileTypes.some((f) => f == fileType); + } + if (!isDAE) { + message.error(`只能上传 ${defaultFileTypes.join()} 格式的文件!`); + return false; + } + const isLt = file.size / 1024 / 1024 < (maxFileSize || 3); + if (!isLt) { + message.error(`文件必须小于${maxFileSize || 3}MB!`); + return false; + } + this.setState({ + fileUploading: true + }); + if (onStateChange) { + onStateChange({ uploading: true }); + } + }, + onChange (info) { + const status = info.file.status; + if (status === 'uploading') { + that.setState({ + fileList: info.fileList + }); + } + if (status === 'done') { + let { uploaded, url } = info.file.response; + let size = info.file.size; + let nextFileList = fileList; + nextFileList[nextFileList.length - 1] = { + uid: -moment().unix(), + name: that.dealName(uploaded), + status: 'done', + storageUrl: uploaded, + url: url, + size: size + }; + onChange(nextFileList); + that.setState({ + fileUploading: false, + fileList: nextFileList + }); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } else if (status === 'error') { + that.setState({ + fileUploading: false + }); + message.error(`${info.file.name} 上传失败,请重试`); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } + }, + onRemove (file) { + let nextFileList = []; + fileList.map((f, i) => { + if (f.uid != file.uid) { + nextFileList.push(f); + } + }); + let nextRemoveFiles = removeFilesList.concat([file.storageUrl]); + if (curPreviewPic == file.url) { + that.setState({ + curPreviewPic: '' + }); + } + onChange(nextFileList); + that.setState({ + fileList: nextFileList, + removeFilesList: nextRemoveFiles + }); + }, + onPreview (file) { + let filePostfix = file.url.split('.').pop(); + filePostfix = filePostfix.toLowerCase(); + if (UploadPath.image.some((img) => img == filePostfix)) { + that.setState({ + curPreviewPic: file.url + }); + } else { + message.warn('仅支持图片预览'); + } + } + }; + + let fileList_ = fileList + // .map(f => { + // if (f.storageUrl) { + // let realName = f.storageUrl.split('/').pop() + // if (f.name != realName) { + // f.name = realName + // } + // } + // return f + // }) + + return ( +
+ + + { + disabled ? ( + '' + ) : + listType == 'picture-card' ? + ( + fileList.length >= maxFilesNum_ ? null : ( +
+ +
上传图片
+
+ ) + ) : ( + + ) + } +
+ { + curPreviewPic ? ( + +
+ 文件预览 + { this.setState({ curPreviewPic: '' }); }} + > + + +
+ +
+ ) : '' + } +
+
+ ); + } +} + +function mapStateToProps (state) { + const { auth } = state + return { + user: auth.user + }; +} + +export default connect(mapStateToProps)(Uploads); diff --git a/super-screen/client/src/components/UploadLocal/index.js b/super-screen/client/src/components/UploadLocal/index.js new file mode 100644 index 0000000..abd1dfa --- /dev/null +++ b/super-screen/client/src/components/UploadLocal/index.js @@ -0,0 +1,339 @@ +'use strict'; + +import React, { Component } from 'react'; +import { connect } from 'react-redux'; +import { Spin, Upload, message, Modal, Card, Button } from 'antd'; +import moment from 'moment'; +import { PlusOutlined, UploadOutlined, CloseOutlined } from '@ant-design/icons'; +import { RouteRequest } from '@peace/utils'; +import { RouteTable } from '$utils' +const { confirm } = Modal; +class Uploads extends Component { + constructor(props) { + super(props); + this.state = { + fileUploading: false, + fileList: [], + curPreviewPic: '', + delPicIng: false, + removeFilesList: [] + }; + } + dealName = (uploaded) => { + let realName = uploaded.split('/')[2] + let x1 = realName.split('.') + let x2 = x1[0].split('_') + let showName = `${x2[0]}.${x1[1]}` + return showName + } + + // setFileList = (value) => { + // let defaultFileList = []; + // defaultFileList = value.map((u, index) => { + // let fileUrl = `${this.ApiRoot}/${u.url}`; + // return { + // uid: -index - 1, + // name: this.dealName(u.url), + // status: 'done', + // storageUrl: u.url, + // url: fileUrl + // }; + // }); + // onChange(defaultFileList) + // this.setState({ + // fileList: defaultFileList + // }); + // }; + + componentDidMount() { + const { value } = this.props; + if (value) { + // this.setState(value); + this.setState({ fileList: value }) + } + } + + UNSAFE_componentWillReceiveProps(np) { + const { dispatch, value: thisEditData, onChange } = this.props; + const { value: nextEditData } = np; + + const setFileList = () => { + let defaultFileList = []; + defaultFileList = nextEditData.map((u, index) => { + let fileUrl = u.filename; + return { + uid: -index - 1, + name: u.name, + status: 'done', + storageUrl: u.filename, + url: fileUrl, + size: u.size || -1 + }; + }); + this.setState({ + fileList: defaultFileList + }); + }; + + if (nextEditData && nextEditData.length) { + if (!thisEditData || !this.state.fileList.length) { + setFileList(); + } else if (nextEditData.length != thisEditData.length) { + setFileList(); + } else { + let repeat = true; + for (let i = 0; i < thisEditData.length; i++) { + if (thisEditData[i] != nextEditData[i]) { + repeat = false; + break; + } + } + if (!repeat) { + setFileList(); + } + } + } + // else{ + // this.setState({ + // fileList:[], + // }) + // } + } + //删除文件 + deleteFile(file) { + if (file.url) { + RouteRequest.delete(RouteTable.cleanUpUploadTrash, { url: file.url }); + }; + } + handleOk = (that, file, fileList, curPreviewPic, removeFilesList) => { + let nextFileList = []; + fileList.map((f, i) => { + if (f.uid != file.uid) { + nextFileList.push(f); + } + }); + that.deleteFile(file); + let nextRemoveFiles = removeFilesList.concat([file.storageUrl]); + if (curPreviewPic == file.url) { + that.setState({ + curPreviewPic: '' + }); + } + that.props.onChange(nextFileList); + that.setState({ + fileList: nextFileList, + removeFilesList: nextRemoveFiles + }); + } + render() { + const UploadPath = { + project: ['txt', 'dwg', 'doc', 'docx', 'xls', 'xlsx', 'pdf', 'png', 'jpg', 'rar', 'zip'], + report: ['doc', 'docx', 'xls', 'xlsx', 'pdf'], + data: ['txt', 'xls', 'xlsx'], + image: ['png', 'jpg', 'svg', 'jpeg'], + three: ['js'], + video: ['mp4'] + }; + /** + * uploadType 【string】 主要区别文件上传路径 以及类型 以 web/routes/attachment/index.js 中 UploadPath 的 key 值为准;默认 project; + * disabled 【boolean】 上传是否可用 + * maxFilesNum 【number】 最大上传数量 + * fileTypes 【array[string]】 可允许上传的文件类型; + * maxFileSize 【number】 单个文件最大大小 M + * listType 【antd】 upload 组件的属性 + * onChange 【function】 文件数量变化时候回调 返回文件 + * value 【array[obj]】 编辑数据 [{url:'xxx', [size:999]}] + * onStateChange 【function】 文件状态改变回调函数 上传中 return { uploading:true/false } + */ + const { + uploadType, + disabled, + maxFilesNum, + fileTypes, + maxFileSize, + listType, + onChange, + value, + showUploadList, + onStateChange, + addNew + } = this.props; + const { fileList, curPreviewPic, delPicIng, removeFilesList } = this.state; + const that = this; + let uploadType_ = uploadType || 'project'; + let maxFilesNum_ = maxFilesNum || 1; + let defaultFileTypes = fileTypes || UploadPath[uploadType_]; + const uploadProps = { + name: 'checkFile_', + multiple: false, + showUploadList: showUploadList || true, + action: "/_upload/new?type=project", + listType: listType || 'text', + disabled: disabled, + beforeUpload: (file) => { + if (fileList.length >= maxFilesNum_) { + message.warning(`最多选择${maxFilesNum_}个文件上传`); + return false; + } + if (file.name.length > 60) { + message.warning(`文件名过长(大于60字符),请修改后上传`); + return false; + } + const extNames = file.name.split('.'); + var reg = /^[\.\s\u4e00-\u9fa5a-zA-Z0-9_-]{0,}$/; + // if (!reg.exec(file.name)) { + // message.warning(`文件名包含除字母、汉字、数字、中划线、下划线之外的字符,请修改后上传`); + // return false; + // } + let isDAE = false; + if (extNames.length > 0) { + let fileType = extNames[extNames.length - 1].toLowerCase(); + isDAE = defaultFileTypes.some((f) => f == fileType); + } + if (!isDAE) { + message.error(`只能上传 ${defaultFileTypes.join()} 格式的文件!`); + return false; + } + const isLt = file.size / 1024 / 1024 < (maxFileSize || 3); + if (!isLt) { + message.error(`文件必须小于${maxFileSize || 3}MB!`); + return false; + } + this.setState({ + fileUploading: true + }); + if (onStateChange) { + onStateChange({ uploading: true }); + } + }, + onChange(info) { + const status = info.file.status; + if (status === 'uploading') { + that.setState({ + fileList: info.fileList + }); + } + if (status === 'done') { + let { filename, realName } = info.file.response; + let size = info.file.size; + let nextFileList = fileList; + nextFileList[nextFileList.length - 1] = { + uid: -moment().unix(), + name: info.file.name, + status: 'done', + storageUrl: filename, + url: filename, + size: size, + realName: realName + }; + onChange(nextFileList); + that.setState({ + fileUploading: false, + fileList: nextFileList + }); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } else if (status === 'error') { + that.setState({ + fileUploading: false + }); + message.error(`${info.file.name} 上传失败,请重试`); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } + }, + onRemove(file) { + // if (confirm('请确认是否删除此文件?删除后将不可恢复!') === true) { + if (addNew) { + that.handleOk(that, file, fileList, curPreviewPic, removeFilesList); + } else { + confirm({ + title: '请确认是否删除此文件?删除后将不可恢复!', + onOk() { + that.handleOk(that, file, fileList, curPreviewPic, removeFilesList); + }, + onCancel() { }, + }); + } + }, + onPreview(file) { + let filePostfix = file.url.split('.').pop(); + filePostfix = filePostfix.toLowerCase(); + if (UploadPath.image.some((img) => img == filePostfix)) { + that.setState({ + curPreviewPic: file.url + }); + } else { + message.warn('仅支持图片预览'); + } + } + }; + + let fileList_ = fileList + // .map(f => { + // if (f.storageUrl) { + // let realName = f.storageUrl.split('/').pop() + // if (f.name != realName) { + // f.name = realName + // } + // } + // return f + // }) + + return ( +
+ + + { + disabled ? ( + '' + ) : + listType == 'picture-card' ? + ( + fileList.length >= maxFilesNum_ ? null : ( +
+ +
上传图片
+
+ ) + ) : ( + + ) + } +
+ { + curPreviewPic ? ( + +
+ 文件预览 + { this.setState({ curPreviewPic: '' }); }} + > + + +
+ +
+ ) : '' + } +
+
+ ); + } +} + +function mapStateToProps(state) { + const { auth } = state + return { + user: auth.user + }; +} + +export default connect(mapStateToProps)(Uploads); diff --git a/super-screen/client/src/components/Uploads/index.js b/super-screen/client/src/components/Uploads/index.js new file mode 100644 index 0000000..30f1330 --- /dev/null +++ b/super-screen/client/src/components/Uploads/index.js @@ -0,0 +1,391 @@ +'use strict'; + +import React, { Component } from 'react'; +import { connect } from 'react-redux'; +import { Spin, Upload, message, Modal, Card, Button } from 'antd'; +import moment from 'moment'; +import { PlusOutlined, UploadOutlined, CloseOutlined } from '@ant-design/icons'; + +class Uploads extends Component { + constructor(props) { + super(props); + this.ApiRoot = localStorage.getItem('tyApiRoot') + this.qnDomain = localStorage.getItem('qnDomain'); + this.aliAdmin = localStorage.getItem('aliAdmin'); + this.state = { + fileUploading: false, + fileList: [], + curPreviewPic: '', + curPreviewVideo: '', + delPicIng: false, + removeFilesList: [] + }; + } + + dealName = (uploaded) => { + let realName = uploaded.split('/')[2] + // let x1 = realName.split('.') + // let postfix = x1.pop() + // let allName = x1.join('.') + // let x2 = allName.split('_') + // let showName = `${x2[0]}.${postfix}` + return realName + } + + // setFileList = (value) => { + // let defaultFileList = []; + // defaultFileList = value.map((u, index) => { + // let fileUrl = `${this.ApiRoot}/${u.url}`; + // return { + // uid: -index - 1, + // name: this.dealName(u.url), + // status: 'done', + // storageUrl: u.url, + // url: fileUrl + // }; + // }); + // onChange(defaultFileList) + // this.setState({ + // fileList: defaultFileList + // }); + // }; + + setFileList = (nextEditData, isQiniu, isAli) => { + let defaultFileList = []; + if (nextEditData.length) { + defaultFileList = nextEditData.map((u, index) => { + let fileUrl = + isQiniu ? `/_file-server/${u.storageUrl}` + : isAli ? `/_file-ali-server/${u.storageUrl}` + : `${this.ApiRoot}/${u.storageUrl}`; + + return { + uid: -index - 1, + name: this.dealName(u.storageUrl), + status: 'done', + storageUrl: u.storageUrl, + url: fileUrl, + size: u.size || -1 + }; + }); + } + this.setState({ + fileList: defaultFileList + }); + }; + + componentDidMount() { + const { value, defaultValue, isQiniu, isAli } = this.props; + if (defaultValue) { + this.setFileList(defaultValue, isQiniu, isAli) + } + } + + UNSAFE_componentWillReceiveProps(np) { + const { dispatch, value: thisEditData, onChange } = this.props; + const { value: nextEditData, isQiniu, isAli } = np; + // this.setFileList(nextEditData, isQiniu) + // const setFileList = () => { + // let defaultFileList = []; + // defaultFileList = nextEditData.map((u, index) => { + // let fileUrl = isQiniu ? `/_file-server/${u.storageUrl}` : `${this.ApiRoot}/${u.storageUrl}`; + // return { + // uid: -index - 1, + // name: this.dealName(u.storageUrl), + // status: 'done', + // storageUrl: u.storageUrl, + // url: fileUrl, + // size: u.size || -1 + // }; + // }); + // this.setState({ + // fileList: defaultFileList + // }); + // }; + if (nextEditData && nextEditData.length) { + if (!thisEditData || !this.state.fileList.length) { + this.setFileList(nextEditData, isQiniu, isAli); + } else if (nextEditData.length != thisEditData.length) { + this.setFileList(nextEditData, isQiniu, isAli); + } else { + let repeat = true; + for (let i = 0; i < thisEditData.length; i++) { + if (thisEditData[i] != nextEditData[i]) { + repeat = false; + break; + } + } + if (!repeat) { + this.setFileList(nextEditData, isQiniu, isAli); + } + } + } + // else{ + // this.setState({ + // fileList:[], + // }) + // } + } + + render() { + const UploadPath = { + project: ['txt', 'dwg', 'doc', 'docx', 'xls', 'xlsx', 'csv', 'pdf', 'pptx', 'png', 'jpg', 'svg', 'jpeg', 'rar', 'zip', 'jpeg', 'mp4'], + report: ['doc', 'docx', 'xls', 'xlsx', 'csv', 'pdf'], + data: ['txt', 'xls', 'xlsx', 'csv'], + image: ['png', 'jpg', 'svg', 'jpeg'], + three: ['js'], + video: ['mp4'] + }; + /** + * uploadType 【string】 主要区别文件上传路径 以及类型 以 web/routes/attachment/index.js 中 UploadPath 的 key 值为准;默认 project; + * disabled 【boolean】 上传是否可用 + * maxFilesNum 【number】 最大上传数量 + * fileTypes 【array[string]】 可允许上传的文件类型; + * maxFileSize 【number】 单个文件最大大小 M + * listType 【antd】 upload 组件的属性 + * onChange 【function】 文件数量变化时候回调 返回文件 + * value 【array[obj]】 编辑数据 [{url:'xxx', [size:999]}] + * onStateChange 【function】 文件状态改变回调函数 上传中 return { uploading:true/false } + */ + const { + uploadType, + disabled, + maxFilesNum, + fileTypes, + maxFileSize, + listType, + onChange = () => { }, + value, + showUploadList, + onStateChange, + isQiniu, + isAli, + } = this.props; + const { fileList, curPreviewPic, curPreviewVideo, delPicIng, removeFilesList } = this.state; + const that = this; + let uploadType_ = uploadType || 'project'; + let maxFilesNum_ = maxFilesNum || 1; + let defaultFileTypes = fileTypes || UploadPath[uploadType_]; + // debugger + const uploadProps = { + name: 'checkFile_', + multiple: false, + showUploadList: showUploadList || true, + action: + isQiniu ? `/_upload/attachments/${uploadType_}` + : isAli ? `/_upload/attachments/ali/${uploadType_}` + : `${this.ApiRoot}/attachments/${uploadType_}`, + listType: listType || 'text', + disabled: disabled, + beforeUpload: (file) => { + if (fileList.length >= maxFilesNum_) { + message.warning(`最多选择${maxFilesNum_}个文件上传`); + return false; + } + if (file.name.length > 60) { + message.warning(`文件名过长(大于60字符),请修改后上传`); + return false; + } + const extNames = file.name.split('.'); + // var reg = /^[\.\s\u4e00-\u9fa5a-zA-Z0-9_-]{0,}$/; + // if (!reg.exec(file.name)) { + // message.warning(`文件名包含除字母、汉字、数字、中划线、下划线之外的字符,请修改后上传`); + // return false; + // } + let isDAE = false; + if (extNames.length > 0) { + let fileType = extNames[extNames.length - 1].toLowerCase(); + isDAE = defaultFileTypes.some((f) => f == fileType); + } + if (!isDAE) { + message.error(`只能上传 ${defaultFileTypes.join()} 格式的文件!`); + return false; + } + const isLt = file.size / 1024 / 1024 < (maxFileSize || 3); + if (!isLt) { + message.error(`文件必须小于${maxFileSize || 3}MB!`); + return false; + } + this.setState({ + fileUploading: true + }); + if (onStateChange) { + onStateChange({ uploading: true }); + } + }, + onChange(info) { + const status = info.file.status; + if (status === 'uploading') { + that.setState({ + fileList: info.fileList + }); + } + if (status === 'done') { + let { uploaded, url } = info.file.response; + let size = info.file.size; + let nextFileList = fileList; + nextFileList[nextFileList.length - 1] = { + uid: -moment().unix(), + name: that.dealName(uploaded), + status: 'done', + storageUrl: uploaded, + url: + isQiniu ? '/_file-server/' + uploaded : + isAli ? `/_file-ali-server/${uploaded}` : + url, + size: size + }; + onChange(nextFileList); + that.setState({ + fileUploading: false, + fileList: nextFileList + }); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } else if (status === 'error') { + that.setState({ + fileUploading: false + }); + message.error(`${info.file.name} 上传失败,请重试`); + if (onStateChange) { + onStateChange({ uploading: false }); + } + } + }, + onRemove(file) { + let nextFileList = []; + fileList.map((f, i) => { + if (f.uid != file.uid) { + nextFileList.push(f); + } + }); + let nextRemoveFiles = removeFilesList.concat([file.storageUrl]); + if (curPreviewPic == file.url) { + that.setState({ + curPreviewPic: '' + }); + } + if (curPreviewVideo == file.url) { + that.setState({ + curPreviewVideo: '' + }); + } + onChange(nextFileList); + that.setState({ + fileList: nextFileList, + removeFilesList: nextRemoveFiles + }); + }, + onPreview(file) { + let filePostfix = file.url.split('.').pop(); + filePostfix = filePostfix.toLowerCase(); + if (UploadPath.image.some((img) => img == filePostfix)) { + that.setState({ + curPreviewPic: file.url + }); + } else if (UploadPath.video.some((img) => img == filePostfix)) { + that.setState({ + curPreviewVideo: file.url + }); + } else { + //message.warn('仅支持图片预览'); + preview(file.storageUrl) + } + } + }; + + const preview = (url) => { + let link = isQiniu ? encodeURI(`${this.qnDomain}/${url}`) : + isAli ? encodeURI(`${this.aliAdmin}/${url}`) : '' + if (link) + if (url.indexOf("pdf") !== -1 || url.indexOf("csv") !== -1) { + window.open(link) + } else { + window.open(`https://view.officeapps.live.com/op/view.aspx?src=${link}`) + } + } + + let fileList_ = fileList + // .map(f => { + // if (f.storageUrl) { + // let realName = f.storageUrl.split('/').pop() + // if (f.name != realName) { + // f.name = realName + // } + // } + // return f + // }) + //下载文件 + const handleDownload = (file) => { + saveAs(file) + }; + const saveAs = (file) => { + const link = document.createElement('a'); + link.href = file.url; + link.download = file.name; + link.style.display = 'none'; + link.click(); + } + //自定义下载 + return ( +
+ + + { + disabled ? ( + '' + ) : + listType == 'picture-card' ? + ( + fileList.length >= maxFilesNum_ ? null : ( +
+ +
添加附件
+
+ ) + ) : ( + + ) + } +
+ { + curPreviewPic ? ( + +
+ 图片预览 + { this.setState({ curPreviewPic: '' }) }}> + + +
+ +
+ ) : '' + } + { + curPreviewVideo ? ( +
+ 视频预览 + { this.setState({ curPreviewVideo: '' }) }}> + + +
+ +
) : '' + } +
+
+ ); + } +} + +function mapStateToProps(state) { + const { auth } = state + return { + user: auth.user + }; +} + +export default connect(mapStateToProps)(Uploads); \ No newline at end of file diff --git a/super-screen/client/src/components/buttonGroup/index.js b/super-screen/client/src/components/buttonGroup/index.js new file mode 100644 index 0000000..d0335ad --- /dev/null +++ b/super-screen/client/src/components/buttonGroup/index.js @@ -0,0 +1,51 @@ +'use strict'; + +import React, { Component } from 'react'; +import { connect } from 'react-redux'; +import { Button, Popover, Icon } from 'antd'; +import { EllipsisOutlined } from '@ant-design/icons'; + +class ButtonGroup extends Component { + constructor(props) { + super(props); + this.state = { + + }; + } + + content = () => { + + } + + render_ = () => { + const { children } = this.props + return ( +
+ + + +
+ ) + } + + render() { + const { children } = this.props + if (children) { + if (Array.isArray(children)) { + if (children.some(c => c)) { + return this.render_() + } + } else { + return this.render_() + } + } + return '' + } +} + +function mapStateToProps(state) { + return { + } +} + +export default connect(mapStateToProps)(ButtonGroup); \ No newline at end of file diff --git a/super-screen/client/src/components/export/index.js b/super-screen/client/src/components/export/index.js new file mode 100644 index 0000000..9847347 --- /dev/null +++ b/super-screen/client/src/components/export/index.js @@ -0,0 +1,683 @@ +/** + * Created by Xumeng 2020/04/22. + */ + +import React, { useState, useEffect } from 'react'; +import PropTypes from 'prop-types'; +import { + Row, Col, Space, Button, message, notification, Form, Input, Tooltip, +} from 'antd'; +import moment from 'moment'; +import XLSX from 'xlsx'; +import { fromJS } from 'immutable'; +import { Request } from '@peace/utils'; +import FileSaver from 'file-saver'; +import './index.less'; + +// 通用前端导入导出组件 使用方法查看底部propTypes +function ExportAndImport (props) { + const [form] = Form.useForm(); + const [exportLoading, setExportLoading] = useState(false); + const [importLoading, setImportLoading] = useState(false); + const { + importDataCallback, onImportSucess, handelData, importMethod = 'post', + } = props; + + useEffect(() => () => { + // 只有unmount 时调用 + notification.close('import-notification'); + }); + const importExcel = (file, type) => { + setImportLoading(true); + // 获取上传的文件对象 + const { files } = file.target; + // 判断xls、xlsx格式 + if (files[0].type.indexOf('sheet') > -1 || files[0].type.indexOf('ms-excel') > -1) { + // 通过FileReader对象读取文件 + const fileReader = new FileReader(); + fileReader.onload = (event) => { + try { + const { importRequest = true, importUrl, importQuery } = props; + if (importRequest && !importUrl) { + message.error('获取导入接口失败!'); + form.resetFields(); + return; + } + const { result } = event.target; + // 以二进制流方式读取得到整份excel表格对象 + const workbook = XLSX.read(result, { type: 'binary', cellDates: true }); + let data = []; // 存储获取到的数据 + // 遍历每张工作表进行读取(这里默认只读取第一张表) + for (const sheet in workbook.Sheets) { + if (workbook.Sheets.hasOwnProperty(sheet)) { + // 利用 sheet_to_json 方法将 excel 转成 json 数据 + data = data.concat(XLSX.utils.sheet_to_json(workbook.Sheets[sheet])); + break; // 如果只取第一张表,就取消注释这行 + } + } + if (data.length > 10000) { + message.error('一次最多导入10000条数据,请分批导入!'); + form.resetFields(); + setImportLoading(false); + return; + } + if (importRequest) { + message.success('获取文件数据成功,开始处理导入...'); + const importData = handelData ? handelData(data) : data; + Request[importMethod](importUrl, { data: importData }, importQuery || {}).then((res) => { + message.success('导入数据成功'); + form.resetFields(); + notification.close('import-notification'); + setImportLoading(false); + onImportSucess && onImportSucess(); + }, (err) => { + if (err.status === 500) { + message.error('数据导入出错,导入失败'); + } else if (err.status === 400) { + message.error(err.body.message || '数据验证出错,请检查数据格式是否正确'); + } else { + message.error('导入失败'); + } + form.resetFields(); + setImportLoading(false); + }); + } else { + form.resetFields(); + setImportLoading(false); + importDataCallback && importDataCallback(data, type); + notification.close('import-notification'); + } + } catch (e) { + console.log(e); + // 这里可以抛出文件类型错误不正确的相关提示 + message.error('文件格式不正确!'); + setImportLoading(false); + form.resetFields(); + } + }; + // fileReader.onloadend = (event) => { + // console.log(event) + // } + // 以二进制方式打开文件 + fileReader.readAsBinaryString(files[0]); + } else { + message.error('文件格式不正确!'); + form.resetFields(); + setImportLoading(false); + } + }; + + const loop = (data, keypath, values) => { // deal with array + const dkey = keypath.slice(0, 1)[0]; + console.log(dkey); + if (dkey) { + const dvalue = data[dkey]; + const otherKeypath = keypath.slice(1); + if (Array.isArray(dvalue)) { + if (otherKeypath.length) { + const immutableData = fromJS(data); + for (let index = 0; index < dvalue.length; index++) { + const tmp = immutableData.getIn([dkey, index]).toJS(); + loop(tmp, otherKeypath, values); + } + } + } else { + values.push(dvalue); + } + } + return values; + }; + const getColumnData = (opts) => { + const { + data, keypath, render, spliter, rawdata, + } = opts; + let v = null; + const outer = data[keypath[0]]; + + if (Array.isArray(outer)) { + const values = loop(data, keypath, []); + v = rawdata ? values : values.join(spliter || ','); + } else { + v = fromJS(data).getIn(keypath); + } + // 处理render + if (render && typeof render === 'function') { + v = render(outer, data); + } + return v; + }; + const getDataSource = (attrs, filterData) => { + // let token = JSON.parse(sessionStorage.getItem('user')).token; + const dataSource = filterData.map((item) => { + const record = {}; + attrs.forEach((attr) => { + const { + key, dataIndex, render, child, + } = attr; + if (child) { + record[key] = getDataSource(child, item[key]); + } else { + const v = getColumnData({ + data: item, + keypath: dataIndex || [key], + render: render || null, + }); + record[key] = v; + } + }); + + return record; + }); + return dataSource; + }; + // 暂时只处理两层 + const getFlatData = (attrs, filterData, dataToAoa, deep = 0) => { + filterData.map((item) => { + let cur = dataToAoa[deep]; + if (!cur) { + cur = dataToAoa[deep] = []; + } + attrs.map((attr, index) => { + const { key, child } = attr; + if (child) { + if (Array.isArray(item[key])) { + // getFlatData(child,item[key],dataToAoa,deep) + + item[key].map((s, i) => { + if (i == 0) { + child.map((c) => { + cur.push(s[c.key]); + }); + } else { + deep++; + const childCur = dataToAoa[deep] = []; + pushNull(childCur, index); + child.map((c) => { + childCur.push(s[c.key]); + }); + } + }); + } + } else { + cur.push(item[key]); + } + }); + deep++; + }); + }; + + const getHeader = (headers, excelHeader, deep, perOffset) => { + let offset = 0; + let cur = excelHeader[deep]; + if (!cur) { + cur = excelHeader[deep] = []; + } + pushNull(cur, perOffset - cur.length); + for (let i = 0; i < headers.length; i++) { + const head = headers[i]; + cur.push(head.name); + if (head.hasOwnProperty('child') && Array.isArray(head.child) && head.child.length > 0) { + const childOffset = getHeader(head.child, excelHeader, deep + 1, cur.length - 1); + pushNull(cur, childOffset - 1); + offset += childOffset; + } else { + offset++; + } + } + return offset; + }; + + const pushNull = (arr, count) => { + for (let i = 0; i < count; i++) { + arr.push(null); + } + }; + const fillNull = (arr) => { + const max = Math.max(...(arr.map((a) => a.length))); + arr.filter((e) => e.length < max).forEach((e) => pushNull(e, max - e.length)); + }; + const doMerges = (arr) => { + // 要么横向合并 要么纵向合并 + const deep = arr.length; + const merges = []; + for (let y = 0; y < deep; y++) { + // 先处理横向合并 + const row = arr[y]; + let colSpan = 0; + for (let x = 0; x < row.length; x++) { + if (row[x] === null) { + colSpan++; + if (((x + 1) === row.length) && (colSpan > 0 && x > colSpan)) { + merges.push({ s: { r: y, c: x - colSpan }, e: { r: y, c: x } }); + } + } else if (colSpan > 0 && x > colSpan) { + merges.push({ s: { r: y, c: x - colSpan - 1 }, e: { r: y, c: x - 1 } }); + colSpan = 0; + } else { + colSpan = 0; + } + } + } + // 再处理纵向合并 + const colLength = arr[0].length; + for (let x = 0; x < colLength; x++) { + let rowSpan = 0; + for (let y = 0; y < deep; y++) { + if (arr[y][x] != null) { + rowSpan = 0; + } else { + rowSpan++; + } + } + if (rowSpan > 0) { + merges.push({ s: { r: deep - rowSpan - 1, c: x }, e: { r: deep - 1, c: x } }); + } + } + return merges; + }; + // 内容暂只出了纵向合并 + const doContetMerges = (arr, headerLength) => { + const deep = arr.length; + const merges = []; + // 处理纵向合并 + const colLength = arr[0].length; + for (let x = 0; x < colLength; x++) { + let rowSpan = 0; + const mergY = 0; + for (let y = 0; y < deep; y++) { + if (rowSpan > 0) { + // 如果还有null 继续加 + if (arr[y][x] === null) { + rowSpan += 1; + } else { + // 不为null 增加merge + merges.push({ s: { r: headerLength + (y - rowSpan - 1), c: x }, e: { r: headerLength + y - 1, c: x } }); + rowSpan = 0; + } + } else if (arr[y][x] === null) { + rowSpan += 1; + } + } + if (rowSpan > 0) { + merges.push({ s: { r: headerLength + (deep - rowSpan - 1), c: x }, e: { r: headerLength + deep - 1, c: x } }); + rowSpan = 0; + } + } + return merges; + }; + const exportMergeExcel = async () => { + setExportLoading(true); + const { + column, data, fileName, exportUrl, exportQuery, exportBody, requestType, header, showYearMouth, + } = props || {}; + + let resultData = []; + if (exportUrl) { + resultData = requestType == 'post' ? await Request.post(exportUrl, exportBody || {}, exportQuery || {}).then((data) => { + // 数据接口返回的结果 如果是对象 必须把返回数组放入rows + if (typeof data === 'object' && data.rows) { + return data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }) : await Request.get(exportUrl, exportQuery || {}).then((data) => { + if (typeof data === 'object' && data.rows) { + return data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }); + if (!resultData) { + return; + } + } else { + resultData = data; + } + const excelHeader = []; + getHeader(column, excelHeader, 0, 0); + fillNull(excelHeader); + + // console.log(excelHeader); + + const loopData = getDataSource(column, resultData); + // console.log(loopData) + + const dataToAoa = []; + getFlatData(column, loopData, dataToAoa, 0); + fillNull(dataToAoa); + // console.log(dataToAoa); + + const aoa = [].concat(excelHeader, dataToAoa); + // console.log(aoa) + + const headerMerges = doMerges(excelHeader); + const contentMerages = doContetMerges(dataToAoa, excelHeader.length); + const merges = [].concat(headerMerges, contentMerages); + // console.log(contentMerages) + + // let opts = { + // defaultCellStyle: { + // font: { name: "宋体", sz: 11, color: { auto: 1 } }, + // border: { + // color: { auto: 1 } + // }, + // alignment: { + // /// 自动换行 + // wrapText: 1, + // // 居中 + // horizontal: "center", + // vertical: "center", + // indent: 0 + // } + // } + // } + const sheet = XLSX.utils.aoa_to_sheet(aoa); + // let newSheet = {}; + // for (let [key, value] of Object.entries(sheet)) { + // if(key == '!ref'){ + // newSheet[key] = value + // }else if(typeof value === 'object'){ + // newSheet[key] = { + // ...value, + // s: opts.defaultCellStyle + // } + // } + // } + const wpx = column.map((c) => ({ + wpx: Number.parseInt(c.wpx) ? Number.parseInt(c.wpx) : 100, + })); + sheet['!cols'] = wpx; + sheet['!merges'] = merges; + + // 构建 workbook 对象 + const workbook = XLSX.utils.book_new(); + + const time = moment().format('YYYY-MM-DD'); + + XLSX.utils.book_append_sheet(workbook, sheet, 'mySheet'); + // 导出 Excel + XLSX.writeFile(workbook, fileName ? `${fileName}-${time}.xlsx` : '导出数据.xlsx'); + setExportLoading(false); + // message.success(`成功导出了 ${loopData.length || 0} 条数据`); + }; + + const exportProExcel = async () => { + setExportLoading(true); + const { + column, data, fileName, exportUrl, exportQuery, exportBody, requestType, showYearMouth, + } = props || {}; + let resultData = []; + if (exportUrl) { + resultData = requestType == 'post' ? await Request.post(exportUrl, exportBody || {}, exportQuery || {}).then((data) => { + // 数据接口返回的结果 如果是对象 必须把返回数组放入rows + if (typeof data === 'object') { + return data.data ? data.data : data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }) : await Request.get(exportUrl, exportQuery || {}).then((data) => { + if (showYearMouth) { + + } + if (typeof data === 'object' && data.rows) { + return data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }); + if (!resultData) { + return; + } + } else { + resultData = data; + } + + const loopData = getDataSource(column, resultData); + + let content = ''; + let header = ''; + // header += `
序号
`; + column.map((colum) => { + header += `
${colum.name}
`; + }); + header += ''; + loopData.map((data) => { + content += ''; + column.map((c) => { + if (c.style) { + content += `
${data[c.dataIndex || c.key]}
`; + } else { + content += `
${data[c.dataIndex || c.key]}
`; + } + }); + content += ''; + }); + + const exportTable = `\uFEFF + + ${header} + ${content} +
+ `; + const time = moment().format('YYYY-MM-DD'); + const tempStrs = new Blob([exportTable], { type: 'text/xls' }); + FileSaver.saveAs(tempStrs, fileName ? `${fileName}-${time}.xls` : '导出数据.xls'); + setExportLoading(false); + // message.success(`成功导出了 ${loopData.length || 0} 条数据`); + }; + + const exportExcel = async () => { + setExportLoading(true); + const { + column, data, fileName, exportUrl, exportQuery, exportBody, requestType, + } = props || {}; + const _headers = column + .map((item, i) => ({ key: item.key, title: item.name, position: String.fromCharCode(65 + i) + 1 })) + .reduce((prev, next) => ({ ...prev, [next.position]: { key: next.key, v: next.title } }), {}); + let resultData = []; + if (exportUrl) { + resultData = requestType == 'post' ? await Request.post(exportUrl, exportBody || {}, exportQuery || {}).then((data) => { + // 数据接口返回的结果 如果是对象 必须把返回数组放入rows + + if (typeof data === 'object' && (data.rows || data.data)) { + return data.data ? data.data : data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }) : await Request.get(exportUrl, exportQuery || {}).then((data) => { + if (typeof data === 'object' && data.rows) { + return data.rows; + } + return data; + }, (err) => { + message.error('获取数据失败,导出失败!'); + }); + if (!resultData) { + return; + } + } else { + resultData = data; + } + + const loopDate = getDataSource(column, resultData); + + const wpx = column.map((c) => ({ + wpx: Number.parseInt(c.wpx) ? Number.parseInt(c.wpx) : 100, + })); + if (!(loopDate.length > 0)) { + setExportLoading(false); + return; + } + const _data = loopDate + .map((item, i) => column.map((key, j) => ({ content: item[key.key], position: String.fromCharCode(65 + j) + (i + 2) }))) + // 对刚才的结果进行降维处理(二维数组变成一维数组) + .reduce((prev, next) => prev.concat(next)) + // 转换成 worksheet 需要的结构 + .reduce((prev, next) => ({ ...prev, [next.position]: { v: next.content } }), {}); + + // 合并 column 和 data + const output = { ..._headers, ..._data }; + // 获取所有单元格的位置 + const outputPos = Object.keys(output); + // 计算出范围 ,["A1",..., "H2"] + const ref = `${outputPos[0]}:${outputPos[outputPos.length - 1]}`; + + // 构建 workbook 对象 + const workbook = { + SheetNames: ['mySheet'], + Sheets: { + mySheet: { + + ...output, + '!ref': ref, + '!cols': wpx, + }, + }, + }; + const time = moment().format('YYYY-MM-DD'); + // 导出 Excel + XLSX.writeFile(workbook, fileName ? `${fileName}-${time}.xlsx` : '导出数据.xlsx'); + setExportLoading(false); + // message.success(`成功导出了 ${loopDate.length || 0} 条数据`); + }; + + const exportTemplete = async () => { + const { importTemColumn, importTemData, fileName } = props || {}; + const _headers = importTemColumn + .map((item, i) => { + let group = 0; // 用于处理Z1的时候,重计算AA1 + if (parseInt(i / 26) > group) { + group = parseInt(i / 26); + } + if (group > 0) { // AA1 BA1 CA1 + const position = String.fromCharCode(65 + (group - 1)); + return { key: item.key, title: item.name, position: position + String.fromCharCode(65 + (i % 26)) + 1 }; + } return { key: item.key, title: item.name, position: String.fromCharCode(65 + i) + 1 }; + }) + .reduce((prev, next) => ({ ...prev, [next.position]: { key: next.key, v: next.title } }), {}); + + const loopDate = getDataSource(importTemColumn, importTemData); + + const wpx = importTemColumn.map((c) => ({ + wpx: Number.parseInt(c.wpx) ? Number.parseInt(c.wpx) : 100, + })); + const _data = loopDate.length ? loopDate + .map((item, i) => importTemColumn.map((key, j) => ({ content: item[key.key], position: String.fromCharCode(65 + j) + (i + 2) }))) + // 对刚才的结果进行降维处理(二维数组变成一维数组) + .reduce((prev, next) => prev.concat(next)) + // 转换成 worksheet 需要的结构 + .reduce((prev, next) => ({ ...prev, [next.position]: { v: next.content } }), {}) : []; + // 合并 column 和 data + const output = { ..._headers, ..._data }; + // 获取所有单元格的位置 + const outputPos = Object.keys(output); + // 计算出范围 ,["A1",..., "H2"] + const ref = `${outputPos[0]}:${outputPos[outputPos.length - 1]}`; + + // 构建 workbook 对象 + const workbook = { + SheetNames: ['mySheet'], + Sheets: { + mySheet: { + + ...output, + '!ref': ref, + '!cols': wpx, + }, + }, + }; + // 导出 Excel + XLSX.writeFile(workbook, fileName ? `${fileName}-导入模板.xlsx` : '导入模板.xlsx'); + }; + const tips = (type) => { + const { tips, templeteBth = true } = props; + const description = ( +
+ {tips && tips} + + +
+ + importExcel(e, type)} /> + + +
+ + {templeteBth && ( + + + + )} +
+
+ ); + + notification.info({ + message: '支持 .xlsx、.xls 格式的文件', + description, + key: 'import-notification', + duration: null, + }); + }; + + return ( + + { + props.import && ( + + ) + } + { + props.export && ( + + + + ) + } + + ); +} + +ExportAndImport.propTypes = { + export: PropTypes.bool, // 是否显示导出按钮 + exportBtnName: PropTypes.string, // 导出按钮文字 + importBtnName: PropTypes.string, // 导入按钮文字 + import: PropTypes.bool, // 是否显示导入按钮 + variedImport: PropTypes.bool, // 是否显示多样导入 + variedImportDisable: PropTypes.bool, // 多样导入禁用 + variedImportBtnName: PropTypes.string, // 多样导入文字 + column: PropTypes.array, // 导出显示的header数组 兼容antd column 可直接拿table的column使用 注:column每列的属性wpx设置导出的execl每列的宽度值 默认 100 + data: PropTypes.array, // 导出的数据 兼容antd table 数组嵌套处理 + exportUrl: PropTypes.string, // 导出数据从接口获取的url地址 返回的数据1、数组必须支持column的设置 ,2、如果是对象,数组需放在rows属性上 + exportBody: PropTypes.object, // 导出数据接口body参数 + exportQuery: PropTypes.object, // 导出数据从接口获取的url地址上的参数 + exportBtnTips: PropTypes.string, // 导出按钮tips文字提示 + importUrl: PropTypes.string, // 导入接口url + importQuery: PropTypes.object, // 导入接口url地址上的参数 + btnClass: PropTypes.string, // 按钮className + btnStyle: PropTypes.object, // 按钮style + tips: PropTypes.oneOfType([PropTypes.string, PropTypes.element]), // 上传文件提示的信息 + onImportSucess: PropTypes.func, // 上传成功后 返回处理函数 + importTemColumn: PropTypes.array, // 导入模板设置 头部字段数组 + importTemData: PropTypes.array, // 导入模板默认数据 + requestType: PropTypes.string, // 请求类型 + importDataCallback: PropTypes.func, // 上传后数据返回 + templeteBth: PropTypes.bool, // 模板按钮 + importRequest: PropTypes.bool, // 请求导入接口,false时搭配importDataCallback, + exportType: PropTypes.string, // 导出执行的函数名 +}; + +export default ExportAndImport; diff --git a/super-screen/client/src/components/export/index.less b/super-screen/client/src/components/export/index.less new file mode 100644 index 0000000..a362e30 --- /dev/null +++ b/super-screen/client/src/components/export/index.less @@ -0,0 +1,13 @@ +.export-import { + .file-uploader { + position: absolute; + width: 100%; + height: 100%; + top: 0; + left: 0; + outline: none; + opacity: 0; + background-color: transparent; + z-index: 10; + } + } \ No newline at end of file diff --git a/super-screen/client/src/components/index.js b/super-screen/client/src/components/index.js new file mode 100644 index 0000000..80d0a3e --- /dev/null +++ b/super-screen/client/src/components/index.js @@ -0,0 +1,18 @@ + +'use strict'; + +import Upload from './Upload'; +import Uploads from './Uploads'; +import NoResource from './no-resource'; +import ExportAndImport from './export'; +import ButtonGroup from './buttonGroup'; +import UploadLocal from './UploadLocal'; + +export { + Upload, + Uploads, + NoResource, + ExportAndImport, + ButtonGroup, + UploadLocal +}; diff --git a/super-screen/client/src/components/no-resource/index.js b/super-screen/client/src/components/no-resource/index.js new file mode 100644 index 0000000..b4a221d --- /dev/null +++ b/super-screen/client/src/components/no-resource/index.js @@ -0,0 +1,21 @@ +'use strict'; + +import React from 'react'; +import { Result} from 'antd'; +import { MehOutlined } from '@ant-design/icons'; +class NoResource extends React.Component { + constructor(props) { + super(props); + } + render() { + const title = this.props.title ? this.props.title : "抱歉,没有可访问的资源!" + return ( + } + title={title} + /> + ); + } +} + +export default NoResource; \ No newline at end of file diff --git a/super-screen/client/src/index.js b/super-screen/client/src/index.js new file mode 100644 index 0000000..4367f4d --- /dev/null +++ b/super-screen/client/src/index.js @@ -0,0 +1,7 @@ +'use strict'; + +import React from 'react'; +import { render } from 'react-dom'; +import App from './app'; + +render((), document.getElementById('App')); \ No newline at end of file diff --git a/super-screen/client/src/layout/actions/global.js b/super-screen/client/src/layout/actions/global.js new file mode 100644 index 0000000..2cecf94 --- /dev/null +++ b/super-screen/client/src/layout/actions/global.js @@ -0,0 +1,27 @@ +'use strict'; +import { RouteRequest } from '@peace/utils'; +import { RouteTable } from '$utils' + +export const INIT_LAYOUT = 'INIT_LAYOUT'; +export function initLayout (title, copyright, sections, actions) { + return { + type: INIT_LAYOUT, + payload: { + title, + copyright, + sections, + actions + } + }; +} + +export const RESIZE = 'RESIZE'; +export function resize (clientHeight, clientWidth) { + return { + type: RESIZE, + payload: { + clientHeight, + clientWidth + } + } +} \ No newline at end of file diff --git a/super-screen/client/src/layout/components/footer/index.js b/super-screen/client/src/layout/components/footer/index.js new file mode 100644 index 0000000..6e1fa30 --- /dev/null +++ b/super-screen/client/src/layout/components/footer/index.js @@ -0,0 +1,15 @@ +'use strict'; +import React from 'react'; +import style from './style.css'; + +export default class Footer extends React.Component { + render() { + const {footerProps} = this.props; + + return ( +
+ {this.props.children} +
+ ); + } +}; \ No newline at end of file diff --git a/super-screen/client/src/layout/components/footer/style.css b/super-screen/client/src/layout/components/footer/style.css new file mode 100644 index 0000000..c1bea3c --- /dev/null +++ b/super-screen/client/src/layout/components/footer/style.css @@ -0,0 +1,5 @@ +.footer { + text-align: center; + font-size: 12px; + color: #999; +} \ No newline at end of file diff --git a/super-screen/client/src/layout/components/header/index.js b/super-screen/client/src/layout/components/header/index.js new file mode 100644 index 0000000..076e3b9 --- /dev/null +++ b/super-screen/client/src/layout/components/header/index.js @@ -0,0 +1,100 @@ +'use strict'; +import React from 'react'; +import { Menu } from 'antd'; +import { Link } from 'react-router-dom'; +import { connect } from 'react-redux'; +import styles from './style.css'; +import { + MenuFoldOutlined, MenuUnfoldOutlined, UserOutlined, LogoutOutlined +} from '@ant-design/icons'; +import ResetPasswordModal from '../../../sections/memberManagement/components/resetPassword'; +const Header = props => { + const { dispatch, history, user, pathname, toggleCollapsed, collapsed, actions } = props + + const onFinish = async (values) => { + const dataToSave = { ...values } + return dispatch( + actions.memberManagement.modifyUser(user.id, dataToSave, values?.msg || ''), + ).then((res) => { + if (res.success) { + return true; + } else { + return false; + } + }); + }; + + const handelClick = item => { + if (item.key == 'logout') { + dispatch(actions.auth.logout(user)); + history.push(`/signin`); + } + } + + let current = pathname; + if (pathname == '/' || pathname == '') { + current = 'default'; + } else if (pathname.charAt(0) == '/') { + current = pathname.substring(1); + } + + if (current.indexOf('/') != -1) { + current = current.substring(0, current.indexOf('/')); + } + + return ( +
+
+ + { + collapsed ? + : + } + +
+ 政务数据资源中心 +
+
+ +
+ ); +}; + +function mapStateToProps(state) { + const { global, auth } = state; + return { + actions: global.actions, + user: auth.user + }; +} + +export default connect(mapStateToProps)(Header); \ No newline at end of file diff --git a/super-screen/client/src/layout/components/header/style.css b/super-screen/client/src/layout/components/header/style.css new file mode 100644 index 0000000..7a73dd1 --- /dev/null +++ b/super-screen/client/src/layout/components/header/style.css @@ -0,0 +1,41 @@ +.header { + position: relative; + height: 65px; + min-width: 520px; + background-color: #1890ff; +} + +.header-fold { + float: left; + padding-left: 32px; + font-size: 16px; +} + +.header-title { + line-height: 60px; + display: inline-block; + font-size: 20px; + color: #fff; + text-shadow: 0 4px 3px rgba(54, 77, 108, 0.20); +} + +.header-nav { + float: right; +} + +.header-nav-notification { + /* color : #666; */ + font-size: 16px; +} + +.header-nav-user-img-wrapper { + display: inline; + margin: 14px 8px; +} + +.header-nav-user-img { + width: 36px; + height: 36px; + position: relative; + bottom: 2px; +} \ No newline at end of file diff --git a/super-screen/client/src/layout/components/sider/index.js b/super-screen/client/src/layout/components/sider/index.js new file mode 100644 index 0000000..775fe34 --- /dev/null +++ b/super-screen/client/src/layout/components/sider/index.js @@ -0,0 +1,95 @@ +import React, { Component, useEffect, useState } from 'react'; +import { Menu } from 'antd'; +const JumpUrls = [ + { url: '/risk/hiddenrectification_approval', keys: 'riskHiddenrectification_approval' }, + { url: '/safetymanage/hiddenrectification_approval', keys: 'hiddenrectification_approval' }, + { url: '/metadataManagement/latestMetadata', keys: 'latestMetadata' }, +] +const Sider = (props) => { + const [items, setItems] = useState([]) + const [selectedKeys, setSelectedKeys] = useState([]) + const [openKeys, setOpenKeys] = useState([]) + const { pathname } = props; + useEffect(() => { + let jumpurlObj = JumpUrls.find(s => s.url == pathname && selectedKeys != s.keys) + if (jumpurlObj) { + localStorage.setItem('governmentDataResourceCenter_selected_sider', JSON.stringify([jumpurlObj.keys])) + setSelectedKeys(jumpurlObj.keys) + } + if (pathname.indexOf('metadataManagement/latestMetadata') < 0) + sessionStorage.removeItem('jumpSelectedKey'); + if (pathname.indexOf('metadataManagement/businessMetadata') < 0) + sessionStorage.removeItem('jumpBusinessSelectedKey'); + }, [pathname]) + + useEffect(() => { + const { sections, dispatch, user } = props; + let items = sections.reduce((p, c) => { + if (typeof c.getNavItem == 'function') { + let item = c.getNavItem(user, dispatch); + if (item != null) { + if (Array.isArray(item)) { + p = p.concat(item); + } else { + p.push(item); + } + } + } + return p; + }, []); + setItems(items) + + let selectedKeys = [] + let openKeys = [] + const lastSelectedKeys = localStorage.getItem('governmentDataResourceCenter_selected_sider') + if (lastSelectedKeys) { + selectedKeys = JSON.parse(lastSelectedKeys) + } + const lastOpenKeys = localStorage.getItem('governmentDataResourceCenter_open_sider') + if (lastOpenKeys) { + openKeys = JSON.parse(lastOpenKeys) + } + if (!selectedKeys.length && !openKeys.length) { + let firstItem = items[0] || null + + if (firstItem) { + let children = firstItem.props.children + if (Array.isArray(children)) { + selectedKeys = [children[0].key] + openKeys = [firstItem.key] + } else if (children.key) { + selectedKeys = [children.key] + openKeys = [firstItem.key] + } else { + selectedKeys = [firstItem.key] + } + } + } + localStorage.setItem('governmentDataResourceCenter_selected_sider', JSON.stringify(selectedKeys)) + setSelectedKeys(selectedKeys) + localStorage.setItem('governmentDataResourceCenter_open_sider', JSON.stringify(openKeys)) + setOpenKeys(openKeys) + }, []) + + + return ( + { + const { selectedKeys } = e; + setSelectedKeys(selectedKeys) + localStorage.setItem('governmentDataResourceCenter_selected_sider', JSON.stringify(selectedKeys)) + }} + onOpenChange={(openKeys) => { + setOpenKeys(openKeys) + localStorage.setItem('governmentDataResourceCenter_open_sider', JSON.stringify(openKeys)) + }} + > + {items} + + ) +} + +export default Sider; \ No newline at end of file diff --git a/super-screen/client/src/layout/containers/index.js b/super-screen/client/src/layout/containers/index.js new file mode 100644 index 0000000..345ec16 --- /dev/null +++ b/super-screen/client/src/layout/containers/index.js @@ -0,0 +1,6 @@ +'use strict'; +import Layout from './layout'; +import NoMatch from './no-match'; + +export { Layout }; +export { NoMatch }; \ No newline at end of file diff --git a/super-screen/client/src/layout/containers/layout/breadcrumb.js b/super-screen/client/src/layout/containers/layout/breadcrumb.js new file mode 100644 index 0000000..bb1b83f --- /dev/null +++ b/super-screen/client/src/layout/containers/layout/breadcrumb.js @@ -0,0 +1,48 @@ +import React from 'react'; +import { Breadcrumb } from 'antd'; +import withBreadcrumbs from 'react-router-breadcrumbs-hoc'; +import { Link } from 'react-router-dom'; + +const extRoutes = [{ path: '/project-monitor/things/struct/:id/configuration/station', breadcrumb: '测点' }]; + +function Breadcrumbs(props) { + const excludePaths = [ + '/', + '/metadataManagement/latestMetadata/detail', + '/metadataAcquisition/adapter/detail', + ]; + + const { routes } = props; + + const Bread = withBreadcrumbs(routes.concat(extRoutes), { excludePaths })(({ breadcrumbs }) => ( + + { + breadcrumbs.map((bc, index) => ( + + { + bc.component + ? ( + + {bc.breadcrumb} + + ) + : bc.breadcrumb + } + + )) + } + + )); + + return ( + + ); +} + +export default Breadcrumbs; diff --git a/super-screen/client/src/layout/containers/layout/index.js b/super-screen/client/src/layout/containers/layout/index.js new file mode 100644 index 0000000..cbade91 --- /dev/null +++ b/super-screen/client/src/layout/containers/layout/index.js @@ -0,0 +1,132 @@ +'use strict'; + +import './index.less'; +import React, { useState, useEffect } from 'react'; +import { connect } from 'react-redux'; +import { message, Layout } from 'antd'; +import Sider from '../../components/sider'; +import Header from '../../components/header'; +import Footer from '../../components/footer'; +import Breadcrumbs from './breadcrumb'; +import { resize } from '../../actions/global'; +import * as NProgress from 'nprogress'; +import PerfectScrollbar from 'perfect-scrollbar'; + +NProgress.configure({ + template: ` +
+
+
+
+
+
+ ` +}); + +const headerHeight = 64 +const footerHeight = 0 +let scrollbar + +const LayoutContainer = props => { + const { dispatch, msg, user, copyright, children, sections, clientWidth, clientHeight, location, match, routes, history } = props + const [collapsed, setCollapsed] = useState(false) + + NProgress.start(); + + const resize_ = (collapsed) => { + const extraHeight = headerHeight + footerHeight; + dispatch(resize( + document.body.clientHeight - extraHeight - 12, + document.body.clientWidth - (collapsed ? 120 : 220) + )); + } + + useEffect(() => { + resize_(collapsed) + scrollbar = new PerfectScrollbar('#page-content', { suppressScrollX: true }); + }, []) + + useEffect(() => { + NProgress.done(); + if (!user || !user.authorized) { + history.push('/signin'); + } + if (msg) { + message.destroy(); + if (msg.done) { + message.success(msg.done); + } + if (msg.error) { + message.error(msg.error); + } + } + const dom = document.getElementById('page-content'); + if (dom) { + scrollbar.update(); + dom.scrollTop = 0; + } + }) + // console.log(FS_API_ROOT); + return ( + + +
{ + setCollapsed(!collapsed); + resize_(!collapsed) + }} + collapsed={collapsed} + history={history} + /> + + + + + + +
+
+ +
+
+ {children} +
+
+
+ {/* + {copyright} + */} +
+ + ) +} + +function mapStateToProps(state) { + const { global, auth, ajaxResponse } = state; + return { + title: global.title, + copyright: global.copyright, + sections: global.sections, + actions: global.actions, + clientWidth: global.clientWidth, + clientHeight: global.clientHeight, + msg: ajaxResponse.msg, + user: auth.user, + }; +} + +export default connect(mapStateToProps)(LayoutContainer); \ No newline at end of file diff --git a/super-screen/client/src/layout/containers/layout/index.less b/super-screen/client/src/layout/containers/layout/index.less new file mode 100644 index 0000000..ce3bc72 --- /dev/null +++ b/super-screen/client/src/layout/containers/layout/index.less @@ -0,0 +1,3 @@ +@import '~perfect-scrollbar/css/perfect-scrollbar.css'; +@import '~nprogress/nprogress.css'; +@import '~simplebar-react/dist/simplebar.min.css'; \ No newline at end of file diff --git a/super-screen/client/src/layout/containers/no-match/index.js b/super-screen/client/src/layout/containers/no-match/index.js new file mode 100644 index 0000000..c0437a5 --- /dev/null +++ b/super-screen/client/src/layout/containers/no-match/index.js @@ -0,0 +1,18 @@ +'use strict'; + +import React from 'react'; +import moment from 'moment' + +const NoMatch = props => { + return ( +
+

404

+

PAGE NOT FOUND

+

很遗憾,您暂时无法访问该页面。

+

请检查您访问的链接地址是否正确。

+

Copyright © {moment().year()} 飞尚

+
+ ) +} + +export default NoMatch; \ No newline at end of file diff --git a/super-screen/client/src/layout/index.js b/super-screen/client/src/layout/index.js new file mode 100644 index 0000000..5c28d62 --- /dev/null +++ b/super-screen/client/src/layout/index.js @@ -0,0 +1,179 @@ +'use strict'; +import React, { useEffect, useState } from 'react'; +import moment from 'moment'; +import configStore from './store'; +import { Provider } from 'react-redux'; +import { createBrowserHistory } from 'history'; +import { ConnectedRouter } from 'connected-react-router' +import { Layout, NoMatch } from './containers'; +import { Switch, Route } from "react-router-dom"; +import { ConfigProvider } from 'antd'; +import * as layoutActions from './actions/global'; +import zhCN from 'antd/lib/locale/zh_CN'; +import { basicReducer } from '@peace/utils'; +import 'moment/locale/zh-cn'; +import 'antd/dist/antd.less'; + +moment.locale('zh-cn'); + +const { initLayout } = layoutActions; + +const Root = props => { + const { sections, title, copyright } = props; + const [history, setHistory] = useState(null) + const [store, setStore] = useState(null) + const [outerRoutes, setOuterRoutes] = useState([]) + const [combineRoutes, setCombineRoutes] = useState([]) + const [innnerRoutes, setInnerRoutes] = useState([]) + + const flatRoutes = (routes) => { + const combineRoutes = []; + + function flat(routes, parentRoute) { + routes.forEach((route, i) => { + const obj = { + path: route.path, + breadcrumb: route.breadcrumb, + component: route.component || null, + authCode: route.authCode || '', + key: route.key, + }; + if (!route.path.startsWith('/')) { + console.error(`路由配置需以 "/" 开始:${route.path}`); + } + if (route.path.length > 1 && route.path[route.path.length] == '/') { + console.error(`除根路由路由配置不可以以 "/" 结束:${route.path}`); + } + if (parentRoute && parentRoute != '/') { + obj.path = parentRoute + route.path; + } + if (route.exact === false) { + obj.exact = false; + } + if (route.hasOwnProperty('childRoutes')) { + combineRoutes.push(obj); + flat(route.childRoutes, obj.path); + } else { + combineRoutes.push(obj); + } + }); + } + + flat(routes); + return combineRoutes; + }; + + + const initReducer = (reducers, reducerName, action) => { + let reducerParams = {} + const { actionType, initReducer, reducer } = action()() + if (initReducer || reducer) { + if (reducer) { + if (reducer.name) { + reducerName = reducer.name + } + if (reducer.params) { + reducerParams = reducer.params + } + } else { + reducerName = `${reducerName}Rslt` + } + reducers[reducerName] = function (state, action) { + return basicReducer(state, action, Object.assign({ actionType: actionType }, reducerParams)); + } + } + } + + useEffect(() => { + let innerRoutes = [] + let outerRoutes = [] + let reducers = {} + let actions = { + layout: layoutActions + } + + for (let s of sections) { + if (!s.key) console.warn('请给你的section添加一个key值,section name:' + s.name); + for (let r of s.routes) { + if (r.type == 'inner' || r.type == 'home') { + innerRoutes.push(r.route) + } else if (r.type == 'outer') { + outerRoutes.push(r.route) + } + } + if (s.reducers) { + reducers = { ...reducers, ...s.reducers } + } + if (s.actions) { + actions = { ...actions, [s.key]: s.actions } + if (s.key != 'auth') { + for (let ak in s.actions) { + let actions = s.actions[ak] + if (actions && typeof actions == 'object') { + for (let actionName in actions) { + initReducer(reducers, actionName, actions[actionName]) + } + } else if (typeof actions == 'function') { + initReducer(reducers, ak, actions) + } + } + } + } + } + + let history = createBrowserHistory(); + let store = configStore(reducers, history); + store.dispatch(initLayout(title, copyright, sections, actions)); + store.dispatch(actions.auth.initAuth()); + + const combineRoutes = flatRoutes(innerRoutes); + + setInnerRoutes(combineRoutes) + setHistory(history) + setStore(store) + setOuterRoutes(outerRoutes.map(route => ( + + ))) + setCombineRoutes(combineRoutes.map(route => ( + + ))) + }, []) + + return ( + store ? + + + +
+ + {outerRoutes} + + {combineRoutes} + + + +
+
+
+
+ : '' + ) +} + +export default Root; \ No newline at end of file diff --git a/super-screen/client/src/layout/reducers/ajaxResponse.js b/super-screen/client/src/layout/reducers/ajaxResponse.js new file mode 100644 index 0000000..ee934d8 --- /dev/null +++ b/super-screen/client/src/layout/reducers/ajaxResponse.js @@ -0,0 +1,28 @@ +/** + * Created by liu.xinyi + * on 2016/4/1. + */ +'use strict'; +const initState = { + msg: null +}; + +import Immutable from 'immutable'; + +/** + * 全局ajax响应处理: + * 判断action中是否有done字段,如果有,则修改store中的msg.done + * 判断action中是否有error字段,如果有,则修改store中msg.error + * 在layout中根据msg的值,呈现提示信息。 +*/ +export default function ajaxResponse(state = initState, action) { + if (action.done) { + return Immutable.fromJS(state).set('msg', {done: action.done}).toJS(); + } + + if (action.error) { + return Immutable.fromJS(state).set('msg', {error: action.error}).toJS(); + } + + return {msg: null}; +}; \ No newline at end of file diff --git a/super-screen/client/src/layout/reducers/global.js b/super-screen/client/src/layout/reducers/global.js new file mode 100644 index 0000000..fc8622a --- /dev/null +++ b/super-screen/client/src/layout/reducers/global.js @@ -0,0 +1,36 @@ +'use strict'; +import Immutable from 'immutable'; +import { INIT_LAYOUT, RESIZE } from '../actions/global'; + +function global (state = { + title: '', + copyright: '', + sections: [], + actions: {}, + plugins: {}, + clientHeight: 768, + clientWidth: 1024, +}, action) { + const payload = action.payload; + switch (action.type) { + case RESIZE: + return Immutable.fromJS(state).merge({ + clientHeight: payload.clientHeight, + clientWidth: payload.clientWidth + }).toJS(); + case INIT_LAYOUT: + return { + title: payload.title, + copyright: payload.copyright, + sections: payload.sections, + actions: payload.actions, + plugins: payload.plugins, + clientHeight: state.clientHeight, + clientWidth: state.clientWidth, + }; + default: + return state; + } +} + +export default global; \ No newline at end of file diff --git a/super-screen/client/src/layout/reducers/index.js b/super-screen/client/src/layout/reducers/index.js new file mode 100644 index 0000000..975cbd5 --- /dev/null +++ b/super-screen/client/src/layout/reducers/index.js @@ -0,0 +1,15 @@ +/** + * User: liuxinyi/liu.xinyi@free-sun.com.cn + * Date: 2016/1/13 + * Time: 17:52 + * + */ +'use strict'; + +import global from './global'; +import ajaxResponse from './ajaxResponse'; + +export default { + global, + ajaxResponse +}; \ No newline at end of file diff --git a/super-screen/client/src/layout/store/index.js b/super-screen/client/src/layout/store/index.js new file mode 100644 index 0000000..764f481 --- /dev/null +++ b/super-screen/client/src/layout/store/index.js @@ -0,0 +1,16 @@ +/** + * User: liuxinyi/liu.xinyi@free-sun.com.cn + * Date: 2016/1/13 + * Time: 17:51 + * + */ +'use strict'; + +let store = null; +if(process.env.NODE_ENV == 'production'){ + store = require('./store.prod').default; +}else { + store = require('./store.dev').default; +} + +export default store; \ No newline at end of file diff --git a/super-screen/client/src/layout/store/store.dev.js b/super-screen/client/src/layout/store/store.dev.js new file mode 100644 index 0000000..57beb1e --- /dev/null +++ b/super-screen/client/src/layout/store/store.dev.js @@ -0,0 +1,30 @@ +/** + * Created by liu.xinyi + * on 2016/4/8. + */ +'use strict'; +import { createStore, combineReducers, applyMiddleware, compose } from 'redux'; +import reduxThunk from 'redux-thunk'; +import { connectRouter, routerMiddleware } from 'connected-react-router'; +import innerReducers from '../reducers'; + +function configStore(reducers, history) { + const reducer = Object.assign({}, innerReducers, reducers, { + router: connectRouter(history) + }); + + const composeEnhancers = + typeof window === 'object' && + window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? + window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({ + // Specify extension’s options like name, actionsBlacklist, actionsCreators, serialize... + }) : compose; + + const enhancers = composeEnhancers( + applyMiddleware(routerMiddleware(history), reduxThunk) + ); + + return createStore(combineReducers(reducer), {}, enhancers); +} + +export default configStore; \ No newline at end of file diff --git a/super-screen/client/src/layout/store/store.prod.js b/super-screen/client/src/layout/store/store.prod.js new file mode 100644 index 0000000..e29f026 --- /dev/null +++ b/super-screen/client/src/layout/store/store.prod.js @@ -0,0 +1,20 @@ +/** + * Created by liu.xinyi + * on 2016/4/8. + */ +'use strict'; + +import { createStore, combineReducers, applyMiddleware } from 'redux'; +import reduxThunk from 'redux-thunk'; +import { connectRouter, routerMiddleware } from 'connected-react-router'; +import innerReducers from '../reducers'; + +function configStore(reducers, history){ + const reducer = Object.assign({}, innerReducers, reducers, { + router: connectRouter(history) + }); + + return createStore(combineReducers(reducer), {}, applyMiddleware(routerMiddleware(history), reduxThunk)); +} + +export default configStore; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/actions/auth.js b/super-screen/client/src/sections/auth/actions/auth.js new file mode 100644 index 0000000..1733d08 --- /dev/null +++ b/super-screen/client/src/sections/auth/actions/auth.js @@ -0,0 +1,62 @@ +'use strict'; + +import { ApiTable } from '$utils' +import { Request } from '@peace/utils' + +export const INIT_AUTH = 'INIT_AUTH'; +export function initAuth() { + const user = JSON.parse(sessionStorage.getItem('user')) || {}; + return { + type: INIT_AUTH, + payload: { + user: user + } + }; +} + +export const REQUEST_LOGIN = 'REQUEST_LOGIN'; +export const LOGIN_SUCCESS = 'LOGIN_SUCCESS'; +export const LOGIN_ERROR = 'LOGIN_ERROR'; +export function login({ username, password, phone, code }) { + return dispatch => { + dispatch({ type: REQUEST_LOGIN }); + + return Request.post(ApiTable.login, { username, password, phone, code }) + .then(user => { + sessionStorage.setItem('user', JSON.stringify(user)); + dispatch({ + type: LOGIN_SUCCESS, + payload: { user: user }, + }); + }, error => { + let { body } = error.response; + dispatch({ + type: LOGIN_ERROR, + payload: { + error: body && body.message ? body.message : '登录失败' + } + }) + }); + } +} + +export const LOGOUT = 'LOGOUT'; +export function logout(user) { + const token = user.token; + const url = ApiTable.logout; + sessionStorage.removeItem('user'); + localStorage.removeItem('governmentDataResourceCenter_selected_sider') + localStorage.removeItem('governmentDataResourceCenter_open_sider') + Request.put(url, { + token: token + }); + return { + type: LOGOUT + }; +} + +export default { + initAuth, + login, + logout +} \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/actions/index.js b/super-screen/client/src/sections/auth/actions/index.js new file mode 100644 index 0000000..d44996e --- /dev/null +++ b/super-screen/client/src/sections/auth/actions/index.js @@ -0,0 +1,10 @@ +/** + * Created by liu.xinyi + * on 2016/4/1. + */ +'use strict'; +import auth from './auth'; + +export default { + ...auth +}; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/containers/index.js b/super-screen/client/src/sections/auth/containers/index.js new file mode 100644 index 0000000..9229b94 --- /dev/null +++ b/super-screen/client/src/sections/auth/containers/index.js @@ -0,0 +1,4 @@ +'use strict'; +import Login from './login'; + +export { Login }; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/containers/login.js b/super-screen/client/src/sections/auth/containers/login.js new file mode 100644 index 0000000..e1cabcb --- /dev/null +++ b/super-screen/client/src/sections/auth/containers/login.js @@ -0,0 +1,158 @@ +'use strict'; +import React, { useState, useEffect, useRef } from 'react'; +import { connect } from 'react-redux'; +import { push } from 'react-router-redux'; +import SHA1 from 'crypto-js/sha1'; +import Hex from 'crypto-js/enc-hex'; +import { ApiTable } from '$utils' +import { Request } from '@peace/utils' +import { Button, Input, Form, Row, Col, message, Tabs } from 'antd'; +import { login, LOGIN_ERROR } from '../actions/auth'; +import { ExclamationCircleOutlined } from '@ant-design/icons'; +import { Uploads } from '$components' +import '../style.less'; + +const FormItem = Form.Item; + +let codCountDownInterval = null +const Login = props => { + const { dispatch, user, error, isRequesting } = props + const [username, setUserName] = useState('') + const [password, setPassword] = useState('') + const [phone, setPhone] = useState('') + const [code, setCode] = useState('') + const [inputChanged, setInputChanged] = useState(false) + const [curTabKey, setCurTabKey] = useState(1) + const [codSending, setCodSending] = useState(false) + const [codCountDown, setCodeCountDown] = useState(60) + const codCountDownRef = useRef(0) + + useEffect(() => { + sessionStorage.removeItem('user'); + localStorage.removeItem('governmentDataResourceCenter_selected_sider') + localStorage.removeItem('governmentDataResourceCenter_open_sider') + }, []) + + + useEffect(() => { + if (user && user.authorized) { + user?.role == '数据消费者' ? dispatch(push('/metadataManagement/latestMetadata')) : dispatch(push('/homePage')); + } + }, [user]) + + useEffect(() => { + if (codSending) { + setCodeCountDown(59) + codCountDownRef.current = 59 + codCountDownInterval = setInterval(() => { + codCountDownRef.current -= 1 + if (codCountDownRef.current == 0) { + setCodSending(false) + setCodeCountDown(60) + clearInterval(codCountDownInterval) + codCountDownInterval = null + } else { + setCodeCountDown(codCountDownRef.current) + } + }, 1000); + } else { + if (codCountDownInterval) { + clearInterval(codCountDownInterval) + codCountDownInterval = null + setCodeCountDown(60) + } + } + }, [codSending]) + + const doLogin = () => { + if (curTabKey == 1) { + if (!username || !password) + dispatch({ + type: LOGIN_ERROR, + payload: { error: '请输入账号名和密码' } + }); + setInputChanged(false) + dispatch(login({ username, password })); + } else { + if (!phone || !code) + dispatch({ + type: LOGIN_ERROR, + payload: { error: '请输入手机号和验证码' } + }); + dispatch(login({ phone, code })); + } + } + + const enterHandler = e => { + if (e.key === 'Enter') { + doLogin() + } + }; + + return ( +
+
+
+
+
欢迎登录系统
+
+
+ + + { + setUserName(e.target.value) + setInputChanged(true) + }} + /> + + + { + setPassword(e.target.value) + setInputChanged(true) + }} + /> + +
+ + { + inputChanged || !error ? + - : + + {error} + + } + + +
+
+
+ ); +} + +function mapStateToProps(state) { + const { auth } = state; + return { + user: auth.user, + error: auth.error, + isRequesting: auth.isRequesting + } +} + +export default connect(mapStateToProps)(Login); \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/index.js b/super-screen/client/src/sections/auth/index.js new file mode 100644 index 0000000..f8e40fb --- /dev/null +++ b/super-screen/client/src/sections/auth/index.js @@ -0,0 +1,12 @@ +'use strict'; + +import routes from './routes'; +import reducers from './reducers'; +import actions from './actions'; + +export default { + key: 'auth', + reducers: reducers, + routes: routes, + actions: actions +}; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/reducers/auth.js b/super-screen/client/src/sections/auth/reducers/auth.js new file mode 100644 index 0000000..edeebff --- /dev/null +++ b/super-screen/client/src/sections/auth/reducers/auth.js @@ -0,0 +1,40 @@ +'use strict'; +import * as actionTypes from '../actions/auth'; +import Immutable from 'immutable'; + +const initState = { + user: {}, + isRequesting: false, + error: null +}; + +function auth(state = initState, action) { + const payload = action.payload; + switch (action.type){ + case actionTypes.INIT_AUTH: + return Immutable.fromJS(state).set('user', payload.user).toJS(); + case actionTypes.REQUEST_LOGIN: + return Immutable.fromJS(state).merge({ + isRequesting: true, + error: null + }).toJS(); + case actionTypes.LOGIN_SUCCESS: + return Immutable.fromJS(state).merge({ + isRequesting: false, + user: payload.user + }).toJS(); + case actionTypes.LOGIN_ERROR: + return Immutable.fromJS(state).merge({ + isRequesting: false, + error: payload.error + }).toJS(); + case actionTypes.LOGOUT: + return Immutable.fromJS(state).merge({ + user: null + }).toJS(); + default: + return state; + } +} + +export default auth; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/reducers/index.js b/super-screen/client/src/sections/auth/reducers/index.js new file mode 100644 index 0000000..ba81f11 --- /dev/null +++ b/super-screen/client/src/sections/auth/reducers/index.js @@ -0,0 +1,6 @@ +'use strict'; +import auth from './auth' + +export default { + auth +}; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/routes.js b/super-screen/client/src/sections/auth/routes.js new file mode 100644 index 0000000..d9a14ac --- /dev/null +++ b/super-screen/client/src/sections/auth/routes.js @@ -0,0 +1,12 @@ +'use strict'; + +import { Login } from './containers'; + +export default [{ + type: 'outer', + route: { + key:'signin', + path: "/signin", + component: Login + } +}]; \ No newline at end of file diff --git a/super-screen/client/src/sections/auth/style.less b/super-screen/client/src/sections/auth/style.less new file mode 100644 index 0000000..5ed8001 --- /dev/null +++ b/super-screen/client/src/sections/auth/style.less @@ -0,0 +1,112 @@ +.login { + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + background-image: url('/assets/images/login_bg.png'); + background-size: 100% 100%; + + .left { + + background-size: 100% 100%; + background-repeat: no-repeat; + width: 55%; + height: 100%; + float: left; + top: 0px; + left: 0px; + } + + .right { + width: 45%; + height: 100%; + // background-color: #000066; + float: left; + right: 0px; + bottom: 0px; + } +} + +@media screen and (max-height:1440px) { + .loginBox { + top: 25%; + } +} + +@media screen and (max-height: 768px) { + .loginBox { + top: 20%; + } +} + +@media screen and (max-height: 630px) { + .loginBox { + top: 10%; + } +} + +.loginBox { + height: 50%; + width: 25%; + position: absolute; + right: 16.5%; + z-index: 20; + background: #fff; + text-align: center; + padding-top: 30px; + + @media screen and (min-height:1080px) { + height: 40%; + } + + ._title { + font-family: SourceHanSansCN-Medium; + font-weight: 500; + font-size: 24px; + color: rgba(0, 0, 0, 0.75); + letter-spacing: 0; + } + + ._divider { + width: 58px; + height: 4px; + background: #4263F7; + display: inline-block; + } + + h1 { + color: #fff; + font-size: 58px; + } + + .loginFormTit { + width: 20%; + font-size: 18px; + color: rgb(255, 255, 255); + // margin-bottom: 10px; + } + + .loginInp { + width: 80%; + height: 50px; + background: #ffffff; + border: 1px solid #C2C2C2; + border-radius: 5px; + } + + .loginBtn { + width: 80%; + height: 50px; + margin-top: 40px; + border-radius: 5px; + font-size: 16px; + background: #4263F7; + border-color: #4263F7; + } + + .loginBtn:hover { + background: #4263F7; + border-color: #4263F7; + } +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/actions/example.js b/super-screen/client/src/sections/homePage/actions/example.js new file mode 100644 index 0000000..6b3c25d --- /dev/null +++ b/super-screen/client/src/sections/homePage/actions/example.js @@ -0,0 +1,15 @@ +'use strict'; + +import { basicAction } from '@peace/utils' +import { ApiTable } from '$utils' + +// export function getMembers(orgId) { +// return dispatch => basicAction({ +// type: 'get', +// dispatch: dispatch, +// actionType: 'GET_MEMBERS', +// url: `${ApiTable.getEnterprisesMembers.replace('{enterpriseId}', orgId)}`, +// msg: { error: '获取用户列表失败' }, +// reducer: { name: 'members' } +// }); +// } diff --git a/super-screen/client/src/sections/homePage/actions/index.js b/super-screen/client/src/sections/homePage/actions/index.js new file mode 100644 index 0000000..444af37 --- /dev/null +++ b/super-screen/client/src/sections/homePage/actions/index.js @@ -0,0 +1,7 @@ +'use strict'; + +import * as example from './example' + +export default { + ...example, +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/components/abnormalMonitoring.js b/super-screen/client/src/sections/homePage/components/abnormalMonitoring.js new file mode 100644 index 0000000..e2107ed --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/abnormalMonitoring.js @@ -0,0 +1,49 @@ +import React, { useEffect, useState } from 'react' +import CarouselList from './public/carousel-list'; +import { Tooltip } from 'antd'; +import { ApiTable, useFsRequest } from '$utils'; +import moment from 'moment'; +function AbnormalMonitoring(props) { + + const { data: logs = {} } = useFsRequest({ + url: ApiTable.getLogs, + query: { + logState: false, + startTime: moment().subtract(7, 'days').format('YYYY-MM-DD HH:mm:ss'), + endTime: moment().format('YYYY-MM-DD HH:mm:ss') + }, + pollingInterval: 1000 * 60 + }); + + const dataSource = logs?.rows ? logs?.rows?.map(s => { + return [ +
+ + {s?.acquisitionTask?.taskName?.length > 20 ? s?.acquisitionTask?.taskNamesubstring(0, 20) + '...' : s?.acquisitionTask?.taskName} + +
, + moment(s?.startTime).format('YYYY-MM-DD HH:mm:ss'), + moment(s?.endTime).valueOf() - moment(s?.startTime).valueOf() + '毫秒', +
+ + {s?.details?.length > 20 ? s?.details.substring(0, 20) + '...' : s?.details} + +
+ ] + }) : [] + return
+
异常监控
+ +
+} + +export default AbnormalMonitoring; + + diff --git a/super-screen/client/src/sections/homePage/components/accessData.js b/super-screen/client/src/sections/homePage/components/accessData.js new file mode 100644 index 0000000..2d37d29 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/accessData.js @@ -0,0 +1,36 @@ +import React from 'react' +import Box from './public/table-card'; +import { useFsRequest } from '$utils'; +import { mathRound } from './util' +function AccessData() { + + const { data: accessdata = [] } = useFsRequest({ + url: 'homepage/accessdata', + pollingInterval: 1000 * 60, + cacheKey: 'accessdata', + }); + + + const renderBody = () => { + return
+
+
+ 数据单位
{!accessdata?.projects ? '-' : accessdata?.projects?.split(',')?.length}
个 +
+
+ 今日数据
{!accessdata?.res?.stat?.today ? '-' : accessdata?.res?.stat?.today > 1000 ? mathRound(accessdata?.res?.stat?.today) : accessdata?.res?.stat?.today}
{accessdata?.res?.stat?.today > 1000 ? '万条' : '条'} +
+
+ 数据总量
{accessdata?.res?.stat?.datas ? Math.round(accessdata?.res?.stat?.datas / 10000) : '-'}
万条 +
+
+ } + + return + {renderBody()} + +} + +export default AccessData; + + diff --git a/super-screen/client/src/sections/homePage/components/alarmList.js b/super-screen/client/src/sections/homePage/components/alarmList.js new file mode 100644 index 0000000..55181b5 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/alarmList.js @@ -0,0 +1,52 @@ +import React from 'react' +import Box from './public/table-card'; +import CarouselList from './public/carousel-list'; +import { Tooltip } from 'antd'; +import moment from 'moment'; +import NoData from './public/noData'; +import { useFsRequest } from '$utils'; + +function AlarmList(props) { + const { cardContentHeight } = props; + const { data: alarms = [] } = useFsRequest({ + url: 'homepage/alarms', + pollingInterval: 1000 * 60, + cacheKey: 'alarms', + }); + + + const data = alarms.map(s => { + return [ + s.content, + s.level == 1 ? '一级' : s.level == 2 ? '二级' : s.level == 3 ? '三级' : '四级', + moment(s.time).format('YYYY-MM-DD HH:mm:ss') + ] + }) + + const renderBody = () => { + return { + return [ + + {s[0].length > 20 ? s[0]?.substring(0, 20) + '...' : s[0]} + , +
{s[1]}
, + s[2] + ] + })} + rowNum={6} + height={cardContentHeight} + multiellipsis + columnWidth={[180, 80, 150]} + /> + } + + return + {alarms?.length > 0 ? renderBody() : } + +} + +export default AlarmList; + + diff --git a/super-screen/client/src/sections/homePage/components/centerTop.js b/super-screen/client/src/sections/homePage/components/centerTop.js new file mode 100644 index 0000000..a70d656 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/centerTop.js @@ -0,0 +1,19 @@ +import React from 'react' +import './style.less' + +function CenterTop(props) { + + + return
+
+
共享交换
+
数据监控
+
数据治理
+
数据采集
+
+
+} + +export default CenterTop; + + diff --git a/super-screen/client/src/sections/homePage/components/dataShare.js b/super-screen/client/src/sections/homePage/components/dataShare.js new file mode 100644 index 0000000..c8f2b08 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/dataShare.js @@ -0,0 +1,54 @@ +import React from 'react' +import Box from './public/table-card'; +import { useFsRequest } from '$utils'; +import { mathRound } from './util'; +function DataShare(props) { + + const { data: dataTotal = {} } = useFsRequest({ + url: 'homepage/datatotal/top5', + pollingInterval: 1000 * 60, + cacheKey: 'datatotal', + }); + + const { data: restfulInfo = {} } = useFsRequest({ + url: 'homepage/restful/info', + pollingInterval: 1000 * 60, + cacheKey: 'restfulInfo', + }); + + const renderItem = (s) => { + return
+
+
+ {s.title} +
+ {s.data}{s.unit} +
+
+
+ } + + const leftData = [ + { key: '1', data: mathRound(dataTotal?.total), unit: '万条', title: '共享库数据总量' }, + { key: '2', data: restfulInfo?.total, unit: '次', title: '访问接口总次数' }, + { key: '3', data: restfulInfo?.totalUser, unit: '个', title: '访问接口用户总数' }] + const rightData = [ + { key: '2', data: restfulInfo?.todayTotal, unit: '次', title: '接口访问次数' }, + { key: '3', data: restfulInfo?.todayUser, unit: '个', title: '访问接口用户总数' }] + + return +
+
+ {leftData.map(s => renderItem(s))} +
+
+
今日
+ {rightData.map(s => renderItem(s))} +
+
+
+} + +export default DataShare; + + diff --git a/super-screen/client/src/sections/homePage/components/dataTop5.js b/super-screen/client/src/sections/homePage/components/dataTop5.js new file mode 100644 index 0000000..bbe7a9e --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/dataTop5.js @@ -0,0 +1,262 @@ +import React, { useEffect, useState } from 'react' +import Box from './public/table-card'; +import ReactEcharts from 'echarts-for-react'; +import './style.less'; +import { useFsRequest } from '$utils'; +import { mathRound } from './util'; +import NoData from './public/noData'; +function DataTop5(props) { + const { cardContentHeight } = props; + const { data: dataTotal = {} } = useFsRequest({ + url: 'homepage/datatotal/top5', + pollingInterval: 1000 * 60, + cacheKey: 'datatotal', + }); + + const renderBody = () => { + let chartData = dataTotal?.top5?.map(x => { + return { + name: x?.dataSource?.resourceCatalog?.name, + value: mathRound(x.dbRecordCount), + } + }) || [] + + let options = { + xAxis: { + splitLine: { + show: false, + }, + axisLabel: { + show: false, + }, + axisTick: { + show: false, + }, + splitArea: { show: false }, + axisLine: { + show: false, + }, + }, + tooltip: { + confine: true, + trigger: 'axis', + axisPointer: { + type: 'shadow', + }, + backgroundColor: 'rgba(13,30,44, 0.7)', + borderColor: 'rgba(3, 65, 118, 0.8)', + textStyle: { + color: '#fff', + }, + formatter: function (params) { + var name = params[0].name + if (name.length > 20) { + name = name.replace(/(.{20})/g, '$1
') // 每 30 个字符添加一个换行符 + } + var content = name + + return content + ' : ' + params[0].value + '万条' + } + }, + grid: { + top: 13, + bottom: -10, + left: '5%', + }, + yAxis: { + inverse: true, + axisLine: { + show: false, + }, + axisTick: { + show: false, + }, + axisLabel: { + textStyle: { + color: '#fff', + padding: [-5, 0, 35, 18], + }, + formatter(value, index) { + let str = '', num = 'TOP' + (index + 1) + let valueHandle = value.length > 10 ? value.substring(0, 10) + '...' : value + if (index === 0) { + str = '{a| ' + num + '}{title| ' + valueHandle + '}' + } else if (index === 1) { + str = '{b| ' + num + '}{title| ' + valueHandle + '}' + } else if (index === 2) { + str = '{c| ' + num + '}{title| ' + valueHandle + '}' + } else { + str = '{d| ' + num + '}{title| ' + valueHandle + '}' + } + return str + }, + rich: { + a: { + borderColor: '#EE6F7C', + borderWidth: 1, + borderRadius: [0, 10, 10, 0], + padding: [3.5, 10, 1, -13], + backgroundColor: 'rgba(238, 111, 124, 0.8)', + }, + b: { + borderColor: '#FFCF5F', + borderWidth: 1, + borderRadius: [0, 10, 10, 0], + padding: [3.5, 10, 1, -13], + backgroundColor: 'rgba(255, 207, 95, 0.7)', + }, + c: { + borderColor: '#00E8FF', + borderWidth: 1, + borderRadius: [0, 10, 10, 0], + padding: [3.5, 10, 1, -13], + backgroundColor: 'rgba(0, 232, 255, 0.7)', + }, + d: { + borderColor: '#1A90FF', + borderWidth: 1, + borderRadius: [0, 10, 10, 0], + padding: [3.5, 10, 1, -13], + backgroundColor: 'rgba(26, 144, 255, 0.7)', + }, + title: { + padding: [0, 0, 0, 3], + }, + }, + align: 'left', + }, + data: chartData.map((item) => item.name), + }, + series: [ + { + type: 'pictorialBar', + symbol: 'rect', + symbolRotate: 30, + symbolRepeat: 'fixed', + symbolClip: true, + symbolOffset: [0, -1.5], + symbolSize: [2, 12], + symbolMargin: '3', + itemStyle: { + normal: { + color: '#000726', + }, + }, + label: { + show: true, + color: '#C8F0FF', + fontFamily: 'Bebas', + fontSize: 12, + offset: [-9, 1], + position: 'right', + formatter(params) { + let result = '' + switch (params.dataIndex) { + case 0: + result = '{img|}{index0|' + params.value + '}{unit|}' + break + case 1: + result = '{img|}{index1|' + params.value + '}{unit|}' + break + case 2: + result = '{img|}{index2|' + params.value + '}{unit|}' + break + default: + result = '{img|}{index3|' + params.value + '}{unit|}' + break + } + return result + }, + rich: { + img: { + height: 18, + width: 20, + // backgroundColor: { image: arrow },这个图片自己切,这里上传不了(加了一个尾巴的形状) + }, + unit: { + color: '#C8F0FF', + fontSize: 11, + }, + index0: { + color: '#FFF', + fontFamily: 'Bebas', + padding: [-2, 2, 0, 0], + fontWeight: 'bold', + fontSize: 16, + }, + index1: { + color: '#FFF', + fontFamily: 'Bebas', + padding: [-2, 2, 0, 0], + fontWeight: 'bold', + fontSize: 16, + }, + index2: { + color: '#FFF', + fontFamily: 'Bebas', + padding: [-2, 2, 0, 0], + fontWeight: 'bold', + fontSize: 16, + }, + index3: { + color: '#FFF', + fontFamily: 'Bebas', + padding: [-2, 2, 0, 0], + fontWeight: 'bold', + fontSize: 16, + }, + }, + }, + symbolBoundingData: Math.max(...chartData.map((item) => item.value)) * 1.3, + data: chartData.map((item) => item.value), + z: 2, + }, + { + type: 'bar', + barWidth: 10, + data: chartData.map((item) => item.value), + itemStyle: { + normal: { + color: '#54DEFA', + }, + }, + z: 1, + }, + { + type: 'bar', + barGap: '-125%', // 设置外框粗细 + data: chartData.map((items) => Math.max(...chartData.map((item) => item.value)) * 1.3), + barWidth: 15, + itemStyle: { + color: 'none', + borderColor: '#979797', + }, + z: 0, + }, + ], + }; + + return + } + + return + { + dataTotal?.top5?.length > 0 ? + <> +
数据量:万条
+ {renderBody()} + + : + } + +
+} + +export default DataTop5; + + diff --git a/super-screen/client/src/sections/homePage/components/hotspotData.js b/super-screen/client/src/sections/homePage/components/hotspotData.js new file mode 100644 index 0000000..f8a7240 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/hotspotData.js @@ -0,0 +1,42 @@ +import React, { useEffect, useState } from 'react' +import Box from './public/table-card'; +import NoData from './public/noData'; +import './style.less'; +import { ApiTable, useFsRequest } from '$utils'; +function HotspotData(props) { + + const { data: restfulInfo = {} } = useFsRequest({ + url: 'homepage/restful/info', + pollingInterval: 1000 * 60, + cacheKey: 'restfulInfo', + }); + + const top3 = restfulInfo?.top3 + return + {top3?.length > 0 ? +
+
+
+ {top3[0].name?.length > 8 ? top3[0].name.substring(0, 8) + '...' : top3[0].name} +
{top3[0].count}
+
+
+ {top3?.length > 2 && <> + {top3[2].name?.length > 8 ? top3[2].name.substring(0, 8) + '...' : top3[2].name} +
{top3[2].count}
+ } +
+
+ {top3?.length > 1 && <> + {top3[1].name?.length > 8 ? top3[1].name.substring(0, 8) + '...' : top3[1].name} +
{top3[1].count}
+ } +
+
: + } +
+} + +export default HotspotData; + + diff --git a/super-screen/client/src/sections/homePage/components/nodeResource.js b/super-screen/client/src/sections/homePage/components/nodeResource.js new file mode 100644 index 0000000..e142a1e --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/nodeResource.js @@ -0,0 +1,39 @@ +import React, { useEffect, useState } from 'react' +import Box from './public/table-card'; +import { ApiTable, useFsRequest } from '$utils'; +import './style.less'; +function NodeResource(props) { + const { data: cluters = {} } = useFsRequest({ + url: 'homepage/datatotal/cluters', + pollingInterval: 1000 * 20, + }); + + const renderBody = () => { + return
+
+
{cluters?.disk}%
+
硬盘
+
+
+
+
{cluters?.memory}%
+
内存
+
+
+
+
{cluters?.cpu}%
+
CPU
+
+
+
+ + } + + return + {renderBody()} + +} + +export default NodeResource; + + diff --git a/super-screen/client/src/sections/homePage/components/public/carousel-list.js b/super-screen/client/src/sections/homePage/components/public/carousel-list.js new file mode 100644 index 0000000..8aaf397 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/carousel-list.js @@ -0,0 +1,33 @@ +/* 轮播列表组件 */ +import React from 'react'; +import ScrollBoard from './scrollBoard'; +import NoData from './noData'; +import './index.less'; +function CarouselList(props) { + const { + header = [], data = [], rowNum = 4, height, columnWidth, multiellipsis, waitTime = 2000, marginTop, ...restProps + } = props; + + const config = { + header, + rowNum, + headerBGC: 'rgba(81, 200, 247, 0.2)', + oddRowBGC: 'transparent', + evenRowBGC: 'transparent', + headerHeight: 30, + data, + waitTime, + columnWidth: columnWidth || [], + }; + + return data.length > 0 ? ( + + ) : ; +} + +export default CarouselList; diff --git a/super-screen/client/src/sections/homePage/components/public/index.less b/super-screen/client/src/sections/homePage/components/public/index.less new file mode 100644 index 0000000..e67fb57 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/index.less @@ -0,0 +1,80 @@ +.opcityBackground { + background-color: rgba(8, 27, 55, 0.6); +} + +.card-title { + // background: linear-gradient(to bottom, #fafafb, #92cbff); + // background-clip: border-box; + // -webkit-background-clip: text; + color: #fff; + font-size: 22px; + font-family: YouSheBiaoTiHei; + padding-left: 20px; + // font-weight: 600; +} + +/* 滚动列表 */ +.scroll-board { + width: 533px; + height: 220px; + margin-top: 10px; + margin-left: 6px; + + .header { + height: 30px; + border-top: 1px solid #0047ba; + border-bottom: 1px solid #0047ba; + + .header-item { + // background: rgba(12, 49, 110, 0.3); + margin-right: 10px; + } + } + + .rows { + .row-item { + font-size: 16px; + } + + .row-item:hover { + background: linear-gradient(270deg, rgba(17, 183, 247, 0) 0%, rgba(17, 183, 247, 0.85) 100%); + color: #9ac8fc; + } + } +} + +.scroll-board-multi { + padding: 5px 0px 5px; + color: rgba(204, 228, 255, 1) !important; + + .header { + display: flex; + flex-direction: row; + font-size: 12px !important; + color: rgba(204, 228, 255, 1) !important; + // border-bottom: 1px solid #124C79 !important; + } + + .rows { + color: rgba(204, 228, 255, 1) !important; + + .row-item { + border-bottom: 1px solid #124C79 !important; + } + + .row-item:hover { + background: linear-gradient(270deg, rgba(17, 183, 247, 0) 0%, rgba(17, 183, 247, 0.85) 100%); + color: #9ac8fc; + } + } +} + +._sorrow { + display: inline-block; + width: 15px; + height: 15px; + background: url('/assets/images/homePage/bigscreen/sorrow.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + margin-left: 13px; +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/components/public/noData.js b/super-screen/client/src/sections/homePage/components/public/noData.js new file mode 100644 index 0000000..9d5bb13 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/noData.js @@ -0,0 +1,18 @@ +/* 公共模块暂无数据组件 */ +import React from 'react'; +import { Empty } from 'antd'; + +function NoData({ height = 180, marginTop = 0 }) { + return ( + + ); +} + +export default NoData; diff --git a/super-screen/client/src/sections/homePage/components/public/scrollBoard/index.js b/super-screen/client/src/sections/homePage/components/public/scrollBoard/index.js new file mode 100644 index 0000000..fbddde3 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/scrollBoard/index.js @@ -0,0 +1,469 @@ +import React, { + useEffect, useState, useRef, useMemo, forwardRef, +} from 'react'; + +import PropTypes from 'prop-types'; + +import classnames from 'classnames'; + +import { deepMerge } from '@jiaminghi/charts/lib/util/index'; + +import { deepClone } from '@jiaminghi/c-render/lib/plugin/util'; + +import { useAutoResize, co } from '@jiaminghi/data-view-react'; + +import './style.less'; + +const defaultConfig = { + /** + * @description Board header + * @type {Array} + * @default header = [] + * @example header = ['column1', 'column2', 'column3'] + */ + header: [], + /** + * @description Board data + * @type {Array} + * @default data = [] + */ + data: [], + /** + * @description Row num + * @type {Number} + * @default rowNum = 5 + */ + rowNum: 5, + /** + * @description Header background color + * @type {String} + * @default headerBGC = '#00BAFF' + */ + headerBGC: '#00BAFF', + /** + * @description Odd row background color + * @type {String} + * @default oddRowBGC = '#003B51' + */ + oddRowBGC: '#003B51', + /** + * @description Even row background color + * @type {String} + * @default evenRowBGC = '#003B51' + */ + evenRowBGC: '#0A2732', + /** + * @description Scroll wait time + * @type {Number} + * @default waitTime = 2000 + */ + waitTime: 2000, + /** + * @description Header height + * @type {Number} + * @default headerHeight = 35 + */ + headerHeight: 35, + /** + * @description Column width + * @type {Array} + * @default columnWidth = [] + */ + columnWidth: [], + /** + * @description Column align + * @type {Array} + * @default align = [] + * @example align = ['left', 'center', 'right'] + */ + align: [], + /** + * @description Show index + * @type {Boolean} + * @default index = false + */ + index: false, + /** + * @description index Header + * @type {String} + * @default indexHeader = '#' + */ + indexHeader: '#', + /** + * @description Carousel type + * @type {String} + * @default carousel = 'single' + * @example carousel = 'single' | 'page' + */ + carousel: 'single', + /** + * @description Pause scroll when mouse hovered + * @type {Boolean} + * @default hoverPause = true + * @example hoverPause = true | false + */ + hoverPause: true, +}; + +function calcHeaderData({ header, index, indexHeader }) { + if (!header.length) { + return []; + } + + header = [...header]; + + if (index) header.unshift(indexHeader); + + return header; +} + +function calcRows({ + data, index, headerBGC, rowNum, +}) { + if (index) { + data = data.map((row, i) => { + row = [...row]; + + const indexTag = `${i + + 1}`; + + row.unshift(indexTag); + + return row; + }); + } + + data = data.map((ceils, i) => ({ ceils, rowIndex: i })); + + const rowLength = data.length; + + if (rowLength > rowNum && rowLength < 2 * rowNum) { + data = [...data, ...data]; + } + + return data.map((d, i) => ({ ...d, scroll: i })); +} + +function calcAligns(mergedConfig, header) { + const columnNum = header.length; + + const aligns = new Array(columnNum).fill('left'); + + const { align } = mergedConfig; + + return deepMerge(aligns, align); +} + +const ScrollBoard = forwardRef(({ + onClick, config = {}, className, style, onMouseOver, +}, ref) => { + const { width, height, domRef } = useAutoResize(ref); + + const [state, setState] = useState({ + mergedConfig: null, + + header: [], + + rows: [], + + rowsShow: [], + + widths: [], + + heights: [], + + aligns: [], + }); + + const { + mergedConfig, header, rows, widths, heights, aligns, rowsShow, + } = state; + + const stateRef = useRef({ + ...state, + rowsData: [], + avgHeight: 0, + animationIndex: 0, + }); + + Object.assign(stateRef.current, state); + + function onResize() { + if (!mergedConfig) return; + + const widths = calcWidths(mergedConfig, stateRef.current.rowsData); + + const heights = calcHeights(mergedConfig, header); + + const data = { widths, heights }; + + Object.assign(stateRef.current, data); + setState((state) => ({ ...state, ...data })); + } + const [init, setInit] = useState(true); + + function calcData() { + // const mergedConfig = deepMerge( + // deepClone(defaultConfig, true), + // config || {}, + // ); + const mergedConfig = { + ...defaultConfig, + ...config, + }; + + const header = calcHeaderData(mergedConfig); + + const rows = calcRows(mergedConfig); + + const widths = calcWidths(mergedConfig, stateRef.current.rowsData); + + const heights = calcHeights(mergedConfig, header); + + const aligns = calcAligns(mergedConfig, header); + + const data = { + mergedConfig, + header, + rows, + widths, + aligns, + heights: init ? heights : state.heights.concat(heights), + rowsShow: init ? rows : state.rowsShow, + }; + setInit(false); + Object.assign(stateRef.current, data, { + rowsData: rows, + animationIndex: stateRef.current.animationIndex, + }); + + setState((state) => ({ ...state, ...data })); + } + + function calcWidths({ columnWidth, header }, rowsData) { + const usedWidth = columnWidth.reduce((all, w) => all + w, 0); + + let columnNum = 0; + if (rowsData[0]) { + columnNum = rowsData[0].ceils.length; + } else if (header.length) { + columnNum = header.length; + } + + const avgWidth = (width - usedWidth) / (columnNum - columnWidth.length); + + const widths = new Array(columnNum).fill(avgWidth); + + return deepMerge(widths, columnWidth); + } + + function calcHeights({ headerHeight, rowNum, data }, header) { + let allHeight = height; + + if (header.length) allHeight -= headerHeight; + + const avgHeight = allHeight / rowNum; + + Object.assign(stateRef.current, { avgHeight }); + + return new Array(data.length).fill(avgHeight); + } + + function* animation(start = false) { + let { + avgHeight, + animationIndex, + mergedConfig: { waitTime, carousel, rowNum }, + rowsData, + } = stateRef.current; + + const rowLength = rowsData.length; + + if (start) yield new Promise((resolve) => setTimeout(resolve, waitTime)); + + const animationNum = carousel === 'single' ? 1 : rowNum; + + let rows = rowsData.slice(animationIndex); + rows.push(...rowsData.slice(0, animationIndex)); + rows = rows.slice(0, carousel === 'page' ? rowNum * 2 : rowNum + 1); + + const heights = new Array(rowLength).fill(avgHeight); + setState((state) => ({ + ...state, rows, heights, rowsShow: rows, + })); + + yield new Promise((resolve) => setTimeout(resolve, 300)); + + animationIndex += animationNum; + + const back = animationIndex - rowLength; + if (back >= 0) animationIndex = back; + + const newHeights = [...heights]; + newHeights.splice(0, animationNum, ...new Array(animationNum).fill(0)); + + Object.assign(stateRef.current, { animationIndex }); + setState((state) => ({ ...state, heights: newHeights })); + } + + function emitEvent(handle, ri, ci, row, ceil) { + const { ceils, rowIndex } = row; + + handle && handle({ + row: ceils, ceil, rowIndex, columnIndex: ci, + }); + } + + function handleHover(enter, ri, ci, row, ceil) { + if (enter) emitEvent(onMouseOver, ri, ci, row, ceil); + + if (!mergedConfig.hoverPause) return; + + const { pause, resume } = task.current; + + enter && pause && resume ? pause() : resume && resume(); + } + + // updateRows(rows, animationIndex) { + // const { mergedConfig, animationHandler, animation } = this + // this.mergedConfig = { + // ...mergedConfig, + // data: [...rows] + // } + // this.needCalc = true + // if (typeof animationIndex === 'number') this.animationIndex = animationIndex + // if (!animationHandler) animation(true) + // } + + const getBackgroundColor = (rowIndex) => mergedConfig[rowIndex % 2 === 0 ? 'evenRowBGC' : 'oddRowBGC']; + + const task = useRef({}); + + useEffect(() => { + calcData(); + + let start = true; + + function* loop() { + while (true) { + yield* animation(start); + + start = false; + + const { waitTime } = stateRef.current.mergedConfig; + + yield new Promise((resolve) => setTimeout(resolve, waitTime - 300)); + } + } + + const { + mergedConfig: { rowNum }, + rows: rowsData, + } = stateRef.current; + + const rowLength = rowsData.length; + + if (rowNum >= rowLength) { + setState((prestate) => ({ + ...prestate, rowsShow: state.rows, + })); + return; + } + + task.current = co(loop); + + return task.current.end; + }, [config, domRef.current]); + + useEffect(onResize, [width, height, domRef.current]); + + const classNames = useMemo(() => classnames('dv-scroll-board', className), [ + className, + ]); + + return ( +
+ {!!header.length && !!mergedConfig && ( +
+ {header.map((headerItem, i) => ( +
+ ))} +
+ )} + + {!!mergedConfig && ( +
+ {rowsShow.map((row, ri) => ( +
+ {row.ceils.map((ceil, ci) => { + if (typeof (ceil) === 'string') { + return ( +
emitEvent(onClick, ri, ci, row, ceil)} + onMouseEnter={() => handleHover(true, ri, ci, row, ceil)} + onMouseLeave={() => handleHover(false)} + /> + ); + } + return ( +
handleHover(true, ri, ci, row, ceil)} + onMouseLeave={() => handleHover(false)} + > + {ceil} +
+ ); + })} +
+ ))} +
+ )} +
+ ); +}); + +ScrollBoard.propTypes = { + config: PropTypes.object, + onClick: PropTypes.func, + onMouseOver: PropTypes.func, + className: PropTypes.string, + style: PropTypes.object, +}; + +export default ScrollBoard; diff --git a/super-screen/client/src/sections/homePage/components/public/scrollBoard/style.less b/super-screen/client/src/sections/homePage/components/public/scrollBoard/style.less new file mode 100644 index 0000000..cb6eea5 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/scrollBoard/style.less @@ -0,0 +1,44 @@ +.dv-scroll-board { + position: relative; + width: 100%; + height: 100%; + color: #fff; + + .text { + padding: 0 10px; + box-sizing: border-box; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + .header { + display: flex; + flex-direction: row; + font-size: 15px; + + .header-item { + .text; + transition: all 0.3s; + } + } + + .rows { + overflow: hidden; + + .row-item { + display: flex; + font-size: 14px; + transition: all 0.3s; + } + + .ceil { + .text; + } + + .index { + border-radius: 3px; + padding: 0px 3px; + } + } +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/components/public/table-card.js b/super-screen/client/src/sections/homePage/components/public/table-card.js new file mode 100644 index 0000000..ada8a4e --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/public/table-card.js @@ -0,0 +1,34 @@ +'use strict' + +import React from 'react' +import './index.less' +class Box extends React.Component { + render() { + const { title, height = '100%', children, bodyPaddingTop = 1, titlePaddingTop, margin, overflow } = this.props + + const headerbg = { + background: 'url(/assets/images/homePage/bigscreen/headertitlebg.png) no-repeat', + backgroundSize: '100% 100%', + } + return ( +
+
+
+ {title}
+
+
+ {children} +
+
+ ) + } +} +export default Box + diff --git a/super-screen/client/src/sections/homePage/components/style.less b/super-screen/client/src/sections/homePage/components/style.less new file mode 100644 index 0000000..b544be6 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/style.less @@ -0,0 +1,373 @@ +@card-height: calc(100% - 42px - 13px); //左右卡片内容高度定义 目前卡片为等高 + +//节点资源 +.node-resource-container { + display: flex; + height: @card-height; + width: 100%; + align-items: center; + + ._item { + width: 33%; + display: flex; + flex-direction: column; + align-items: center; + + ._noderesource_data { + font-family: D-DINExp-Bold; + font-weight: 600; + font-size: 24px; + color: #FFFFFF; + line-height: 43.2px; + display: flex; + align-items: center; + + ._percent { + opacity: 0.8; + font-family: PingFangSC-Regular; + font-weight: 400; + font-size: 12px; + color: #C8F0FF; + text-align: left; + line-height: 24px; + } + } + + ._noderesource_title { + font-family: YouSheBiaoTiHei; + font-size: 20px; + color: #D8F0FF; + letter-spacing: 1.54px; + text-align: center; + text-shadow: 0 0 10px rgba(0, 145, 255, 0.5); + margin-bottom: 17px; + } + + .disk_icon { + width: 68.73px; + height: 62.77px; + background: url('/assets/images/homePage/bigscreen/disk.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + .cpu_icon { + width: 68.73px; + height: 62.77px; + background: url('/assets/images/homePage/bigscreen/cpu.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + .memory_icon { + width: 68.73px; + height: 62.77px; + background: url('/assets/images/homePage/bigscreen/memory.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + } +} + +//接入数据统计 +.access_data { + display: flex; + height: @card-height; + width: 100%; + justify-content: center; + + font-family: PingFangSC-Regular; + font-weight: 400; + font-size: 14px; + color: #FFFFFF; + + ._img { + width: 230px; + height: 95%; + background: url('/assets/images/homePage/bigscreen/accessdata.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + .data_unit { + position: absolute; + top: 27%; + right: 21%; + + .data_number { + line-height: 25px; + font-family: D-DINExp-Bold; + font-weight: 700; + font-size: 20px; + color: #3E86FF; + letter-spacing: 0; + } + } + + .data_today { + position: absolute; + bottom: 13%; + right: 79%; + text-align: right; + + .data_number { + line-height: 25px; + font-family: D-DINExp-Bold; + font-weight: 700; + font-size: 20px; + color: #00F6E4; + letter-spacing: 0; + } + } + + .data_total { + position: absolute; + bottom: 13%; + left: 79%; + + .data_number { + line-height: 25px; + font-family: D-DINExp-Bold; + font-weight: 700; + font-size: 20px; + color: #FFDC4E; + letter-spacing: 0; + } + } +} + +.data_top5_unit { + position: absolute; + right: 4%; + top: 18%; + font-family: PingFangSC-Regular; + font-weight: 400; + font-size: 12px; + color: #C8F0FF; +} + +.hotspot_data_container { + display: flex; + height: @card-height; + width: 100%; + justify-content: center; + + font-family: PingFangSC-Regular; + font-weight: 400; + font-size: 14px; + color: #FFFFFF; + + ._img { + width: 203px; + height: 80%; + background: url('/assets/images/homePage/bigscreen/hotspotdatabg.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + .hotspot_title { + padding: 2px; + padding-left: 6px; + padding-right: 6px; + background: rgba(77, 241, 227, 0.08); + border: 1px solid rgba(77, 241, 227, 0.1); + box-shadow: inset 0 0 20px 0 rgba(28, 185, 196, 0.23); + } + + + .hotspot_data_number { + font-family: D-DINExp-Bold; + font-weight: 700; + font-size: 18px; + color: #FFFFFF; + } + + ._top1 { + position: absolute; + top: 25%; + right: 63%; + text-align: right; + } + + ._top2 { + position: absolute; + bottom: 22%; + right: 67%; + text-align: center; + } + + ._top3 { + position: absolute; + bottom: 34%; + left: 73%; + } +} + +//数据共享 +.data_share { + display: flex; + height: @card-height; + + ._left_content { + width: 50%; + height: 90%; + padding-left: 30px; + display: flex; + flex-direction: column; + justify-content: space-between; + } + + ._right_content { + ._today_text { + font-family: YouSheBiaoTiHei; + font-size: 24px; + color: #FFFFFF; + letter-spacing: 0.5px; + position: absolute; + right: 6%; + top: 21%; + } + + padding-top: 23px; + display: flex; + flex-direction: column; + width: 47%; + height: 95%; + background: url(/assets/images/homePage/bigscreen/todaybg.png); + background-repeat: no-repeat; + background-size: 100% 100%; + justify-content: space-evenly; + align-items: center; + + } + + ._item_content { + display: flex; + + + ._item_icon1 { + width: 52px; + height: 52px; + background: url('/assets/images/homePage/bigscreen/1.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + ._item_icon2 { + width: 52px; + height: 52px; + background: url('/assets/images/homePage/bigscreen/2.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + ._item_icon3 { + width: 52px; + height: 52px; + background: url('/assets/images/homePage/bigscreen/3.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + ._item_text { + color: #C8F0FF; + padding-left: 6px; + + .number_container { + ._number { + font-family: D-DINExp-Bold; + font-weight: 700; + font-size: 22px; + color: #FFFFFF; + } + + display: flex; + align-items: center; + justify-content: space-evenly; + width: 112px; + height: 28px; + background-image: linear-gradient(227deg, #3196AB 0%, #2091cd00 100%); + } + } + } +} + +//大屏中间上部分 +.center_top_data { + + ._center_card1 { + width: 353px; + height: 74px; + font-family: YouSheBiaoTiHei; + font-size: 22px; + color: #FFFFFF; + letter-spacing: 0.46px; + text-align: center; + position: absolute; + top: -3%; + left: 32%; + background: url(/assets/images/homePage/bigscreen/centerdatabg1.png); + background-repeat: no-repeat; + background-size: 100% 100%; + display: flex; + align-items: center; + justify-content: center; + } + + ._center_card2 { + width: 146px; + height: 35px; + font-family: YouSheBiaoTiHei; + font-size: 16px; + color: #35D0FF; + letter-spacing: 0.46px; + text-align: center; + position: absolute; + top: 26%; + left: 42%; + background: url(/assets/images/homePage/bigscreen/centerdatabg2.png); + background-repeat: no-repeat; + background-size: 100% 100%; + display: flex; + align-items: center; + justify-content: center; + } + + ._center_card3 { + width: 146px; + height: 35px; + font-family: YouSheBiaoTiHei; + font-size: 16px; + color: #35D0FF; + letter-spacing: 0.46px; + text-align: center; + position: absolute; + top: 52%; + left: 42%; + background: url(/assets/images/homePage/bigscreen/centerdatabg2.png); + background-repeat: no-repeat; + background-size: 100% 100%; + display: flex; + align-items: center; + justify-content: center; + } + + ._center_card4 { + width: 146px; + height: 35px; + font-family: YouSheBiaoTiHei; + font-size: 16px; + color: #35D0FF; + letter-spacing: 0.46px; + text-align: center; + position: absolute; + top: 74%; + left: 42%; + background: url(/assets/images/homePage/bigscreen/centerdatabg2.png); + background-repeat: no-repeat; + background-size: 100% 100%; + display: flex; + align-items: center; + justify-content: center; + } +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/components/util.js b/super-screen/client/src/sections/homePage/components/util.js new file mode 100644 index 0000000..1a4c117 --- /dev/null +++ b/super-screen/client/src/sections/homePage/components/util.js @@ -0,0 +1,3 @@ +export const mathRound = (number) => { + return number ? Math.round(number / 1000) / 10 : 0 +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/containers/homePage.js b/super-screen/client/src/sections/homePage/containers/homePage.js new file mode 100644 index 0000000..ef570f6 --- /dev/null +++ b/super-screen/client/src/sections/homePage/containers/homePage.js @@ -0,0 +1,74 @@ +import React, { useEffect, useState } from 'react' +import { connect } from 'react-redux'; +import { push } from 'react-router-redux'; +import AccessData from '../components/accessData' +import AlarmList from '../components/alarmList' +import DataShare from '../components/dataShare' +import DataTop5 from '../components/dataTop5' +import HotspotData from '../components/hotspotData' +import NodeResource from '../components/nodeResource' +import AbnormalMonitoring from '../components/abnormalMonitoring' +import CenterTop from '../components/centerTop' +import './style.less' + +function homePage(props) { + const { dispatch } = props; + const childStyle = { height: '32%', color: '#fff', marginBottom: 17 } + const cardHeight = document.body.clientHeight * 0.896 * 0.32 + const cardContentHeight = cardHeight - 42 - 13 + return
+
+
{ dispatch(push('/metadataManagement/latestMetadata')) }} className='_exit' >
进入后台
+
+
+
+
+ +
+
+ +
+
+ +
+
+
+
+ +
+
+ +
+
+
+
+
+
+ +
+
+ +
+
+ +
+
+
+
+ +} + +function mapStateToProps(state) { + const { + auth, global + } = state; + return { + clientHeight: global.clientHeight, + actions: global.actions, + + }; +} + +export default connect(mapStateToProps)(homePage); + + diff --git a/super-screen/client/src/sections/homePage/containers/index.js b/super-screen/client/src/sections/homePage/containers/index.js new file mode 100644 index 0000000..e793d09 --- /dev/null +++ b/super-screen/client/src/sections/homePage/containers/index.js @@ -0,0 +1,6 @@ +'use strict'; + +import homePage from './homePage'; + + +export default homePage ; diff --git a/super-screen/client/src/sections/homePage/containers/style.less b/super-screen/client/src/sections/homePage/containers/style.less new file mode 100644 index 0000000..be0cdd4 --- /dev/null +++ b/super-screen/client/src/sections/homePage/containers/style.less @@ -0,0 +1,224 @@ +.homepage { + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + background: url('/assets/images/homePage/bigscreen/bg.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + overflow: hidden; + + ._title { + width: 100%; + height: 88px; + background: url('/assets/images/homePage/bigscreen/top.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } + + ._exit { + position: absolute; + right: 60px; + top: 38px; + cursor: pointer; + color: #C8F0FF; + display: flex; + + ._icon { + display: inline-block; + width: 28px; + height: 28px; + background: url('/assets/images/homePage/bigscreen/exit.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + margin-right: 3px; + } + } + + .homepage-left { + width: 21.8%; + height: 89.6%; + position: absolute; + top: 8.2%; + z-index: 300; + } + + .homepage-center { + width: 49.16%; + height: 89.6%; + position: absolute; + bottom: 2.4%; + left: 25.5%; + padding-left: 16px; + padding-right: 16px; + z-index: 400; + + ._top { + margin-top: 5%; + height: calc(100% - 200px); + background: url('/assets/images/homePage/bigscreen/centerbg.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + position: relative; + } + } + + .homepage-left-left { + left: 48px; + } + + .homepage-left-right { + right: 48px; + } + +} + + +.list { + list-style: none; + height: 100%; +} + +.list .child { + box-sizing: border-box; + opacity: 0; + transform: translateX(-300px); + animation: show .5s forwards; +} + +.list .child.show { + animation-delay: 0s !important; +} + +.list .child.hide { + opacity: 1; + transform: translateX(0); + animation-name: hide; + animation-delay: 0s; +} + +/*animation-delay*/ +.list .child:not(.hide):nth-child(5n + 1) { + animation-delay: .3s; +} + +.list .child:not(.hide):nth-child(5n + 2) { + animation-delay: .6s; +} + +.list .child:not(.hide):nth-child(5n + 3) { + animation-delay: .9s; +} + +.list .child:not(.hide):nth-child(5n + 4) { + animation-delay: 1.2s; +} + +.list .child:not(.hide):nth-child(5n + 5) { + animation-delay: 1.5s; +} + +.list .child-right { + box-sizing: border-box; + opacity: 0; + transform: translateX(300px); + animation: show .5s forwards; +} + +.list .child-right.show { + animation-delay: 0s !important; +} + +.list .child-right.hide { + opacity: 1; + transform: translateX(0); + animation-name: hide; + animation-delay: 0s; +} + +/*animation-delay*/ +.list .child-right:not(.hide):nth-child(5n + 1) { + animation-delay: .3s; +} + +.list .child-right:not(.hide):nth-child(5n + 2) { + animation-delay: .6s; +} + +.list .child-right:not(.hide):nth-child(5n + 3) { + animation-delay: .9s; +} + +.list .child-right:not(.hide):nth-child(5n + 4) { + animation-delay: 1.2s; +} + +.list .child-right:not(.hide):nth-child(5n + 5) { + animation-delay: 1.5s; +} + +.list .child-top { + box-sizing: border-box; + opacity: 0; + transform: translateY(300px); + animation: show 1s forwards; +} + +.list .child-top.show { + animation-delay: 0s !important; +} + +.list .child-top.hide { + opacity: 1; + transform: translateY(0); + animation-name: hide; + animation-delay: 0s; +} + + +@keyframes show { + to { + opacity: 1; + transform: translateX(0); + } +} + +@keyframes hide { + to { + opacity: 0; + transform: translateX(100px); + max-height: 0; + margin: 0; + } +} + +.center-card-title { + height: 31px; + font-family: YouSheBiaoTiHei; + font-size: 24px; + color: #FFFFFF; + display: flex; + align-items: center; + margin-top: 5px; + + ._icon_left { + width: 32px; + height: 17px; + background: url('/assets/images/homePage/bigscreen/center-left.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + margin-right: 11px; + margin-left: 10px; + } + + ._icon_right { + width: 32px; + height: 17px; + background: url('/assets/images/homePage/bigscreen/center-right.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + margin-right: 11px; + margin-left: 10px; + } +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/index.js b/super-screen/client/src/sections/homePage/index.js new file mode 100644 index 0000000..be61a4a --- /dev/null +++ b/super-screen/client/src/sections/homePage/index.js @@ -0,0 +1,15 @@ +'use strict'; + +import reducers from './reducers'; +import routes from './routes'; +import actions from './actions'; +import { getNavItem } from './nav-item'; + +export default { + key: 'homePage', + name: '首页', + reducers: reducers, + routes: routes, + actions: actions, + getNavItem: getNavItem +}; \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/nav-item.js b/super-screen/client/src/sections/homePage/nav-item.js new file mode 100644 index 0000000..5255789 --- /dev/null +++ b/super-screen/client/src/sections/homePage/nav-item.js @@ -0,0 +1,11 @@ +import React from 'react'; +import { Link } from 'react-router-dom'; +import { Menu } from 'antd'; +import { HomeOutlined } from '@ant-design/icons'; +export function getNavItem(user) { + return ( + user?.role == '系统管理员' && }> + 数据监控平台 + + ); +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/reducers/index.js b/super-screen/client/src/sections/homePage/reducers/index.js new file mode 100644 index 0000000..7ed1088 --- /dev/null +++ b/super-screen/client/src/sections/homePage/reducers/index.js @@ -0,0 +1,5 @@ +'use strict'; + +export default { + +} \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/routes.js b/super-screen/client/src/sections/homePage/routes.js new file mode 100644 index 0000000..fd004b3 --- /dev/null +++ b/super-screen/client/src/sections/homePage/routes.js @@ -0,0 +1,13 @@ +'use strict'; +import homePage from './containers/index'; + +export default [{ + type: 'outer', + route: { + path: '/homePage', + key: 'homePage', + breadcrumb: '数据监控平台', + // 不设置 component 则面包屑禁止跳转 + component: homePage + } +}]; \ No newline at end of file diff --git a/super-screen/client/src/sections/homePage/style.less b/super-screen/client/src/sections/homePage/style.less new file mode 100644 index 0000000..e69de29 diff --git a/super-screen/client/src/styles/antd.less b/super-screen/client/src/styles/antd.less new file mode 100644 index 0000000..f4c73e8 --- /dev/null +++ b/super-screen/client/src/styles/antd.less @@ -0,0 +1,10 @@ + +@icon-url: "/assets/fonticon/iconfont"; + +.tree-transfer .ant-transfer-list-body { + overflow: auto !important; +} + +.ant-pro-table-search { + background-color: @component-background !important; +} \ No newline at end of file diff --git a/super-screen/client/src/styles/theme.less b/super-screen/client/src/styles/theme.less new file mode 100644 index 0000000..574643a --- /dev/null +++ b/super-screen/client/src/styles/theme.less @@ -0,0 +1,16 @@ +@import "~antd/lib/style/themes/default.less"; +@primary-color : @blue-6; +@link-color : @primary-color; +@secondary-color : fade(@primary-color, 20%); +@btn-primary-bg : @primary-color; +@select-item-selected-option-color: @primary-color; +@processing-color : @primary-color; +@select-item-selected-bg : @background-color-base; +@skeleton-color : @primary-color; +@btn-primary-bg : @primary-color; + +@component-background: transparent; + +:root { + --PC: @primary-color; +} \ No newline at end of file diff --git a/super-screen/client/src/utils/authCode.js b/super-screen/client/src/utils/authCode.js new file mode 100644 index 0000000..971ccb5 --- /dev/null +++ b/super-screen/client/src/utils/authCode.js @@ -0,0 +1,5 @@ +'use strict'; + +export const AuthorizationCode = { + +}; diff --git a/super-screen/client/src/utils/func.js b/super-screen/client/src/utils/func.js new file mode 100644 index 0000000..e473145 --- /dev/null +++ b/super-screen/client/src/utils/func.js @@ -0,0 +1,13 @@ +'use strict'; + + export default class Func { + static isAuthorized(authcode) { + if (JSON.parse(sessionStorage.getItem('user'))) { + const { resources } = JSON.parse(sessionStorage.getItem('user')); + return resources.includes(authcode); + }else{ + return false; + } + } + } + \ No newline at end of file diff --git a/super-screen/client/src/utils/hooks.js b/super-screen/client/src/utils/hooks.js new file mode 100644 index 0000000..37a7deb --- /dev/null +++ b/super-screen/client/src/utils/hooks.js @@ -0,0 +1,30 @@ +import React, { useEffect } from 'react'; +import { useRequest } from 'ahooks'; +import { Request } from '@peace/utils'; + +export const useFsRequest = ({ ...props }) => { + const { + method = 'get', header = null, body = {}, query = {}, root = null, url, ...rest + } = props; + return useRequest(() => { + if (method === 'post') { + return Request.post(url, body, query, root, header); + } + if (method === 'put') { + return Request.put(url, body, query, root, header); + } + if (method === 'delete') { + return Request.delete(url, query, root, header); + } + return Request.get(url, query, root, header); + }, { + loadingDelay: 500, + ...rest, + }); +}; + + + +export default { + useFsRequest, +}; diff --git a/super-screen/client/src/utils/index.js b/super-screen/client/src/utils/index.js new file mode 100644 index 0000000..b697c96 --- /dev/null +++ b/super-screen/client/src/utils/index.js @@ -0,0 +1,12 @@ +'use strict'; +import { AuthorizationCode } from './authCode'; +import { ApiTable, RouteTable, } from './webapi' +import Func from './func'; +import { useFsRequest } from './hooks'; + +export { + AuthorizationCode, + Func, + ApiTable, RouteTable, + useFsRequest, +} \ No newline at end of file diff --git a/super-screen/client/src/utils/pinyin.js b/super-screen/client/src/utils/pinyin.js new file mode 100644 index 0000000..e1516d2 --- /dev/null +++ b/super-screen/client/src/utils/pinyin.js @@ -0,0 +1,131 @@ +/** + * Created by liu.xinyi + * on 2016/5/10. + */ +'use strict'; +function Pinyin(){ + this.char_dict = "YDYQSXMWZSSXJBYMGCCZQPSSQBYCDSCDQLDYLYBSSJGYZZJJFKCCLZDHWDWZJLJPFYYNWJJTMYHZWZHFLZPPQHGSCYYYNJQYXXGJHHSDSJNKKTMOMLCRXYPSNQSECCQZGGLLYJLMYZZSECYKYYHQWJSSGGYXYZYJWWKDJHYCHMYXJTLXJYQBYXZLDWRDJRWYSRLDZJPCBZJJBRCFTLECZSTZFXXZHTRQHYBDLYCZSSYMMRFMYQZPWWJJYFCRWFDFZQPYDDWYXKYJAWJFFXYPSFTZYHHYZYSWCJYXSCLCXXWZZXNBGNNXBXLZSZSBSGPYSYZDHMDZBQBZCWDZZYYTZHBTSYYBZGNTNXQYWQSKBPHHLXGYBFMJEBJHHGQTJCYSXSTKZHLYCKGLYSMZXYALMELDCCXGZYRJXSDLTYZCQKCNNJWHJTZZCQLJSTSTBNXBTYXCEQXGKWJYFLZQLYHYXSPSFXLMPBYSXXXYDJCZYLLLSJXFHJXPJBTFFYABYXBHZZBJYZLWLCZGGBTSSMDTJZXPTHYQTGLJSCQFZKJZJQNLZWLSLHDZBWJNCJZYZSQQYCQYRZCJJWYBRTWPYFTWEXCSKDZCTBZHYZZYYJXZCFFZZMJYXXSDZZOTTBZLQWFCKSZSXFYRLNYJMBDTHJXSQQCCSBXYYTSYFBXDZTGBCNSLCYZZPSAZYZZSCJCSHZQYDXLBPJLLMQXTYDZXSQJTZPXLCGLQTZWJBHCTSYJSFXYEJJTLBGXSXJMYJQQPFZASYJNTYDJXKJCDJSZCBARTDCLYJQMWNQNCLLLKBYBZZSYHQQLTWLCCXTXLLZNTYLNEWYZYXCZXXGRKRMTCNDNJTSYYSSDQDGHSDBJGHRWRQLYBGLXHLGTGXBQJDZPYJSJYJCTMRNYMGRZJCZGJMZMGXMPRYXKJNYMSGMZJYMKMFXMLDTGFBHCJHKYLPFMDXLQJJSMTQGZSJLQDLDGJYCALCMZCSDJLLNXDJFFFFJCZFMZFFPFKHKGDPSXKTACJDHHZDDCRRCFQYJKQCCWJDXHWJLYLLZGCFCQDSMLZPBJJPLSBCJGGDCKKDEZSQCCKJGCGKDJTJDLZYCXKLQSCGJCLTFPCQCZGWPJDQYZJJBYJHSJDZWGFSJGZKQCCZLLPSPKJGQJHZZLJPLGJGJJTHJJYJZCZMLZLYQBGJWMLJKXZDZNJQSYZMLJLLJKYWXMKJLHSKJGBMCLYYMKXJQLBMLLKMDXXKWYXYSLMLPSJQQJQXYXFJTJDXMXXLLCXQBSYJBGWYMBGGBCYXPJYGPEPFGDJGBHBNSQJYZJKJKHXQFGQZKFHYGKHDKLLSDJQXPQYKYBNQSXQNSZSWHBSXWHXWBZZXDMNSJBSBKBBZKLYLXGWXDRWYQZMYWSJQLCJXXJXKJEQXSCYETLZHLYYYSDZPAQYZCMTLSHTZCFYZYXYLJSDCJQAGYSLCQLYYYSHMRQQKLDXZSCSSSYDYCJYSFSJBFRSSZQSBXXPXJYSDRCKGJLGDKZJZBDKTCSYQPYHSTCLDJDHMXMCGXYZHJDDTMHLTXZXYLYMOHYJCLTYFBQQXPFBDFHHTKSQHZYYWCNXXCRWHOWGYJLEGWDQCWGFJYCSNTMYTOLBYGWQWESJPWNMLRYDZSZTXYQPZGCWXHNGPYXSHMYQJXZTDPPBFYHZHTJYFDZWKGKZBLDNTSXHQEEGZZYLZMMZYJZGXZXKHKSTXNXXWYLYAPSTHXDWHZYMPXAGKYDXBHNHXKDPJNMYHYLPMGOCSLNZHKXXLPZZLBMLSFBHHGYGYYGGBHSCYAQTYWLXTZQCEZYDQDQMMHTKLLSZHLSJZWFYHQSWSCWLQAZYNYTLSXTHAZNKZZSZZLAXXZWWCTGQQTDDYZTCCHYQZFLXPSLZYGPZSZNGLNDQTBDLXGTCTAJDKYWNSYZLJHHZZCWNYYZYWMHYCHHYXHJKZWSXHZYXLYSKQYSPSLYZWMYPPKBYGLKZHTYXAXQSYSHXASMCHKDSCRSWJPWXSGZJLWWSCHSJHSQNHCSEGNDAQTBAALZZMSSTDQJCJKTSCJAXPLGGXHHGXXZCXPDMMHLDGTYBYSJMXHMRCPXXJZCKZXSHMLQXXTTHXWZFKHCCZDYTCJYXQHLXDHYPJQXYLSYYDZOZJNYXQEZYSQYAYXWYPDGXDDXSPPYZNDLTWRHXYDXZZJHTCXMCZLHPYYYYMHZLLHNXMYLLLMDCPPXHMXDKYCYRDLTXJCHHZZXZLCCLYLNZSHZJZZLNNRLWHYQSNJHXYNTTTKYJPYCHHYEGKCTTWLGQRLGGTGTYGYHPYHYLQYQGCWYQKPYYYTTTTLHYHLLTYTTSPLKYZXGZWGPYDSSZZDQXSKCQNMJJZZBXYQMJRTFFBTKHZKBXLJJKDXJTLBWFZPPTKQTZTGPDGNTPJYFALQMKGXBDCLZFHZCLLLLADPMXDJHLCCLGYHDZFGYDDGCYYFGYDXKSSEBDHYKDKDKHNAXXYBPBYYHXZQGAFFQYJXDMLJCSQZLLPCHBSXGJYNDYBYQSPZWJLZKSDDTACTBXZDYZYPJZQSJNKKTKNJDJGYYPGTLFYQKASDNTCYHBLWDZHBBYDWJRYGKZYHEYYFJMSDTYFZJJHGCXPLXHLDWXXJKYTCYKSSSMTWCTTQZLPBSZDZWZXGZAGYKTYWXLHLSPBCLLOQMMZSSLCMBJCSZZKYDCZJGQQDSMCYTZQQLWZQZXSSFPTTFQMDDZDSHDTDWFHTDYZJYQJQKYPBDJYYXTLJHDRQXXXHAYDHRJLKLYTWHLLRLLRCXYLBWSRSZZSYMKZZHHKYHXKSMDSYDYCJPBZBSQLFCXXXNXKXWYWSDZYQOGGQMMYHCDZTTFJYYBGSTTTYBYKJDHKYXBELHTYPJQNFXFDYKZHQKZBYJTZBXHFDXKDASWTAWAJLDYJSFHBLDNNTNQJTJNCHXFJSRFWHZFMDRYJYJWZPDJKZYJYMPCYZNYNXFBYTFYFWYGDBNZZZDNYTXZEMMQBSQEHXFZMBMFLZZSRXYMJGSXWZJSPRYDJSJGXHJJGLJJYNZZJXHGXKYMLPYYYCXYTWQZSWHWLYRJLPXSLSXMFSWWKLCTNXNYNPSJSZHDZEPTXMYYWXYYSYWLXJQZQXZDCLEEELMCPJPCLWBXSQHFWWTFFJTNQJHJQDXHWLBYZNFJLALKYYJLDXHHYCSTYYWNRJYXYWTRMDRQHWQCMFJDYZMHMYYXJWMYZQZXTLMRSPWWCHAQBXYGZYPXYYRRCLMPYMGKSJSZYSRMYJSNXTPLNBAPPYPYLXYYZKYNLDZYJZCZNNLMZHHARQMPGWQTZMXXMLLHGDZXYHXKYXYCJMFFYYHJFSBSSQLXXNDYCANNMTCJCYPRRNYTYQNYYMBMSXNDLYLYSLJRLXYSXQMLLYZLZJJJKYZZCSFBZXXMSTBJGNXYZHLXNMCWSCYZYFZLXBRNNNYLBNRTGZQYSATSWRYHYJZMZDHZGZDWYBSSCSKXSYHYTXXGCQGXZZSHYXJSCRHMKKBXCZJYJYMKQHZJFNBHMQHYSNJNZYBKNQMCLGQHWLZNZSWXKHLJHYYBQLBFCDSXDLDSPFZPSKJYZWZXZDDXJSMMEGJSCSSMGCLXXKYYYLNYPWWWGYDKZJGGGZGGSYCKNJWNJPCXBJJTQTJWDSSPJXZXNZXUMELPXFSXTLLXCLJXJJLJZXCTPSWXLYDHLYQRWHSYCSQYYBYAYWJJJQFWQCQQCJQGXALDBZZYJGKGXPLTZYFXJLTPADKYQHPMATLCPDCKBMTXYBHKLENXDLEEGQDYMSAWHZMLJTWYGXLYQZLJEEYYBQQFFNLYXRDSCTGJGXYYNKLLYQKCCTLHJLQMKKZGCYYGLLLJDZGYDHZWXPYSJBZKDZGYZZHYWYFQYTYZSZYEZZLYMHJJHTSMQWYZLKYYWZCSRKQYTLTDXWCTYJKLWSQZWBDCQYNCJSRSZJLKCDCDTLZZZACQQZZDDXYPLXZBQJYLZLLLQDDZQJYJYJZYXNYYYNYJXKXDAZWYRDLJYYYRJLXLLDYXJCYWYWNQCCLDDNYYYNYCKCZHXXCCLGZQJGKWPPCQQJYSBZZXYJSQPXJPZBSBDSFNSFPZXHDWZTDWPPTFLZZBZDMYYPQJRSDZSQZSQXBDGCPZSWDWCSQZGMDHZXMWWFYBPDGPHTMJTHZSMMBGZMBZJCFZWFZBBZMQCFMBDMCJXLGPNJBBXGYHYYJGPTZGZMQBQTCGYXJXLWZKYDPDYMGCFTPFXYZTZXDZXTGKMTYBBCLBJASKYTSSQYYMSZXFJEWLXLLSZBQJJJAKLYLXLYCCTSXMCWFKKKBSXLLLLJYXTYLTJYYTDPJHNHNNKBYQNFQYYZBYYESSESSGDYHFHWTCJBSDZZTFDMXHCNJZYMQWSRYJDZJQPDQBBSTJGGFBKJBXTGQHNGWJXJGDLLTHZHHYYYYYYSXWTYYYCCBDBPYPZYCCZYJPZYWCBDLFWZCWJDXXHYHLHWZZXJTCZLCDPXUJCZZZLYXJJTXPHFXWPYWXZPTDZZBDZCYHJHMLXBQXSBYLRDTGJRRCTTTHYTCZWMXFYTWWZCWJWXJYWCSKYBZSCCTZQNHXNWXXKHKFHTSWOCCJYBCMPZZYKBNNZPBZHHZDLSYDDYTYFJPXYNGFXBYQXCBHXCPSXTYZDMKYSNXSXLHKMZXLYHDHKWHXXSSKQYHHCJYXGLHZXCSNHEKDTGZXQYPKDHEXTYKCNYMYYYPKQYYYKXZLTHJQTBYQHXBMYHSQCKWWYLLHCYYLNNEQXQWMCFBDCCMLJGGXDQKTLXKGNQCDGZJWYJJLYHHQTTTNWCHMXCXWHWSZJYDJCCDBQCDGDNYXZTHCQRXCBHZTQCBXWGQWYYBXHMBYMYQTYEXMQKYAQYRGYZSLFYKKQHYSSQYSHJGJCNXKZYCXSBXYXHYYLSTYCXQTHYSMGSCPMMGCCCCCMTZTASMGQZJHKLOSQYLSWTMXSYQKDZLJQQYPLSYCZTCQQPBBQJZCLPKHQZYYXXDTDDTSJCXFFLLCHQXMJLWCJCXTSPYCXNDTJSHJWXDQQJSKXYAMYLSJHMLALYKXCYYDMNMDQMXMCZNNCYBZKKYFLMCHCMLHXRCJJHSYLNMTJZGZGYWJXSRXCWJGJQHQZDQJDCJJZKJKGDZQGJJYJYLXZXXCDQHHHEYTMHLFSBDJSYYSHFYSTCZQLPBDRFRZTZYKYWHSZYQKWDQZRKMSYNBCRXQBJYFAZPZZEDZCJYWBCJWHYJBQSZYWRYSZPTDKZPFPBNZTKLQYHBBZPNPPTYZZYBQNYDCPJMMCYCQMCYFZZDCMNLFPBPLNGQJTBTTNJZPZBBZNJKLJQYLNBZQHKSJZNGGQSZZKYXSHPZSNBCGZKDDZQANZHJKDRTLZLSWJLJZLYWTJNDJZJHXYAYNCBGTZCSSQMNJPJYTYSWXZFKWJQTKHTZPLBHSNJZSYZBWZZZZLSYLSBJHDWWQPSLMMFBJDWAQYZTCJTBNNWZXQXCDSLQGDSDPDZHJTQQPSWLYYJZLGYXYZLCTCBJTKTYCZJTQKBSJLGMGZDMCSGPYNJZYQYYKNXRPWSZXMTNCSZZYXYBYHYZAXYWQCJTLLCKJJTJHGDXDXYQYZZBYWDLWQCGLZGJGQRQZCZSSBCRPCSKYDZNXJSQGXSSJMYDNSTZTPBDLTKZWXQWQTZEXNQCZGWEZKSSBYBRTSSSLCCGBPSZQSZLCCGLLLZXHZQTHCZMQGYZQZNMCOCSZJMMZSQPJYGQLJYJPPLDXRGZYXCCSXHSHGTZNLZWZKJCXTCFCJXLBMQBCZZWPQDNHXLJCTHYZLGYLNLSZZPCXDSCQQHJQKSXZPBAJYEMSMJTZDXLCJYRYYNWJBNGZZTMJXLTBSLYRZPYLSSCNXPHLLHYLLQQZQLXYMRSYCXZLMMCZLTZSDWTJJLLNZGGQXPFSKYGYGHBFZPDKMWGHCXMSGDXJMCJZDYCABXJDLNBCDQYGSKYDQTXDJJYXMSZQAZDZFSLQXYJSJZYLBTXXWXQQZBJZUFBBLYLWDSLJHXJYZJWTDJCZFQZQZZDZSXZZQLZCDZFJHYSPYMPQZMLPPLFFXJJNZZYLSJEYQZFPFZKSYWJJJHRDJZZXTXXGLGHYDXCSKYSWMMZCWYBAZBJKSHFHJCXMHFQHYXXYZFTSJYZFXYXPZLCHMZMBXHZZSXYFYMNCWDABAZLXKTCSHHXKXJJZJSTHYGXSXYYHHHJWXKZXSSBZZWHHHCWTZZZPJXSNXQQJGZYZYWLLCWXZFXXYXYHXMKYYSWSQMNLNAYCYSPMJKHWCQHYLAJJMZXHMMCNZHBHXCLXTJPLTXYJHDYYLTTXFSZHYXXSJBJYAYRSMXYPLCKDUYHLXRLNLLSTYZYYQYGYHHSCCSMZCTZQXKYQFPYYRPFFLKQUNTSZLLZMWWTCQQYZWTLLMLMPWMBZSSTZRBPDDTLQJJBXZCSRZQQYGWCSXFWZLXCCRSZDZMCYGGDZQSGTJSWLJMYMMZYHFBJDGYXCCPSHXNZCSBSJYJGJMPPWAFFYFNXHYZXZYLREMZGZCYZSSZDLLJCSQFNXZKPTXZGXJJGFMYYYSNBTYLBNLHPFZDCYFBMGQRRSSSZXYSGTZRNYDZZCDGPJAFJFZKNZBLCZSZPSGCYCJSZLMLRSZBZZLDLSLLYSXSQZQLYXZLSKKBRXBRBZCYCXZZZEEYFGKLZLYYHGZSGZLFJHGTGWKRAAJYZKZQTSSHJJXDCYZUYJLZYRZDQQHGJZXSSZBYKJPBFRTJXLLFQWJHYLQTYMBLPZDXTZYGBDHZZRBGXHWNJTJXLKSCFSMWLSDQYSJTXKZSCFWJLBXFTZLLJZLLQBLSQMQQCGCZFPBPHZCZJLPYYGGDTGWDCFCZQYYYQYSSCLXZSKLZZZGFFCQNWGLHQYZJJCZLQZZYJPJZZBPDCCMHJGXDQDGDLZQMFGPSYTSDYFWWDJZJYSXYYCZCYHZWPBYKXRYLYBHKJKSFXTZJMMCKHLLTNYYMSYXYZPYJQYCSYCWMTJJKQYRHLLQXPSGTLYYCLJSCPXJYZFNMLRGJJTYZBXYZMSJYJHHFZQMSYXRSZCWTLRTQZSSTKXGQKGSPTGCZNJSJCQCXHMXGGZTQYDJKZDLBZSXJLHYQGGGTHQSZPYHJHHGYYGKGGCWJZZYLCZLXQSFTGZSLLLMLJSKCTBLLZZSZMMNYTPZSXQHJCJYQXYZXZQZCPSHKZZYSXCDFGMWQRLLQXRFZTLYSTCTMJCXJJXHJNXTNRZTZFQYHQGLLGCXSZSJDJLJCYDSJTLNYXHSZXCGJZYQPYLFHDJSBPCCZHJJJQZJQDYBSSLLCMYTTMQTBHJQNNYGKYRQYQMZGCJKPDCGMYZHQLLSLLCLMHOLZGDYYFZSLJCQZLYLZQJESHNYLLJXGJXLYSYYYXNBZLJSSZCQQCJYLLZLTJYLLZLLBNYLGQCHXYYXOXCXQKYJXXXYKLXSXXYQXCYKQXQCSGYXXYQXYGYTQOHXHXPYXXXULCYEYCHZZCBWQBBWJQZSCSZSSLZYLKDESJZWMYMCYTSDSXXSCJPQQSQYLYYZYCMDJDZYWCBTJSYDJKCYDDJLBDJJSODZYSYXQQYXDHHGQQYQHDYXWGMMMAJDYBBBPPBCMUUPLJZSMTXERXJMHQNUTPJDCBSSMSSSTKJTSSMMTRCPLZSZMLQDSDMJMQPNQDXCFYNBFSDQXYXHYAYKQYDDLQYYYSSZBYDSLNTFQTZQPZMCHDHCZCWFDXTMYQSPHQYYXSRGJCWTJTZZQMGWJJTJHTQJBBHWZPXXHYQFXXQYWYYHYSCDYDHHQMNMTMWCPBSZPPZZGLMZFOLLCFWHMMSJZTTDHZZYFFYTZZGZYSKYJXQYJZQBHMBZZLYGHGFMSHPZFZSNCLPBQSNJXZSLXXFPMTYJYGBXLLDLXPZJYZJYHHZCYWHJYLSJEXFSZZYWXKZJLUYDTMLYMQJPWXYHXSKTQJEZRPXXZHHMHWQPWQLYJJQJJZSZCPHJLCHHNXJLQWZJHBMZYXBDHHYPZLHLHLGFWLCHYYTLHJXCJMSCPXSTKPNHQXSRTYXXTESYJCTLSSLSTDLLLWWYHDHRJZSFGXTSYCZYNYHTDHWJSLHTZDQDJZXXQHGYLTZPHCSQFCLNJTCLZPFSTPDYNYLGMJLLYCQHYSSHCHYLHQYQTMZYPBYWRFQYKQSYSLZDQJMPXYYSSRHZJNYWTQDFZBWWTWWRXCWHGYHXMKMYYYQMSMZHNGCEPMLQQMTCWCTMMPXJPJJHFXYYZSXZHTYBMSTSYJTTQQQYYLHYNPYQZLCYZHZWSMYLKFJXLWGXYPJYTYSYXYMZCKTTWLKSMZSYLMPWLZWXWQZSSAQSYXYRHSSNTSRAPXCPWCMGDXHXZDZYFJHGZTTSBJHGYZSZYSMYCLLLXBTYXHBBZJKSSDMALXHYCFYGMQYPJYCQXJLLLJGSLZGQLYCJCCZOTYXMTMTTLLWTGPXYMZMKLPSZZZXHKQYSXCTYJZYHXSHYXZKXLZWPSQPYHJWPJPWXQQYLXSDHMRSLZZYZWTTCYXYSZZSHBSCCSTPLWSSCJCHNLCGCHSSPHYLHFHHXJSXYLLNYLSZDHZXYLSXLWZYKCLDYAXZCMDDYSPJTQJZLNWQPSSSWCTSTSZLBLNXSMNYYMJQBQHRZWTYYDCHQLXKPZWBGQYBKFCMZWPZLLYYLSZYDWHXPSBCMLJBSCGBHXLQHYRLJXYSWXWXZSLDFHLSLYNJLZYFLYJYCDRJLFSYZFSLLCQYQFGJYHYXZLYLMSTDJCYHBZLLNWLXXYGYYHSMGDHXXHHLZZJZXCZZZCYQZFNGWPYLCPKPYYPMCLQKDGXZGGWQBDXZZKZFBXXLZXJTPJPTTBYTSZZDWSLCHZHSLTYXHQLHYXXXYYZYSWTXZKHLXZXZPYHGCHKCFSYHUTJRLXFJXPTZTWHPLYXFCRHXSHXKYXXYHZQDXQWULHYHMJTBFLKHTXCWHJFWJCFPQRYQXCYYYQYGRPYWSGSUNGWCHKZDXYFLXXHJJBYZWTSXXNCYJJYMSWZJQRMHXZWFQSYLZJZGBHYNSLBGTTCSYBYXXWXYHXYYXNSQYXMQYWRGYQLXBBZLJSYLPSYTJZYHYZAWLRORJMKSCZJXXXYXCHDYXRYXXJDTSQFXLYLTSFFYXLMTYJMJUYYYXLTZCSXQZQHZXLYYXZHDNBRXXXJCTYHLBRLMBRLLAXKYLLLJLYXXLYCRYLCJTGJCMTLZLLCYZZPZPCYAWHJJFYBDYYZSMPCKZDQYQPBPCJPDCYZMDPBCYYDYCNNPLMTMLRMFMMGWYZBSJGYGSMZQQQZTXMKQWGXLLPJGZBQCDJJJFPKJKCXBLJMSWMDTQJXLDLPPBXCWRCQFBFQJCZAHZGMYKPHYYHZYKNDKZMBPJYXPXYHLFPNYYGXJDBKXNXHJMZJXSTRSTLDXSKZYSYBZXJLXYSLBZYSLHXJPFXPQNBYLLJQKYGZMCYZZYMCCSLCLHZFWFWYXZMWSXTYNXJHPYYMCYSPMHYSMYDYSHQYZCHMJJMZCAAGCFJBBHPLYZYLXXSDJGXDHKXXTXXNBHRMLYJSLTXMRHNLXQJXYZLLYSWQGDLBJHDCGJYQYCMHWFMJYBMBYJYJWYMDPWHXQLDYGPDFXXBCGJSPCKRSSYZJMSLBZZJFLJJJLGXZGYXYXLSZQYXBEXYXHGCXBPLDYHWETTWWCJMBTXCHXYQXLLXFLYXLLJLSSFWDPZSMYJCLMWYTCZPCHQEKCQBWLCQYDPLQPPQZQFJQDJHYMMCXTXDRMJWRHXCJZYLQXDYYNHYYHRSLSRSYWWZJYMTLTLLGTQCJZYABTCKZCJYCCQLJZQXALMZYHYWLWDXZXQDLLQSHGPJFJLJHJABCQZDJGTKHSSTCYJLPSWZLXZXRWGLDLZRLZXTGSLLLLZLYXXWGDZYGBDPHZPBRLWSXQBPFDWOFMWHLYPCBJCCLDMBZPBZZLCYQXLDOMZBLZWPDWYYGDSTTHCSQSCCRSSSYSLFYBFNTYJSZDFNDPDHDZZMBBLSLCMYFFGTJJQWFTMTPJWFNLBZCMMJTGBDZLQLPYFHYYMJYLSDCHDZJWJCCTLJCLDTLJJCPDDSQDSSZYBNDBJLGGJZXSXNLYCYBJXQYCBYLZCFZPPGKCXZDZFZTJJFJSJXZBNZYJQTTYJYHTYCZHYMDJXTTMPXSPLZCDWSLSHXYPZGTFMLCJTYCBPMGDKWYCYZCDSZZYHFLYCTYGWHKJYYLSJCXGYWJCBLLCSNDDBTZBSCLYZCZZSSQDLLMQYYHFSLQLLXFTYHABXGWNYWYYPLLSDLDLLBJCYXJZMLHLJDXYYQYTDLLLBUGBFDFBBQJZZMDPJHGCLGMJJPGAEHHBWCQXAXHHHZCHXYPHJAXHLPHJPGPZJQCQZGJJZZUZDMQYYBZZPHYHYBWHAZYJHYKFGDPFQSDLZMLJXKXGALXZDAGLMDGXMWZQYXXDXXPFDMMSSYMPFMDMMKXKSYZYSHDZKXSYSMMZZZMSYDNZZCZXFPLSTMZDNMXCKJMZTYYMZMZZMSXHHDCZJEMXXKLJSTLWLSQLYJZLLZJSSDPPMHNLZJCZYHMXXHGZCJMDHXTKGRMXFWMCGMWKDTKSXQMMMFZZYDKMSCLCMPCGMHSPXQPZDSSLCXKYXTWLWJYAHZJGZQMCSNXYYMMPMLKJXMHLMLQMXCTKZMJQYSZJSYSZHSYJZJCDAJZYBSDQJZGWZQQXFKDMSDJLFWEHKZQKJPEYPZYSZCDWYJFFMZZYLTTDZZEFMZLBNPPLPLPEPSZALLTYLKCKQZKGENQLWAGYXYDPXLHSXQQWQCQXQCLHYXXMLYCCWLYMQYSKGCHLCJNSZKPYZKCQZQLJPDMDZHLASXLBYDWQLWDNBQCRYDDZTJYBKBWSZDXDTNPJDTCTQDFXQQMGNXECLTTBKPWSLCTYQLPWYZZKLPYGZCQQPLLKCCYLPQMZCZQCLJSLQZDJXLDDHPZQDLJJXZQDXYZQKZLJCYQDYJPPYPQYKJYRMPCBYMCXKLLZLLFQPYLLLMBSGLCYSSLRSYSQTMXYXZQZFDZUYSYZTFFMZZSMZQHZSSCCMLYXWTPZGXZJGZGSJSGKDDHTQGGZLLBJDZLCBCHYXYZHZFYWXYZYMSDBZZYJGTSMTFXQYXQSTDGSLNXDLRYZZLRYYLXQHTXSRTZNGZXBNQQZFMYKMZJBZYMKBPNLYZPBLMCNQYZZZSJZHJCTZKHYZZJRDYZHNPXGLFZTLKGJTCTSSYLLGZRZBBQZZKLPKLCZYSSUYXBJFPNJZZXCDWXZYJXZZDJJKGGRSRJKMSMZJLSJYWQSKYHQJSXPJZZZLSNSHRNYPZTWCHKLPSRZLZXYJQXQKYSJYCZTLQZYBBYBWZPQDWWYZCYTJCJXCKCWDKKZXSGKDZXWWYYJQYYTCYTDLLXWKCZKKLCCLZCQQDZLQLCSFQCHQHSFSMQZZLNBJJZBSJHTSZDYSJQJPDLZCDCWJKJZZLPYCGMZWDJJBSJQZSYZYHHXJPBJYDSSXDZNCGLQMBTSFSBPDZDLZNFGFJGFSMPXJQLMBLGQCYYXBQKDJJQYRFKZTJDHCZKLBSDZCFJTPLLJGXHYXZCSSZZXSTJYGKGCKGYOQXJPLZPBPGTGYJZGHZQZZLBJLSQFZGKQQJZGYCZBZQTLDXRJXBSXXPZXHYZYCLWDXJJHXMFDZPFZHQHQMQGKSLYHTYCGFRZGNQXCLPDLBZCSCZQLLJBLHBZCYPZZPPDYMZZSGYHCKCPZJGSLJLNSCDSLDLXBMSTLDDFJMKDJDHZLZXLSZQPQPGJLLYBDSZGQLBZLSLKYYHZTTNTJYQTZZPSZQZTLLJTYYLLQLLQYZQLBDZLSLYYZYMDFSZSNHLXZNCZQZPBWSKRFBSYZMTHBLGJPMCZZLSTLXSHTCSYZLZBLFEQHLXFLCJLYLJQCBZLZJHHSSTBRMHXZHJZCLXFNBGXGTQJCZTMSFZKJMSSNXLJKBHSJXNTNLZDNTLMSJXGZJYJCZXYJYJWRWWQNZTNFJSZPZSHZJFYRDJSFSZJZBJFZQZZHZLXFYSBZQLZSGYFTZDCSZXZJBQMSZKJRHYJZCKMJKHCHGTXKXQGLXPXFXTRTYLXJXHDTSJXHJZJXZWZLCQSBTXWXGXTXXHXFTSDKFJHZYJFJXRZSDLLLTQSQQZQWZXSYQTWGWBZCGZLLYZBCLMQQTZHZXZXLJFRMYZFLXYSQXXJKXRMQDZDMMYYBSQBHGZMWFWXGMXLZPYYTGZYCCDXYZXYWGSYJYZNBHPZJSQSYXSXRTFYZGRHZTXSZZTHCBFCLSYXZLZQMZLMPLMXZJXSFLBYZMYQHXJSXRXSQZZZSSLYFRCZJRCRXHHZXQYDYHXSJJHZCXZBTYNSYSXJBQLPXZQPYMLXZKYXLXCJLCYSXXZZLXDLLLJJYHZXGYJWKJRWYHCPSGNRZLFZWFZZNSXGXFLZSXZZZBFCSYJDBRJKRDHHGXJLJJTGXJXXSTJTJXLYXQFCSGSWMSBCTLQZZWLZZKXJMLTMJYHSDDBXGZHDLBMYJFRZFSGCLYJBPMLYSMSXLSZJQQHJZFXGFQFQBPXZGYYQXGZTCQWYLTLGWSGWHRLFSFGZJMGMGBGTJFSYZZGZYZAFLSSPMLPFLCWBJZCLJJMZLPJJLYMQDMYYYFBGYGYZMLYZDXQYXRQQQHSYYYQXYLJTYXFSFSLLGNQCYHYCWFHCCCFXPYLYPLLZYXXXXXKQHHXSHJZCFZSCZJXCPZWHHHHHAPYLQALPQAFYHXDYLUKMZQGGGDDESRNNZLTZGCHYPPYSQJJHCLLJTOLNJPZLJLHYMHEYDYDSQYCDDHGZUNDZCLZYZLLZNTNYZGSLHSLPJJBDGWXPCDUTJCKLKCLWKLLCASSTKZZDNQNTTLYYZSSYSSZZRYLJQKCQDHHCRXRZYDGRGCWCGZQFFFPPJFZYNAKRGYWYQPQXXFKJTSZZXSWZDDFBBXTBGTZKZNPZZPZXZPJSZBMQHKCYXYLDKLJNYPKYGHGDZJXXEAHPNZKZTZCMXCXMMJXNKSZQNMNLWBWWXJKYHCPSTMCSQTZJYXTPCTPDTNNPGLLLZSJLSPBLPLQHDTNJNLYYRSZFFJFQWDPHZDWMRZCCLODAXNSSNYZRESTYJWJYJDBCFXNMWTTBYLWSTSZGYBLJPXGLBOCLHPCBJLTMXZLJYLZXCLTPNCLCKXTPZJSWCYXSFYSZDKNTLBYJCYJLLSTGQCBXRYZXBXKLYLHZLQZLNZCXWJZLJZJNCJHXMNZZGJZZXTZJXYCYYCXXJYYXJJXSSSJSTSSTTPPGQTCSXWZDCSYFPTFBFHFBBLZJCLZZDBXGCXLQPXKFZFLSYLTUWBMQJHSZBMDDBCYSCCLDXYCDDQLYJJWMQLLCSGLJJSYFPYYCCYLTJANTJJPWYCMMGQYYSXDXQMZHSZXPFTWWZQSWQRFKJLZJQQYFBRXJHHFWJJZYQAZMYFRHCYYBYQWLPEXCCZSTYRLTTDMQLYKMBBGMYYJPRKZNPBSXYXBHYZDJDNGHPMFSGMWFZMFQMMBCMZZCJJLCNUXYQLMLRYGQZCYXZLWJGCJCGGMCJNFYZZJHYCPRRCMTZQZXHFQGTJXCCJEAQCRJYHPLQLSZDJRBCQHQDYRHYLYXJSYMHZYDWLDFRYHBPYDTSSCNWBXGLPZMLZZTQSSCPJMXXYCSJYTYCGHYCJWYRXXLFEMWJNMKLLSWTXHYYYNCMMCWJDQDJZGLLJWJRKHPZGGFLCCSCZMCBLTBHBQJXQDSPDJZZGKGLFQYWBZYZJLTSTDHQHCTCBCHFLQMPWDSHYYTQWCNZZJTLBYMBPDYYYXSQKXWYYFLXXNCWCXYPMAELYKKJMZZZBRXYYQJFLJPFHHHYTZZXSGQQMHSPGDZQWBWPJHZJDYSCQWZKTXXSQLZYYMYSDZGRXCKKUJLWPYSYSCSYZLRMLQSYLJXBCXTLWDQZPCYCYKPPPNSXFYZJJRCEMHSZMSXLXGLRWGCSTLRSXBZGBZGZTCPLUJLSLYLYMTXMTZPALZXPXJTJWTCYYZLBLXBZLQMYLXPGHDSLSSDMXMBDZZSXWHAMLCZCPJMCNHJYSNSYGCHSKQMZZQDLLKABLWJXSFMOCDXJRRLYQZKJMYBYQLYHETFJZFRFKSRYXFJTWDSXXSYSQJYSLYXWJHSNLXYYXHBHAWHHJZXWMYLJCSSLKYDZTXBZSYFDXGXZJKHSXXYBSSXDPYNZWRPTQZCZENYGCXQFJYKJBZMLJCMQQXUOXSLYXXLYLLJDZBTYMHPFSTTQQWLHOKYBLZZALZXQLHZWRRQHLSTMYPYXJJXMQSJFNBXYXYJXXYQYLTHYLQYFMLKLJTMLLHSZWKZHLJMLHLJKLJSTLQXYLMBHHLNLZXQJHXCFXXLHYHJJGBYZZKBXSCQDJQDSUJZYYHZHHMGSXCSYMXFEBCQWWRBPYYJQTYZCYQYQQZYHMWFFHGZFRJFCDPXNTQYZPDYKHJLFRZXPPXZDBBGZQSTLGDGYLCQMLCHHMFYWLZYXKJLYPQHSYWMQQGQZMLZJNSQXJQSYJYCBEHSXFSZPXZWFLLBCYYJDYTDTHWZSFJMQQYJLMQXXLLDTTKHHYBFPWTYYSQQWNQWLGWDEBZWCMYGCULKJXTMXMYJSXHYBRWFYMWFRXYQMXYSZTZZTFYKMLDHQDXWYYNLCRYJBLPSXCXYWLSPRRJWXHQYPHTYDNXHHMMYWYTZCSQMTSSCCDALWZTCPQPYJLLQZYJSWXMZZMMYLMXCLMXCZMXMZSQTZPPQQBLPGXQZHFLJJHYTJSRXWZXSCCDLXTYJDCQJXSLQYCLZXLZZXMXQRJMHRHZJBHMFLJLMLCLQNLDXZLLLPYPSYJYSXCQQDCMQJZZXHNPNXZMEKMXHYKYQLXSXTXJYYHWDCWDZHQYYBGYBCYSCFGPSJNZDYZZJZXRZRQJJYMCANYRJTLDPPYZBSTJKXXZYPFDWFGZZRPYMTNGXZQBYXNBUFNQKRJQZMJEGRZGYCLKXZDSKKNSXKCLJSPJYYZLQQJYBZSSQLLLKJXTBKTYLCCDDBLSPPFYLGYDTZJYQGGKQTTFZXBDKTYYHYBBFYTYYBCLPDYTGDHRYRNJSPTCSNYJQHKLLLZSLYDXXWBCJQSPXBPJZJCJDZFFXXBRMLAZHCSNDLBJDSZBLPRZTSWSBXBCLLXXLZDJZSJPYLYXXYFTFFFBHJJXGBYXJPMMMPSSJZJMTLYZJXSWXTYLEDQPJMYGQZJGDJLQJWJQLLSJGJGYGMSCLJJXDTYGJQJQJCJZCJGDZZSXQGSJGGCXHQXSNQLZZBXHSGZXCXYLJXYXYYDFQQJHJFXDHCTXJYRXYSQTJXYEFYYSSYYJXNCYZXFXMSYSZXYYSCHSHXZZZGZZZGFJDLTYLNPZGYJYZYYQZPBXQBDZTZCZYXXYHHSQXSHDHGQHJHGYWSZTMZMLHYXGEBTYLZKQWYTJZRCLEKYSTDBCYKQQSAYXCJXWWGSBHJYZYDHCSJKQCXSWXFLTYNYZPZCCZJQTZWJQDZZZQZLJJXLSBHPYXXPSXSHHEZTXFPTLQYZZXHYTXNCFZYYHXGNXMYWXTZSJPTHHGYMXMXQZXTSBCZYJYXXTYYZYPCQLMMSZMJZZLLZXGXZAAJZYXJMZXWDXZSXZDZXLEYJJZQBHZWZZZQTZPSXZTDSXJJJZNYAZPHXYYSRNQDTHZHYYKYJHDZXZLSWCLYBZYECWCYCRYLCXNHZYDZYDYJDFRJJHTRSQTXYXJRJHOJYNXELXSFSFJZGHPZSXZSZDZCQZBYYKLSGSJHCZSHDGQGXYZGXCHXZJWYQWGYHKSSEQZZNDZFKWYSSTCLZSTSYMCDHJXXYWEYXCZAYDMPXMDSXYBSQMJMZJMTZQLPJYQZCGQHXJHHLXXHLHDLDJQCLDWBSXFZZYYSCHTYTYYBHECXHYKGJPXHHYZJFXHWHBDZFYZBCAPNPGNYDMSXHMMMMAMYNBYJTMPXYYMCTHJBZYFCGTYHWPHFTWZZEZSBZEGPFMTSKFTYCMHFLLHGPZJXZJGZJYXZSBBQSCZZLZCCSTPGXMJSFTCCZJZDJXCYBZLFCJSYZFGSZLYBCWZZBYZDZYPSWYJZXZBDSYUXLZZBZFYGCZXBZHZFTPBGZGEJBSTGKDMFHYZZJHZLLZZGJQZLSFDJSSCBZGPDLFZFZSZYZYZSYGCXSNXXCHCZXTZZLJFZGQSQYXZJQDCCZTQCDXZJYQJQCHXZTDLGSCXZSYQJQTZWLQDQZTQCHQQJZYEZZZPBWKDJFCJPZTYPQYQTTYNLMBDKTJZPQZQZZFPZSBNJLGYJDXJDZZKZGQKXDLPZJTCJDQBXDJQJSTCKNXBXZMSLYJCQMTJQWWCJQNJNLLLHJCWQTBZQYDZCZPZZDZYDDCYZZZCCJTTJFZDPRRTZTJDCQTQZDTJNPLZBCLLCTZSXKJZQZPZLBZRBTJDCXFCZDBCCJJLTQQPLDCGZDBBZJCQDCJWYNLLZYZCCDWLLXWZLXRXNTQQCZXKQLSGDFQTDDGLRLAJJTKUYMKQLLTZYTDYYCZGJWYXDXFRSKSTQTENQMRKQZHHQKDLDAZFKYPBGGPZREBZZYKZZSPEGJXGYKQZZZSLYSYYYZWFQZYLZZLZHWCHKYPQGNPGBLPLRRJYXCCSYYHSFZFYBZYYTGZXYLXCZWXXZJZBLFFLGSKHYJZEYJHLPLLLLCZGXDRZELRHGKLZZYHZLYQSZZJZQLJZFLNBHGWLCZCFJYSPYXZLZLXGCCPZBLLCYBBBBUBBCBPCRNNZCZYRBFSRLDCGQYYQXYGMQZWTZYTYJXYFWTEHZZJYWLCCNTZYJJZDEDPZDZTSYQJHDYMBJNYJZLXTSSTPHNDJXXBYXQTZQDDTJTDYYTGWSCSZQFLSHLGLBCZPHDLYZJYCKWTYTYLBNYTSDSYCCTYSZYYEBHEXHQDTWNYGYCLXTSZYSTQMYGZAZCCSZZDSLZCLZRQXYYELJSBYMXSXZTEMBBLLYYLLYTDQYSHYMRQWKFKBFXNXSBYCHXBWJYHTQBPBSBWDZYLKGZSKYHXQZJXHXJXGNLJKZLYYCDXLFYFGHLJGJYBXQLYBXQPQGZTZPLNCYPXDJYQYDYMRBESJYYHKXXSTMXRCZZYWXYQYBMCLLYZHQYZWQXDBXBZWZMSLPDMYSKFMZKLZCYQYCZLQXFZZYDQZPZYGYJYZMZXDZFYFYTTQTZHGSPCZMLCCYTZXJCYTJMKSLPZHYSNZLLYTPZCTZZCKTXDHXXTQCYFKSMQCCYYAZHTJPCYLZLYJBJXTPNYLJYYNRXSYLMMNXJSMYBCSYSYLZYLXJJQYLDZLPQBFZZBLFNDXQKCZFYWHGQMRDSXYCYTXNQQJZYYPFZXDYZFPRXEJDGYQBXRCNFYYQPGHYJDYZXGRHTKYLNWDZNTSMPKLBTHBPYSZBZTJZSZZJTYYXZPHSSZZBZCZPTQFZMYFLYPYBBJQXZMXXDJMTSYSKKBJZXHJCKLPSMKYJZCXTMLJYXRZZQSLXXQPYZXMKYXXXJCLJPRMYYGADYSKQLSNDHYZKQXZYZTCGHZTLMLWZYBWSYCTBHJHJFCWZTXWYTKZLXQSHLYJZJXTMPLPYCGLTBZZTLZJCYJGDTCLKLPLLQPJMZPAPXYZLKKTKDZCZZBNZDYDYQZJYJGMCTXLTGXSZLMLHBGLKFWNWZHDXUHLFMKYSLGXDTWWFRJEJZTZHYDXYKSHWFZCQSHKTMQQHTZHYMJDJSKHXZJZBZZXYMPAGQMSTPXLSKLZYNWRTSQLSZBPSPSGZWYHTLKSSSWHZZLYYTNXJGMJSZSUFWNLSOZTXGXLSAMMLBWLDSZYLAKQCQCTMYCFJBSLXCLZZCLXXKSBZQCLHJPSQPLSXXCKSLNHPSFQQYTXYJZLQLDXZQJZDYYDJNZPTUZDSKJFSLJHYLZSQZLBTXYDGTQFDBYAZXDZHZJNHHQBYKNXJJQCZMLLJZKSPLDYCLBBLXKLELXJLBQYCXJXGCNLCQPLZLZYJTZLJGYZDZPLTQCSXFDMNYCXGBTJDCZNBGBQYQJWGKFHTNPYQZQGBKPBBYZMTJDYTBLSQMPSXTBNPDXKLEMYYCJYNZCTLDYKZZXDDXHQSHDGMZSJYCCTAYRZLPYLTLKXSLZCGGEXCLFXLKJRTLQJAQZNCMBYDKKCXGLCZJZXJHPTDJJMZQYKQSECQZDSHHADMLZFMMZBGNTJNNLGBYJBRBTMLBYJDZXLCJLPLDLPCQDHLXZLYCBLCXZZJADJLNZMMSSSMYBHBSQKBHRSXXJMXSDZNZPXLGBRHWGGFCXGMSKLLTSJYYCQLTSKYWYYHYWXBXQYWPYWYKQLSQPTNTKHQCWDQKTWPXXHCPTHTWUMSSYHBWCRWXHJMKMZNGWTMLKFGHKJYLSYYCXWHYECLQHKQHTTQKHFZLDXQWYZYYDESBPKYRZPJFYYZJCEQDZZDLATZBBFJLLCXDLMJSSXEGYGSJQXCWBXSSZPDYZCXDNYXPPZYDLYJCZPLTXLSXYZYRXCYYYDYLWWNZSAHJSYQYHGYWWAXTJZDAXYSRLTDPSSYYFNEJDXYZHLXLLLZQZSJNYQYQQXYJGHZGZCYJCHZLYCDSHWSHJZYJXCLLNXZJJYYXNFXMWFPYLCYLLABWDDHWDXJMCXZTZPMLQZHSFHZYNZTLLDYWLSLXHYMMYLMBWWKYXYADTXYLLDJPYBPWUXJMWMLLSAFDLLYFLBHHHBQQLTZJCQJLDJTFFKMMMBYTHYGDCQRDDWRQJXNBYSNWZDBYYTBJHPYBYTTJXAAHGQDQTMYSTQXKBTZPKJLZRBEQQSSMJJBDJOTGTBXPGBKTLHQXJJJCTHXQDWJLWRFWQGWSHCKRYSWGFTGYGBXSDWDWRFHWYTJJXXXJYZYSLPYYYPAYXHYDQKXSHXYXGSKQHYWFDDDPPLCJLQQEEWXKSYYKDYPLTJTHKJLTCYYHHJTTPLTZZCDLTHQKZXQYSTEEYWYYZYXXYYSTTJKLLPZMCYHQGXYHSRMBXPLLNQYDQHXSXXWGDQBSHYLLPJJJTHYJKYPPTHYYKTYEZYENMDSHLCRPQFDGFXZPSFTLJXXJBSWYYSKSFLXLPPLBBBLBSFXFYZBSJSSYLPBBFFFFSSCJDSTZSXZRYYSYFFSYZYZBJTBCTSBSDHRTJJBYTCXYJEYLXCBNEBJDSYXYKGSJZBXBYTFZWGENYHHTHZHHXFWGCSTBGXKLSXYWMTMBYXJSTZSCDYQRCYTWXZFHMYMCXLZNSDJTTTXRYCFYJSBSDYERXJLJXBBDEYNJGHXGCKGSCYMBLXJMSZNSKGXFBNBPTHFJAAFXYXFPXMYPQDTZCXZZPXRSYWZDLYBBKTYQPQJPZYPZJZNJPZJLZZFYSBTTSLMPTZRTDXQSJEHBZYLZDHLJSQMLHTXTJECXSLZZSPKTLZKQQYFSYGYWPCPQFHQHYTQXZKRSGTTSQCZLPTXCDYYZXSQZSLXLZMYCPCQBZYXHBSXLZDLTCDXTYLZJYYZPZYZLTXJSJXHLPMYTXCQRBLZSSFJZZTNJYTXMYJHLHPPLCYXQJQQKZZSCPZKSWALQSBLCCZJSXGWWWYGYKTJBBZTDKHXHKGTGPBKQYSLPXPJCKBMLLXDZSTBKLGGQKQLSBKKTFXRMDKBFTPZFRTBBRFERQGXYJPZSSTLBZTPSZQZSJDHLJQLZBPMSMMSXLQQNHKNBLRDDNXXDHDDJCYYGYLXGZLXSYGMQQGKHBPMXYXLYTQWLWGCPBMQXCYZYDRJBHTDJYHQSHTMJSBYPLWHLZFFNYPMHXXHPLTBQPFBJWQDBYGPNZTPFZJGSDDTQSHZEAWZZYLLTYYBWJKXXGHLFKXDJTMSZSQYNZGGSWQSPHTLSSKMCLZXYSZQZXNCJDQGZDLFNYKLJCJLLZLMZZNHYDSSHTHZZLZZBBHQZWWYCRZHLYQQJBEYFXXXWHSRXWQHWPSLMSSKZTTYGYQQWRSLALHMJTQJSMXQBJJZJXZYZKXBYQXBJXSHZTSFJLXMXZXFGHKZSZGGYLCLSARJYHSLLLMZXELGLXYDJYTLFBHBPNLYZFBBHPTGJKWETZHKJJXZXXGLLJLSTGSHJJYQLQZFKCGNNDJSSZFDBCTWWSEQFHQJBSAQTGYPQLBXBMMYWXGSLZHGLZGQYFLZBYFZJFRYSFMBYZHQGFWZSYFYJJPHZBYYZFFWODGRLMFTWLBZGYCQXCDJYGZYYYYTYTYDWEGAZYHXJLZYYHLRMGRXXZCLHNELJJTJTPWJYBJJBXJJTJTEEKHWSLJPLPSFYZPQQBDLQJJTYYQLYZKDKSQJYYQZLDQTGJQYZJSUCMRYQTHTEJMFCTYHYPKMHYZWJDQFHYYXWSHCTXRLJHQXHCCYYYJLTKTTYTMXGTCJTZAYYOCZLYLBSZYWJYTSJYHBYSHFJLYGJXXTMZYYLTXXYPZLXYJZYZYYPNHMYMDYYLBLHLSYYQQLLNJJYMSOYQBZGDLYXYLCQYXTSZEGXHZGLHWBLJHEYXTWQMAKBPQCGYSHHEGQCMWYYWLJYJHYYZLLJJYLHZYHMGSLJLJXCJJYCLYCJPCPZJZJMMYLCQLNQLJQJSXYJMLSZLJQLYCMMHCFMMFPQQMFYLQMCFFQMMMMHMZNFHHJGTTHHKHSLNCHHYQDXTMMQDCYZYXYQMYQYLTDCYYYZAZZCYMZYDLZFFFMMYCQZWZZMABTBYZTDMNZZGGDFTYPCGQYTTSSFFWFDTZQSSYSTWXJHXYTSXXYLBYQHWWKXHZXWZNNZZJZJJQJCCCHYYXBZXZCYZTLLCQXYNJYCYYCYNZZQYYYEWYCZDCJYCCHYJLBTZYYCQWMPWPYMLGKDLDLGKQQBGYCHJXY" + this.full_dict = { "a": "\u554a\u963f\u9515", "ai": "\u57c3\u6328\u54ce\u5509\u54c0\u7691\u764c\u853c\u77ee\u827e\u788d\u7231\u9698\u8bf6\u6371\u55f3\u55cc\u5ad2\u7477\u66a7\u7839\u953f\u972d", "an": "\u978d\u6c28\u5b89\u4ffa\u6309\u6697\u5cb8\u80fa\u6848\u8c19\u57ef\u63de\u72b4\u5eb5\u6849\u94f5\u9e4c\u9878\u9eef", "ang": "\u80ae\u6602\u76ce", "ao": "\u51f9\u6556\u71ac\u7ff1\u8884\u50b2\u5965\u61ca\u6fb3\u5773\u62d7\u55f7\u5662\u5c99\u5ed2\u9068\u5aaa\u9a9c\u8071\u87af\u93ca\u9ccc\u93d6", "ba": "\u82ad\u634c\u6252\u53ed\u5427\u7b06\u516b\u75a4\u5df4\u62d4\u8dcb\u9776\u628a\u8019\u575d\u9738\u7f62\u7238\u8307\u83dd\u8406\u636d\u5c9c\u705e\u6777\u94af\u7c91\u9c85\u9b43", "bai": "\u767d\u67cf\u767e\u6446\u4f70\u8d25\u62dc\u7a17\u859c\u63b0\u97b4", "ban": "\u6591\u73ed\u642c\u6273\u822c\u9881\u677f\u7248\u626e\u62cc\u4f34\u74e3\u534a\u529e\u7eca\u962a\u5742\u8c73\u94a3\u7622\u764d\u8228", "bang": "\u90a6\u5e2e\u6886\u699c\u8180\u7ed1\u68d2\u78c5\u868c\u9551\u508d\u8c24\u84a1\u8783", "bao": "\u82de\u80de\u5305\u8912\u96f9\u4fdd\u5821\u9971\u5b9d\u62b1\u62a5\u66b4\u8c79\u9c8d\u7206\u52f9\u8446\u5b80\u5b62\u7172\u9e28\u8913\u8db5\u9f85", "bo": "\u5265\u8584\u73bb\u83e0\u64ad\u62e8\u94b5\u6ce2\u535a\u52c3\u640f\u94c2\u7b94\u4f2f\u5e1b\u8236\u8116\u818a\u6e24\u6cca\u9a73\u4eb3\u8543\u5575\u997d\u6a97\u64d8\u7934\u94b9\u9e41\u7c38\u8ddb", "bei": "\u676f\u7891\u60b2\u5351\u5317\u8f88\u80cc\u8d1d\u94a1\u500d\u72c8\u5907\u60eb\u7119\u88ab\u5b5b\u9642\u90b6\u57e4\u84d3\u5457\u602b\u6096\u789a\u9e4e\u8919\u943e", "ben": "\u5954\u82ef\u672c\u7b28\u755a\u574c\u951b", "beng": "\u5d29\u7ef7\u752d\u6cf5\u8e66\u8ff8\u552a\u5623\u750f", "bi": "\u903c\u9f3b\u6bd4\u9119\u7b14\u5f7c\u78a7\u84d6\u853d\u6bd5\u6bd9\u6bd6\u5e01\u5e87\u75f9\u95ed\u655d\u5f0a\u5fc5\u8f9f\u58c1\u81c2\u907f\u965b\u5315\u4ef3\u4ffe\u8298\u835c\u8378\u5421\u54d4\u72f4\u5eb3\u610e\u6ed7\u6fde\u5f3c\u59a3\u5a62\u5b16\u74a7\u8d32\u7540\u94cb\u79d5\u88e8\u7b5a\u7b85\u7be6\u822d\u895e\u8df8\u9ac0", "bian": "\u97ad\u8fb9\u7f16\u8d2c\u6241\u4fbf\u53d8\u535e\u8fa8\u8fa9\u8fab\u904d\u533e\u5f01\u82c4\u5fed\u6c74\u7f0f\u7178\u782d\u78a5\u7a39\u7a86\u8759\u7b3e\u9cca", "biao": "\u6807\u5f6a\u8198\u8868\u5a4a\u9aa0\u98d1\u98d9\u98da\u706c\u9556\u9573\u762d\u88f1\u9cd4", "bie": "\u9cd6\u618b\u522b\u762a\u8e69\u9cd8", "bin": "\u5f6c\u658c\u6fd2\u6ee8\u5bbe\u6448\u50a7\u6d5c\u7f24\u73a2\u6ba1\u8191\u9554\u9acc\u9b13", "bing": "\u5175\u51b0\u67c4\u4e19\u79c9\u997c\u70b3\u75c5\u5e76\u7980\u90b4\u6452\u7ee0\u678b\u69df\u71f9", "bu": "\u6355\u535c\u54fa\u8865\u57e0\u4e0d\u5e03\u6b65\u7c3f\u90e8\u6016\u62ca\u535f\u900b\u74ff\u6661\u949a\u91ad", "ca": "\u64e6\u5693\u7924", "cai": "\u731c\u88c1\u6750\u624d\u8d22\u776c\u8e29\u91c7\u5f69\u83dc\u8521", "can": "\u9910\u53c2\u8695\u6b8b\u60ed\u60e8\u707f\u9a96\u74a8\u7cb2\u9eea", "cang": "\u82cd\u8231\u4ed3\u6ca7\u85cf\u4f27", "cao": "\u64cd\u7cd9\u69fd\u66f9\u8349\u8279\u5608\u6f15\u87ac\u825a", "ce": "\u5395\u7b56\u4fa7\u518c\u6d4b\u5202\u5e3b\u607b", "ceng": "\u5c42\u8e6d\u564c", "cha": "\u63d2\u53c9\u832c\u8336\u67e5\u78b4\u643d\u5bdf\u5c94\u5dee\u8be7\u7339\u9987\u6c4a\u59f9\u6748\u6942\u69ce\u6aab\u9497\u9538\u9572\u8869", "chai": "\u62c6\u67f4\u8c7a\u4faa\u8308\u7625\u867f\u9f87", "chan": "\u6400\u63ba\u8749\u998b\u8c17\u7f20\u94f2\u4ea7\u9610\u98a4\u5181\u8c04\u8c36\u8487\u5edb\u5fcf\u6f7a\u6fb6\u5b71\u7fbc\u5a75\u5b17\u9aa3\u89c7\u7985\u9561\u88e3\u87fe\u8e94", "chang": "\u660c\u7316\u573a\u5c1d\u5e38\u957f\u507f\u80a0\u5382\u655e\u7545\u5531\u5021\u4f25\u9b2f\u82cc\u83d6\u5f9c\u6005\u60dd\u960a\u5a3c\u5ae6\u6636\u6c05\u9cb3", "chao": "\u8d85\u6284\u949e\u671d\u5632\u6f6e\u5de2\u5435\u7092\u600a\u7ec9\u6641\u8016", "che": "\u8f66\u626f\u64a4\u63a3\u5f7b\u6f88\u577c\u5c6e\u7817", "chen": "\u90f4\u81e3\u8fb0\u5c18\u6668\u5ff1\u6c89\u9648\u8d81\u886c\u79f0\u8c0c\u62bb\u55d4\u5bb8\u741b\u6987\u809c\u80c2\u789c\u9f80", "cheng": "\u6491\u57ce\u6a59\u6210\u5448\u4e58\u7a0b\u60e9\u6f84\u8bda\u627f\u901e\u9a8b\u79e4\u57d5\u5d4a\u5fb5\u6d48\u67a8\u67fd\u6a18\u665f\u584d\u77a0\u94d6\u88ce\u86cf\u9172", "chi": "\u5403\u75f4\u6301\u5319\u6c60\u8fdf\u5f1b\u9a70\u803b\u9f7f\u4f88\u5c3a\u8d64\u7fc5\u65a5\u70bd\u50ba\u5880\u82aa\u830c\u640b\u53f1\u54e7\u557b\u55e4\u5f73\u996c\u6cb2\u5ab8\u6555\u80dd\u7719\u7735\u9e31\u761b\u892b\u86a9\u87ad\u7b1e\u7bea\u8c49\u8e05\u8e1f\u9b51", "chong": "\u5145\u51b2\u866b\u5d07\u5ba0\u833a\u5fe1\u61a7\u94f3\u825f", "chou": "\u62bd\u916c\u7574\u8e0c\u7a20\u6101\u7b79\u4ec7\u7ef8\u7785\u4e11\u4fe6\u5733\u5e31\u60c6\u6eb4\u59af\u7633\u96e0\u9c8b", "chu": "\u81ed\u521d\u51fa\u6a71\u53a8\u8e87\u9504\u96cf\u6ec1\u9664\u695a\u7840\u50a8\u77d7\u6410\u89e6\u5904\u4e8d\u520d\u61b7\u7ecc\u6775\u696e\u6a17\u870d\u8e70\u9edc", "chuan": "\u63e3\u5ddd\u7a7f\u693d\u4f20\u8239\u5598\u4e32\u63be\u821b\u60f4\u9044\u5ddb\u6c1a\u948f\u9569\u8221", "chuang": "\u75ae\u7a97\u5e62\u5e8a\u95ef\u521b\u6006", "chui": "\u5439\u708a\u6376\u9524\u5782\u9672\u68f0\u69cc", "chun": "\u6625\u693f\u9187\u5507\u6df3\u7eaf\u8822\u4fc3\u83bc\u6c8c\u80ab\u6710\u9e51\u877d", "chuo": "\u6233\u7ef0\u851f\u8fb6\u8f8d\u955e\u8e14\u9f8a", "ci": "\u75b5\u8328\u78c1\u96cc\u8f9e\u6148\u74f7\u8bcd\u6b64\u523a\u8d50\u6b21\u8360\u5472\u5d6f\u9e5a\u8785\u7ccd\u8d91", "cong": "\u806a\u8471\u56f1\u5306\u4ece\u4e1b\u506c\u82c1\u6dd9\u9aa2\u742e\u7481\u679e", "cu": "\u51d1\u7c97\u918b\u7c07\u731d\u6b82\u8e59", "cuan": "\u8e7f\u7be1\u7a9c\u6c46\u64ba\u6615\u7228", "cui": "\u6467\u5d14\u50ac\u8106\u7601\u7cb9\u6dec\u7fe0\u8403\u60b4\u7480\u69b1\u96b9", "cun": "\u6751\u5b58\u5bf8\u78cb\u5fd6\u76b4", "cuo": "\u64ae\u6413\u63aa\u632b\u9519\u539d\u811e\u9509\u77ec\u75e4\u9e7e\u8e49\u8e9c", "da": "\u642d\u8fbe\u7b54\u7629\u6253\u5927\u8037\u54d2\u55d2\u601b\u59b2\u75b8\u8921\u7b2a\u977c\u9791", "dai": "\u5446\u6b79\u50a3\u6234\u5e26\u6b86\u4ee3\u8d37\u888b\u5f85\u902e\u6020\u57ed\u7519\u5454\u5cb1\u8fe8\u902f\u9a80\u7ed0\u73b3\u9edb", "dan": "\u803d\u62c5\u4e39\u5355\u90f8\u63b8\u80c6\u65e6\u6c2e\u4f46\u60ee\u6de1\u8bde\u5f39\u86cb\u4ebb\u510b\u5369\u840f\u5556\u6fb9\u6a90\u6b9a\u8d55\u7708\u7605\u8043\u7baa", "dang": "\u5f53\u6321\u515a\u8361\u6863\u8c20\u51fc\u83ea\u5b95\u7800\u94db\u88c6", "dao": "\u5200\u6363\u8e48\u5012\u5c9b\u7977\u5bfc\u5230\u7a3b\u60bc\u9053\u76d7\u53e8\u5541\u5fc9\u6d2e\u6c18\u7118\u5fd1\u7e9b", "de": "\u5fb7\u5f97\u7684\u951d", "deng": "\u8e6c\u706f\u767b\u7b49\u77aa\u51f3\u9093\u5654\u5d9d\u6225\u78f4\u956b\u7c26", "di": "\u5824\u4f4e\u6ef4\u8fea\u654c\u7b1b\u72c4\u6da4\u7fdf\u5ae1\u62b5\u5e95\u5730\u8482\u7b2c\u5e1d\u5f1f\u9012\u7f14\u6c10\u7c74\u8bcb\u8c1b\u90b8\u577b\u839c\u837b\u5600\u5a23\u67e2\u68e3\u89cc\u7825\u78b2\u7747\u955d\u7f9d\u9ab6", "dian": "\u98a0\u6382\u6ec7\u7898\u70b9\u5178\u975b\u57ab\u7535\u4f43\u7538\u5e97\u60e6\u5960\u6dc0\u6bbf\u4e36\u963d\u576b\u57dd\u5dc5\u73b7\u765c\u766b\u7c1f\u8e2e", "diao": "\u7889\u53fc\u96d5\u51cb\u5201\u6389\u540a\u9493\u8c03\u8f7a\u94de\u8729\u7c9c\u8c82", "die": "\u8dcc\u7239\u789f\u8776\u8fed\u8c0d\u53e0\u4f5a\u57a4\u581e\u63f2\u558b\u6e2b\u8f76\u7252\u74de\u8936\u800b\u8e40\u9cbd\u9cce", "ding": "\u4e01\u76ef\u53ee\u9489\u9876\u9f0e\u952d\u5b9a\u8ba2\u4e22\u4ec3\u5576\u738e\u815a\u7887\u753a\u94e4\u7594\u8035\u914a", "dong": "\u4e1c\u51ac\u8463\u61c2\u52a8\u680b\u4f97\u606b\u51bb\u6d1e\u578c\u549a\u5cbd\u5cd2\u5902\u6c21\u80e8\u80f4\u7850\u9e2b", "dou": "\u515c\u6296\u6597\u9661\u8c46\u9017\u75d8\u8538\u94ad\u7aa6\u7aac\u86aa\u7bfc\u9161", "du": "\u90fd\u7763\u6bd2\u728a\u72ec\u8bfb\u5835\u7779\u8d4c\u675c\u9540\u809a\u5ea6\u6e21\u5992\u828f\u561f\u6e0e\u691f\u6a50\u724d\u8839\u7b03\u9ad1\u9ee9", "duan": "\u7aef\u77ed\u953b\u6bb5\u65ad\u7f0e\u5f56\u6934\u7145\u7c16", "dui": "\u5806\u5151\u961f\u5bf9\u603c\u619d\u7893", "dun": "\u58a9\u5428\u8e72\u6566\u987f\u56e4\u949d\u76fe\u9041\u7096\u7818\u7905\u76f9\u9566\u8db8", "duo": "\u6387\u54c6\u591a\u593a\u579b\u8eb2\u6735\u8dfa\u8235\u5241\u60f0\u5815\u5484\u54da\u7f0d\u67c1\u94ce\u88f0\u8e31", "e": "\u86fe\u5ce8\u9e45\u4fc4\u989d\u8bb9\u5a25\u6076\u5384\u627c\u904f\u9102\u997f\u5669\u8c14\u57a9\u57ad\u82ca\u83aa\u843c\u5443\u6115\u5c59\u5a40\u8f6d\u66f7\u816d\u786a\u9507\u9537\u9e57\u989a\u9cc4", "en": "\u6069\u84bd\u6441\u5514\u55ef", "er": "\u800c\u513f\u8033\u5c14\u9975\u6d31\u4e8c\u8d30\u8fe9\u73e5\u94d2\u9e38\u9c95", "fa": "\u53d1\u7f5a\u7b4f\u4f10\u4e4f\u9600\u6cd5\u73d0\u57a1\u781d", "fan": "\u85e9\u5e06\u756a\u7ffb\u6a0a\u77fe\u9492\u7e41\u51e1\u70e6\u53cd\u8fd4\u8303\u8d29\u72af\u996d\u6cdb\u8629\u5e61\u72ad\u68b5\u6535\u71d4\u7548\u8e6f", "fang": "\u574a\u82b3\u65b9\u80aa\u623f\u9632\u59a8\u4eff\u8bbf\u7eba\u653e\u531a\u90a1\u5f77\u94ab\u822b\u9c82", "fei": "\u83f2\u975e\u5561\u98de\u80a5\u532a\u8bfd\u5420\u80ba\u5e9f\u6cb8\u8d39\u82be\u72d2\u60b1\u6ddd\u5983\u7ecb\u7eef\u69a7\u8153\u6590\u6249\u7953\u7829\u9544\u75f1\u871a\u7bda\u7fe1\u970f\u9cb1", "fen": "\u82ac\u915a\u5429\u6c1b\u5206\u7eb7\u575f\u711a\u6c7e\u7c89\u594b\u4efd\u5fff\u6124\u7caa\u507e\u7035\u68fc\u610d\u9cbc\u9f22", "feng": "\u4e30\u5c01\u67ab\u8702\u5cf0\u950b\u98ce\u75af\u70fd\u9022\u51af\u7f1d\u8bbd\u5949\u51e4\u4ff8\u9146\u8451\u6ca3\u781c", "fu": "\u4f5b\u5426\u592b\u6577\u80a4\u5b75\u6276\u62c2\u8f90\u5e45\u6c1f\u7b26\u4f0f\u4fd8\u670d\u6d6e\u6daa\u798f\u88b1\u5f17\u752b\u629a\u8f85\u4fef\u91dc\u65a7\u812f\u8151\u5e9c\u8150\u8d74\u526f\u8986\u8d4b\u590d\u5085\u4ed8\u961c\u7236\u8179\u8d1f\u5bcc\u8ba3\u9644\u5987\u7f1a\u5490\u5310\u51eb\u90db\u8299\u82fb\u832f\u83a9\u83d4\u544b\u5e5e\u6ecf\u8274\u5b5a\u9a78\u7ec2\u6874\u8d59\u9efb\u9efc\u7f58\u7a03\u99a5\u864d\u86a8\u8709\u8760\u876e\u9eb8\u8dba\u8dd7\u9cc6", "ga": "\u5676\u560e\u86e4\u5c2c\u5477\u5c15\u5c1c\u65ee\u9486", "gai": "\u8be5\u6539\u6982\u9499\u76d6\u6e89\u4e10\u9654\u5793\u6224\u8d45\u80f2", "gan": "\u5e72\u7518\u6746\u67d1\u7aff\u809d\u8d76\u611f\u79c6\u6562\u8d63\u5769\u82f7\u5c34\u64c0\u6cd4\u6de6\u6f89\u7ec0\u6a44\u65f0\u77f8\u75b3\u9150", "gang": "\u5188\u521a\u94a2\u7f38\u809b\u7eb2\u5c97\u6e2f\u6206\u7f61\u9883\u7b7b", "gong": "\u6760\u5de5\u653b\u529f\u606d\u9f9a\u4f9b\u8eac\u516c\u5bab\u5f13\u5de9\u6c5e\u62f1\u8d21\u5171\u857b\u5efe\u54a3\u73d9\u80b1\u86a3\u86e9\u89e5", "gao": "\u7bd9\u768b\u9ad8\u818f\u7f94\u7cd5\u641e\u9550\u7a3f\u544a\u777e\u8bf0\u90dc\u84bf\u85c1\u7f1f\u69d4\u69c1\u6772\u9506", "ge": "\u54e5\u6b4c\u6401\u6208\u9e3d\u80f3\u7599\u5272\u9769\u845b\u683c\u9601\u9694\u94ec\u4e2a\u5404\u9b32\u4ee1\u54ff\u5865\u55dd\u7ea5\u643f\u8188\u784c\u94ea\u9549\u88bc\u988c\u867c\u8238\u9abc\u9ac2", "gei": "\u7ed9", "gen": "\u6839\u8ddf\u4e98\u831b\u54cf\u826e", "geng": "\u8015\u66f4\u5e9a\u7fb9\u57c2\u803f\u6897\u54fd\u8d53\u9ca0", "gou": "\u94a9\u52fe\u6c9f\u82df\u72d7\u57a2\u6784\u8d2d\u591f\u4f5d\u8bdf\u5ca3\u9058\u5abe\u7f11\u89cf\u5f40\u9e32\u7b31\u7bdd\u97b2", "gu": "\u8f9c\u83c7\u5495\u7b8d\u4f30\u6cbd\u5b64\u59d1\u9f13\u53e4\u86ca\u9aa8\u8c37\u80a1\u6545\u987e\u56fa\u96c7\u560f\u8bc2\u83f0\u54cc\u5d2e\u6c69\u688f\u8f71\u726f\u727f\u80cd\u81cc\u6bc2\u77bd\u7f5f\u94b4\u9522\u74e0\u9e2a\u9e44\u75fc\u86c4\u9164\u89da\u9cb4\u9ab0\u9e58", "gua": "\u522e\u74dc\u5250\u5be1\u6302\u8902\u5366\u8bd6\u5471\u681d\u9e39", "guai": "\u4e56\u62d0\u602a\u54d9", "guan": "\u68fa\u5173\u5b98\u51a0\u89c2\u7ba1\u9986\u7f50\u60ef\u704c\u8d2f\u500c\u839e\u63bc\u6dab\u76e5\u9e73\u9ccf", "guang": "\u5149\u5e7f\u901b\u72b7\u6844\u80f1\u7592", "gui": "\u7470\u89c4\u572d\u7845\u5f52\u9f9f\u95fa\u8f68\u9b3c\u8be1\u7678\u6842\u67dc\u8dea\u8d35\u523d\u5326\u523f\u5e8b\u5b84\u59ab\u6867\u7085\u6677\u7688\u7c0b\u9c91\u9cdc", "gun": "\u8f8a\u6eda\u68cd\u4e28\u886e\u7ef2\u78d9\u9ca7", "guo": "\u9505\u90ed\u56fd\u679c\u88f9\u8fc7\u9998\u8803\u57da\u63b4\u5459\u56d7\u5e3c\u5d1e\u7313\u6901\u8662\u951e\u8052\u872e\u873e\u8748", "ha": "\u54c8", "hai": "\u9ab8\u5b69\u6d77\u6c26\u4ea5\u5bb3\u9a87\u54b4\u55e8\u988f\u91a2", "han": "\u9163\u61a8\u90af\u97e9\u542b\u6db5\u5bd2\u51fd\u558a\u7f55\u7ff0\u64bc\u634d\u65f1\u61be\u608d\u710a\u6c57\u6c49\u9097\u83e1\u6496\u961a\u701a\u6657\u7113\u9894\u86b6\u9f3e", "hen": "\u592f\u75d5\u5f88\u72e0\u6068", "hang": "\u676d\u822a\u6c86\u7ed7\u73e9\u6841", "hao": "\u58d5\u568e\u8c6a\u6beb\u90dd\u597d\u8017\u53f7\u6d69\u8585\u55e5\u5686\u6fe0\u704f\u660a\u7693\u98a2\u869d", "he": "\u5475\u559d\u8377\u83cf\u6838\u79be\u548c\u4f55\u5408\u76d2\u8c89\u9602\u6cb3\u6db8\u8d6b\u8910\u9e64\u8d3a\u8bc3\u52be\u58d1\u85ff\u55d1\u55ec\u9616\u76cd\u86b5\u7fee", "hei": "\u563f\u9ed1", "heng": "\u54fc\u4ea8\u6a2a\u8861\u6052\u8a07\u8605", "hong": "\u8f70\u54c4\u70d8\u8679\u9e3f\u6d2a\u5b8f\u5f18\u7ea2\u9ec9\u8ba7\u836d\u85a8\u95f3\u6cd3", "hou": "\u5589\u4faf\u7334\u543c\u539a\u5019\u540e\u5820\u5f8c\u9005\u760a\u7bcc\u7cc7\u9c8e\u9aba", "hu": "\u547c\u4e4e\u5ffd\u745a\u58f6\u846b\u80e1\u8774\u72d0\u7cca\u6e56\u5f27\u864e\u552c\u62a4\u4e92\u6caa\u6237\u51b1\u553f\u56eb\u5cb5\u7322\u6019\u60da\u6d52\u6ef9\u7425\u69f2\u8f77\u89f3\u70c0\u7173\u623d\u6248\u795c\u9e55\u9e71\u7b0f\u9190\u659b", "hua": "\u82b1\u54d7\u534e\u733e\u6ed1\u753b\u5212\u5316\u8bdd\u5290\u6d4d\u9a85\u6866\u94e7\u7a1e", "huai": "\u69d0\u5f8a\u6000\u6dee\u574f\u8fd8\u8e1d", "huan": "\u6b22\u73af\u6853\u7f13\u6362\u60a3\u5524\u75ea\u8c62\u7115\u6da3\u5ba6\u5e7b\u90c7\u5942\u57b8\u64d0\u571c\u6d39\u6d63\u6f36\u5bf0\u902d\u7f33\u953e\u9ca9\u9b1f", "huang": "\u8352\u614c\u9ec4\u78fa\u8757\u7c27\u7687\u51f0\u60f6\u714c\u6643\u5e4c\u604d\u8c0e\u968d\u5fa8\u6e5f\u6f62\u9051\u749c\u8093\u7640\u87e5\u7bc1\u9cc7", "hui": "\u7070\u6325\u8f89\u5fbd\u6062\u86d4\u56de\u6bc1\u6094\u6167\u5349\u60e0\u6666\u8d3f\u79fd\u4f1a\u70e9\u6c47\u8bb3\u8bf2\u7ed8\u8bd9\u8334\u835f\u8559\u54d5\u5599\u96b3\u6d04\u5f57\u7f0b\u73f2\u6656\u605a\u867a\u87ea\u9ebe", "hun": "\u8364\u660f\u5a5a\u9b42\u6d51\u6df7\u8be8\u9984\u960d\u6eb7\u7f17", "huo": "\u8c41\u6d3b\u4f19\u706b\u83b7\u6216\u60d1\u970d\u8d27\u7978\u6509\u56af\u5925\u94ac\u952a\u956c\u8020\u8816", "ji": "\u51fb\u573e\u57fa\u673a\u7578\u7a3d\u79ef\u7b95\u808c\u9965\u8ff9\u6fc0\u8ba5\u9e21\u59ec\u7ee9\u7f09\u5409\u6781\u68d8\u8f91\u7c4d\u96c6\u53ca\u6025\u75be\u6c72\u5373\u5ac9\u7ea7\u6324\u51e0\u810a\u5df1\u84df\u6280\u5180\u5b63\u4f0e\u796d\u5242\u60b8\u6d4e\u5bc4\u5bc2\u8ba1\u8bb0\u65e2\u5fcc\u9645\u5993\u7ee7\u7eaa\u5c45\u4e0c\u4e69\u525e\u4f76\u4f74\u8114\u58bc\u82a8\u82b0\u8401\u84ba\u857a\u638e\u53fd\u54ad\u54dc\u5527\u5c8c\u5d74\u6d0e\u5f50\u5c50\u9aa5\u757f\u7391\u696b\u6b9b\u621f\u6222\u8d4d\u89ca\u7284\u9f51\u77f6\u7f81\u5d47\u7a37\u7620\u7635\u866e\u7b08\u7b04\u66a8\u8dfb\u8dfd\u9701\u9c9a\u9cab\u9afb\u9e82", "jia": "\u5609\u67b7\u5939\u4f73\u5bb6\u52a0\u835a\u988a\u8d3e\u7532\u94be\u5047\u7a3c\u4ef7\u67b6\u9a7e\u5ac1\u4f3d\u90cf\u62ee\u5cac\u6d43\u8fe6\u73c8\u621b\u80db\u605d\u94d7\u9553\u75c2\u86f1\u7b33\u8888\u8dcf", "jian": "\u6b7c\u76d1\u575a\u5c16\u7b3a\u95f4\u714e\u517c\u80a9\u8270\u5978\u7f04\u8327\u68c0\u67ec\u78b1\u7877\u62e3\u6361\u7b80\u4fed\u526a\u51cf\u8350\u69db\u9274\u8df5\u8d31\u89c1\u952e\u7bad\u4ef6\u5065\u8230\u5251\u996f\u6e10\u6e85\u6da7\u5efa\u50ed\u8c0f\u8c2b\u83c5\u84b9\u641b\u56dd\u6e54\u8e47\u8b07\u7f23\u67a7\u67d9\u6957\u620b\u622c\u726e\u728d\u6bfd\u8171\u7751\u950f\u9e63\u88e5\u7b15\u7bb4\u7fe6\u8dbc\u8e3a\u9ca3\u97af", "jiang": "\u50f5\u59dc\u5c06\u6d46\u6c5f\u7586\u848b\u6868\u5956\u8bb2\u5320\u9171\u964d\u8333\u6d1a\u7edb\u7f30\u729f\u7913\u8029\u7ce8\u8c47", "jiao": "\u8549\u6912\u7901\u7126\u80f6\u4ea4\u90ca\u6d47\u9a84\u5a07\u56bc\u6405\u94f0\u77eb\u4fa5\u811a\u72e1\u89d2\u997a\u7f34\u7ede\u527f\u6559\u9175\u8f7f\u8f83\u53eb\u4f7c\u50ec\u832d\u6322\u564d\u5ce4\u5fbc\u59e3\u7e9f\u656b\u768e\u9e6a\u86df\u91ae\u8de4\u9c9b", "jie": "\u7a96\u63ed\u63a5\u7686\u79f8\u8857\u9636\u622a\u52ab\u8282\u6854\u6770\u6377\u776b\u7aed\u6d01\u7ed3\u89e3\u59d0\u6212\u85c9\u82a5\u754c\u501f\u4ecb\u75a5\u8beb\u5c4a\u5048\u8ba6\u8bd8\u5588\u55df\u736c\u5a55\u5b51\u6840\u7352\u78a3\u9534\u7596\u88b7\u9889\u86a7\u7faf\u9c92\u9ab1\u9aeb", "jin": "\u5dfe\u7b4b\u65a4\u91d1\u4eca\u6d25\u895f\u7d27\u9526\u4ec5\u8c28\u8fdb\u9773\u664b\u7981\u8fd1\u70ec\u6d78\u5c3d\u537a\u8369\u5807\u5664\u9991\u5ed1\u5997\u7f19\u747e\u69ff\u8d46\u89d0\u9485\u9513\u887f\u77dc", "jing": "\u52b2\u8346\u5162\u830e\u775b\u6676\u9cb8\u4eac\u60ca\u7cbe\u7cb3\u7ecf\u4e95\u8b66\u666f\u9888\u9759\u5883\u656c\u955c\u5f84\u75c9\u9756\u7adf\u7ade\u51c0\u522d\u5106\u9631\u83c1\u734d\u61ac\u6cfe\u8ff3\u5f2a\u5a67\u80bc\u80eb\u8148\u65cc", "jiong": "\u70af\u7a98\u5182\u8fe5\u6243", "jiu": "\u63ea\u7a76\u7ea0\u7396\u97ed\u4e45\u7078\u4e5d\u9152\u53a9\u6551\u65e7\u81fc\u8205\u548e\u5c31\u759a\u50e6\u557e\u9604\u67e9\u6855\u9e6b\u8d73\u9b0f", "ju": "\u97a0\u62d8\u72d9\u75bd\u9a79\u83ca\u5c40\u5480\u77e9\u4e3e\u6cae\u805a\u62d2\u636e\u5de8\u5177\u8ddd\u8e1e\u952f\u4ff1\u53e5\u60e7\u70ac\u5267\u5028\u8bb5\u82e3\u82f4\u8392\u63ac\u907d\u5c66\u741a\u67b8\u6910\u6998\u6989\u6a58\u728b\u98d3\u949c\u9514\u7aad\u88fe\u8d84\u91b5\u8e3d\u9f83\u96ce\u97ab", "juan": "\u6350\u9e43\u5a1f\u5026\u7737\u5377\u7ee2\u9104\u72f7\u6d93\u684a\u8832\u9529\u954c\u96bd", "jue": "\u6485\u652b\u6289\u6398\u5014\u7235\u89c9\u51b3\u8bc0\u7edd\u53a5\u5282\u8c32\u77cd\u8568\u5658\u5d1b\u7357\u5b53\u73cf\u6877\u6a5b\u721d\u9562\u8e76\u89d6", "jun": "\u5747\u83cc\u94a7\u519b\u541b\u5cfb\u4fca\u7ae3\u6d5a\u90e1\u9a8f\u6343\u72fb\u76b2\u7b60\u9e87", "ka": "\u5580\u5496\u5361\u4f67\u5494\u80e9", "ke": "\u54af\u5777\u82db\u67ef\u68f5\u78d5\u9897\u79d1\u58f3\u54b3\u53ef\u6e34\u514b\u523b\u5ba2\u8bfe\u5ca2\u606a\u6e98\u9a92\u7f02\u73c2\u8f72\u6c2a\u778c\u94b6\u75b4\u7aa0\u874c\u9ac1", "kai": "\u5f00\u63e9\u6977\u51ef\u6168\u5240\u57b2\u8488\u5ffe\u607a\u94e0\u950e", "kan": "\u520a\u582a\u52d8\u574e\u780d\u770b\u4f83\u51f5\u83b0\u83b6\u6221\u9f9b\u77b0", "kang": "\u5eb7\u6177\u7ce0\u625b\u6297\u4ea2\u7095\u5751\u4f09\u95f6\u94aa", "kao": "\u8003\u62f7\u70e4\u9760\u5c3b\u6832\u7292\u94d0", "ken": "\u80af\u5543\u57a6\u6073\u57a0\u88c9\u9880", "keng": "\u542d\u5fd0\u94ff", "kong": "\u7a7a\u6050\u5b54\u63a7\u5025\u5d06\u7b9c", "kou": "\u62a0\u53e3\u6263\u5bc7\u82a4\u853b\u53e9\u770d\u7b58", "ku": "\u67af\u54ed\u7a9f\u82e6\u9177\u5e93\u88e4\u5233\u5800\u55be\u7ed4\u9ab7", "kua": "\u5938\u57ae\u630e\u8de8\u80ef\u4f89", "kuai": "\u5757\u7b77\u4fa9\u5feb\u84af\u90d0\u8489\u72ef\u810d", "kuan": "\u5bbd\u6b3e\u9acb", "kuang": "\u5321\u7b50\u72c2\u6846\u77ff\u7736\u65f7\u51b5\u8bd3\u8bf3\u909d\u5739\u593c\u54d0\u7ea9\u8d36", "kui": "\u4e8f\u76d4\u5cbf\u7aa5\u8475\u594e\u9b41\u5080\u9988\u6127\u6e83\u9997\u532e\u5914\u9697\u63c6\u55b9\u559f\u609d\u6126\u9615\u9035\u668c\u777d\u8069\u8770\u7bd1\u81fe\u8dec", "kun": "\u5764\u6606\u6346\u56f0\u6083\u9603\u7428\u951f\u918c\u9cb2\u9ae1", "kuo": "\u62ec\u6269\u5ed3\u9614\u86de", "la": "\u5783\u62c9\u5587\u8721\u814a\u8fa3\u5566\u524c\u647a\u908b\u65ef\u782c\u760c", "lai": "\u83b1\u6765\u8d56\u5d03\u5f95\u6d9e\u6fd1\u8d49\u7750\u94fc\u765e\u7c41", "lan": "\u84dd\u5a6a\u680f\u62e6\u7bee\u9611\u5170\u6f9c\u8c30\u63fd\u89c8\u61d2\u7f06\u70c2\u6ee5\u5549\u5c9a\u61d4\u6f24\u6984\u6593\u7f71\u9567\u8934", "lang": "\u7405\u6994\u72fc\u5eca\u90ce\u6717\u6d6a\u83a8\u8497\u5577\u9606\u9512\u7a02\u8782", "lao": "\u635e\u52b3\u7262\u8001\u4f6c\u59e5\u916a\u70d9\u6d9d\u5520\u5d02\u6833\u94d1\u94f9\u75e8\u91aa", "le": "\u52d2\u4e50\u808b\u4ec2\u53fb\u561e\u6cd0\u9cd3", "lei": "\u96f7\u956d\u857e\u78ca\u7d2f\u5121\u5792\u64c2\u7c7b\u6cea\u7fb8\u8bd4\u837d\u54a7\u6f2f\u5ad8\u7f27\u6a91\u8012\u9179", "ling": "\u68f1\u51b7\u62ce\u73b2\u83f1\u96f6\u9f84\u94c3\u4f36\u7f9a\u51cc\u7075\u9675\u5cad\u9886\u53e6\u4ee4\u9143\u5844\u82d3\u5464\u56f9\u6ce0\u7eeb\u67c3\u68c2\u74f4\u8046\u86c9\u7fce\u9cae", "leng": "\u695e\u6123", "li": "\u5398\u68a8\u7281\u9ece\u7bf1\u72f8\u79bb\u6f13\u7406\u674e\u91cc\u9ca4\u793c\u8389\u8354\u540f\u6817\u4e3d\u5389\u52b1\u783e\u5386\u5229\u5088\u4f8b\u4fd0\u75e2\u7acb\u7c92\u6ca5\u96b6\u529b\u7483\u54e9\u4fea\u4fda\u90e6\u575c\u82c8\u8385\u84e0\u85dc\u6369\u5456\u5533\u55b1\u7301\u6ea7\u6fa7\u9026\u5a0c\u5ae0\u9a8a\u7f21\u73de\u67a5\u680e\u8f79\u623e\u783a\u8a48\u7f79\u9502\u9e42\u75a0\u75ac\u86ce\u870a\u8821\u7b20\u7be5\u7c9d\u91b4\u8dde\u96f3\u9ca1\u9ce2\u9ee7", "lian": "\u4fe9\u8054\u83b2\u8fde\u9570\u5ec9\u601c\u6d9f\u5e18\u655b\u8138\u94fe\u604b\u70bc\u7ec3\u631b\u8539\u5941\u6f4b\u6fc2\u5a08\u740f\u695d\u6b93\u81c1\u81a6\u88e2\u880a\u9ca2", "liang": "\u7cae\u51c9\u6881\u7cb1\u826f\u4e24\u8f86\u91cf\u667e\u4eae\u8c05\u589a\u690b\u8e09\u9753\u9b49", "liao": "\u64a9\u804a\u50da\u7597\u71ce\u5be5\u8fbd\u6f66\u4e86\u6482\u9563\u5ed6\u6599\u84fc\u5c25\u5639\u7360\u5bee\u7f2d\u948c\u9e69\u8022", "lie": "\u5217\u88c2\u70c8\u52a3\u730e\u51bd\u57d2\u6d0c\u8d94\u8e90\u9b23", "lin": "\u7433\u6797\u78f7\u9716\u4e34\u90bb\u9cde\u6dcb\u51db\u8d41\u541d\u853a\u5d99\u5eea\u9074\u6aa9\u8f9a\u77b5\u7cbc\u8e8f\u9e9f", "liu": "\u6e9c\u7409\u69b4\u786b\u998f\u7559\u5218\u7624\u6d41\u67f3\u516d\u62a1\u507b\u848c\u6cd6\u6d4f\u905b\u9a9d\u7efa\u65d2\u7198\u950d\u954f\u9e68\u938f", "long": "\u9f99\u804b\u5499\u7b3c\u7abf\u9686\u5784\u62e2\u9647\u5f04\u5785\u830f\u6cf7\u73d1\u680a\u80e7\u783b\u7643", "lou": "\u697c\u5a04\u6402\u7bd3\u6f0f\u964b\u55bd\u5d5d\u9542\u7618\u8027\u877c\u9ac5", "lu": "\u82a6\u5362\u9885\u5e90\u7089\u63b3\u5364\u864f\u9c81\u9e93\u788c\u9732\u8def\u8d42\u9e7f\u6f5e\u7984\u5f55\u9646\u622e\u5786\u6445\u64b8\u565c\u6cf8\u6e0c\u6f09\u7490\u680c\u6a79\u8f73\u8f82\u8f98\u6c07\u80ea\u9565\u9e2c\u9e6d\u7c0f\u823b\u9c88", "lv": "\u9a74\u5415\u94dd\u4fa3\u65c5\u5c65\u5c61\u7f15\u8651\u6c2f\u5f8b\u7387\u6ee4\u7eff\u634b\u95fe\u6988\u8182\u7a06\u891b", "luan": "\u5ce6\u5b6a\u6ee6\u5375\u4e71\u683e\u9e3e\u92ae", "lue": "\u63a0\u7565\u950a", "lun": "\u8f6e\u4f26\u4ed1\u6ca6\u7eb6\u8bba\u56f5", "luo": "\u841d\u87ba\u7f57\u903b\u9523\u7ba9\u9aa1\u88f8\u843d\u6d1b\u9a86\u7edc\u502e\u8366\u645e\u7321\u6cfa\u6924\u8136\u9559\u7630\u96d2", "ma": "\u5988\u9ebb\u739b\u7801\u8682\u9a6c\u9a82\u561b\u5417\u551b\u72b8\u5b37\u6769\u9ebd", "mai": "\u57cb\u4e70\u9ea6\u5356\u8fc8\u8109\u52a2\u836c\u54aa\u973e", "man": "\u7792\u9992\u86ee\u6ee1\u8513\u66fc\u6162\u6f2b\u8c29\u5881\u5e54\u7f26\u71b3\u9558\u989f\u87a8\u9cd7\u9794", "mang": "\u8292\u832b\u76f2\u5fd9\u83bd\u9099\u6f2d\u6726\u786d\u87d2", "meng": "\u6c13\u840c\u8499\u6aac\u76df\u9530\u731b\u68a6\u5b5f\u52d0\u750d\u77a2\u61f5\u791e\u867b\u8722\u8813\u824b\u8268\u9efe", "miao": "\u732b\u82d7\u63cf\u7784\u85d0\u79d2\u6e3a\u5e99\u5999\u55b5\u9088\u7f08\u7f2a\u676a\u6dfc\u7707\u9e4b\u8731", "mao": "\u8305\u951a\u6bdb\u77db\u94c6\u536f\u8302\u5192\u5e3d\u8c8c\u8d38\u4f94\u88a4\u52d6\u8306\u5cc1\u7441\u6634\u7266\u8004\u65c4\u61cb\u7780\u86d1\u8765\u87ca\u9ae6", "me": "\u4e48", "mei": "\u73ab\u679a\u6885\u9176\u9709\u7164\u6ca1\u7709\u5a92\u9541\u6bcf\u7f8e\u6627\u5bd0\u59b9\u5a9a\u5776\u8393\u5d4b\u7338\u6d7c\u6e44\u6963\u9545\u9e5b\u8882\u9b45", "men": "\u95e8\u95f7\u4eec\u626a\u739f\u7116\u61d1\u9494", "mi": "\u772f\u919a\u9761\u7cdc\u8ff7\u8c1c\u5f25\u7c73\u79d8\u89c5\u6ccc\u871c\u5bc6\u5e42\u8288\u5196\u8c27\u863c\u5627\u7315\u736f\u6c68\u5b93\u5f2d\u8112\u6549\u7cf8\u7e3b\u9e8b", "mian": "\u68c9\u7720\u7ef5\u5195\u514d\u52c9\u5a29\u7f05\u9762\u6c94\u6e4e\u817c\u7704", "mie": "\u8511\u706d\u54a9\u881b\u7bfe", "min": "\u6c11\u62bf\u76bf\u654f\u60af\u95fd\u82e0\u5cb7\u95f5\u6cef\u73c9", "ming": "\u660e\u879f\u9e23\u94ed\u540d\u547d\u51a5\u8317\u6e9f\u669d\u7791\u9169", "miu": "\u8c2c", "mo": "\u6478\u6479\u8611\u6a21\u819c\u78e8\u6469\u9b54\u62b9\u672b\u83ab\u58a8\u9ed8\u6cab\u6f20\u5bde\u964c\u8c1f\u8309\u84e6\u998d\u5aeb\u9546\u79e3\u763c\u8031\u87c6\u8c8a\u8c98", "mou": "\u8c0b\u725f\u67d0\u53b6\u54de\u5a7a\u7738\u936a", "mu": "\u62c7\u7261\u4ea9\u59c6\u6bcd\u5893\u66ae\u5e55\u52df\u6155\u6728\u76ee\u7766\u7267\u7a46\u4eeb\u82dc\u5452\u6c90\u6bea\u94bc", "na": "\u62ff\u54ea\u5450\u94a0\u90a3\u5a1c\u7eb3\u5185\u637a\u80ad\u954e\u8872\u7bac", "nai": "\u6c16\u4e43\u5976\u8010\u5948\u9f10\u827f\u8418\u67f0", "nan": "\u5357\u7537\u96be\u56ca\u5583\u56e1\u6960\u8169\u877b\u8d67", "nao": "\u6320\u8111\u607c\u95f9\u5b6c\u57b4\u7331\u7459\u7847\u94d9\u86f2", "ne": "\u6dd6\u5462\u8bb7", "nei": "\u9981", "nen": "\u5ae9\u80fd\u6798\u6041", "ni": "\u59ae\u9713\u502a\u6ce5\u5c3c\u62df\u4f60\u533f\u817b\u9006\u6eba\u4f32\u576d\u730a\u6029\u6ee0\u6635\u65ce\u7962\u615d\u7768\u94cc\u9cb5", "nian": "\u852b\u62c8\u5e74\u78be\u64b5\u637b\u5ff5\u5eff\u8f87\u9ecf\u9c87\u9cb6", "niang": "\u5a18\u917f", "niao": "\u9e1f\u5c3f\u8311\u5b32\u8132\u8885", "nie": "\u634f\u8042\u5b7d\u556e\u954a\u954d\u6d85\u4e5c\u9667\u8616\u55eb\u8080\u989e\u81ec\u8e51", "nin": "\u60a8\u67e0", "ning": "\u72de\u51dd\u5b81\u62e7\u6cde\u4f5e\u84e5\u549b\u752f\u804d", "niu": "\u725b\u626d\u94ae\u7ebd\u72c3\u5ff8\u599e\u86b4", "nong": "\u8113\u6d53\u519c\u4fac", "nu": "\u5974\u52aa\u6012\u5476\u5e11\u5f29\u80ec\u5b65\u9a7d", "nv": "\u5973\u6067\u9495\u8844", "nuan": "\u6696", "nuenue": "\u8650", "nue": "\u759f\u8c11", "nuo": "\u632a\u61e6\u7cef\u8bfa\u50a9\u6426\u558f\u9518", "ou": "\u54e6\u6b27\u9e25\u6bb4\u85d5\u5455\u5076\u6ca4\u6004\u74ef\u8026", "pa": "\u556a\u8db4\u722c\u5e15\u6015\u7436\u8469\u7b62", "pai": "\u62cd\u6392\u724c\u5f98\u6e43\u6d3e\u4ff3\u848e", "pan": "\u6500\u6f58\u76d8\u78d0\u76fc\u7554\u5224\u53db\u723f\u6cee\u88a2\u897b\u87e0\u8e52", "pang": "\u4e53\u5e9e\u65c1\u802a\u80d6\u6ec2\u9004", "pao": "\u629b\u5486\u5228\u70ae\u888d\u8dd1\u6ce1\u530f\u72cd\u5e96\u812c\u75b1", "pei": "\u5478\u80da\u57f9\u88f4\u8d54\u966a\u914d\u4f69\u6c9b\u638a\u8f94\u5e14\u6de0\u65c6\u952b\u9185\u9708", "pen": "\u55b7\u76c6\u6e53", "peng": "\u7830\u62a8\u70f9\u6f8e\u5f6d\u84ec\u68da\u787c\u7bf7\u81a8\u670b\u9e4f\u6367\u78b0\u576f\u580b\u562d\u6026\u87db", "pi": "\u7812\u9739\u6279\u62ab\u5288\u7435\u6bd7\u5564\u813e\u75b2\u76ae\u5339\u75de\u50fb\u5c41\u8b6c\u4e15\u9674\u90b3\u90eb\u572e\u9f19\u64d7\u567c\u5e80\u5ab2\u7eb0\u6787\u7513\u7765\u7f74\u94cd\u75e6\u7656\u758b\u868d\u8c94", "pian": "\u7bc7\u504f\u7247\u9a97\u8c1d\u9a88\u728f\u80fc\u890a\u7fe9\u8e41", "piao": "\u98d8\u6f02\u74e2\u7968\u527d\u560c\u5ad6\u7f25\u6b8d\u779f\u87b5", "pie": "\u6487\u77a5\u4e3f\u82e4\u6c15", "pin": "\u62fc\u9891\u8d2b\u54c1\u8058\u62da\u59d8\u5ad4\u6980\u725d\u98a6", "ping": "\u4e52\u576a\u82f9\u840d\u5e73\u51ed\u74f6\u8bc4\u5c4f\u4fdc\u5a09\u67b0\u9c86", "po": "\u5761\u6cfc\u9887\u5a46\u7834\u9b44\u8feb\u7c95\u53f5\u9131\u6ea5\u73c0\u948b\u94b7\u76a4\u7b38", "pou": "\u5256\u88d2\u8e23", "pu": "\u6251\u94fa\u4ec6\u8386\u8461\u83e9\u84b2\u57d4\u6734\u5703\u666e\u6d66\u8c31\u66dd\u7011\u530d\u5657\u6fee\u749e\u6c06\u9564\u9568\u8e7c", "qi": "\u671f\u6b3a\u6816\u621a\u59bb\u4e03\u51c4\u6f06\u67d2\u6c8f\u5176\u68cb\u5947\u6b67\u7566\u5d0e\u8110\u9f50\u65d7\u7948\u7941\u9a91\u8d77\u5c82\u4e5e\u4f01\u542f\u5951\u780c\u5668\u6c14\u8fc4\u5f03\u6c7d\u6ce3\u8bab\u4e9f\u4e93\u573b\u8291\u840b\u847a\u5601\u5c7a\u5c90\u6c54\u6dc7\u9a90\u7eee\u742a\u7426\u675e\u6864\u69ed\u6b39\u797a\u61a9\u789b\u86f4\u871e\u7da6\u7dae\u8dbf\u8e4a\u9ccd\u9e92", "qia": "\u6390\u6070\u6d3d\u845c", "qian": "\u7275\u6266\u948e\u94c5\u5343\u8fc1\u7b7e\u4edf\u8c26\u4e7e\u9ed4\u94b1\u94b3\u524d\u6f5c\u9063\u6d45\u8c34\u5811\u5d4c\u6b20\u6b49\u4f65\u9621\u828a\u82a1\u8368\u63ae\u5c8d\u60ad\u614a\u9a9e\u6434\u8930\u7f31\u6920\u80b7\u6106\u94a4\u8654\u7b9d", "qiang": "\u67aa\u545b\u8154\u7f8c\u5899\u8537\u5f3a\u62a2\u5af1\u6a2f\u6217\u709d\u9516\u9535\u956a\u8941\u8723\u7f9f\u8deb\u8dc4", "qiao": "\u6a47\u9539\u6572\u6084\u6865\u77a7\u4e54\u4fa8\u5de7\u9798\u64ac\u7fd8\u5ced\u4fcf\u7a8d\u5281\u8bee\u8c2f\u835e\u6100\u6194\u7f32\u6a35\u6bf3\u7857\u8df7\u9792", "qie": "\u5207\u8304\u4e14\u602f\u7a83\u90c4\u553c\u60ec\u59be\u6308\u9532\u7ba7", "qin": "\u94a6\u4fb5\u4eb2\u79e6\u7434\u52e4\u82b9\u64d2\u79bd\u5bdd\u6c81\u82a9\u84c1\u8572\u63ff\u5423\u55ea\u5659\u6eb1\u6a8e\u8793\u887e", "qing": "\u9752\u8f7b\u6c22\u503e\u537f\u6e05\u64ce\u6674\u6c30\u60c5\u9877\u8bf7\u5e86\u5029\u82d8\u570a\u6aa0\u78ec\u873b\u7f44\u7b90\u8b26\u9cad\u9ee5", "qiong": "\u743c\u7a77\u909b\u8315\u7a79\u7b47\u928e", "qiu": "\u79cb\u4e18\u90b1\u7403\u6c42\u56da\u914b\u6cc5\u4fc5\u6c3d\u5def\u827d\u72b0\u6e6b\u9011\u9052\u6978\u8d47\u9e20\u866c\u86af\u8764\u88d8\u7cd7\u9cc5\u9f3d", "qu": "\u8d8b\u533a\u86c6\u66f2\u8eaf\u5c48\u9a71\u6e20\u53d6\u5a36\u9f8b\u8da3\u53bb\u8bce\u52ac\u8556\u8627\u5c96\u8862\u9612\u74a9\u89d1\u6c0d\u795b\u78f2\u766f\u86d0\u883c\u9eb4\u77bf\u9ee2", "quan": "\u5708\u98a7\u6743\u919b\u6cc9\u5168\u75ca\u62f3\u72ac\u5238\u529d\u8be0\u8343\u737e\u609b\u7efb\u8f81\u754e\u94e8\u8737\u7b4c\u9b08", "que": "\u7f3a\u7094\u7638\u5374\u9e4a\u69b7\u786e\u96c0\u9619\u60ab", "qun": "\u88d9\u7fa4\u9021", "ran": "\u7136\u71c3\u5189\u67d3\u82d2\u9aef", "rang": "\u74e4\u58e4\u6518\u56b7\u8ba9\u79b3\u7a70", "rao": "\u9976\u6270\u7ed5\u835b\u5a06\u6861", "ruo": "\u60f9\u82e5\u5f31", "re": "\u70ed\u504c", "ren": "\u58ec\u4ec1\u4eba\u5fcd\u97e7\u4efb\u8ba4\u5203\u598a\u7eab\u4ede\u834f\u845a\u996a\u8f6b\u7a14\u887d", "reng": "\u6254\u4ecd", "ri": "\u65e5", "rong": "\u620e\u8338\u84c9\u8363\u878d\u7194\u6eb6\u5bb9\u7ed2\u5197\u5d58\u72e8\u7f1b\u6995\u877e", "rou": "\u63c9\u67d4\u8089\u7cc5\u8e42\u97a3", "ru": "\u8339\u8815\u5112\u5b7a\u5982\u8fb1\u4e73\u6c5d\u5165\u8925\u84d0\u85b7\u5685\u6d33\u6ebd\u6fe1\u94f7\u8966\u98a5", "ruan": "\u8f6f\u962e\u670a", "rui": "\u854a\u745e\u9510\u82ae\u8564\u777f\u868b", "run": "\u95f0\u6da6", "sa": "\u6492\u6d12\u8428\u5345\u4ee8\u6332\u98d2", "sai": "\u816e\u9cc3\u585e\u8d5b\u567b", "san": "\u4e09\u53c1\u4f1e\u6563\u5f61\u9993\u6c35\u6bf5\u7cc1\u9730", "sang": "\u6851\u55d3\u4e27\u6421\u78c9\u98a1", "sao": "\u6414\u9a9a\u626b\u5ac2\u57fd\u81ca\u7619\u9ccb", "se": "\u745f\u8272\u6da9\u556c\u94e9\u94ef\u7a51", "sen": "\u68ee", "seng": "\u50e7", "sha": "\u838e\u7802\u6740\u5239\u6c99\u7eb1\u50bb\u5565\u715e\u810e\u6b43\u75e7\u88df\u970e\u9ca8", "shai": "\u7b5b\u6652\u917e", "shan": "\u73ca\u82eb\u6749\u5c71\u5220\u717d\u886b\u95ea\u9655\u64c5\u8d61\u81b3\u5584\u6c55\u6247\u7f2e\u5261\u8baa\u912f\u57cf\u829f\u6f78\u59d7\u9a9f\u81bb\u9490\u759d\u87ee\u8222\u8dda\u9cdd", "shang": "\u5892\u4f24\u5546\u8d4f\u664c\u4e0a\u5c1a\u88f3\u57a7\u7ef1\u6b87\u71b5\u89de", "shao": "\u68a2\u634e\u7a0d\u70e7\u828d\u52fa\u97f6\u5c11\u54e8\u90b5\u7ecd\u52ad\u82d5\u6f72\u86f8\u7b24\u7b72\u8244", "she": "\u5962\u8d4a\u86c7\u820c\u820d\u8d66\u6444\u5c04\u6151\u6d89\u793e\u8bbe\u538d\u4f58\u731e\u7572\u9e9d", "shen": "\u7837\u7533\u547b\u4f38\u8eab\u6df1\u5a20\u7ec5\u795e\u6c88\u5ba1\u5a76\u751a\u80be\u614e\u6e17\u8bdc\u8c02\u5432\u54c2\u6e16\u6939\u77e7\u8703", "sheng": "\u58f0\u751f\u7525\u7272\u5347\u7ef3\u7701\u76db\u5269\u80dc\u5723\u4e1e\u6e11\u5ab5\u771a\u7b19", "shi": "\u5e08\u5931\u72ee\u65bd\u6e7f\u8bd7\u5c38\u8671\u5341\u77f3\u62fe\u65f6\u4ec0\u98df\u8680\u5b9e\u8bc6\u53f2\u77e2\u4f7f\u5c4e\u9a76\u59cb\u5f0f\u793a\u58eb\u4e16\u67ff\u4e8b\u62ed\u8a93\u901d\u52bf\u662f\u55dc\u566c\u9002\u4ed5\u4f8d\u91ca\u9970\u6c0f\u5e02\u6043\u5ba4\u89c6\u8bd5\u8c25\u57d8\u83b3\u84cd\u5f11\u5511\u9963\u8f7c\u8006\u8d33\u70bb\u793b\u94c8\u94ca\u87ab\u8210\u7b6e\u8c55\u9ca5\u9cba", "shou": "\u6536\u624b\u9996\u5b88\u5bff\u6388\u552e\u53d7\u7626\u517d\u624c\u72e9\u7ef6\u824f", "shu": "\u852c\u67a2\u68b3\u6b8a\u6292\u8f93\u53d4\u8212\u6dd1\u758f\u4e66\u8d4e\u5b70\u719f\u85af\u6691\u66d9\u7f72\u8700\u9ecd\u9f20\u5c5e\u672f\u8ff0\u6811\u675f\u620d\u7ad6\u5885\u5eb6\u6570\u6f31\u6055\u500f\u587e\u83fd\u5fc4\u6cad\u6d91\u6f8d\u59dd\u7ebe\u6bf9\u8167\u6bb3\u956f\u79eb\u9e6c", "shua": "\u5237\u800d\u5530\u6dae", "shuai": "\u6454\u8870\u7529\u5e05\u87c0", "shuan": "\u6813\u62f4\u95e9", "shuang": "\u971c\u53cc\u723d\u5b40", "shui": "\u8c01\u6c34\u7761\u7a0e", "shun": "\u542e\u77ac\u987a\u821c\u6042", "shuo": "\u8bf4\u7855\u6714\u70c1\u84b4\u6420\u55cd\u6fef\u5981\u69ca\u94c4", "si": "\u65af\u6495\u5636\u601d\u79c1\u53f8\u4e1d\u6b7b\u8086\u5bfa\u55e3\u56db\u4f3a\u4f3c\u9972\u5df3\u53ae\u4fdf\u5155\u83e5\u549d\u6c5c\u6cd7\u6f8c\u59d2\u9a77\u7f0c\u7940\u7960\u9536\u9e36\u801c\u86f3\u7b25", "song": "\u677e\u8038\u6002\u9882\u9001\u5b8b\u8bbc\u8bf5\u51c7\u83d8\u5d27\u5d69\u5fea\u609a\u6dde\u7ae6", "sou": "\u641c\u8258\u64de\u55fd\u53df\u55d6\u55fe\u998a\u6eb2\u98d5\u778d\u953c\u878b", "su": "\u82cf\u9165\u4fd7\u7d20\u901f\u7c9f\u50f3\u5851\u6eaf\u5bbf\u8bc9\u8083\u5919\u8c21\u850c\u55c9\u612b\u7c0c\u89eb\u7a23", "suan": "\u9178\u849c\u7b97", "sui": "\u867d\u968b\u968f\u7ee5\u9ad3\u788e\u5c81\u7a57\u9042\u96a7\u795f\u84d1\u51ab\u8c07\u6fc9\u9083\u71e7\u772d\u7762", "sun": "\u5b59\u635f\u7b0b\u836a\u72f2\u98e7\u69ab\u8de3\u96bc", "suo": "\u68ad\u5506\u7f29\u7410\u7d22\u9501\u6240\u5522\u55e6\u5a11\u686b\u7743\u7fa7", "ta": "\u584c\u4ed6\u5b83\u5979\u5854\u736d\u631e\u8e4b\u8e0f\u95fc\u6ebb\u9062\u69bb\u6c93", "tai": "\u80ce\u82d4\u62ac\u53f0\u6cf0\u915e\u592a\u6001\u6c70\u90b0\u85b9\u80bd\u70b1\u949b\u8dc6\u9c90", "tan": "\u574d\u644a\u8d2a\u762b\u6ee9\u575b\u6a80\u75f0\u6f6d\u8c2d\u8c08\u5766\u6bef\u8892\u78b3\u63a2\u53f9\u70ad\u90ef\u8548\u6619\u94bd\u952c\u8983", "tang": "\u6c64\u5858\u642a\u5802\u68e0\u819b\u5510\u7cd6\u50a5\u9967\u6e8f\u746d\u94f4\u9557\u8025\u8797\u87b3\u7fb0\u91a3", "thang": "\u5018\u8eba\u6dcc", "theng": "\u8d9f\u70eb", "tao": "\u638f\u6d9b\u6ed4\u7ee6\u8404\u6843\u9003\u6dd8\u9676\u8ba8\u5957\u6311\u9f17\u5555\u97ec\u9955", "te": "\u7279", "teng": "\u85e4\u817e\u75bc\u8a8a\u6ed5", "ti": "\u68af\u5254\u8e22\u9511\u63d0\u9898\u8e44\u557c\u4f53\u66ff\u568f\u60d5\u6d95\u5243\u5c49\u8351\u608c\u9016\u7ee8\u7f07\u9e48\u88fc\u918d", "tian": "\u5929\u6dfb\u586b\u7530\u751c\u606c\u8214\u8146\u63ad\u5fdd\u9617\u6b84\u754b\u94bf\u86ba", "tiao": "\u6761\u8fe2\u773a\u8df3\u4f7b\u7967\u94eb\u7a95\u9f86\u9ca6", "tie": "\u8d34\u94c1\u5e16\u841c\u992e", "ting": "\u5385\u542c\u70c3\u6c40\u5ef7\u505c\u4ead\u5ead\u633a\u8247\u839b\u8476\u5a77\u6883\u8713\u9706", "tong": "\u901a\u6850\u916e\u77b3\u540c\u94dc\u5f64\u7ae5\u6876\u6345\u7b52\u7edf\u75db\u4f5f\u50ee\u4edd\u833c\u55f5\u6078\u6f7c\u783c", "tou": "\u5077\u6295\u5934\u900f\u4ea0", "tu": "\u51f8\u79c3\u7a81\u56fe\u5f92\u9014\u6d82\u5c60\u571f\u5410\u5154\u580d\u837c\u83df\u948d\u9174", "tuan": "\u6e4d\u56e2\u7583", "tui": "\u63a8\u9893\u817f\u8715\u892a\u9000\u5fd2\u717a", "tun": "\u541e\u5c6f\u81c0\u9968\u66be\u8c5a\u7a80", "tuo": "\u62d6\u6258\u8131\u9e35\u9640\u9a6e\u9a7c\u692d\u59a5\u62d3\u553e\u4e47\u4f57\u5768\u5eb9\u6cb1\u67dd\u7823\u7ba8\u8204\u8dce\u9f0d", "wa": "\u6316\u54c7\u86d9\u6d3c\u5a03\u74e6\u889c\u4f64\u5a32\u817d", "wai": "\u6b6a\u5916", "wan": "\u8c4c\u5f2f\u6e7e\u73a9\u987d\u4e38\u70f7\u5b8c\u7897\u633d\u665a\u7696\u60cb\u5b9b\u5a49\u4e07\u8155\u525c\u8284\u82cb\u83c0\u7ea8\u7efe\u742c\u8118\u7579\u873f\u7ba2", "wang": "\u6c6a\u738b\u4ea1\u6789\u7f51\u5f80\u65fa\u671b\u5fd8\u5984\u7f54\u5c22\u60d8\u8f8b\u9b4d", "wei": "\u5a01\u5dcd\u5fae\u5371\u97e6\u8fdd\u6845\u56f4\u552f\u60df\u4e3a\u6f4d\u7ef4\u82c7\u840e\u59d4\u4f1f\u4f2a\u5c3e\u7eac\u672a\u851a\u5473\u754f\u80c3\u5582\u9b4f\u4f4d\u6e2d\u8c13\u5c09\u6170\u536b\u502d\u504e\u8bff\u9688\u8473\u8587\u5e0f\u5e37\u5d34\u5d6c\u7325\u732c\u95f1\u6ca9\u6d27\u6da0\u9036\u5a13\u73ae\u97ea\u8ece\u709c\u7168\u71a8\u75ff\u8249\u9c94", "wen": "\u761f\u6e29\u868a\u6587\u95fb\u7eb9\u543b\u7a33\u7d0a\u95ee\u520e\u6120\u960c\u6c76\u74ba\u97eb\u6b81\u96ef", "weng": "\u55e1\u7fc1\u74ee\u84ca\u8579", "wo": "\u631d\u8717\u6da1\u7a9d\u6211\u65a1\u5367\u63e1\u6c83\u83b4\u5e44\u6e25\u674c\u809f\u9f8c", "wu": "\u5deb\u545c\u94a8\u4e4c\u6c61\u8bec\u5c4b\u65e0\u829c\u68a7\u543e\u5434\u6bcb\u6b66\u4e94\u6342\u5348\u821e\u4f0d\u4fae\u575e\u620a\u96fe\u6664\u7269\u52ff\u52a1\u609f\u8bef\u5140\u4ef5\u9622\u90ac\u572c\u82b4\u5e91\u6003\u5fe4\u6d6f\u5be4\u8fd5\u59a9\u9a9b\u727e\u7110\u9e49\u9e5c\u8708\u92c8\u9f2f", "xi": "\u6614\u7199\u6790\u897f\u7852\u77fd\u6670\u563b\u5438\u9521\u727a\u7a00\u606f\u5e0c\u6089\u819d\u5915\u60dc\u7184\u70ef\u6eaa\u6c50\u7280\u6a84\u88ad\u5e2d\u4e60\u5ab3\u559c\u94e3\u6d17\u7cfb\u9699\u620f\u7ec6\u50d6\u516e\u96b0\u90d7\u831c\u8478\u84f0\u595a\u550f\u5f99\u9969\u960b\u6d60\u6dc5\u5c63\u5b09\u73ba\u6a28\u66e6\u89cb\u6b37\u71b9\u798a\u79a7\u94b8\u7699\u7a78\u8725\u87cb\u823e\u7fb2\u7c9e\u7fd5\u91af\u9f37", "xia": "\u778e\u867e\u5323\u971e\u8f96\u6687\u5ce1\u4fa0\u72ed\u4e0b\u53a6\u590f\u5413\u6380\u846d\u55c4\u72ce\u9050\u7455\u7856\u7615\u7f45\u9ee0", "xian": "\u9528\u5148\u4ed9\u9c9c\u7ea4\u54b8\u8d24\u8854\u8237\u95f2\u6d8e\u5f26\u5acc\u663e\u9669\u73b0\u732e\u53bf\u817a\u9985\u7fa1\u5baa\u9677\u9650\u7ebf\u51bc\u85d3\u5c98\u7303\u66b9\u5a34\u6c19\u7946\u9e47\u75eb\u86ac\u7b45\u7c7c\u9170\u8df9", "xiang": "\u76f8\u53a2\u9576\u9999\u7bb1\u8944\u6e58\u4e61\u7fd4\u7965\u8be6\u60f3\u54cd\u4eab\u9879\u5df7\u6a61\u50cf\u5411\u8c61\u8297\u8459\u9977\u5ea0\u9aa7\u7f03\u87d3\u9c9e\u98e8", "xiao": "\u8427\u785d\u9704\u524a\u54ee\u56a3\u9500\u6d88\u5bb5\u6dc6\u6653\u5c0f\u5b5d\u6821\u8096\u5578\u7b11\u6548\u54d3\u54bb\u5d24\u6f47\u900d\u9a81\u7ee1\u67ad\u67b5\u7b71\u7bab\u9b48", "xie": "\u6954\u4e9b\u6b47\u874e\u978b\u534f\u631f\u643a\u90aa\u659c\u80c1\u8c10\u5199\u68b0\u5378\u87f9\u61c8\u6cc4\u6cfb\u8c22\u5c51\u5055\u4eb5\u52f0\u71ee\u85a4\u64b7\u5ee8\u7023\u9082\u7ec1\u7f2c\u69ad\u698d\u6b59\u8e9e", "xin": "\u85aa\u82af\u950c\u6b23\u8f9b\u65b0\u5ffb\u5fc3\u4fe1\u8845\u56df\u99a8\u8398\u6b46\u94fd\u946b", "xing": "\u661f\u8165\u7329\u60fa\u5174\u5211\u578b\u5f62\u90a2\u884c\u9192\u5e78\u674f\u6027\u59d3\u9649\u8347\u8365\u64e4\u60bb\u784e", "xiong": "\u5144\u51f6\u80f8\u5308\u6c79\u96c4\u718a\u828e", "xiu": "\u4f11\u4fee\u7f9e\u673d\u55c5\u9508\u79c0\u8896\u7ee3\u83a0\u5cab\u9990\u5ea5\u9e3a\u8c85\u9af9", "xu": "\u589f\u620c\u9700\u865a\u5618\u987b\u5f90\u8bb8\u84c4\u9157\u53d9\u65ed\u5e8f\u755c\u6064\u7d6e\u5a7f\u7eea\u7eed\u8bb4\u8be9\u5729\u84ff\u6035\u6d2b\u6e86\u987c\u6829\u7166\u7809\u76f1\u80e5\u7cc8\u9191", "xuan": "\u8f69\u55a7\u5ba3\u60ac\u65cb\u7384\u9009\u7663\u7729\u7eda\u5107\u8c16\u8431\u63ce\u9994\u6ceb\u6d35\u6e32\u6f29\u7487\u6966\u6684\u70ab\u714a\u78b9\u94c9\u955f\u75c3", "xue": "\u9774\u859b\u5b66\u7a74\u96ea\u8840\u5671\u6cf6\u9cd5", "xun": "\u52cb\u718f\u5faa\u65ec\u8be2\u5bfb\u9a6f\u5de1\u6b89\u6c5b\u8bad\u8baf\u900a\u8fc5\u5dfd\u57d9\u8340\u85b0\u5ccb\u5f87\u6d54\u66db\u7aa8\u91ba\u9c9f", "ya": "\u538b\u62bc\u9e26\u9e2d\u5440\u4e2b\u82bd\u7259\u869c\u5d16\u8859\u6daf\u96c5\u54d1\u4e9a\u8bb6\u4f22\u63e0\u5416\u5c88\u8fd3\u5a05\u740a\u6860\u6c29\u7811\u775a\u75d6", "yan": "\u7109\u54bd\u9609\u70df\u6df9\u76d0\u4e25\u7814\u8712\u5ca9\u5ef6\u8a00\u989c\u960e\u708e\u6cbf\u5944\u63a9\u773c\u884d\u6f14\u8273\u5830\u71d5\u538c\u781a\u96c1\u5501\u5f66\u7130\u5bb4\u8c1a\u9a8c\u53a3\u9765\u8d5d\u4fe8\u5043\u5156\u8ba0\u8c33\u90fe\u9122\u82ab\u83f8\u5d26\u6079\u95eb\u960f\u6d07\u6e6e\u6edf\u598d\u5ae3\u7430\u664f\u80ed\u814c\u7131\u7f68\u7b75\u917d\u9b47\u990d\u9f39", "yang": "\u6b83\u592e\u9e2f\u79e7\u6768\u626c\u4f6f\u75a1\u7f8a\u6d0b\u9633\u6c27\u4ef0\u75d2\u517b\u6837\u6f3e\u5f89\u600f\u6cf1\u7080\u70ca\u6059\u86d8\u9785", "yao": "\u9080\u8170\u5996\u7476\u6447\u5c27\u9065\u7a91\u8c23\u59da\u54ac\u8200\u836f\u8981\u8000\u592d\u723b\u5406\u5d3e\u5fad\u7039\u5e7a\u73e7\u6773\u66dc\u80b4\u9e5e\u7a88\u7e47\u9cd0", "ye": "\u6930\u564e\u8036\u7237\u91ce\u51b6\u4e5f\u9875\u6396\u4e1a\u53f6\u66f3\u814b\u591c\u6db2\u8c12\u90ba\u63f6\u9980\u6654\u70e8\u94d8", "yi": "\u4e00\u58f9\u533b\u63d6\u94f1\u4f9d\u4f0a\u8863\u9890\u5937\u9057\u79fb\u4eea\u80f0\u7591\u6c82\u5b9c\u59e8\u5f5d\u6905\u8681\u501a\u5df2\u4e59\u77e3\u4ee5\u827a\u6291\u6613\u9091\u5c79\u4ebf\u5f79\u81c6\u9038\u8084\u75ab\u4ea6\u88d4\u610f\u6bc5\u5fc6\u4e49\u76ca\u6ea2\u8be3\u8bae\u8c0a\u8bd1\u5f02\u7ffc\u7fcc\u7ece\u5208\u5293\u4f7e\u8bd2\u572a\u572f\u57f8\u61ff\u82e1\u858f\u5f08\u5955\u6339\u5f0b\u5453\u54a6\u54bf\u566b\u5cc4\u5db7\u7317\u9974\u603f\u6021\u6092\u6f2a\u8fe4\u9a7f\u7f22\u6baa\u8d3b\u65d6\u71a0\u9487\u9552\u9571\u75cd\u7617\u7654\u7fca\u8864\u8734\u8223\u7fbf\u7ff3\u914f\u9edf", "yin": "\u8335\u836b\u56e0\u6bb7\u97f3\u9634\u59fb\u541f\u94f6\u6deb\u5bc5\u996e\u5c39\u5f15\u9690\u5370\u80e4\u911e\u5819\u831a\u5591\u72fa\u5924\u6c24\u94df\u763e\u8693\u972a\u9f88", "ying": "\u82f1\u6a31\u5a74\u9e70\u5e94\u7f28\u83b9\u8424\u8425\u8367\u8747\u8fce\u8d62\u76c8\u5f71\u9896\u786c\u6620\u5b34\u90e2\u8314\u83ba\u8426\u6484\u5624\u81ba\u6ee2\u6f46\u701b\u745b\u748e\u6979\u9e66\u763f\u988d\u7f42", "yo": "\u54df\u5537", "yong": "\u62e5\u4f63\u81c3\u75c8\u5eb8\u96cd\u8e0a\u86f9\u548f\u6cf3\u6d8c\u6c38\u607f\u52c7\u7528\u4fd1\u58c5\u5889\u6175\u9095\u955b\u752c\u9cd9\u9954", "you": "\u5e7d\u4f18\u60a0\u5fe7\u5c24\u7531\u90ae\u94c0\u72b9\u6cb9\u6e38\u9149\u6709\u53cb\u53f3\u4f51\u91c9\u8bf1\u53c8\u5e7c\u5363\u6538\u4f91\u83b8\u5466\u56ff\u5ba5\u67da\u7337\u7256\u94d5\u75a3\u8763\u9c7f\u9edd\u9f2c", "yu": "\u8fc2\u6de4\u4e8e\u76c2\u6986\u865e\u611a\u8206\u4f59\u4fde\u903e\u9c7c\u6109\u6e1d\u6e14\u9685\u4e88\u5a31\u96e8\u4e0e\u5c7f\u79b9\u5b87\u8bed\u7fbd\u7389\u57df\u828b\u90c1\u5401\u9047\u55bb\u5cea\u5fa1\u6108\u6b32\u72f1\u80b2\u8a89\u6d74\u5bd3\u88d5\u9884\u8c6b\u9a6d\u79ba\u6bd3\u4f1b\u4fe3\u8c00\u8c15\u8438\u84e3\u63c4\u5581\u5704\u5709\u5d5b\u72f3\u996b\u5ebe\u9608\u59aa\u59a4\u7ea1\u745c\u6631\u89ce\u8174\u6b24\u65bc\u715c\u71e0\u807f\u94b0\u9e46\u7610\u7600\u7ab3\u8753\u7afd\u8201\u96e9\u9f89", "yuan": "\u9e33\u6e0a\u51a4\u5143\u57a3\u8881\u539f\u63f4\u8f95\u56ed\u5458\u5706\u733f\u6e90\u7f18\u8fdc\u82d1\u613f\u6028\u9662\u586c\u6c85\u5a9b\u7457\u6a7c\u7230\u7722\u9e22\u8788\u9f0b", "yue": "\u66f0\u7ea6\u8d8a\u8dc3\u94a5\u5cb3\u7ca4\u6708\u60a6\u9605\u9fa0\u6a3e\u5216\u94ba", "yun": "\u8018\u4e91\u90e7\u5300\u9668\u5141\u8fd0\u8574\u915d\u6655\u97f5\u5b55\u90d3\u82b8\u72c1\u607d\u7ead\u6b92\u6600\u6c32", "za": "\u531d\u7838\u6742\u62f6\u5482", "zai": "\u683d\u54c9\u707e\u5bb0\u8f7d\u518d\u5728\u54b1\u5d3d\u753e", "zan": "\u6512\u6682\u8d5e\u74d2\u661d\u7c2a\u7ccc\u8db1\u933e", "zang": "\u8d43\u810f\u846c\u5958\u6215\u81e7", "zao": "\u906d\u7cdf\u51ff\u85fb\u67a3\u65e9\u6fa1\u86a4\u8e81\u566a\u9020\u7682\u7076\u71e5\u5523\u7f2b", "ze": "\u8d23\u62e9\u5219\u6cfd\u4ec4\u8d5c\u5567\u8fee\u6603\u7b2e\u7ba6\u8234", "zei": "\u8d3c", "zen": "\u600e\u8c2e", "zeng": "\u589e\u618e\u66fe\u8d60\u7f2f\u7511\u7f7e\u9503", "zha": "\u624e\u55b3\u6e23\u672d\u8f67\u94e1\u95f8\u7728\u6805\u69a8\u548b\u4e4d\u70b8\u8bc8\u63f8\u5412\u54a4\u54f3\u600d\u781f\u75c4\u86b1\u9f44", "zhai": "\u6458\u658b\u5b85\u7a84\u503a\u5be8\u7826", "zhan": "\u77bb\u6be1\u8a79\u7c98\u6cbe\u76cf\u65a9\u8f97\u5d2d\u5c55\u8638\u6808\u5360\u6218\u7ad9\u6e5b\u7efd\u8c35\u640c\u65c3", "zhang": "\u6a1f\u7ae0\u5f70\u6f33\u5f20\u638c\u6da8\u6756\u4e08\u5e10\u8d26\u4ed7\u80c0\u7634\u969c\u4ec9\u9123\u5e5b\u5d82\u7350\u5adc\u748b\u87d1", "zhao": "\u62db\u662d\u627e\u6cbc\u8d75\u7167\u7f69\u5146\u8087\u53ec\u722a\u8bcf\u68f9\u948a\u7b0a", "zhe": "\u906e\u6298\u54f2\u86f0\u8f99\u8005\u9517\u8517\u8fd9\u6d59\u8c2a\u966c\u67d8\u8f84\u78d4\u9e67\u891a\u8707\u8d6d", "zhen": "\u73cd\u659f\u771f\u7504\u7827\u81fb\u8d1e\u9488\u4fa6\u6795\u75b9\u8bca\u9707\u632f\u9547\u9635\u7f1c\u6862\u699b\u8f78\u8d48\u80d7\u6715\u796f\u755b\u9e29", "zheng": "\u84b8\u6323\u7741\u5f81\u72f0\u4e89\u6014\u6574\u62ef\u6b63\u653f\u5e27\u75c7\u90d1\u8bc1\u8be4\u5ce5\u94b2\u94ee\u7b5d", "zhi": "\u829d\u679d\u652f\u5431\u8718\u77e5\u80a2\u8102\u6c41\u4e4b\u7ec7\u804c\u76f4\u690d\u6b96\u6267\u503c\u4f84\u5740\u6307\u6b62\u8dbe\u53ea\u65e8\u7eb8\u5fd7\u631a\u63b7\u81f3\u81f4\u7f6e\u5e1c\u5cd9\u5236\u667a\u79e9\u7a1a\u8d28\u7099\u75d4\u6ede\u6cbb\u7a92\u536e\u965f\u90c5\u57f4\u82b7\u646d\u5e19\u5fee\u5f58\u54ab\u9a98\u6809\u67b3\u6800\u684e\u8f75\u8f7e\u6534\u8d3d\u81a3\u7949\u7957\u9ef9\u96c9\u9e37\u75e3\u86ed\u7d77\u916f\u8dd6\u8e2c\u8e2f\u8c78\u89ef", "zhong": "\u4e2d\u76c5\u5fe0\u949f\u8877\u7ec8\u79cd\u80bf\u91cd\u4ef2\u4f17\u51a2\u953a\u87bd\u8202\u822f\u8e35", "zhou": "\u821f\u5468\u5dde\u6d32\u8bcc\u7ca5\u8f74\u8098\u5e1a\u5492\u76b1\u5b99\u663c\u9aa4\u5544\u7740\u501c\u8bf9\u836e\u9b3b\u7ea3\u80c4\u78a1\u7c40\u8233\u914e\u9cb7", "zhu": "\u73e0\u682a\u86db\u6731\u732a\u8bf8\u8bdb\u9010\u7af9\u70db\u716e\u62c4\u77a9\u5631\u4e3b\u8457\u67f1\u52a9\u86c0\u8d2e\u94f8\u7b51\u4f4f\u6ce8\u795d\u9a7b\u4f2b\u4f8f\u90be\u82ce\u8331\u6d19\u6e1a\u6f74\u9a7a\u677c\u69e0\u6a65\u70b7\u94e2\u75b0\u7603\u86b0\u7afa\u7bb8\u7fe5\u8e85\u9e88", "zhua": "\u6293", "zhuai": "\u62fd", "zhuan": "\u4e13\u7816\u8f6c\u64b0\u8d5a\u7bc6\u629f\u556d\u989b", "zhuang": "\u6869\u5e84\u88c5\u5986\u649e\u58ee\u72b6\u4e2c", "zhui": "\u690e\u9525\u8ffd\u8d58\u5760\u7f00\u8411\u9a93\u7f12", "zhun": "\u8c06\u51c6", "zhuo": "\u6349\u62d9\u5353\u684c\u7422\u8301\u914c\u707c\u6d4a\u502c\u8bfc\u5ef4\u855e\u64e2\u555c\u6d5e\u6dbf\u6753\u712f\u799a\u65ab", "zi": "\u5179\u54a8\u8d44\u59ff\u6ecb\u6dc4\u5b5c\u7d2b\u4ed4\u7c7d\u6ed3\u5b50\u81ea\u6e0d\u5b57\u8c18\u5d6b\u59ca\u5b73\u7f01\u6893\u8f8e\u8d40\u6063\u7726\u9531\u79ed\u8014\u7b2b\u7ca2\u89dc\u8a3e\u9cbb\u9aed", "zong": "\u9b03\u68d5\u8e2a\u5b97\u7efc\u603b\u7eb5\u8159\u7cbd", "zou": "\u90b9\u8d70\u594f\u63cd\u9139\u9cb0", "zu": "\u79df\u8db3\u5352\u65cf\u7956\u8bc5\u963b\u7ec4\u4fce\u83f9\u5550\u5f82\u9a75\u8e74", "zuan": "\u94bb\u7e82\u6525\u7f35", "zui": "\u5634\u9189\u6700\u7f6a", "zun": "\u5c0a\u9075\u6499\u6a3d\u9cdf", "zuo": "\u6628\u5de6\u4f50\u67de\u505a\u4f5c\u5750\u5ea7\u961d\u963c\u80d9\u795a\u9162", "cou": "\u85ae\u6971\u8f8f\u8160", "nang": "\u652e\u54dd\u56d4\u9995\u66e9", "o": "\u5594", "dia": "\u55f2", "chuai": "\u562c\u81aa\u8e39", "cen": "\u5c91\u6d94", "diu": "\u94e5", "nou": "\u8028", "fou": "\u7f36", "bia": "\u9adf" }; + this.polyphone = { "19969": "DZ", "19975": "WM", "19988": "QJ", "20048": "YL", "20056": "SC", "20060": "NM", "20094": "QG", "20127": "QJ", "20167": "QC", "20193": "YG", "20250": "KH", "20256": "ZC", "20282": "SC", "20285": "QJG", "20291": "TD", "20314": "YD", "20340": "NE", "20375": "TD", "20389": "YJ", "20391": "CZ", "20415": "PB", "20446": "YS", "20447": "SQ", "20504": "TC", "20608": "KG", "20854": "QJ", "20857": "ZC", "20911": "PF", "20504": "TC", "20608": "KG", "20854": "QJ", "20857": "ZC", "20911": "PF", "20985": "AW", "21032": "PB", "21048": "XQ", "21049": "SC", "21089": "YS", "21119": "JC", "21242": "SB", "21273": "SC", "21305": "YP", "21306": "QO", "21330": "ZC", "21333": "SDC", "21345": "QK", "21378": "CA", "21397": "SC", "21414": "XS", "21442": "SC", "21477": "JG", "21480": "TD", "21484": "ZS", "21494": "YX", "21505": "YX", "21512": "HG", "21523": "XH", "21537": "PB", "21542": "PF", "21549": "KH", "21571": "E", "21574": "DA", "21588": "TD", "21589": "O", "21618": "ZC", "21621": "KHA", "21632": "ZJ", "21654": "KG", "21679": "LKG", "21683": "KH", "21710": "A", "21719": "YH", "21734": "WOE", "21769": "A", "21780": "WN", "21804": "XH", "21834": "A", "21899": "ZD", "21903": "RN", "21908": "WO", "21939": "ZC", "21956": "SA", "21964": "YA", "21970": "TD", "22003": "A", "22031": "JG", "22040": "XS", "22060": "ZC", "22066": "ZC", "22079": "MH", "22129": "XJ", "22179": "XA", "22237": "NJ", "22244": "TD", "22280": "JQ", "22300": "YH", "22313": "XW", "22331": "YQ", "22343": "YJ", "22351": "PH", "22395": "DC", "22412": "TD", "22484": "PB", "22500": "PB", "22534": "ZD", "22549": "DH", "22561": "PB", "22612": "TD", "22771": "KQ", "22831": "HB", "22841": "JG", "22855": "QJ", "22865": "XQ", "23013": "ML", "23081": "WM", "23487": "SX", "23558": "QJ", "23561": "YW", "23586": "YW", "23614": "YW", "23615": "SN", "23631": "PB", "23646": "ZS", "23663": "ZT", "23673": "YG", "23762": "TD", "23769": "ZS", "23780": "QJ", "23884": "QK", "24055": "XH", "24113": "DC", "24162": "ZC", "24191": "GA", "24273": "QJ", "24324": "NL", "24377": "TD", "24378": "QJ", "24439": "PF", "24554": "ZS", "24683": "TD", "24694": "WE", "24733": "LK", "24925": "TN", "25094": "ZG", "25100": "XQ", "25103": "XH", "25153": "PB", "25170": "PB", "25179": "KG", "25203": "PB", "25240": "ZS", "25282": "FB", "25303": "NA", "25324": "KG", "25341": "ZY", "25373": "WZ", "25375": "XJ", "25384": "A", "25457": "A", "25528": "SD", "25530": "SC", "25552": "TD", "25774": "ZC", "25874": "ZC", "26044": "YW", "26080": "WM", "26292": "PB", "26333": "PB", "26355": "ZY", "26366": "CZ", "26397": "ZC", "26399": "QJ", "26415": "ZS", "26451": "SB", "26526": "ZC", "26552": "JG", "26561": "TD", "26588": "JG", "26597": "CZ", "26629": "ZS", "26638": "YL", "26646": "XQ", "26653": "KG", "26657": "XJ", "26727": "HG", "26894": "ZC", "26937": "ZS", "26946": "ZC", "26999": "KJ", "27099": "KJ", "27449": "YQ", "27481": "XS", "27542": "ZS", "27663": "ZS", "27748": "TS", "27784": "SC", "27788": "ZD", "27795": "TD", "27812": "O", "27850": "PB", "27852": "MB", "27895": "SL", "27898": "PL", "27973": "QJ", "27981": "KH", "27986": "HX", "27994": "XJ", "28044": "YC", "28065": "WG", "28177": "SM", "28267": "QJ", "28291": "KH", "28337": "ZQ", "28463": "TL", "28548": "DC", "28601": "TD", "28689": "PB", "28805": "JG", "28820": "QG", "28846": "PB", "28952": "TD", "28975": "ZC", "29100": "A", "29325": "QJ", "29575": "SL", "29602": "FB", "30010": "TD", "30044": "CX", "30058": "PF", "30091": "YSP", "30111": "YN", "30229": "XJ", "30427": "SC", "30465": "SX", "30631": "YQ", "30655": "QJ", "30684": "QJG", "30707": "SD", "30729": "XH", "30796": "LG", "30917": "PB", "31074": "NM", "31085": "JZ", "31109": "SC", "31181": "ZC", "31192": "MLB", "31293": "JQ", "31400": "YX", "31584": "YJ", "31896": "ZN", "31909": "ZY", "31995": "XJ", "32321": "PF", "32327": "ZY", "32418": "HG", "32420": "XQ", "32421": "HG", "32438": "LG", "32473": "GJ", "32488": "TD", "32521": "QJ", "32527": "PB", "32562": "ZSQ", "32564": "JZ", "32735": "ZD", "32793": "PB", "33071": "PF", "33098": "XL", "33100": "YA", "33152": "PB", "33261": "CX", "33324": "BP", "33333": "TD", "33406": "YA", "33426": "WM", "33432": "PB", "33445": "JG", "33486": "ZN", "33493": "TS", "33507": "QJ", "33540": "QJ", "33544": "ZC", "33564": "XQ", "33617": "YT", "33632": "QJ", "33636": "XH", "33637": "YX", "33694": "WG", "33705": "PF", "33728": "YW", "33882": "SR", "34067": "WM", "34074": "YW", "34121": "QJ", "34255": "ZC", "34259": "XL", "34425": "JH", "34430": "XH", "34485": "KH", "34503": "YS", "34532": "HG", "34552": "XS", "34558": "YE", "34593": "ZL", "34660": "YQ", "34892": "XH", "34928": "SC", "34999": "QJ", "35048": "PB", "35059": "SC", "35098": "ZC", "35203": "TQ", "35265": "JX", "35299": "JX", "35782": "SZ", "35828": "YS", "35830": "E", "35843": "TD", "35895": "YG", "35977": "MH", "36158": "JG", "36228": "QJ", "36426": "XQ", "36466": "DC", "36710": "JC", "36711": "ZYG", "36767": "PB", "36866": "SK", "36951": "YW", "37034": "YX", "37063": "XH", "37218": "ZC", "37325": "ZC", "38063": "PB", "38079": "TD", "38085": "QY", "38107": "DC", "38116": "TD", "38123": "YD", "38224": "HG", "38241": "XTC", "38271": "ZC", "38415": "YE", "38426": "KH", "38461": "YD", "38463": "AE", "38466": "PB", "38477": "XJ", "38518": "YT", "38551": "WK", "38585": "ZC", "38704": "XS", "38739": "LJ", "38761": "GJ", "38808": "SQ", "39048": "JG", "39049": "XJ", "39052": "HG", "39076": "CZ", "39271": "XT", "39534": "TD", "39552": "TD", "39584": "PB", "39647": "SB", "39730": "LG", "39748": "TPB", "40109": "ZQ", "40479": "ND", "40516": "HG", "40536": "HG", "40583": "QJ", "40765": "YQ", "40784": "QJ", "40840": "YK", "40863": "QJG" }; + this.options = { + checkPolyphone: false, + charcase: 'default' + }; + this.getCamelChars = function(str) { + if (typeof (str) != "string") + throw new Error(-1, "函数getFisrt需要字符串类型参数!"); + var chars = new Array(); //保存中间结果的数组 + for (var i = 0, len = str.length; i < len; i++) { + //获得unicode码 + var ch = str.charAt(i); + //检查该unicode码是否在处理范围之内,在则返回该码对映汉字的拼音首字母,不在则调用其它函数处理 + chars.push(this._getChar(ch)); + } + //处理arrResult,返回所有可能的拼音首字母串数组 + return this._getResult(chars); + }; + + this.getFullChars = function(str) { + var len = str.length; + var result = ""; + var reg = new RegExp('[a-zA-Z0-9\- ]'); + for (var i = 0; i < len; i++) { + var ch = str.substr(i, 1); + var unicode = ch.charCodeAt(0); + //如果不在汉字处理范围之内,返回原字符,也可以调用自己的处理函数 + if (unicode > 40869 || unicode < 19968) { + result += ch; + } else { + var name = this._getFullChar(ch); + if (name !== false) { + result += name; + } + } + } + return result; + }; + + this.getFullHeadChars = function(str) { + var len = str.length; + var result = ""; + var reg = new RegExp('[a-zA-Z0-9\- ]'); + for (var i = 0; i < len; i++) { + var ch = str.substr(i, 1); + var unicode = ch.charCodeAt(0); + //如果不在汉字处理范围之内,返回原字符,也可以调用自己的处理函数 + if (unicode > 40869 || unicode < 19968) { + result += ch; + } else { + var name = this._getFullChar(ch); + if (name !== false) { + result += name.substr(0,1); + } + } + } + return result; + }; + + + + this._getFullChar = function(str) { + for (var key in this.full_dict) { + if (this.full_dict[key].indexOf(str) != -1) { + return this._capitalize(key); + break; + } + } + return false; + }; + // 首字母大写 + this._capitalize = function(str) { + if (str.length > 0) { + var first = str.substr(0, 1).toUpperCase(); + var spare = str.substr(1, str.length); + return first + spare; + } + }; + + this._getChar = function(ch) { + var unicode = ch.charCodeAt(0); + //如果不在汉字处理范围之内,返回原字符,也可以调用自己的处理函数 + if (unicode > 40869 || unicode < 19968) + return ch; //dealWithOthers(ch); + //检查是否是多音字,是按多音字处理,不是就直接在strChineseFirstPY字符串中找对应的首字母 + if (!this.options.checkPolyphone) + return this.char_dict.charAt(unicode - 19968); + return this.polyphone[unicode] ? this.polyphone[unicode] : this.char_dict.charAt(unicode - 19968); + }; + + this._getResult = function(chars) { + if (!this.options.checkPolyphone) + return chars.join(''); + var result = ['']; + for (var i = 0, len = chars.length; i < len; i++) { + var str = chars[i]; + var strlen = str.length; + if (strlen == 1) { + for (var j = 0; j < result.length; j++) { + result[k] += str; + } + } else { + var swap1 = result.slice(0); + result = []; + for (var j = 0; j < strlen; j++) { + //复制一个相同的arrRslt + var swap2 = swap1.slice(0); + //把当前字符str[k]添加到每个元素末尾 + for (var k = 0; k < swap2.length; k++) { + swap2[k] += str.charAt(j); + } + //把复制并修改后的数组连接到arrRslt上 + result = result.concat(swap2); + } + } + } + return result; + }; + + return this; +} + +export default Pinyin; \ No newline at end of file diff --git a/super-screen/client/src/utils/region.js b/super-screen/client/src/utils/region.js new file mode 100644 index 0000000..c7b6df6 --- /dev/null +++ b/super-screen/client/src/utils/region.js @@ -0,0 +1,13961 @@ +/** + * Created by yuanfenghua on 2016/5/23. + */ +'use strict' + +const RegionTree = [ + { + "value": 1, + "label": "北京市", + "children": [ + { + "value": 2, + "label": "东城区" + }, + { + "value": 3, + "label": "西城区" + }, + { + "value": 4, + "label": "朝阳区" + }, + { + "value": 5, + "label": "丰台区" + }, + { + "value": 6, + "label": "石景山区" + }, + { + "value": 7, + "label": "海淀区" + }, + { + "value": 8, + "label": "门头沟区" + }, + { + "value": 9, + "label": "房山区" + }, + { + "value": 10, + "label": "通州区" + }, + { + "value": 11, + "label": "顺义区" + }, + { + "value": 12, + "label": "昌平区" + }, + { + "value": 13, + "label": "大兴区" + }, + { + "value": 14, + "label": "怀柔区" + }, + { + "value": 15, + "label": "平谷区" + }, + { + "value": 16, + "label": "密云县" + }, + { + "value": 17, + "label": "延庆县" + } + ] + }, + { + "value": 18, + "label": "天津市", + "children": [ + { + "value": 19, + "label": "和平区" + }, + { + "value": 20, + "label": "河东区" + }, + { + "value": 21, + "label": "河西区" + }, + { + "value": 22, + "label": "南开区" + }, + { + "value": 23, + "label": "河北区" + }, + { + "value": 24, + "label": "红桥区" + }, + { + "value": 25, + "label": "东丽区" + }, + { + "value": 26, + "label": "西青区" + }, + { + "value": 27, + "label": "津南区" + }, + { + "value": 28, + "label": "北辰区" + }, + { + "value": 29, + "label": "武清区" + }, + { + "value": 30, + "label": "宝坻区" + }, + { + "value": 31, + "label": "滨海新区" + }, + { + "value": 32, + "label": "宁河县" + }, + { + "value": 33, + "label": "静海县" + }, + { + "value": 34, + "label": "蓟县" + } + ] + }, + { + "value": 35, + "label": "河北省", + "children": [ + { + "value": 36, + "label": "石家庄市", + "children": [ + { + "value": 37, + "label": "长安区" + }, + { + "value": 38, + "label": "桥东区" + }, + { + "value": 39, + "label": "桥西区" + }, + { + "value": 40, + "label": "新华区" + }, + { + "value": 41, + "label": "井陉矿区" + }, + { + "value": 42, + "label": "裕华区" + }, + { + "value": 55, + "label": "辛集市" + }, + { + "value": 56, + "label": "藁城市" + }, + { + "value": 57, + "label": "晋州市" + }, + { + "value": 58, + "label": "新乐市" + }, + { + "value": 59, + "label": "鹿泉市" + }, + { + "value": 49, + "label": "深泽县" + }, + { + "value": 50, + "label": "赞皇县" + }, + { + "value": 51, + "label": "无极县" + }, + { + "value": 52, + "label": "平山县" + }, + { + "value": 53, + "label": "元氏县" + }, + { + "value": 54, + "label": "赵县" + }, + { + "value": 43, + "label": "井陉县" + }, + { + "value": 44, + "label": "正定县" + }, + { + "value": 45, + "label": "栾城县" + }, + { + "value": 46, + "label": "行唐县" + }, + { + "value": 47, + "label": "灵寿县" + }, + { + "value": 48, + "label": "高邑县" + } + ] + }, + { + "value": 60, + "label": "唐山市", + "children": [ + { + "value": 61, + "label": "路南区" + }, + { + "value": 62, + "label": "路北区" + }, + { + "value": 63, + "label": "古冶区" + }, + { + "value": 64, + "label": "开平区" + }, + { + "value": 65, + "label": "丰南区" + }, + { + "value": 66, + "label": "丰润区" + }, + { + "value": 73, + "label": "遵化市" + }, + { + "value": 74, + "label": "迁安市" + }, + { + "value": 67, + "label": "滦县" + }, + { + "value": 68, + "label": "滦南县" + }, + { + "value": 69, + "label": "乐亭县" + }, + { + "value": 70, + "label": "迁西县" + }, + { + "value": 71, + "label": "玉田县" + }, + { + "value": 72, + "label": "唐海县" + } + ] + }, + { + "value": 75, + "label": "秦皇岛市", + "children": [ + { + "value": 76, + "label": "海港区" + }, + { + "value": 77, + "label": "山海关区" + }, + { + "value": 78, + "label": "北戴河区" + }, + { + "value": 79, + "label": "青龙满族自治县" + }, + { + "value": 80, + "label": "昌黎县" + }, + { + "value": 81, + "label": "抚宁县" + }, + { + "value": 82, + "label": "卢龙县" + } + ] + }, + { + "value": 83, + "label": "邯郸市", + "children": [ + { + "value": 84, + "label": "邯山区" + }, + { + "value": 85, + "label": "丛台区" + }, + { + "value": 86, + "label": "复兴区" + }, + { + "value": 87, + "label": "峰峰矿区" + }, + { + "value": 88, + "label": "邯郸县" + }, + { + "value": 89, + "label": "临漳县" + }, + { + "value": 102, + "label": "武安市" + }, + { + "value": 96, + "label": "邱县" + }, + { + "value": 97, + "label": "鸡泽县" + }, + { + "value": 98, + "label": "广平县" + }, + { + "value": 99, + "label": "馆陶县" + }, + { + "value": 100, + "label": "魏县" + }, + { + "value": 101, + "label": "曲周县" + }, + { + "value": 90, + "label": "成安县" + }, + { + "value": 91, + "label": "大名县" + }, + { + "value": 92, + "label": "涉县" + }, + { + "value": 93, + "label": "磁县" + }, + { + "value": 94, + "label": "肥乡县" + }, + { + "value": 95, + "label": "永年县" + } + ] + }, + { + "value": 103, + "label": "邢台市", + "children": [ + { + "value": 104, + "label": "桥东区" + }, + { + "value": 105, + "label": "桥西区" + }, + { + "value": 106, + "label": "邢台县" + }, + { + "value": 107, + "label": "临城县" + }, + { + "value": 108, + "label": "内丘县" + }, + { + "value": 109, + "label": "柏乡县" + }, + { + "value": 122, + "label": "沙河市" + }, + { + "value": 116, + "label": "广宗县" + }, + { + "value": 117, + "label": "平乡县" + }, + { + "value": 118, + "label": "威县" + }, + { + "value": 119, + "label": "清河县" + }, + { + "value": 120, + "label": "临西县" + }, + { + "value": 121, + "label": "南宫市" + }, + { + "value": 110, + "label": "隆尧县" + }, + { + "value": 111, + "label": "任县" + }, + { + "value": 112, + "label": "南和县" + }, + { + "value": 113, + "label": "宁晋县" + }, + { + "value": 114, + "label": "巨鹿县" + }, + { + "value": 115, + "label": "新河县" + } + ] + }, + { + "value": 123, + "label": "保定市", + "children": [ + { + "value": 124, + "label": "新市区" + }, + { + "value": 125, + "label": "北市区" + }, + { + "value": 126, + "label": "南市区" + }, + { + "value": 127, + "label": "满城县" + }, + { + "value": 128, + "label": "清苑县" + }, + { + "value": 129, + "label": "涞水县" + }, + { + "value": 148, + "label": "高碑店市" + }, + { + "value": 142, + "label": "顺平县" + }, + { + "value": 143, + "label": "博野县" + }, + { + "value": 144, + "label": "雄县" + }, + { + "value": 145, + "label": "涿州市" + }, + { + "value": 146, + "label": "定州市" + }, + { + "value": 147, + "label": "安国市" + }, + { + "value": 136, + "label": "涞源县" + }, + { + "value": 137, + "label": "望都县" + }, + { + "value": 138, + "label": "安新县" + }, + { + "value": 139, + "label": "易县" + }, + { + "value": 140, + "label": "曲阳县" + }, + { + "value": 141, + "label": "蠡县" + }, + { + "value": 130, + "label": "阜平县" + }, + { + "value": 131, + "label": "徐水县" + }, + { + "value": 132, + "label": "定兴县" + }, + { + "value": 133, + "label": "唐县" + }, + { + "value": 134, + "label": "高阳县" + }, + { + "value": 135, + "label": "容城县" + } + ] + }, + { + "value": 149, + "label": "张家口市", + "children": [ + { + "value": 150, + "label": "桥东区" + }, + { + "value": 151, + "label": "桥西区" + }, + { + "value": 152, + "label": "宣化区" + }, + { + "value": 153, + "label": "下花园区" + }, + { + "value": 154, + "label": "宣化县" + }, + { + "value": 155, + "label": "张北县" + }, + { + "value": 162, + "label": "万全县" + }, + { + "value": 163, + "label": "怀来县" + }, + { + "value": 164, + "label": "涿鹿县" + }, + { + "value": 165, + "label": "赤城县" + }, + { + "value": 166, + "label": "崇礼县" + }, + { + "value": 156, + "label": "康保县" + }, + { + "value": 157, + "label": "沽源县" + }, + { + "value": 158, + "label": "尚义县" + }, + { + "value": 159, + "label": "蔚县" + }, + { + "value": 160, + "label": "阳原县" + }, + { + "value": 161, + "label": "怀安县" + } + ] + }, + { + "value": 167, + "label": "承德市", + "children": [ + { + "value": 168, + "label": "双桥区" + }, + { + "value": 169, + "label": "双滦区" + }, + { + "value": 170, + "label": "鹰手营子矿区" + }, + { + "value": 171, + "label": "承德县" + }, + { + "value": 172, + "label": "兴隆县" + }, + { + "value": 173, + "label": "平泉县" + }, + { + "value": 174, + "label": "滦平县" + }, + { + "value": 175, + "label": "隆化县" + }, + { + "value": 176, + "label": "丰宁满族自治县" + }, + { + "value": 177, + "label": "宽城满族自治县" + }, + { + "value": 178, + "label": "围场满族蒙古族自治县" + } + ] + }, + { + "value": 179, + "label": "沧州市", + "children": [ + { + "value": 180, + "label": "新华区" + }, + { + "value": 181, + "label": "运河区" + }, + { + "value": 182, + "label": "沧县" + }, + { + "value": 183, + "label": "青县" + }, + { + "value": 184, + "label": "东光县" + }, + { + "value": 185, + "label": "海兴县" + }, + { + "value": 192, + "label": "泊头市" + }, + { + "value": 193, + "label": "任丘市" + }, + { + "value": 194, + "label": "黄骅市" + }, + { + "value": 195, + "label": "河间市" + }, + { + "value": 186, + "label": "盐山县" + }, + { + "value": 187, + "label": "肃宁县" + }, + { + "value": 188, + "label": "南皮县" + }, + { + "value": 189, + "label": "吴桥县" + }, + { + "value": 190, + "label": "献县" + }, + { + "value": 191, + "label": "孟村回族自治县" + } + ] + }, + { + "value": 196, + "label": "廊坊市", + "children": [ + { + "value": 197, + "label": "安次区" + }, + { + "value": 198, + "label": "广阳区" + }, + { + "value": 199, + "label": "固安县" + }, + { + "value": 200, + "label": "永清县" + }, + { + "value": 201, + "label": "香河县" + }, + { + "value": 202, + "label": "大城县" + }, + { + "value": 203, + "label": "文安县" + }, + { + "value": 204, + "label": "大厂回族自治县" + }, + { + "value": 205, + "label": "霸州市" + }, + { + "value": 206, + "label": "三河市" + } + ] + }, + { + "value": 207, + "label": "衡水市", + "children": [ + { + "value": 208, + "label": "桃城区" + }, + { + "value": 209, + "label": "枣强县" + }, + { + "value": 210, + "label": "武邑县" + }, + { + "value": 211, + "label": "武强县" + }, + { + "value": 212, + "label": "饶阳县" + }, + { + "value": 213, + "label": "安平县" + }, + { + "value": 214, + "label": "故城县" + }, + { + "value": 215, + "label": "景县" + }, + { + "value": 216, + "label": "阜城县" + }, + { + "value": 217, + "label": "冀州市" + }, + { + "value": 218, + "label": "深州市" + } + ] + } + ] + }, + { + "value": 219, + "label": "山西省", + "children": [ + { + "value": 220, + "label": "太原市", + "children": [ + { + "value": 221, + "label": "小店区" + }, + { + "value": 222, + "label": "迎泽区" + }, + { + "value": 223, + "label": "杏花岭区" + }, + { + "value": 224, + "label": "尖草坪区" + }, + { + "value": 225, + "label": "万柏林区" + }, + { + "value": 226, + "label": "晋源区" + }, + { + "value": 227, + "label": "清徐县" + }, + { + "value": 228, + "label": "阳曲县" + }, + { + "value": 229, + "label": "娄烦县" + }, + { + "value": 230, + "label": "古交市" + } + ] + }, + { + "value": 231, + "label": "大同市", + "children": [ + { + "value": 232, + "label": "城区" + }, + { + "value": 233, + "label": "矿区" + }, + { + "value": 234, + "label": "南郊区" + }, + { + "value": 235, + "label": "新荣区" + }, + { + "value": 236, + "label": "阳高县" + }, + { + "value": 237, + "label": "天镇县" + }, + { + "value": 238, + "label": "广灵县" + }, + { + "value": 239, + "label": "灵丘县" + }, + { + "value": 240, + "label": "浑源县" + }, + { + "value": 241, + "label": "左云县" + }, + { + "value": 242, + "label": "大同县" + } + ] + }, + { + "value": 243, + "label": "阳泉市", + "children": [ + { + "value": 244, + "label": "城区" + }, + { + "value": 245, + "label": "矿区" + }, + { + "value": 246, + "label": "郊区" + }, + { + "value": 247, + "label": "平定县" + }, + { + "value": 248, + "label": "盂县" + } + ] + }, + { + "value": 249, + "label": "长治市", + "children": [ + { + "value": 250, + "label": "城区" + }, + { + "value": 251, + "label": "郊区" + }, + { + "value": 252, + "label": "长治县" + }, + { + "value": 253, + "label": "襄垣县" + }, + { + "value": 254, + "label": "屯留县" + }, + { + "value": 255, + "label": "平顺县" + }, + { + "value": 262, + "label": "潞城市" + }, + { + "value": 256, + "label": "黎城县" + }, + { + "value": 257, + "label": "壶关县" + }, + { + "value": 258, + "label": "长子县" + }, + { + "value": 259, + "label": "武乡县" + }, + { + "value": 260, + "label": "沁县" + }, + { + "value": 261, + "label": "沁源县" + } + ] + }, + { + "value": 263, + "label": "晋城市", + "children": [ + { + "value": 264, + "label": "城区" + }, + { + "value": 265, + "label": "沁水县" + }, + { + "value": 266, + "label": "阳城县" + }, + { + "value": 267, + "label": "陵川县" + }, + { + "value": 268, + "label": "泽州县" + }, + { + "value": 269, + "label": "高平市" + } + ] + }, + { + "value": 270, + "label": "朔州市", + "children": [ + { + "value": 271, + "label": "朔城区" + }, + { + "value": 272, + "label": "平鲁区" + }, + { + "value": 273, + "label": "山阴县" + }, + { + "value": 274, + "label": "应县" + }, + { + "value": 275, + "label": "右玉县" + }, + { + "value": 276, + "label": "怀仁县" + } + ] + }, + { + "value": 277, + "label": "晋中市", + "children": [ + { + "value": 278, + "label": "榆次区" + }, + { + "value": 279, + "label": "榆社县" + }, + { + "value": 280, + "label": "左权县" + }, + { + "value": 281, + "label": "和顺县" + }, + { + "value": 282, + "label": "昔阳县" + }, + { + "value": 283, + "label": "寿阳县" + }, + { + "value": 284, + "label": "太谷县" + }, + { + "value": 285, + "label": "祁县" + }, + { + "value": 286, + "label": "平遥县" + }, + { + "value": 287, + "label": "灵石县" + }, + { + "value": 288, + "label": "介休市" + } + ] + }, + { + "value": 289, + "label": "运城市", + "children": [ + { + "value": 290, + "label": "盐湖区" + }, + { + "value": 291, + "label": "临猗县" + }, + { + "value": 292, + "label": "万荣县" + }, + { + "value": 293, + "label": "闻喜县" + }, + { + "value": 294, + "label": "稷山县" + }, + { + "value": 295, + "label": "新绛县" + }, + { + "value": 302, + "label": "河津市" + }, + { + "value": 296, + "label": "绛县" + }, + { + "value": 297, + "label": "垣曲县" + }, + { + "value": 298, + "label": "夏县" + }, + { + "value": 299, + "label": "平陆县" + }, + { + "value": 300, + "label": "芮城县" + }, + { + "value": 301, + "label": "永济市" + } + ] + }, + { + "value": 303, + "label": "忻州市", + "children": [ + { + "value": 304, + "label": "忻府区" + }, + { + "value": 305, + "label": "定襄县" + }, + { + "value": 306, + "label": "五台县" + }, + { + "value": 307, + "label": "代县" + }, + { + "value": 308, + "label": "繁峙县" + }, + { + "value": 309, + "label": "宁武县" + }, + { + "value": 316, + "label": "偏关县" + }, + { + "value": 317, + "label": "原平市" + }, + { + "value": 310, + "label": "静乐县" + }, + { + "value": 311, + "label": "神池县" + }, + { + "value": 312, + "label": "五寨县" + }, + { + "value": 313, + "label": "岢岚县" + }, + { + "value": 314, + "label": "河曲县" + }, + { + "value": 315, + "label": "保德县" + } + ] + }, + { + "value": 318, + "label": "临汾市", + "children": [ + { + "value": 319, + "label": "尧都区" + }, + { + "value": 320, + "label": "曲沃县" + }, + { + "value": 321, + "label": "翼城县" + }, + { + "value": 322, + "label": "襄汾县" + }, + { + "value": 323, + "label": "洪洞县" + }, + { + "value": 324, + "label": "古县" + }, + { + "value": 331, + "label": "永和县" + }, + { + "value": 332, + "label": "蒲县" + }, + { + "value": 333, + "label": "汾西县" + }, + { + "value": 334, + "label": "侯马市" + }, + { + "value": 335, + "label": "霍州市" + }, + { + "value": 325, + "label": "安泽县" + }, + { + "value": 326, + "label": "浮山县" + }, + { + "value": 327, + "label": "吉县" + }, + { + "value": 328, + "label": "乡宁县" + }, + { + "value": 329, + "label": "大宁县" + }, + { + "value": 330, + "label": "隰县" + } + ] + }, + { + "value": 336, + "label": "吕梁市", + "children": [ + { + "value": 337, + "label": "离石区" + }, + { + "value": 338, + "label": "文水县" + }, + { + "value": 339, + "label": "交城县" + }, + { + "value": 340, + "label": "兴县" + }, + { + "value": 341, + "label": "临县" + }, + { + "value": 342, + "label": "柳林县" + }, + { + "value": 349, + "label": "汾阳市" + }, + { + "value": 343, + "label": "石楼县" + }, + { + "value": 344, + "label": "岚县" + }, + { + "value": 345, + "label": "方山县" + }, + { + "value": 346, + "label": "中阳县" + }, + { + "value": 347, + "label": "交口县" + }, + { + "value": 348, + "label": "孝义市" + } + ] + } + ] + }, + { + "value": 350, + "label": "内蒙古自治区", + "children": [ + { + "value": 351, + "label": "呼和浩特市", + "children": [ + { + "value": 352, + "label": "新城区" + }, + { + "value": 353, + "label": "回民区" + }, + { + "value": 354, + "label": "玉泉区" + }, + { + "value": 355, + "label": "赛罕区" + }, + { + "value": 356, + "label": "土默特左旗" + }, + { + "value": 357, + "label": "托克托县" + }, + { + "value": 358, + "label": "和林格尔县" + }, + { + "value": 359, + "label": "清水河县" + }, + { + "value": 360, + "label": "武川县" + } + ] + }, + { + "value": 361, + "label": "包头市", + "children": [ + { + "value": 362, + "label": "东河区" + }, + { + "value": 363, + "label": "昆都仑区" + }, + { + "value": 364, + "label": "青山区" + }, + { + "value": 365, + "label": "石拐区" + }, + { + "value": 366, + "label": "白云鄂博矿区" + }, + { + "value": 367, + "label": "九原区" + }, + { + "value": 368, + "label": "土默特右旗" + }, + { + "value": 369, + "label": "固阳县" + }, + { + "value": 370, + "label": "达尔罕茂明安联合旗" + } + ] + }, + { + "value": 371, + "label": "乌海市", + "children": [ + { + "value": 372, + "label": "海勃湾区" + }, + { + "value": 373, + "label": "海南区" + }, + { + "value": 374, + "label": "乌达区" + } + ] + }, + { + "value": 375, + "label": "赤峰市", + "children": [ + { + "value": 376, + "label": "红山区" + }, + { + "value": 377, + "label": "元宝山区" + }, + { + "value": 378, + "label": "松山区" + }, + { + "value": 379, + "label": "阿鲁科尔沁旗" + }, + { + "value": 380, + "label": "巴林左旗" + }, + { + "value": 381, + "label": "巴林右旗" + }, + { + "value": 382, + "label": "林西县" + }, + { + "value": 383, + "label": "克什克腾旗" + }, + { + "value": 384, + "label": "翁牛特旗" + }, + { + "value": 385, + "label": "喀喇沁旗" + }, + { + "value": 386, + "label": "宁城县" + }, + { + "value": 387, + "label": "敖汉旗" + } + ] + }, + { + "value": 388, + "label": "通辽市", + "children": [ + { + "value": 392, + "label": "开鲁县" + }, + { + "value": 393, + "label": "库伦旗" + }, + { + "value": 394, + "label": "奈曼旗" + }, + { + "value": 395, + "label": "扎鲁特旗" + }, + { + "value": 396, + "label": "霍林郭勒市" + }, + { + "value": 389, + "label": "科尔沁区" + }, + { + "value": 390, + "label": "科尔沁左翼中旗" + }, + { + "value": 391, + "label": "科尔沁左翼后旗" + } + ] + }, + { + "value": 397, + "label": "鄂尔多斯市", + "children": [ + { + "value": 398, + "label": "东胜区" + }, + { + "value": 399, + "label": "达拉特旗" + }, + { + "value": 400, + "label": "准格尔旗" + }, + { + "value": 401, + "label": "鄂托克前旗" + }, + { + "value": 402, + "label": "鄂托克旗" + }, + { + "value": 403, + "label": "杭锦旗" + }, + { + "value": 404, + "label": "乌审旗" + }, + { + "value": 405, + "label": "伊金霍洛旗" + } + ] + }, + { + "value": 406, + "label": "呼伦贝尔市", + "children": [ + { + "value": 407, + "label": "海拉尔区" + }, + { + "value": 408, + "label": "阿荣旗" + }, + { + "value": 409, + "label": "莫力达瓦达斡尔族自治旗" + }, + { + "value": 410, + "label": "鄂伦春自治旗" + }, + { + "value": 411, + "label": "鄂温克族自治旗" + }, + { + "value": 412, + "label": "陈巴尔虎旗" + }, + { + "value": 419, + "label": "根河市" + }, + { + "value": 413, + "label": "新巴尔虎左旗" + }, + { + "value": 414, + "label": "新巴尔虎右旗" + }, + { + "value": 415, + "label": "满洲里市" + }, + { + "value": 416, + "label": "牙克石市" + }, + { + "value": 417, + "label": "扎兰屯市" + }, + { + "value": 418, + "label": "额尔古纳市" + } + ] + }, + { + "value": 420, + "label": "巴彦淖尔市", + "children": [ + { + "value": 421, + "label": "临河区" + }, + { + "value": 422, + "label": "五原县" + }, + { + "value": 423, + "label": "磴口县" + }, + { + "value": 424, + "label": "乌拉特前旗" + }, + { + "value": 425, + "label": "乌拉特中旗" + }, + { + "value": 426, + "label": "乌拉特后旗" + }, + { + "value": 427, + "label": "杭锦后旗" + } + ] + }, + { + "value": 428, + "label": "乌兰察布市", + "children": [ + { + "value": 429, + "label": "集宁区" + }, + { + "value": 430, + "label": "卓资县" + }, + { + "value": 431, + "label": "化德县" + }, + { + "value": 432, + "label": "商都县" + }, + { + "value": 433, + "label": "兴和县" + }, + { + "value": 434, + "label": "凉城县" + }, + { + "value": 435, + "label": "察哈尔右翼前旗" + }, + { + "value": 436, + "label": "察哈尔右翼中旗" + }, + { + "value": 437, + "label": "察哈尔右翼后旗" + }, + { + "value": 438, + "label": "四子王旗" + }, + { + "value": 439, + "label": "丰镇市" + } + ] + }, + { + "value": 440, + "label": "兴安盟", + "children": [ + { + "value": 441, + "label": "乌兰浩特市" + }, + { + "value": 442, + "label": "阿尔山市" + }, + { + "value": 443, + "label": "科尔沁右翼前旗" + }, + { + "value": 444, + "label": "科尔沁右翼中旗" + }, + { + "value": 445, + "label": "扎赉特旗" + }, + { + "value": 446, + "label": "突泉县" + } + ] + }, + { + "value": 447, + "label": "锡林郭勒盟", + "children": [ + { + "value": 448, + "label": "二连浩特市" + }, + { + "value": 449, + "label": "锡林浩特市" + }, + { + "value": 450, + "label": "阿巴嘎旗" + }, + { + "value": 451, + "label": "苏尼特左旗" + }, + { + "value": 452, + "label": "苏尼特右旗" + }, + { + "value": 453, + "label": "东乌珠穆沁旗" + }, + { + "value": 454, + "label": "西乌珠穆沁旗" + }, + { + "value": 455, + "label": "太仆寺旗" + }, + { + "value": 456, + "label": "镶黄旗" + }, + { + "value": 457, + "label": "正镶白旗" + }, + { + "value": 458, + "label": "正蓝旗" + }, + { + "value": 459, + "label": "多伦县" + } + ] + }, + { + "value": 460, + "label": "阿拉善盟", + "children": [ + { + "value": 461, + "label": "阿拉善左旗" + }, + { + "value": 462, + "label": "阿拉善右旗" + }, + { + "value": 463, + "label": "额济纳旗" + } + ] + } + ] + }, + { + "value": 464, + "label": "辽宁省", + "children": [ + { + "value": 465, + "label": "沈阳市", + "children": [ + { + "value": 466, + "label": "和平区" + }, + { + "value": 467, + "label": "沈河区" + }, + { + "value": 468, + "label": "大东区" + }, + { + "value": 469, + "label": "皇姑区" + }, + { + "value": 470, + "label": "铁西区" + }, + { + "value": 471, + "label": "苏家屯区" + }, + { + "value": 478, + "label": "新民市" + }, + { + "value": 472, + "label": "东陵区" + }, + { + "value": 473, + "label": "沈北新区" + }, + { + "value": 474, + "label": "于洪区" + }, + { + "value": 475, + "label": "辽中县" + }, + { + "value": 476, + "label": "康平县" + }, + { + "value": 477, + "label": "法库县" + } + ] + }, + { + "value": 479, + "label": "大连市", + "children": [ + { + "value": 480, + "label": "中山区" + }, + { + "value": 481, + "label": "西岗区" + }, + { + "value": 482, + "label": "沙河口区" + }, + { + "value": 483, + "label": "甘井子区" + }, + { + "value": 484, + "label": "旅顺口区" + }, + { + "value": 485, + "label": "金州区" + }, + { + "value": 486, + "label": "长海县" + }, + { + "value": 487, + "label": "瓦房店市" + }, + { + "value": 488, + "label": "普兰店市" + }, + { + "value": 489, + "label": "庄河市" + } + ] + }, + { + "value": 490, + "label": "鞍山市", + "children": [ + { + "value": 497, + "label": "海城市" + }, + { + "value": 491, + "label": "铁东区" + }, + { + "value": 492, + "label": "铁西区" + }, + { + "value": 493, + "label": "立山区" + }, + { + "value": 494, + "label": "千山区" + }, + { + "value": 495, + "label": "台安县" + }, + { + "value": 496, + "label": "岫岩满族自治县" + } + ] + }, + { + "value": 498, + "label": "抚顺市", + "children": [ + { + "value": 499, + "label": "新抚区" + }, + { + "value": 500, + "label": "东洲区" + }, + { + "value": 501, + "label": "望花区" + }, + { + "value": 502, + "label": "顺城区" + }, + { + "value": 503, + "label": "抚顺县" + }, + { + "value": 504, + "label": "新宾满族自治县" + }, + { + "value": 505, + "label": "清原满族自治县" + } + ] + }, + { + "value": 506, + "label": "本溪市", + "children": [ + { + "value": 507, + "label": "平山区" + }, + { + "value": 508, + "label": "溪湖区" + }, + { + "value": 509, + "label": "明山区" + }, + { + "value": 510, + "label": "南芬区" + }, + { + "value": 511, + "label": "本溪满族自治县" + }, + { + "value": 512, + "label": "桓仁满族自治县" + } + ] + }, + { + "value": 513, + "label": "丹东市", + "children": [ + { + "value": 514, + "label": "元宝区" + }, + { + "value": 515, + "label": "振兴区" + }, + { + "value": 516, + "label": "振安区" + }, + { + "value": 517, + "label": "宽甸满族自治县" + }, + { + "value": 518, + "label": "东港市" + }, + { + "value": 519, + "label": "凤城市" + } + ] + }, + { + "value": 520, + "label": "锦州市", + "children": [ + { + "value": 521, + "label": "古塔区" + }, + { + "value": 522, + "label": "凌河区" + }, + { + "value": 523, + "label": "太和区" + }, + { + "value": 524, + "label": "黑山县" + }, + { + "value": 525, + "label": "义县" + }, + { + "value": 526, + "label": "凌海市" + }, + { + "value": 527, + "label": "北镇市" + } + ] + }, + { + "value": 528, + "label": "营口市", + "children": [ + { + "value": 529, + "label": "站前区" + }, + { + "value": 530, + "label": "西市区" + }, + { + "value": 531, + "label": "鲅鱼圈区" + }, + { + "value": 532, + "label": "老边区" + }, + { + "value": 533, + "label": "盖州市" + }, + { + "value": 534, + "label": "大石桥市" + } + ] + }, + { + "value": 535, + "label": "阜新市", + "children": [ + { + "value": 536, + "label": "海州区" + }, + { + "value": 537, + "label": "新邱区" + }, + { + "value": 538, + "label": "太平区" + }, + { + "value": 539, + "label": "清河门区" + }, + { + "value": 540, + "label": "细河区" + }, + { + "value": 541, + "label": "阜新蒙古族自治县" + }, + { + "value": 542, + "label": "彰武县" + } + ] + }, + { + "value": 543, + "label": "辽阳市", + "children": [ + { + "value": 544, + "label": "白塔区" + }, + { + "value": 545, + "label": "文圣区" + }, + { + "value": 546, + "label": "宏伟区" + }, + { + "value": 547, + "label": "弓长岭区" + }, + { + "value": 548, + "label": "太子河区" + }, + { + "value": 549, + "label": "辽阳县" + }, + { + "value": 550, + "label": "灯塔市" + } + ] + }, + { + "value": 551, + "label": "盘锦市", + "children": [ + { + "value": 552, + "label": "双台子区" + }, + { + "value": 553, + "label": "兴隆台区" + }, + { + "value": 554, + "label": "大洼县" + }, + { + "value": 555, + "label": "盘山县" + } + ] + }, + { + "value": 556, + "label": "铁岭市", + "children": [ + { + "value": 557, + "label": "银州区" + }, + { + "value": 558, + "label": "清河区" + }, + { + "value": 559, + "label": "铁岭县" + }, + { + "value": 560, + "label": "西丰县" + }, + { + "value": 561, + "label": "昌图县" + }, + { + "value": 562, + "label": "调兵山市" + }, + { + "value": 563, + "label": "开原市" + } + ] + }, + { + "value": 564, + "label": "朝阳市", + "children": [ + { + "value": 568, + "label": "建平县" + }, + { + "value": 569, + "label": "喀喇沁左翼蒙古族自治县" + }, + { + "value": 570, + "label": "北票市" + }, + { + "value": 571, + "label": "凌源市" + }, + { + "value": 565, + "label": "双塔区" + }, + { + "value": 566, + "label": "龙城区" + }, + { + "value": 567, + "label": "朝阳县" + } + ] + }, + { + "value": 572, + "label": "葫芦岛市", + "children": [ + { + "value": 573, + "label": "连山区" + }, + { + "value": 574, + "label": "龙港区" + }, + { + "value": 575, + "label": "南票区" + }, + { + "value": 576, + "label": "绥中县" + }, + { + "value": 577, + "label": "建昌县" + }, + { + "value": 578, + "label": "兴城市" + } + ] + } + ] + }, + { + "value": 579, + "label": "吉林省", + "children": [ + { + "value": 580, + "label": "长春市", + "children": [ + { + "value": 581, + "label": "南关区" + }, + { + "value": 582, + "label": "宽城区" + }, + { + "value": 583, + "label": "朝阳区" + }, + { + "value": 584, + "label": "二道区" + }, + { + "value": 585, + "label": "绿园区" + }, + { + "value": 586, + "label": "双阳区" + }, + { + "value": 587, + "label": "农安县" + }, + { + "value": 588, + "label": "九台市" + }, + { + "value": 589, + "label": "榆树市" + }, + { + "value": 590, + "label": "德惠市" + } + ] + }, + { + "value": 591, + "label": "吉林市", + "children": [ + { + "value": 592, + "label": "昌邑区" + }, + { + "value": 593, + "label": "龙潭区" + }, + { + "value": 594, + "label": "船营区" + }, + { + "value": 595, + "label": "丰满区" + }, + { + "value": 596, + "label": "永吉县" + }, + { + "value": 597, + "label": "蛟河市" + }, + { + "value": 598, + "label": "桦甸市" + }, + { + "value": 599, + "label": "舒兰市" + }, + { + "value": 600, + "label": "磐石市" + } + ] + }, + { + "value": 601, + "label": "四平市", + "children": [ + { + "value": 602, + "label": "铁西区" + }, + { + "value": 603, + "label": "铁东区" + }, + { + "value": 604, + "label": "梨树县" + }, + { + "value": 605, + "label": "伊通满族自治县" + }, + { + "value": 606, + "label": "公主岭市" + }, + { + "value": 607, + "label": "双辽市" + } + ] + }, + { + "value": 608, + "label": "辽源市", + "children": [ + { + "value": 609, + "label": "龙山区" + }, + { + "value": 610, + "label": "西安区" + }, + { + "value": 611, + "label": "东丰县" + }, + { + "value": 612, + "label": "东辽县" + } + ] + }, + { + "value": 613, + "label": "通化市", + "children": [ + { + "value": 614, + "label": "东昌区" + }, + { + "value": 615, + "label": "二道江区" + }, + { + "value": 616, + "label": "通化县" + }, + { + "value": 617, + "label": "辉南县" + }, + { + "value": 618, + "label": "柳河县" + }, + { + "value": 619, + "label": "梅河口市" + }, + { + "value": 620, + "label": "集安市" + } + ] + }, + { + "value": 621, + "label": "白山市", + "children": [ + { + "value": 622, + "label": "八道江区" + }, + { + "value": 623, + "label": "江源区" + }, + { + "value": 624, + "label": "抚松县" + }, + { + "value": 625, + "label": "靖宇县" + }, + { + "value": 626, + "label": "长白朝鲜族自治县" + }, + { + "value": 627, + "label": "临江市" + } + ] + }, + { + "value": 628, + "label": "松原市", + "children": [ + { + "value": 629, + "label": "宁江区" + }, + { + "value": 630, + "label": "前郭尔罗斯蒙古族自治县" + }, + { + "value": 631, + "label": "长岭县" + }, + { + "value": 632, + "label": "乾安县" + }, + { + "value": 633, + "label": "扶余县" + } + ] + }, + { + "value": 634, + "label": "白城市", + "children": [ + { + "value": 635, + "label": "洮北区" + }, + { + "value": 636, + "label": "镇赉县" + }, + { + "value": 637, + "label": "通榆县" + }, + { + "value": 638, + "label": "洮南市" + }, + { + "value": 639, + "label": "大安市" + } + ] + }, + { + "value": 640, + "label": "延边朝鲜族自治州", + "children": [ + { + "value": 641, + "label": "延吉市" + }, + { + "value": 642, + "label": "图们市" + }, + { + "value": 643, + "label": "敦化市" + }, + { + "value": 644, + "label": "珲春市" + }, + { + "value": 645, + "label": "龙井市" + }, + { + "value": 646, + "label": "和龙市" + }, + { + "value": 647, + "label": "汪清县" + }, + { + "value": 648, + "label": "安图县" + } + ] + } + ] + }, + { + "value": 649, + "label": "黑龙江省", + "children": [ + { + "value": 650, + "label": "哈尔滨市", + "children": [ + { + "value": 651, + "label": "道里区" + }, + { + "value": 652, + "label": "南岗区" + }, + { + "value": 653, + "label": "道外区" + }, + { + "value": 654, + "label": "平房区" + }, + { + "value": 655, + "label": "松北区" + }, + { + "value": 656, + "label": "香坊区" + }, + { + "value": 663, + "label": "木兰县" + }, + { + "value": 664, + "label": "通河县" + }, + { + "value": 665, + "label": "延寿县" + }, + { + "value": 666, + "label": "双城市" + }, + { + "value": 667, + "label": "尚志市" + }, + { + "value": 668, + "label": "五常市" + }, + { + "value": 657, + "label": "呼兰区" + }, + { + "value": 658, + "label": "阿城区" + }, + { + "value": 659, + "label": "依兰县" + }, + { + "value": 660, + "label": "方正县" + }, + { + "value": 661, + "label": "宾县" + }, + { + "value": 662, + "label": "巴彦县" + } + ] + }, + { + "value": 669, + "label": "齐齐哈尔市", + "children": [ + { + "value": 670, + "label": "龙沙区" + }, + { + "value": 671, + "label": "建华区" + }, + { + "value": 672, + "label": "铁锋区" + }, + { + "value": 673, + "label": "昂昂溪区" + }, + { + "value": 674, + "label": "富拉尔基区" + }, + { + "value": 675, + "label": "碾子山区" + }, + { + "value": 682, + "label": "克山县" + }, + { + "value": 683, + "label": "克东县" + }, + { + "value": 684, + "label": "拜泉县" + }, + { + "value": 685, + "label": "讷河市" + }, + { + "value": 676, + "label": "梅里斯达斡尔族区" + }, + { + "value": 677, + "label": "龙江县" + }, + { + "value": 678, + "label": "依安县" + }, + { + "value": 679, + "label": "泰来县" + }, + { + "value": 680, + "label": "甘南县" + }, + { + "value": 681, + "label": "富裕县" + } + ] + }, + { + "value": 686, + "label": "鸡西市", + "children": [ + { + "value": 687, + "label": "鸡冠区" + }, + { + "value": 688, + "label": "恒山区" + }, + { + "value": 689, + "label": "滴道区" + }, + { + "value": 690, + "label": "梨树区" + }, + { + "value": 691, + "label": "城子河区" + }, + { + "value": 692, + "label": "麻山区" + }, + { + "value": 693, + "label": "鸡东县" + }, + { + "value": 694, + "label": "虎林市" + }, + { + "value": 695, + "label": "密山市" + } + ] + }, + { + "value": 696, + "label": "鹤岗市", + "children": [ + { + "value": 697, + "label": "向阳区" + }, + { + "value": 698, + "label": "工农区" + }, + { + "value": 699, + "label": "南山区" + }, + { + "value": 700, + "label": "兴安区" + }, + { + "value": 701, + "label": "东山区" + }, + { + "value": 702, + "label": "兴山区" + }, + { + "value": 703, + "label": "萝北县" + }, + { + "value": 704, + "label": "绥滨县" + } + ] + }, + { + "value": 705, + "label": "双鸭山市", + "children": [ + { + "value": 706, + "label": "尖山区" + }, + { + "value": 707, + "label": "岭东区" + }, + { + "value": 708, + "label": "四方台区" + }, + { + "value": 709, + "label": "宝山区" + }, + { + "value": 710, + "label": "集贤县" + }, + { + "value": 711, + "label": "友谊县" + }, + { + "value": 712, + "label": "宝清县" + }, + { + "value": 713, + "label": "饶河县" + } + ] + }, + { + "value": 714, + "label": "大庆市", + "children": [ + { + "value": 715, + "label": "萨尔图区" + }, + { + "value": 716, + "label": "龙凤区" + }, + { + "value": 717, + "label": "让胡路区" + }, + { + "value": 718, + "label": "红岗区" + }, + { + "value": 719, + "label": "大同区" + }, + { + "value": 720, + "label": "肇州县" + }, + { + "value": 721, + "label": "肇源县" + }, + { + "value": 722, + "label": "林甸县" + }, + { + "value": 723, + "label": "杜尔伯特蒙古族自治县" + } + ] + }, + { + "value": 724, + "label": "伊春市", + "children": [ + { + "value": 741, + "label": "铁力市" + }, + { + "value": 735, + "label": "汤旺河区" + }, + { + "value": 736, + "label": "带岭区" + }, + { + "value": 737, + "label": "乌伊岭区" + }, + { + "value": 738, + "label": "红星区" + }, + { + "value": 739, + "label": "上甘岭区" + }, + { + "value": 740, + "label": "嘉荫县" + }, + { + "value": 729, + "label": "翠峦区" + }, + { + "value": 730, + "label": "新青区" + }, + { + "value": 731, + "label": "美溪区" + }, + { + "value": 732, + "label": "金山屯区" + }, + { + "value": 733, + "label": "五营区" + }, + { + "value": 734, + "label": "乌马河区" + }, + { + "value": 725, + "label": "伊春区" + }, + { + "value": 726, + "label": "南岔区" + }, + { + "value": 727, + "label": "友好区" + }, + { + "value": 728, + "label": "西林区" + } + ] + }, + { + "value": 742, + "label": "佳木斯市", + "children": [ + { + "value": 743, + "label": "向阳区" + }, + { + "value": 744, + "label": "前进区" + }, + { + "value": 745, + "label": "东风区" + }, + { + "value": 746, + "label": "郊区" + }, + { + "value": 747, + "label": "桦南县" + }, + { + "value": 748, + "label": "桦川县" + }, + { + "value": 749, + "label": "汤原县" + }, + { + "value": 750, + "label": "抚远县" + }, + { + "value": 751, + "label": "同江市" + }, + { + "value": 752, + "label": "富锦市" + } + ] + }, + { + "value": 753, + "label": "七台河市", + "children": [ + { + "value": 754, + "label": "新兴区" + }, + { + "value": 755, + "label": "桃山区" + }, + { + "value": 756, + "label": "茄子河区" + }, + { + "value": 757, + "label": "勃利县" + } + ] + }, + { + "value": 758, + "label": "牡丹江市", + "children": [ + { + "value": 759, + "label": "东安区" + }, + { + "value": 760, + "label": "阳明区" + }, + { + "value": 761, + "label": "爱民区" + }, + { + "value": 762, + "label": "西安区" + }, + { + "value": 763, + "label": "东宁县" + }, + { + "value": 764, + "label": "林口县" + }, + { + "value": 765, + "label": "绥芬河市" + }, + { + "value": 766, + "label": "海林市" + }, + { + "value": 767, + "label": "宁安市" + }, + { + "value": 768, + "label": "穆棱市" + } + ] + }, + { + "value": 769, + "label": "黑河市", + "children": [ + { + "value": 770, + "label": "爱辉区" + }, + { + "value": 771, + "label": "嫩江县" + }, + { + "value": 772, + "label": "逊克县" + }, + { + "value": 773, + "label": "孙吴县" + }, + { + "value": 774, + "label": "北安市" + }, + { + "value": 775, + "label": "五大连池市" + } + ] + }, + { + "value": 776, + "label": "绥化市", + "children": [ + { + "value": 777, + "label": "北林区" + }, + { + "value": 778, + "label": "望奎县" + }, + { + "value": 779, + "label": "兰西县" + }, + { + "value": 780, + "label": "青冈县" + }, + { + "value": 781, + "label": "庆安县" + }, + { + "value": 782, + "label": "明水县" + }, + { + "value": 783, + "label": "绥棱县" + }, + { + "value": 784, + "label": "安达市" + }, + { + "value": 785, + "label": "肇东市" + }, + { + "value": 786, + "label": "海伦市" + } + ] + }, + { + "value": 787, + "label": "大兴安岭地区", + "children": [ + { + "value": 788, + "label": "呼玛县" + }, + { + "value": 789, + "label": "塔河县" + }, + { + "value": 790, + "label": "漠河县" + } + ] + } + ] + }, + { + "value": 791, + "label": "上海市", + "children": [ + { + "value": 792, + "label": "黄浦区" + }, + { + "value": 793, + "label": "徐汇区" + }, + { + "value": 794, + "label": "长宁区" + }, + { + "value": 795, + "label": "静安区" + }, + { + "value": 796, + "label": "普陀区" + }, + { + "value": 797, + "label": "闸北区" + }, + { + "value": 798, + "label": "虹口区" + }, + { + "value": 799, + "label": "杨浦区" + }, + { + "value": 800, + "label": "闵行区" + }, + { + "value": 801, + "label": "宝山区" + }, + { + "value": 802, + "label": "嘉定区" + }, + { + "value": 803, + "label": "浦东新区" + }, + { + "value": 804, + "label": "金山区" + }, + { + "value": 805, + "label": "松江区" + }, + { + "value": 806, + "label": "青浦区" + }, + { + "value": 807, + "label": "奉贤区" + }, + { + "value": 808, + "label": "崇明县" + } + ] + }, + { + "value": 809, + "label": "江苏省", + "children": [ + { + "value": 810, + "label": "南京市", + "children": [ + { + "value": 811, + "label": "玄武区" + }, + { + "value": 812, + "label": "白下区" + }, + { + "value": 813, + "label": "秦淮区" + }, + { + "value": 814, + "label": "建邺区" + }, + { + "value": 815, + "label": "鼓楼区" + }, + { + "value": 816, + "label": "下关区" + }, + { + "value": 823, + "label": "高淳县" + }, + { + "value": 817, + "label": "浦口区" + }, + { + "value": 818, + "label": "栖霞区" + }, + { + "value": 819, + "label": "雨花台区" + }, + { + "value": 820, + "label": "江宁区" + }, + { + "value": 821, + "label": "六合区" + }, + { + "value": 822, + "label": "溧水县" + } + ] + }, + { + "value": 824, + "label": "无锡市", + "children": [ + { + "value": 825, + "label": "崇安区" + }, + { + "value": 826, + "label": "南长区" + }, + { + "value": 827, + "label": "北塘区" + }, + { + "value": 828, + "label": "锡山区" + }, + { + "value": 829, + "label": "惠山区" + }, + { + "value": 830, + "label": "滨湖区" + }, + { + "value": 831, + "label": "江阴市" + }, + { + "value": 832, + "label": "宜兴市" + } + ] + }, + { + "value": 833, + "label": "徐州市", + "children": [ + { + "value": 834, + "label": "鼓楼区" + }, + { + "value": 835, + "label": "云龙区" + }, + { + "value": 836, + "label": "贾汪区" + }, + { + "value": 837, + "label": "泉山区" + }, + { + "value": 838, + "label": "铜山区" + }, + { + "value": 839, + "label": "丰县" + }, + { + "value": 840, + "label": "沛县" + }, + { + "value": 841, + "label": "睢宁县" + }, + { + "value": 842, + "label": "新沂市" + }, + { + "value": 843, + "label": "邳州市" + } + ] + }, + { + "value": 844, + "label": "常州市", + "children": [ + { + "value": 845, + "label": "天宁区" + }, + { + "value": 846, + "label": "钟楼区" + }, + { + "value": 847, + "label": "戚墅堰区" + }, + { + "value": 848, + "label": "新北区" + }, + { + "value": 849, + "label": "武进区" + }, + { + "value": 850, + "label": "溧阳市" + }, + { + "value": 851, + "label": "金坛市" + } + ] + }, + { + "value": 852, + "label": "苏州市", + "children": [ + { + "value": 853, + "label": "沧浪区" + }, + { + "value": 854, + "label": "平江区" + }, + { + "value": 855, + "label": "金阊区" + }, + { + "value": 856, + "label": "虎丘区" + }, + { + "value": 857, + "label": "吴中区" + }, + { + "value": 858, + "label": "相城区" + }, + { + "value": 859, + "label": "常熟市" + }, + { + "value": 860, + "label": "张家港市" + }, + { + "value": 861, + "label": "昆山市" + }, + { + "value": 862, + "label": "吴江市" + }, + { + "value": 863, + "label": "太仓市" + } + ] + }, + { + "value": 864, + "label": "南通市", + "children": [ + { + "value": 865, + "label": "崇川区" + }, + { + "value": 866, + "label": "港闸区" + }, + { + "value": 867, + "label": "通州区" + }, + { + "value": 868, + "label": "海安县" + }, + { + "value": 869, + "label": "如东县" + }, + { + "value": 870, + "label": "启东市" + }, + { + "value": 871, + "label": "如皋市" + }, + { + "value": 872, + "label": "海门市" + } + ] + }, + { + "value": 873, + "label": "连云港市", + "children": [ + { + "value": 874, + "label": "连云区" + }, + { + "value": 875, + "label": "新浦区" + }, + { + "value": 876, + "label": "海州区" + }, + { + "value": 877, + "label": "赣榆县" + }, + { + "value": 878, + "label": "东海县" + }, + { + "value": 879, + "label": "灌云县" + }, + { + "value": 880, + "label": "灌南县" + } + ] + }, + { + "value": 881, + "label": "淮安市", + "children": [ + { + "value": 882, + "label": "清河区" + }, + { + "value": 883, + "label": "楚州区" + }, + { + "value": 884, + "label": "淮阴区" + }, + { + "value": 885, + "label": "清浦区" + }, + { + "value": 886, + "label": "涟水县" + }, + { + "value": 887, + "label": "洪泽县" + }, + { + "value": 888, + "label": "盱眙县" + }, + { + "value": 889, + "label": "金湖县" + } + ] + }, + { + "value": 890, + "label": "盐城市", + "children": [ + { + "value": 891, + "label": "亭湖区" + }, + { + "value": 892, + "label": "盐都区" + }, + { + "value": 893, + "label": "响水县" + }, + { + "value": 894, + "label": "滨海县" + }, + { + "value": 895, + "label": "阜宁县" + }, + { + "value": 896, + "label": "射阳县" + }, + { + "value": 897, + "label": "建湖县" + }, + { + "value": 898, + "label": "东台市" + }, + { + "value": 899, + "label": "大丰市" + } + ] + }, + { + "value": 900, + "label": "扬州市", + "children": [ + { + "value": 901, + "label": "广陵区" + }, + { + "value": 902, + "label": "邗江区" + }, + { + "value": 903, + "label": "江都区" + }, + { + "value": 904, + "label": "宝应县" + }, + { + "value": 905, + "label": "仪征市" + }, + { + "value": 906, + "label": "高邮市" + } + ] + }, + { + "value": 907, + "label": "镇江市", + "children": [ + { + "value": 908, + "label": "京口区" + }, + { + "value": 909, + "label": "润州区" + }, + { + "value": 910, + "label": "丹徒区" + }, + { + "value": 911, + "label": "丹阳市" + }, + { + "value": 912, + "label": "扬中市" + }, + { + "value": 913, + "label": "句容市" + } + ] + }, + { + "value": 914, + "label": "泰州市", + "children": [ + { + "value": 915, + "label": "海陵区" + }, + { + "value": 916, + "label": "高港区" + }, + { + "value": 917, + "label": "兴化市" + }, + { + "value": 918, + "label": "靖江市" + }, + { + "value": 919, + "label": "泰兴市" + }, + { + "value": 920, + "label": "姜堰市" + } + ] + }, + { + "value": 921, + "label": "宿迁市", + "children": [ + { + "value": 922, + "label": "宿城区" + }, + { + "value": 923, + "label": "宿豫区" + }, + { + "value": 924, + "label": "沭阳县" + }, + { + "value": 925, + "label": "泗阳县" + }, + { + "value": 926, + "label": "泗洪县" + } + ] + } + ] + }, + { + "value": 927, + "label": "浙江省", + "children": [ + { + "value": 928, + "label": "杭州市", + "children": [ + { + "value": 929, + "label": "上城区" + }, + { + "value": 930, + "label": "下城区" + }, + { + "value": 931, + "label": "江干区" + }, + { + "value": 932, + "label": "拱墅区" + }, + { + "value": 933, + "label": "西湖区" + }, + { + "value": 934, + "label": "滨江区" + }, + { + "value": 941, + "label": "临安市" + }, + { + "value": 935, + "label": "萧山区" + }, + { + "value": 936, + "label": "余杭区" + }, + { + "value": 937, + "label": "桐庐县" + }, + { + "value": 938, + "label": "淳安县" + }, + { + "value": 939, + "label": "建德市" + }, + { + "value": 940, + "label": "富阳市" + } + ] + }, + { + "value": 942, + "label": "宁波市", + "children": [ + { + "value": 943, + "label": "海曙区" + }, + { + "value": 944, + "label": "江东区" + }, + { + "value": 945, + "label": "江北区" + }, + { + "value": 946, + "label": "北仑区" + }, + { + "value": 947, + "label": "镇海区" + }, + { + "value": 948, + "label": "鄞州区" + }, + { + "value": 949, + "label": "象山县" + }, + { + "value": 950, + "label": "宁海县" + }, + { + "value": 951, + "label": "余姚市" + }, + { + "value": 952, + "label": "慈溪市" + }, + { + "value": 953, + "label": "奉化市" + } + ] + }, + { + "value": 954, + "label": "温州市", + "children": [ + { + "value": 955, + "label": "鹿城区" + }, + { + "value": 956, + "label": "龙湾区" + }, + { + "value": 957, + "label": "瓯海区" + }, + { + "value": 958, + "label": "洞头县" + }, + { + "value": 959, + "label": "永嘉县" + }, + { + "value": 960, + "label": "平阳县" + }, + { + "value": 961, + "label": "苍南县" + }, + { + "value": 962, + "label": "文成县" + }, + { + "value": 963, + "label": "泰顺县" + }, + { + "value": 964, + "label": "瑞安市" + }, + { + "value": 965, + "label": "乐清市" + } + ] + }, + { + "value": 966, + "label": "嘉兴市", + "children": [ + { + "value": 967, + "label": "南湖区" + }, + { + "value": 968, + "label": "秀洲区" + }, + { + "value": 969, + "label": "嘉善县" + }, + { + "value": 970, + "label": "海盐县" + }, + { + "value": 971, + "label": "海宁市" + }, + { + "value": 972, + "label": "平湖市" + }, + { + "value": 973, + "label": "桐乡市" + } + ] + }, + { + "value": 974, + "label": "湖州市", + "children": [ + { + "value": 977, + "label": "德清县" + }, + { + "value": 978, + "label": "长兴县" + }, + { + "value": 979, + "label": "安吉县" + }, + { + "value": 975, + "label": "吴兴区" + }, + { + "value": 976, + "label": "南浔区" + } + ] + }, + { + "value": 980, + "label": "绍兴市", + "children": [ + { + "value": 981, + "label": "越城区" + }, + { + "value": 982, + "label": "绍兴县" + }, + { + "value": 983, + "label": "新昌县" + }, + { + "value": 984, + "label": "诸暨市" + }, + { + "value": 985, + "label": "上虞市" + }, + { + "value": 986, + "label": "嵊州市" + } + ] + }, + { + "value": 987, + "label": "金华市", + "children": [ + { + "value": 988, + "label": "婺城区" + }, + { + "value": 989, + "label": "金东区" + }, + { + "value": 990, + "label": "武义县" + }, + { + "value": 991, + "label": "浦江县" + }, + { + "value": 992, + "label": "磐安县" + }, + { + "value": 993, + "label": "兰溪市" + }, + { + "value": 994, + "label": "义乌市" + }, + { + "value": 995, + "label": "东阳市" + }, + { + "value": 996, + "label": "永康市" + } + ] + }, + { + "value": 997, + "label": "衢州市", + "children": [ + { + "value": 998, + "label": "柯城区" + }, + { + "value": 999, + "label": "衢江区" + }, + { + "value": 1000, + "label": "常山县" + }, + { + "value": 1001, + "label": "开化县" + }, + { + "value": 1002, + "label": "龙游县" + }, + { + "value": 1003, + "label": "江山市" + } + ] + }, + { + "value": 1004, + "label": "舟山市", + "children": [ + { + "value": 1005, + "label": "定海区" + }, + { + "value": 1006, + "label": "普陀区" + }, + { + "value": 1007, + "label": "岱山县" + }, + { + "value": 1008, + "label": "嵊泗县" + } + ] + }, + { + "value": 1009, + "label": "台州市", + "children": [ + { + "value": 1013, + "label": "玉环县" + }, + { + "value": 1014, + "label": "三门县" + }, + { + "value": 1015, + "label": "天台县" + }, + { + "value": 1016, + "label": "仙居县" + }, + { + "value": 1017, + "label": "温岭市" + }, + { + "value": 1018, + "label": "临海市" + }, + { + "value": 1010, + "label": "椒江区" + }, + { + "value": 1011, + "label": "黄岩区" + }, + { + "value": 1012, + "label": "路桥区" + } + ] + }, + { + "value": 1019, + "label": "丽水市", + "children": [ + { + "value": 1020, + "label": "莲都区" + }, + { + "value": 1021, + "label": "青田县" + }, + { + "value": 1022, + "label": "缙云县" + }, + { + "value": 1023, + "label": "遂昌县" + }, + { + "value": 1024, + "label": "松阳县" + }, + { + "value": 1025, + "label": "云和县" + }, + { + "value": 1026, + "label": "庆元县" + }, + { + "value": 1027, + "label": "景宁畲族自治县" + }, + { + "value": 1028, + "label": "龙泉市" + } + ] + } + ] + }, + { + "value": 1029, + "label": "安徽省", + "children": [ + { + "value": 1030, + "label": "合肥市", + "children": [ + { + "value": 1034, + "label": "包河区" + }, + { + "value": 1035, + "label": "长丰县" + }, + { + "value": 1036, + "label": "肥东县" + }, + { + "value": 1037, + "label": "肥西县" + }, + { + "value": 1038, + "label": "庐江县" + }, + { + "value": 1039, + "label": "巢湖市" + }, + { + "value": 1031, + "label": "瑶海区" + }, + { + "value": 1032, + "label": "庐阳区" + }, + { + "value": 1033, + "label": "蜀山区" + } + ] + }, + { + "value": 1040, + "label": "芜湖市", + "children": [ + { + "value": 1041, + "label": "镜湖区" + }, + { + "value": 1042, + "label": "弋江区" + }, + { + "value": 1043, + "label": "鸠江区" + }, + { + "value": 1044, + "label": "三山区" + }, + { + "value": 1045, + "label": "芜湖县" + }, + { + "value": 1046, + "label": "繁昌县" + }, + { + "value": 1047, + "label": "南陵县" + }, + { + "value": 1048, + "label": "无为县" + } + ] + }, + { + "value": 1049, + "label": "蚌埠市", + "children": [ + { + "value": 1050, + "label": "龙子湖区" + }, + { + "value": 1051, + "label": "蚌山区" + }, + { + "value": 1052, + "label": "禹会区" + }, + { + "value": 1053, + "label": "淮上区" + }, + { + "value": 1054, + "label": "怀远县" + }, + { + "value": 1055, + "label": "五河县" + }, + { + "value": 1056, + "label": "固镇县" + } + ] + }, + { + "value": 1057, + "label": "淮南市", + "children": [ + { + "value": 1058, + "label": "大通区" + }, + { + "value": 1059, + "label": "田家庵区" + }, + { + "value": 1060, + "label": "谢家集区" + }, + { + "value": 1061, + "label": "八公山区" + }, + { + "value": 1062, + "label": "潘集区" + }, + { + "value": 1063, + "label": "凤台县" + } + ] + }, + { + "value": 1064, + "label": "马鞍山市", + "children": [ + { + "value": 1065, + "label": "金家庄区" + }, + { + "value": 1066, + "label": "花山区" + }, + { + "value": 1067, + "label": "雨山区" + }, + { + "value": 1068, + "label": "当涂县" + }, + { + "value": 1069, + "label": "含山县" + }, + { + "value": 1070, + "label": "和县" + } + ] + }, + { + "value": 1071, + "label": "淮北市", + "children": [ + { + "value": 1072, + "label": "杜集区" + }, + { + "value": 1073, + "label": "相山区" + }, + { + "value": 1074, + "label": "烈山区" + }, + { + "value": 1075, + "label": "濉溪县" + } + ] + }, + { + "value": 1076, + "label": "铜陵市", + "children": [ + { + "value": 1077, + "label": "铜官山区" + }, + { + "value": 1078, + "label": "狮子山区" + }, + { + "value": 1079, + "label": "郊区" + }, + { + "value": 1080, + "label": "铜陵县" + } + ] + }, + { + "value": 1081, + "label": "安庆市", + "children": [ + { + "value": 1082, + "label": "迎江区" + }, + { + "value": 1083, + "label": "大观区" + }, + { + "value": 1084, + "label": "宜秀区" + }, + { + "value": 1085, + "label": "怀宁县" + }, + { + "value": 1086, + "label": "枞阳县" + }, + { + "value": 1087, + "label": "潜山县" + }, + { + "value": 1088, + "label": "太湖县" + }, + { + "value": 1089, + "label": "宿松县" + }, + { + "value": 1090, + "label": "望江县" + }, + { + "value": 1091, + "label": "岳西县" + }, + { + "value": 1092, + "label": "桐城市" + } + ] + }, + { + "value": 1093, + "label": "黄山市", + "children": [ + { + "value": 1094, + "label": "屯溪区" + }, + { + "value": 1095, + "label": "黄山区" + }, + { + "value": 1096, + "label": "徽州区" + }, + { + "value": 1097, + "label": "歙县" + }, + { + "value": 1098, + "label": "休宁县" + }, + { + "value": 1099, + "label": "黟县" + }, + { + "value": 1100, + "label": "祁门县" + } + ] + }, + { + "value": 1101, + "label": "滁州市", + "children": [ + { + "value": 1108, + "label": "天长市" + }, + { + "value": 1109, + "label": "明光市" + }, + { + "value": 1102, + "label": "琅琊区" + }, + { + "value": 1103, + "label": "南谯区" + }, + { + "value": 1104, + "label": "来安县" + }, + { + "value": 1105, + "label": "全椒县" + }, + { + "value": 1106, + "label": "定远县" + }, + { + "value": 1107, + "label": "凤阳县" + } + ] + }, + { + "value": 1110, + "label": "阜阳市", + "children": [ + { + "value": 1117, + "label": "颍上县" + }, + { + "value": 1118, + "label": "界首市" + }, + { + "value": 1111, + "label": "颍州区" + }, + { + "value": 1112, + "label": "颍东区" + }, + { + "value": 1113, + "label": "颍泉区" + }, + { + "value": 1114, + "label": "临泉县" + }, + { + "value": 1115, + "label": "太和县" + }, + { + "value": 1116, + "label": "阜南县" + } + ] + }, + { + "value": 1119, + "label": "宿州市", + "children": [ + { + "value": 1120, + "label": "埇桥区" + }, + { + "value": 1121, + "label": "砀山县" + }, + { + "value": 1122, + "label": "萧县" + }, + { + "value": 1123, + "label": "灵璧县" + }, + { + "value": 1124, + "label": "泗县" + } + ] + }, + { + "value": 1125, + "label": "六安市", + "children": [ + { + "value": 1126, + "label": "金安区" + }, + { + "value": 1127, + "label": "裕安区" + }, + { + "value": 1128, + "label": "寿县" + }, + { + "value": 1129, + "label": "霍邱县" + }, + { + "value": 1130, + "label": "舒城县" + }, + { + "value": 1131, + "label": "金寨县" + }, + { + "value": 1132, + "label": "霍山县" + } + ] + }, + { + "value": 1133, + "label": "亳州市", + "children": [ + { + "value": 1134, + "label": "谯城区" + }, + { + "value": 1135, + "label": "涡阳县" + }, + { + "value": 1136, + "label": "蒙城县" + }, + { + "value": 1137, + "label": "利辛县" + } + ] + }, + { + "value": 1138, + "label": "池州市", + "children": [ + { + "value": 1139, + "label": "贵池区" + }, + { + "value": 1140, + "label": "东至县" + }, + { + "value": 1141, + "label": "石台县" + }, + { + "value": 1142, + "label": "青阳县" + } + ] + }, + { + "value": 1143, + "label": "宣城市", + "children": [ + { + "value": 1147, + "label": "泾县" + }, + { + "value": 1148, + "label": "绩溪县" + }, + { + "value": 1149, + "label": "旌德县" + }, + { + "value": 1150, + "label": "宁国市" + }, + { + "value": 1144, + "label": "宣州区" + }, + { + "value": 1145, + "label": "郎溪县" + }, + { + "value": 1146, + "label": "广德县" + } + ] + } + ] + }, + { + "value": 1151, + "label": "福建省", + "children": [ + { + "value": 1152, + "label": "福州市", + "children": [ + { + "value": 1153, + "label": "鼓楼区" + }, + { + "value": 1154, + "label": "台江区" + }, + { + "value": 1155, + "label": "仓山区" + }, + { + "value": 1156, + "label": "马尾区" + }, + { + "value": 1157, + "label": "晋安区" + }, + { + "value": 1158, + "label": "闽侯县" + }, + { + "value": 1165, + "label": "长乐市" + }, + { + "value": 1159, + "label": "连江县" + }, + { + "value": 1160, + "label": "罗源县" + }, + { + "value": 1161, + "label": "闽清县" + }, + { + "value": 1162, + "label": "永泰县" + }, + { + "value": 1163, + "label": "平潭县" + }, + { + "value": 1164, + "label": "福清市" + } + ] + }, + { + "value": 1166, + "label": "厦门市", + "children": [ + { + "value": 1167, + "label": "思明区" + }, + { + "value": 1168, + "label": "海沧区" + }, + { + "value": 1169, + "label": "湖里区" + }, + { + "value": 1170, + "label": "集美区" + }, + { + "value": 1171, + "label": "同安区" + }, + { + "value": 1172, + "label": "翔安区" + } + ] + }, + { + "value": 1173, + "label": "莆田市", + "children": [ + { + "value": 1174, + "label": "城厢区" + }, + { + "value": 1175, + "label": "涵江区" + }, + { + "value": 1176, + "label": "荔城区" + }, + { + "value": 1177, + "label": "秀屿区" + }, + { + "value": 1178, + "label": "仙游县" + } + ] + }, + { + "value": 1179, + "label": "三明市", + "children": [ + { + "value": 1180, + "label": "梅列区" + }, + { + "value": 1181, + "label": "三元区" + }, + { + "value": 1182, + "label": "明溪县" + }, + { + "value": 1183, + "label": "清流县" + }, + { + "value": 1184, + "label": "宁化县" + }, + { + "value": 1185, + "label": "大田县" + }, + { + "value": 1186, + "label": "尤溪县" + }, + { + "value": 1187, + "label": "沙县" + }, + { + "value": 1188, + "label": "将乐县" + }, + { + "value": 1189, + "label": "泰宁县" + }, + { + "value": 1190, + "label": "建宁县" + }, + { + "value": 1191, + "label": "永安市" + } + ] + }, + { + "value": 1192, + "label": "泉州市", + "children": [ + { + "value": 1201, + "label": "金门县" + }, + { + "value": 1202, + "label": "石狮市" + }, + { + "value": 1203, + "label": "晋江市" + }, + { + "value": 1204, + "label": "南安市" + }, + { + "value": 1195, + "label": "洛江区" + }, + { + "value": 1196, + "label": "泉港区" + }, + { + "value": 1197, + "label": "惠安县" + }, + { + "value": 1198, + "label": "安溪县" + }, + { + "value": 1199, + "label": "永春县" + }, + { + "value": 1200, + "label": "德化县" + }, + { + "value": 1193, + "label": "鲤城区" + }, + { + "value": 1194, + "label": "丰泽区" + } + ] + }, + { + "value": 1205, + "label": "漳州市", + "children": [ + { + "value": 1211, + "label": "长泰县" + }, + { + "value": 1212, + "label": "东山县" + }, + { + "value": 1213, + "label": "南靖县" + }, + { + "value": 1214, + "label": "平和县" + }, + { + "value": 1215, + "label": "华安县" + }, + { + "value": 1216, + "label": "龙海市" + }, + { + "value": 1206, + "label": "芗城区" + }, + { + "value": 1207, + "label": "龙文区" + }, + { + "value": 1208, + "label": "云霄县" + }, + { + "value": 1209, + "label": "漳浦县" + }, + { + "value": 1210, + "label": "诏安县" + } + ] + }, + { + "value": 1217, + "label": "南平市", + "children": [ + { + "value": 1218, + "label": "延平区" + }, + { + "value": 1219, + "label": "顺昌县" + }, + { + "value": 1220, + "label": "浦城县" + }, + { + "value": 1221, + "label": "光泽县" + }, + { + "value": 1222, + "label": "松溪县" + }, + { + "value": 1223, + "label": "政和县" + }, + { + "value": 1224, + "label": "邵武市" + }, + { + "value": 1225, + "label": "武夷山市" + }, + { + "value": 1226, + "label": "建瓯市" + }, + { + "value": 1227, + "label": "建阳市" + } + ] + }, + { + "value": 1228, + "label": "龙岩市", + "children": [ + { + "value": 1229, + "label": "新罗区" + }, + { + "value": 1230, + "label": "长汀县" + }, + { + "value": 1231, + "label": "永定县" + }, + { + "value": 1232, + "label": "上杭县" + }, + { + "value": 1233, + "label": "武平县" + }, + { + "value": 1234, + "label": "连城县" + }, + { + "value": 1235, + "label": "漳平市" + } + ] + }, + { + "value": 1236, + "label": "宁德市", + "children": [ + { + "value": 1243, + "label": "柘荣县" + }, + { + "value": 1244, + "label": "福安市" + }, + { + "value": 1245, + "label": "福鼎市" + }, + { + "value": 1237, + "label": "蕉城区" + }, + { + "value": 1238, + "label": "霞浦县" + }, + { + "value": 1239, + "label": "古田县" + }, + { + "value": 1240, + "label": "屏南县" + }, + { + "value": 1241, + "label": "寿宁县" + }, + { + "value": 1242, + "label": "周宁县" + } + ] + } + ] + }, + { + "value": 1246, + "label": "江西省", + "children": [ + { + "value": 1247, + "label": "南昌市", + "children": [ + { + "value": 1248, + "label": "东湖区" + }, + { + "value": 1249, + "label": "西湖区" + }, + { + "value": 1250, + "label": "青云谱区" + }, + { + "value": 1251, + "label": "湾里区" + }, + { + "value": 1252, + "label": "青山湖区" + }, + { + "value": 1253, + "label": "南昌县" + }, + { + "value": 1254, + "label": "新建县" + }, + { + "value": 1255, + "label": "安义县" + }, + { + "value": 1256, + "label": "进贤县" + } + ] + }, + { + "value": 1257, + "label": "景德镇市", + "children": [ + { + "value": 1258, + "label": "昌江区" + }, + { + "value": 1259, + "label": "珠山区" + }, + { + "value": 1260, + "label": "浮梁县" + }, + { + "value": 1261, + "label": "乐平市" + } + ] + }, + { + "value": 1262, + "label": "萍乡市", + "children": [ + { + "value": 1263, + "label": "安源区" + }, + { + "value": 1264, + "label": "湘东区" + }, + { + "value": 1265, + "label": "莲花县" + }, + { + "value": 1266, + "label": "上栗县" + }, + { + "value": 1267, + "label": "芦溪县" + } + ] + }, + { + "value": 1268, + "label": "九江市", + "children": [ + { + "value": 1269, + "label": "庐山区" + }, + { + "value": 1270, + "label": "浔阳区" + }, + { + "value": 1271, + "label": "九江县" + }, + { + "value": 1272, + "label": "武宁县" + }, + { + "value": 1273, + "label": "修水县" + }, + { + "value": 1274, + "label": "永修县" + }, + { + "value": 1281, + "label": "共青城市" + }, + { + "value": 1275, + "label": "德安县" + }, + { + "value": 1276, + "label": "星子县" + }, + { + "value": 1277, + "label": "都昌县" + }, + { + "value": 1278, + "label": "湖口县" + }, + { + "value": 1279, + "label": "彭泽县" + }, + { + "value": 1280, + "label": "瑞昌市" + } + ] + }, + { + "value": 1282, + "label": "新余市", + "children": [ + { + "value": 1283, + "label": "渝水区" + }, + { + "value": 1284, + "label": "分宜县" + } + ] + }, + { + "value": 1285, + "label": "鹰潭市", + "children": [ + { + "value": 1286, + "label": "月湖区" + }, + { + "value": 1287, + "label": "余江县" + }, + { + "value": 1288, + "label": "贵溪市" + } + ] + }, + { + "value": 1289, + "label": "赣州市", + "children": [ + { + "value": 1290, + "label": "章贡区" + }, + { + "value": 1291, + "label": "赣县" + }, + { + "value": 1292, + "label": "信丰县" + }, + { + "value": 1293, + "label": "大余县" + }, + { + "value": 1294, + "label": "上犹县" + }, + { + "value": 1295, + "label": "崇义县" + }, + { + "value": 1302, + "label": "兴国县" + }, + { + "value": 1303, + "label": "会昌县" + }, + { + "value": 1304, + "label": "寻乌县" + }, + { + "value": 1305, + "label": "石城县" + }, + { + "value": 1306, + "label": "瑞金市" + }, + { + "value": 1307, + "label": "南康市" + }, + { + "value": 1296, + "label": "安远县" + }, + { + "value": 1297, + "label": "龙南县" + }, + { + "value": 1298, + "label": "定南县" + }, + { + "value": 1299, + "label": "全南县" + }, + { + "value": 1300, + "label": "宁都县" + }, + { + "value": 1301, + "label": "于都县" + } + ] + }, + { + "value": 1308, + "label": "吉安市", + "children": [ + { + "value": 1309, + "label": "吉州区" + }, + { + "value": 1310, + "label": "青原区" + }, + { + "value": 1311, + "label": "吉安县" + }, + { + "value": 1312, + "label": "吉水县" + }, + { + "value": 1313, + "label": "峡江县" + }, + { + "value": 1314, + "label": "新干县" + }, + { + "value": 1321, + "label": "井冈山市" + }, + { + "value": 1315, + "label": "永丰县" + }, + { + "value": 1316, + "label": "泰和县" + }, + { + "value": 1317, + "label": "遂川县" + }, + { + "value": 1318, + "label": "万安县" + }, + { + "value": 1319, + "label": "安福县" + }, + { + "value": 1320, + "label": "永新县" + } + ] + }, + { + "value": 1322, + "label": "宜春市", + "children": [ + { + "value": 1323, + "label": "袁州区" + }, + { + "value": 1324, + "label": "奉新县" + }, + { + "value": 1325, + "label": "万载县" + }, + { + "value": 1326, + "label": "上高县" + }, + { + "value": 1327, + "label": "宜丰县" + }, + { + "value": 1328, + "label": "靖安县" + }, + { + "value": 1329, + "label": "铜鼓县" + }, + { + "value": 1330, + "label": "丰城市" + }, + { + "value": 1331, + "label": "樟树市" + }, + { + "value": 1332, + "label": "高安市" + } + ] + }, + { + "value": 1333, + "label": "抚州市", + "children": [ + { + "value": 1334, + "label": "临川区" + }, + { + "value": 1335, + "label": "南城县" + }, + { + "value": 1336, + "label": "黎川县" + }, + { + "value": 1337, + "label": "南丰县" + }, + { + "value": 1338, + "label": "崇仁县" + }, + { + "value": 1339, + "label": "乐安县" + }, + { + "value": 1340, + "label": "宜黄县" + }, + { + "value": 1341, + "label": "金溪县" + }, + { + "value": 1342, + "label": "资溪县" + }, + { + "value": 1343, + "label": "东乡县" + }, + { + "value": 1344, + "label": "广昌县" + } + ] + }, + { + "value": 1345, + "label": "上饶市", + "children": [ + { + "value": 1346, + "label": "信州区" + }, + { + "value": 1347, + "label": "上饶县" + }, + { + "value": 1348, + "label": "广丰县" + }, + { + "value": 1349, + "label": "玉山县" + }, + { + "value": 1350, + "label": "铅山县" + }, + { + "value": 1351, + "label": "横峰县" + }, + { + "value": 1352, + "label": "弋阳县" + }, + { + "value": 1353, + "label": "余干县" + }, + { + "value": 1354, + "label": "鄱阳县" + }, + { + "value": 1355, + "label": "万年县" + }, + { + "value": 1356, + "label": "婺源县" + }, + { + "value": 1357, + "label": "德兴市" + } + ] + } + ] + }, + { + "value": 1358, + "label": "山东省", + "children": [ + { + "value": 1359, + "label": "济南市", + "children": [ + { + "value": 1360, + "label": "历下区" + }, + { + "value": 1361, + "label": "市中区" + }, + { + "value": 1362, + "label": "槐荫区" + }, + { + "value": 1363, + "label": "天桥区" + }, + { + "value": 1364, + "label": "历城区" + }, + { + "value": 1365, + "label": "长清区" + }, + { + "value": 1366, + "label": "平阴县" + }, + { + "value": 1367, + "label": "济阳县" + }, + { + "value": 1368, + "label": "商河县" + }, + { + "value": 1369, + "label": "章丘市" + } + ] + }, + { + "value": 1370, + "label": "青岛市", + "children": [ + { + "value": 1371, + "label": "市南区" + }, + { + "value": 1372, + "label": "市北区" + }, + { + "value": 1373, + "label": "四方区" + }, + { + "value": 1374, + "label": "黄岛区" + }, + { + "value": 1375, + "label": "崂山区" + }, + { + "value": 1376, + "label": "李沧区" + }, + { + "value": 1377, + "label": "城阳区" + }, + { + "value": 1378, + "label": "胶州市" + }, + { + "value": 1379, + "label": "即墨市" + }, + { + "value": 1380, + "label": "平度市" + }, + { + "value": 1381, + "label": "胶南市" + }, + { + "value": 1382, + "label": "莱西市" + } + ] + }, + { + "value": 1383, + "label": "淄博市", + "children": [ + { + "value": 1384, + "label": "淄川区" + }, + { + "value": 1385, + "label": "张店区" + }, + { + "value": 1386, + "label": "博山区" + }, + { + "value": 1387, + "label": "临淄区" + }, + { + "value": 1388, + "label": "周村区" + }, + { + "value": 1389, + "label": "桓台县" + }, + { + "value": 1390, + "label": "高青县" + }, + { + "value": 1391, + "label": "沂源县" + } + ] + }, + { + "value": 1392, + "label": "枣庄市", + "children": [ + { + "value": 1393, + "label": "市中区" + }, + { + "value": 1394, + "label": "薛城区" + }, + { + "value": 1395, + "label": "峄城区" + }, + { + "value": 1396, + "label": "台儿庄区" + }, + { + "value": 1397, + "label": "山亭区" + }, + { + "value": 1398, + "label": "滕州市" + } + ] + }, + { + "value": 1399, + "label": "东营市", + "children": [ + { + "value": 1400, + "label": "东营区" + }, + { + "value": 1401, + "label": "河口区" + }, + { + "value": 1402, + "label": "垦利县" + }, + { + "value": 1403, + "label": "利津县" + }, + { + "value": 1404, + "label": "广饶县" + } + ] + }, + { + "value": 1405, + "label": "烟台市", + "children": [ + { + "value": 1406, + "label": "芝罘区" + }, + { + "value": 1407, + "label": "福山区" + }, + { + "value": 1408, + "label": "牟平区" + }, + { + "value": 1409, + "label": "莱山区" + }, + { + "value": 1410, + "label": "长岛县" + }, + { + "value": 1411, + "label": "龙口市" + }, + { + "value": 1412, + "label": "莱阳市" + }, + { + "value": 1413, + "label": "莱州市" + }, + { + "value": 1414, + "label": "蓬莱市" + }, + { + "value": 1415, + "label": "招远市" + }, + { + "value": 1416, + "label": "栖霞市" + }, + { + "value": 1417, + "label": "海阳市" + } + ] + }, + { + "value": 1418, + "label": "潍坊市", + "children": [ + { + "value": 1419, + "label": "潍城区" + }, + { + "value": 1420, + "label": "寒亭区" + }, + { + "value": 1421, + "label": "坊子区" + }, + { + "value": 1422, + "label": "奎文区" + }, + { + "value": 1423, + "label": "临朐县" + }, + { + "value": 1424, + "label": "昌乐县" + }, + { + "value": 1425, + "label": "青州市" + }, + { + "value": 1426, + "label": "诸城市" + }, + { + "value": 1427, + "label": "寿光市" + }, + { + "value": 1428, + "label": "安丘市" + }, + { + "value": 1429, + "label": "高密市" + }, + { + "value": 1430, + "label": "昌邑市" + } + ] + }, + { + "value": 1431, + "label": "济宁市", + "children": [ + { + "value": 1432, + "label": "市中区" + }, + { + "value": 1433, + "label": "任城区" + }, + { + "value": 1434, + "label": "微山县" + }, + { + "value": 1435, + "label": "鱼台县" + }, + { + "value": 1436, + "label": "金乡县" + }, + { + "value": 1437, + "label": "嘉祥县" + }, + { + "value": 1438, + "label": "汶上县" + }, + { + "value": 1439, + "label": "泗水县" + }, + { + "value": 1440, + "label": "梁山县" + }, + { + "value": 1441, + "label": "曲阜市" + }, + { + "value": 1442, + "label": "兖州市" + }, + { + "value": 1443, + "label": "邹城市" + } + ] + }, + { + "value": 1444, + "label": "泰安市", + "children": [ + { + "value": 1445, + "label": "泰山区" + }, + { + "value": 1446, + "label": "岱岳区" + }, + { + "value": 1447, + "label": "宁阳县" + }, + { + "value": 1448, + "label": "东平县" + }, + { + "value": 1449, + "label": "新泰市" + }, + { + "value": 1450, + "label": "肥城市" + } + ] + }, + { + "value": 1451, + "label": "威海市", + "children": [ + { + "value": 1452, + "label": "环翠区" + }, + { + "value": 1453, + "label": "文登市" + }, + { + "value": 1454, + "label": "荣成市" + }, + { + "value": 1455, + "label": "乳山市" + } + ] + }, + { + "value": 1456, + "label": "日照市", + "children": [ + { + "value": 1457, + "label": "东港区" + }, + { + "value": 1458, + "label": "岚山区" + }, + { + "value": 1459, + "label": "五莲县" + }, + { + "value": 1460, + "label": "莒县" + } + ] + }, + { + "value": 1461, + "label": "莱芜市", + "children": [ + { + "value": 1462, + "label": "莱城区" + }, + { + "value": 1463, + "label": "钢城区" + } + ] + }, + { + "value": 1464, + "label": "临沂市", + "children": [ + { + "value": 1465, + "label": "兰山区" + }, + { + "value": 1466, + "label": "罗庄区" + }, + { + "value": 1467, + "label": "河东区" + }, + { + "value": 1468, + "label": "沂南县" + }, + { + "value": 1469, + "label": "郯城县" + }, + { + "value": 1470, + "label": "沂水县" + }, + { + "value": 1471, + "label": "苍山县" + }, + { + "value": 1472, + "label": "费县" + }, + { + "value": 1473, + "label": "平邑县" + }, + { + "value": 1474, + "label": "莒南县" + }, + { + "value": 1475, + "label": "蒙阴县" + }, + { + "value": 1476, + "label": "临沭县" + } + ] + }, + { + "value": 1477, + "label": "德州市", + "children": [ + { + "value": 1478, + "label": "德城区" + }, + { + "value": 1479, + "label": "陵县" + }, + { + "value": 1480, + "label": "宁津县" + }, + { + "value": 1481, + "label": "庆云县" + }, + { + "value": 1482, + "label": "临邑县" + }, + { + "value": 1483, + "label": "齐河县" + }, + { + "value": 1484, + "label": "平原县" + }, + { + "value": 1485, + "label": "夏津县" + }, + { + "value": 1486, + "label": "武城县" + }, + { + "value": 1487, + "label": "乐陵市" + }, + { + "value": 1488, + "label": "禹城市" + } + ] + }, + { + "value": 1489, + "label": "聊城市", + "children": [ + { + "value": 1490, + "label": "东昌府区" + }, + { + "value": 1491, + "label": "阳谷县" + }, + { + "value": 1492, + "label": "莘县" + }, + { + "value": 1493, + "label": "茌平县" + }, + { + "value": 1494, + "label": "东阿县" + }, + { + "value": 1495, + "label": "冠县" + }, + { + "value": 1496, + "label": "高唐县" + }, + { + "value": 1497, + "label": "临清市" + } + ] + }, + { + "value": 1498, + "label": "滨州市", + "children": [ + { + "value": 1499, + "label": "滨城区" + }, + { + "value": 1500, + "label": "惠民县" + }, + { + "value": 1501, + "label": "阳信县" + }, + { + "value": 1502, + "label": "无棣县" + }, + { + "value": 1503, + "label": "沾化县" + }, + { + "value": 1504, + "label": "博兴县" + }, + { + "value": 1505, + "label": "邹平县" + } + ] + }, + { + "value": 1506, + "label": "菏泽市", + "children": [ + { + "value": 1507, + "label": "牡丹区" + }, + { + "value": 1508, + "label": "曹县" + }, + { + "value": 1509, + "label": "单县" + }, + { + "value": 1510, + "label": "成武县" + }, + { + "value": 1511, + "label": "巨野县" + }, + { + "value": 1512, + "label": "郓城县" + }, + { + "value": 1513, + "label": "鄄城县" + }, + { + "value": 1514, + "label": "定陶县" + }, + { + "value": 1515, + "label": "东明县" + } + ] + } + ] + }, + { + "value": 1516, + "label": "河南省", + "children": [ + { + "value": 1517, + "label": "郑州市", + "children": [ + { + "value": 1518, + "label": "中原区" + }, + { + "value": 1519, + "label": "二七区" + }, + { + "value": 1520, + "label": "管城回族区" + }, + { + "value": 1521, + "label": "金水区" + }, + { + "value": 1522, + "label": "上街区" + }, + { + "value": 1523, + "label": "惠济区" + }, + { + "value": 1524, + "label": "中牟县" + }, + { + "value": 1525, + "label": "巩义市" + }, + { + "value": 1526, + "label": "荥阳市" + }, + { + "value": 1527, + "label": "新密市" + }, + { + "value": 1528, + "label": "新郑市" + }, + { + "value": 1529, + "label": "登封市" + } + ] + }, + { + "value": 1530, + "label": "开封市", + "children": [ + { + "value": 1538, + "label": "尉氏县" + }, + { + "value": 1539, + "label": "开封县" + }, + { + "value": 1540, + "label": "兰考县" + }, + { + "value": 1532, + "label": "顺河回族区" + }, + { + "value": 1533, + "label": "鼓楼区" + }, + { + "value": 1534, + "label": "禹王台区" + }, + { + "value": 1535, + "label": "金明区" + }, + { + "value": 1536, + "label": "杞县" + }, + { + "value": 1537, + "label": "通许县" + }, + { + "value": 1531, + "label": "龙亭区" + } + ] + }, + { + "value": 1541, + "label": "洛阳市", + "children": [ + { + "value": 1542, + "label": "老城区" + }, + { + "value": 1543, + "label": "西工区" + }, + { + "value": 1544, + "label": "瀍河回族区" + }, + { + "value": 1545, + "label": "涧西区" + }, + { + "value": 1546, + "label": "吉利区" + }, + { + "value": 1547, + "label": "洛龙区" + }, + { + "value": 1554, + "label": "洛宁县" + }, + { + "value": 1555, + "label": "伊川县" + }, + { + "value": 1556, + "label": "偃师市" + }, + { + "value": 1548, + "label": "孟津县" + }, + { + "value": 1549, + "label": "新安县" + }, + { + "value": 1550, + "label": "栾川县" + }, + { + "value": 1551, + "label": "嵩县" + }, + { + "value": 1552, + "label": "汝阳县" + }, + { + "value": 1553, + "label": "宜阳县" + } + ] + }, + { + "value": 1557, + "label": "平顶山市", + "children": [ + { + "value": 1558, + "label": "新华区" + }, + { + "value": 1559, + "label": "卫东区" + }, + { + "value": 1560, + "label": "石龙区" + }, + { + "value": 1561, + "label": "湛河区" + }, + { + "value": 1562, + "label": "宝丰县" + }, + { + "value": 1563, + "label": "叶县" + }, + { + "value": 1564, + "label": "鲁山县" + }, + { + "value": 1565, + "label": "郏县" + }, + { + "value": 1566, + "label": "舞钢市" + }, + { + "value": 1567, + "label": "汝州市" + } + ] + }, + { + "value": 1568, + "label": "安阳市", + "children": [ + { + "value": 1572, + "label": "龙安区" + }, + { + "value": 1573, + "label": "安阳县" + }, + { + "value": 1574, + "label": "汤阴县" + }, + { + "value": 1575, + "label": "滑县" + }, + { + "value": 1576, + "label": "内黄县" + }, + { + "value": 1577, + "label": "林州市" + }, + { + "value": 1569, + "label": "文峰区" + }, + { + "value": 1570, + "label": "北关区" + }, + { + "value": 1571, + "label": "殷都区" + } + ] + }, + { + "value": 1578, + "label": "鹤壁市", + "children": [ + { + "value": 1579, + "label": "鹤山区" + }, + { + "value": 1580, + "label": "山城区" + }, + { + "value": 1581, + "label": "淇滨区" + }, + { + "value": 1582, + "label": "浚县" + }, + { + "value": 1583, + "label": "淇县" + } + ] + }, + { + "value": 1584, + "label": "新乡市", + "children": [ + { + "value": 1585, + "label": "红旗区" + }, + { + "value": 1586, + "label": "卫滨区" + }, + { + "value": 1587, + "label": "凤泉区" + }, + { + "value": 1588, + "label": "牧野区" + }, + { + "value": 1589, + "label": "新乡县" + }, + { + "value": 1590, + "label": "获嘉县" + }, + { + "value": 1591, + "label": "原阳县" + }, + { + "value": 1592, + "label": "延津县" + }, + { + "value": 1593, + "label": "封丘县" + }, + { + "value": 1594, + "label": "长垣县" + }, + { + "value": 1595, + "label": "卫辉市" + }, + { + "value": 1596, + "label": "辉县市" + } + ] + }, + { + "value": 1597, + "label": "焦作市", + "children": [ + { + "value": 1598, + "label": "解放区" + }, + { + "value": 1599, + "label": "中站区" + }, + { + "value": 1600, + "label": "马村区" + }, + { + "value": 1601, + "label": "山阳区" + }, + { + "value": 1602, + "label": "修武县" + }, + { + "value": 1603, + "label": "博爱县" + }, + { + "value": 1604, + "label": "武陟县" + }, + { + "value": 1605, + "label": "温县" + }, + { + "value": 1606, + "label": "沁阳市" + }, + { + "value": 1607, + "label": "孟州市" + } + ] + }, + { + "value": 1608, + "label": "濮阳市", + "children": [ + { + "value": 1609, + "label": "华龙区" + }, + { + "value": 1610, + "label": "清丰县" + }, + { + "value": 1611, + "label": "南乐县" + }, + { + "value": 1612, + "label": "范县" + }, + { + "value": 1613, + "label": "台前县" + }, + { + "value": 1614, + "label": "濮阳县" + } + ] + }, + { + "value": 1615, + "label": "许昌市", + "children": [ + { + "value": 1616, + "label": "魏都区" + }, + { + "value": 1617, + "label": "许昌县" + }, + { + "value": 1618, + "label": "鄢陵县" + }, + { + "value": 1619, + "label": "襄城县" + }, + { + "value": 1620, + "label": "禹州市" + }, + { + "value": 1621, + "label": "长葛市" + } + ] + }, + { + "value": 1622, + "label": "漯河市", + "children": [ + { + "value": 1623, + "label": "源汇区" + }, + { + "value": 1624, + "label": "郾城区" + }, + { + "value": 1625, + "label": "召陵区" + }, + { + "value": 1626, + "label": "舞阳县" + }, + { + "value": 1627, + "label": "临颍县" + } + ] + }, + { + "value": 1628, + "label": "三门峡市", + "children": [ + { + "value": 1629, + "label": "湖滨区" + }, + { + "value": 1630, + "label": "渑池县" + }, + { + "value": 1631, + "label": "陕县" + }, + { + "value": 1632, + "label": "卢氏县" + }, + { + "value": 1633, + "label": "义马市" + }, + { + "value": 1634, + "label": "灵宝市" + } + ] + }, + { + "value": 1635, + "label": "南阳市", + "children": [ + { + "value": 1636, + "label": "宛城区" + }, + { + "value": 1637, + "label": "卧龙区" + }, + { + "value": 1638, + "label": "南召县" + }, + { + "value": 1639, + "label": "方城县" + }, + { + "value": 1640, + "label": "西峡县" + }, + { + "value": 1641, + "label": "镇平县" + }, + { + "value": 1648, + "label": "邓州市" + }, + { + "value": 1642, + "label": "内乡县" + }, + { + "value": 1643, + "label": "淅川县" + }, + { + "value": 1644, + "label": "社旗县" + }, + { + "value": 1645, + "label": "唐河县" + }, + { + "value": 1646, + "label": "新野县" + }, + { + "value": 1647, + "label": "桐柏县" + } + ] + }, + { + "value": 1649, + "label": "商丘市", + "children": [ + { + "value": 1650, + "label": "梁园区" + }, + { + "value": 1651, + "label": "睢阳区" + }, + { + "value": 1652, + "label": "民权县" + }, + { + "value": 1653, + "label": "睢县" + }, + { + "value": 1654, + "label": "宁陵县" + }, + { + "value": 1655, + "label": "柘城县" + }, + { + "value": 1656, + "label": "虞城县" + }, + { + "value": 1657, + "label": "夏邑县" + }, + { + "value": 1658, + "label": "永城市" + } + ] + }, + { + "value": 1659, + "label": "信阳市", + "children": [ + { + "value": 1660, + "label": "浉河区" + }, + { + "value": 1661, + "label": "平桥区" + }, + { + "value": 1662, + "label": "罗山县" + }, + { + "value": 1663, + "label": "光山县" + }, + { + "value": 1664, + "label": "新县" + }, + { + "value": 1665, + "label": "商城县" + }, + { + "value": 1666, + "label": "固始县" + }, + { + "value": 1667, + "label": "潢川县" + }, + { + "value": 1668, + "label": "淮滨县" + }, + { + "value": 1669, + "label": "息县" + } + ] + }, + { + "value": 1670, + "label": "周口市", + "children": [ + { + "value": 1671, + "label": "川汇区" + }, + { + "value": 1672, + "label": "扶沟县" + }, + { + "value": 1673, + "label": "西华县" + }, + { + "value": 1674, + "label": "商水县" + }, + { + "value": 1675, + "label": "沈丘县" + }, + { + "value": 1676, + "label": "郸城县" + }, + { + "value": 1677, + "label": "淮阳县" + }, + { + "value": 1678, + "label": "太康县" + }, + { + "value": 1679, + "label": "鹿邑县" + }, + { + "value": 1680, + "label": "项城市" + } + ] + }, + { + "value": 1681, + "label": "驻马店市", + "children": [ + { + "value": 1682, + "label": "驿城区" + }, + { + "value": 1683, + "label": "西平县" + }, + { + "value": 1684, + "label": "上蔡县" + }, + { + "value": 1685, + "label": "平舆县" + }, + { + "value": 1686, + "label": "正阳县" + }, + { + "value": 1687, + "label": "确山县" + }, + { + "value": 1688, + "label": "泌阳县" + }, + { + "value": 1689, + "label": "汝南县" + }, + { + "value": 1690, + "label": "遂平县" + }, + { + "value": 1691, + "label": "新蔡县" + } + ] + }, + { + "value": 1692, + "label": "济源市", + "children": [ + ] + } + ] + }, + { + "value": 1693, + "label": "湖北省", + "children": [ + { + "value": 1694, + "label": "武汉市", + "children": [ + { + "value": 1695, + "label": "江岸区" + }, + { + "value": 1696, + "label": "江汉区" + }, + { + "value": 1697, + "label": "硚口区" + }, + { + "value": 1698, + "label": "汉阳区" + }, + { + "value": 1699, + "label": "武昌区" + }, + { + "value": 1700, + "label": "青山区" + }, + { + "value": 1707, + "label": "新洲区" + }, + { + "value": 1701, + "label": "洪山区" + }, + { + "value": 1702, + "label": "东西湖区" + }, + { + "value": 1703, + "label": "汉南区" + }, + { + "value": 1704, + "label": "蔡甸区" + }, + { + "value": 1705, + "label": "江夏区" + }, + { + "value": 1706, + "label": "黄陂区" + } + ] + }, + { + "value": 1708, + "label": "黄石市", + "children": [ + { + "value": 1709, + "label": "黄石港区" + }, + { + "value": 1710, + "label": "西塞山区" + }, + { + "value": 1711, + "label": "下陆区" + }, + { + "value": 1712, + "label": "铁山区" + }, + { + "value": 1713, + "label": "阳新县" + }, + { + "value": 1714, + "label": "大冶市" + } + ] + }, + { + "value": 1715, + "label": "十堰市", + "children": [ + { + "value": 1716, + "label": "茅箭区" + }, + { + "value": 1717, + "label": "张湾区" + }, + { + "value": 1718, + "label": "郧县" + }, + { + "value": 1719, + "label": "郧西县" + }, + { + "value": 1720, + "label": "竹山县" + }, + { + "value": 1721, + "label": "竹溪县" + }, + { + "value": 1722, + "label": "房县" + }, + { + "value": 1723, + "label": "丹江口市" + } + ] + }, + { + "value": 1724, + "label": "宜昌市", + "children": [ + { + "value": 1725, + "label": "西陵区" + }, + { + "value": 1726, + "label": "伍家岗区" + }, + { + "value": 1727, + "label": "点军区" + }, + { + "value": 1728, + "label": "猇亭区" + }, + { + "value": 1729, + "label": "夷陵区" + }, + { + "value": 1730, + "label": "远安县" + }, + { + "value": 1737, + "label": "枝江市" + }, + { + "value": 1731, + "label": "兴山县" + }, + { + "value": 1732, + "label": "秭归县" + }, + { + "value": 1733, + "label": "长阳土家族自治县" + }, + { + "value": 1734, + "label": "五峰土家族自治县" + }, + { + "value": 1735, + "label": "宜都市" + }, + { + "value": 1736, + "label": "当阳市" + } + ] + }, + { + "value": 1738, + "label": "襄阳市", + "children": [ + { + "value": 1739, + "label": "襄城区" + }, + { + "value": 1740, + "label": "樊城区" + }, + { + "value": 1741, + "label": "襄州区" + }, + { + "value": 1742, + "label": "南漳县" + }, + { + "value": 1743, + "label": "谷城县" + }, + { + "value": 1744, + "label": "保康县" + }, + { + "value": 1745, + "label": "老河口市" + }, + { + "value": 1746, + "label": "枣阳市" + }, + { + "value": 1747, + "label": "宜城市" + } + ] + }, + { + "value": 1748, + "label": "鄂州市", + "children": [ + { + "value": 1749, + "label": "梁子湖区" + }, + { + "value": 1750, + "label": "华容区" + }, + { + "value": 1751, + "label": "鄂城区" + } + ] + }, + { + "value": 1752, + "label": "荆门市", + "children": [ + { + "value": 1753, + "label": "东宝区" + }, + { + "value": 1754, + "label": "掇刀区" + }, + { + "value": 1755, + "label": "京山县" + }, + { + "value": 1756, + "label": "沙洋县" + }, + { + "value": 1757, + "label": "钟祥市" + } + ] + }, + { + "value": 1758, + "label": "孝感市", + "children": [ + { + "value": 1759, + "label": "孝南区" + }, + { + "value": 1760, + "label": "孝昌县" + }, + { + "value": 1761, + "label": "大悟县" + }, + { + "value": 1762, + "label": "云梦县" + }, + { + "value": 1763, + "label": "应城市" + }, + { + "value": 1764, + "label": "安陆市" + }, + { + "value": 1765, + "label": "汉川市" + } + ] + }, + { + "value": 1766, + "label": "荆州市", + "children": [ + { + "value": 1767, + "label": "沙市区" + }, + { + "value": 1768, + "label": "荆州区" + }, + { + "value": 1769, + "label": "公安县" + }, + { + "value": 1770, + "label": "监利县" + }, + { + "value": 1771, + "label": "江陵县" + }, + { + "value": 1772, + "label": "石首市" + }, + { + "value": 1773, + "label": "洪湖市" + }, + { + "value": 1774, + "label": "松滋市" + } + ] + }, + { + "value": 1775, + "label": "黄冈市", + "children": [ + { + "value": 1776, + "label": "黄州区" + }, + { + "value": 1777, + "label": "团风县" + }, + { + "value": 1778, + "label": "红安县" + }, + { + "value": 1779, + "label": "罗田县" + }, + { + "value": 1780, + "label": "英山县" + }, + { + "value": 1781, + "label": "浠水县" + }, + { + "value": 1782, + "label": "蕲春县" + }, + { + "value": 1783, + "label": "黄梅县" + }, + { + "value": 1784, + "label": "麻城市" + }, + { + "value": 1785, + "label": "武穴市" + } + ] + }, + { + "value": 1786, + "label": "咸宁市", + "children": [ + { + "value": 1787, + "label": "咸安区" + }, + { + "value": 1788, + "label": "嘉鱼县" + }, + { + "value": 1789, + "label": "通城县" + }, + { + "value": 1790, + "label": "崇阳县" + }, + { + "value": 1791, + "label": "通山县" + }, + { + "value": 1792, + "label": "赤壁市" + } + ] + }, + { + "value": 1793, + "label": "随州市", + "children": [ + { + "value": 1794, + "label": "曾都区" + }, + { + "value": 1795, + "label": "随县" + }, + { + "value": 1796, + "label": "广水市" + } + ] + }, + { + "value": 1797, + "label": "恩施土家族苗族自治州", + "children": [ + { + "value": 1800, + "label": "建始县" + }, + { + "value": 1801, + "label": "巴东县" + }, + { + "value": 1802, + "label": "宣恩县" + }, + { + "value": 1803, + "label": "咸丰县" + }, + { + "value": 1804, + "label": "来凤县" + }, + { + "value": 1805, + "label": "鹤峰县" + }, + { + "value": 1798, + "label": "恩施市" + }, + { + "value": 1799, + "label": "利川市" + } + ] + }, + { + "value": 1806, + "label": "仙桃市" + }, + { + "value": 1807, + "label": "潜江市" + }, + { + "value": 1808, + "label": "天门市" + }, + { + "value": 1809, + "label": "神农架林区" + } + ] + }, + { + "value": 1810, + "label": "湖南省", + "children": [ + { + "value": 1811, + "label": "长沙市", + "children": [ + { + "value": 1817, + "label": "望城区" + }, + { + "value": 1818, + "label": "长沙县" + }, + { + "value": 1819, + "label": "宁乡县" + }, + { + "value": 1820, + "label": "浏阳市" + }, + { + "value": 1812, + "label": "芙蓉区" + }, + { + "value": 1813, + "label": "天心区" + }, + { + "value": 1814, + "label": "岳麓区" + }, + { + "value": 1815, + "label": "开福区" + }, + { + "value": 1816, + "label": "雨花区" + } + ] + }, + { + "value": 1821, + "label": "株洲市", + "children": [ + { + "value": 1822, + "label": "荷塘区" + }, + { + "value": 1823, + "label": "芦淞区" + }, + { + "value": 1824, + "label": "石峰区" + }, + { + "value": 1825, + "label": "天元区" + }, + { + "value": 1826, + "label": "株洲县" + }, + { + "value": 1827, + "label": "攸县" + }, + { + "value": 1828, + "label": "茶陵县" + }, + { + "value": 1829, + "label": "炎陵县" + }, + { + "value": 1830, + "label": "醴陵市" + } + ] + }, + { + "value": 1831, + "label": "湘潭市", + "children": [ + { + "value": 1832, + "label": "雨湖区" + }, + { + "value": 1833, + "label": "岳塘区" + }, + { + "value": 1834, + "label": "湘潭县" + }, + { + "value": 1835, + "label": "湘乡市" + }, + { + "value": 1836, + "label": "韶山市" + }, + { + "value": 1837, + "label": "衡阳市" + }, + { + "value": 1844, + "label": "衡南县" + }, + { + "value": 1845, + "label": "衡山县" + }, + { + "value": 1846, + "label": "衡东县" + }, + { + "value": 1847, + "label": "祁东县" + }, + { + "value": 1848, + "label": "耒阳市" + }, + { + "value": 1849, + "label": "常宁市" + }, + { + "value": 1838, + "label": "珠晖区" + }, + { + "value": 1839, + "label": "雁峰区" + }, + { + "value": 1840, + "label": "石鼓区" + }, + { + "value": 1841, + "label": "蒸湘区" + }, + { + "value": 1842, + "label": "南岳区" + }, + { + "value": 1843, + "label": "衡阳县" + } + ] + }, + { + "value": 1850, + "label": "邵阳市", + "children": [ + { + "value": 1851, + "label": "双清区" + }, + { + "value": 1852, + "label": "大祥区" + }, + { + "value": 1853, + "label": "北塔区" + }, + { + "value": 1854, + "label": "邵东县" + }, + { + "value": 1855, + "label": "新邵县" + }, + { + "value": 1856, + "label": "邵阳县" + }, + { + "value": 1857, + "label": "隆回县" + }, + { + "value": 1858, + "label": "洞口县" + }, + { + "value": 1859, + "label": "绥宁县" + }, + { + "value": 1860, + "label": "新宁县" + }, + { + "value": 1861, + "label": "城步苗族自治县" + }, + { + "value": 1862, + "label": "武冈市" + } + ] + }, + { + "value": 1863, + "label": "岳阳市", + "children": [ + { + "value": 1864, + "label": "岳阳楼区" + }, + { + "value": 1865, + "label": "云溪区" + }, + { + "value": 1866, + "label": "君山区" + }, + { + "value": 1867, + "label": "岳阳县" + }, + { + "value": 1868, + "label": "华容县" + }, + { + "value": 1869, + "label": "湘阴县" + }, + { + "value": 1870, + "label": "平江县" + }, + { + "value": 1871, + "label": "汨罗市" + }, + { + "value": 1872, + "label": "临湘市" + } + ] + }, + { + "value": 1873, + "label": "常德市", + "children": [ + { + "value": 1877, + "label": "汉寿县" + }, + { + "value": 1878, + "label": "澧县" + }, + { + "value": 1879, + "label": "临澧县" + }, + { + "value": 1880, + "label": "桃源县" + }, + { + "value": 1881, + "label": "石门县" + }, + { + "value": 1882, + "label": "津市市" + }, + { + "value": 1874, + "label": "武陵区" + }, + { + "value": 1875, + "label": "鼎城区" + }, + { + "value": 1876, + "label": "安乡县" + } + ] + }, + { + "value": 1883, + "label": "张家界市", + "children": [ + { + "value": 1884, + "label": "永定区" + }, + { + "value": 1885, + "label": "武陵源区" + }, + { + "value": 1886, + "label": "慈利县" + }, + { + "value": 1887, + "label": "桑植县" + } + ] + }, + { + "value": 1888, + "label": "益阳市", + "children": [ + { + "value": 1889, + "label": "资阳区" + }, + { + "value": 1890, + "label": "赫山区" + }, + { + "value": 1891, + "label": "南县" + }, + { + "value": 1892, + "label": "桃江县" + }, + { + "value": 1893, + "label": "安化县" + }, + { + "value": 1894, + "label": "沅江市" + } + ] + }, + { + "value": 1895, + "label": "郴州市", + "children": [ + { + "value": 1905, + "label": "安仁县" + }, + { + "value": 1906, + "label": "资兴市" + }, + { + "value": 1899, + "label": "宜章县" + }, + { + "value": 1900, + "label": "永兴县" + }, + { + "value": 1901, + "label": "嘉禾县" + }, + { + "value": 1902, + "label": "临武县" + }, + { + "value": 1903, + "label": "汝城县" + }, + { + "value": 1904, + "label": "桂东县" + }, + { + "value": 1896, + "label": "北湖区" + }, + { + "value": 1897, + "label": "苏仙区" + }, + { + "value": 1898, + "label": "桂阳县" + } + ] + }, + { + "value": 1907, + "label": "永州市", + "children": [ + { + "value": 1908, + "label": "零陵区" + }, + { + "value": 1909, + "label": "冷水滩区" + }, + { + "value": 1910, + "label": "祁阳县" + }, + { + "value": 1911, + "label": "东安县" + }, + { + "value": 1912, + "label": "双牌县" + }, + { + "value": 1913, + "label": "道县" + }, + { + "value": 1914, + "label": "江永县" + }, + { + "value": 1915, + "label": "宁远县" + }, + { + "value": 1916, + "label": "蓝山县" + }, + { + "value": 1917, + "label": "新田县" + }, + { + "value": 1918, + "label": "江华瑶族自治县" + } + ] + }, + { + "value": 1919, + "label": "怀化市", + "children": [ + { + "value": 1920, + "label": "鹤城区" + }, + { + "value": 1921, + "label": "中方县" + }, + { + "value": 1922, + "label": "沅陵县" + }, + { + "value": 1923, + "label": "辰溪县" + }, + { + "value": 1924, + "label": "溆浦县" + }, + { + "value": 1925, + "label": "会同县" + }, + { + "value": 1926, + "label": "麻阳苗族自治县" + }, + { + "value": 1927, + "label": "新晃侗族自治县" + }, + { + "value": 1928, + "label": "芷江侗族自治县" + }, + { + "value": 1929, + "label": "靖州苗族侗族自治县" + }, + { + "value": 1930, + "label": "通道侗族自治县" + }, + { + "value": 1931, + "label": "洪江市" + } + ] + }, + { + "value": 1932, + "label": "娄底市", + "children": [ + { + "value": 1933, + "label": "娄星区" + }, + { + "value": 1934, + "label": "双峰县" + }, + { + "value": 1935, + "label": "新化县" + }, + { + "value": 1936, + "label": "冷水江市" + }, + { + "value": 1937, + "label": "涟源市" + } + ] + }, + { + "value": 1938, + "label": "湘西土家族苗族自治州", + "children": [ + { + "value": 1939, + "label": "吉首市" + }, + { + "value": 1940, + "label": "泸溪县" + }, + { + "value": 1941, + "label": "凤凰县" + }, + { + "value": 1942, + "label": "花垣县" + }, + { + "value": 1943, + "label": "保靖县" + }, + { + "value": 1944, + "label": "古丈县" + }, + { + "value": 1945, + "label": "永顺县" + }, + { + "value": 1946, + "label": "龙山县" + } + ] + } + ] + }, + { + "value": 1947, + "label": "广东省", + "children": [ + { + "value": 1948, + "label": "广州市", + "children": [ + { + "value": 1949, + "label": "荔湾区" + }, + { + "value": 1950, + "label": "越秀区" + }, + { + "value": 1951, + "label": "海珠区" + }, + { + "value": 1952, + "label": "天河区" + }, + { + "value": 1953, + "label": "白云区" + }, + { + "value": 1954, + "label": "黄埔区" + }, + { + "value": 1955, + "label": "番禺区" + }, + { + "value": 1956, + "label": "花都区" + }, + { + "value": 1957, + "label": "南沙区" + }, + { + "value": 1958, + "label": "萝岗区" + }, + { + "value": 1959, + "label": "增城市" + }, + { + "value": 1960, + "label": "从化市" + } + ] + }, + { + "value": 1961, + "label": "韶关市", + "children": [ + { + "value": 1962, + "label": "武江区" + }, + { + "value": 1963, + "label": "浈江区" + }, + { + "value": 1964, + "label": "曲江区" + }, + { + "value": 1965, + "label": "始兴县" + }, + { + "value": 1966, + "label": "仁化县" + }, + { + "value": 1967, + "label": "翁源县" + }, + { + "value": 1968, + "label": "乳源瑶族自治县" + }, + { + "value": 1969, + "label": "新丰县" + }, + { + "value": 1970, + "label": "乐昌市" + }, + { + "value": 1971, + "label": "南雄市" + } + ] + }, + { + "value": 1972, + "label": "深圳市", + "children": [ + { + "value": 1973, + "label": "罗湖区" + }, + { + "value": 1974, + "label": "福田区" + }, + { + "value": 1975, + "label": "南山区" + }, + { + "value": 1976, + "label": "宝安区" + }, + { + "value": 1977, + "label": "龙岗区" + }, + { + "value": 1978, + "label": "盐田区" + } + ] + }, + { + "value": 1979, + "label": "珠海市", + "children": [ + { + "value": 1980, + "label": "香洲区" + }, + { + "value": 1981, + "label": "斗门区" + }, + { + "value": 1982, + "label": "金湾区" + } + ] + }, + { + "value": 1983, + "label": "汕头市", + "children": [ + { + "value": 1984, + "label": "龙湖区" + }, + { + "value": 1985, + "label": "金平区" + }, + { + "value": 1986, + "label": "濠江区" + }, + { + "value": 1987, + "label": "潮阳区" + }, + { + "value": 1988, + "label": "潮南区" + }, + { + "value": 1989, + "label": "澄海区" + }, + { + "value": 1990, + "label": "南澳县" + } + ] + }, + { + "value": 1991, + "label": "佛山市", + "children": [ + { + "value": 1992, + "label": "禅城区" + }, + { + "value": 1993, + "label": "南海区" + }, + { + "value": 1994, + "label": "顺德区" + }, + { + "value": 1995, + "label": "三水区" + }, + { + "value": 1996, + "label": "高明区" + } + ] + }, + { + "value": 1997, + "label": "江门市", + "children": [ + { + "value": 2000, + "label": "新会区" + }, + { + "value": 2001, + "label": "台山市" + }, + { + "value": 2002, + "label": "开平市" + }, + { + "value": 2003, + "label": "鹤山市" + }, + { + "value": 2004, + "label": "恩平市" + }, + { + "value": 1998, + "label": "蓬江区" + }, + { + "value": 1999, + "label": "江海区" + } + ] + }, + { + "value": 2005, + "label": "湛江市", + "children": [ + { + "value": 2012, + "label": "廉江市" + }, + { + "value": 2013, + "label": "雷州市" + }, + { + "value": 2014, + "label": "吴川市" + }, + { + "value": 2006, + "label": "赤坎区" + }, + { + "value": 2007, + "label": "霞山区" + }, + { + "value": 2008, + "label": "坡头区" + }, + { + "value": 2009, + "label": "麻章区" + }, + { + "value": 2010, + "label": "遂溪县" + }, + { + "value": 2011, + "label": "徐闻县" + } + ] + }, + { + "value": 2015, + "label": "茂名市", + "children": [ + { + "value": 2016, + "label": "茂南区" + }, + { + "value": 2017, + "label": "茂港区" + }, + { + "value": 2018, + "label": "电白县" + }, + { + "value": 2019, + "label": "高州市" + }, + { + "value": 2020, + "label": "化州市" + }, + { + "value": 2021, + "label": "信宜市" + } + ] + }, + { + "value": 2022, + "label": "肇庆市", + "children": [ + { + "value": 2023, + "label": "端州区" + }, + { + "value": 2024, + "label": "鼎湖区" + }, + { + "value": 2025, + "label": "广宁县" + }, + { + "value": 2026, + "label": "怀集县" + }, + { + "value": 2027, + "label": "封开县" + }, + { + "value": 2028, + "label": "德庆县" + }, + { + "value": 2029, + "label": "高要市" + }, + { + "value": 2030, + "label": "四会市" + } + ] + }, + { + "value": 2031, + "label": "惠州市", + "children": [ + { + "value": 2032, + "label": "惠城区" + }, + { + "value": 2033, + "label": "惠阳区" + }, + { + "value": 2034, + "label": "博罗县" + }, + { + "value": 2035, + "label": "惠东县" + }, + { + "value": 2036, + "label": "龙门县" + } + ] + }, + { + "value": 2037, + "label": "梅州市", + "children": [ + { + "value": 2038, + "label": "梅江区" + }, + { + "value": 2039, + "label": "梅县" + }, + { + "value": 2040, + "label": "大埔县" + }, + { + "value": 2041, + "label": "丰顺县" + }, + { + "value": 2042, + "label": "五华县" + }, + { + "value": 2043, + "label": "平远县" + }, + { + "value": 2044, + "label": "蕉岭县" + }, + { + "value": 2045, + "label": "兴宁市" + } + ] + }, + { + "value": 2046, + "label": "汕尾市", + "children": [ + { + "value": 2047, + "label": "城区" + }, + { + "value": 2048, + "label": "海丰县" + }, + { + "value": 2049, + "label": "陆河县" + }, + { + "value": 2050, + "label": "陆丰市" + } + ] + }, + { + "value": 2051, + "label": "河源市", + "children": [ + { + "value": 2052, + "label": "源城区" + }, + { + "value": 2053, + "label": "紫金县" + }, + { + "value": 2054, + "label": "龙川县" + }, + { + "value": 2055, + "label": "连平县" + }, + { + "value": 2056, + "label": "和平县" + }, + { + "value": 2057, + "label": "东源县" + } + ] + }, + { + "value": 2058, + "label": "阳江市", + "children": [ + { + "value": 2059, + "label": "江城区" + }, + { + "value": 2060, + "label": "阳西县" + }, + { + "value": 2061, + "label": "阳东县" + }, + { + "value": 2062, + "label": "阳春市" + }, + { + "value": 2064, + "label": "清城区" + }, + { + "value": 2065, + "label": "佛冈县" + }, + { + "value": 2066, + "label": "阳山县" + }, + { + "value": 2067, + "label": "连山壮族瑶族自治县" + }, + { + "value": 2068, + "label": "连南瑶族自治县" + }, + { + "value": 2069, + "label": "清新县" + }, + { + "value": 2070, + "label": "英德市" + }, + { + "value": 2071, + "label": "连州市" + } + ] + }, + { + "value": 2063, + "label": "清远市" + }, + { + "value": 2072, + "label": "东莞市" + }, + { + "value": 2073, + "label": "中山市" + }, + { + "value": 2074, + "label": "潮州市", + "children": [ + { + "value": 2075, + "label": "湘桥区" + }, + { + "value": 2076, + "label": "潮安县" + }, + { + "value": 2077, + "label": "饶平县" + } + ] + }, + { + "value": 2078, + "label": "揭阳市", + "children": [ + { + "value": 2079, + "label": "榕城区" + }, + { + "value": 2080, + "label": "揭东县" + }, + { + "value": 2081, + "label": "揭西县" + }, + { + "value": 2082, + "label": "惠来县" + }, + { + "value": 2083, + "label": "普宁市" + } + ] + }, + { + "value": 2084, + "label": "云浮市", + "children": [ + { + "value": 2085, + "label": "云城区" + }, + { + "value": 2086, + "label": "新兴县" + }, + { + "value": 2087, + "label": "郁南县" + }, + { + "value": 2088, + "label": "云安县" + }, + { + "value": 2089, + "label": "罗定市" + } + ] + } + ] + }, + { + "value": 2090, + "label": "广西壮族自治区", + "children": [ + { + "value": 2091, + "label": "南宁市", + "children": [ + { + "value": 2092, + "label": "兴宁区" + }, + { + "value": 2093, + "label": "青秀区" + }, + { + "value": 2094, + "label": "江南区" + }, + { + "value": 2095, + "label": "西乡塘区" + }, + { + "value": 2096, + "label": "良庆区" + }, + { + "value": 2097, + "label": "邕宁区" + }, + { + "value": 2098, + "label": "武鸣县" + }, + { + "value": 2099, + "label": "隆安县" + }, + { + "value": 2100, + "label": "马山县" + }, + { + "value": 2101, + "label": "上林县" + }, + { + "value": 2102, + "label": "宾阳县" + }, + { + "value": 2103, + "label": "横县" + } + ] + }, + { + "value": 2104, + "label": "柳州市", + "children": [ + { + "value": 2105, + "label": "城中区" + }, + { + "value": 2106, + "label": "鱼峰区" + }, + { + "value": 2107, + "label": "柳南区" + }, + { + "value": 2108, + "label": "柳北区" + }, + { + "value": 2109, + "label": "柳江县" + }, + { + "value": 2110, + "label": "柳城县" + }, + { + "value": 2111, + "label": "鹿寨县" + }, + { + "value": 2112, + "label": "融安县" + }, + { + "value": 2113, + "label": "融水苗族自治县" + }, + { + "value": 2114, + "label": "三江侗族自治县" + } + ] + }, + { + "value": 2115, + "label": "桂林市", + "children": [ + { + "value": 2116, + "label": "秀峰区" + }, + { + "value": 2117, + "label": "叠彩区" + }, + { + "value": 2118, + "label": "象山区" + }, + { + "value": 2119, + "label": "七星区" + }, + { + "value": 2120, + "label": "雁山区" + }, + { + "value": 2121, + "label": "阳朔县" + }, + { + "value": 2128, + "label": "龙胜各族自治县" + }, + { + "value": 2129, + "label": "资源县" + }, + { + "value": 2130, + "label": "平乐县" + }, + { + "value": 2131, + "label": "荔蒲县" + }, + { + "value": 2132, + "label": "恭城瑶族自治县" + }, + { + "value": 2122, + "label": "临桂县" + }, + { + "value": 2123, + "label": "灵川县" + }, + { + "value": 2124, + "label": "全州县" + }, + { + "value": 2125, + "label": "兴安县" + }, + { + "value": 2126, + "label": "永福县" + }, + { + "value": 2127, + "label": "灌阳县" + } + ] + }, + { + "value": 2133, + "label": "梧州市", + "children": [ + { + "value": 2134, + "label": "万秀区" + }, + { + "value": 2135, + "label": "蝶山区" + }, + { + "value": 2136, + "label": "长洲区" + }, + { + "value": 2137, + "label": "苍梧县" + }, + { + "value": 2138, + "label": "藤县" + }, + { + "value": 2139, + "label": "蒙山县" + }, + { + "value": 2140, + "label": "岑溪市" + } + ] + }, + { + "value": 2141, + "label": "北海市", + "children": [ + { + "value": 2142, + "label": "海城区" + }, + { + "value": 2143, + "label": "银海区" + }, + { + "value": 2144, + "label": "铁山港区" + }, + { + "value": 2145, + "label": "合浦县" + } + ] + }, + { + "value": 2146, + "label": "防城港市", + "children": [ + { + "value": 2147, + "label": "港口区" + }, + { + "value": 2148, + "label": "防城区" + }, + { + "value": 2149, + "label": "上思县" + }, + { + "value": 2150, + "label": "东兴市" + } + ] + }, + { + "value": 2151, + "label": "钦州市", + "children": [ + { + "value": 2152, + "label": "钦南区" + }, + { + "value": 2153, + "label": "钦北区" + }, + { + "value": 2154, + "label": "灵山县" + }, + { + "value": 2155, + "label": "浦北县" + } + ] + }, + { + "value": 2156, + "label": "贵港市", + "children": [ + { + "value": 2157, + "label": "港北区" + }, + { + "value": 2158, + "label": "港南区" + }, + { + "value": 2159, + "label": "覃塘区" + }, + { + "value": 2160, + "label": "平南县" + }, + { + "value": 2161, + "label": "桂平市" + } + ] + }, + { + "value": 2162, + "label": "玉林市", + "children": [ + { + "value": 2163, + "label": "玉州区" + }, + { + "value": 2164, + "label": "容县" + }, + { + "value": 2165, + "label": "陆川县" + }, + { + "value": 2166, + "label": "博白县" + }, + { + "value": 2167, + "label": "兴业县" + }, + { + "value": 2168, + "label": "北流市" + } + ] + }, + { + "value": 2169, + "label": "百色市", + "children": [ + { + "value": 2170, + "label": "右江区" + }, + { + "value": 2171, + "label": "田阳县" + }, + { + "value": 2172, + "label": "田东县" + }, + { + "value": 2173, + "label": "平果县" + }, + { + "value": 2174, + "label": "德保县" + }, + { + "value": 2175, + "label": "靖西县" + }, + { + "value": 2176, + "label": "那坡县" + }, + { + "value": 2177, + "label": "凌云县" + }, + { + "value": 2178, + "label": "乐业县" + }, + { + "value": 2179, + "label": "田林县" + }, + { + "value": 2180, + "label": "西林县" + }, + { + "value": 2181, + "label": "隆林各族自治县" + } + ] + }, + { + "value": 2182, + "label": "贺州市", + "children": [ + { + "value": 2183, + "label": "八步区" + }, + { + "value": 2184, + "label": "昭平县" + }, + { + "value": 2185, + "label": "钟山县" + }, + { + "value": 2186, + "label": "富川瑶族自治县" + } + ] + }, + { + "value": 2187, + "label": "河池市", + "children": [ + { + "value": 2188, + "label": "金城江区" + }, + { + "value": 2189, + "label": "南丹县" + }, + { + "value": 2190, + "label": "天峨县" + }, + { + "value": 2191, + "label": "凤山县" + }, + { + "value": 2192, + "label": "东兰县" + }, + { + "value": 2193, + "label": "罗城仫佬族自治县" + }, + { + "value": 2194, + "label": "环江毛南族自治县" + }, + { + "value": 2195, + "label": "巴马瑶族自治县" + }, + { + "value": 2196, + "label": "都安瑶族自治县" + }, + { + "value": 2197, + "label": "大化瑶族自治县" + }, + { + "value": 2198, + "label": "宜州市" + } + ] + }, + { + "value": 2199, + "label": "来宾市", + "children": [ + { + "value": 2200, + "label": "兴宾区" + }, + { + "value": 2201, + "label": "忻城县" + }, + { + "value": 2202, + "label": "象州县" + }, + { + "value": 2203, + "label": "武宣县" + }, + { + "value": 2204, + "label": "金秀瑶族自治县" + }, + { + "value": 2205, + "label": "合山市" + } + ] + }, + { + "value": 2206, + "label": "崇左市", + "children": [ + { + "value": 2207, + "label": "江洲区" + }, + { + "value": 2208, + "label": "扶绥县" + }, + { + "value": 2209, + "label": "宁明县" + }, + { + "value": 2210, + "label": "龙州县" + }, + { + "value": 2211, + "label": "大新县" + }, + { + "value": 2212, + "label": "天等县" + }, + { + "value": 2213, + "label": "凭祥市" + } + ] + } + ] + }, + { + "value": 2214, + "label": "海南省", + "children": [ + { + "value": 2215, + "label": "海口市", + "children": [ + { + "value": 2216, + "label": "秀英区" + }, + { + "value": 2217, + "label": "龙华区" + }, + { + "value": 2218, + "label": "琼山区" + }, + { + "value": 2219, + "label": "美兰区" + } + ] + }, + { + "value": 2220, + "label": "三亚市" + }, + { + "value": 2221, + "label": "五指山市" + }, + { + "value": 2222, + "label": "琼海市" + }, + { + "value": 2223, + "label": "儋州市" + }, + { + "value": 2224, + "label": "文昌市" + }, + { + "value": 2225, + "label": "万宁市" + }, + { + "value": 2226, + "label": "东方市" + }, + { + "value": 2227, + "label": "定安县" + }, + { + "value": 2228, + "label": "屯昌县" + }, + { + "value": 2229, + "label": "澄迈县" + }, + { + "value": 2230, + "label": "临高县" + }, + { + "value": 2231, + "label": "白沙黎族自治县" + }, + { + "value": 2232, + "label": "昌江黎族自治县" + }, + { + "value": 2233, + "label": "乐东黎族自治县" + }, + { + "value": 2234, + "label": "陵水黎族自治县" + }, + { + "value": 2235, + "label": "保亭黎族苗族自治县" + }, + { + "value": 2236, + "label": "琼中黎族苗族自治县" + }, + { + "value": 2237, + "label": "西沙群岛" + }, + { + "value": 2238, + "label": "南沙群岛" + }, + { + "value": 2239, + "label": "中沙群岛的岛礁及其海域" + } + ] + }, + { + "value": 2240, + "label": "重庆市", + "children": [ + { + "value": 2241, + "label": "万州区" + }, + { + "value": 2242, + "label": "涪陵区" + }, + { + "value": 2243, + "label": "渝中区" + }, + { + "value": 2244, + "label": "大渡口区" + }, + { + "value": 2245, + "label": "江北区" + }, + { + "value": 2246, + "label": "沙坪坝区" + }, + { + "value": 2247, + "label": "九龙坡区" + }, + { + "value": 2248, + "label": "南岸区" + }, + { + "value": 2249, + "label": "北碚区" + }, + { + "value": 2250, + "label": "綦江区" + }, + { + "value": 2251, + "label": "大足区" + }, + { + "value": 2252, + "label": "渝北区" + }, + { + "value": 2253, + "label": "巴南区" + }, + { + "value": 2254, + "label": "黔江区" + }, + { + "value": 2255, + "label": "长寿区" + }, + { + "value": 2256, + "label": "江津区" + }, + { + "value": 2257, + "label": "合川区" + }, + { + "value": 2258, + "label": "永川区" + }, + { + "value": 2259, + "label": "南川区" + }, + { + "value": 2260, + "label": "潼南县" + }, + { + "value": 2261, + "label": "铜梁县" + }, + { + "value": 2262, + "label": "荣昌县" + }, + { + "value": 2263, + "label": "璧山县" + }, + { + "value": 2264, + "label": "梁平县" + }, + { + "value": 2265, + "label": "城口县" + }, + { + "value": 2266, + "label": "丰都县" + }, + { + "value": 2267, + "label": "垫江县" + }, + { + "value": 2268, + "label": "武隆县" + }, + { + "value": 2269, + "label": "忠县" + }, + { + "value": 2270, + "label": "开县" + }, + { + "value": 2271, + "label": "云阳县" + }, + { + "value": 2272, + "label": "奉节县" + }, + { + "value": 2273, + "label": "巫山县" + }, + { + "value": 2274, + "label": "巫溪县" + }, + { + "value": 2275, + "label": "石柱土家族自治县" + }, + { + "value": 2276, + "label": "秀山土家族苗族自治县" + }, + { + "value": 2277, + "label": "酉阳土家族苗族自治县" + }, + { + "value": 2278, + "label": "彭水苗族土家族自治县" + } + ] + }, + { + "value": 2279, + "label": "四川省", + "children": [ + { + "value": 2280, + "label": "成都市", + "children": [ + { + "value": 2281, + "label": "锦江区" + }, + { + "value": 2282, + "label": "青羊区" + }, + { + "value": 2283, + "label": "金牛区" + }, + { + "value": 2284, + "label": "武侯区" + }, + { + "value": 2285, + "label": "成华区" + }, + { + "value": 2286, + "label": "龙泉驿区" + }, + { + "value": 2299, + "label": "崇州市" + }, + { + "value": 2293, + "label": "大邑县" + }, + { + "value": 2294, + "label": "蒲江县" + }, + { + "value": 2295, + "label": "新津县" + }, + { + "value": 2296, + "label": "都江堰市" + }, + { + "value": 2297, + "label": "彭州市" + }, + { + "value": 2298, + "label": "邛崃市" + }, + { + "value": 2287, + "label": "青白江区" + }, + { + "value": 2288, + "label": "新都区" + }, + { + "value": 2289, + "label": "温江区" + }, + { + "value": 2290, + "label": "金堂县" + }, + { + "value": 2291, + "label": "双流县" + }, + { + "value": 2292, + "label": "郫县" + } + ] + }, + { + "value": 2300, + "label": "自贡市", + "children": [ + { + "value": 2301, + "label": "自流井区" + }, + { + "value": 2302, + "label": "贡井区" + }, + { + "value": 2303, + "label": "大安区" + }, + { + "value": 2304, + "label": "沿滩区" + }, + { + "value": 2305, + "label": "荣县" + }, + { + "value": 2306, + "label": "富顺县" + } + ] + }, + { + "value": 2307, + "label": "攀枝花市", + "children": [ + { + "value": 2308, + "label": "东区" + }, + { + "value": 2309, + "label": "西区" + }, + { + "value": 2310, + "label": "仁和区" + }, + { + "value": 2311, + "label": "米易县" + }, + { + "value": 2312, + "label": "盐边县" + } + ] + }, + { + "value": 2313, + "label": "泸州市", + "children": [ + { + "value": 2315, + "label": "纳溪区" + }, + { + "value": 2316, + "label": "龙马潭区" + }, + { + "value": 2317, + "label": "泸县" + }, + { + "value": 2318, + "label": "合江县" + }, + { + "value": 2319, + "label": "叙永县" + }, + { + "value": 2320, + "label": "古蔺县" + }, + { + "value": 2314, + "label": "江阳区" + } + ] + }, + { + "value": 2321, + "label": "德阳市", + "children": [ + { + "value": 2322, + "label": "旌阳区" + }, + { + "value": 2323, + "label": "中江县" + }, + { + "value": 2324, + "label": "罗江县" + }, + { + "value": 2325, + "label": "广汉市" + }, + { + "value": 2326, + "label": "什邡市" + }, + { + "value": 2327, + "label": "绵竹市" + } + ] + }, + { + "value": 2328, + "label": "绵阳市", + "children": [ + { + "value": 2329, + "label": "涪城区" + }, + { + "value": 2330, + "label": "游仙区" + }, + { + "value": 2331, + "label": "三台县" + }, + { + "value": 2332, + "label": "盐亭县" + }, + { + "value": 2333, + "label": "安县" + }, + { + "value": 2334, + "label": "梓潼县" + }, + { + "value": 2335, + "label": "北川羌族自治县" + }, + { + "value": 2336, + "label": "平武县" + }, + { + "value": 2337, + "label": "江油市" + } + ] + }, + { + "value": 2338, + "label": "广元市", + "children": [ + { + "value": 2339, + "label": "利州区" + }, + { + "value": 2340, + "label": "元坝区" + }, + { + "value": 2341, + "label": "朝天区" + }, + { + "value": 2342, + "label": "旺苍县" + }, + { + "value": 2343, + "label": "青川县" + }, + { + "value": 2344, + "label": "剑阁县" + }, + { + "value": 2345, + "label": "苍溪县" + } + ] + }, + { + "value": 2346, + "label": "遂宁市", + "children": [ + { + "value": 2347, + "label": "船山区" + }, + { + "value": 2348, + "label": "安居区" + }, + { + "value": 2349, + "label": "蓬溪县" + }, + { + "value": 2350, + "label": "射洪县" + }, + { + "value": 2351, + "label": "大英县" + } + ] + }, + { + "value": 2352, + "label": "内江市", + "children": [ + { + "value": 2353, + "label": "市中区" + }, + { + "value": 2354, + "label": "东兴区" + }, + { + "value": 2355, + "label": "威远县" + }, + { + "value": 2356, + "label": "资中县" + }, + { + "value": 2357, + "label": "隆昌县" + } + ] + }, + { + "value": 2358, + "label": "乐山市", + "children": [ + { + "value": 2359, + "label": "市中区" + }, + { + "value": 2360, + "label": "沙湾区" + }, + { + "value": 2361, + "label": "五通桥区" + }, + { + "value": 2362, + "label": "金口河区" + }, + { + "value": 2363, + "label": "犍为县" + }, + { + "value": 2364, + "label": "井研县" + }, + { + "value": 2365, + "label": "夹江县" + }, + { + "value": 2366, + "label": "沐川县" + }, + { + "value": 2367, + "label": "峨边彝族自治县" + }, + { + "value": 2368, + "label": "马边彝族自治县" + }, + { + "value": 2369, + "label": "峨眉山市" + } + ] + }, + { + "value": 2370, + "label": "南充市", + "children": [ + { + "value": 2371, + "label": "顺庆区" + }, + { + "value": 2372, + "label": "高坪区" + }, + { + "value": 2373, + "label": "嘉陵区" + }, + { + "value": 2374, + "label": "南部县" + }, + { + "value": 2375, + "label": "营山县" + }, + { + "value": 2376, + "label": "蓬安县" + }, + { + "value": 2377, + "label": "仪陇县" + }, + { + "value": 2378, + "label": "西充县" + }, + { + "value": 2379, + "label": "阆中市" + } + ] + }, + { + "value": 2380, + "label": "眉山市", + "children": [ + { + "value": 2381, + "label": "东坡区" + }, + { + "value": 2382, + "label": "仁寿县" + }, + { + "value": 2383, + "label": "彭山县" + }, + { + "value": 2384, + "label": "洪雅县" + }, + { + "value": 2385, + "label": "丹棱县" + }, + { + "value": 2386, + "label": "青神县" + } + ] + }, + { + "value": 2387, + "label": "宜宾市", + "children": [ + { + "value": 2393, + "label": "高县" + }, + { + "value": 2394, + "label": "珙县" + }, + { + "value": 2395, + "label": "筠连县" + }, + { + "value": 2396, + "label": "兴文县" + }, + { + "value": 2397, + "label": "屏山县" + }, + { + "value": 2388, + "label": "翠屏区" + }, + { + "value": 2389, + "label": "南溪区" + }, + { + "value": 2390, + "label": "宜宾县" + }, + { + "value": 2391, + "label": "江安县" + }, + { + "value": 2392, + "label": "长宁县" + } + ] + }, + { + "value": 2398, + "label": "广安市", + "children": [ + { + "value": 2399, + "label": "广安区" + }, + { + "value": 2400, + "label": "岳池县" + }, + { + "value": 2401, + "label": "武胜县" + }, + { + "value": 2402, + "label": "邻水县" + }, + { + "value": 2403, + "label": "华蓥市" + } + ] + }, + { + "value": 2404, + "label": "达州市", + "children": [ + { + "value": 2407, + "label": "宣汉县" + }, + { + "value": 2408, + "label": "开江县" + }, + { + "value": 2409, + "label": "大竹县" + }, + { + "value": 2410, + "label": "渠县" + }, + { + "value": 2411, + "label": "万源市" + }, + { + "value": 2405, + "label": "通川区" + }, + { + "value": 2406, + "label": "达县" + } + ] + }, + { + "value": 2412, + "label": "雅安市", + "children": [ + { + "value": 2420, + "label": "宝兴县" + }, + { + "value": 2414, + "label": "名山县" + }, + { + "value": 2415, + "label": "荥经县" + }, + { + "value": 2416, + "label": "汉源县" + }, + { + "value": 2417, + "label": "石棉县" + }, + { + "value": 2418, + "label": "天全县" + }, + { + "value": 2419, + "label": "芦山县" + }, + { + "value": 2413, + "label": "雨城区" + } + ] + }, + { + "value": 2421, + "label": "巴中市", + "children": [ + { + "value": 2422, + "label": "巴州区" + }, + { + "value": 2423, + "label": "通江县" + }, + { + "value": 2424, + "label": "南江县" + }, + { + "value": 2425, + "label": "平昌县" + } + ] + }, + { + "value": 2426, + "label": "资阳市", + "children": [ + { + "value": 2428, + "label": "安岳县" + }, + { + "value": 2429, + "label": "乐至县" + }, + { + "value": 2430, + "label": "简阳市" + }, + { + "value": 2427, + "label": "雁江区" + } + ] + }, + { + "value": 2431, + "label": "阿坝藏族羌族自治州", + "children": [ + { + "value": 2432, + "label": "汶川县" + }, + { + "value": 2433, + "label": "理县" + }, + { + "value": 2434, + "label": "茂县" + }, + { + "value": 2435, + "label": "松潘县" + }, + { + "value": 2436, + "label": "九寨沟县" + }, + { + "value": 2437, + "label": "金川县" + }, + { + "value": 2444, + "label": "红原县" + }, + { + "value": 2438, + "label": "小金县" + }, + { + "value": 2439, + "label": "黑水县" + }, + { + "value": 2440, + "label": "马尔康县" + }, + { + "value": 2441, + "label": "壤塘县" + }, + { + "value": 2442, + "label": "阿坝县" + }, + { + "value": 2443, + "label": "若尔盖县" + } + ] + }, + { + "value": 2445, + "label": "甘孜藏族自治州", + "children": [ + { + "value": 2446, + "label": "康定县" + }, + { + "value": 2447, + "label": "泸定县" + }, + { + "value": 2448, + "label": "丹巴县" + }, + { + "value": 2449, + "label": "九龙县" + }, + { + "value": 2450, + "label": "雅江县" + }, + { + "value": 2451, + "label": "道孚县" + }, + { + "value": 2458, + "label": "色达县" + }, + { + "value": 2459, + "label": "理塘县" + }, + { + "value": 2460, + "label": "巴塘县" + }, + { + "value": 2461, + "label": "乡城县" + }, + { + "value": 2462, + "label": "稻城县" + }, + { + "value": 2463, + "label": "得荣县" + }, + { + "value": 2452, + "label": "炉霍县" + }, + { + "value": 2453, + "label": "甘孜县" + }, + { + "value": 2454, + "label": "新龙县" + }, + { + "value": 2455, + "label": "德格县" + }, + { + "value": 2456, + "label": "白玉县" + }, + { + "value": 2457, + "label": "石渠县" + } + ] + }, + { + "value": 2464, + "label": "凉山彝族自治州", + "children": [ + { + "value": 2465, + "label": "西昌市" + }, + { + "value": 2466, + "label": "木里藏族自治县" + }, + { + "value": 2479, + "label": "甘洛县" + }, + { + "value": 2480, + "label": "美姑县" + }, + { + "value": 2481, + "label": "雷波县" + }, + { + "value": 2473, + "label": "布拖县" + }, + { + "value": 2474, + "label": "金阳县" + }, + { + "value": 2475, + "label": "昭觉县" + }, + { + "value": 2476, + "label": "喜德县" + }, + { + "value": 2477, + "label": "冕宁县" + }, + { + "value": 2478, + "label": "越西县" + }, + { + "value": 2467, + "label": "盐源县" + }, + { + "value": 2468, + "label": "德昌县" + }, + { + "value": 2469, + "label": "会理县" + }, + { + "value": 2470, + "label": "会东县" + }, + { + "value": 2471, + "label": "宁南县" + }, + { + "value": 2472, + "label": "普格县" + } + ] + } + ] + }, + { + "value": 2482, + "label": "贵州省", + "children": [ + { + "value": 2483, + "label": "贵阳市", + "children": [ + { + "value": 2484, + "label": "南明区" + }, + { + "value": 2485, + "label": "云岩区" + }, + { + "value": 2486, + "label": "花溪区" + }, + { + "value": 2487, + "label": "乌当区" + }, + { + "value": 2488, + "label": "白云区" + }, + { + "value": 2489, + "label": "小河区" + }, + { + "value": 2490, + "label": "开阳县" + }, + { + "value": 2491, + "label": "息烽县" + }, + { + "value": 2492, + "label": "修文县" + }, + { + "value": 2493, + "label": "清镇市" + } + ] + }, + { + "value": 2494, + "label": "六盘水市", + "children": [ + { + "value": 2495, + "label": "钟山区" + }, + { + "value": 2496, + "label": "六枝特区" + }, + { + "value": 2497, + "label": "水城县" + }, + { + "value": 2498, + "label": "盘县" + } + ] + }, + { + "value": 2499, + "label": "遵义市", + "children": [ + { + "value": 2500, + "label": "红花岗区" + }, + { + "value": 2501, + "label": "汇川区" + }, + { + "value": 2502, + "label": "遵义县" + }, + { + "value": 2503, + "label": "桐梓县" + }, + { + "value": 2504, + "label": "绥阳县" + }, + { + "value": 2505, + "label": "正安县" + }, + { + "value": 2512, + "label": "赤水市" + }, + { + "value": 2513, + "label": "仁怀市" + }, + { + "value": 2506, + "label": "道真仡佬族苗族自治县" + }, + { + "value": 2507, + "label": "务川仡佬族苗族自治县" + }, + { + "value": 2508, + "label": "凤冈县" + }, + { + "value": 2509, + "label": "湄潭县" + }, + { + "value": 2510, + "label": "余庆县" + }, + { + "value": 2511, + "label": "习水县" + } + ] + }, + { + "value": 2514, + "label": "安顺市", + "children": [ + { + "value": 2517, + "label": "普定县" + }, + { + "value": 2518, + "label": "镇宁布依族苗族自治县" + }, + { + "value": 2519, + "label": "关岭布依族苗族自治县" + }, + { + "value": 2520, + "label": "紫云苗族布依族自治县" + }, + { + "value": 2515, + "label": "西秀区" + }, + { + "value": 2516, + "label": "平坝县" + } + ] + }, + { + "value": 2521, + "label": "毕节市", + "children": [ + { + "value": 2522, + "label": "七星关区" + }, + { + "value": 2523, + "label": "大方县" + }, + { + "value": 2524, + "label": "黔西县" + }, + { + "value": 2525, + "label": "金沙县" + }, + { + "value": 2526, + "label": "织金县" + }, + { + "value": 2527, + "label": "纳雍县" + }, + { + "value": 2528, + "label": "威宁彝族回族苗族自治县" + }, + { + "value": 2529, + "label": "赫章县" + } + ] + }, + { + "value": 2530, + "label": "铜仁市", + "children": [ + { + "value": 2536, + "label": "思南县" + }, + { + "value": 2537, + "label": "印江土家族苗族自治县" + }, + { + "value": 2538, + "label": "德江县" + }, + { + "value": 2539, + "label": "沿河土家族自治县" + }, + { + "value": 2540, + "label": "松桃苗族自治县" + }, + { + "value": 2531, + "label": "碧江区" + }, + { + "value": 2532, + "label": "万山区" + }, + { + "value": 2533, + "label": "江口县" + }, + { + "value": 2534, + "label": "玉屏侗族自治县" + }, + { + "value": 2535, + "label": "石阡县" + } + ] + }, + { + "value": 2541, + "label": "黔西南布依族苗族自治州", + "children": [ + { + "value": 2542, + "label": "兴义市" + }, + { + "value": 2543, + "label": "兴仁县" + }, + { + "value": 2544, + "label": "普安县" + }, + { + "value": 2545, + "label": "晴隆县" + }, + { + "value": 2546, + "label": "贞丰县" + }, + { + "value": 2547, + "label": "望谟县" + }, + { + "value": 2548, + "label": "册亨县" + }, + { + "value": 2549, + "label": "安龙县" + } + ] + }, + { + "value": 2550, + "label": "黔东南苗族侗族自治州", + "children": [ + { + "value": 2551, + "label": "凯里市" + }, + { + "value": 2552, + "label": "黄平县" + }, + { + "value": 2553, + "label": "施秉县" + }, + { + "value": 2554, + "label": "三穗县" + }, + { + "value": 2555, + "label": "镇远县" + }, + { + "value": 2556, + "label": "岑巩县" + }, + { + "value": 2563, + "label": "从江县" + }, + { + "value": 2564, + "label": "雷山县" + }, + { + "value": 2565, + "label": "麻江县" + }, + { + "value": 2566, + "label": "丹寨县" + }, + { + "value": 2557, + "label": "天柱县" + }, + { + "value": 2558, + "label": "锦屏县" + }, + { + "value": 2559, + "label": "剑河县" + }, + { + "value": 2560, + "label": "台江县" + }, + { + "value": 2561, + "label": "黎平县" + }, + { + "value": 2562, + "label": "榕江县" + } + ] + }, + { + "value": 2567, + "label": "黔南布依族苗族自治州", + "children": [ + { + "value": 2568, + "label": "都匀市" + }, + { + "value": 2569, + "label": "福泉市" + }, + { + "value": 2570, + "label": "荔波县" + }, + { + "value": 2571, + "label": "贵定县" + }, + { + "value": 2572, + "label": "瓮安县" + }, + { + "value": 2573, + "label": "独山县" + }, + { + "value": 2574, + "label": "平塘县" + }, + { + "value": 2575, + "label": "罗甸县" + }, + { + "value": 2576, + "label": "长顺县" + }, + { + "value": 2577, + "label": "龙里县" + }, + { + "value": 2578, + "label": "惠水县" + }, + { + "value": 2579, + "label": "三都水族自治县" + } + ] + } + ] + }, + { + "value": 2580, + "label": "云南省", + "children": [ + { + "value": 2581, + "label": "昆明市", + "children": [ + { + "value": 2590, + "label": "宜良县" + }, + { + "value": 2591, + "label": "石林彝族自治县" + }, + { + "value": 2592, + "label": "嵩明县" + }, + { + "value": 2593, + "label": "禄劝彝族苗族自治县" + }, + { + "value": 2594, + "label": "寻甸回族彝族自治县" + }, + { + "value": 2595, + "label": "安宁市" + }, + { + "value": 2584, + "label": "官渡区" + }, + { + "value": 2585, + "label": "西山区" + }, + { + "value": 2586, + "label": "东川区" + }, + { + "value": 2587, + "label": "呈贡区" + }, + { + "value": 2588, + "label": "晋宁县" + }, + { + "value": 2589, + "label": "富民县" + }, + { + "value": 2582, + "label": "五华区" + }, + { + "value": 2583, + "label": "盘龙区" + } + ] + }, + { + "value": 2596, + "label": "曲靖市", + "children": [ + { + "value": 2604, + "label": "沾益县" + }, + { + "value": 2605, + "label": "宣威市" + }, + { + "value": 2598, + "label": "马龙县" + }, + { + "value": 2599, + "label": "陆良县" + }, + { + "value": 2600, + "label": "师宗县" + }, + { + "value": 2601, + "label": "罗平县" + }, + { + "value": 2602, + "label": "富源县" + }, + { + "value": 2603, + "label": "会泽县" + }, + { + "value": 2597, + "label": "麒麟区" + } + ] + }, + { + "value": 2606, + "label": "玉溪市", + "children": [ + { + "value": 2607, + "label": "红塔区" + }, + { + "value": 2608, + "label": "江川县" + }, + { + "value": 2609, + "label": "澄江县" + }, + { + "value": 2610, + "label": "通海县" + }, + { + "value": 2611, + "label": "华宁县" + }, + { + "value": 2612, + "label": "易门县" + }, + { + "value": 2613, + "label": "峨山彝族自治县" + }, + { + "value": 2614, + "label": "新平彝族傣族自治县" + }, + { + "value": 2615, + "label": "元江哈尼族彝族傣族自治县" + } + ] + }, + { + "value": 2616, + "label": "保山市", + "children": [ + { + "value": 2617, + "label": "隆阳区" + }, + { + "value": 2618, + "label": "施甸县" + }, + { + "value": 2619, + "label": "腾冲县" + }, + { + "value": 2620, + "label": "龙陵县" + }, + { + "value": 2621, + "label": "昌宁县" + } + ] + }, + { + "value": 2622, + "label": "昭通市", + "children": [ + { + "value": 2628, + "label": "永善县" + }, + { + "value": 2629, + "label": "绥江县" + }, + { + "value": 2630, + "label": "镇雄县" + }, + { + "value": 2631, + "label": "彝良县" + }, + { + "value": 2632, + "label": "威信县" + }, + { + "value": 2633, + "label": "水富县" + }, + { + "value": 2623, + "label": "昭阳区" + }, + { + "value": 2624, + "label": "鲁甸县" + }, + { + "value": 2625, + "label": "巧家县" + }, + { + "value": 2626, + "label": "盐津县" + }, + { + "value": 2627, + "label": "大关县" + } + ] + }, + { + "value": 2634, + "label": "丽江市", + "children": [ + { + "value": 2635, + "label": "古城区" + }, + { + "value": 2636, + "label": "玉龙纳西族自治县" + }, + { + "value": 2637, + "label": "永胜县" + }, + { + "value": 2638, + "label": "华坪县" + }, + { + "value": 2639, + "label": "宁蒗彝族自治县" + } + ] + }, + { + "value": 2640, + "label": "普洱市", + "children": [ + { + "value": 2641, + "label": "思茅区" + }, + { + "value": 2642, + "label": "宁洱哈尼族彝族自治县" + }, + { + "value": 2643, + "label": "墨江哈尼族自治县" + }, + { + "value": 2644, + "label": "景东彝族自治县" + }, + { + "value": 2645, + "label": "景谷傣族彝族自治县" + }, + { + "value": 2646, + "label": "镇沅彝族哈尼族拉祜族自治县" + }, + { + "value": 2647, + "label": "江城哈尼族彝族自治县" + }, + { + "value": 2648, + "label": "孟连傣族拉祜族佤族自治县" + }, + { + "value": 2649, + "label": "澜沧拉祜族自治县" + }, + { + "value": 2650, + "label": "西盟佤族自治县" + } + ] + }, + { + "value": 2651, + "label": "临沧市", + "children": [ + { + "value": 2652, + "label": "临翔区" + }, + { + "value": 2653, + "label": "凤庆县" + }, + { + "value": 2654, + "label": "云县" + }, + { + "value": 2655, + "label": "永德县" + }, + { + "value": 2656, + "label": "镇康县" + }, + { + "value": 2657, + "label": "双江拉祜族佤族布朗族傣族自治县" + }, + { + "value": 2658, + "label": "耿马傣族佤族自治县" + }, + { + "value": 2659, + "label": "沧源佤族自治县" + } + ] + }, + { + "value": 2660, + "label": "楚雄彝族自治州", + "children": [ + { + "value": 2667, + "label": "永仁县" + }, + { + "value": 2668, + "label": "元谋县" + }, + { + "value": 2669, + "label": "武定县" + }, + { + "value": 2670, + "label": "禄丰县" + }, + { + "value": 2661, + "label": "楚雄市" + }, + { + "value": 2662, + "label": "双柏县" + }, + { + "value": 2663, + "label": "牟定县" + }, + { + "value": 2664, + "label": "南华县" + }, + { + "value": 2665, + "label": "姚安县" + }, + { + "value": 2666, + "label": "大姚县" + } + ] + }, + { + "value": 2671, + "label": "红河哈尼族彝族自治州", + "children": [ + { + "value": 2672, + "label": "个旧市" + }, + { + "value": 2673, + "label": "开远市" + }, + { + "value": 2674, + "label": "蒙自市" + }, + { + "value": 2675, + "label": "屏边苗族自治县" + }, + { + "value": 2676, + "label": "建水县" + }, + { + "value": 2677, + "label": "石屏县" + }, + { + "value": 2684, + "label": "河口瑶族自治县" + }, + { + "value": 2678, + "label": "弥勒县" + }, + { + "value": 2679, + "label": "泸西县" + }, + { + "value": 2680, + "label": "元阳县" + }, + { + "value": 2681, + "label": "红河县" + }, + { + "value": 2682, + "label": "金平苗族瑶族傣族自治县" + }, + { + "value": 2683, + "label": "绿春县" + } + ] + }, + { + "value": 2685, + "label": "文山壮族苗族自治州", + "children": [ + { + "value": 2688, + "label": "西畴县" + }, + { + "value": 2689, + "label": "麻栗坡县" + }, + { + "value": 2690, + "label": "马关县" + }, + { + "value": 2691, + "label": "丘北县" + }, + { + "value": 2692, + "label": "广南县" + }, + { + "value": 2693, + "label": "富宁县" + }, + { + "value": 2686, + "label": "文山市" + }, + { + "value": 2687, + "label": "砚山县" + } + ] + }, + { + "value": 2694, + "label": "西双版纳傣族自治州", + "children": [ + { + "value": 2695, + "label": "景洪市" + }, + { + "value": 2696, + "label": "勐海县" + }, + { + "value": 2697, + "label": "勐腊县" + } + ] + }, + { + "value": 2698, + "label": "大理白族自治州", + "children": [ + { + "value": 2699, + "label": "大理市" + }, + { + "value": 2700, + "label": "漾濞彝族自治县" + }, + { + "value": 2701, + "label": "祥云县" + }, + { + "value": 2702, + "label": "宾川县" + }, + { + "value": 2703, + "label": "弥渡县" + }, + { + "value": 2704, + "label": "南涧彝族自治县" + }, + { + "value": 2705, + "label": "巍山彝族回族自治县" + }, + { + "value": 2706, + "label": "永平县" + }, + { + "value": 2707, + "label": "云龙县" + }, + { + "value": 2708, + "label": "洱源县" + }, + { + "value": 2709, + "label": "剑川县" + }, + { + "value": 2710, + "label": "鹤庆县" + } + ] + }, + { + "value": 2711, + "label": "德宏傣族景颇族自治州", + "children": [ + { + "value": 2712, + "label": "瑞丽市" + }, + { + "value": 2713, + "label": "芒市" + }, + { + "value": 2714, + "label": "梁河县" + }, + { + "value": 2715, + "label": "盈江县" + }, + { + "value": 2716, + "label": "陇川县" + } + ] + }, + { + "value": 2717, + "label": "怒江傈僳族自治州", + "children": [ + { + "value": 2720, + "label": "贡山独龙族怒族自治县" + }, + { + "value": 2721, + "label": "兰坪白族普米族自治县" + }, + { + "value": 2718, + "label": "泸水县" + }, + { + "value": 2719, + "label": "福贡县" + } + ] + }, + { + "value": 2722, + "label": "迪庆藏族自治州", + "children": [ + { + "value": 2723, + "label": "香格里拉县" + }, + { + "value": 2724, + "label": "德钦县" + }, + { + "value": 2725, + "label": "维西傈僳族自治县" + } + ] + } + ] + }, + { + "value": 2726, + "label": "西藏自治区", + "children": [ + { + "value": 2727, + "label": "拉萨市", + "children": [ + { + "value": 2728, + "label": "城关区" + }, + { + "value": 2735, + "label": "墨竹工卡县" + }, + { + "value": 2729, + "label": "林周县" + }, + { + "value": 2730, + "label": "当雄县" + }, + { + "value": 2731, + "label": "尼木县" + }, + { + "value": 2732, + "label": "曲水县" + }, + { + "value": 2733, + "label": "堆龙德庆县" + }, + { + "value": 2734, + "label": "达孜县" + } + ] + }, + { + "value": 2736, + "label": "昌都地区", + "children": [ + { + "value": 2744, + "label": "左贡县" + }, + { + "value": 2745, + "label": "芒康县" + }, + { + "value": 2746, + "label": "洛隆县" + }, + { + "value": 2747, + "label": "边坝县" + }, + { + "value": 2738, + "label": "江达县" + }, + { + "value": 2739, + "label": "贡觉县" + }, + { + "value": 2740, + "label": "类乌齐县" + }, + { + "value": 2741, + "label": "丁青县" + }, + { + "value": 2742, + "label": "察雅县" + }, + { + "value": 2743, + "label": "八宿县" + }, + { + "value": 2737, + "label": "昌都县" + } + ] + }, + { + "value": 2748, + "label": "山南地区", + "children": [ + { + "value": 2749, + "label": "乃东县" + }, + { + "value": 2756, + "label": "洛扎县" + }, + { + "value": 2757, + "label": "加查县" + }, + { + "value": 2758, + "label": "隆子县" + }, + { + "value": 2759, + "label": "错那县" + }, + { + "value": 2760, + "label": "浪卡子县" + }, + { + "value": 2750, + "label": "扎囊县" + }, + { + "value": 2751, + "label": "贡嘎县" + }, + { + "value": 2752, + "label": "桑日县" + }, + { + "value": 2753, + "label": "琼结县" + }, + { + "value": 2754, + "label": "曲松县" + }, + { + "value": 2755, + "label": "措美县" + } + ] + }, + { + "value": 2761, + "label": "日喀则地区", + "children": [ + { + "value": 2776, + "label": "吉隆县" + }, + { + "value": 2777, + "label": "聂拉木县" + }, + { + "value": 2778, + "label": "萨嘎县" + }, + { + "value": 2779, + "label": "岗巴县" + }, + { + "value": 2770, + "label": "白朗县" + }, + { + "value": 2771, + "label": "仁布县" + }, + { + "value": 2772, + "label": "康马县" + }, + { + "value": 2773, + "label": "定结县" + }, + { + "value": 2774, + "label": "仲巴县" + }, + { + "value": 2775, + "label": "亚东县" + }, + { + "value": 2764, + "label": "江孜县" + }, + { + "value": 2765, + "label": "定日县" + }, + { + "value": 2766, + "label": "萨迦县" + }, + { + "value": 2767, + "label": "拉孜县" + }, + { + "value": 2768, + "label": "昂仁县" + }, + { + "value": 2769, + "label": "谢通门县" + }, + { + "value": 2762, + "label": "日喀则市" + }, + { + "value": 2763, + "label": "南木林县" + } + ] + }, + { + "value": 2780, + "label": "那曲地区", + "children": [ + { + "value": 2781, + "label": "那曲县" + }, + { + "value": 2782, + "label": "嘉黎县" + }, + { + "value": 2783, + "label": "比如县" + }, + { + "value": 2784, + "label": "聂荣县" + }, + { + "value": 2785, + "label": "安多县" + }, + { + "value": 2786, + "label": "申扎县" + }, + { + "value": 2787, + "label": "索县" + }, + { + "value": 2788, + "label": "班戈县" + }, + { + "value": 2789, + "label": "巴青县" + }, + { + "value": 2790, + "label": "尼玛县" + } + ] + }, + { + "value": 2791, + "label": "阿里地区", + "children": [ + { + "value": 2792, + "label": "普兰县" + }, + { + "value": 2793, + "label": "札达县" + }, + { + "value": 2794, + "label": "噶尔县" + }, + { + "value": 2795, + "label": "日土县" + }, + { + "value": 2796, + "label": "革吉县" + }, + { + "value": 2797, + "label": "改则县" + }, + { + "value": 2798, + "label": "措勤县" + } + ] + }, + { + "value": 2799, + "label": "林芝地区", + "children": [ + { + "value": 2800, + "label": "林芝县" + }, + { + "value": 2801, + "label": "工布江达县" + }, + { + "value": 2802, + "label": "米林县" + }, + { + "value": 2803, + "label": "墨脱县" + }, + { + "value": 2804, + "label": "波密县" + }, + { + "value": 2805, + "label": "察隅县" + }, + { + "value": 2806, + "label": "朗县" + } + ] + } + ] + }, + { + "value": 2807, + "label": "陕西省", + "children": [ + { + "value": 2808, + "label": "西安市", + "children": [ + { + "value": 2809, + "label": "新城区" + }, + { + "value": 2810, + "label": "碑林区" + }, + { + "value": 2811, + "label": "莲湖区" + }, + { + "value": 2812, + "label": "灞桥区" + }, + { + "value": 2813, + "label": "未央区" + }, + { + "value": 2814, + "label": "雁塔区" + }, + { + "value": 2821, + "label": "高陵县" + }, + { + "value": 2815, + "label": "阎良区" + }, + { + "value": 2816, + "label": "临潼区" + }, + { + "value": 2817, + "label": "长安区" + }, + { + "value": 2818, + "label": "蓝田县" + }, + { + "value": 2819, + "label": "周至县" + }, + { + "value": 2820, + "label": "户县" + } + ] + }, + { + "value": 2822, + "label": "铜川市", + "children": [ + { + "value": 2823, + "label": "王益区" + }, + { + "value": 2824, + "label": "印台区" + }, + { + "value": 2825, + "label": "耀州区" + }, + { + "value": 2826, + "label": "宜君县" + } + ] + }, + { + "value": 2827, + "label": "宝鸡市", + "children": [ + { + "value": 2838, + "label": "凤县" + }, + { + "value": 2839, + "label": "太白县" + }, + { + "value": 2832, + "label": "岐山县" + }, + { + "value": 2833, + "label": "扶风县" + }, + { + "value": 2834, + "label": "眉县" + }, + { + "value": 2835, + "label": "陇县" + }, + { + "value": 2836, + "label": "千阳县" + }, + { + "value": 2837, + "label": "麟游县" + }, + { + "value": 2828, + "label": "渭滨区" + }, + { + "value": 2829, + "label": "金台区" + }, + { + "value": 2830, + "label": "陈仓区" + }, + { + "value": 2831, + "label": "凤翔县" + } + ] + }, + { + "value": 2840, + "label": "咸阳市", + "children": [ + { + "value": 2841, + "label": "秦都区" + }, + { + "value": 2842, + "label": "杨陵区" + }, + { + "value": 2843, + "label": "渭城区" + }, + { + "value": 2844, + "label": "三原县" + }, + { + "value": 2845, + "label": "泾阳县" + }, + { + "value": 2846, + "label": "乾县" + }, + { + "value": 2853, + "label": "武功县" + }, + { + "value": 2854, + "label": "兴平市" + }, + { + "value": 2847, + "label": "礼泉县" + }, + { + "value": 2848, + "label": "永寿县" + }, + { + "value": 2849, + "label": "彬县" + }, + { + "value": 2850, + "label": "长武县" + }, + { + "value": 2851, + "label": "旬邑县" + }, + { + "value": 2852, + "label": "淳化县" + } + ] + }, + { + "value": 2855, + "label": "渭南市", + "children": [ + { + "value": 2865, + "label": "韩城市" + }, + { + "value": 2866, + "label": "华阴市" + }, + { + "value": 2859, + "label": "大荔县" + }, + { + "value": 2860, + "label": "合阳县" + }, + { + "value": 2861, + "label": "澄城县" + }, + { + "value": 2862, + "label": "蒲城县" + }, + { + "value": 2863, + "label": "白水县" + }, + { + "value": 2864, + "label": "富平县" + }, + { + "value": 2856, + "label": "临渭区" + }, + { + "value": 2857, + "label": "华县" + }, + { + "value": 2858, + "label": "潼关县" + } + ] + }, + { + "value": 2867, + "label": "延安市", + "children": [ + { + "value": 2879, + "label": "黄龙县" + }, + { + "value": 2880, + "label": "黄陵县" + }, + { + "value": 2873, + "label": "志丹县" + }, + { + "value": 2874, + "label": "吴起县" + }, + { + "value": 2875, + "label": "甘泉县" + }, + { + "value": 2876, + "label": "富县" + }, + { + "value": 2877, + "label": "洛川县" + }, + { + "value": 2878, + "label": "宜川县" + }, + { + "value": 2868, + "label": "宝塔区" + }, + { + "value": 2869, + "label": "延长县" + }, + { + "value": 2870, + "label": "延川县" + }, + { + "value": 2871, + "label": "子长县" + }, + { + "value": 2872, + "label": "安塞县" + } + ] + }, + { + "value": 2881, + "label": "汉中市", + "children": [ + { + "value": 2882, + "label": "汉台区" + }, + { + "value": 2883, + "label": "南郑县" + }, + { + "value": 2884, + "label": "城固县" + }, + { + "value": 2885, + "label": "洋县" + }, + { + "value": 2886, + "label": "西乡县" + }, + { + "value": 2887, + "label": "勉县" + }, + { + "value": 2888, + "label": "宁强县" + }, + { + "value": 2889, + "label": "略阳县" + }, + { + "value": 2890, + "label": "镇巴县" + }, + { + "value": 2891, + "label": "留坝县" + }, + { + "value": 2892, + "label": "佛坪县" + } + ] + }, + { + "value": 2893, + "label": "榆林市", + "children": [ + { + "value": 2894, + "label": "榆阳区" + }, + { + "value": 2895, + "label": "神木县" + }, + { + "value": 2896, + "label": "府谷县" + }, + { + "value": 2897, + "label": "横山县" + }, + { + "value": 2898, + "label": "靖边县" + }, + { + "value": 2899, + "label": "定边县" + }, + { + "value": 2900, + "label": "绥德县" + }, + { + "value": 2901, + "label": "米脂县" + }, + { + "value": 2902, + "label": "佳县" + }, + { + "value": 2903, + "label": "吴堡县" + }, + { + "value": 2904, + "label": "清涧县" + }, + { + "value": 2905, + "label": "子洲县" + } + ] + }, + { + "value": 2906, + "label": "安康市", + "children": [ + { + "value": 2907, + "label": "汉滨区" + }, + { + "value": 2908, + "label": "汉阴县" + }, + { + "value": 2909, + "label": "石泉县" + }, + { + "value": 2910, + "label": "宁陕县" + }, + { + "value": 2911, + "label": "紫阳县" + }, + { + "value": 2912, + "label": "岚皋县" + }, + { + "value": 2913, + "label": "平利县" + }, + { + "value": 2914, + "label": "镇坪县" + }, + { + "value": 2915, + "label": "旬阳县" + }, + { + "value": 2916, + "label": "白河县" + } + ] + }, + { + "value": 2917, + "label": "商洛市", + "children": [ + { + "value": 2921, + "label": "商南县" + }, + { + "value": 2922, + "label": "山阳县" + }, + { + "value": 2923, + "label": "镇安县" + }, + { + "value": 2924, + "label": "柞水县" + }, + { + "value": 2918, + "label": "商州区" + }, + { + "value": 2919, + "label": "洛南县" + }, + { + "value": 2920, + "label": "丹凤县" + } + ] + } + ] + }, + { + "value": 2925, + "label": "甘肃省", + "children": [ + { + "value": 2926, + "label": "兰州市", + "children": [ + { + "value": 2933, + "label": "皋兰县" + }, + { + "value": 2934, + "label": "榆中县" + }, + { + "value": 2927, + "label": "城关区" + }, + { + "value": 2928, + "label": "七里河区" + }, + { + "value": 2929, + "label": "西固区" + }, + { + "value": 2930, + "label": "安宁区" + }, + { + "value": 2931, + "label": "红古区" + }, + { + "value": 2932, + "label": "永登县" + } + ] + }, + { + "value": 2935, + "label": "嘉峪关市", + "children": [ + { + "value": 2938, + "label": "永昌县" + }, + { + "value": 2936, + "label": "金昌市" + }, + { + "value": 2937, + "label": "金川区" + } + ] + }, + { + "value": 2939, + "label": "白银市", + "children": [ + { + "value": 2940, + "label": "白银区" + }, + { + "value": 2941, + "label": "平川区" + }, + { + "value": 2942, + "label": "靖远县" + }, + { + "value": 2943, + "label": "会宁县" + }, + { + "value": 2944, + "label": "景泰县" + } + ] + }, + { + "value": 2945, + "label": "天水市", + "children": [ + { + "value": 2947, + "label": "麦积区" + }, + { + "value": 2948, + "label": "清水县" + }, + { + "value": 2949, + "label": "秦安县" + }, + { + "value": 2950, + "label": "甘谷县" + }, + { + "value": 2951, + "label": "武山县" + }, + { + "value": 2952, + "label": "张家川回族自治县" + }, + { + "value": 2946, + "label": "秦州区" + } + ] + }, + { + "value": 2953, + "label": "武威市", + "children": [ + { + "value": 2954, + "label": "凉州区" + }, + { + "value": 2955, + "label": "民勤县" + }, + { + "value": 2956, + "label": "古浪县" + }, + { + "value": 2957, + "label": "天祝藏族自治县" + } + ] + }, + { + "value": 2958, + "label": "张掖市", + "children": [ + { + "value": 2959, + "label": "甘州区" + }, + { + "value": 2960, + "label": "肃南裕固族自治县" + }, + { + "value": 2961, + "label": "民乐县" + }, + { + "value": 2962, + "label": "临泽县" + }, + { + "value": 2963, + "label": "高台县" + }, + { + "value": 2964, + "label": "山丹县" + } + ] + }, + { + "value": 2965, + "label": "平凉市", + "children": [ + { + "value": 2966, + "label": "崆峒区" + }, + { + "value": 2967, + "label": "泾川县" + }, + { + "value": 2968, + "label": "灵台县" + }, + { + "value": 2969, + "label": "崇信县" + }, + { + "value": 2970, + "label": "华亭县" + }, + { + "value": 2971, + "label": "庄浪县" + }, + { + "value": 2972, + "label": "静宁县" + } + ] + }, + { + "value": 2973, + "label": "酒泉市", + "children": [ + { + "value": 2974, + "label": "肃州区" + }, + { + "value": 2975, + "label": "金塔县" + }, + { + "value": 2976, + "label": "瓜州县" + }, + { + "value": 2977, + "label": "肃北蒙古族自治县" + }, + { + "value": 2978, + "label": "阿克塞哈萨克族自治县" + }, + { + "value": 2979, + "label": "玉门市" + }, + { + "value": 2980, + "label": "敦煌市" + } + ] + }, + { + "value": 2981, + "label": "庆阳市", + "children": [ + { + "value": 2982, + "label": "西峰区" + }, + { + "value": 2983, + "label": "庆城县" + }, + { + "value": 2984, + "label": "环县" + }, + { + "value": 2985, + "label": "华池县" + }, + { + "value": 2986, + "label": "合水县" + }, + { + "value": 2987, + "label": "正宁县" + }, + { + "value": 2988, + "label": "宁县" + }, + { + "value": 2989, + "label": "镇原县" + } + ] + }, + { + "value": 2990, + "label": "定西市", + "children": [ + { + "value": 2991, + "label": "安定区" + }, + { + "value": 2992, + "label": "通渭县" + }, + { + "value": 2993, + "label": "陇西县" + }, + { + "value": 2994, + "label": "渭源县" + }, + { + "value": 2995, + "label": "临洮县" + }, + { + "value": 2996, + "label": "漳县" + }, + { + "value": 2997, + "label": "岷县" + } + ] + }, + { + "value": 2998, + "label": "陇南市", + "children": [ + { + "value": 3006, + "label": "徽县" + }, + { + "value": 3007, + "label": "两当县" + }, + { + "value": 3000, + "label": "成县" + }, + { + "value": 3001, + "label": "文县" + }, + { + "value": 3002, + "label": "宕昌县" + }, + { + "value": 3003, + "label": "康县" + }, + { + "value": 3004, + "label": "西和县" + }, + { + "value": 3005, + "label": "礼县" + }, + { + "value": 2999, + "label": "武都区" + } + ] + }, + { + "value": 3008, + "label": "临夏回族自治州", + "children": [ + { + "value": 3009, + "label": "临夏市" + }, + { + "value": 3010, + "label": "临夏县" + }, + { + "value": 3011, + "label": "康乐县" + }, + { + "value": 3012, + "label": "永靖县" + }, + { + "value": 3013, + "label": "广河县" + }, + { + "value": 3014, + "label": "和政县" + }, + { + "value": 3015, + "label": "东乡族自治县" + }, + { + "value": 3016, + "label": "积石山保安族东乡族撒拉族自治县" + } + ] + }, + { + "value": 3017, + "label": "甘南藏族自治州", + "children": [ + { + "value": 3024, + "label": "碌曲县" + }, + { + "value": 3025, + "label": "夏河县" + }, + { + "value": 3018, + "label": "合作市" + }, + { + "value": 3019, + "label": "临潭县" + }, + { + "value": 3020, + "label": "卓尼县" + }, + { + "value": 3021, + "label": "舟曲县" + }, + { + "value": 3022, + "label": "迭部县" + }, + { + "value": 3023, + "label": "玛曲县" + } + ] + } + ] + }, + { + "value": 3026, + "label": "青海省", + "children": [ + { + "value": 3027, + "label": "西宁市", + "children": [ + { + "value": 3028, + "label": "城东区" + }, + { + "value": 3029, + "label": "城中区" + }, + { + "value": 3030, + "label": "城西区" + }, + { + "value": 3031, + "label": "城北区" + }, + { + "value": 3032, + "label": "大通回族土族自治县" + }, + { + "value": 3033, + "label": "湟中县" + }, + { + "value": 3034, + "label": "湟源县" + } + ] + }, + { + "value": 3035, + "label": "海东地区", + "children": [ + { + "value": 3036, + "label": "平安县" + }, + { + "value": 3037, + "label": "民和回族土族自治县" + }, + { + "value": 3038, + "label": "乐都县" + }, + { + "value": 3039, + "label": "互助土族自治县" + }, + { + "value": 3040, + "label": "化隆回族自治县" + }, + { + "value": 3041, + "label": "循化撒拉族自治县" + } + ] + }, + { + "value": 3042, + "label": "海北藏族自治州", + "children": [ + { + "value": 3043, + "label": "门源回族自治县" + }, + { + "value": 3044, + "label": "祁连县" + }, + { + "value": 3045, + "label": "海晏县" + }, + { + "value": 3046, + "label": "刚察县" + } + ] + }, + { + "value": 3047, + "label": "黄南藏族自治州", + "children": [ + { + "value": 3048, + "label": "同仁县" + }, + { + "value": 3049, + "label": "尖扎县" + }, + { + "value": 3050, + "label": "泽库县" + }, + { + "value": 3051, + "label": "河南蒙古族自治县" + } + ] + }, + { + "value": 3052, + "label": "海南藏族自治州", + "children": [ + { + "value": 3053, + "label": "共和县" + }, + { + "value": 3054, + "label": "同德县" + }, + { + "value": 3055, + "label": "贵德县" + }, + { + "value": 3056, + "label": "兴海县" + }, + { + "value": 3057, + "label": "贵南县" + } + ] + }, + { + "value": 3058, + "label": "果洛藏族自治州", + "children": [ + { + "value": 3064, + "label": "玛多县" + }, + { + "value": 3059, + "label": "玛沁县" + }, + { + "value": 3060, + "label": "班玛县" + }, + { + "value": 3061, + "label": "甘德县" + }, + { + "value": 3062, + "label": "达日县" + }, + { + "value": 3063, + "label": "久治县" + } + ] + }, + { + "value": 3065, + "label": "玉树藏族自治州", + "children": [ + { + "value": 3066, + "label": "玉树县" + }, + { + "value": 3067, + "label": "杂多县" + }, + { + "value": 3068, + "label": "称多县" + }, + { + "value": 3069, + "label": "治多县" + }, + { + "value": 3070, + "label": "囊谦县" + }, + { + "value": 3071, + "label": "曲麻莱县" + } + ] + }, + { + "value": 3072, + "label": "海西蒙古族藏族自治州", + "children": [ + { + "value": 3074, + "label": "德令哈市" + }, + { + "value": 3075, + "label": "乌兰县" + }, + { + "value": 3076, + "label": "都兰县" + }, + { + "value": 3077, + "label": "天峻县" + }, + { + "value": 3073, + "label": "格尔木市" + } + ] + } + ] + }, + { + "value": 3078, + "label": "宁夏回族自治区", + "children": [ + { + "value": 3079, + "label": "银川市", + "children": [ + { + "value": 3081, + "label": "西夏区" + }, + { + "value": 3082, + "label": "金凤区" + }, + { + "value": 3083, + "label": "永宁县" + }, + { + "value": 3084, + "label": "贺兰县" + }, + { + "value": 3085, + "label": "灵武市" + }, + { + "value": 3080, + "label": "兴庆区" + } + ] + }, + { + "value": 3086, + "label": "石嘴山市", + "children": [ + { + "value": 3088, + "label": "惠农区" + }, + { + "value": 3089, + "label": "平罗县" + }, + { + "value": 3087, + "label": "大武口区" + } + ] + }, + { + "value": 3090, + "label": "吴忠市", + "children": [ + { + "value": 3091, + "label": "利通区" + }, + { + "value": 3092, + "label": "红寺堡区" + }, + { + "value": 3093, + "label": "盐池县" + }, + { + "value": 3094, + "label": "同心县" + }, + { + "value": 3095, + "label": "青铜峡市" + } + ] + }, + { + "value": 3096, + "label": "固原市", + "children": [ + { + "value": 3097, + "label": "原州区" + }, + { + "value": 3098, + "label": "西吉县" + }, + { + "value": 3099, + "label": "隆德县" + }, + { + "value": 3100, + "label": "泾源县" + }, + { + "value": 3101, + "label": "彭阳县" + } + ] + }, + { + "value": 3102, + "label": "中卫市", + "children": [ + { + "value": 3103, + "label": "沙坡头区" + }, + { + "value": 3104, + "label": "中宁县" + }, + { + "value": 3105, + "label": "海原县" + } + ] + } + ] + }, + { + "value": 3106, + "label": "新疆维吾尔自治区", + "children": [ + { + "value": 3107, + "label": "乌鲁木齐市", + "children": [ + { + "value": 3108, + "label": "天山区" + }, + { + "value": 3109, + "label": "沙依巴克区" + }, + { + "value": 3110, + "label": "新市区" + }, + { + "value": 3111, + "label": "水磨沟区" + }, + { + "value": 3112, + "label": "头屯河区" + }, + { + "value": 3113, + "label": "达坂城区" + }, + { + "value": 3114, + "label": "米东区" + }, + { + "value": 3115, + "label": "乌鲁木齐县" + } + ] + }, + { + "value": 3116, + "label": "克拉玛依市", + "children": [ + { + "value": 3117, + "label": "独山子区" + }, + { + "value": 3118, + "label": "克拉玛依区" + }, + { + "value": 3119, + "label": "白碱滩区" + }, + { + "value": 3120, + "label": "乌尔禾区" + } + ] + }, + { + "value": 3121, + "label": "吐鲁番地区", + "children": [ + { + "value": 3122, + "label": "吐鲁番市" + }, + { + "value": 3123, + "label": "鄯善县" + }, + { + "value": 3124, + "label": "托克逊县" + } + ] + }, + { + "value": 3125, + "label": "哈密地区", + "children": [ + { + "value": 3126, + "label": "哈密市" + }, + { + "value": 3127, + "label": "巴里坤哈萨克自治县" + }, + { + "value": 3128, + "label": "伊吾县" + } + ] + }, + { + "value": 3129, + "label": "昌吉回族自治州", + "children": [ + { + "value": 3130, + "label": "昌吉市" + }, + { + "value": 3131, + "label": "阜康市" + }, + { + "value": 3132, + "label": "呼图壁县" + }, + { + "value": 3133, + "label": "玛纳斯县" + }, + { + "value": 3134, + "label": "奇台县" + }, + { + "value": 3135, + "label": "吉木萨尔县" + }, + { + "value": 3136, + "label": "木垒哈萨克自治县" + } + ] + }, + { + "value": 3137, + "label": "博尔塔拉蒙古自治州", + "children": [ + { + "value": 3139, + "label": "精河县" + }, + { + "value": 3140, + "label": "温泉县" + }, + { + "value": 3138, + "label": "博乐市" + } + ] + }, + { + "value": 3141, + "label": "巴音郭楞蒙古自治州", + "children": [ + { + "value": 3142, + "label": "库尔勒市" + }, + { + "value": 3143, + "label": "轮台县" + }, + { + "value": 3144, + "label": "尉犁县" + }, + { + "value": 3145, + "label": "若羌县" + }, + { + "value": 3146, + "label": "且末县" + }, + { + "value": 3147, + "label": "焉耆回族自治县" + }, + { + "value": 3148, + "label": "和静县" + }, + { + "value": 3149, + "label": "和硕县" + }, + { + "value": 3150, + "label": "博湖县" + } + ] + }, + { + "value": 3151, + "label": "阿克苏地区", + "children": [ + { + "value": 3158, + "label": "乌什县" + }, + { + "value": 3159, + "label": "阿瓦提县" + }, + { + "value": 3160, + "label": "柯坪县" + }, + { + "value": 3152, + "label": "阿克苏市" + }, + { + "value": 3153, + "label": "温宿县" + }, + { + "value": 3154, + "label": "库车县" + }, + { + "value": 3155, + "label": "沙雅县" + }, + { + "value": 3156, + "label": "新和县" + }, + { + "value": 3157, + "label": "拜城县" + } + ] + }, + { + "value": 3161, + "label": "克孜勒苏柯尔克孜自治州", + "children": [ + { + "value": 3165, + "label": "乌恰县" + }, + { + "value": 3162, + "label": "阿图什市" + }, + { + "value": 3163, + "label": "阿克陶县" + }, + { + "value": 3164, + "label": "阿合奇县" + } + ] + }, + { + "value": 3166, + "label": "喀什地区", + "children": [ + { + "value": 3167, + "label": "喀什市" + }, + { + "value": 3168, + "label": "疏附县" + }, + { + "value": 3169, + "label": "疏勒县" + }, + { + "value": 3170, + "label": "英吉沙县" + }, + { + "value": 3171, + "label": "泽普县" + }, + { + "value": 3172, + "label": "莎车县" + }, + { + "value": 3173, + "label": "叶城县" + }, + { + "value": 3174, + "label": "麦盖提县" + }, + { + "value": 3175, + "label": "岳普湖县" + }, + { + "value": 3176, + "label": "伽师县" + }, + { + "value": 3177, + "label": "巴楚县" + }, + { + "value": 3178, + "label": "塔什库尔干塔吉克自治县" + } + ] + }, + { + "value": 3179, + "label": "和田地区", + "children": [ + { + "value": 3180, + "label": "和田市" + }, + { + "value": 3181, + "label": "和田县" + }, + { + "value": 3182, + "label": "墨玉县" + }, + { + "value": 3183, + "label": "皮山县" + }, + { + "value": 3184, + "label": "洛浦县" + }, + { + "value": 3185, + "label": "策勒县" + }, + { + "value": 3186, + "label": "于田县" + }, + { + "value": 3187, + "label": "民丰县" + } + ] + }, + { + "value": 3188, + "label": "伊犁哈萨克自治州", + "children": [ + { + "value": 3189, + "label": "伊宁市" + }, + { + "value": 3190, + "label": "奎屯市" + }, + { + "value": 3191, + "label": "伊宁县" + }, + { + "value": 3192, + "label": "察布查尔锡伯自治县" + }, + { + "value": 3193, + "label": "霍城县" + }, + { + "value": 3194, + "label": "巩留县" + }, + { + "value": 3195, + "label": "新源县" + }, + { + "value": 3196, + "label": "昭苏县" + }, + { + "value": 3197, + "label": "特克斯县" + }, + { + "value": 3198, + "label": "尼勒克县" + } + ] + }, + { + "value": 3199, + "label": "塔城地区", + "children": [ + { + "value": 3200, + "label": "塔城市" + }, + { + "value": 3201, + "label": "乌苏市" + }, + { + "value": 3202, + "label": "额敏县" + }, + { + "value": 3203, + "label": "沙湾县" + }, + { + "value": 3204, + "label": "托里县" + }, + { + "value": 3205, + "label": "裕民县" + }, + { + "value": 3206, + "label": "和布克赛尔蒙古自治县" + } + ] + }, + { + "value": 3207, + "label": "阿勒泰地区", + "children": [ + { + "value": 3214, + "label": "吉木乃县" + }, + { + "value": 3208, + "label": "阿勒泰市" + }, + { + "value": 3209, + "label": "布尔津县" + }, + { + "value": 3210, + "label": "富蕴县" + }, + { + "value": 3211, + "label": "福海县" + }, + { + "value": 3212, + "label": "哈巴河县" + }, + { + "value": 3213, + "label": "青河县" + } + ] + }, + { + "value": 3215, + "label": "石河子市" + }, + { + "value": 3216, + "label": "阿拉尔市" + }, + { + "value": 3217, + "label": "图木舒克市" + }, + { + "value": 3218, + "label": "五家渠市" + } + ] + }, + { + "value": 3219, + "label": "台湾省", + "children": [ + { + "value": 3220, + "label": "台北市" + }, + { + "value": 3221, + "label": "高雄市" + }, + { + "value": 3222, + "label": "基隆市" + }, + { + "value": 3223, + "label": "台中市" + }, + { + "value": 3224, + "label": "台南市" + }, + { + "value": 3225, + "label": "新竹市" + }, + { + "value": 3226, + "label": "嘉义市" + }, + { + "value": 3227, + "label": "台北县" + }, + { + "value": 3228, + "label": "宜兰县" + }, + { + "value": 3229, + "label": "桃园县" + }, + { + "value": 3230, + "label": "新竹县" + }, + { + "value": 3231, + "label": "苗栗县" + }, + { + "value": 3232, + "label": "台中县" + }, + { + "value": 3233, + "label": "彰化县" + }, + { + "value": 3234, + "label": "南投县" + }, + { + "value": 3235, + "label": "云林县" + }, + { + "value": 3236, + "label": "嘉义县" + }, + { + "value": 3237, + "label": "台南县" + }, + { + "value": 3238, + "label": "高雄县" + }, + { + "value": 3239, + "label": "屏东县" + }, + { + "value": 3240, + "label": "台东县" + }, + { + "value": 3241, + "label": "花莲县" + }, + { + "value": 3242, + "label": "澎湖县" + } + ] + }, + { + "value": 3243, + "label": "香港特别行政区", + "children": [ + { + "value": 3244, + "label": "香港岛", + "children": [ + { + "value": 3245, + "label": "中西区" + }, + { + "value": 3246, + "label": "湾仔区" + }, + { + "value": 3247, + "label": "东区" + }, + { + "value": 3248, + "label": "南区" + } + ] + }, + { + "value": 3249, + "label": "九龙", + "children": [ + { + "value": 3250, + "label": "油尖旺区" + }, + { + "value": 3251, + "label": "深水埗区" + }, + { + "value": 3252, + "label": "九龙城区" + }, + { + "value": 3253, + "label": "黄大仙区" + },{ + "value": 3254, + "label": "观塘区" + } + ] + }, + { + "value": 3255, + "label": "新界", + "children": [ + { + "value": 3256, + "label": "葵青区" + }, + { + "value": 3257, + "label": "荃湾区" + }, + { + "value": 3258, + "label": "屯门区" + },{ + "value": 3259, + "label": "元朗区" + }, + { + "value": 3260, + "label": "北区" + }, + { + "value": 3261, + "label": "大埔区" + },{ + "value": 3262, + "label": "沙田区" + }, + { + "value": 3263, + "label": "西贡区" + }, + { + "value": 3264, + "label": "离岛区" + } + ] + } + ] + }, + { + "value": 3265, + "label": "澳门特别行政区", + "children": [ + { + "value": 3266, + "label": "花地玛堂区", + "children": [ + { + "value": 3267, + "label": "青洲区" + }, + { + "value": 3268, + "label": "台山区" + }, + { + "value": 3269, + "label": "马场区" + }, + { + "value": 3270, + "label": "祐汉区" + }, + { + "value": 3271, + "label": "黑沙环区" + }, + { + "value": 3272, + "label": "黑沙环新填海区" + }, + { + "value": 3273, + "label": "望厦及水塘区" + }, + { + "value": 3274, + "label": "筷子基区" + } + ] + }, + { + "value": 3275, + "label": "圣安多尼堂区", + "children": [ + { + "value": 3276, + "label": "林茂塘区" + }, + { + "value": 3277, + "label": "高士德及雅廉访区" + }, + { + "value": 3278, + "label": "新桥区" + }, + { + "value": 3279, + "label": "沙梨头及大三巴区" + } + ] + }, + { + "value": 3280, + "label": "大堂区", + "children": [ + { + "value": 3281, + "label": "新口岸区" + }, + { + "value": 3282, + "label": "外港及南湾湖新填海区" + }, + { + "value": 3283, + "label": "中区" + } + ] + }, + { + "value": 3284, + "label": "望德堂区", + "children": [ + { + "value": 3285, + "label": "荷兰园区" + }, + { + "value": 3286, + "label": "东望洋区(松山区)" + } + ] + }, + { + "value": 3287, + "label": "风顺堂区", + "children": [ + { + "value": 3288, + "label": "下环区" + }, + { + "value": 3289, + "label": "南西湾及主教山区" + } + ] + }, + { + "value": 3290, + "label": "嘉模堂区", + "children": [ + { + "value": 3291, + "label": "海洋及小潭山区" + }, + { + "value": 3292, + "label": "氹仔中心区" + }, + { + "value": 3293, + "label": "大学及北安湾区" + }, + { + "value": 3294, + "label": "北安及大潭山区" + }, + { + "value": 3295, + "label": "氹仔旧城及马场区" + }, + { + "value": 3296, + "label": "澳门大学新校区" + } + ] + }, + { + "value": 3297, + "label": "圣方济各堂区", + "children": [ + { + "value": 3298, + "label": "路环市区" + }, + { + "value": 3299, + "label": "石排湾" + }, + { + "value": 3300, + "label": "九澳村" + }, + { + "value": 3301, + "label": "黑沙村" + } + ] + }, + { + "value": 3302, + "label": "路氹城" + }, + { + "value": 3303, + "label": "澳门新城区" + } + ] + } +] + + +export default RegionTree; diff --git a/super-screen/client/src/utils/webapi.js b/super-screen/client/src/utils/webapi.js new file mode 100644 index 0000000..0245b23 --- /dev/null +++ b/super-screen/client/src/utils/webapi.js @@ -0,0 +1,172 @@ +'use strict'; +import request from 'superagent'; + +export const ApiTable = { + login: 'login', + logout: 'logout', + validatePhone: 'validate/phone', + //标签管理 + getTags: 'tags', + postTagSets: 'tag-sets', + putTagSets: 'tag-sets/{id}', + delTagSets: 'tag-sets/{id}', + postTags: 'tags', + putTags: 'tags/{id}', + delTags: 'tags/{id}', + //元数据管理-模型管理 + getMetaModelList: 'meta/models', + addMetaModel: 'meta/model', + modifyMetaModel: 'meta/model/{id}', + //最新元数据-资源目录 + getResourceCatalog: 'resource-catalog', + postResourceCatalog: 'resource-catalog', + putResourceCatalog: 'resource-catalog/{id}', + delResourceCatalog: 'resource-catalog/{id}', + listStructuredData: 'listStructuredData', + publishingServices: 'publishing/services', + + //最新元数据-元数据列表查询 + getMetadataDatabases: 'metadata/databases', + getMetadataFiles: 'metadata/files', + getMetadataRestapis: 'metadata/restapis', + getMetadataModels: 'metadata/models', + //库表元数据增删改、等配置 + postMetadataDatabases: 'metadata/databases', + putMetadataDatabases: 'metadata/databases/{id}', + delMetadataDatabases: 'metadata/databases/{id}', + getMetadataDatabasesById: 'metadata/databases/{id}', + postTagMetadata: 'tag/metadata', + getTagMetadata: 'tag/metadata/{id}', + getMetadataResourceApplications: 'resource-consumption/applications', + postMetadataResourceApplications: 'resource-consumption/applications', + //文件元数据增删改 + postMetadataFiles: 'metadata/files', + putMetadataFiles: 'metadata/files/{id}', + delMetadataFiles: 'metadata/files/{id}', + //接口元数据增删改 + postMetadataRestapis: 'metadata/restapis', + putMetadataRestapis: 'metadata/restapis/{id}', + delMetadataRestapis: 'metadata/restapis/{id}', + + //业务元数据管理 + getBusinessMetadataDatabases: 'business/metadata/databases', + postBusinessMetadataDatabases: 'business/metadata/databases', + putBusinessMetadataDatabases: 'business/metadata/databases/{id}', + delBusinessMetadataDatabases: 'business/metadata/databases/{id}', + getBusinessMetadataFiles: 'business/metadata/files', + postBusinessMetadataFiles: 'business/metadata/files', + putBusinessMetadataFiles: 'business/metadata/files/{id}', + delBusinessMetadataFiles: 'business/metadata/files/{id}', + getBusinessMetadataRestapis: 'business/metadata/restapis', + postBusinessMetadataRestapis: 'business/metadata/restapis', + putBusinessMetadataRestapis: 'business/metadata/restapis/{id}', + delBusinessMetadataRestapis: 'business/metadata/restapis/{id}', + + //元数据采集-数据源管理 + pgCheckConnect: 'adapter/check/connect', + addDataSource: 'meta/acq/dataSource', + getAdapters: 'meta/acq/adapters', + getDataSources: 'meta/acq/dataSources', + modifyDataSource: 'acq/dataSource/{id}', + + //元数据采集-采集任务管理 + addTask: 'meta/acq/task', + getTasks: 'meta/acq/tasks', + modifyTask: 'acq/task/{id}', + runTask: 'run/acq/task', + + //采集日志 + getLogs: "meta/acq/logs", + + //资源消费 + approveList: 'resource/approve', + //用户管理 + getUserList: 'meta/members', + addUser: 'meta/member', + modifyUser: 'meta/member/{id}', + + //元数据检索 + searchMetadata: "meta/data/search", + + //数据质量 + standardDocFolders: 'standard-doc-folders', + standardDocs: 'standard-docs', + postFolderFile: 'postFolderFile', + businessRules: 'business-rules', + delBusinessRules: 'business-rules/{id}', + regularBasis: 'regular-basis', + fetchFiles: 'fetchFiles', + getQualityInspection: 'quality-inspection', + + //数据安全规范上传 + specifications: 'data-security/specifications', + delSpecifications: 'data-security/specifications/{fileIds}', + + //元数据检索 + searchMetadata: "meta/data/search", + + //备份恢复 + getBackupsList: 'meta/backups', + addBackups: 'meta/backups', + modifyBackups: 'meta/backups/{id}', + restoreBackups: 'backups/restore', + + //REST服务 + serviceManagement: 'service-management', + delServiceManagement: 'service-management/{id}', + lookField: 'lookField', + +}; + +export const RouteTable = { + fileUpload: '/_upload/new', + cleanUpUploadTrash: '/_upload/cleanup', +}; + +const resultHandler = (resolve, reject) => (err, res) => { + if (err) { + if (err.status == 401) { + // 退出到登录页 + const user = JSON.parse(sessionStorage.getItem('user')); + sessionStorage.clear(); + window.document.location.replace('/login'); + reject('unauth'); + } else { + reject({ + status: err.status || 0, + body: err.response ? err.response.body : err.message + }); + } + reject({ + status: err.status || 0, + body: err.response ? err.response.body : err.message + }); + } else { + resolve(res.body); + } +}; +export const buildRoute = (url) => { + const user = JSON.parse(sessionStorage.getItem('user')); + if (user == null) { + return url; + } + let connector = url.indexOf('?') === -1 ? '?' : '&'; + return `${url}${connector}token=${user.token}`; +}; +export class RouteRequest { + static get = (url, query) => + new Promise((resolve, reject) => { + request.get(buildRoute(url)).query(query).end(resultHandler(resolve, reject)); + }); + + static post = (url, data, query) => + new Promise((resolve, reject) => { + request.post(buildRoute(url)).query(query).send(data).end(resultHandler(resolve, reject)); + }); + + static delete = (url, data, query) => + new Promise((resolve, reject) => { + request.delete(buildRoute(url)).query(query).send(data).end(resultHandler(resolve, reject)); + }); +} + diff --git a/super-screen/config.js b/super-screen/config.js new file mode 100644 index 0000000..685e278 --- /dev/null +++ b/super-screen/config.js @@ -0,0 +1,145 @@ +/** + * Created by rain on 2016/1/25. + */ + +'use strict'; +/*jslint node:true*/ +const path = require('path'); +/*这种以CommonJS的同步形式去引入其它模块的方式代码更加简洁:获取组件*/ +const os = require('os'); +const moment = require('moment'); +const args = require('args'); +const dev = process.env.NODE_ENV == 'development'; +dev && console.log('\x1B[33m%s\x1b[0m', '请遵循并及时更新 readme.md,维护良好的开发环境,媛猿有责'); +// // 启动参数 +args.option(['p', 'port'], '启动端口'); +args.option(['u', 'api-url'], 'webapi的URL'); +args.option('qnak', 'qiniuAccessKey'); +args.option('qnsk', 'qiniuSecretKey'); +args.option('qnbkt', 'qiniuBucket'); +args.option('qndmn', 'qiniuDomain'); +const flags = dev ? args.parse(process.argv) : {}; + +const FS_UNIAPP_API = process.env.FS_UNIAPP_API || flags.apiUrl; + +const ANXINCLOUD_QINIU_ACCESSKEY = process.env.ANXINCLOUD_QINIU_ACCESSKEY || flags.qnak; +const ANXINCLOUD_QINIU_SECRETKEY = process.env.ANXINCLOUD_QINIU_SECRETKEY || flags.qnsk; +const ANXINCLOUD_QINIU_BUCKET_RESOURCE = process.env.ANXINCLOUD_QINIU_BUCKET_RESOURCE || flags.qnbkt; +const ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE = process.env.ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE || flags.qndmn; + +//阿里OSS +const ALI_OSS_ACCESSKEY = process.env.ALI_OSS_ACCESSKEY || flags.aliOssAccessKey; +const ALI_OSS_SECRETKET = process.env.ALI_OSS_SECRETKET || flags.aliOssSecretKey; +const ALI_OSS_BUCKET = process.env.ALI_OSS_BUCKET || flags.aliOssBucket; +const ALI_OSS_REGION = process.env.ALI_OSS_REGION || flags.aliOssRegion; + +if ( + !FS_UNIAPP_API + // || !ANXINCLOUD_QINIU_ACCESSKEY + // || !ANXINCLOUD_QINIU_SECRETKEY + // || !ANXINCLOUD_QINIU_BUCKET_RESOURCE + // || !ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE +) { + console.log('缺少启动参数,异常退出'); + args.showHelp(); + process.exit(-1); +} + +const product = { + port: flags.port || 8080, + staticDirs: [path.join(__dirname, './client')], + mws: [ + { + entry: require('./middlewares/proxy').entry, + opts: { + host: FS_UNIAPP_API, + match: /^\/_api\//, + } + }, + // { + // entry: require('./middlewares/attachment').entry, + // opts: { + // qiniu: { + // accessKey: ANXINCLOUD_QINIU_ACCESSKEY, + // secretKey: ANXINCLOUD_QINIU_SECRETKEY, + // bucket: ANXINCLOUD_QINIU_BUCKET_RESOURCE, + // domain: ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE + // }, + // maxSize: 104857600, // 100M + // uploadPath: 'other' + // } + // }, + { + entry: require('./routes').entry, + opts: { + apiUrl: FS_UNIAPP_API, + staticRoot: './client', + qiniu: { + fetchUrl: '/_file-server', + domain: ANXINCLOUD_QINIU_DOMAIN_QNDMN_RESOURCE + }, + aliOss: { + fetchUrl: '/_file-ali-server', + accessKey: ALI_OSS_ACCESSKEY, + secretKey: ALI_OSS_SECRETKET, + bucket: ALI_OSS_BUCKET, + region: ALI_OSS_REGION + } + } + }, + { + entry: require('./client').entry,// 静态信息 + opts: {} + } + ], + logger: { + level: 'debug', + json: false, + filename: path.join(__dirname, 'log', 'runtime.txt'), + colorize: true, + maxsize: 1024 * 1024 * 5, + rotationFormat: false, + zippedArchive: true, + maxFiles: 10, + prettyPrint: true, + label: '', + timestamp: () => moment().format('YYYY-MM-DD HH:mm:ss.SSS'), + eol: os.EOL, + tailable: true, + depth: null, + showLevel: true, + maxRetries: 1 + } +}; +if (product.frontParams) { + const patt = /[^A-Z|_]+/ + for (let k in product.frontParams) { + if (!k.startsWith('FS_') || patt.test(k)) { + console.warn(`参数 ${k} 当以大写字母和下划线组成 且以 FS_ 开头`); + process.exit(-1); + } + } +} + +let config; +if (dev) { + config = { + port: product.port, + staticDirs: product.staticDirs, + frontParams: product.frontParams, + mws: product.mws.concat([ + { + entry: require('./middlewares/webpack-dev').entry, + opts: { + frontParams: product.frontParams, + } + } + ]), + logger: product.logger + } + config.logger.filename = path.join(__dirname, 'log', 'development.txt'); +} else { + config = product; +} + +module.exports = config;//区分开发和发布 \ No newline at end of file diff --git a/super-screen/jsconfig.json b/super-screen/jsconfig.json new file mode 100644 index 0000000..99271a0 --- /dev/null +++ b/super-screen/jsconfig.json @@ -0,0 +1,15 @@ +{ + + "compilerOptions": { + "target": "es6", + "module": "commonjs", + "allowSyntheticDefaultImports": true + }, + "exclude": [ + "node_modules", + "bower_components", + "jspm_packages", + "tmp", + "temp" + ] +} diff --git a/super-screen/middlewares/attachment.js b/super-screen/middlewares/attachment.js new file mode 100644 index 0000000..611d675 --- /dev/null +++ b/super-screen/middlewares/attachment.js @@ -0,0 +1,23 @@ +/** + * Created by PengLing on 2018/1/2. + */ +'use strict'; + +const Attachment = require('fs-attachment'); + +module.exports = { + entry: function (app, router, opts) { + const attachment = new Attachment(opts); + + app.fs = app.fs || {}; + app.fs.attachment = attachment; + + app.fs.logger.log('debug', 'init fs.attachment and inject it into app(app.fs.attachment) and runtime ctx(ctx.fs.attachment)'); + + return async (ctx, next) => { + ctx.fs = ctx.fs || {}; + ctx.fs.attachment = attachment; + await next(); + }; + } +}; \ No newline at end of file diff --git a/super-screen/middlewares/proxy.js b/super-screen/middlewares/proxy.js new file mode 100644 index 0000000..c9a2623 --- /dev/null +++ b/super-screen/middlewares/proxy.js @@ -0,0 +1,16 @@ +'use strict'; + +const proxy = require('koa-proxy'); +const convert = require('koa-convert'); + +module.exports = { + entry: function (app, router, opts) { + app.use(convert(proxy({ + host: opts.host, + match: opts.match, + map: function (path) { + return path.replace(opts.match, ''); + } + }))); + } +}; \ No newline at end of file diff --git a/super-screen/middlewares/webpack-dev.js b/super-screen/middlewares/webpack-dev.js new file mode 100644 index 0000000..369a5c4 --- /dev/null +++ b/super-screen/middlewares/webpack-dev.js @@ -0,0 +1,53 @@ +'use strict'; +const express = require('express') +const webpack = require('webpack'); +const devConfig = require('../webpack.config'); +const middleware = require('webpack-dev-middleware'); +const proxy = require('koa-better-http-proxy'); +const url = require('url'); + +module.exports = { + entry: function (app, router, opts) { + devConfig.plugins.push( + new webpack.DefinePlugin({ + 'process.env.NODE_ENV': JSON.stringify('development'), + ...(() => { + let nextParams = {} + for (let k in opts.frontParams) { + nextParams[k] = JSON.stringify(opts.frontParams[k]) + } + return nextParams + })() + }), + ) + + const compiler = webpack(devConfig); + + app.use(proxy('http://localhost:5501', { + filter: function (ctx) { + return /\/build/.test(url.parse(ctx.url).path); + }, + proxyReqPathResolver: function (ctx) { + return 'client' + url.parse(ctx.url).path; + } + })); + + app.use(proxy('http://localhost:5501', { + filter: function (ctx) { + return /\/$/.test(url.parse(ctx.url).path); + }, + proxyReqPathResolver: function (ctx) { + return 'client/build/index.html'; + } + })); + + const server = express(); + server.use(middleware(compiler)); + //server.use(require("webpack-hot-middleware")(compiler)); + server.listen('5401', function (err) { + if (err) { + console.log(err); + } + }) + } +}; diff --git a/super-screen/package.json b/super-screen/package.json new file mode 100644 index 0000000..904f85f --- /dev/null +++ b/super-screen/package.json @@ -0,0 +1,101 @@ +{ + "name": "fs-anxincloud-4.0", + "version": "1.0.0", + "description": "anxincloud-4.0", + "main": "server.js", + "scripts": { + "test": "mocha", + "start": "cross-env NODE_ENV=development npm run start-params", + "start-params": "node server -p 5500 -u http://localhost:4400", + "deploy": "export NODE_ENV=production && npm run build && node server", + "build-dev": "set NODE_ENV=development&&webpack --config webpack.config.js", + "build": "set NODE_ENV=production&&webpack --config webpack.config.prod.js" + }, + "keywords": [ + "app" + ], + "author": "", + "license": "ISC", + "devDependencies": { + "@babel/core": "^7.14.6", + "@babel/plugin-proposal-class-properties": "^7.14.5", + "@babel/plugin-proposal-object-rest-spread": "^7.14.7", + "@babel/plugin-transform-runtime": "^7.14.5", + "@babel/polyfill": "^7.12.1", + "@babel/preset-env": "^7.14.7", + "@babel/preset-react": "^7.14.5", + "babel-loader": "^8.2.2", + "babel-plugin-import": "^1.13.3", + "babel-polyfill": "^6.26.0", + "connected-react-router": "^6.8.0", + "css-loader": "^3.5.0", + "express": "^4.17.1", + "file-loader": "^6.0.0", + "html-webpack-plugin": "^4.5.0", + "immutable": "^4.0.0-rc.12", + "less": "^3.12.2", + "less-loader": "^7.0.2", + "natty-fetch": "^2.5.3", + "nprogress": "^0.2.0", + "path-to-regexp": "^2.4.0", + "perfect-scrollbar": "^1.5.5", + "react": "^17.0.0", + "react-copy-to-clipboard": "^5.0.1", + "react-dnd": "^10.0.2", + "react-dnd-html5-backend": "^10.0.2", + "react-dom": "^17.0.0", + "react-if": "^2.2.1", + "react-jsonschema-form": "^1.8.1", + "react-quill": "^1.3.5", + "react-redux": "^7.2.1", + "react-router-dom": "^5.2.0", + "react-router-redux": "^4.0.8", + "redux": "^4.0.5", + "redux-thunk": "^2.3.0", + "redux-undo": "^1.0.1", + "style-loader": "^2.0.0", + "webpack": "^5.3.2", + "webpack-bundle-analyzer": "^4.1.0", + "webpack-cli": "^4.2.0", + "webpack-dev-middleware": "^4.0.2", + "webpack-hot-middleware": "^2.25.0" + }, + "dependencies": { + "@ant-design/icons": "^4.6.2", + "@ant-design/pro-form": "^1.34.0", + "@ant-design/pro-table": "^2.48.0", + "@antv/g6": "^4.2.5", + "@douyinfe/semi-ui": "^2.28.1", + "@fs/attachment": "^1.0.0", + "@jiaminghi/data-view-react": "^1.2.5", + "@peace/components": "0.0.35", + "@peace/utils": "0.0.37", + "ahooks": "^3.7.4", + "ali-oss": "^6.17.1", + "antd": "^4.24.5", + "args": "^5.0.1", + "cron-js-parser": "^1.0.17", + "cron-parser": "^4.8.1", + "cross-env": "^7.0.3", + "crypto-js": "^4.1.1", + "echarts": "^5.4.1", + "echarts-for-react": "^3.0.2", + "file-saver": "^2.0.5", + "fs-attachment": "^1.0.0", + "fs-web-server-scaffold": "^1.0.6", + "jszip": "^3.10.1", + "koa-better-http-proxy": "^0.2.5", + "koa-proxy": "^1.0.0-alpha.3", + "koa-view": "^2.1.4", + "moment": "^2.22.0", + "npm": "^7.20.6", + "path": "^0.12.7", + "react-router-breadcrumbs-hoc": "^4.0.1", + "simplebar-react": "^3.2.4", + "superagent": "^6.1.0", + "uuid": "^8.3.1", + "webpack-dev-server": "^3.11.2", + "xlsx": "^0.16.9", + "xmlhttprequest": "^1.8.0" + } +} \ No newline at end of file diff --git a/super-screen/readme.md b/super-screen/readme.md index e69de29..91981ce 100644 --- a/super-screen/readme.md +++ b/super-screen/readme.md @@ -0,0 +1,231 @@ +创建时间:2021/08/19 +项目名称: +## 1. 文档维护: + +- 文档相关内容若有更改,请及时更新文档,以备后来者查询; + +## 2. 项目开发: + +- 请遵循此文档约定的目录结构与约定 + +```js + |-- .babelrc + |-- color.js + |-- config.js + |-- Dockerfile + |-- jsconfig.json + |-- package.json + |-- readme.md + |-- server.js + |-- webpack.config.js + |-- webpack.config.prod.js + |-- .vscode + | |-- launch.json + | |-- settings.json + |-- client + | |-- index.ejs + | |-- index.html // 当前 html 文件 + | |-- index.js + | |-- assets // 资源文件 + | | |-- color.less + | | |-- files + | | |-- fonticon + | | |-- font_sc + | | |-- images + | | |-- avatar + | | |-- loginUi + | |-- src // 项目代码 + | |-- app.js // 由此开始并加载模块 + | |-- index.js + | |-- components // 公用组件 + | | |-- index.js // 由此导出组件 + | | |-- Upload + | | |-- index.js + | |-- layout // 项目布局以及初始化等操作 + | | |-- index.js + | | |-- actions + | | | |-- global.js + | | |-- components + | | | |-- footer + | | | | |-- index.js + | | | | |-- style.css + | | | |-- header + | | | | |-- index.js + | | | | |-- style.css + | | | |-- sider + | | | |-- index.js + | | |-- containers + | | | |-- index.js + | | | |-- layout + | | | | |-- breadcrumb.js // 面包屑组件 + | | | | |-- index.js + | | | | |-- index.less + | | | |-- no-match + | | | |-- index.js + | | |-- reducers + | | | |-- ajaxResponse.js + | | | |-- global.js // 全局数据,主要包含屏幕可视宽高、所有的 action 等 + | | | |-- index.js + | | |-- store + | | |-- index.js + | | |-- store.dev.js + | | |-- store.prod.js + | |-- sections // 各功能模块 + | | |-- auth // 比较特别的 Auth 模块,目前 action、reducer 依然采用原始写法;包含登录、忘记密码等项目基本功能页面 + | | | |-- index.js + | | | |-- routes.js + | | | |-- actions + | | | | |-- auth.js + | | | | |-- index.js + | | | |-- components + | | | |-- containers + | | | | |-- index.js + | | | | |-- login.js + | | | |-- reducers + | | | | |-- auth.js + | | | | |-- index.js + | | | |-- __tests__ + | | |-- example // 示例模块,一般的功能模块应遵循此结构 + | | |-- index.js // 由此导出该模块信息,应包括一个 key 值,actions 等 + | | |-- nav-item.js // 用于生成菜单项,此文件内可以进行权限判断 + | | |-- routes.js // 路由文件 + | | |-- style.less // 样式文件,若样式并不是非常多,每个模块一个样式文件即可 + | | |-- actions + | | | |-- example.js // 具体的 action 操作 + | | | |-- index.js // 由此导出该项目的 action + | | |-- components // 组件 + | | |-- containers // 容器,此文件夹内应只包括该模块第一层级的页面 + | | | |-- example.js + | | | |-- index.js + | | |-- reducers // 若采用封装后的 action 写法,则 reducer 可不写 + | | |-- index.js + | |-- styles // 待初始化的主题样式 + | | |-- antd.less + | | |-- theme.less + | |-- themes // 初始化后的主题样式文件 + | | |-- dark.json + | | |-- light.json + | | |-- theme.json + | |-- utils // + | |-- authCode.js + | |-- func.js // 常用函数 + | |-- index.js + | |-- region.js + | |-- webapi.js // api 路由 + |-- log + |-- middlewares + | |-- proxy.js + | |-- webpack-dev.js + |-- routes + | |-- index.js + | |-- attachment + |-- typings + |-- node + | |-- node.d.ts + |-- react + |-- react.d.ts +``` + +- 封装后一般 action 写法: + + `@peace/utils 的 actionHelp 中有详细注释` + + ``` js + 'use strict'; + + import { basicAction } from '@peace/utils' + import { ApiTable } from '$utils' + + export function getMembers(orgId) { + return dispatch => basicAction({ + type: 'get', + dispatch: dispatch, + actionType: 'GET_MEMBERS', + url: `${ApiTable.getEnterprisesMembers.replace('{enterpriseId}', orgId)}`, + msg: { error: '获取用户列表失败' }, + reducer: { name: 'members' } + }); + } + ``` + +1. 若 type=post,则可以使用 data 属性发送对象格式数据; + +2. reducer.name 会作为该 action 对应的 reducer 的名字,从 state 里可以解构此变量,获得该 action 异步或其他操作获得的数据; + +3. msg 可以发送 `{ option:'获取用户列表' }` ,则 actionHelp 会自动将其处理为失败和成功两种情况; + + 若单独写 success 或 error 的 key,则只在成功或失败的时候进行提示; + +4. 后续可以优化:type=get 时候, + + 使用 query 属性将数据传递,在 @peace/utils 的 actionHelp 中将其添加到路由后面;eg. `{ enterpriseId: orgId }` + + 使用 replace 属性传递对象数据,对象数据中将被替换的值为key,替换的值为 value,然后再 actionHelp 中更改路由;eg. `{ "{enterpriseId}": orgId}` + +5. 最终取得的 reducer 中的数据格式一般为: + ``` js + { + data: xxx, // 接口返回的数据格式 + isRequesting: false, // 请求状态 + success: true, // 以此判断请求是否成功,不用再以 payload.type 判断 + } + ``` + +- actions 的引用 + + 从 reducer 的 state.global.actions 里引用具体 action + + ```js + const Example = (props) => { + const { dispatch, actions, user, loading } = props + + useEffect(() => { + dispatch(actions.example.getMembers(user.orgId)) + }, []) + + return ( + + example + + ) + } + + function mapStateToProps(state) { + const { auth, global, members } = state; + return { + loading: members.isRequesting, + user: auth.user, + actions: global.actions, + members: members.data + }; + } + + export default connect(mapStateToProps)(Example); + ``` + +- 一般路由配置 + ```js + 'use strict'; + import { Example, } from './containers'; + + export default [{ + type: 'inner', // 是否在layout 内,如果为outer,则看不到 header、footer、sider等布局,比如登陆页面 + route: { + path: '/example', + key: 'example', + breadcrumb: '栗子', + // 不设置 component 则面包屑禁止跳转 + childRoutes: [{ + path: '/e1', // 自路由不必复写父路由内容,会自动拼接; 则此处组件的实际路由为 /example/e1 + key: 'e1', + component: Example, + breadcrumb: '棒子', + }] + } + }]; + ``` +- cross-env 的使用限制 + + cross-env 可以统一不同操作系统下环境变量的导出方式,不用再在 windows 下写 set;linux 下写 export; 可以统一以 cross-env NODE_ENV=DEV 代替; + + 但是这样的话就不能在同一条运行的命令中使用 && 切割,因为会把命令切割为两个环境,则最终拿不到我们设置的变量; \ No newline at end of file diff --git a/super-screen/routes/attachment/index.js b/super-screen/routes/attachment/index.js new file mode 100644 index 0000000..bfcf516 --- /dev/null +++ b/super-screen/routes/attachment/index.js @@ -0,0 +1,240 @@ +'use strict'; +const request = require('superagent'); +const parse = require('async-busboy'); +const path = require('path') +const fs = require('fs'); +const OSS = require('ali-oss'); +const uuid = require('uuid'); + +const UploadPath = { + project: ['.txt', '.dwg', '.doc', '.docx', '.xls', '.xlsx', ".csv", '.pdf', '.pptx', '.png', '.jpg', '.svg', '.rar', '.zip', '.jpeg', '.mp4'], + report: ['.doc', '.docx', '.xls', '.xlsx', ".csv", '.pdf'], + data: ['.txt', '.xls', '.xlsx', ".csv"], + image: ['.png', '.jpg', '.svg'], + three: ['.js'], + video: ['.mp4'] +}; +const ext = { + project: ['.txt', '.dwg', '.doc', '.docx', '.xls', '.xlsx', ".csv", '.pdf', '.pptx', '.png', '.jpg', '.gif', '.svg', '.rar', '.zip', '.jpeg', '.mp4'], + report: [".doc", ".docx", ".xls", ".xlsx", ".pdf"], + data: [".txt", ".xls", ".xlsx"], + image: [".png", ".jpg", ".svg"], + three: [".js"], + video: [".mp4"], + bpmn: [".bpmn", ".bpmn20.xml", ".zip", ".bar"], + app: [".apk"] +} + +module.exports = { + entry: function (app, router, opts) { + let download_ = async function (ctx, next) { + const { fetchUrl } = opts.qiniu; + const { fetchUrl: aliFetchUrl, bucket, region } = opts.aliOss + if (ctx.path && ctx.path.includes(fetchUrl)) { + try { + const { filename } = ctx.request.query; + const fkey = decodeURI(ctx.path.slice(fetchUrl.length + 1)).replace(/\.json$/, '.js'); + if (ctx.path) { + const extNames = ctx.path.split('.'); + app.fs.logger.log('info', 'extNames', extNames); + if (extNames.length > 0) { + let fileType = extNames[extNames.length - 1].toLowerCase(); + if (fileType === 'pdf') { + ctx.type = 'application/pdf'; + app.fs.logger.log('info', 'application/pdf', fileType); + } + } + } + const publicDownloadUrl = await app.fs.attachment.download(fkey); + ctx.status = 200; + if (filename) ctx.attachment(filename); + ctx.body = request.get(publicDownloadUrl); + } catch (err) { + ctx.fs.logger.error(err); + ctx.status = 404; + ctx.body = { error: 'file not found.' }; + } + } else if (ctx.path && ctx.path.includes(aliFetchUrl)) { + const { filename } = ctx.request.query; + const fkey = decodeURI(ctx.path.slice(aliFetchUrl.length + 1)).replace(/\.json$/, '.js'); + if (ctx.path) { + const extNames = ctx.path.split('.'); + app.fs.logger.log('info', 'extNames', extNames); + if (extNames.length > 0) { + let fileType = extNames[extNames.length - 1].toLowerCase(); + if (fileType === 'pdf') { + ctx.type = 'application/pdf'; + app.fs.logger.log('info', 'application/pdf', fileType); + } + } + } + const publicDownloadUrl = `http://${bucket}.${region}.aliyuncs.com/${encodeURIComponent(fkey)}` + ctx.status = 200; + ctx.body = request.get(publicDownloadUrl); + } else { + await next(); + } + }; + + let upload = async function (ctx, next) { + try { + const { files } = await parse(ctx.req); + const file = files[0]; + const extname = path.extname(file.filename).toLowerCase(); + const fileType = ctx.query.type || "image"; + const fileFolder = ctx.query.fileFolder || 'common'; + if (ext[fileType].indexOf(extname) < 0) { + ctx.status = 400; + ctx.body = JSON.stringify({ name: 'UploadFailed', message: '文件格式无效' }); + return; + } + const date = new Date().toLocaleDateString(); + const time = new Date().getTime(); + let fileName = time + '_' + file.filename; + let saveFile = path.join(__dirname, '../../', `/client/assets/files/${fileFolder}`, fileName); + const pathUrl = `./client/assets/files/${fileFolder}`; + + const res1 = fs.existsSync(`./client/assets/files/${fileFolder}`); + !res1 && fs.mkdirSync(`./client/assets/files/${fileFolder}`); + const res = fs.existsSync(pathUrl); + !res && fs.mkdirSync(pathUrl); + let stream = fs.createWriteStream(saveFile); + fs.createReadStream(file.path).pipe(stream); + stream.on('error', function (err) { + app.fs.logger.log('error', '[Upload Heatmap]', err); + }); + ctx.status = 200; + ctx.body = { realName: fileName, filename: path.join(`/assets/files/${fileFolder}`, fileName), name: 'UploadSuccess', message: '上传成功' }; + } catch (err) { + ctx.status = 500; + ctx.fs.logger.error(err); + ctx.body = { err: 'upload error.' }; + } + } + + let remove = async function (ctx, next) { + try { + const fkeys = ctx.request.body; + let removeUrl = path.join(__dirname, '../../', './client', fkeys.url); + const res = fs.existsSync(removeUrl); + if (!res) { + ctx.status = 400; + ctx.body = JSON.stringify({ name: 'DeleteFailed', message: '文件地址不存在' }); + return; + } + fs.unlink(removeUrl, function (error) { + if (error) { + console.log(error); + } + }) + ctx.status = 200; + ctx.body = { name: 'DeleteSuccess.', message: '删除成功' }; + } catch (err) { + ctx.status = 500; + ctx.fs.logger.error(err); + ctx.body = { err: 'upload cleanup error.' }; + } + } + let upload_ = async function (ctx, next) { + let fkey = null; + try { + const { p } = ctx.params; + const { files } = await parse(ctx.req); + const file = files[0]; + const extname = path.extname(file.filename).toLowerCase(); + if (!UploadPath[p]) { + ctx.status = 400; + ctx.body = JSON.stringify({ error: '附件存放的文件夹名称无效' }); + return; + } else if (UploadPath[p].indexOf(extname) < 0) { + ctx.status = 400; + ctx.body = JSON.stringify({ error: '文件格式无效' }); + return; + } else { + const fileInfo = await ctx.app.fs.attachment.upload(file, { uploadPath: p }); + fkey = fileInfo.key; + ctx.body = { uploaded: fkey }; + } + } catch (err) { + ctx.status = 500; + ctx.fs.logger.error(err); + ctx.body = { err: 'upload error.' }; + } + } + + const uploadAliOSS = async (ctx,) => { + // 这个是上传到阿里 + try { + const { aliOss } = opts + const { p = 'default' } = ctx.params; + const { files } = await parse(ctx.req); + const file = files[0]; + const filename = file.filename || path.basename(file); + + const client = new OSS({ + // yourRegion填写Bucket所在地域.以华东1(杭州)为例,Region填写为oss-cn-hangzhou. + region: aliOss.region, + // 阿里云账号AccessKey拥有所有API的访问权限,风险很高.强烈建议您创建并使用RAM用户进行API访问或日常运维,请登录RAM控制台创建RAM用户. + accessKeyId: aliOss.accessKey, + accessKeySecret: aliOss.secretKey, + // 填写Bucket名称,例如examplebucket. + bucket: aliOss.bucket, + }); + + let uploadPath = path.posix.join(p, uuid.v4(), filename); + let result = await client.putStream( + uploadPath, + file, + // { contentLength: size } + ); + + ctx.status = 200; + ctx.body = { + key: result.name, + uploaded: result.name, + url: result.url, + }; + } catch (error) { + ctx.status = 400; + ctx.fs.logger.error(error); + ctx.body = { err: 'upload error.' }; + } + } + + const downloadFromAli = async (ctx) => { + try { + const { aliOss } = opts + const { path, filename } = ctx.query + const client = new OSS({ + // yourRegion填写Bucket所在地域.以华东1(杭州)为例,Region填写为oss-cn-hangzhou. + region: aliOss.region, + // 阿里云账号AccessKey拥有所有API的访问权限,风险很高.强烈建议您创建并使用RAM用户进行API访问或日常运维,请登录RAM控制台创建RAM用户. + accessKeyId: aliOss.accessKey, + accessKeySecret: aliOss.secretKey, + // 填写Bucket名称,例如examplebucket. + bucket: aliOss.bucket, + }); + + const filename_ = filename || path.split('/').pop() + + const result = await client.get(path); + ctx.status = 200; + ctx.set('Content-Type', 'application/x-xls'); + ctx.set('Content-disposition', 'attachment; filename=' + filename_); + ctx.body = result.content; + } catch (error) { + ctx.status = 400; + ctx.fs.logger.error(error); + ctx.body = { err: 'download error.' }; + } + } + + + router.use(download_); + router.post('/_upload/new', upload); + router.delete('/_upload/cleanup', remove); + router.post('/_upload/attachments/ali/:p', uploadAliOSS); + router.get('/_download/attachments/ali', downloadFromAli); + router.post('/_upload/attachments/:p', upload_); + } +}; diff --git a/super-screen/routes/index.js b/super-screen/routes/index.js new file mode 100644 index 0000000..e81bfaa --- /dev/null +++ b/super-screen/routes/index.js @@ -0,0 +1,20 @@ +/** + * Created by liu.xinyi + * on 2016/7/7. + */ +'use strict'; +const path = require('path'); +const fs = require('fs'); + +module.exports = { + entry: function (app, router, opts) { + fs.readdirSync(__dirname).forEach(function (dir) { + if(fs.lstatSync(path.join(__dirname, dir)).isDirectory()){ + fs.readdirSync(path.join(__dirname, dir)).forEach(function (api) { + require(`./${dir}/${api}`).entry(app, router, opts); + app.fs.logger.log('info', '[Router]', 'Inject api:', dir + '/' + path.basename(api, '.js')); + }); + } + }); + } +}; \ No newline at end of file diff --git a/super-screen/server.js b/super-screen/server.js new file mode 100644 index 0000000..9e2474a --- /dev/null +++ b/super-screen/server.js @@ -0,0 +1,8 @@ +'use strict'; +/*jslint node:true*/ +//from koa + +const scaffold = require('fs-web-server-scaffold'); +const config = require('./config.js'); + +module.exports = scaffold(config); \ No newline at end of file diff --git a/super-screen/typings/node/node.d.ts b/super-screen/typings/node/node.d.ts new file mode 100644 index 0000000..bad534c --- /dev/null +++ b/super-screen/typings/node/node.d.ts @@ -0,0 +1,2599 @@ +// Type definitions for Node.js v6.x +// Project: http://nodejs.org/ +// Definitions by: Microsoft TypeScript , DefinitelyTyped +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +/************************************************ +* * +* Node.js v6.x API * +* * +************************************************/ + +interface Error { + stack?: string; +} + +interface ErrorConstructor { + captureStackTrace(targetObject: Object, constructorOpt?: Function): void; + stackTraceLimit: number; +} + +// compat for TypeScript 1.8 +// if you use with --target es3 or --target es5 and use below definitions, +// use the lib.es6.d.ts that is bundled with TypeScript 1.8. +interface MapConstructor { } +interface WeakMapConstructor { } +interface SetConstructor { } +interface WeakSetConstructor { } + +/************************************************ +* * +* GLOBAL * +* * +************************************************/ +declare var process: NodeJS.Process; +declare var global: NodeJS.Global; + +declare var __filename: string; +declare var __dirname: string; + +declare function setTimeout(callback: (...args: any[]) => void, ms: number, ...args: any[]): NodeJS.Timer; +declare function clearTimeout(timeoutId: NodeJS.Timer): void; +declare function setInterval(callback: (...args: any[]) => void, ms: number, ...args: any[]): NodeJS.Timer; +declare function clearInterval(intervalId: NodeJS.Timer): void; +declare function setImmediate(callback: (...args: any[]) => void, ...args: any[]): any; +declare function clearImmediate(immediateId: any): void; + +interface NodeRequireFunction { + (id: string): any; +} + +interface NodeRequire extends NodeRequireFunction { + resolve(id: string): string; + cache: any; + extensions: any; + main: any; +} + +declare var require: NodeRequire; + +interface NodeModule { + exports: any; + require: NodeRequireFunction; + id: string; + filename: string; + loaded: boolean; + parent: any; + children: any[]; +} + +declare var module: NodeModule; + +// Same as module.exports +declare var exports: any; +declare var SlowBuffer: { + new (str: string, encoding?: string): Buffer; + new (size: number): Buffer; + new (size: Uint8Array): Buffer; + new (array: any[]): Buffer; + prototype: Buffer; + isBuffer(obj: any): boolean; + byteLength(string: string, encoding?: string): number; + concat(list: Buffer[], totalLength?: number): Buffer; +}; + + +// Buffer class +type BufferEncoding = "ascii" | "utf8" | "utf16le" | "ucs2" | "binary" | "hex"; +interface Buffer extends NodeBuffer { } + +/** + * Raw data is stored in instances of the Buffer class. + * A Buffer is similar to an array of integers but corresponds to a raw memory allocation outside the V8 heap. A Buffer cannot be resized. + * Valid string encodings: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex' + */ +declare var Buffer: { + /** + * Allocates a new buffer containing the given {str}. + * + * @param str String to store in buffer. + * @param encoding encoding to use, optional. Default is 'utf8' + */ + new (str: string, encoding?: string): Buffer; + /** + * Allocates a new buffer of {size} octets. + * + * @param size count of octets to allocate. + */ + new (size: number): Buffer; + /** + * Allocates a new buffer containing the given {array} of octets. + * + * @param array The octets to store. + */ + new (array: Uint8Array): Buffer; + /** + * Produces a Buffer backed by the same allocated memory as + * the given {ArrayBuffer}. + * + * + * @param arrayBuffer The ArrayBuffer with which to share memory. + */ + new (arrayBuffer: ArrayBuffer): Buffer; + /** + * Allocates a new buffer containing the given {array} of octets. + * + * @param array The octets to store. + */ + new (array: any[]): Buffer; + /** + * Copies the passed {buffer} data onto a new {Buffer} instance. + * + * @param buffer The buffer to copy. + */ + new (buffer: Buffer): Buffer; + prototype: Buffer; + /** + * Allocates a new Buffer using an {array} of octets. + * + * @param array + */ + from(array: any[]): Buffer; + /** + * When passed a reference to the .buffer property of a TypedArray instance, + * the newly created Buffer will share the same allocated memory as the TypedArray. + * The optional {byteOffset} and {length} arguments specify a memory range + * within the {arrayBuffer} that will be shared by the Buffer. + * + * @param arrayBuffer The .buffer property of a TypedArray or a new ArrayBuffer() + * @param byteOffset + * @param length + */ + from(arrayBuffer: ArrayBuffer, byteOffset?: number, length?: number): Buffer; + /** + * Copies the passed {buffer} data onto a new Buffer instance. + * + * @param buffer + */ + from(buffer: Buffer): Buffer; + /** + * Creates a new Buffer containing the given JavaScript string {str}. + * If provided, the {encoding} parameter identifies the character encoding. + * If not provided, {encoding} defaults to 'utf8'. + * + * @param str + */ + from(str: string, encoding?: string): Buffer; + /** + * Returns true if {obj} is a Buffer + * + * @param obj object to test. + */ + isBuffer(obj: any): obj is Buffer; + /** + * Returns true if {encoding} is a valid encoding argument. + * Valid string encodings in Node 0.12: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex' + * + * @param encoding string to test. + */ + isEncoding(encoding: string): boolean; + /** + * Gives the actual byte length of a string. encoding defaults to 'utf8'. + * This is not the same as String.prototype.length since that returns the number of characters in a string. + * + * @param string string to test. + * @param encoding encoding used to evaluate (defaults to 'utf8') + */ + byteLength(string: string, encoding?: string): number; + /** + * Returns a buffer which is the result of concatenating all the buffers in the list together. + * + * If the list has no items, or if the totalLength is 0, then it returns a zero-length buffer. + * If the list has exactly one item, then the first item of the list is returned. + * If the list has more than one item, then a new Buffer is created. + * + * @param list An array of Buffer objects to concatenate + * @param totalLength Total length of the buffers when concatenated. + * If totalLength is not provided, it is read from the buffers in the list. However, this adds an additional loop to the function, so it is faster to provide the length explicitly. + */ + concat(list: Buffer[], totalLength?: number): Buffer; + /** + * The same as buf1.compare(buf2). + */ + compare(buf1: Buffer, buf2: Buffer): number; + /** + * Allocates a new buffer of {size} octets. + * + * @param size count of octets to allocate. + * @param fill if specified, buffer will be initialized by calling buf.fill(fill). + * If parameter is omitted, buffer will be filled with zeros. + * @param encoding encoding used for call to buf.fill while initalizing + */ + alloc(size: number, fill?: string | Buffer | number, encoding?: string): Buffer; + /** + * Allocates a new buffer of {size} octets, leaving memory not initialized, so the contents + * of the newly created Buffer are unknown and may contain sensitive data. + * + * @param size count of octets to allocate + */ + allocUnsafe(size: number): Buffer; + /** + * Allocates a new non-pooled buffer of {size} octets, leaving memory not initialized, so the contents + * of the newly created Buffer are unknown and may contain sensitive data. + * + * @param size count of octets to allocate + */ + allocUnsafeSlow(size: number): Buffer; +}; + +/************************************************ +* * +* GLOBAL INTERFACES * +* * +************************************************/ +declare namespace NodeJS { + export interface ErrnoException extends Error { + errno?: number; + code?: string; + path?: string; + syscall?: string; + stack?: string; + } + + export interface EventEmitter { + addListener(event: string, listener: Function): this; + on(event: string, listener: Function): this; + once(event: string, listener: Function): this; + removeListener(event: string, listener: Function): this; + removeAllListeners(event?: string): this; + setMaxListeners(n: number): this; + getMaxListeners(): number; + listeners(event: string): Function[]; + emit(event: string, ...args: any[]): boolean; + listenerCount(type: string): number; + } + + export interface ReadableStream extends EventEmitter { + readable: boolean; + read(size?: number): string | Buffer; + setEncoding(encoding: string): void; + pause(): void; + resume(): void; + pipe(destination: T, options?: { end?: boolean; }): T; + unpipe(destination?: T): void; + unshift(chunk: string): void; + unshift(chunk: Buffer): void; + wrap(oldStream: ReadableStream): ReadableStream; + } + + export interface WritableStream extends EventEmitter { + writable: boolean; + write(buffer: Buffer | string, cb?: Function): boolean; + write(str: string, encoding?: string, cb?: Function): boolean; + end(): void; + end(buffer: Buffer, cb?: Function): void; + end(str: string, cb?: Function): void; + end(str: string, encoding?: string, cb?: Function): void; + } + + export interface ReadWriteStream extends ReadableStream, WritableStream { } + + export interface Events extends EventEmitter { } + + export interface Domain extends Events { + run(fn: Function): void; + add(emitter: Events): void; + remove(emitter: Events): void; + bind(cb: (err: Error, data: any) => any): any; + intercept(cb: (data: any) => any): any; + dispose(): void; + + addListener(event: string, listener: Function): this; + on(event: string, listener: Function): this; + once(event: string, listener: Function): this; + removeListener(event: string, listener: Function): this; + removeAllListeners(event?: string): this; + } + + export interface MemoryUsage { + rss: number; + heapTotal: number; + heapUsed: number; + } + + export interface Process extends EventEmitter { + stdout: WritableStream; + stderr: WritableStream; + stdin: ReadableStream; + argv: string[]; + execArgv: string[]; + execPath: string; + abort(): void; + chdir(directory: string): void; + cwd(): string; + env: any; + exit(code?: number): void; + getgid(): number; + setgid(id: number): void; + setgid(id: string): void; + getuid(): number; + setuid(id: number): void; + setuid(id: string): void; + version: string; + versions: { + http_parser: string; + node: string; + v8: string; + ares: string; + uv: string; + zlib: string; + modules: string; + openssl: string; + }; + config: { + target_defaults: { + cflags: any[]; + default_configuration: string; + defines: string[]; + include_dirs: string[]; + libraries: string[]; + }; + variables: { + clang: number; + host_arch: string; + node_install_npm: boolean; + node_install_waf: boolean; + node_prefix: string; + node_shared_openssl: boolean; + node_shared_v8: boolean; + node_shared_zlib: boolean; + node_use_dtrace: boolean; + node_use_etw: boolean; + node_use_openssl: boolean; + target_arch: string; + v8_no_strict_aliasing: number; + v8_use_snapshot: boolean; + visibility: string; + }; + }; + kill(pid: number, signal?: string | number): void; + pid: number; + title: string; + arch: string; + platform: string; + memoryUsage(): MemoryUsage; + nextTick(callback: Function): void; + umask(mask?: number): number; + uptime(): number; + hrtime(time?: number[]): number[]; + domain: Domain; + + // Worker + send?(message: any, sendHandle?: any): void; + disconnect(): void; + connected: boolean; + } + + export interface Global { + Array: typeof Array; + ArrayBuffer: typeof ArrayBuffer; + Boolean: typeof Boolean; + Buffer: typeof Buffer; + DataView: typeof DataView; + Date: typeof Date; + Error: typeof Error; + EvalError: typeof EvalError; + Float32Array: typeof Float32Array; + Float64Array: typeof Float64Array; + Function: typeof Function; + GLOBAL: Global; + Infinity: typeof Infinity; + Int16Array: typeof Int16Array; + Int32Array: typeof Int32Array; + Int8Array: typeof Int8Array; + Intl: typeof Intl; + JSON: typeof JSON; + Map: MapConstructor; + Math: typeof Math; + NaN: typeof NaN; + Number: typeof Number; + Object: typeof Object; + Promise: Function; + RangeError: typeof RangeError; + ReferenceError: typeof ReferenceError; + RegExp: typeof RegExp; + Set: SetConstructor; + String: typeof String; + Symbol: Function; + SyntaxError: typeof SyntaxError; + TypeError: typeof TypeError; + URIError: typeof URIError; + Uint16Array: typeof Uint16Array; + Uint32Array: typeof Uint32Array; + Uint8Array: typeof Uint8Array; + Uint8ClampedArray: Function; + WeakMap: WeakMapConstructor; + WeakSet: WeakSetConstructor; + clearImmediate: (immediateId: any) => void; + clearInterval: (intervalId: NodeJS.Timer) => void; + clearTimeout: (timeoutId: NodeJS.Timer) => void; + console: typeof console; + decodeURI: typeof decodeURI; + decodeURIComponent: typeof decodeURIComponent; + encodeURI: typeof encodeURI; + encodeURIComponent: typeof encodeURIComponent; + escape: (str: string) => string; + eval: typeof eval; + global: Global; + isFinite: typeof isFinite; + isNaN: typeof isNaN; + parseFloat: typeof parseFloat; + parseInt: typeof parseInt; + process: Process; + root: Global; + setImmediate: (callback: (...args: any[]) => void, ...args: any[]) => any; + setInterval: (callback: (...args: any[]) => void, ms: number, ...args: any[]) => NodeJS.Timer; + setTimeout: (callback: (...args: any[]) => void, ms: number, ...args: any[]) => NodeJS.Timer; + undefined: typeof undefined; + unescape: (str: string) => string; + gc: () => void; + v8debug?: any; + } + + export interface Timer { + ref(): void; + unref(): void; + } +} + +/** + * @deprecated + */ +interface NodeBuffer extends Uint8Array { + write(string: string, offset?: number, length?: number, encoding?: string): number; + toString(encoding?: string, start?: number, end?: number): string; + toJSON(): any; + equals(otherBuffer: Buffer): boolean; + compare(otherBuffer: Buffer): number; + copy(targetBuffer: Buffer, targetStart?: number, sourceStart?: number, sourceEnd?: number): number; + slice(start?: number, end?: number): Buffer; + writeUIntLE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeUIntBE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeIntLE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeIntBE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + readUIntLE(offset: number, byteLength: number, noAssert?: boolean): number; + readUIntBE(offset: number, byteLength: number, noAssert?: boolean): number; + readIntLE(offset: number, byteLength: number, noAssert?: boolean): number; + readIntBE(offset: number, byteLength: number, noAssert?: boolean): number; + readUInt8(offset: number, noAssert?: boolean): number; + readUInt16LE(offset: number, noAssert?: boolean): number; + readUInt16BE(offset: number, noAssert?: boolean): number; + readUInt32LE(offset: number, noAssert?: boolean): number; + readUInt32BE(offset: number, noAssert?: boolean): number; + readInt8(offset: number, noAssert?: boolean): number; + readInt16LE(offset: number, noAssert?: boolean): number; + readInt16BE(offset: number, noAssert?: boolean): number; + readInt32LE(offset: number, noAssert?: boolean): number; + readInt32BE(offset: number, noAssert?: boolean): number; + readFloatLE(offset: number, noAssert?: boolean): number; + readFloatBE(offset: number, noAssert?: boolean): number; + readDoubleLE(offset: number, noAssert?: boolean): number; + readDoubleBE(offset: number, noAssert?: boolean): number; + writeUInt8(value: number, offset: number, noAssert?: boolean): number; + writeUInt16LE(value: number, offset: number, noAssert?: boolean): number; + writeUInt16BE(value: number, offset: number, noAssert?: boolean): number; + writeUInt32LE(value: number, offset: number, noAssert?: boolean): number; + writeUInt32BE(value: number, offset: number, noAssert?: boolean): number; + writeInt8(value: number, offset: number, noAssert?: boolean): number; + writeInt16LE(value: number, offset: number, noAssert?: boolean): number; + writeInt16BE(value: number, offset: number, noAssert?: boolean): number; + writeInt32LE(value: number, offset: number, noAssert?: boolean): number; + writeInt32BE(value: number, offset: number, noAssert?: boolean): number; + writeFloatLE(value: number, offset: number, noAssert?: boolean): number; + writeFloatBE(value: number, offset: number, noAssert?: boolean): number; + writeDoubleLE(value: number, offset: number, noAssert?: boolean): number; + writeDoubleBE(value: number, offset: number, noAssert?: boolean): number; + fill(value: any, offset?: number, end?: number): this; + // TODO: encoding param + indexOf(value: string | number | Buffer, byteOffset?: number): number; + // TODO: entries + // TODO: includes + // TODO: keys + // TODO: values +} + +/************************************************ +* * +* MODULES * +* * +************************************************/ +declare module "buffer" { + export var INSPECT_MAX_BYTES: number; + var BuffType: typeof Buffer; + var SlowBuffType: typeof SlowBuffer; + export { BuffType as Buffer, SlowBuffType as SlowBuffer }; +} + +declare module "querystring" { + export interface StringifyOptions { + encodeURIComponent?: Function; + } + + export interface ParseOptions { + maxKeys?: number; + decodeURIComponent?: Function; + } + + export function stringify(obj: T, sep?: string, eq?: string, options?: StringifyOptions): string; + export function parse(str: string, sep?: string, eq?: string, options?: ParseOptions): any; + export function parse(str: string, sep?: string, eq?: string, options?: ParseOptions): T; + export function escape(str: string): string; + export function unescape(str: string): string; +} + +declare module "events" { + export class EventEmitter implements NodeJS.EventEmitter { + static EventEmitter: EventEmitter; + static listenerCount(emitter: EventEmitter, event: string): number; // deprecated + static defaultMaxListeners: number; + + addListener(event: string, listener: Function): this; + on(event: string, listener: Function): this; + once(event: string, listener: Function): this; + prependListener(event: string, listener: Function): this; + prependOnceListener(event: string, listener: Function): this; + removeListener(event: string, listener: Function): this; + removeAllListeners(event?: string): this; + setMaxListeners(n: number): this; + getMaxListeners(): number; + listeners(event: string): Function[]; + emit(event: string, ...args: any[]): boolean; + eventNames(): string[]; + listenerCount(type: string): number; + } +} + +declare module "http" { + import * as events from "events"; + import * as net from "net"; + import * as stream from "stream"; + + export interface RequestOptions { + protocol?: string; + host?: string; + hostname?: string; + family?: number; + port?: number; + localAddress?: string; + socketPath?: string; + method?: string; + path?: string; + headers?: { [key: string]: any }; + auth?: string; + agent?: Agent | boolean; + } + + export interface Server extends events.EventEmitter, net.Server { + setTimeout(msecs: number, callback: Function): void; + maxHeadersCount: number; + timeout: number; + } + /** + * @deprecated Use IncomingMessage + */ + export interface ServerRequest extends IncomingMessage { + connection: net.Socket; + } + export interface ServerResponse extends events.EventEmitter, stream.Writable { + // Extended base methods + write(buffer: Buffer): boolean; + write(buffer: Buffer, cb?: Function): boolean; + write(str: string, cb?: Function): boolean; + write(str: string, encoding?: string, cb?: Function): boolean; + write(str: string, encoding?: string, fd?: string): boolean; + + writeContinue(): void; + writeHead(statusCode: number, reasonPhrase?: string, headers?: any): void; + writeHead(statusCode: number, headers?: any): void; + statusCode: number; + statusMessage: string; + headersSent: boolean; + setHeader(name: string, value: string | string[]): void; + setTimeout(msecs: number, callback: Function): ServerResponse; + sendDate: boolean; + getHeader(name: string): string; + removeHeader(name: string): void; + write(chunk: any, encoding?: string): any; + addTrailers(headers: any): void; + + // Extended base methods + end(): void; + end(buffer: Buffer, cb?: Function): void; + end(str: string, cb?: Function): void; + end(str: string, encoding?: string, cb?: Function): void; + end(data?: any, encoding?: string): void; + } + export interface ClientRequest extends events.EventEmitter, stream.Writable { + // Extended base methods + write(buffer: Buffer): boolean; + write(buffer: Buffer, cb?: Function): boolean; + write(str: string, cb?: Function): boolean; + write(str: string, encoding?: string, cb?: Function): boolean; + write(str: string, encoding?: string, fd?: string): boolean; + + write(chunk: any, encoding?: string): void; + abort(): void; + setTimeout(timeout: number, callback?: Function): void; + setNoDelay(noDelay?: boolean): void; + setSocketKeepAlive(enable?: boolean, initialDelay?: number): void; + + setHeader(name: string, value: string | string[]): void; + getHeader(name: string): string; + removeHeader(name: string): void; + addTrailers(headers: any): void; + + // Extended base methods + end(): void; + end(buffer: Buffer, cb?: Function): void; + end(str: string, cb?: Function): void; + end(str: string, encoding?: string, cb?: Function): void; + end(data?: any, encoding?: string): void; + } + export interface IncomingMessage extends events.EventEmitter, stream.Readable { + httpVersion: string; + headers: any; + rawHeaders: string[]; + trailers: any; + rawTrailers: any; + setTimeout(msecs: number, callback: Function): NodeJS.Timer; + /** + * Only valid for request obtained from http.Server. + */ + method?: string; + /** + * Only valid for request obtained from http.Server. + */ + url?: string; + /** + * Only valid for response obtained from http.ClientRequest. + */ + statusCode?: number; + /** + * Only valid for response obtained from http.ClientRequest. + */ + statusMessage?: string; + socket: net.Socket; + } + /** + * @deprecated Use IncomingMessage + */ + export interface ClientResponse extends IncomingMessage { } + + export interface AgentOptions { + /** + * Keep sockets around in a pool to be used by other requests in the future. Default = false + */ + keepAlive?: boolean; + /** + * When using HTTP KeepAlive, how often to send TCP KeepAlive packets over sockets being kept alive. Default = 1000. + * Only relevant if keepAlive is set to true. + */ + keepAliveMsecs?: number; + /** + * Maximum number of sockets to allow per host. Default for Node 0.10 is 5, default for Node 0.12 is Infinity + */ + maxSockets?: number; + /** + * Maximum number of sockets to leave open in a free state. Only relevant if keepAlive is set to true. Default = 256. + */ + maxFreeSockets?: number; + } + + export class Agent { + maxSockets: number; + sockets: any; + requests: any; + + constructor(opts?: AgentOptions); + + /** + * Destroy any sockets that are currently in use by the agent. + * It is usually not necessary to do this. However, if you are using an agent with KeepAlive enabled, + * then it is best to explicitly shut down the agent when you know that it will no longer be used. Otherwise, + * sockets may hang open for quite a long time before the server terminates them. + */ + destroy(): void; + } + + export var METHODS: string[]; + + export var STATUS_CODES: { + [errorCode: number]: string; + [errorCode: string]: string; + }; + export function createServer(requestListener?: (request: IncomingMessage, response: ServerResponse) => void): Server; + export function createClient(port?: number, host?: string): any; + export function request(options: RequestOptions, callback?: (res: IncomingMessage) => void): ClientRequest; + export function get(options: any, callback?: (res: IncomingMessage) => void): ClientRequest; + export var globalAgent: Agent; +} + +declare module "cluster" { + import * as child from "child_process"; + import * as events from "events"; + + export interface ClusterSettings { + exec?: string; + args?: string[]; + silent?: boolean; + } + + export interface Address { + address: string; + port: number; + addressType: string; + } + + export class Worker extends events.EventEmitter { + id: string; + process: child.ChildProcess; + suicide: boolean; + send(message: any, sendHandle?: any): void; + kill(signal?: string): void; + destroy(signal?: string): void; + disconnect(): void; + isConnected(): boolean; + isDead(): boolean; + } + + export var settings: ClusterSettings; + export var isMaster: boolean; + export var isWorker: boolean; + export function setupMaster(settings?: ClusterSettings): void; + export function fork(env?: any): Worker; + export function disconnect(callback?: Function): void; + export var worker: Worker; + export var workers: { + [index: string]: Worker + }; + + // Event emitter + export function addListener(event: string, listener: Function): void; + export function on(event: "disconnect", listener: (worker: Worker) => void): void; + export function on(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): void; + export function on(event: "fork", listener: (worker: Worker) => void): void; + export function on(event: "listening", listener: (worker: Worker, address: any) => void): void; + export function on(event: "message", listener: (worker: Worker, message: any) => void): void; + export function on(event: "online", listener: (worker: Worker) => void): void; + export function on(event: "setup", listener: (settings: any) => void): void; + export function on(event: string, listener: Function): any; + export function once(event: string, listener: Function): void; + export function removeListener(event: string, listener: Function): void; + export function removeAllListeners(event?: string): void; + export function setMaxListeners(n: number): void; + export function listeners(event: string): Function[]; + export function emit(event: string, ...args: any[]): boolean; +} + +declare module "zlib" { + import * as stream from "stream"; + export interface ZlibOptions { chunkSize?: number; windowBits?: number; level?: number; memLevel?: number; strategy?: number; dictionary?: any; } + + export interface Gzip extends stream.Transform { } + export interface Gunzip extends stream.Transform { } + export interface Deflate extends stream.Transform { } + export interface Inflate extends stream.Transform { } + export interface DeflateRaw extends stream.Transform { } + export interface InflateRaw extends stream.Transform { } + export interface Unzip extends stream.Transform { } + + export function createGzip(options?: ZlibOptions): Gzip; + export function createGunzip(options?: ZlibOptions): Gunzip; + export function createDeflate(options?: ZlibOptions): Deflate; + export function createInflate(options?: ZlibOptions): Inflate; + export function createDeflateRaw(options?: ZlibOptions): DeflateRaw; + export function createInflateRaw(options?: ZlibOptions): InflateRaw; + export function createUnzip(options?: ZlibOptions): Unzip; + + export function deflate(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function deflateSync(buf: Buffer, options?: ZlibOptions): any; + export function deflateRaw(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function deflateRawSync(buf: Buffer, options?: ZlibOptions): any; + export function gzip(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function gzipSync(buf: Buffer, options?: ZlibOptions): any; + export function gunzip(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function gunzipSync(buf: Buffer, options?: ZlibOptions): any; + export function inflate(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function inflateSync(buf: Buffer, options?: ZlibOptions): any; + export function inflateRaw(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function inflateRawSync(buf: Buffer, options?: ZlibOptions): any; + export function unzip(buf: Buffer, callback: (error: Error, result: any) => void): void; + export function unzipSync(buf: Buffer, options?: ZlibOptions): any; + + // Constants + export var Z_NO_FLUSH: number; + export var Z_PARTIAL_FLUSH: number; + export var Z_SYNC_FLUSH: number; + export var Z_FULL_FLUSH: number; + export var Z_FINISH: number; + export var Z_BLOCK: number; + export var Z_TREES: number; + export var Z_OK: number; + export var Z_STREAM_END: number; + export var Z_NEED_DICT: number; + export var Z_ERRNO: number; + export var Z_STREAM_ERROR: number; + export var Z_DATA_ERROR: number; + export var Z_MEM_ERROR: number; + export var Z_BUF_ERROR: number; + export var Z_VERSION_ERROR: number; + export var Z_NO_COMPRESSION: number; + export var Z_BEST_SPEED: number; + export var Z_BEST_COMPRESSION: number; + export var Z_DEFAULT_COMPRESSION: number; + export var Z_FILTERED: number; + export var Z_HUFFMAN_ONLY: number; + export var Z_RLE: number; + export var Z_FIXED: number; + export var Z_DEFAULT_STRATEGY: number; + export var Z_BINARY: number; + export var Z_TEXT: number; + export var Z_ASCII: number; + export var Z_UNKNOWN: number; + export var Z_DEFLATED: number; + export var Z_NULL: number; +} + +declare module "os" { + export interface CpuInfo { + model: string; + speed: number; + times: { + user: number; + nice: number; + sys: number; + idle: number; + irq: number; + }; + } + + export interface NetworkInterfaceInfo { + address: string; + netmask: string; + family: string; + mac: string; + internal: boolean; + } + + export function tmpdir(): string; + export function homedir(): string; + export function endianness(): "BE" | "LE"; + export function hostname(): string; + export function type(): string; + export function platform(): string; + export function arch(): string; + export function release(): string; + export function uptime(): number; + export function loadavg(): number[]; + export function totalmem(): number; + export function freemem(): number; + export function cpus(): CpuInfo[]; + export function networkInterfaces(): { [index: string]: NetworkInterfaceInfo[] }; + export var EOL: string; +} + +declare module "https" { + import * as tls from "tls"; + import * as events from "events"; + import * as http from "http"; + + export interface ServerOptions { + pfx?: any; + key?: any; + passphrase?: string; + cert?: any; + ca?: any; + crl?: any; + ciphers?: string; + honorCipherOrder?: boolean; + requestCert?: boolean; + rejectUnauthorized?: boolean; + NPNProtocols?: any; + SNICallback?: (servername: string) => any; + } + + export interface RequestOptions extends http.RequestOptions { + pfx?: any; + key?: any; + passphrase?: string; + cert?: any; + ca?: any; + ciphers?: string; + rejectUnauthorized?: boolean; + secureProtocol?: string; + } + + export interface Agent extends http.Agent { } + + export interface AgentOptions extends http.AgentOptions { + maxCachedSessions?: number; + } + + export var Agent: { + new (options?: AgentOptions): Agent; + }; + export interface Server extends tls.Server { } + export function createServer(options: ServerOptions, requestListener?: Function): Server; + export function request(options: RequestOptions, callback?: (res: http.IncomingMessage) => void): http.ClientRequest; + export function get(options: RequestOptions, callback?: (res: http.IncomingMessage) => void): http.ClientRequest; + export var globalAgent: Agent; +} + +declare module "punycode" { + export function decode(string: string): string; + export function encode(string: string): string; + export function toUnicode(domain: string): string; + export function toASCII(domain: string): string; + export var ucs2: ucs2; + interface ucs2 { + decode(string: string): number[]; + encode(codePoints: number[]): string; + } + export var version: any; +} + +declare module "repl" { + import * as stream from "stream"; + import * as events from "events"; + + export interface ReplOptions { + prompt?: string; + input?: NodeJS.ReadableStream; + output?: NodeJS.WritableStream; + terminal?: boolean; + eval?: Function; + useColors?: boolean; + useGlobal?: boolean; + ignoreUndefined?: boolean; + writer?: Function; + } + export function start(options: ReplOptions): events.EventEmitter; +} + +declare module "readline" { + import * as events from "events"; + import * as stream from "stream"; + + export interface Key { + sequence?: string; + name?: string; + ctrl?: boolean; + meta?: boolean; + shift?: boolean; + } + + export interface ReadLine extends events.EventEmitter { + setPrompt(prompt: string): void; + prompt(preserveCursor?: boolean): void; + question(query: string, callback: (answer: string) => void): void; + pause(): ReadLine; + resume(): ReadLine; + close(): void; + write(data: string | Buffer, key?: Key): void; + } + + export interface Completer { + (line: string): CompleterResult; + (line: string, callback: (err: any, result: CompleterResult) => void): any; + } + + export interface CompleterResult { + completions: string[]; + line: string; + } + + export interface ReadLineOptions { + input: NodeJS.ReadableStream; + output?: NodeJS.WritableStream; + completer?: Completer; + terminal?: boolean; + historySize?: number; + } + + export function createInterface(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer, terminal?: boolean): ReadLine; + export function createInterface(options: ReadLineOptions): ReadLine; + + export function cursorTo(stream: NodeJS.WritableStream, x: number, y: number): void; + export function moveCursor(stream: NodeJS.WritableStream, dx: number | string, dy: number | string): void; + export function clearLine(stream: NodeJS.WritableStream, dir: number): void; + export function clearScreenDown(stream: NodeJS.WritableStream): void; +} + +declare module "vm" { + export interface Context { } + export interface ScriptOptions { + filename?: string; + lineOffset?: number; + columnOffset?: number; + displayErrors?: boolean; + timeout?: number; + cachedData?: Buffer; + produceCachedData?: boolean; + } + export interface RunningScriptOptions { + filename?: string; + lineOffset?: number; + columnOffset?: number; + displayErrors?: boolean; + timeout?: number; + } + export class Script { + constructor(code: string, options?: ScriptOptions); + runInContext(contextifiedSandbox: Context, options?: RunningScriptOptions): any; + runInNewContext(sandbox?: Context, options?: RunningScriptOptions): any; + runInThisContext(options?: RunningScriptOptions): any; + } + export function createContext(sandbox?: Context): Context; + export function isContext(sandbox: Context): boolean; + export function runInContext(code: string, contextifiedSandbox: Context, options?: RunningScriptOptions): any; + export function runInDebugContext(code: string): any; + export function runInNewContext(code: string, sandbox?: Context, options?: RunningScriptOptions): any; + export function runInThisContext(code: string, options?: RunningScriptOptions): any; +} + +declare module "child_process" { + import * as events from "events"; + import * as stream from "stream"; + + export interface ChildProcess extends events.EventEmitter { + stdin: stream.Writable; + stdout: stream.Readable; + stderr: stream.Readable; + stdio: [stream.Writable, stream.Readable, stream.Readable]; + pid: number; + kill(signal?: string): void; + send(message: any, sendHandle?: any): void; + connected: boolean; + disconnect(): void; + unref(): void; + ref(): void; + } + + export interface SpawnOptions { + cwd?: string; + env?: any; + stdio?: any; + detached?: boolean; + uid?: number; + gid?: number; + shell?: boolean | string; + } + export function spawn(command: string, args?: string[], options?: SpawnOptions): ChildProcess; + + export interface ExecOptions { + cwd?: string; + env?: any; + shell?: string; + timeout?: number; + maxBuffer?: number; + killSignal?: string; + uid?: number; + gid?: number; + } + export interface ExecOptionsWithStringEncoding extends ExecOptions { + encoding: BufferEncoding; + } + export interface ExecOptionsWithBufferEncoding extends ExecOptions { + encoding: string; // specify `null`. + } + export function exec(command: string, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + export function exec(command: string, options: ExecOptionsWithStringEncoding, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + // usage. child_process.exec("tsc", {encoding: null as string}, (err, stdout, stderr) => {}); + export function exec(command: string, options: ExecOptionsWithBufferEncoding, callback?: (error: Error, stdout: Buffer, stderr: Buffer) => void): ChildProcess; + export function exec(command: string, options: ExecOptions, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + + export interface ExecFileOptions { + cwd?: string; + env?: any; + timeout?: number; + maxBuffer?: number; + killSignal?: string; + uid?: number; + gid?: number; + } + export interface ExecFileOptionsWithStringEncoding extends ExecFileOptions { + encoding: BufferEncoding; + } + export interface ExecFileOptionsWithBufferEncoding extends ExecFileOptions { + encoding: string; // specify `null`. + } + export function execFile(file: string, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + export function execFile(file: string, options?: ExecFileOptionsWithStringEncoding, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + // usage. child_process.execFile("file.sh", {encoding: null as string}, (err, stdout, stderr) => {}); + export function execFile(file: string, options?: ExecFileOptionsWithBufferEncoding, callback?: (error: Error, stdout: Buffer, stderr: Buffer) => void): ChildProcess; + export function execFile(file: string, options?: ExecFileOptions, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + export function execFile(file: string, args?: string[], callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + export function execFile(file: string, args?: string[], options?: ExecFileOptionsWithStringEncoding, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + // usage. child_process.execFile("file.sh", ["foo"], {encoding: null as string}, (err, stdout, stderr) => {}); + export function execFile(file: string, args?: string[], options?: ExecFileOptionsWithBufferEncoding, callback?: (error: Error, stdout: Buffer, stderr: Buffer) => void): ChildProcess; + export function execFile(file: string, args?: string[], options?: ExecFileOptions, callback?: (error: Error, stdout: string, stderr: string) => void): ChildProcess; + + export interface ForkOptions { + cwd?: string; + env?: any; + execPath?: string; + execArgv?: string[]; + silent?: boolean; + uid?: number; + gid?: number; + } + export function fork(modulePath: string, args?: string[], options?: ForkOptions): ChildProcess; + + export interface SpawnSyncOptions { + cwd?: string; + input?: string | Buffer; + stdio?: any; + env?: any; + uid?: number; + gid?: number; + timeout?: number; + killSignal?: string; + maxBuffer?: number; + encoding?: string; + shell?: boolean | string; + } + export interface SpawnSyncOptionsWithStringEncoding extends SpawnSyncOptions { + encoding: BufferEncoding; + } + export interface SpawnSyncOptionsWithBufferEncoding extends SpawnSyncOptions { + encoding: string; // specify `null`. + } + export interface SpawnSyncReturns { + pid: number; + output: string[]; + stdout: T; + stderr: T; + status: number; + signal: string; + error: Error; + } + export function spawnSync(command: string): SpawnSyncReturns; + export function spawnSync(command: string, options?: SpawnSyncOptionsWithStringEncoding): SpawnSyncReturns; + export function spawnSync(command: string, options?: SpawnSyncOptionsWithBufferEncoding): SpawnSyncReturns; + export function spawnSync(command: string, options?: SpawnSyncOptions): SpawnSyncReturns; + export function spawnSync(command: string, args?: string[], options?: SpawnSyncOptionsWithStringEncoding): SpawnSyncReturns; + export function spawnSync(command: string, args?: string[], options?: SpawnSyncOptionsWithBufferEncoding): SpawnSyncReturns; + export function spawnSync(command: string, args?: string[], options?: SpawnSyncOptions): SpawnSyncReturns; + + export interface ExecSyncOptions { + cwd?: string; + input?: string | Buffer; + stdio?: any; + env?: any; + shell?: string; + uid?: number; + gid?: number; + timeout?: number; + killSignal?: string; + maxBuffer?: number; + encoding?: string; + } + export interface ExecSyncOptionsWithStringEncoding extends ExecSyncOptions { + encoding: BufferEncoding; + } + export interface ExecSyncOptionsWithBufferEncoding extends ExecSyncOptions { + encoding: string; // specify `null`. + } + export function execSync(command: string): Buffer; + export function execSync(command: string, options?: ExecSyncOptionsWithStringEncoding): string; + export function execSync(command: string, options?: ExecSyncOptionsWithBufferEncoding): Buffer; + export function execSync(command: string, options?: ExecSyncOptions): Buffer; + + export interface ExecFileSyncOptions { + cwd?: string; + input?: string | Buffer; + stdio?: any; + env?: any; + uid?: number; + gid?: number; + timeout?: number; + killSignal?: string; + maxBuffer?: number; + encoding?: string; + } + export interface ExecFileSyncOptionsWithStringEncoding extends ExecFileSyncOptions { + encoding: BufferEncoding; + } + export interface ExecFileSyncOptionsWithBufferEncoding extends ExecFileSyncOptions { + encoding: string; // specify `null`. + } + export function execFileSync(command: string): Buffer; + export function execFileSync(command: string, options?: ExecFileSyncOptionsWithStringEncoding): string; + export function execFileSync(command: string, options?: ExecFileSyncOptionsWithBufferEncoding): Buffer; + export function execFileSync(command: string, options?: ExecFileSyncOptions): Buffer; + export function execFileSync(command: string, args?: string[], options?: ExecFileSyncOptionsWithStringEncoding): string; + export function execFileSync(command: string, args?: string[], options?: ExecFileSyncOptionsWithBufferEncoding): Buffer; + export function execFileSync(command: string, args?: string[], options?: ExecFileSyncOptions): Buffer; +} + +declare module "url" { + export interface Url { + href?: string; + protocol?: string; + auth?: string; + hostname?: string; + port?: string; + host?: string; + pathname?: string; + search?: string; + query?: string | any; + slashes?: boolean; + hash?: string; + path?: string; + } + + export function parse(urlStr: string, parseQueryString?: boolean, slashesDenoteHost?: boolean): Url; + export function format(url: Url): string; + export function resolve(from: string, to: string): string; +} + +declare module "dns" { + export function lookup(domain: string, family: number, callback: (err: Error, address: string, family: number) => void): string; + export function lookup(domain: string, callback: (err: Error, address: string, family: number) => void): string; + export function resolve(domain: string, rrtype: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolve(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolve4(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolve6(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolveMx(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolveTxt(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolveSrv(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolveNs(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function resolveCname(domain: string, callback: (err: Error, addresses: string[]) => void): string[]; + export function reverse(ip: string, callback: (err: Error, domains: string[]) => void): string[]; +} + +declare module "net" { + import * as stream from "stream"; + + export interface Socket extends stream.Duplex { + // Extended base methods + write(buffer: Buffer): boolean; + write(buffer: Buffer, cb?: Function): boolean; + write(str: string, cb?: Function): boolean; + write(str: string, encoding?: string, cb?: Function): boolean; + write(str: string, encoding?: string, fd?: string): boolean; + + connect(port: number, host?: string, connectionListener?: Function): void; + connect(path: string, connectionListener?: Function): void; + bufferSize: number; + setEncoding(encoding?: string): void; + write(data: any, encoding?: string, callback?: Function): void; + destroy(): void; + pause(): void; + resume(): void; + setTimeout(timeout: number, callback?: Function): void; + setNoDelay(noDelay?: boolean): void; + setKeepAlive(enable?: boolean, initialDelay?: number): void; + address(): { port: number; family: string; address: string; }; + unref(): void; + ref(): void; + + remoteAddress: string; + remoteFamily: string; + remotePort: number; + localAddress: string; + localPort: number; + bytesRead: number; + bytesWritten: number; + + // Extended base methods + end(): void; + end(buffer: Buffer, cb?: Function): void; + end(str: string, cb?: Function): void; + end(str: string, encoding?: string, cb?: Function): void; + end(data?: any, encoding?: string): void; + } + + export var Socket: { + new (options?: { fd?: string; type?: string; allowHalfOpen?: boolean; }): Socket; + }; + + export interface ListenOptions { + port?: number; + host?: string; + backlog?: number; + path?: string; + exclusive?: boolean; + } + + export interface Server extends Socket { + listen(port: number, hostname?: string, backlog?: number, listeningListener?: Function): Server; + listen(port: number, hostname?: string, listeningListener?: Function): Server; + listen(port: number, backlog?: number, listeningListener?: Function): Server; + listen(port: number, listeningListener?: Function): Server; + listen(path: string, backlog?: number, listeningListener?: Function): Server; + listen(path: string, listeningListener?: Function): Server; + listen(handle: any, backlog?: number, listeningListener?: Function): Server; + listen(handle: any, listeningListener?: Function): Server; + listen(options: ListenOptions, listeningListener?: Function): Server; + close(callback?: Function): Server; + address(): { port: number; family: string; address: string; }; + getConnections(cb: (error: Error, count: number) => void): void; + ref(): Server; + unref(): Server; + maxConnections: number; + connections: number; + } + export function createServer(connectionListener?: (socket: Socket) => void): Server; + export function createServer(options?: { allowHalfOpen?: boolean; }, connectionListener?: (socket: Socket) => void): Server; + export function connect(options: { port: number, host?: string, localAddress?: string, localPort?: string, family?: number, allowHalfOpen?: boolean; }, connectionListener?: Function): Socket; + export function connect(port: number, host?: string, connectionListener?: Function): Socket; + export function connect(path: string, connectionListener?: Function): Socket; + export function createConnection(options: { port: number, host?: string, localAddress?: string, localPort?: string, family?: number, allowHalfOpen?: boolean; }, connectionListener?: Function): Socket; + export function createConnection(port: number, host?: string, connectionListener?: Function): Socket; + export function createConnection(path: string, connectionListener?: Function): Socket; + export function isIP(input: string): number; + export function isIPv4(input: string): boolean; + export function isIPv6(input: string): boolean; +} + +declare module "dgram" { + import * as events from "events"; + + interface RemoteInfo { + address: string; + port: number; + size: number; + } + + interface AddressInfo { + address: string; + family: string; + port: number; + } + + export function createSocket(type: string, callback?: (msg: Buffer, rinfo: RemoteInfo) => void): Socket; + + interface Socket extends events.EventEmitter { + send(buf: Buffer, offset: number, length: number, port: number, address: string, callback?: (error: Error, bytes: number) => void): void; + bind(port: number, address?: string, callback?: () => void): void; + close(): void; + address(): AddressInfo; + setBroadcast(flag: boolean): void; + setMulticastTTL(ttl: number): void; + setMulticastLoopback(flag: boolean): void; + addMembership(multicastAddress: string, multicastInterface?: string): void; + dropMembership(multicastAddress: string, multicastInterface?: string): void; + } +} + +declare module "fs" { + import * as stream from "stream"; + import * as events from "events"; + + interface Stats { + isFile(): boolean; + isDirectory(): boolean; + isBlockDevice(): boolean; + isCharacterDevice(): boolean; + isSymbolicLink(): boolean; + isFIFO(): boolean; + isSocket(): boolean; + dev: number; + ino: number; + mode: number; + nlink: number; + uid: number; + gid: number; + rdev: number; + size: number; + blksize: number; + blocks: number; + atime: Date; + mtime: Date; + ctime: Date; + birthtime: Date; + } + + interface FSWatcher extends events.EventEmitter { + close(): void; + } + + export interface ReadStream extends stream.Readable { + close(): void; + destroy(): void; + } + export interface WriteStream extends stream.Writable { + close(): void; + bytesWritten: number; + } + + /** + * Asynchronous rename. + * @param oldPath + * @param newPath + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function rename(oldPath: string, newPath: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + /** + * Synchronous rename + * @param oldPath + * @param newPath + */ + export function renameSync(oldPath: string, newPath: string): void; + export function truncate(path: string | Buffer, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function truncate(path: string | Buffer, len: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function truncateSync(path: string | Buffer, len?: number): void; + export function ftruncate(fd: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function ftruncate(fd: number, len: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function ftruncateSync(fd: number, len?: number): void; + export function chown(path: string | Buffer, uid: number, gid: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function chownSync(path: string | Buffer, uid: number, gid: number): void; + export function fchown(fd: number, uid: number, gid: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function fchownSync(fd: number, uid: number, gid: number): void; + export function lchown(path: string | Buffer, uid: number, gid: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function lchownSync(path: string | Buffer, uid: number, gid: number): void; + export function chmod(path: string | Buffer, mode: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function chmod(path: string | Buffer, mode: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function chmodSync(path: string | Buffer, mode: number): void; + export function chmodSync(path: string | Buffer, mode: string): void; + export function fchmod(fd: number, mode: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function fchmod(fd: number, mode: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function fchmodSync(fd: number, mode: number): void; + export function fchmodSync(fd: number, mode: string): void; + export function lchmod(path: string | Buffer, mode: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function lchmod(path: string | Buffer, mode: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function lchmodSync(path: string | Buffer, mode: number): void; + export function lchmodSync(path: string | Buffer, mode: string): void; + export function stat(path: string | Buffer, callback?: (err: NodeJS.ErrnoException, stats: Stats) => any): void; + export function lstat(path: string | Buffer, callback?: (err: NodeJS.ErrnoException, stats: Stats) => any): void; + export function fstat(fd: number, callback?: (err: NodeJS.ErrnoException, stats: Stats) => any): void; + export function statSync(path: string | Buffer): Stats; + export function lstatSync(path: string | Buffer): Stats; + export function fstatSync(fd: number): Stats; + export function link(srcpath: string | Buffer, dstpath: string | Buffer, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function linkSync(srcpath: string | Buffer, dstpath: string | Buffer): void; + export function symlink(srcpath: string | Buffer, dstpath: string | Buffer, type?: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function symlinkSync(srcpath: string | Buffer, dstpath: string | Buffer, type?: string): void; + export function readlink(path: string | Buffer, callback?: (err: NodeJS.ErrnoException, linkString: string) => any): void; + export function readlinkSync(path: string | Buffer): string; + export function realpath(path: string | Buffer, callback?: (err: NodeJS.ErrnoException, resolvedPath: string) => any): void; + export function realpath(path: string | Buffer, cache: { [path: string]: string }, callback: (err: NodeJS.ErrnoException, resolvedPath: string) => any): void; + export function realpathSync(path: string | Buffer, cache?: { [path: string]: string }): string; + /* + * Asynchronous unlink - deletes the file specified in {path} + * + * @param path + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function unlink(path: string | Buffer, callback?: (err?: NodeJS.ErrnoException) => void): void; + /* + * Synchronous unlink - deletes the file specified in {path} + * + * @param path + */ + export function unlinkSync(path: string | Buffer): void; + /* + * Asynchronous rmdir - removes the directory specified in {path} + * + * @param path + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function rmdir(path: string | Buffer, callback?: (err?: NodeJS.ErrnoException) => void): void; + /* + * Synchronous rmdir - removes the directory specified in {path} + * + * @param path + */ + export function rmdirSync(path: string | Buffer): void; + /* + * Asynchronous mkdir - creates the directory specified in {path}. Parameter {mode} defaults to 0777. + * + * @param path + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function mkdir(path: string | Buffer, callback?: (err?: NodeJS.ErrnoException) => void): void; + /* + * Asynchronous mkdir - creates the directory specified in {path}. Parameter {mode} defaults to 0777. + * + * @param path + * @param mode + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function mkdir(path: string | Buffer, mode: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + /* + * Asynchronous mkdir - creates the directory specified in {path}. Parameter {mode} defaults to 0777. + * + * @param path + * @param mode + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function mkdir(path: string | Buffer, mode: string, callback?: (err?: NodeJS.ErrnoException) => void): void; + /* + * Synchronous mkdir - creates the directory specified in {path}. Parameter {mode} defaults to 0777. + * + * @param path + * @param mode + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function mkdirSync(path: string | Buffer, mode?: number): void; + /* + * Synchronous mkdir - creates the directory specified in {path}. Parameter {mode} defaults to 0777. + * + * @param path + * @param mode + * @param callback No arguments other than a possible exception are given to the completion callback. + */ + export function mkdirSync(path: string | Buffer, mode?: string): void; + /* + * Asynchronous mkdtemp - Creates a unique temporary directory. Generates six random characters to be appended behind a required prefix to create a unique temporary directory. + * + * @param prefix + * @param callback The created folder path is passed as a string to the callback's second parameter. + */ + export function mkdtemp(prefix: string, callback?: (err: NodeJS.ErrnoException, folder: string) => void): void; + /* + * Synchronous mkdtemp - Creates a unique temporary directory. Generates six random characters to be appended behind a required prefix to create a unique temporary directory. + * + * @param prefix + * @returns Returns the created folder path. + */ + export function mkdtempSync(prefix: string): string; + export function readdir(path: string | Buffer, callback?: (err: NodeJS.ErrnoException, files: string[]) => void): void; + export function readdirSync(path: string | Buffer): string[]; + export function close(fd: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function closeSync(fd: number): void; + export function open(path: string | Buffer, flags: string | number, callback: (err: NodeJS.ErrnoException, fd: number) => void): void; + export function open(path: string | Buffer, flags: string | number, mode: number, callback: (err: NodeJS.ErrnoException, fd: number) => void): void; + export function openSync(path: string | Buffer, flags: string | number, mode?: number): number; + export function utimes(path: string | Buffer, atime: number, mtime: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function utimes(path: string | Buffer, atime: Date, mtime: Date, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function utimesSync(path: string | Buffer, atime: number, mtime: number): void; + export function utimesSync(path: string | Buffer, atime: Date, mtime: Date): void; + export function futimes(fd: number, atime: number, mtime: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function futimes(fd: number, atime: Date, mtime: Date, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function futimesSync(fd: number, atime: number, mtime: number): void; + export function futimesSync(fd: number, atime: Date, mtime: Date): void; + export function fsync(fd: number, callback?: (err?: NodeJS.ErrnoException) => void): void; + export function fsyncSync(fd: number): void; + export function write(fd: number, buffer: Buffer, offset: number, length: number, position: number, callback?: (err: NodeJS.ErrnoException, written: number, buffer: Buffer) => void): void; + export function write(fd: number, buffer: Buffer, offset: number, length: number, callback?: (err: NodeJS.ErrnoException, written: number, buffer: Buffer) => void): void; + export function write(fd: number, data: any, callback?: (err: NodeJS.ErrnoException, written: number, str: string) => void): void; + export function write(fd: number, data: any, offset: number, callback?: (err: NodeJS.ErrnoException, written: number, str: string) => void): void; + export function write(fd: number, data: any, offset: number, encoding: string, callback?: (err: NodeJS.ErrnoException, written: number, str: string) => void): void; + export function writeSync(fd: number, buffer: Buffer, offset: number, length: number, position?: number): number; + export function writeSync(fd: number, data: any, position?: number, enconding?: string): number; + export function read(fd: number, buffer: Buffer, offset: number, length: number, position: number, callback?: (err: NodeJS.ErrnoException, bytesRead: number, buffer: Buffer) => void): void; + export function readSync(fd: number, buffer: Buffer, offset: number, length: number, position: number): number; + /* + * Asynchronous readFile - Asynchronously reads the entire contents of a file. + * + * @param fileName + * @param encoding + * @param callback - The callback is passed two arguments (err, data), where data is the contents of the file. + */ + export function readFile(filename: string, encoding: string, callback: (err: NodeJS.ErrnoException, data: string) => void): void; + /* + * Asynchronous readFile - Asynchronously reads the entire contents of a file. + * + * @param fileName + * @param options An object with optional {encoding} and {flag} properties. If {encoding} is specified, readFile returns a string; otherwise it returns a Buffer. + * @param callback - The callback is passed two arguments (err, data), where data is the contents of the file. + */ + export function readFile(filename: string, options: { encoding: string; flag?: string; }, callback: (err: NodeJS.ErrnoException, data: string) => void): void; + /* + * Asynchronous readFile - Asynchronously reads the entire contents of a file. + * + * @param fileName + * @param options An object with optional {encoding} and {flag} properties. If {encoding} is specified, readFile returns a string; otherwise it returns a Buffer. + * @param callback - The callback is passed two arguments (err, data), where data is the contents of the file. + */ + export function readFile(filename: string, options: { flag?: string; }, callback: (err: NodeJS.ErrnoException, data: Buffer) => void): void; + /* + * Asynchronous readFile - Asynchronously reads the entire contents of a file. + * + * @param fileName + * @param callback - The callback is passed two arguments (err, data), where data is the contents of the file. + */ + export function readFile(filename: string, callback: (err: NodeJS.ErrnoException, data: Buffer) => void): void; + /* + * Synchronous readFile - Synchronously reads the entire contents of a file. + * + * @param fileName + * @param encoding + */ + export function readFileSync(filename: string, encoding: string): string; + /* + * Synchronous readFile - Synchronously reads the entire contents of a file. + * + * @param fileName + * @param options An object with optional {encoding} and {flag} properties. If {encoding} is specified, readFileSync returns a string; otherwise it returns a Buffer. + */ + export function readFileSync(filename: string, options: { encoding: string; flag?: string; }): string; + /* + * Synchronous readFile - Synchronously reads the entire contents of a file. + * + * @param fileName + * @param options An object with optional {encoding} and {flag} properties. If {encoding} is specified, readFileSync returns a string; otherwise it returns a Buffer. + */ + export function readFileSync(filename: string, options?: { flag?: string; }): Buffer; + export function writeFile(filename: string, data: any, callback?: (err: NodeJS.ErrnoException) => void): void; + export function writeFile(filename: string, data: any, options: { encoding?: string; mode?: number; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; + export function writeFile(filename: string, data: any, options: { encoding?: string; mode?: string; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; + export function writeFileSync(filename: string, data: any, options?: { encoding?: string; mode?: number; flag?: string; }): void; + export function writeFileSync(filename: string, data: any, options?: { encoding?: string; mode?: string; flag?: string; }): void; + export function appendFile(filename: string, data: any, options: { encoding?: string; mode?: number; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; + export function appendFile(filename: string, data: any, options: { encoding?: string; mode?: string; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; + export function appendFile(filename: string, data: any, callback?: (err: NodeJS.ErrnoException) => void): void; + export function appendFileSync(filename: string, data: any, options?: { encoding?: string; mode?: number; flag?: string; }): void; + export function appendFileSync(filename: string, data: any, options?: { encoding?: string; mode?: string; flag?: string; }): void; + export function watchFile(filename: string, listener: (curr: Stats, prev: Stats) => void): void; + export function watchFile(filename: string, options: { persistent?: boolean; interval?: number; }, listener: (curr: Stats, prev: Stats) => void): void; + export function unwatchFile(filename: string, listener?: (curr: Stats, prev: Stats) => void): void; + export function watch(filename: string, listener?: (event: string, filename: string) => any): FSWatcher; + export function watch(filename: string, encoding: string, listener?: (event: string, filename: string | Buffer) => any): FSWatcher; + export function watch(filename: string, options: { persistent?: boolean; recursive?: boolean; encoding?: string }, listener?: (event: string, filename: string | Buffer) => any): FSWatcher; + export function exists(path: string | Buffer, callback?: (exists: boolean) => void): void; + export function existsSync(path: string | Buffer): boolean; + /** Constant for fs.access(). File is visible to the calling process. */ + export var F_OK: number; + /** Constant for fs.access(). File can be read by the calling process. */ + export var R_OK: number; + /** Constant for fs.access(). File can be written by the calling process. */ + export var W_OK: number; + /** Constant for fs.access(). File can be executed by the calling process. */ + export var X_OK: number; + /** Tests a user's permissions for the file specified by path. */ + export function access(path: string | Buffer, callback: (err: NodeJS.ErrnoException) => void): void; + export function access(path: string | Buffer, mode: number, callback: (err: NodeJS.ErrnoException) => void): void; + /** Synchronous version of fs.access. This throws if any accessibility checks fail, and does nothing otherwise. */ + export function accessSync(path: string | Buffer, mode?: number): void; + export function createReadStream(path: string | Buffer, options?: { + flags?: string; + encoding?: string; + fd?: number; + mode?: number; + autoClose?: boolean; + start?: number; + end?: number; + }): ReadStream; + export function createWriteStream(path: string | Buffer, options?: { + flags?: string; + encoding?: string; + fd?: number; + mode?: number; + }): WriteStream; +} + +declare module "path" { + + /** + * A parsed path object generated by path.parse() or consumed by path.format(). + */ + export interface ParsedPath { + /** + * The root of the path such as '/' or 'c:\' + */ + root: string; + /** + * The full directory path such as '/home/user/dir' or 'c:\path\dir' + */ + dir: string; + /** + * The file name including extension (if any) such as 'index.html' + */ + base: string; + /** + * The file extension (if any) such as '.html' + */ + ext: string; + /** + * The file name without extension (if any) such as 'index' + */ + name: string; + } + + /** + * Normalize a string path, reducing '..' and '.' parts. + * When multiple slashes are found, they're replaced by a single one; when the path contains a trailing slash, it is preserved. On Windows backslashes are used. + * + * @param p string path to normalize. + */ + export function normalize(p: string): string; + /** + * Join all arguments together and normalize the resulting path. + * Arguments must be strings. In v0.8, non-string arguments were silently ignored. In v0.10 and up, an exception is thrown. + * + * @param paths string paths to join. + */ + export function join(...paths: any[]): string; + /** + * Join all arguments together and normalize the resulting path. + * Arguments must be strings. In v0.8, non-string arguments were silently ignored. In v0.10 and up, an exception is thrown. + * + * @param paths string paths to join. + */ + export function join(...paths: string[]): string; + /** + * The right-most parameter is considered {to}. Other parameters are considered an array of {from}. + * + * Starting from leftmost {from} paramter, resolves {to} to an absolute path. + * + * If {to} isn't already absolute, {from} arguments are prepended in right to left order, until an absolute path is found. If after using all {from} paths still no absolute path is found, the current working directory is used as well. The resulting path is normalized, and trailing slashes are removed unless the path gets resolved to the root directory. + * + * @param pathSegments string paths to join. Non-string arguments are ignored. + */ + export function resolve(...pathSegments: any[]): string; + /** + * Determines whether {path} is an absolute path. An absolute path will always resolve to the same location, regardless of the working directory. + * + * @param path path to test. + */ + export function isAbsolute(path: string): boolean; + /** + * Solve the relative path from {from} to {to}. + * At times we have two absolute paths, and we need to derive the relative path from one to the other. This is actually the reverse transform of path.resolve. + * + * @param from + * @param to + */ + export function relative(from: string, to: string): string; + /** + * Return the directory name of a path. Similar to the Unix dirname command. + * + * @param p the path to evaluate. + */ + export function dirname(p: string): string; + /** + * Return the last portion of a path. Similar to the Unix basename command. + * Often used to extract the file name from a fully qualified path. + * + * @param p the path to evaluate. + * @param ext optionally, an extension to remove from the result. + */ + export function basename(p: string, ext?: string): string; + /** + * Return the extension of the path, from the last '.' to end of string in the last portion of the path. + * If there is no '.' in the last portion of the path or the first character of it is '.', then it returns an empty string + * + * @param p the path to evaluate. + */ + export function extname(p: string): string; + /** + * The platform-specific file separator. '\\' or '/'. + */ + export var sep: string; + /** + * The platform-specific file delimiter. ';' or ':'. + */ + export var delimiter: string; + /** + * Returns an object from a path string - the opposite of format(). + * + * @param pathString path to evaluate. + */ + export function parse(pathString: string): ParsedPath; + /** + * Returns a path string from an object - the opposite of parse(). + * + * @param pathString path to evaluate. + */ + export function format(pathObject: ParsedPath): string; + + export module posix { + export function normalize(p: string): string; + export function join(...paths: any[]): string; + export function resolve(...pathSegments: any[]): string; + export function isAbsolute(p: string): boolean; + export function relative(from: string, to: string): string; + export function dirname(p: string): string; + export function basename(p: string, ext?: string): string; + export function extname(p: string): string; + export var sep: string; + export var delimiter: string; + export function parse(p: string): ParsedPath; + export function format(pP: ParsedPath): string; + } + + export module win32 { + export function normalize(p: string): string; + export function join(...paths: any[]): string; + export function resolve(...pathSegments: any[]): string; + export function isAbsolute(p: string): boolean; + export function relative(from: string, to: string): string; + export function dirname(p: string): string; + export function basename(p: string, ext?: string): string; + export function extname(p: string): string; + export var sep: string; + export var delimiter: string; + export function parse(p: string): ParsedPath; + export function format(pP: ParsedPath): string; + } +} + +declare module "string_decoder" { + export interface NodeStringDecoder { + write(buffer: Buffer): string; + end(buffer?: Buffer): string; + } + export var StringDecoder: { + new (encoding?: string): NodeStringDecoder; + }; +} + +declare module "tls" { + import * as crypto from "crypto"; + import * as net from "net"; + import * as stream from "stream"; + + var CLIENT_RENEG_LIMIT: number; + var CLIENT_RENEG_WINDOW: number; + + export interface Certificate { + /** + * Country code. + */ + C: string; + /** + * Street. + */ + ST: string; + /** + * Locality. + */ + L: string; + /** + * Organization. + */ + O: string; + /** + * Organizational unit. + */ + OU: string; + /** + * Common name. + */ + CN: string; + } + + export interface CipherNameAndProtocol { + /** + * The cipher name. + */ + name: string; + /** + * SSL/TLS protocol version. + */ + version: string; + } + + export class TLSSocket extends stream.Duplex { + /** + * Returns the bound address, the address family name and port of the underlying socket as reported by + * the operating system. + * @returns {any} - An object with three properties, e.g. { port: 12346, family: 'IPv4', address: '127.0.0.1' }. + */ + address(): { port: number; family: string; address: string }; + /** + * A boolean that is true if the peer certificate was signed by one of the specified CAs, otherwise false. + */ + authorized: boolean; + /** + * The reason why the peer's certificate has not been verified. + * This property becomes available only when tlsSocket.authorized === false. + */ + authorizationError: Error; + /** + * Static boolean value, always true. + * May be used to distinguish TLS sockets from regular ones. + */ + encrypted: boolean; + /** + * Returns an object representing the cipher name and the SSL/TLS protocol version of the current connection. + * @returns {CipherNameAndProtocol} - Returns an object representing the cipher name + * and the SSL/TLS protocol version of the current connection. + */ + getCipher(): CipherNameAndProtocol; + /** + * Returns an object representing the peer's certificate. + * The returned object has some properties corresponding to the field of the certificate. + * If detailed argument is true the full chain with issuer property will be returned, + * if false only the top certificate without issuer property. + * If the peer does not provide a certificate, it returns null or an empty object. + * @param {boolean} detailed - If true; the full chain with issuer property will be returned. + * @returns {any} - An object representing the peer's certificate. + */ + getPeerCertificate(detailed?: boolean): { + subject: Certificate; + issuerInfo: Certificate; + issuer: Certificate; + raw: any; + valid_from: string; + valid_to: string; + fingerprint: string; + serialNumber: string; + }; + /** + * Could be used to speed up handshake establishment when reconnecting to the server. + * @returns {any} - ASN.1 encoded TLS session or undefined if none was negotiated. + */ + getSession(): any; + /** + * NOTE: Works only with client TLS sockets. + * Useful only for debugging, for session reuse provide session option to tls.connect(). + * @returns {any} - TLS session ticket or undefined if none was negotiated. + */ + getTLSTicket(): any; + /** + * The string representation of the local IP address. + */ + localAddress: string; + /** + * The numeric representation of the local port. + */ + localPort: string; + /** + * The string representation of the remote IP address. + * For example, '74.125.127.100' or '2001:4860:a005::68'. + */ + remoteAddress: string; + /** + * The string representation of the remote IP family. 'IPv4' or 'IPv6'. + */ + remoteFamily: string; + /** + * The numeric representation of the remote port. For example, 443. + */ + remotePort: number; + /** + * Initiate TLS renegotiation process. + * + * NOTE: Can be used to request peer's certificate after the secure connection has been established. + * ANOTHER NOTE: When running as the server, socket will be destroyed with an error after handshakeTimeout timeout. + * @param {TlsOptions} options - The options may contain the following fields: rejectUnauthorized, + * requestCert (See tls.createServer() for details). + * @param {Function} callback - callback(err) will be executed with null as err, once the renegotiation + * is successfully completed. + */ + renegotiate(options: TlsOptions, callback: (err: Error) => any): any; + /** + * Set maximum TLS fragment size (default and maximum value is: 16384, minimum is: 512). + * Smaller fragment size decreases buffering latency on the client: large fragments are buffered by + * the TLS layer until the entire fragment is received and its integrity is verified; + * large fragments can span multiple roundtrips, and their processing can be delayed due to packet + * loss or reordering. However, smaller fragments add extra TLS framing bytes and CPU overhead, + * which may decrease overall server throughput. + * @param {number} size - TLS fragment size (default and maximum value is: 16384, minimum is: 512). + * @returns {boolean} - Returns true on success, false otherwise. + */ + setMaxSendFragment(size: number): boolean; + } + + export interface TlsOptions { + host?: string; + port?: number; + pfx?: any; //string or buffer + key?: any; //string or buffer + passphrase?: string; + cert?: any; + ca?: any; //string or buffer + crl?: any; //string or string array + ciphers?: string; + honorCipherOrder?: any; + requestCert?: boolean; + rejectUnauthorized?: boolean; + NPNProtocols?: any; //array or Buffer; + SNICallback?: (servername: string) => any; + } + + export interface ConnectionOptions { + host?: string; + port?: number; + socket?: net.Socket; + pfx?: string | Buffer + key?: string | Buffer + passphrase?: string; + cert?: string | Buffer + ca?: (string | Buffer)[]; + rejectUnauthorized?: boolean; + NPNProtocols?: (string | Buffer)[]; + servername?: string; + } + + export interface Server extends net.Server { + close(): Server; + address(): { port: number; family: string; address: string; }; + addContext(hostName: string, credentials: { + key: string; + cert: string; + ca: string; + }): void; + maxConnections: number; + connections: number; + } + + export interface ClearTextStream extends stream.Duplex { + authorized: boolean; + authorizationError: Error; + getPeerCertificate(): any; + getCipher: { + name: string; + version: string; + }; + address: { + port: number; + family: string; + address: string; + }; + remoteAddress: string; + remotePort: number; + } + + export interface SecurePair { + encrypted: any; + cleartext: any; + } + + export interface SecureContextOptions { + pfx?: string | Buffer; + key?: string | Buffer; + passphrase?: string; + cert?: string | Buffer; + ca?: string | Buffer; + crl?: string | string[] + ciphers?: string; + honorCipherOrder?: boolean; + } + + export interface SecureContext { + context: any; + } + + export function createServer(options: TlsOptions, secureConnectionListener?: (cleartextStream: ClearTextStream) => void): Server; + export function connect(options: TlsOptions, secureConnectionListener?: () => void): ClearTextStream; + export function connect(port: number, host?: string, options?: ConnectionOptions, secureConnectListener?: () => void): ClearTextStream; + export function connect(port: number, options?: ConnectionOptions, secureConnectListener?: () => void): ClearTextStream; + export function createSecurePair(credentials?: crypto.Credentials, isServer?: boolean, requestCert?: boolean, rejectUnauthorized?: boolean): SecurePair; + export function createSecureContext(details: SecureContextOptions): SecureContext; +} + +declare module "crypto" { + export interface CredentialDetails { + pfx: string; + key: string; + passphrase: string; + cert: string; + ca: string | string[]; + crl: string | string[]; + ciphers: string; + } + export interface Credentials { context?: any; } + export function createCredentials(details: CredentialDetails): Credentials; + export function createHash(algorithm: string): Hash; + export function createHmac(algorithm: string, key: string): Hmac; + export function createHmac(algorithm: string, key: Buffer): Hmac; + export interface Hash { + update(data: any, input_encoding?: string): Hash; + digest(encoding: 'buffer'): Buffer; + digest(encoding: string): any; + digest(): Buffer; + } + export interface Hmac extends NodeJS.ReadWriteStream { + update(data: any, input_encoding?: string): Hmac; + digest(encoding: 'buffer'): Buffer; + digest(encoding: string): any; + digest(): Buffer; + } + export function createCipher(algorithm: string, password: any): Cipher; + export function createCipheriv(algorithm: string, key: any, iv: any): Cipher; + export interface Cipher extends NodeJS.ReadWriteStream { + update(data: Buffer): Buffer; + update(data: string, input_encoding: "utf8" | "ascii" | "binary"): Buffer; + update(data: Buffer, input_encoding: any, output_encoding: "binary" | "base64" | "hex"): string; + update(data: string, input_encoding: "utf8" | "ascii" | "binary", output_encoding: "binary" | "base64" | "hex"): string; + final(): Buffer; + final(output_encoding: string): string; + setAutoPadding(auto_padding: boolean): void; + getAuthTag(): Buffer; + } + export function createDecipher(algorithm: string, password: any): Decipher; + export function createDecipheriv(algorithm: string, key: any, iv: any): Decipher; + export interface Decipher extends NodeJS.ReadWriteStream { + update(data: Buffer): Buffer; + update(data: string, input_encoding: "binary" | "base64" | "hex"): Buffer; + update(data: Buffer, input_encoding: any, output_encoding: "utf8" | "ascii" | "binary"): string; + update(data: string, input_encoding: "binary" | "base64" | "hex", output_encoding: "utf8" | "ascii" | "binary"): string; + final(): Buffer; + final(output_encoding: string): string; + setAutoPadding(auto_padding: boolean): void; + setAuthTag(tag: Buffer): void; + } + export function createSign(algorithm: string): Signer; + export interface Signer extends NodeJS.WritableStream { + update(data: any): void; + sign(private_key: string, output_format: string): string; + } + export function createVerify(algorith: string): Verify; + export interface Verify extends NodeJS.WritableStream { + update(data: any): void; + verify(object: string, signature: string, signature_format?: string): boolean; + } + export function createDiffieHellman(prime_length: number): DiffieHellman; + export function createDiffieHellman(prime: number, encoding?: string): DiffieHellman; + export interface DiffieHellman { + generateKeys(encoding?: string): string; + computeSecret(other_public_key: string, input_encoding?: string, output_encoding?: string): string; + getPrime(encoding?: string): string; + getGenerator(encoding: string): string; + getPublicKey(encoding?: string): string; + getPrivateKey(encoding?: string): string; + setPublicKey(public_key: string, encoding?: string): void; + setPrivateKey(public_key: string, encoding?: string): void; + } + export function getDiffieHellman(group_name: string): DiffieHellman; + export function pbkdf2(password: string | Buffer, salt: string | Buffer, iterations: number, keylen: number, callback: (err: Error, derivedKey: Buffer) => any): void; + export function pbkdf2(password: string | Buffer, salt: string | Buffer, iterations: number, keylen: number, digest: string, callback: (err: Error, derivedKey: Buffer) => any): void; + export function pbkdf2Sync(password: string | Buffer, salt: string | Buffer, iterations: number, keylen: number): Buffer; + export function pbkdf2Sync(password: string | Buffer, salt: string | Buffer, iterations: number, keylen: number, digest: string): Buffer; + export function randomBytes(size: number): Buffer; + export function randomBytes(size: number, callback: (err: Error, buf: Buffer) => void): void; + export function pseudoRandomBytes(size: number): Buffer; + export function pseudoRandomBytes(size: number, callback: (err: Error, buf: Buffer) => void): void; + export interface RsaPublicKey { + key: string; + padding?: any; + } + export interface RsaPrivateKey { + key: string; + passphrase?: string, + padding?: any; + } + export function publicEncrypt(public_key: string | RsaPublicKey, buffer: Buffer): Buffer + export function privateDecrypt(private_key: string | RsaPrivateKey, buffer: Buffer): Buffer +} + +declare module "stream" { + import * as events from "events"; + + export class Stream extends events.EventEmitter { + pipe(destination: T, options?: { end?: boolean; }): T; + } + + export interface ReadableOptions { + highWaterMark?: number; + encoding?: string; + objectMode?: boolean; + read?: (size?: number) => any; + } + + export class Readable extends events.EventEmitter implements NodeJS.ReadableStream { + readable: boolean; + constructor(opts?: ReadableOptions); + _read(size: number): void; + read(size?: number): any; + setEncoding(encoding: string): void; + pause(): void; + resume(): void; + pipe(destination: T, options?: { end?: boolean; }): T; + unpipe(destination?: T): void; + unshift(chunk: any): void; + wrap(oldStream: NodeJS.ReadableStream): NodeJS.ReadableStream; + push(chunk: any, encoding?: string): boolean; + } + + export interface WritableOptions { + highWaterMark?: number; + decodeStrings?: boolean; + objectMode?: boolean; + write?: (chunk: string|Buffer, encoding: string, callback: Function) => any; + writev?: (chunks: {chunk: string|Buffer, encoding: string}[], callback: Function) => any; + } + + export class Writable extends events.EventEmitter implements NodeJS.WritableStream { + writable: boolean; + constructor(opts?: WritableOptions); + _write(chunk: any, encoding: string, callback: Function): void; + write(chunk: any, cb?: Function): boolean; + write(chunk: any, encoding?: string, cb?: Function): boolean; + end(): void; + end(chunk: any, cb?: Function): void; + end(chunk: any, encoding?: string, cb?: Function): void; + } + + export interface DuplexOptions extends ReadableOptions, WritableOptions { + allowHalfOpen?: boolean; + readableObjectMode?: boolean; + writableObjectMode?: boolean; + } + + // Note: Duplex extends both Readable and Writable. + export class Duplex extends Readable implements NodeJS.ReadWriteStream { + writable: boolean; + constructor(opts?: DuplexOptions); + _write(chunk: any, encoding: string, callback: Function): void; + write(chunk: any, cb?: Function): boolean; + write(chunk: any, encoding?: string, cb?: Function): boolean; + end(): void; + end(chunk: any, cb?: Function): void; + end(chunk: any, encoding?: string, cb?: Function): void; + } + + export interface TransformOptions extends ReadableOptions, WritableOptions { + transform?: (chunk: string|Buffer, encoding: string, callback: Function) => any; + flush?: (callback: Function) => any; + } + + // Note: Transform lacks the _read and _write methods of Readable/Writable. + export class Transform extends events.EventEmitter implements NodeJS.ReadWriteStream { + readable: boolean; + writable: boolean; + constructor(opts?: TransformOptions); + _transform(chunk: any, encoding: string, callback: Function): void; + _flush(callback: Function): void; + read(size?: number): any; + setEncoding(encoding: string): void; + pause(): void; + resume(): void; + pipe(destination: T, options?: { end?: boolean; }): T; + unpipe(destination?: T): void; + unshift(chunk: any): void; + wrap(oldStream: NodeJS.ReadableStream): NodeJS.ReadableStream; + push(chunk: any, encoding?: string): boolean; + write(chunk: any, cb?: Function): boolean; + write(chunk: any, encoding?: string, cb?: Function): boolean; + end(): void; + end(chunk: any, cb?: Function): void; + end(chunk: any, encoding?: string, cb?: Function): void; + } + + export class PassThrough extends Transform { } +} + +declare module "util" { + export interface InspectOptions { + showHidden?: boolean; + depth?: number; + colors?: boolean; + customInspect?: boolean; + } + + export function format(format: any, ...param: any[]): string; + export function debug(string: string): void; + export function error(...param: any[]): void; + export function puts(...param: any[]): void; + export function print(...param: any[]): void; + export function log(string: string): void; + export function inspect(object: any, showHidden?: boolean, depth?: number, color?: boolean): string; + export function inspect(object: any, options: InspectOptions): string; + export function isArray(object: any): boolean; + export function isRegExp(object: any): boolean; + export function isDate(object: any): boolean; + export function isError(object: any): boolean; + export function inherits(constructor: any, superConstructor: any): void; + export function debuglog(key: string): (msg: string, ...param: any[]) => void; +} + +declare module "assert" { + function internal(value: any, message?: string): void; + namespace internal { + export class AssertionError implements Error { + name: string; + message: string; + actual: any; + expected: any; + operator: string; + generatedMessage: boolean; + + constructor(options?: { + message?: string; actual?: any; expected?: any; + operator?: string; stackStartFunction?: Function + }); + } + + export function fail(actual?: any, expected?: any, message?: string, operator?: string): void; + export function ok(value: any, message?: string): void; + export function equal(actual: any, expected: any, message?: string): void; + export function notEqual(actual: any, expected: any, message?: string): void; + export function deepEqual(actual: any, expected: any, message?: string): void; + export function notDeepEqual(acutal: any, expected: any, message?: string): void; + export function strictEqual(actual: any, expected: any, message?: string): void; + export function notStrictEqual(actual: any, expected: any, message?: string): void; + export function deepStrictEqual(actual: any, expected: any, message?: string): void; + export function notDeepStrictEqual(actual: any, expected: any, message?: string): void; + export var throws: { + (block: Function, message?: string): void; + (block: Function, error: Function, message?: string): void; + (block: Function, error: RegExp, message?: string): void; + (block: Function, error: (err: any) => boolean, message?: string): void; + }; + + export var doesNotThrow: { + (block: Function, message?: string): void; + (block: Function, error: Function, message?: string): void; + (block: Function, error: RegExp, message?: string): void; + (block: Function, error: (err: any) => boolean, message?: string): void; + }; + + export function ifError(value: any): void; + } + + export = internal; +} + +declare module "tty" { + import * as net from "net"; + + export function isatty(fd: number): boolean; + export interface ReadStream extends net.Socket { + isRaw: boolean; + setRawMode(mode: boolean): void; + isTTY: boolean; + } + export interface WriteStream extends net.Socket { + columns: number; + rows: number; + isTTY: boolean; + } +} + +declare module "domain" { + import * as events from "events"; + + export class Domain extends events.EventEmitter implements NodeJS.Domain { + run(fn: Function): void; + add(emitter: events.EventEmitter): void; + remove(emitter: events.EventEmitter): void; + bind(cb: (err: Error, data: any) => any): any; + intercept(cb: (data: any) => any): any; + dispose(): void; + } + + export function create(): Domain; +} + +declare module "constants" { + export var E2BIG: number; + export var EACCES: number; + export var EADDRINUSE: number; + export var EADDRNOTAVAIL: number; + export var EAFNOSUPPORT: number; + export var EAGAIN: number; + export var EALREADY: number; + export var EBADF: number; + export var EBADMSG: number; + export var EBUSY: number; + export var ECANCELED: number; + export var ECHILD: number; + export var ECONNABORTED: number; + export var ECONNREFUSED: number; + export var ECONNRESET: number; + export var EDEADLK: number; + export var EDESTADDRREQ: number; + export var EDOM: number; + export var EEXIST: number; + export var EFAULT: number; + export var EFBIG: number; + export var EHOSTUNREACH: number; + export var EIDRM: number; + export var EILSEQ: number; + export var EINPROGRESS: number; + export var EINTR: number; + export var EINVAL: number; + export var EIO: number; + export var EISCONN: number; + export var EISDIR: number; + export var ELOOP: number; + export var EMFILE: number; + export var EMLINK: number; + export var EMSGSIZE: number; + export var ENAMETOOLONG: number; + export var ENETDOWN: number; + export var ENETRESET: number; + export var ENETUNREACH: number; + export var ENFILE: number; + export var ENOBUFS: number; + export var ENODATA: number; + export var ENODEV: number; + export var ENOENT: number; + export var ENOEXEC: number; + export var ENOLCK: number; + export var ENOLINK: number; + export var ENOMEM: number; + export var ENOMSG: number; + export var ENOPROTOOPT: number; + export var ENOSPC: number; + export var ENOSR: number; + export var ENOSTR: number; + export var ENOSYS: number; + export var ENOTCONN: number; + export var ENOTDIR: number; + export var ENOTEMPTY: number; + export var ENOTSOCK: number; + export var ENOTSUP: number; + export var ENOTTY: number; + export var ENXIO: number; + export var EOPNOTSUPP: number; + export var EOVERFLOW: number; + export var EPERM: number; + export var EPIPE: number; + export var EPROTO: number; + export var EPROTONOSUPPORT: number; + export var EPROTOTYPE: number; + export var ERANGE: number; + export var EROFS: number; + export var ESPIPE: number; + export var ESRCH: number; + export var ETIME: number; + export var ETIMEDOUT: number; + export var ETXTBSY: number; + export var EWOULDBLOCK: number; + export var EXDEV: number; + export var WSAEINTR: number; + export var WSAEBADF: number; + export var WSAEACCES: number; + export var WSAEFAULT: number; + export var WSAEINVAL: number; + export var WSAEMFILE: number; + export var WSAEWOULDBLOCK: number; + export var WSAEINPROGRESS: number; + export var WSAEALREADY: number; + export var WSAENOTSOCK: number; + export var WSAEDESTADDRREQ: number; + export var WSAEMSGSIZE: number; + export var WSAEPROTOTYPE: number; + export var WSAENOPROTOOPT: number; + export var WSAEPROTONOSUPPORT: number; + export var WSAESOCKTNOSUPPORT: number; + export var WSAEOPNOTSUPP: number; + export var WSAEPFNOSUPPORT: number; + export var WSAEAFNOSUPPORT: number; + export var WSAEADDRINUSE: number; + export var WSAEADDRNOTAVAIL: number; + export var WSAENETDOWN: number; + export var WSAENETUNREACH: number; + export var WSAENETRESET: number; + export var WSAECONNABORTED: number; + export var WSAECONNRESET: number; + export var WSAENOBUFS: number; + export var WSAEISCONN: number; + export var WSAENOTCONN: number; + export var WSAESHUTDOWN: number; + export var WSAETOOMANYREFS: number; + export var WSAETIMEDOUT: number; + export var WSAECONNREFUSED: number; + export var WSAELOOP: number; + export var WSAENAMETOOLONG: number; + export var WSAEHOSTDOWN: number; + export var WSAEHOSTUNREACH: number; + export var WSAENOTEMPTY: number; + export var WSAEPROCLIM: number; + export var WSAEUSERS: number; + export var WSAEDQUOT: number; + export var WSAESTALE: number; + export var WSAEREMOTE: number; + export var WSASYSNOTREADY: number; + export var WSAVERNOTSUPPORTED: number; + export var WSANOTINITIALISED: number; + export var WSAEDISCON: number; + export var WSAENOMORE: number; + export var WSAECANCELLED: number; + export var WSAEINVALIDPROCTABLE: number; + export var WSAEINVALIDPROVIDER: number; + export var WSAEPROVIDERFAILEDINIT: number; + export var WSASYSCALLFAILURE: number; + export var WSASERVICE_NOT_FOUND: number; + export var WSATYPE_NOT_FOUND: number; + export var WSA_E_NO_MORE: number; + export var WSA_E_CANCELLED: number; + export var WSAEREFUSED: number; + export var SIGHUP: number; + export var SIGINT: number; + export var SIGILL: number; + export var SIGABRT: number; + export var SIGFPE: number; + export var SIGKILL: number; + export var SIGSEGV: number; + export var SIGTERM: number; + export var SIGBREAK: number; + export var SIGWINCH: number; + export var SSL_OP_ALL: number; + export var SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION: number; + export var SSL_OP_CIPHER_SERVER_PREFERENCE: number; + export var SSL_OP_CISCO_ANYCONNECT: number; + export var SSL_OP_COOKIE_EXCHANGE: number; + export var SSL_OP_CRYPTOPRO_TLSEXT_BUG: number; + export var SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS: number; + export var SSL_OP_EPHEMERAL_RSA: number; + export var SSL_OP_LEGACY_SERVER_CONNECT: number; + export var SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER: number; + export var SSL_OP_MICROSOFT_SESS_ID_BUG: number; + export var SSL_OP_MSIE_SSLV2_RSA_PADDING: number; + export var SSL_OP_NETSCAPE_CA_DN_BUG: number; + export var SSL_OP_NETSCAPE_CHALLENGE_BUG: number; + export var SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG: number; + export var SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG: number; + export var SSL_OP_NO_COMPRESSION: number; + export var SSL_OP_NO_QUERY_MTU: number; + export var SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION: number; + export var SSL_OP_NO_SSLv2: number; + export var SSL_OP_NO_SSLv3: number; + export var SSL_OP_NO_TICKET: number; + export var SSL_OP_NO_TLSv1: number; + export var SSL_OP_NO_TLSv1_1: number; + export var SSL_OP_NO_TLSv1_2: number; + export var SSL_OP_PKCS1_CHECK_1: number; + export var SSL_OP_PKCS1_CHECK_2: number; + export var SSL_OP_SINGLE_DH_USE: number; + export var SSL_OP_SINGLE_ECDH_USE: number; + export var SSL_OP_SSLEAY_080_CLIENT_DH_BUG: number; + export var SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG: number; + export var SSL_OP_TLS_BLOCK_PADDING_BUG: number; + export var SSL_OP_TLS_D5_BUG: number; + export var SSL_OP_TLS_ROLLBACK_BUG: number; + export var ENGINE_METHOD_DSA: number; + export var ENGINE_METHOD_DH: number; + export var ENGINE_METHOD_RAND: number; + export var ENGINE_METHOD_ECDH: number; + export var ENGINE_METHOD_ECDSA: number; + export var ENGINE_METHOD_CIPHERS: number; + export var ENGINE_METHOD_DIGESTS: number; + export var ENGINE_METHOD_STORE: number; + export var ENGINE_METHOD_PKEY_METHS: number; + export var ENGINE_METHOD_PKEY_ASN1_METHS: number; + export var ENGINE_METHOD_ALL: number; + export var ENGINE_METHOD_NONE: number; + export var DH_CHECK_P_NOT_SAFE_PRIME: number; + export var DH_CHECK_P_NOT_PRIME: number; + export var DH_UNABLE_TO_CHECK_GENERATOR: number; + export var DH_NOT_SUITABLE_GENERATOR: number; + export var NPN_ENABLED: number; + export var RSA_PKCS1_PADDING: number; + export var RSA_SSLV23_PADDING: number; + export var RSA_NO_PADDING: number; + export var RSA_PKCS1_OAEP_PADDING: number; + export var RSA_X931_PADDING: number; + export var RSA_PKCS1_PSS_PADDING: number; + export var POINT_CONVERSION_COMPRESSED: number; + export var POINT_CONVERSION_UNCOMPRESSED: number; + export var POINT_CONVERSION_HYBRID: number; + export var O_RDONLY: number; + export var O_WRONLY: number; + export var O_RDWR: number; + export var S_IFMT: number; + export var S_IFREG: number; + export var S_IFDIR: number; + export var S_IFCHR: number; + export var S_IFBLK: number; + export var S_IFIFO: number; + export var S_IFSOCK: number; + export var S_IRWXU: number; + export var S_IRUSR: number; + export var S_IWUSR: number; + export var S_IXUSR: number; + export var S_IRWXG: number; + export var S_IRGRP: number; + export var S_IWGRP: number; + export var S_IXGRP: number; + export var S_IRWXO: number; + export var S_IROTH: number; + export var S_IWOTH: number; + export var S_IXOTH: number; + export var S_IFLNK: number; + export var O_CREAT: number; + export var O_EXCL: number; + export var O_NOCTTY: number; + export var O_DIRECTORY: number; + export var O_NOATIME: number; + export var O_NOFOLLOW: number; + export var O_SYNC: number; + export var O_SYMLINK: number; + export var O_DIRECT: number; + export var O_NONBLOCK: number; + export var O_TRUNC: number; + export var O_APPEND: number; + export var F_OK: number; + export var R_OK: number; + export var W_OK: number; + export var X_OK: number; + export var UV_UDP_REUSEADDR: number; +} diff --git a/super-screen/typings/react/react.d.ts b/super-screen/typings/react/react.d.ts new file mode 100644 index 0000000..57ef054 --- /dev/null +++ b/super-screen/typings/react/react.d.ts @@ -0,0 +1,2517 @@ +// Type definitions for React v0.14 +// Project: http://facebook.github.io/react/ +// Definitions by: Asana , AssureSign , Microsoft +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +declare namespace __React { + + // + // React Elements + // ---------------------------------------------------------------------- + + type ReactType = string | ComponentClass | StatelessComponent; + + type Key = string | number; + type Ref = string | ((instance: T) => any); + type ComponentState = {} | void; + + interface Attributes { + key?: Key; + } + interface ClassAttributes extends Attributes { + ref?: Ref; + } + + interface ReactElement

{ + type: string | ComponentClass

| SFC

; + props: P; + key?: Key; + } + + interface SFCElement

extends ReactElement

{ + type: SFC

; + } + + type CElement> = ComponentElement; + interface ComponentElement> extends ReactElement

{ + type: ComponentClass

; + ref?: Ref; + } + + type ClassicElement

= CElement>; + + interface DOMElement

extends ReactElement

{ + type: string; + ref: Ref; + } + + interface ReactHTMLElement extends DOMElement { + } + + interface ReactSVGElement extends DOMElement { + } + + // + // Factories + // ---------------------------------------------------------------------- + + interface Factory

{ + (props?: P & Attributes, ...children: ReactNode[]): ReactElement

; + } + + interface SFCFactory

{ + (props?: P & Attributes, ...children: ReactNode[]): SFCElement

; + } + + interface ComponentFactory> { + (props?: P & ClassAttributes, ...children: ReactNode[]): CElement; + } + + type CFactory> = ComponentFactory; + type ClassicFactory

= CFactory>; + + interface DOMFactory

{ + (props?: P & ClassAttributes, ...children: ReactNode[]): DOMElement; + } + + interface HTMLFactory extends DOMFactory { + } + + interface SVGFactory extends DOMFactory { + } + + // + // React Nodes + // http://facebook.github.io/react/docs/glossary.html + // ---------------------------------------------------------------------- + + type ReactText = string | number; + type ReactChild = ReactElement | ReactText; + + // Should be Array but type aliases cannot be recursive + type ReactFragment = {} | Array; + type ReactNode = ReactChild | ReactFragment | boolean; + + // + // Top Level API + // ---------------------------------------------------------------------- + + function createClass(spec: ComponentSpec): ClassicComponentClass

; + + function createFactory

( + type: string): DOMFactory; + function createFactory

(type: SFC

): SFCFactory

; + function createFactory

( + type: ClassType, ClassicComponentClass

>): CFactory>; + function createFactory, C extends ComponentClass

>( + type: ClassType): CFactory; + function createFactory

(type: ComponentClass

| SFC

): Factory

; + + function createElement

( + type: string, + props?: P & ClassAttributes, + ...children: ReactNode[]): DOMElement; + function createElement

( + type: SFC

, + props?: P & Attributes, + ...children: ReactNode[]): SFCElement

; + function createElement

( + type: ClassType, ClassicComponentClass

>, + props?: P & ClassAttributes>, + ...children: ReactNode[]): CElement>; + function createElement, C extends ComponentClass

>( + type: ClassType, + props?: P & ClassAttributes, + ...children: ReactNode[]): CElement; + function createElement

( + type: ComponentClass

| SFC

, + props?: P & Attributes, + ...children: ReactNode[]): ReactElement

; + + function cloneElement

( + element: DOMElement, + props?: P & ClassAttributes, + ...children: ReactNode[]): DOMElement; + function cloneElement

( + element: SFCElement

, + props?: Q, // should be Q & Attributes, but then Q is inferred as {} + ...children: ReactNode[]): SFCElement

; + function cloneElement

>( + element: CElement, + props?: Q, // should be Q & ClassAttributes + ...children: ReactNode[]): CElement; + function cloneElement

( + element: ReactElement

, + props?: Q, // should be Q & Attributes + ...children: ReactNode[]): ReactElement

; + + function isValidElement

(object: {}): object is ReactElement

; + + var DOM: ReactDOM; + var PropTypes: ReactPropTypes; + var Children: ReactChildren; + var version: string; + + // + // Component API + // ---------------------------------------------------------------------- + + type ReactInstance = Component | Element; + + // Base component for plain JS classes + class Component implements ComponentLifecycle { + constructor(props?: P, context?: any); + setState(f: (prevState: S, props: P) => S, callback?: () => any): void; + setState(state: S, callback?: () => any): void; + forceUpdate(callback?: () => any): void; + render(): JSX.Element; + + // React.Props is now deprecated, which means that the `children` + // property is not available on `P` by default, even though you can + // always pass children as variadic arguments to `createElement`. + // In the future, if we can define its call signature conditionally + // on the existence of `children` in `P`, then we should remove this. + props: P & { children?: ReactNode }; + state: S; + context: {}; + refs: { + [key: string]: ReactInstance + }; + } + + interface ClassicComponent extends Component { + replaceState(nextState: S, callback?: () => any): void; + isMounted(): boolean; + getInitialState?(): S; + } + + interface ChildContextProvider { + getChildContext(): CC; + } + + // + // Class Interfaces + // ---------------------------------------------------------------------- + + type SFC

= StatelessComponent

; + interface StatelessComponent

{ + (props?: P, context?: any): ReactElement; + propTypes?: ValidationMap

; + contextTypes?: ValidationMap; + defaultProps?: P; + displayName?: string; + } + + interface ComponentClass

{ + new(props?: P, context?: any): Component; + propTypes?: ValidationMap

; + contextTypes?: ValidationMap; + childContextTypes?: ValidationMap; + defaultProps?: P; + displayName?: string; + } + + interface ClassicComponentClass

extends ComponentClass

{ + new(props?: P, context?: any): ClassicComponent; + getDefaultProps?(): P; + } + + /** + * We use an intersection type to infer multiple type parameters from + * a single argument, which is useful for many top-level API defs. + * See https://github.com/Microsoft/TypeScript/issues/7234 for more info. + */ + type ClassType, C extends ComponentClass

> = + C & + (new() => T) & + (new() => { props: P }); + + // + // Component Specs and Lifecycle + // ---------------------------------------------------------------------- + + interface ComponentLifecycle { + componentWillMount?(): void; + componentDidMount?(): void; + componentWillReceiveProps?(nextProps: P, nextContext: any): void; + shouldComponentUpdate?(nextProps: P, nextState: S, nextContext: any): boolean; + componentWillUpdate?(nextProps: P, nextState: S, nextContext: any): void; + componentDidUpdate?(prevProps: P, prevState: S, prevContext: any): void; + componentWillUnmount?(): void; + } + + interface Mixin extends ComponentLifecycle { + mixins?: Mixin; + statics?: { + [key: string]: any; + }; + + displayName?: string; + propTypes?: ValidationMap; + contextTypes?: ValidationMap; + childContextTypes?: ValidationMap; + + getDefaultProps?(): P; + getInitialState?(): S; + } + + interface ComponentSpec extends Mixin { + render(): ReactElement; + + [propertyName: string]: any; + } + + // + // Event System + // ---------------------------------------------------------------------- + + interface SyntheticEvent { + bubbles: boolean; + cancelable: boolean; + currentTarget: EventTarget; + defaultPrevented: boolean; + eventPhase: number; + isTrusted: boolean; + nativeEvent: Event; + preventDefault(): void; + stopPropagation(): void; + target: EventTarget; + timeStamp: Date; + type: string; + } + + interface ClipboardEvent extends SyntheticEvent { + clipboardData: DataTransfer; + } + + interface CompositionEvent extends SyntheticEvent { + data: string; + } + + interface DragEvent extends MouseEvent { + dataTransfer: DataTransfer; + } + + interface FocusEvent extends SyntheticEvent { + relatedTarget: EventTarget; + } + + interface FormEvent extends SyntheticEvent { + } + + interface KeyboardEvent extends SyntheticEvent { + altKey: boolean; + charCode: number; + ctrlKey: boolean; + getModifierState(key: string): boolean; + key: string; + keyCode: number; + locale: string; + location: number; + metaKey: boolean; + repeat: boolean; + shiftKey: boolean; + which: number; + } + + interface MouseEvent extends SyntheticEvent { + altKey: boolean; + button: number; + buttons: number; + clientX: number; + clientY: number; + ctrlKey: boolean; + getModifierState(key: string): boolean; + metaKey: boolean; + pageX: number; + pageY: number; + relatedTarget: EventTarget; + screenX: number; + screenY: number; + shiftKey: boolean; + } + + interface TouchEvent extends SyntheticEvent { + altKey: boolean; + changedTouches: TouchList; + ctrlKey: boolean; + getModifierState(key: string): boolean; + metaKey: boolean; + shiftKey: boolean; + targetTouches: TouchList; + touches: TouchList; + } + + interface UIEvent extends SyntheticEvent { + detail: number; + view: AbstractView; + } + + interface WheelEvent extends MouseEvent { + deltaMode: number; + deltaX: number; + deltaY: number; + deltaZ: number; + } + + interface AnimationEvent extends SyntheticEvent { + animationName: string; + pseudoElement: string; + elapsedTime: number; + } + + interface TransitionEvent extends SyntheticEvent { + propertyName: string; + pseudoElement: string; + elapsedTime: number; + } + + // + // Event Handler Types + // ---------------------------------------------------------------------- + + interface EventHandler { + (event: E): void; + } + + type ReactEventHandler = EventHandler; + + type ClipboardEventHandler = EventHandler; + type CompositionEventHandler = EventHandler; + type DragEventHandler = EventHandler; + type FocusEventHandler = EventHandler; + type FormEventHandler = EventHandler; + type KeyboardEventHandler = EventHandler; + type MouseEventHandler = EventHandler; + type TouchEventHandler = EventHandler; + type UIEventHandler = EventHandler; + type WheelEventHandler = EventHandler; + type AnimationEventHandler = EventHandler; + type TransitionEventHandler = EventHandler; + + // + // Props / DOM Attributes + // ---------------------------------------------------------------------- + + /** + * @deprecated. This was used to allow clients to pass `ref` and `key` + * to `createElement`, which is no longer necessary due to intersection + * types. If you need to declare a props object before passing it to + * `createElement` or a factory, use `ClassAttributes`: + * + * ```ts + * var b: Button; + * var props: ButtonProps & ClassAttributes