diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/src/permission.js b/src/permission.js index e41df7c..669bb65 100644 --- a/src/permission.js +++ b/src/permission.js @@ -59,9 +59,21 @@ console.log('is In WhiteList') next() } else { - console.log('noTokentoToLogin') - // next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 - next('/login') // 否则全部重定向到登录页 + // 获取链接里的token + const token = to.query.token + console.log('token' + to.query.token) + if (token) { + // 调用自动登录接口,否则跳转到登录页 + store.dispatch('AppLogin', token).then(() => { + console.log('自动登录成功') + console.log(to.path) + next({ ...to, replace: true }) // 登录成功继续 + }).catch(() => { + next('/401') // 否则全部重定向到401没有权限页面 + }) + } else { + next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 + } NProgress.done() } } diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/src/permission.js b/src/permission.js index e41df7c..669bb65 100644 --- a/src/permission.js +++ b/src/permission.js @@ -59,9 +59,21 @@ console.log('is In WhiteList') next() } else { - console.log('noTokentoToLogin') - // next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 - next('/login') // 否则全部重定向到登录页 + // 获取链接里的token + const token = to.query.token + console.log('token' + to.query.token) + if (token) { + // 调用自动登录接口,否则跳转到登录页 + store.dispatch('AppLogin', token).then(() => { + console.log('自动登录成功') + console.log(to.path) + next({ ...to, replace: true }) // 登录成功继续 + }).catch(() => { + next('/401') // 否则全部重定向到401没有权限页面 + }) + } else { + next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 + } NProgress.done() } } diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 28149ed..c0583db 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -69,7 +69,19 @@ }) }) }, - + // 自动登录接口 + AppLogin({ commit }, token) { + return new Promise((resolve, reject) => { + // 如果token存在直接setToken + if (token) { + setToken(token) + commit('SET_TOKEN', token) + resolve() + } else { + reject() + } + }) + }, // 获取用户信息 GetInfo({ commit, state }) { return new Promise((resolve, reject) => { diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/src/permission.js b/src/permission.js index e41df7c..669bb65 100644 --- a/src/permission.js +++ b/src/permission.js @@ -59,9 +59,21 @@ console.log('is In WhiteList') next() } else { - console.log('noTokentoToLogin') - // next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 - next('/login') // 否则全部重定向到登录页 + // 获取链接里的token + const token = to.query.token + console.log('token' + to.query.token) + if (token) { + // 调用自动登录接口,否则跳转到登录页 + store.dispatch('AppLogin', token).then(() => { + console.log('自动登录成功') + console.log(to.path) + next({ ...to, replace: true }) // 登录成功继续 + }).catch(() => { + next('/401') // 否则全部重定向到401没有权限页面 + }) + } else { + next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 + } NProgress.done() } } diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 28149ed..c0583db 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -69,7 +69,19 @@ }) }) }, - + // 自动登录接口 + AppLogin({ commit }, token) { + return new Promise((resolve, reject) => { + // 如果token存在直接setToken + if (token) { + setToken(token) + commit('SET_TOKEN', token) + resolve() + } else { + reject() + } + }) + }, // 获取用户信息 GetInfo({ commit, state }) { return new Promise((resolve, reject) => { diff --git a/src/styles/element-ui.scss b/src/styles/element-ui.scss index d15535e..c7968c9 100644 --- a/src/styles/element-ui.scss +++ b/src/styles/element-ui.scss @@ -64,3 +64,14 @@ max-width: 200px !important; } +.title-img{ + .el-image{ + //height:100%; + .el-image__inner{ + //height:100%; + object-position: left !important; + width:auto; + } + } +} + diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/src/permission.js b/src/permission.js index e41df7c..669bb65 100644 --- a/src/permission.js +++ b/src/permission.js @@ -59,9 +59,21 @@ console.log('is In WhiteList') next() } else { - console.log('noTokentoToLogin') - // next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 - next('/login') // 否则全部重定向到登录页 + // 获取链接里的token + const token = to.query.token + console.log('token' + to.query.token) + if (token) { + // 调用自动登录接口,否则跳转到登录页 + store.dispatch('AppLogin', token).then(() => { + console.log('自动登录成功') + console.log(to.path) + next({ ...to, replace: true }) // 登录成功继续 + }).catch(() => { + next('/401') // 否则全部重定向到401没有权限页面 + }) + } else { + next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 + } NProgress.done() } } diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 28149ed..c0583db 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -69,7 +69,19 @@ }) }) }, - + // 自动登录接口 + AppLogin({ commit }, token) { + return new Promise((resolve, reject) => { + // 如果token存在直接setToken + if (token) { + setToken(token) + commit('SET_TOKEN', token) + resolve() + } else { + reject() + } + }) + }, // 获取用户信息 GetInfo({ commit, state }) { return new Promise((resolve, reject) => { diff --git a/src/styles/element-ui.scss b/src/styles/element-ui.scss index d15535e..c7968c9 100644 --- a/src/styles/element-ui.scss +++ b/src/styles/element-ui.scss @@ -64,3 +64,14 @@ max-width: 200px !important; } +.title-img{ + .el-image{ + //height:100%; + .el-image__inner{ + //height:100%; + object-position: left !important; + width:auto; + } + } +} + diff --git a/src/views/baseSource/baseSource.vue b/src/views/baseSource/baseSource.vue index cd941b9..bd19789 100644 --- a/src/views/baseSource/baseSource.vue +++ b/src/views/baseSource/baseSource.vue @@ -27,8 +27,9 @@ const map = L.map(this.$refs.map, { minZoom: 3, maxZoom: 18, - center: [27.75962, 116.06021], - zoom: 15, + // center: [27.75962, 116.06021], + center: this.baseConfig.center, + zoom: this.baseConfig.zoom, zoomControl: false, attributionControl: false, crs: L.CRS.EPSG3857 @@ -36,11 +37,13 @@ this.map = map // data上需要挂载 window.map = map this.baselayer.push(L.tileLayer( - 'https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + // 'https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + this.baseConfig.mapUrl, { subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'] } ).addTo(map)) this.baselayer.push(L.tileLayer( - 'https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + // 'https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + this.baseConfig.labelUrl, { subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'] } ).addTo(map)) } diff --git a/README-zh.md b/README-zh.md index 8ba0011..1792779 100644 --- a/README-zh.md +++ b/README-zh.md @@ -1,8 +1,7 @@ -# 协同办公子系统前端 +# 智慧城管系统基础子系统前端 -> 城管产品化协同办公子系统WEB前端. +> 智慧城管系统基础子系统WEB前端. -> 可作为后续前后端分离的管理系统的基础前端框架使用。 ## 相关项目 @@ -32,7 +31,7 @@ ```bash # 克隆项目 -git clone http://192.168.0.203:8080/gitbucket/root/smartwell_front +git clone http://111.198.10.15:12003/gitbucket/git/wangxiaoying/dcms_front.git # 安装依赖 npm install @@ -50,9 +49,35 @@ npm run build --report ``` -## 界面 +## 配置文件属性解释 -![demo](http://192.168.0.203:8080/gitbucket/root/BaseFrontEnd/tree/master/static/images/demo.gif) +static/project.config.json + +```` +{ + "title": "智慧城管平台", + "baseUrl": "http://111.198.10.15:11409/", + "sameWindow": true, + "city":"崇仁县", + "mapUrl":"https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "labelUrl":"https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8", + "center":[27.75962, 116.06021], + "zoom":15 +} +```` +- title: 系统名称 +- baseUrl: 后台地址 +- sameWindow: 是否要在同一个窗口打开子系统,true为是,false为否,选择false将在新窗口打开子系统 +- city: 城市,暂无用处 +- mapUrl: 地图地址 +- labelUrl: 地图标注地址 +- center: 默认地图中心坐标 [纬度,经度] +- zoom: 默认缩放级别,数字 + + + + + ## 浏览器支持情况 diff --git a/index.html b/index.html index 9a5a6eb..5227303 100644 --- a/index.html +++ b/index.html @@ -2,6 +2,8 @@ + + 智慧城管平台 diff --git a/src/components/CaseCommon/caseDetail.vue b/src/components/CaseCommon/caseDetail.vue index ff2621b..abe9f13 100644 --- a/src/components/CaseCommon/caseDetail.vue +++ b/src/components/CaseCommon/caseDetail.vue @@ -261,7 +261,7 @@ - 小时 + 小时 分钟 @@ -276,7 +276,7 @@ - 小时 + 小时 分钟 diff --git a/src/icons/svg/icon-lamp.svg b/src/icons/svg/icon-lamp.svg new file mode 100644 index 0000000..0423cec --- /dev/null +++ b/src/icons/svg/icon-lamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-pipe.svg b/src/icons/svg/icon-pipe.svg new file mode 100644 index 0000000..17a907f --- /dev/null +++ b/src/icons/svg/icon-pipe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-store.svg b/src/icons/svg/icon-store.svg new file mode 100644 index 0000000..4813b3d --- /dev/null +++ b/src/icons/svg/icon-store.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/icons/svg/icon-toilet.svg b/src/icons/svg/icon-toilet.svg new file mode 100644 index 0000000..9522392 --- /dev/null +++ b/src/icons/svg/icon-toilet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/main.js b/src/main.js index f1c1c55..043a276 100644 --- a/src/main.js +++ b/src/main.js @@ -56,10 +56,22 @@ import VCharts from 'v-charts' Vue.use(VCharts) -new Vue({ - el: '#app', - router, - store, - render: h => h(App) +// 先加载配置文件后,new Vue +/* eslint-disable no-new */ +import axios from 'axios' +import service from '@/utils/request' +axios.get('./static/project.config.json').then((result) => { + console.log('get config') + Vue.prototype.baseConfig = result.data + document.title = result.data.title // 首先设置网页的title + service.defaults.baseURL = result.data.baseUrl // 设置默认请求网址 + new Vue({ + el: '#app', + router, + store, + render: h => h(App) + }) +}).catch((error) => { + console.log('get baseConfig error...' + error) }) diff --git a/src/permission.js b/src/permission.js index e41df7c..669bb65 100644 --- a/src/permission.js +++ b/src/permission.js @@ -59,9 +59,21 @@ console.log('is In WhiteList') next() } else { - console.log('noTokentoToLogin') - // next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 - next('/login') // 否则全部重定向到登录页 + // 获取链接里的token + const token = to.query.token + console.log('token' + to.query.token) + if (token) { + // 调用自动登录接口,否则跳转到登录页 + store.dispatch('AppLogin', token).then(() => { + console.log('自动登录成功') + console.log(to.path) + next({ ...to, replace: true }) // 登录成功继续 + }).catch(() => { + next('/401') // 否则全部重定向到401没有权限页面 + }) + } else { + next(`/login?redirect=${to.path}`) // 否则全部重定向到登录页 + } NProgress.done() } } diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 28149ed..c0583db 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -69,7 +69,19 @@ }) }) }, - + // 自动登录接口 + AppLogin({ commit }, token) { + return new Promise((resolve, reject) => { + // 如果token存在直接setToken + if (token) { + setToken(token) + commit('SET_TOKEN', token) + resolve() + } else { + reject() + } + }) + }, // 获取用户信息 GetInfo({ commit, state }) { return new Promise((resolve, reject) => { diff --git a/src/styles/element-ui.scss b/src/styles/element-ui.scss index d15535e..c7968c9 100644 --- a/src/styles/element-ui.scss +++ b/src/styles/element-ui.scss @@ -64,3 +64,14 @@ max-width: 200px !important; } +.title-img{ + .el-image{ + //height:100%; + .el-image__inner{ + //height:100%; + object-position: left !important; + width:auto; + } + } +} + diff --git a/src/views/baseSource/baseSource.vue b/src/views/baseSource/baseSource.vue index cd941b9..bd19789 100644 --- a/src/views/baseSource/baseSource.vue +++ b/src/views/baseSource/baseSource.vue @@ -27,8 +27,9 @@ const map = L.map(this.$refs.map, { minZoom: 3, maxZoom: 18, - center: [27.75962, 116.06021], - zoom: 15, + // center: [27.75962, 116.06021], + center: this.baseConfig.center, + zoom: this.baseConfig.zoom, zoomControl: false, attributionControl: false, crs: L.CRS.EPSG3857 @@ -36,11 +37,13 @@ this.map = map // data上需要挂载 window.map = map this.baselayer.push(L.tileLayer( - 'https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + // 'https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + this.baseConfig.mapUrl, { subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'] } ).addTo(map)) this.baselayer.push(L.tileLayer( - 'https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + // 'https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=216ee92889e17ab1b083fae665d522b8', + this.baseConfig.labelUrl, { subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'] } ).addTo(map)) } diff --git a/src/views/dashboard/index.vue b/src/views/dashboard/index.vue index 12e0d1d..1e2dde6 100644 --- a/src/views/dashboard/index.vue +++ b/src/views/dashboard/index.vue @@ -1,7 +1,7 @@