Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sample-form-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
sample-form-platform
Commits
43ff0178
Commit
43ff0178
authored
Jun 05, 2025
by
“yiyousong”
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perf: 回退版本加优化基础设置热点词汇
parent
2e308032
Changes
35
Show whitespace changes
Inline
Side-by-side
Showing
35 changed files
with
823 additions
and
911 deletions
+823
-911
sample-form-manager-ui/admin/.eslintrc.js
sample-form-manager-ui/admin/.eslintrc.js
+15
-12
sample-form-manager-ui/admin/package.json
sample-form-manager-ui/admin/package.json
+1
-2
sample-form-manager-ui/admin/src/App.vue
sample-form-manager-ui/admin/src/App.vue
+23
-4
sample-form-manager-ui/admin/src/api/system.js
sample-form-manager-ui/admin/src/api/system.js
+0
-224
sample-form-manager-ui/admin/src/assets/css/common.less
sample-form-manager-ui/admin/src/assets/css/common.less
+0
-7
sample-form-manager-ui/admin/src/assets/fonts/demo_index.html
...le-form-manager-ui/admin/src/assets/fonts/demo_index.html
+211
-0
sample-form-manager-ui/admin/src/components/TableHeader.vue
sample-form-manager-ui/admin/src/components/TableHeader.vue
+1
-4
sample-form-manager-ui/admin/src/main.js
sample-form-manager-ui/admin/src/main.js
+2
-10
sample-form-manager-ui/admin/src/pages/hardware/NumberWriteDevice.vue
...manager-ui/admin/src/pages/hardware/NumberWriteDevice.vue
+6
-13
sample-form-manager-ui/admin/src/pages/hardware/modal/AddDevice.vue
...m-manager-ui/admin/src/pages/hardware/modal/AddDevice.vue
+2
-2
sample-form-manager-ui/admin/src/pages/hardware/modal/AddMatter.vue
...m-manager-ui/admin/src/pages/hardware/modal/AddMatter.vue
+3
-1
sample-form-manager-ui/admin/src/pages/jump/jump.vue
sample-form-manager-ui/admin/src/pages/jump/jump.vue
+7
-46
sample-form-manager-ui/admin/src/pages/layouts/Layouts.vue
sample-form-manager-ui/admin/src/pages/layouts/Layouts.vue
+94
-32
sample-form-manager-ui/admin/src/pages/layouts/components/Header.vue
...-manager-ui/admin/src/pages/layouts/components/Header.vue
+121
-40
sample-form-manager-ui/admin/src/pages/layouts/components/HeaderSite copy.vue
...ui/admin/src/pages/layouts/components/HeaderSite copy.vue
+2
-2
sample-form-manager-ui/admin/src/pages/layouts/components/HeaderSite.vue
...ager-ui/admin/src/pages/layouts/components/HeaderSite.vue
+3
-2
sample-form-manager-ui/admin/src/pages/login/login.vue
sample-form-manager-ui/admin/src/pages/login/login.vue
+2
-1
sample-form-manager-ui/admin/src/pages/software/basics/BasicsSet.vue
...-manager-ui/admin/src/pages/software/basics/BasicsSet.vue
+7
-10
sample-form-manager-ui/admin/src/pages/software/librarymanage/LibraryManage.vue
.../admin/src/pages/software/librarymanage/LibraryManage.vue
+3
-13
sample-form-manager-ui/admin/src/pages/software/librarymanage/modal/AddMaterals.vue
...in/src/pages/software/librarymanage/modal/AddMaterals.vue
+9
-6
sample-form-manager-ui/admin/src/pages/software/materials/MaterialsManage.vue
...ui/admin/src/pages/software/materials/MaterialsManage.vue
+11
-38
sample-form-manager-ui/admin/src/pages/software/materials/modal/AddFolders.vue
...i/admin/src/pages/software/materials/modal/AddFolders.vue
+2
-2
sample-form-manager-ui/admin/src/pages/software/materials/modal/AddMaterials.vue
...admin/src/pages/software/materials/modal/AddMaterials.vue
+5
-3
sample-form-manager-ui/admin/src/pages/software/materials/modal/CommonLib.vue
...ui/admin/src/pages/software/materials/modal/CommonLib.vue
+3
-1
sample-form-manager-ui/admin/src/pages/software/matter/MatterManage.vue
...nager-ui/admin/src/pages/software/matter/MatterManage.vue
+10
-32
sample-form-manager-ui/admin/src/pages/software/matter/modal/AddMatter.vue
...er-ui/admin/src/pages/software/matter/modal/AddMatter.vue
+5
-3
sample-form-manager-ui/admin/src/pages/software/skinManage/SkinManage.vue
...ger-ui/admin/src/pages/software/skinManage/SkinManage.vue
+3
-2
sample-form-manager-ui/admin/src/pages/system/parameter/Parameter.vue
...manager-ui/admin/src/pages/system/parameter/Parameter.vue
+5
-19
sample-form-manager-ui/admin/src/pages/system/parameter/modal/AddParameter.vue
...i/admin/src/pages/system/parameter/modal/AddParameter.vue
+2
-2
sample-form-manager-ui/admin/src/pages/system/task/TaskSet.vue
...e-form-manager-ui/admin/src/pages/system/task/TaskSet.vue
+7
-21
sample-form-manager-ui/admin/src/pages/system/task/modal/AddTask.vue
...-manager-ui/admin/src/pages/system/task/modal/AddTask.vue
+2
-2
sample-form-manager-ui/admin/src/router/index.js
sample-form-manager-ui/admin/src/router/index.js
+240
-117
sample-form-manager-ui/admin/src/store/index.js
sample-form-manager-ui/admin/src/store/index.js
+10
-81
sample-form-manager-ui/admin/src/utils/index.js
sample-form-manager-ui/admin/src/utils/index.js
+0
-100
sample-form-manager-ui/admin/yarn.lock
sample-form-manager-ui/admin/yarn.lock
+6
-57
No files found.
sample-form-manager-ui/admin/.eslintrc.js
View file @
43ff0178
module
.
exports
=
{
module
.
exports
=
{
root
:
true
,
root
:
true
,
env
:
{
env
:
{
node
:
true
,
node
:
true
},
},
extends
:
[
"
plugin:vue/essential
"
,
"
eslint:recommended
"
],
'
extends
'
:
[
'
plugin:vue/essential
'
,
'
eslint:recommended
'
],
parserOptions
:
{
parserOptions
:
{
parser
:
"
@babel/eslint-parser
"
,
parser
:
'
@babel/eslint-parser
'
},
},
rules
:
{
rules
:
{
"
no-console
"
:
process
.
env
.
NODE_ENV
===
"
production
"
?
"
warn
"
:
"
off
"
,
'
no-console
'
:
process
.
env
.
NODE_ENV
===
'
production
'
?
'
warn
'
:
'
off
'
,
"
no-debugger
"
:
process
.
env
.
NODE_ENV
===
"
production
"
?
"
warn
"
:
"
off
"
,
'
no-debugger
'
:
process
.
env
.
NODE_ENV
===
'
production
'
?
'
warn
'
:
'
off
'
,
"
vue/no-mutating-props
"
:
0
,
'
vue/no-mutating-props
'
:
0
,
},
},
overrides
:
[
overrides
:
[
{
{
files
:
[
"
src/**/**/*.vue
"
],
files
:
[
'
src/**/**/*.vue
'
],
rules
:
{
rules
:
{
"
vue/multi-word-component-names
"
:
0
,
'
vue/multi-word-component-names
'
:
0
}
,
}
}
,
}
]
,
]
}
;
}
sample-form-manager-ui/admin/package.json
View file @
43ff0178
...
@@ -13,7 +13,6 @@
...
@@ -13,7 +13,6 @@
},
},
"dependencies"
:
{
"dependencies"
:
{
"@babel/parser"
:
"^7.7.4"
,
"@babel/parser"
:
"^7.7.4"
,
"@riophae/vue-treeselect"
:
"^0.4.0"
,
"axios"
:
"^0.27.2"
,
"axios"
:
"^0.27.2"
,
"beautifier"
:
"^0.1.7"
,
"beautifier"
:
"^0.1.7"
,
"clipboard"
:
"^2.0.4"
,
"clipboard"
:
"^2.0.4"
,
...
@@ -21,7 +20,7 @@
...
@@ -21,7 +20,7 @@
"crypto-js"
:
"^4.1.1"
,
"crypto-js"
:
"^4.1.1"
,
"css-loader"
:
"^3.5.3"
,
"css-loader"
:
"^3.5.3"
,
"element-china-area-data"
:
"^5.0.2"
,
"element-china-area-data"
:
"^5.0.2"
,
"element-ui"
:
"^2.15.1
4
"
,
"element-ui"
:
"^2.15.1
0
"
,
"file-saver"
:
"^2.0.2"
,
"file-saver"
:
"^2.0.2"
,
"moment"
:
"^2.29.4"
,
"moment"
:
"^2.29.4"
,
"npm"
:
"^6.13.7"
,
"npm"
:
"^6.13.7"
,
...
...
sample-form-manager-ui/admin/src/App.vue
View file @
43ff0178
...
@@ -9,16 +9,35 @@ export default {
...
@@ -9,16 +9,35 @@ export default {
data
()
{
data
()
{
return
{};
return
{};
},
},
created
()
{},
created
()
{
methods
:
{},
// this.readVueXData();
},
methods
:
{
// 解决刷新store初始化问题
readVueXData
()
{
window
.
addEventListener
(
"
beforeunload
"
,
()
=>
{
sessionStorage
.
setItem
(
"
store
"
,
JSON
.
stringify
(
this
.
$store
.
state
));
});
if
(
sessionStorage
.
getItem
(
"
store
"
))
{
this
.
$store
.
replaceState
(
Object
.
assign
(
{},
this
.
$store
.
state
,
JSON
.
parse
(
sessionStorage
.
getItem
(
"
store
"
))
)
);
sessionStorage
.
removeItem
(
"
store
"
);
}
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
>
.app {
.app {
max-width: 2560px;
width: 100%;
margin: auto;
height: 100%;
height: 100%;
background-color: #f0f2f5;
background-color: #f0f2f5;
// display: flex;
}
}
</
style
>
</
style
>
sample-form-manager-ui/admin/src/api/system.js
View file @
43ff0178
...
@@ -92,227 +92,3 @@ export const getlog = (params) => {
...
@@ -92,227 +92,3 @@ export const getlog = (params) => {
params
,
params
,
});
});
};
};
/**
* 资源信息
*/
// 获取资源信息列表
export
const
getResourceList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/resource/list`
,
method
:
"
post
"
,
data
,
});
};
// 获取资源信息详情
export
const
getResourceDetail
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/resource/info`
,
method
:
"
get
"
,
params
,
});
};
// 添加资源信息
export
const
saveResource
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/resource/save`
,
method
:
"
post
"
,
data
,
});
};
// 删除资源信息
export
const
deleteResource
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/resource/delete`
,
method
:
"
get
"
,
params
,
});
};
// 刷新资源
export
const
refreshResource
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/resource/refreshUrl`
,
method
:
"
post
"
,
data
,
});
};
// 资源分组
export
const
getResourceGroup
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/resource/group`
,
method
:
"
post
"
,
data
,
});
};
/**
* 角色
*/
// 获取角色列表
export
const
getRoleList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/list`
,
method
:
"
post
"
,
data
,
});
};
// 获取角色详情
export
const
getRole
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/role/get`
,
method
:
"
get
"
,
params
,
});
};
// 保存角色
export
const
addRole
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/save`
,
method
:
"
post
"
,
data
,
});
};
// 删除角色
export
const
deleteRole
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/role/delete`
,
method
:
"
get
"
,
params
,
});
};
// 获取角色资源列表
export
const
getRoleResourceList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/auth/list`
,
method
:
"
post
"
,
data
,
});
};
// 添加角色资源
export
const
addRoleResource
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/auth/distributionSource`
,
method
:
"
post
"
,
data
,
});
};
// 添加角色菜单
export
const
addRoleMenu
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/auth/distributionMenu`
,
method
:
"
post
"
,
data
,
});
};
// 获取角色菜单
export
const
getRoleMenuList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/role/auth/editMenu`
,
method
:
"
post
"
,
data
,
});
};
/**
* 用户管理
*/
// 获取用户列表
export
const
getUserList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/user/list`
,
method
:
"
post
"
,
data
,
});
};
// 获取用户信息
export
const
getUserInfo
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/user/info`
,
method
:
"
get
"
,
params
,
});
};
// 保存用户
export
const
saveUser
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/user/save`
,
method
:
"
post
"
,
data
,
});
};
// 删除用户
export
const
deleteUser
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/user/delete`
,
method
:
"
get
"
,
params
,
});
};
/**
* 菜单管理
*/
// 获取菜单列表
export
const
getMenuList
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/menu/list`
,
method
:
"
post
"
,
data
,
});
};
// 获取菜单信息
export
const
getMenuInfo
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/menu/info`
,
method
:
"
get
"
,
params
,
});
};
// 保存菜单
export
const
saveMenu
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/menu/save`
,
method
:
"
post
"
,
data
,
});
};
// 删除菜单
export
const
deleteMenu
=
(
params
)
=>
{
return
request
({
url
:
`/sampleform/menu/delete`
,
method
:
"
get
"
,
params
,
});
};
// 改变菜单排序
export
const
changeMenuSort
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/menu/upOrDown`
,
method
:
"
post
"
,
data
,
});
};
// 获取菜单树列表
export
const
getMenuTreeselect
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/menu/treeselect`
,
method
:
"
post
"
,
data
,
});
};
// 获取个人菜单树
export
const
getMenuTree
=
(
data
)
=>
{
return
request
({
url
:
`/sampleform/login/index`
,
method
:
"
post
"
,
data
,
});
};
sample-form-manager-ui/admin/src/assets/css/common.less
View file @
43ff0178
...
@@ -430,13 +430,6 @@
...
@@ -430,13 +430,6 @@
.el-tabs__header{
.el-tabs__header{
margin: 0px !important;
margin: 0px !important;
}
}
.table-control{
display: flex;
align-items: center;
justify-content: center;
gap:8px;
}
// .el-tabs__content {
// .el-tabs__content {
// padding: 0px 15px 15px 15px;
// padding: 0px 15px 15px 15px;
// }
// }
sample-form-manager-ui/admin/src/assets/fonts/demo_index.html
0 → 100644
View file @
43ff0178
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
/>
<title>
iconfont Demo
</title>
<link
rel=
"shortcut icon"
href=
"//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg"
type=
"image/x-icon"
/>
<link
rel=
"icon"
type=
"image/svg+xml"
href=
"//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg"
/>
<link
rel=
"stylesheet"
href=
"https://g.alicdn.com/thx/cube/1.3.2/cube.min.css"
>
<link
rel=
"stylesheet"
href=
"demo.css"
>
<link
rel=
"stylesheet"
href=
"iconfont.css"
>
<script
src=
"iconfont.js"
></script>
<!-- jQuery -->
<script
src=
"https://a1.alicdn.com/oss/uploads/2018/12/26/7bfddb60-08e8-11e9-9b04-53e73bb6408b.js"
></script>
<!-- 代码高亮 -->
<script
src=
"https://a1.alicdn.com/oss/uploads/2018/12/26/a3f714d0-08e6-11e9-8a15-ebf944d7534c.js"
></script>
<style>
.main
.logo
{
margin-top
:
0
;
height
:
auto
;
}
.main
.logo
a
{
display
:
flex
;
align-items
:
center
;
}
.main
.logo
.sub-title
{
margin-left
:
0.5em
;
font-size
:
22px
;
color
:
#fff
;
background
:
linear-gradient
(
-45deg
,
#3967FF
,
#B500FE
);
-webkit-background-clip
:
text
;
-webkit-text-fill-color
:
transparent
;
}
</style>
</head>
<body>
<div
class=
"main"
>
<h1
class=
"logo"
><a
href=
"https://www.iconfont.cn/"
title=
"iconfont 首页"
target=
"_blank"
>
<img
width=
"200"
src=
"https://img.alicdn.com/imgextra/i3/O1CN01Mn65HV1FfSEzR6DKv_!!6000000000514-55-tps-228-59.svg"
>
</a></h1>
<div
class=
"nav-tabs"
>
<ul
id=
"tabs"
class=
"dib-box"
>
<li
class=
"dib active"
><span>
Unicode
</span></li>
<li
class=
"dib"
><span>
Font class
</span></li>
<li
class=
"dib"
><span>
Symbol
</span></li>
</ul>
<a
href=
"https://www.iconfont.cn/manage/index?manage_type=myprojects&projectId=4136233"
target=
"_blank"
class=
"nav-more"
>
查看项目
</a>
</div>
<div
class=
"tab-container"
>
<div
class=
"content unicode"
style=
"display: block;"
>
<ul
class=
"icon_lists dib-box"
>
<li
class=
"dib"
>
<span
class=
"icon iconfont"
>

</span>
<div
class=
"name"
>
24gf-folderOpen
</div>
<div
class=
"code-name"
>
&
#xeac5;
</div>
</li>
</ul>
<div
class=
"article markdown"
>
<h2
id=
"unicode-"
>
Unicode 引用
</h2>
<hr>
<p>
Unicode 是字体在网页端最原始的应用方式,特点是:
</p>
<ul>
<li>
支持按字体的方式去动态调整图标大小,颜色等等。
</li>
<li>
默认情况下不支持多色,直接添加多色图标会自动去色。
</li>
</ul>
<blockquote>
<p>
注意:新版 iconfont 支持两种方式引用多色图标:SVG symbol 引用方式和彩色字体图标模式。(使用彩色字体图标需要在「编辑项目」中开启「彩色」选项后并重新生成。)
</p>
</blockquote>
<p>
Unicode 使用步骤如下:
</p>
<h3
id=
"-font-face"
>
第一步:拷贝项目下面生成的
<code>
@font-face
</code></h3>
<pre><code
class=
"language-css"
>
@font-face {
font-family: 'iconfont';
src: url('iconfont.woff2?t=1687661668952') format('woff2'),
url('iconfont.woff?t=1687661668952') format('woff'),
url('iconfont.ttf?t=1687661668952') format('truetype');
}
</code></pre>
<h3
id=
"-iconfont-"
>
第二步:定义使用 iconfont 的样式
</h3>
<pre><code
class=
"language-css"
>
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
</code></pre>
<h3
id=
"-"
>
第三步:挑选相应图标并获取字体编码,应用于页面
</h3>
<pre>
<code
class=
"language-html"
>
<
span class="iconfont"
>&
#x33;
<
/span
>
</code></pre>
<blockquote>
<p>
"iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。
</p>
</blockquote>
</div>
</div>
<div
class=
"content font-class"
>
<ul
class=
"icon_lists dib-box"
>
<li
class=
"dib"
>
<span
class=
"icon iconfont icon-folder"
></span>
<div
class=
"name"
>
24gf-folderOpen
</div>
<div
class=
"code-name"
>
.icon-folder
</div>
</li>
</ul>
<div
class=
"article markdown"
>
<h2
id=
"font-class-"
>
font-class 引用
</h2>
<hr>
<p>
font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。
</p>
<p>
与 Unicode 使用方式相比,具有如下特点:
</p>
<ul>
<li>
相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。
</li>
<li>
因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。
</li>
</ul>
<p>
使用步骤如下:
</p>
<h3
id=
"-fontclass-"
>
第一步:引入项目下面生成的 fontclass 代码:
</h3>
<pre><code
class=
"language-html"
>
<
link rel="stylesheet" href="./iconfont.css"
>
</code></pre>
<h3
id=
"-"
>
第二步:挑选相应图标并获取类名,应用于页面:
</h3>
<pre><code
class=
"language-html"
>
<
span class="iconfont icon-xxx"
><
/span
>
</code></pre>
<blockquote>
<p>
"
iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。
</p>
</blockquote>
</div>
</div>
<div
class=
"content symbol"
>
<ul
class=
"icon_lists dib-box"
>
<li
class=
"dib"
>
<svg
class=
"icon svg-icon"
aria-hidden=
"true"
>
<use
xlink:href=
"#icon-folder"
></use>
</svg>
<div
class=
"name"
>
24gf-folderOpen
</div>
<div
class=
"code-name"
>
#icon-folder
</div>
</li>
</ul>
<div
class=
"article markdown"
>
<h2
id=
"symbol-"
>
Symbol 引用
</h2>
<hr>
<p>
这是一种全新的使用方式,应该说这才是未来的主流,也是平台目前推荐的用法。相关介绍可以参考这篇
<a
href=
""
>
文章
</a>
这种用法其实是做了一个 SVG 的集合,与另外两种相比具有如下特点:
</p>
<ul>
<li>
支持多色图标了,不再受单色限制。
</li>
<li>
通过一些技巧,支持像字体那样,通过
<code>
font-size
</code>
,
<code>
color
</code>
来调整样式。
</li>
<li>
兼容性较差,支持 IE9+,及现代浏览器。
</li>
<li>
浏览器渲染 SVG 的性能一般,还不如 png。
</li>
</ul>
<p>
使用步骤如下:
</p>
<h3
id=
"-symbol-"
>
第一步:引入项目下面生成的 symbol 代码:
</h3>
<pre><code
class=
"language-html"
>
<
script src="./iconfont.js"
><
/script
>
</code></pre>
<h3
id=
"-css-"
>
第二步:加入通用 CSS 代码(引入一次就行):
</h3>
<pre><code
class=
"language-html"
>
<
style
>
.icon {
width: 1em;
height: 1em;
vertical-align: -0.15em;
fill: currentColor;
overflow: hidden;
}
<
/style
>
</code></pre>
<h3
id=
"-"
>
第三步:挑选相应图标并获取类名,应用于页面:
</h3>
<pre><code
class=
"language-html"
>
<
svg class="icon" aria-hidden="true"
>
<
use xlink:href="#icon-xxx"
><
/use
>
<
/svg
>
</code></pre>
</div>
</div>
</div>
</div>
<script>
$
(
document
).
ready
(
function
()
{
$
(
'
.tab-container .content:first
'
).
show
()
$
(
'
#tabs li
'
).
click
(
function
(
e
)
{
var
tabContent
=
$
(
'
.tab-container .content
'
)
var
index
=
$
(
this
).
index
()
if
(
$
(
this
).
hasClass
(
'
active
'
))
{
return
}
else
{
$
(
'
#tabs li
'
).
removeClass
(
'
active
'
)
$
(
this
).
addClass
(
'
active
'
)
tabContent
.
hide
().
eq
(
index
).
fadeIn
()
}
})
})
</script>
</body>
</html>
sample-form-manager-ui/admin/src/components/TableHeader.vue
View file @
43ff0178
...
@@ -20,8 +20,5 @@ export default {};
...
@@ -20,8 +20,5 @@ export default {};
display: flex;
display: flex;
align-items: center;
align-items: center;
justify-content: space-between;
justify-content: space-between;
:deep(.el-form-item) {
margin-bottom: 0px;
}
}
}
</
style
>
</
style
>
\ No newline at end of file
sample-form-manager-ui/admin/src/main.js
View file @
43ff0178
...
@@ -14,12 +14,6 @@ import "@/assets/fonts/iconfont.css";
...
@@ -14,12 +14,6 @@ import "@/assets/fonts/iconfont.css";
import
moment
from
"
moment
"
;
import
moment
from
"
moment
"
;
Vue
.
prototype
.
$moment
=
moment
;
Vue
.
prototype
.
$moment
=
moment
;
// 引入注册全局指令
import
*
as
directives
from
"
@/directive
"
;
Object
.
keys
(
directives
).
forEach
((
name
)
=>
Vue
.
directive
(
name
,
directives
[
name
])
);
// 引入element-ui
// 引入element-ui
import
ElementUI
from
"
element-ui
"
;
import
ElementUI
from
"
element-ui
"
;
import
"
element-ui/lib/theme-chalk/index.css
"
;
import
"
element-ui/lib/theme-chalk/index.css
"
;
...
@@ -27,10 +21,8 @@ Vue.use(ElementUI);
...
@@ -27,10 +21,8 @@ Vue.use(ElementUI);
import
{
message
}
from
"
@/utils/resetMessage
"
;
import
{
message
}
from
"
@/utils/resetMessage
"
;
Vue
.
prototype
.
$message
=
message
;
Vue
.
prototype
.
$message
=
message
;
// 重置表单
import
{
resetForm
}
from
"
@/utils
"
;
import
{
resetForm
,
clearSelection
}
from
"
@/utils
"
;
Vue
.
prototype
.
resetForm
=
resetForm
;
Vue
.
prototype
.
$resetForm
=
resetForm
;
Vue
.
prototype
.
$clearSelection
=
clearSelection
;
// 注册全局组件
// 注册全局组件
import
customComponents
from
"
@/components
"
;
import
customComponents
from
"
@/components
"
;
...
...
sample-form-manager-ui/admin/src/pages/hardware/NumberWriteDevice.vue
View file @
43ff0178
...
@@ -120,22 +120,13 @@
...
@@ -120,22 +120,13 @@
class
=
"
primary
"
class
=
"
primary
"
>
激活
<
/spa
n
>
激活
<
/spa
n
>
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handleBound(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['numberwritedevice:binding']
"
@
click
=
"
handleBound(scope.row)
"
>
绑定表单
<
/spa
n
>
绑定表单
<
/spa
n
>
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handleEdit(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['numberwritedevice:edit']
"
@
click
=
"
handleEdit(scope.row)
"
>
编辑
<
/spa
n
>
编辑
<
/spa
n
>
>
<
span
<
span
class
=
"
delete pointer
"
@
click
=
"
handleDel(scope.row.id)
"
class
=
"
delete pointer
"
v
-
hasPermi
=
"
['numberwritedevice:remove']
"
@
click
=
"
handleDel(scope.row.id)
"
>
删除
<
/spa
n
>
删除
<
/spa
n
>
>
<
/div
>
<
/div
>
...
@@ -189,7 +180,9 @@ export default {
...
@@ -189,7 +180,9 @@ export default {
return
{
return
{
typeList
,
typeList
,
searchVal
:
""
,
searchVal
:
""
,
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
tableData
:
[],
tableData
:
[],
total
:
0
,
total
:
0
,
page
:
1
,
page
:
1
,
...
...
sample-form-manager-ui/admin/src/pages/hardware/modal/AddDevice.vue
View file @
43ff0178
...
@@ -261,7 +261,7 @@ export default {
...
@@ -261,7 +261,7 @@ export default {
},
},
methods
:
{
methods
:
{
handleReset
()
{
handleReset
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
},
},
handleOk
()
{
handleOk
()
{
this
.
$refs
.
form
.
validate
(
async
(
valid
)
=>
{
this
.
$refs
.
form
.
validate
(
async
(
valid
)
=>
{
...
@@ -288,7 +288,7 @@ export default {
...
@@ -288,7 +288,7 @@ export default {
},
10
);
},
10
);
},
},
handleClose
()
{
handleClose
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
Visible
=
false
;
this
.
Visible
=
false
;
},
},
},
},
...
...
sample-form-manager-ui/admin/src/pages/hardware/modal/AddMatter.vue
View file @
43ff0178
...
@@ -177,7 +177,9 @@ export default {
...
@@ -177,7 +177,9 @@ export default {
data
()
{
data
()
{
return
{
return
{
loading
:
false
,
loading
:
false
,
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
department
:
""
,
department
:
""
,
searchVal
:
""
,
searchVal
:
""
,
page
:
1
,
page
:
1
,
...
...
sample-form-manager-ui/admin/src/pages/jump/jump.vue
View file @
43ff0178
...
@@ -5,9 +5,8 @@
...
@@ -5,9 +5,8 @@
<
script
>
<
script
>
import
local
from
"
@/utils/local
"
;
import
local
from
"
@/utils/local
"
;
import
{
mapMutations
}
from
"
vuex
"
;
import
{
mapMutations
}
from
"
vuex
"
;
import
{
calcMenu
,
menusFilter
}
from
"
@/router
"
;
import
{
calcMenu
}
from
"
@/router
"
;
import
{
generateRoutes
,
filterBtn
}
from
"
@/utils
"
;
// import { getSiteTree } from "@/services/businessMatter";
import
{
getMenuTree
}
from
"
@/api/system
"
;
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -18,28 +17,18 @@ export default {
...
@@ -18,28 +17,18 @@ export default {
this
.
getInfo
();
this
.
getInfo
();
},
},
methods
:
{
methods
:
{
...
mapMutations
([
...
mapMutations
([
"
SET_sysName
"
,
"
SET_sysLogo
"
,
"
SET_token
"
,
"
SET_path
"
]),
"
SET_token
"
,
"
SET_sysName
"
,
"
SET_sysLogo
"
,
"
SET_path
"
,
"
SET_userInfo
"
,
"
SET_permissions
"
,
"
SET_routes
"
,
"
SET_menusList
"
,
"
SET_secondaryRoutes
"
,
]),
// 获取token和站点信息
// 获取token和站点信息
async
getInfo
()
{
async
getInfo
()
{
let
{
token
,
siteid
,
sysName
,
sysLogo
,
path
}
=
this
.
$route
.
query
;
let
{
token
,
siteid
,
sysName
,
sysLogo
,
path
}
=
this
.
$route
.
query
;
if
(
token
)
{
if
(
token
)
{
local
.
setLocal
(
"
siteId
"
,
siteid
);
local
.
setLocal
(
"
s
ampleS
iteId
"
,
siteid
);
this
.
SET_token
(
token
);
this
.
SET_token
(
token
);
this
.
SET_sysName
(
sysName
);
this
.
SET_sysName
(
sysName
);
this
.
SET_sysLogo
(
sysLogo
);
this
.
SET_sysLogo
(
sysLogo
);
this
.
SET_path
(
path
);
this
.
SET_path
(
path
);
calcMenu
();
calcMenu
();
await
this
.
getIndixData
(
);
this
.
$router
.
push
(
"
/basicsset
"
);
}
else
{
}
else
{
this
.
$message
.
warning
(
"
跳转失败,请重新登录
"
);
this
.
$message
.
warning
(
"
跳转失败,请重新登录
"
);
setTimeout
(()
=>
{
setTimeout
(()
=>
{
...
@@ -47,37 +36,9 @@ export default {
...
@@ -47,37 +36,9 @@ export default {
},
2000
);
},
2000
);
}
}
},
},
// 获取菜单列表
async
getIndixData
()
{
let
res
=
await
getMenuTree
();
if
(
res
.
data
.
code
==
1
)
{
let
{
menuList
}
=
res
.
data
.
data
;
// 过滤掉按钮
let
menus
=
filterBtn
(
menuList
,
false
);
let
routes
=
generateRoutes
(
menus
);
routes
=
menusFilter
(
routes
);
this
.
SET_menusList
(
menus
);
this
.
setBtnPermissions
(
menuList
);
calcMenu
();
if
(
routes
.
length
)
{
let
path
=
routes
[
0
].
path
;
this
.
SET_secondaryRoutes
(
path
);
this
.
$router
.
push
(
path
);
}
else
{
this
.
$message
.
warning
(
"
暂无页面权限,请联系管理员!
"
);
}
}
},
// 添加按钮权限字符
setBtnPermissions
(
menuList
)
{
let
btnPermissions
=
filterBtn
(
menuList
)
.
filter
((
v
)
=>
v
.
perms
)
.
map
((
v
)
=>
v
.
perms
);
this
.
SET_permissions
(
btnPermissions
);
},
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"less"
scoped
></
style
>
<
style
lang=
"less"
scoped
>
</
style
>
\ No newline at end of file
sample-form-manager-ui/admin/src/pages/layouts/Layouts.vue
View file @
43ff0178
<
template
>
<
template
>
<el-container
class=
"layout"
>
<div
class=
"layouts flex flexc aic"
>
<el-header
height=
"64px"
>
<Header></Header>
<Header></Header>
</el-header>
<!--
<div
class=
"crumbs"
>
<el-container
class=
"layout-main"
>
<el-breadcrumb
separator=
"/"
>
<el-aside
width=
"200px"
v-if=
"layout === 'side'"
>
<el-breadcrumb-item
<MenuBar></MenuBar>
><a
:href=
"portalUrl + '/#/home/dataManagement/dataAdmin'"
</el-aside>
>
政务一体化平台
</a
<el-main>
></el-breadcrumb-item
>
<el-breadcrumb-item
><a
:href=
"portalUrl + '/#/home/siteArrange'"
>
站点编排
</a
></el-breadcrumb-item
>
<el-breadcrumb-item
v-for=
"bread in breads"
:key=
"bread.title"
:to=
"bread.to"
>
{{
bread
.
title
}}
</el-breadcrumb-item
>
</el-breadcrumb>
</div>
-->
<div
class=
"main flex1 flex flexc"
>
<!--
<el-tabs
:value=
"activeKey"
@
tab-click=
"changeRouter"
>
<el-tab-pane
v-for=
"v in subMenus"
:key=
"v.path"
:name=
"v.path"
>
<template
slot=
"label"
>
<i
v-if=
"v.meta.icon"
:class=
"['mr5', 'primary', v.meta.icon]"
></i>
<span
class=
"tab-label"
>
{{
v
.
meta
.
title
}}
</span>
</
template
>
</el-tab-pane>
</el-tabs>
-->
<div
class=
"out-box flex1"
>
<keep-alive>
<keep-alive>
<!-- 需要缓存的视图组件 -->
<!-- 需要缓存的视图组件 -->
<router-view
v-if=
"$route.meta.keepAlive"
>
</router-view>
<router-view
v-if=
"$route.meta.keepAlive"
>
</router-view>
</keep-alive>
</keep-alive>
<!-- 不需要缓存的视图组件 -->
<!-- 不需要缓存的视图组件 -->
<router-view
v-if=
"!$route.meta.keepAlive"
>
</router-view>
<router-view
v-if=
"!$route.meta.keepAlive"
>
</router-view>
</
el-main
>
</
div
>
</
el-container
>
</
div
>
</
el-container
>
</
div
>
</template>
</template>
<
script
>
<
script
>
import
Header
from
"
./components/Header.vue
"
;
import
Header
from
"
./components/Header.vue
"
;
import
MenuBar
from
"
./components/MenuBar.vue
"
;
import
{
getdeptList
}
from
"
@/api/department
"
;
import
{
getdeptList
}
from
"
@/api/department
"
;
import
{
mapMutations
,
mapState
}
from
"
vuex
"
;
import
{
mapMutations
,
mapState
}
from
"
vuex
"
;
import
local
from
"
@/utils/local
"
;
import
local
from
"
@/utils/local
"
;
import
{
findBottomSubarrays
}
from
"
@/utils
"
;
import
{
systemName
}
from
"
@/config
"
;
import
{
systemName
}
from
"
@/config
"
;
export
default
{
export
default
{
components
:
{
components
:
{
Header
,
Header
,
MenuBar
,
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -40,22 +62,55 @@ export default {
...
@@ -40,22 +62,55 @@ export default {
};
};
},
},
created
()
{
created
()
{
// this.getSubMenus();
document
.
title
=
this
.
sysName
?
this
.
sysName
:
this
.
systemName
;
// 设置项目标题
document
.
title
=
this
.
sysName
?
this
.
sysName
:
this
.
systemName
;
// 设置项目标题
// this.calcBreads();
this
.
getdeptList
();
this
.
getdeptList
();
},
},
// watch: {
// "$route.path"() {
// this.calcBreads();
// },
// },
computed
:
{
computed
:
{
...
mapState
([
"
sysName
"
,
"
layout
"
]),
...
mapState
([
"
sysName
"
]),
activeKey
()
{
activeKey
()
{
return
this
.
$route
.
path
;
return
this
.
$route
.
path
;
},
},
},
},
methods
:
{
methods
:
{
...
mapMutations
([
"
SET_deptList
"
]),
...
mapMutations
([
"
SET_deptList
"
]),
// 计算面包屑
calcBreads
()
{
let
temp
=
[{
to
:
"
/basicsset
"
,
title
:
"
数字样表系统
"
}];
// 过滤出路由数据
let
r
=
this
.
$route
.
matched
.
filter
((
v
)
=>
v
.
meta
.
title
)
.
map
((
v
)
=>
{
return
{
to
:
v
.
path
,
title
:
v
.
meta
.
title
};
});
// 赋值给面包屑渲染
this
.
breads
=
[...
temp
,
...
r
];
},
// 获取当前顶层路由下的所有子路由
getSubMenus
()
{
let
path
=
this
.
$route
?.
meta
.
activeMenu
?
this
.
$route
.
meta
.
activeMenu
:
this
.
$route
.
path
;
let
options
=
this
.
$router
.
options
.
routes
[
0
].
children
;
let
curRouters
=
options
.
filter
((
v
)
=>
v
.
path
==
path
);
this
.
subMenus
=
findBottomSubarrays
(
curRouters
).
filter
(
(
v
)
=>
!
v
.
meta
.
hidden
);
},
// 获取部门列表
// 获取部门列表
async
getdeptList
()
{
async
getdeptList
()
{
let
res
=
await
getdeptList
({
let
res
=
await
getdeptList
({
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
page
:
1
,
page
:
1
,
size
:
-
1
,
size
:
-
1
,
});
});
...
@@ -73,20 +128,27 @@ export default {
...
@@ -73,20 +128,27 @@ export default {
</
script
>
</
script
>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
>
.layout {
.layouts {
height: 100vh;
width: 100%;
}
// min-width: 1620px;
.el-header {
height: 100%;
padding: 0px 20px;
padding-bottom: 15px;
background: linear-gradient(90deg, #1845c6 0%, #2999ff 100%);
// .crumbs {
}
// margin: 10px 0px;
.layout-main {
// width: 98%;
height: calc(100vh - 64px);
// }
}
.el-aside {
.main {
background-color: #fff;
width: 98%;
}
margin-top: 15px;
.el-main {
// padding-bottom: 15px;
overflow: auto;
border-radius: 4px;
overflow-y: auto;
// background-color: #fff;
}
.out-box {
// padding: 15px;
overflow-y: auto;
}
}
}
</
style
>
</
style
>
sample-form-manager-ui/admin/src/pages/layouts/components/Header.vue
View file @
43ff0178
<
template
>
<
template
>
<div
class=
"header
-content
"
>
<div
class=
"header
flex aic jcb
"
>
<div
class=
"l
ogo-box
"
>
<div
class=
"l
eft flex aic
"
>
<img
<img
class=
"logo"
class=
"
pointer mr10
logo"
:src=
"sysLogo ? sysLogo : require('@/assets/img/logo.png')"
:src=
"sysLogo ? sysLogo : require('@/assets/img/logo.png')"
alt=
"LOGO"
alt=
"LOGO"
@
click=
"handleGoHome"
@
click=
"handleGoHome"
/>
/>
<h1
class=
"title"
@
click=
"handleGoHome"
>
<h1
class=
"title
pointer
"
@
click=
"handleGoHome"
>
{{
sysName
?
sysName
:
systemName
}}
{{
sysName
?
sysName
:
systemName
}}
</h1>
</h1>
<HeaderSite
style=
"margin-right: 120px
"
></HeaderSite>
<HeaderSite
class=
"mr50 ml20
"
></HeaderSite>
<!-- 导航 -->
<!-- 导航 -->
<MenuBar
v-if=
"layout === 'head'"
mode=
"horizontal"
></MenuBar>
<el-menu
:default-active=
"activeMenu"
mode=
"horizontal"
router
text-color=
"rgba(254, 254, 254, 0.65)"
>
<template
v-for=
"v in menus"
>
<!-- 有子路由 -->
<el-submenu
v-if=
"!v.hideChildrenInMenu && v.children && v.children.length"
:key=
"'a' + v.path"
:index=
"v.path"
>
<template
slot=
"title"
>
<i
v-if=
"v.meta && v.meta.icon"
:class=
"v.meta.icon"
></i>
{{
v
.
meta
.
title
}}
</
template
>
<el-menu-item
v-for=
"item in v.children"
:key=
"item.path"
:index=
"item.path"
>
<i
v-if=
"item.meta && item.meta.icon"
:class=
"item.meta.icon"
></i>
{{ item.meta
&&
item.meta.title }}
</el-menu-item>
</el-submenu>
<!-- 单个路由 -->
<el-menu-item
v-else
:key=
"v.path"
:index=
"v.path"
>
<i
v-if=
"v.meta && v.meta.icon"
:class=
"v.meta.icon"
></i>
{{ v.meta.title }}
</el-menu-item>
</template>
<!-- <el-menu-item v-for="v in menus" :key="v.path" :index="v.path">
<i :class="v.meta.icon"></i>
{{ v.meta.title }}
</el-menu-item> -->
</el-menu>
</div>
</div>
<!-- 返回门户 -->
<!-- 返回门户 -->
<div
class=
"back-btn"
>
<div
class=
"back-btn"
>
...
@@ -27,14 +64,11 @@
...
@@ -27,14 +64,11 @@
<
script
>
<
script
>
import
HeaderSite
from
"
./HeaderSite.vue
"
;
import
HeaderSite
from
"
./HeaderSite.vue
"
;
import
MenuBar
from
"
./MenuBar.vue
"
;
import
{
systemName
}
from
"
@/config
"
;
import
{
systemName
}
from
"
@/config
"
;
import
{
mapState
,
mapMutations
}
from
"
vuex
"
;
import
{
mapState
}
from
"
vuex
"
;
export
default
{
export
default
{
components
:
{
components
:
{
HeaderSite
,
HeaderSite
,
MenuBar
,
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -45,58 +79,42 @@ export default {
...
@@ -45,58 +79,42 @@ export default {
computed
:
{
computed
:
{
activeMenu
()
{
activeMenu
()
{
const
route
=
this
.
$route
;
const
route
=
this
.
$route
;
const
{
meta
,
matched
}
=
route
;
const
{
meta
,
path
}
=
route
;
if
(
meta
.
activeMenu
)
{
if
(
meta
.
activeMenu
)
{
return
meta
.
activeMenu
;
return
meta
.
activeMenu
;
}
else
{
let
curMatched
=
matched
.
filter
((
v
)
=>
v
.
path
);
return
curMatched
[
0
].
path
;
}
}
return
path
;
},
},
...
mapState
([
"
menus
"
,
"
sysName
"
,
"
sysLogo
"
,
"
path
"
,
"
layout
"
]),
...
mapState
([
"
menus
"
,
"
sysName
"
,
"
sysLogo
"
,
"
path
"
]),
},
},
created
()
{},
created
()
{},
methods
:
{
methods
:
{
...
mapMutations
([
"
SET_secondaryRoutes
"
]),
selectMenu
(
index
)
{
this
.
SET_secondaryRoutes
(
index
);
},
handleGoHome
()
{
handleGoHome
()
{
let
path
=
this
.
menus
[
0
].
path
;
this
.
$router
.
push
(
"
/basicsset
"
);
if
(
path
)
{
this
.
$router
.
push
(
path
);
}
},
},
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
>
.header
-content
{
.header {
height:
100%
;
height:
64px
;
width: 100%;
width: 100%;
padding: 0px 24px;
// background-color: #2681e8;
background: linear-gradient(90deg, #1845c6 0%, #2999ff 100%);
color: #fff;
color: #fff;
display: flex;
flex-shrink: 0;
align-items: center;
justify-content: space-between;
.logo-box {
height: 100%;
display: flex;
align-items: center;
}
.logo {
.logo {
height: 32px;
height: 32px;
object-fit: contain;
object-fit: contain;
margin-right: 8px;
}
}
.left {
height: 100%;
}
.title {
.title {
margin-right: 34px;
max-width: 200px;
font-weight: bold;
font-size: 18px;
font-size: 18px;
line-height: normal;
color: #fff;
cursor: pointer;
}
}
.back-btn {
.back-btn {
a {
a {
...
@@ -105,4 +123,67 @@ export default {
...
@@ -105,4 +123,67 @@ export default {
}
}
}
}
}
}
/deep/.el-menu {
height: 100% !important;
border: none !important;
background-color: transparent;
i {
color: rgba(254, 254, 254, 0.65);
}
.el-menu-item {
height: 100% !important;
border: none !important;
display: flex;
align-items: center;
color: rgba(254, 254, 254, 0.65);
&:hover {
// background-color: transparent !important;
color: #fff !important;
background-color: #1890ff !important;
// border-bottom: 2px solid #fff !important;
}
}
}
/deep/.el-submenu {
height: 100% !important;
.el-submenu__title {
height: 100% !important;
display: flex;
align-items: center;
color: rgba(254, 254, 254, 0.65) !important;
border: none !important;
&:hover {
// background-color: transparent !important;
color: #fff !important;
background-color: #1890ff !important;
// border-bottom: 2px solid #fff !important;
}
}
}
.el-menu--horizontal .el-menu .el-menu-item {
color: #909399;
&:hover {
i {
color: #1890ff;
}
color: #1890ff;
}
}
.el-menu--horizontal .el-menu .el-menu-item.is-active {
color: #1890ff !important;
}
/deep/.is-active {
// border-bottom: 2px solid #fff !important;
color: #fff !important;
// background-color: transparent !important;
background-color: #1890ff !important;
.el-submenu__title {
border: none !important;
color: #fff !important;
// background-color: transparent !important;
background-color: #1890ff !important;
}
}
</
style
>
</
style
>
sample-form-manager-ui/admin/src/pages/layouts/components/HeaderSite copy.vue
View file @
43ff0178
...
@@ -162,7 +162,7 @@ export default {
...
@@ -162,7 +162,7 @@ export default {
}
}
});
});
};
};
const
siteid
=
local
.
getLocal
(
"
siteId
"
);
const
siteid
=
local
.
getLocal
(
"
s
ampleS
iteId
"
);
treeFn
(
siteTree
);
treeFn
(
siteTree
);
const
siteObj
=
arr
.
find
((
v
)
=>
v
.
id
==
siteid
);
const
siteObj
=
arr
.
find
((
v
)
=>
v
.
id
==
siteid
);
this
.
siteName
=
siteObj
?
siteObj
.
label
:
"
请选择站点
"
;
this
.
siteName
=
siteObj
?
siteObj
.
label
:
"
请选择站点
"
;
...
@@ -178,7 +178,7 @@ export default {
...
@@ -178,7 +178,7 @@ export default {
// siteName: obj.label,
// siteName: obj.label,
// siteid: obj.id,
// siteid: obj.id,
// };
// };
local
.
setLocal
(
"
siteId
"
,
obj
.
id
);
local
.
setLocal
(
"
s
ampleS
iteId
"
,
obj
.
id
);
this
.
show
=
false
;
this
.
show
=
false
;
if
(
location
.
href
.
search
(
/token/gi
)
>=
0
)
{
if
(
location
.
href
.
search
(
/token/gi
)
>=
0
)
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
...
...
sample-form-manager-ui/admin/src/pages/layouts/components/HeaderSite.vue
View file @
43ff0178
...
@@ -176,7 +176,7 @@ export default {
...
@@ -176,7 +176,7 @@ export default {
}
}
});
});
};
};
const
siteid
=
local
.
getLocal
(
"
siteId
"
);
const
siteid
=
local
.
getLocal
(
"
s
ampleS
iteId
"
);
treeFn
(
siteTree
);
treeFn
(
siteTree
);
const
siteObj
=
arr
.
find
((
v
)
=>
v
.
id
==
siteid
);
const
siteObj
=
arr
.
find
((
v
)
=>
v
.
id
==
siteid
);
this
.
siteName
=
siteObj
?
siteObj
.
label
:
"
请选择站点
"
;
this
.
siteName
=
siteObj
?
siteObj
.
label
:
"
请选择站点
"
;
...
@@ -189,7 +189,7 @@ export default {
...
@@ -189,7 +189,7 @@ export default {
// siteName: obj.label,
// siteName: obj.label,
// siteid: obj.id,
// siteid: obj.id,
// };
// };
local
.
setLocal
(
"
siteId
"
,
obj
.
id
);
local
.
setLocal
(
"
s
ampleS
iteId
"
,
obj
.
id
);
this
.
show
=
false
;
this
.
show
=
false
;
if
(
location
.
href
.
search
(
/token/gi
)
>=
0
)
{
if
(
location
.
href
.
search
(
/token/gi
)
>=
0
)
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
...
@@ -211,6 +211,7 @@ export default {
...
@@ -211,6 +211,7 @@ export default {
.ant-dropdown-link {
.ant-dropdown-link {
padding: 0 20px;
padding: 0 20px;
font-size: 16px;
font-size: 16px;
min-width: 200px;
display: inline-block;
display: inline-block;
}
}
.content {
.content {
...
...
sample-form-manager-ui/admin/src/pages/login/login.vue
View file @
43ff0178
...
@@ -64,7 +64,7 @@ export default {
...
@@ -64,7 +64,7 @@ export default {
let
siteIds
=
data
.
user
.
siteIds
;
let
siteIds
=
data
.
user
.
siteIds
;
let
siteid
=
siteIds
.
split
(
"
,
"
)[
0
];
let
siteid
=
siteIds
.
split
(
"
,
"
)[
0
];
if
(
token
)
{
if
(
token
)
{
local
.
setLocal
(
"
siteId
"
,
siteid
);
local
.
setLocal
(
"
s
ampleS
iteId
"
,
siteid
);
this
.
SET_token
(
token
);
this
.
SET_token
(
token
);
// 渲染菜单
// 渲染菜单
calcMenu
();
calcMenu
();
...
@@ -152,3 +152,4 @@ export default {
...
@@ -152,3 +152,4 @@ export default {
}
}
}
}
</
style
>
</
style
>
sample-form-manager-ui/admin/src/pages/software/basics/BasicsSet.vue
View file @
43ff0178
...
@@ -56,11 +56,7 @@
...
@@ -56,11 +56,7 @@
<
/div
>
<
/div
>
<
div
class
=
"
mt50
"
>
<
div
class
=
"
mt50
"
>
<
el
-
button
size
=
"
medium
"
@
click
=
"
handleReset
"
>
重
置
<
/el-button
>
<
el
-
button
size
=
"
medium
"
@
click
=
"
handleReset
"
>
重
置
<
/el-button
>
<
el
-
button
<
el
-
button
size
=
"
medium
"
type
=
"
primary
"
@
click
=
"
handleOk
"
size
=
"
medium
"
type
=
"
primary
"
v
-
hasPermi
=
"
['basicsset:save']
"
@
click
=
"
handleOk
"
>
确
定
>
确
定
<
/el-button
>
<
/el-button
>
<
/div
>
<
/div
>
...
@@ -78,7 +74,9 @@ export default {
...
@@ -78,7 +74,9 @@ export default {
}
,
}
,
data
()
{
data
()
{
return
{
return
{
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
inputVisible
:
false
,
inputVisible
:
false
,
inputValue
:
""
,
inputValue
:
""
,
newSourceEnumData
:
{
}
,
newSourceEnumData
:
{
}
,
...
@@ -101,10 +99,9 @@ export default {
...
@@ -101,10 +99,9 @@ export default {
if
(
res
.
data
.
code
===
1
)
{
if
(
res
.
data
.
code
===
1
)
{
this
.
newSourceEnumData
=
res
.
data
.
dict
.
newsSource
;
this
.
newSourceEnumData
=
res
.
data
.
dict
.
newsSource
;
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
this
.
baseSetInfo
.
hotwords
=
res
.
data
.
data
.
data
[
0
].
hotwordList
.
slice
(
this
.
baseSetInfo
.
hotwords
=
res
.
data
.
data
.
data
[
0
].
hotwordList
0
,
.
filter
((
v
)
=>
v
.
hotwords
)
10
.
slice
(
0
,
10
);
);
this
.
baseSetInfo
.
printDisplay
=
res
.
data
.
data
.
data
[
0
].
printDisplay
;
this
.
baseSetInfo
.
printDisplay
=
res
.
data
.
data
.
data
[
0
].
printDisplay
;
this
.
baseSetInfo
.
newsSource
=
res
.
data
.
data
.
data
[
0
].
newsSource
+
""
;
this
.
baseSetInfo
.
newsSource
=
res
.
data
.
data
.
data
[
0
].
newsSource
+
""
;
}
}
...
...
sample-form-manager-ui/admin/src/pages/software/librarymanage/LibraryManage.vue
View file @
43ff0178
...
@@ -7,11 +7,7 @@
...
@@ -7,11 +7,7 @@
<!--
<el-button
size=
"small"
type=
"primary"
@
click=
"handleAddMaterials"
<!--
<el-button
size=
"small"
type=
"primary"
@
click=
"handleAddMaterials"
>
加入材料
</el-button
>
加入材料
</el-button
>
-->
>
-->
<el-button
<el-button
size=
"small"
type=
"danger"
@
click=
"handleDelAll"
size=
"small"
type=
"danger"
v-hasPermi=
"['librarymanage:remove']"
@
click=
"handleDelAll"
>
批量移除
</el-button
>
批量移除
</el-button
>
>
</div>
</div>
...
@@ -69,16 +65,10 @@
...
@@ -69,16 +65,10 @@
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
div
class
=
"
flex jca
"
>
<
div
class
=
"
flex jca
"
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handlePreview(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['librarymanage:preview']
"
@
click
=
"
handlePreview(scope.row)
"
>
预览
<
/spa
n
>
预览
<
/spa
n
>
>
<
span
<
span
class
=
"
delete pointer
"
@
click
=
"
handleDel(scope.row.id)
"
class
=
"
delete pointer
"
v
-
hasPermi
=
"
['librarymanage:remove']
"
@
click
=
"
handleDel(scope.row.id)
"
>
移除
<
/spa
n
>
移除
<
/spa
n
>
>
<
/div
>
<
/div
>
...
...
sample-form-manager-ui/admin/src/pages/software/librarymanage/modal/AddMaterals.vue
View file @
43ff0178
...
@@ -76,12 +76,13 @@
...
@@ -76,12 +76,13 @@
>
>
<
/el-table-column
>
<
/el-table-column
>
<
/el-table
>
<
/el-table
>
<
y
-
p
agination
<
P
agination
:
total
=
"
total
"
:
total
=
"
total
"
:
page
=
"
current
"
:
current
=
"
current
"
:
pageSize
=
"
size
"
:
size
=
"
size
"
><
/y-pagination
>
@
currentChange
=
"
changePagination
"
@
sizeChange
=
"
changeSize
"
><
/Pagination
>
<
span
slot
=
"
footer
"
class
=
"
dialog-footer
"
>
<
span
slot
=
"
footer
"
class
=
"
dialog-footer
"
>
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
handleOk
"
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
handleOk
"
>
加
入
<
/el-butto
n
>
加
入
<
/el-butto
n
...
@@ -94,10 +95,12 @@
...
@@ -94,10 +95,12 @@
<
script
>
<
script
>
import
TableHeader
from
"
@/components/TableHeader.vue
"
;
import
TableHeader
from
"
@/components/TableHeader.vue
"
;
import
Pagination
from
"
@/components/Pagination.vue
"
;
import
{
mapGetters
}
from
"
vuex
"
;
import
{
mapGetters
}
from
"
vuex
"
;
export
default
{
export
default
{
components
:
{
components
:
{
TableHeader
,
TableHeader
,
Pagination
,
}
,
}
,
props
:
{
props
:
{
libVisible
:
{
libVisible
:
{
...
...
sample-form-manager-ui/admin/src/pages/software/materials/MaterialsManage.vue
View file @
43ff0178
...
@@ -84,39 +84,22 @@
...
@@ -84,39 +84,22 @@
<!--
内容
-->
<!--
内容
-->
<
TableHeader
>
<
TableHeader
>
<
div
slot
=
"
left
"
>
<
div
slot
=
"
left
"
>
<
el
-
button
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
handleAddMaterial
"
size
=
"
small
"
type
=
"
primary
"
v
-
hasPermi
=
"
['materialsmanage:add']
"
@
click
=
"
handleAddMaterial
"
>
新增材料
<
/el-butto
n
>
新增材料
<
/el-butto
n
>
>
<
el
-
button
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
showLib
"
size
=
"
small
"
type
=
"
primary
"
v
-
hasPermi
=
"
['materialsmanage:lib']
"
@
click
=
"
showLib
"
>
公共库选择
<
/el-butto
n
>
公共库选择
<
/el-butto
n
>
>
<
el
-
button
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
addFolder
"
size
=
"
small
"
type
=
"
primary
"
v
-
hasPermi
=
"
['materialsmanage:addFolder']
"
@
click
=
"
addFolder
"
>
新增文件夹
<
/el-butto
n
>
新增文件夹
<
/el-butto
n
>
>
<
el
-
button
<
el
-
button
size
=
"
small
"
type
=
"
danger
"
@
click
=
"
handleDelAll
"
size
=
"
small
"
type
=
"
danger
"
v
-
hasPermi
=
"
['materialsmanage:remove']
"
@
click
=
"
handleDelAll
"
>
批量删除
<
/el-butto
n
>
批量删除
<
/el-butto
n
>
>
<
el
-
button
<
el
-
button
size
=
"
small
"
size
=
"
small
"
v
-
if
=
"
activeDep.id
"
v
-
if
=
"
activeDep.id
"
type
=
"
primary
"
type
=
"
primary
"
v
-
hasPermi
=
"
['materialsmanage:move']
"
@
click
=
"
addMaterialsToFolder
"
@
click
=
"
addMaterialsToFolder
"
>
移动至
<
/el-butto
n
>
移动至
<
/el-butto
n
>
>
...
@@ -176,10 +159,7 @@
...
@@ -176,10 +159,7 @@
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
div
class
=
"
flex jcb
"
>
<
div
class
=
"
flex jcb
"
>
<
div
<
div
style
=
"
width: 60px
"
>
style
=
"
width: 60px
"
v
-
hasPermi
=
"
['materialsmanage:recommend']
"
>
<
span
<
span
@
click
=
"
handleRecommend(scope.row.id)
"
@
click
=
"
handleRecommend(scope.row.id)
"
v
-
if
=
"
scope.row.isRecommend == 1
"
v
-
if
=
"
scope.row.isRecommend == 1
"
...
@@ -193,10 +173,7 @@
...
@@ -193,10 +173,7 @@
>
推荐
<
/spa
n
>
推荐
<
/spa
n
>
>
<
/div
>
<
/div
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handleEdit(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['materialsmanage:edit']
"
@
click
=
"
handleEdit(scope.row)
"
>
编辑
<
/spa
n
>
编辑
<
/spa
n
>
>
<!--
<
span
<!--
<
span
...
@@ -204,16 +181,10 @@
...
@@ -204,16 +181,10 @@
@
click
=
"
addMaterialsToFolder(scope.row)
"
@
click
=
"
addMaterialsToFolder(scope.row)
"
>
移动至
<
/spa
n
>
移动至
<
/spa
n
>
-->
>
-->
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handlePreview(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['materialsmanage:preview']
"
@
click
=
"
handlePreview(scope.row)
"
>
预览
<
/spa
n
>
预览
<
/spa
n
>
>
<
span
<
span
class
=
"
delete pointer
"
@
click
=
"
handleDel(scope.row.id)
"
class
=
"
delete pointer
"
v
-
hasPermi
=
"
['materialsmanage:remove']
"
@
click
=
"
handleDel(scope.row.id)
"
>
删除
<
/spa
n
>
删除
<
/spa
n
>
>
<
/div
>
<
/div
>
...
@@ -290,7 +261,9 @@ export default {
...
@@ -290,7 +261,9 @@ export default {
}
,
}
,
data
()
{
data
()
{
return
{
return
{
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
// 样表事项表格
// 样表事项表格
sampleformMatterTable
:
{
sampleformMatterTable
:
{
loading
:
false
,
loading
:
false
,
...
...
sample-form-manager-ui/admin/src/pages/software/materials/modal/AddFolders.vue
View file @
43ff0178
...
@@ -123,12 +123,12 @@ export default {
...
@@ -123,12 +123,12 @@ export default {
},
},
// 重置
// 重置
handleRest
()
{
handleRest
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
},
},
// 关闭
// 关闭
handleClose
()
{
handleClose
()
{
this
.
loading
=
false
;
this
.
loading
=
false
;
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
Visible
=
false
;
this
.
Visible
=
false
;
},
},
},
},
...
...
sample-form-manager-ui/admin/src/pages/software/materials/modal/AddMaterials.vue
View file @
43ff0178
...
@@ -101,7 +101,9 @@ export default {
...
@@ -101,7 +101,9 @@ export default {
materiaFullName
:
""
,
// 材料全名
materiaFullName
:
""
,
// 材料全名
source
:
1
,
// 来源
source
:
1
,
// 来源
matterId
:
""
,
// 事项id
matterId
:
""
,
// 事项id
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
matterNo
:
""
,
// 事项编号
matterNo
:
""
,
// 事项编号
// fileName: "", // 附件名称
// fileName: "", // 附件名称
// fileUrl: "", // 附件地址
// fileUrl: "", // 附件地址
...
@@ -187,12 +189,12 @@ export default {
...
@@ -187,12 +189,12 @@ export default {
},
},
// 重置
// 重置
handleRest
()
{
handleRest
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
samplePathFileList
=
[];
this
.
samplePathFileList
=
[];
},
},
// 关闭
// 关闭
handleClose
()
{
handleClose
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
// this.fileUrlFileList = [];
// this.fileUrlFileList = [];
// this.templatePathFileList = [];
// this.templatePathFileList = [];
this
.
samplePathFileList
=
[];
this
.
samplePathFileList
=
[];
...
...
sample-form-manager-ui/admin/src/pages/software/materials/modal/CommonLib.vue
View file @
43ff0178
...
@@ -104,7 +104,9 @@ export default {
...
@@ -104,7 +104,9 @@ export default {
}
,
}
,
data
()
{
data
()
{
return
{
return
{
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
department
:
""
,
department
:
""
,
searchVal
:
""
,
searchVal
:
""
,
tableData
:
[],
tableData
:
[],
...
...
sample-form-manager-ui/admin/src/pages/software/matter/MatterManage.vue
View file @
43ff0178
...
@@ -6,18 +6,10 @@
...
@@ -6,18 +6,10 @@
<div
class=
"pd15 flex1 auto-scroll"
>
<div
class=
"pd15 flex1 auto-scroll"
>
<TableHeader>
<TableHeader>
<div
slot=
"left"
>
<div
slot=
"left"
>
<el-button
<el-button
size=
"small"
type=
"primary"
@
click=
"handleAddMatter"
size=
"small"
type=
"primary"
v-hasPermi=
"['basicsset:addMatter']"
@
click=
"handleAddMatter"
>
新增事项
</el-button
>
新增事项
</el-button
>
>
<el-button
<el-button
size=
"small"
type=
"danger"
@
click=
"handleDelAll"
size=
"small"
type=
"danger"
v-hasPermi=
"['basicsset:removeMatter']"
@
click=
"handleDelAll"
>
批量删除
</el-button
>
批量删除
</el-button
>
>
</div>
</div>
...
@@ -77,10 +69,7 @@
...
@@ -77,10 +69,7 @@
<!--
操作
-->
<!--
操作
-->
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
div
class
=
"
flex jcb
"
>
<
div
class
=
"
flex jcb
"
>
<
div
<
div
style
=
"
width: 60px
"
>
style
=
"
width: 60px
"
v
-
hasPermi
=
"
['basicsset:RecommendMatter']
"
>
<
span
<
span
@
click
=
"
handleRecommend(scope.row.id)
"
@
click
=
"
handleRecommend(scope.row.id)
"
v
-
if
=
"
scope.row.isRecommend == 1
"
v
-
if
=
"
scope.row.isRecommend == 1
"
...
@@ -94,16 +83,10 @@
...
@@ -94,16 +83,10 @@
>
推荐
<
/spa
n
>
推荐
<
/spa
n
>
>
<
/div
>
<
/div
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handleEdit(scope.row)
"
class
=
"
primary pointer
"
v
-
hasPermi
=
"
['basicsset:editMatter']
"
@
click
=
"
handleEdit(scope.row)
"
>
编辑
<
/spa
n
>
编辑
<
/spa
n
>
>
<
span
<
span
class
=
"
delete pointer
"
@
click
=
"
handleDel(scope.row.id)
"
class
=
"
delete pointer
"
v
-
hasPermi
=
"
['basicsset:removeMatter']
"
@
click
=
"
handleDel(scope.row.id)
"
>
删除
<
/spa
n
>
删除
<
/spa
n
>
>
<
/div
>
<
/div
>
...
@@ -125,11 +108,7 @@
...
@@ -125,11 +108,7 @@
<!--
内容
-->
<!--
内容
-->
<
TableHeader
>
<
TableHeader
>
<
div
slot
=
"
left
"
>
<
div
slot
=
"
left
"
>
<
el
-
button
<
el
-
button
size
=
"
small
"
type
=
"
primary
"
@
click
=
"
handleAllJoin
"
size
=
"
small
"
type
=
"
primary
"
v
-
hasPermi
=
"
['basicsset:join']
"
@
click
=
"
handleAllJoin
"
>
批量加入
<
/el-butto
n
>
批量加入
<
/el-butto
n
>
>
<
/div
>
<
/div
>
...
@@ -189,10 +168,7 @@
...
@@ -189,10 +168,7 @@
<
el
-
tag
size
=
"
small
"
v
-
else
>
自建事项
<
/el-tag
>
<
el
-
tag
size
=
"
small
"
v
-
else
>
自建事项
<
/el-tag
>
<
/template
>
<
/template
>
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
template
slot
=
"
action
"
slot
-
scope
=
"
scope
"
>
<
span
<
span
class
=
"
primary pointer
"
@
click
=
"
handleJoin(scope.row.id)
"
v
-
hasPermi
=
"
['basicsset:join']
"
class
=
"
primary pointer
"
@
click
=
"
handleJoin(scope.row.id)
"
>
加入
<
/spa
n
>
加入
<
/spa
n
>
>
<
/template
>
<
/template
>
...
@@ -236,7 +212,9 @@ export default {
...
@@ -236,7 +212,9 @@ export default {
}
,
}
,
data
()
{
data
()
{
return
{
return
{
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
// 样表事项表格
// 样表事项表格
sampleformMatterTable
:
{
sampleformMatterTable
:
{
loading
:
false
,
loading
:
false
,
...
...
sample-form-manager-ui/admin/src/pages/software/matter/modal/AddMatter.vue
View file @
43ff0178
...
@@ -90,7 +90,9 @@ export default {
...
@@ -90,7 +90,9 @@ export default {
deptId
:
""
,
// 部门id
deptId
:
""
,
// 部门id
deptCode
:
""
,
// 部门编号
deptCode
:
""
,
// 部门编号
matterNo
:
""
,
// 事项编号
matterNo
:
""
,
// 事项编号
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
source
:
1
,
// 1为手动添加,
source
:
1
,
// 1为手动添加,
deptName
:
""
,
deptName
:
""
,
},
},
...
@@ -148,11 +150,11 @@ export default {
...
@@ -148,11 +150,11 @@ export default {
},
},
// 重置
// 重置
handleRest
()
{
handleRest
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
},
},
// 关闭
// 关闭
handleClose
()
{
handleClose
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
Visible
=
false
;
this
.
Visible
=
false
;
},
},
handleChange
(
val
)
{
handleChange
(
val
)
{
...
...
sample-form-manager-ui/admin/src/pages/software/skinManage/SkinManage.vue
View file @
43ff0178
...
@@ -21,7 +21,6 @@
...
@@ -21,7 +21,6 @@
/>
/>
</div>
</div>
<el-button
<el-button
v-hasPermi=
"['skinmanage:use']"
size=
"small"
size=
"small"
:class=
"
{ active: v.used == 1 }"
:class=
"
{ active: v.used == 1 }"
@click="changeSkin(v)"
@click="changeSkin(v)"
...
@@ -57,7 +56,9 @@ export default {
...
@@ -57,7 +56,9 @@ export default {
},
},
data
()
{
data
()
{
return
{
return
{
siteId
:
local
.
getLocal
(
"
siteId
"
)
?
local
.
getLocal
(
"
siteId
"
)
:
""
,
siteId
:
local
.
getLocal
(
"
sampleSiteId
"
)
?
local
.
getLocal
(
"
sampleSiteId
"
)
:
""
,
skinList
:
[],
skinList
:
[],
previewImg
:
false
,
previewImg
:
false
,
previewUrl
:
""
,
previewUrl
:
""
,
...
...
sample-form-manager-ui/admin/src/pages/system/parameter/Parameter.vue
View file @
43ff0178
...
@@ -2,18 +2,10 @@
...
@@ -2,18 +2,10 @@
<div
class=
"parameter"
>
<div
class=
"parameter"
>
<TableHeader>
<TableHeader>
<div
slot=
"left"
>
<div
slot=
"left"
>
<el-button
<el-button
size=
"small"
type=
"primary"
@
click=
"handleAdd"
size=
"small"
>
新增参数
</el-button
v-hasPermi=
"['system:parameter:add']"
type=
"primary"
@
click=
"handleAdd"
>
新增
</el-button
>
>
<el-button
<el-button
size=
"small"
type=
"danger"
@
click=
"handleDelAll"
size=
"small"
type=
"danger"
v-hasPermi=
"['system:parameter:remove']"
@
click=
"handleDelAll"
>
批量移除
</el-button
>
批量移除
</el-button
>
>
</div>
</div>
...
@@ -52,16 +44,10 @@
...
@@ -52,16 +44,10 @@
<
template
slot=
"action"
slot-scope=
"scope"
>
<
template
slot=
"action"
slot-scope=
"scope"
>
<div
class=
"flex jca"
>
<div
class=
"flex jca"
>
<span
<span
class=
"primary pointer"
@
click=
"handleEdit(scope.row)"
class=
"primary pointer"
v-hasPermi=
"['system:parameter:edit']"
@
click=
"handleEdit(scope.row)"
>
编辑
</span
>
编辑
</span
>
>
<span
<span
class=
"delete pointer"
@
click=
"handleDel(scope.row.id)"
class=
"delete pointer"
v-hasPermi=
"['system:parameter:remove']"
@
click=
"handleDel(scope.row.id)"
>
删除
</span
>
删除
</span
>
>
</div>
</div>
...
...
sample-form-manager-ui/admin/src/pages/system/parameter/modal/AddParameter.vue
View file @
43ff0178
...
@@ -180,11 +180,11 @@ export default {
...
@@ -180,11 +180,11 @@ export default {
},
},
// 重置
// 重置
handleRest
()
{
handleRest
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
},
},
// 关闭
// 关闭
handleClose
()
{
handleClose
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
Visible
=
false
;
this
.
Visible
=
false
;
},
},
},
},
...
...
sample-form-manager-ui/admin/src/pages/system/task/TaskSet.vue
View file @
43ff0178
...
@@ -2,18 +2,10 @@
...
@@ -2,18 +2,10 @@
<div
class=
"task-set"
>
<div
class=
"task-set"
>
<TableHeader>
<TableHeader>
<div
slot=
"left"
>
<div
slot=
"left"
>
<el-button
<el-button
size=
"small"
type=
"primary"
@
click=
"handleAdd"
size=
"small"
>
新增任务
</el-button
type=
"primary"
v-hasPermi=
"['system:task:add']"
@
click=
"handleAdd"
>
新增
</el-button
>
>
<el-button
<el-button
size=
"small"
type=
"danger"
@
click=
"handleDelAll"
size=
"small"
type=
"danger"
v-hasPermi=
"['system:task:remove']"
@
click=
"handleDelAll"
>
批量移除
</el-button
>
批量移除
</el-button
>
>
</div>
</div>
...
@@ -57,16 +49,10 @@
...
@@ -57,16 +49,10 @@
<
template
slot=
"action"
slot-scope=
"scope"
>
<
template
slot=
"action"
slot-scope=
"scope"
>
<div
class=
"flex jca"
>
<div
class=
"flex jca"
>
<span
<span
class=
"primary pointer"
@
click=
"handleEdit(scope.row)"
class=
"primary pointer"
v-hasPermi=
"['system:task:edit']"
@
click=
"handleEdit(scope.row)"
>
编辑
</span
>
编辑
</span
>
>
<span
<span
class=
"delete pointer"
@
click=
"handleDel(scope.row.id)"
class=
"delete pointer"
v-hasPermi=
"['system:task:remove']"
@
click=
"handleDel(scope.row.id)"
>
删除
</span
>
删除
</span
>
>
</div>
</div>
...
@@ -75,8 +61,8 @@
...
@@ -75,8 +61,8 @@
</div>
</div>
<y-pagination
<y-pagination
:total=
"total"
:total=
"total"
:page
.sync
=
"page"
:page=
"page"
:pageSize
.sync
=
"size"
:pageSize=
"size"
@
change=
"getTaskList"
@
change=
"getTaskList"
></y-pagination>
></y-pagination>
<!-- 新增参数 -->
<!-- 新增参数 -->
...
...
sample-form-manager-ui/admin/src/pages/system/task/modal/AddTask.vue
View file @
43ff0178
...
@@ -225,11 +225,11 @@ export default {
...
@@ -225,11 +225,11 @@ export default {
},
},
// 重置
// 重置
handleRest
()
{
handleRest
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
},
},
// 关闭
// 关闭
handleClose
()
{
handleClose
()
{
this
.
$
resetForm
(
"
form
"
);
this
.
resetForm
(
"
form
"
);
this
.
Visible
=
false
;
this
.
Visible
=
false
;
},
},
// 切换策略
// 切换策略
...
...
sample-form-manager-ui/admin/src/router/index.js
View file @
43ff0178
...
@@ -2,7 +2,6 @@ import Vue from "vue";
...
@@ -2,7 +2,6 @@ import Vue from "vue";
import
VueRouter
from
"
vue-router
"
;
import
VueRouter
from
"
vue-router
"
;
import
Layouts
from
"
@/pages/layouts/Layouts.vue
"
;
import
Layouts
from
"
@/pages/layouts/Layouts.vue
"
;
import
store
from
"
@/store
"
;
import
store
from
"
@/store
"
;
import
{
generateRoutes
}
from
"
@/utils
"
;
// import local from "@/utils/local";
// import local from "@/utils/local";
// 解决重复点击同一个路由报错
// 解决重复点击同一个路由报错
const
originalPush
=
VueRouter
.
prototype
.
push
;
const
originalPush
=
VueRouter
.
prototype
.
push
;
...
@@ -24,117 +23,109 @@ Vue.use(VueRouter);
...
@@ -24,117 +23,109 @@ Vue.use(VueRouter);
const
routes
=
[
const
routes
=
[
{
{
path
:
"
/
"
,
path
:
"
/
"
,
name
:
"
/
"
,
component
:
Layouts
,
component
:
Layouts
,
redirect
:
"
/jump
"
,
redirect
:
"
/jump
"
,
children
:
[
children
:
[
// {
{
// path: "/basicsset",
path
:
"
/basicsset
"
,
// // name: '样表基础设置',
// name: '样表基础设置',
// hideChildrenInMenu: true,
hideChildrenInMenu
:
true
,
// component: () => import("@/pages/software/basics/BasicsSet"),
component
:
()
=>
import
(
"
@/pages/software/basics/BasicsSet
"
),
// meta: {
meta
:
{
// icon: "el-icon-setting",
icon
:
"
el-icon-setting
"
,
// title: "样表基础设置",
title
:
"
样表基础设置
"
,
// },
},
// },
},
// {
{
// path: "/mattermanage",
path
:
"
/mattermanage
"
,
// // name: "样表事项管理",
// name: "样表事项管理",
// hideChildrenInMenu: true,
hideChildrenInMenu
:
true
,
// component: () => import("@/pages/software/matter/MatterManage"),
component
:
()
=>
import
(
"
@/pages/software/matter/MatterManage
"
),
// meta: {
meta
:
{
// icon: "el-icon-document",
icon
:
"
el-icon-document
"
,
// title: "样表事项管理",
title
:
"
样表事项管理
"
,
// },
},
// },
},
// {
{
// path: "/materialsmanage",
path
:
"
/materialsmanage
"
,
// // name: '样表管理',
// name: '样表管理',
// hideChildrenInMenu: true,
hideChildrenInMenu
:
true
,
// component: () => import("@/pages/software/materials/MaterialsManage"),
component
:
()
=>
import
(
"
@/pages/software/materials/MaterialsManage
"
),
// meta: {
meta
:
{
// icon: "el-icon-files",
icon
:
"
el-icon-files
"
,
// title: "样表管理",
title
:
"
样表管理
"
,
// },
},
// },
},
// {
{
// path: "/librarymanage",
path
:
"
/librarymanage
"
,
// // name: '公共库管理',
// name: '公共库管理',
// hideChildrenInMenu: true,
hideChildrenInMenu
:
true
,
// component: () => import("@/pages/software/librarymanage/LibraryManage"),
component
:
()
=>
import
(
"
@/pages/software/librarymanage/LibraryManage
"
),
// meta: {
meta
:
{
// icon: "el-icon-refrigerator",
icon
:
"
el-icon-refrigerator
"
,
// title: "公共库管理",
title
:
"
公共库管理
"
,
// },
},
// },
},
// {
{
// path: "/skinmanage",
path
:
"
/skinmanage
"
,
// hideChildrenInMenu: true,
hideChildrenInMenu
:
true
,
// component: () => import("@/pages/software/skinManage/SkinManage"),
component
:
()
=>
import
(
"
@/pages/software/skinManage/SkinManage
"
),
// meta: {
meta
:
{
// icon: "el-icon-orange",
icon
:
"
el-icon-orange
"
,
// title: "皮肤管理",
title
:
"
皮肤管理
"
,
// },
},
// },
},
// {
// path: "/numberwritedevice",
{
// // name: '设备管理',
path
:
"
/numberwritedevice
"
,
// hideChildrenInMenu: true,
// name: '设备管理',
// component: () => import("@/pages/hardware/NumberWriteDevice"),
hideChildrenInMenu
:
true
,
// meta: {
component
:
()
=>
import
(
"
@/pages/hardware/NumberWriteDevice
"
),
// icon: "el-icon-monitor",
meta
:
{
// title: "设备管理",
icon
:
"
el-icon-monitor
"
,
// },
title
:
"
设备管理
"
,
// },
},
// {
},
// path: "/system",
// hideChildrenInMenu: true,
{
// component: () => import("@/pages/system/System.vue"),
path
:
"
/system
"
,
// redirect: "/system/parameter",
hideChildrenInMenu
:
true
,
// meta: {
component
:
()
=>
import
(
"
@/pages/system/System.vue
"
),
// icon: "el-icon-data-board",
redirect
:
"
/system/parameter
"
,
// title: "系统设置",
meta
:
{
// },
icon
:
"
el-icon-data-board
"
,
// children: [
title
:
"
系统设置
"
,
// {
},
// path: "/system/menu",
children
:
[
// component: () => import("@/pages/system/menu/Menu.vue"),
{
// meta: {
path
:
"
/system/parameter
"
,
// activeMenu: "/system",
component
:
()
=>
import
(
"
@/pages/system/parameter/Parameter.vue
"
),
// title: "菜单",
meta
:
{
// icon: "el-icon-cpu",
activeMenu
:
"
/system
"
,
// },
title
:
"
系统参数
"
,
// },
icon
:
"
el-icon-cpu
"
,
// {
},
// path: "/system/parameter",
},
// component: () => import("@/pages/system/parameter/Parameter.vue"),
{
// meta: {
path
:
"
/system/task
"
,
// activeMenu: "/system",
component
:
()
=>
import
(
"
@/pages/system/task/TaskSet.vue
"
),
// title: "系统参数",
meta
:
{
// icon: "el-icon-cpu",
activeMenu
:
"
/system
"
,
// },
title
:
"
任务信息
"
,
// },
icon
:
"
el-icon-bank-card
"
,
// {
},
// path: "/system/task",
},
// component: () => import("@/pages/system/task/TaskSet.vue"),
{
// meta: {
path
:
"
/system/systemlogs
"
,
// activeMenu: "/system",
component
:
()
=>
import
(
"
@/pages/system/systemlogs/SystemLogs.vue
"
),
// title: "任务信息",
meta
:
{
// icon: "el-icon-bank-card",
activeMenu
:
"
/system
"
,
// },
title
:
"
系统日志
"
,
// },
icon
:
"
el-icon-notebook-1
"
,
// {
},
// path: "/system/systemlogs",
},
// component: () => import("@/pages/system/systemlogs/SystemLogs.vue"),
],
// meta: {
},
// activeMenu: "/system",
// title: "系统日志",
// icon: "el-icon-notebook-1",
// },
// },
// ],
// },
],
],
},
},
{
{
...
@@ -172,8 +163,142 @@ router.beforeEach((to, from, next) => {
...
@@ -172,8 +163,142 @@ router.beforeEach((to, from, next) => {
}
}
});
});
// 动态菜单
// const dynamicRouter = [
// {
// path: "/basicsset",
// component: Layouts,
// meta: {
// icon: "el-icon-setting",
// title: "样表基础设置",
// },
// children: [
// {
// path: "",
// // name: '样表基础设置',
// component: () => import("@/pages/software/basics/BasicsSet"),
// },
// ],
// },
// {
// path: "/mattermanage",
// component: Layouts,
// meta: {
// icon: "el-icon-document",
// title: "样表事项管理",
// },
// children: [
// {
// path: "",
// name: "样表事项管理",
// component: () => import("@/pages/software/matter/MatterManage"),
// },
// ],
// },
// {
// path: "/materialsmanage",
// component: Layouts,
// meta: {
// icon: "el-icon-files",
// title: "样表管理",
// },
// children: [
// {
// path: "",
// // name: '材料管理',
// component: () => import("@/pages/software/materials/MaterialsManage"),
// },
// ],
// },
// {
// path: "/librarymanage",
// component: Layouts,
// meta: {
// icon: "el-icon-refrigerator",
// title: "公共库管理",
// },
// children: [
// {
// path: "",
// // name: '公共库管理',
// component: () => import("@/pages/software/librarymanage/LibraryManage"),
// },
// ],
// },
// {
// path: "/skinmanage",
// component: Layouts,
// meta: {
// icon: "el-icon-orange",
// title: "皮肤管理",
// },
// children: [
// {
// path: "",
// component: () => import("@/pages/software/skinManage/SkinManage"),
// },
// ],
// },
// {
// path: "/numberwritedevice",
// component: Layouts,
// meta: {
// icon: "el-icon-monitor",
// title: "数字样表设备",
// },
// children: [
// {
// path: "",
// // name: '数字样表设备',
// component: () => import("@/pages/hardware/NumberWriteDevice"),
// },
// ],
// },
// {
// path: "/system",
// component: Layouts,
// meta: {
// icon: "el-icon-data-board",
// title: "系统设置",
// },
// children: [
// {
// path: "",
// component: () => import("@/pages/system/System.vue"),
// redirect: "/system/parameter",
// children: [
// {
// path: "/system/parameter",
// component: () => import("@/pages/system/parameter/Parameter.vue"),
// meta: {
// activeMenu: "/system",
// hidden: true,
// },
// },
// {
// path: "/system/task",
// component: () => import("@/pages/system/task/TaskSet.vue"),
// meta: {
// activeMenu: "/system",
// hidden: true,
// },
// },
// {
// path: "/system/systemlogs",
// component: () => import("@/pages/system/systemlogs/SystemLogs.vue"),
// meta: {
// activeMenu: "/system",
// hidden: true,
// },
// },
// ],
// },
// ],
// },
// ];
// 过滤菜单
// 过滤菜单
export
function
menusFilter
(
arr
)
{
function
menusFilter
(
arr
)
{
let
router
=
arr
.
filter
((
v
)
=>
{
let
router
=
arr
.
filter
((
v
)
=>
{
if
(
!
v
.
hidden
)
{
if
(
!
v
.
hidden
)
{
if
(
v
.
children
)
{
if
(
v
.
children
)
{
...
@@ -186,13 +311,11 @@ export function menusFilter(arr) {
...
@@ -186,13 +311,11 @@ export function menusFilter(arr) {
}
}
// 动态菜单
// 动态菜单
export
function
calcMenu
()
{
export
function
calcMenu
()
{
let
menusList
=
store
.
getters
[
"
menusList
"
];
// dynamicRouter.forEach((v) => {
let
dynamicRouter
=
generateRoutes
(
menusList
);
// router.addRoute(v);
dynamicRouter
.
forEach
((
v
)
=>
{
// });
router
.
addRoute
(
"
/
"
,
v
);
let
menus
=
menusFilter
(
routes
[
0
].
children
);
});
store
.
commit
(
"
SET_MENUS
"
,
menus
);
let
menus
=
menusFilter
(
dynamicRouter
);
store
.
commit
(
"
SET_menus
"
,
menus
);
}
}
calcMenu
();
calcMenu
();
...
...
sample-form-manager-ui/admin/src/store/index.js
View file @
43ff0178
...
@@ -8,25 +8,17 @@ Vue.use(Vuex);
...
@@ -8,25 +8,17 @@ Vue.use(Vuex);
export
default
new
Vuex
.
Store
({
export
default
new
Vuex
.
Store
({
state
:
{
state
:
{
layout
:
"
head
"
,
//导航布局,可选 side 和 head,分别为侧边导航和顶部导航
menus
:
[],
// 菜单
token
:
""
,
token
:
""
,
siteId
:
""
,
// 站点id
siteId
:
""
,
// 站点id
deptList
:
[],
// 部门列表
deptList
:
[],
// 部门列表
sysName
:
""
,
// 系统名称
sysName
:
""
,
// 系统名称
sysLogo
:
""
,
// 系统logo
sysLogo
:
""
,
// 系统logo
path
:
""
,
// 门户跳转过来的路由
path
:
""
,
// 门户跳转过来的路由
menusList
:
[],
// 原始菜单列表
menus
:
[],
// 格式化菜单列表
routes
:
[],
// 路由列表
secondaryRoutes
:
[],
// 二级路由
barList
:
[],
// 登录返回菜单
homeData
:
{},
// 首页数据
userInfo
:
{},
// 用户信息
permissions
:
[],
// 按钮权限字符列表
},
},
getters
:
{
getters
:
{
layout
(
state
)
{
token
(
state
)
{
return
state
.
layout
;
return
state
.
token
;
},
},
siteId
(
state
)
{
siteId
(
state
)
{
return
state
.
siteId
;
return
state
.
siteId
;
...
@@ -34,67 +26,19 @@ export default new Vuex.Store({
...
@@ -34,67 +26,19 @@ export default new Vuex.Store({
deptList
(
state
)
{
deptList
(
state
)
{
return
state
.
deptList
;
return
state
.
deptList
;
},
},
userInfo
(
state
)
{
return
state
.
userInfo
;
},
token
(
state
)
{
return
state
.
token
;
},
path
(
state
)
{
path
(
state
)
{
return
state
.
path
;
return
state
.
path
;
},
},
barList
(
state
)
{
let
{
barList
}
=
state
.
homeData
;
return
barList
||
[];
},
routes
(
state
)
{
return
state
.
routes
;
},
menus
(
state
)
{
return
state
.
menus
;
},
permissions
(
state
)
{
return
state
.
permissions
;
},
menusList
(
state
)
{
return
state
.
menusList
;
},
secondaryRoutes
(
state
)
{
return
state
.
secondaryRoutes
;
},
},
},
mutations
:
{
mutations
:
{
SET_layout
(
state
,
layout
)
{
SET_MENUS
(
state
,
menus
)
{
state
.
layout
=
layout
;
},
SET_menusList
(
state
,
menusList
)
{
state
.
menusList
=
menusList
;
},
SET_routes
(
state
,
routes
)
{
state
.
routes
=
routes
;
},
SET_permissions
(
state
,
permissions
)
{
state
.
permissions
=
permissions
;
},
SET_secondaryRoutes
(
state
,
value
)
{
let
routes
=
state
.
menus
.
find
((
v
)
=>
v
.
path
==
value
);
let
secondaryRoutes
=
[];
if
(
routes
)
{
secondaryRoutes
=
routes
.
children
;
}
state
.
secondaryRoutes
=
secondaryRoutes
;
},
SET_path
(
state
,
path
)
{
state
.
path
=
path
;
},
SET_menus
(
state
,
menus
)
{
state
.
menus
=
menus
;
state
.
menus
=
menus
;
},
},
SET_
siteId
(
state
,
siteId
)
{
SET_
SITEID
(
state
,
siteId
)
{
state
.
siteId
=
siteId
;
state
.
siteId
=
siteId
;
},
},
SET_
userInfo
(
state
,
userInfo
)
{
SET_
deptList
(
state
,
deptList
)
{
state
.
userInfo
=
userInfo
;
state
.
deptList
=
deptList
;
},
},
SET_sysName
(
state
,
sysName
)
{
SET_sysName
(
state
,
sysName
)
{
state
.
sysName
=
sysName
;
state
.
sysName
=
sysName
;
...
@@ -105,23 +49,8 @@ export default new Vuex.Store({
...
@@ -105,23 +49,8 @@ export default new Vuex.Store({
SET_token
(
state
,
token
)
{
SET_token
(
state
,
token
)
{
state
.
token
=
token
;
state
.
token
=
token
;
},
},
SET_areaTree
(
state
,
areaTree
)
{
SET_path
(
state
,
path
)
{
state
.
areaTree
=
areaTree
;
state
.
path
=
path
;
},
SET_businessList
(
state
,
businessList
)
{
state
.
businessList
=
businessList
;
},
SET_deptList
(
state
,
deptList
)
{
state
.
deptList
=
deptList
;
},
SET_windowList
(
state
,
windowList
)
{
state
.
windowList
=
windowList
;
},
SET_barList
(
state
,
barList
)
{
state
.
barList
=
barList
;
},
SET_homeData
(
state
,
homeData
)
{
state
.
homeData
=
homeData
;
},
},
},
},
actions
:
{},
actions
:
{},
...
@@ -132,7 +61,7 @@ export default new Vuex.Store({
...
@@ -132,7 +61,7 @@ export default new Vuex.Store({
// storage: window.sessionStorage,
// storage: window.sessionStorage,
// }),
// }),
createPersistedState
({
createPersistedState
({
key
:
"
info
"
,
key
:
"
sample
"
,
storage
:
{
storage
:
{
getItem
:
(
key
)
=>
SessionCrypto
.
getItem
(
key
),
getItem
:
(
key
)
=>
SessionCrypto
.
getItem
(
key
),
setItem
:
(
key
,
value
)
=>
SessionCrypto
.
setItem
(
key
,
value
),
setItem
:
(
key
,
value
)
=>
SessionCrypto
.
setItem
(
key
,
value
),
...
...
sample-form-manager-ui/admin/src/utils/index.js
View file @
43ff0178
...
@@ -103,103 +103,3 @@ export function resetForm(refName) {
...
@@ -103,103 +103,3 @@ export function resetForm(refName) {
this
.
$refs
[
refName
].
resetFields
();
this
.
$refs
[
refName
].
resetFields
();
}
}
}
}
// 表格清除选中
export
function
clearSelection
(
refName
)
{
if
(
this
.
$refs
[
refName
])
{
this
.
$refs
[
refName
].
clearSelection
();
}
}
// 构建树形数据
export
function
buildTree
(
data
,
idField
=
"
id
"
,
parentIdField
=
"
parentId
"
)
{
const
idToItem
=
{};
data
.
forEach
((
item
)
=>
{
idToItem
[
item
[
idField
]]
=
{
...
item
,
childList
:
[]
};
});
const
tree
=
[];
data
.
forEach
((
item
)
=>
{
const
parentId
=
item
[
parentIdField
];
if
(
parentId
===
null
||
parentId
===
0
)
{
tree
.
push
(
idToItem
[
item
[
idField
]]);
}
else
{
const
parent
=
idToItem
[
parentId
];
if
(
parent
)
{
parent
.
childList
.
push
(
idToItem
[
item
[
idField
]]);
}
else
{
tree
.
push
(
idToItem
[
item
[
idField
]]);
}
}
});
return
tree
;
}
// 生成路由
export
const
generateRoutes
=
(
menuList
)
=>
{
let
routers
=
menuList
.
map
((
item
)
=>
{
// 构造符合要求的结构
let
path
=
item
.
url
.
charAt
(
0
)
===
"
/
"
?
item
.
url
:
"
/
"
+
item
.
url
;
let
name
=
item
.
url
.
replace
(
/^
\/
/
,
""
);
let
activeMenu
=
item
.
activeDir
?
"
/
"
+
item
.
activeDir
.
replace
(
/^
\/
/
,
""
)
:
""
;
let
component
=
item
.
component
?
item
.
component
.
replace
(
/^
\/
/
,
""
)
:
null
;
const
newItem
=
{
path
,
name
,
hidden
:
!!
item
.
visible
,
hideChildrenInMenu
:
!!
item
.
hideChildrenInMenu
,
component
:
()
=>
import
(
`@/
${
component
}
`
),
meta
:
{
title
:
item
.
name
,
icon
:
item
.
imgPath
,
keepAlive
:
!!
item
.
cache
,
activeMenu
,
},
};
// 递归处理子节点
if
(
item
.
children
&&
item
.
children
.
length
>
0
)
{
newItem
.
children
=
generateRoutes
(
item
.
children
);
// 如果存在子路由,默认重定向到第一个不是在菜单栏隐藏的子路由
let
firstChild
=
newItem
.
children
.
find
((
v
)
=>
!
v
.
hidden
);
if
(
firstChild
)
{
newItem
.
redirect
=
firstChild
.
path
;
}
}
return
newItem
;
});
return
routers
;
};
/**
* 过滤菜单按钮项并提取 menuType = 2 的项
* @param {Array} menuList - 菜单列表
* @param {Boolean} menuType - true 获取 menuType = 2 的项并返回为一维数组, false 剔除 menuType = 2 的项
* @param {Array} btnItems - 用于存储 menuType = 2 的项(递归使用)
* @returns {Array} - 返回提取到的 menuType = 2 的项(如果 menuType 为 true)或剔除 menuType = 2 的菜单
*/
export
const
filterBtn
=
(
menuList
,
menuType
=
true
,
btnItems
=
[])
=>
{
const
result
=
menuList
.
map
((
menu
)
=>
{
// 深拷贝对象,避免修改原数据
const
newMenu
=
{
...
menu
};
if
(
newMenu
.
children
&&
newMenu
.
children
.
length
>
0
)
{
newMenu
.
children
=
filterBtn
(
newMenu
.
children
,
menuType
,
btnItems
);
}
const
btnItem
=
newMenu
.
menuType
==
2
;
if
(
menuType
)
{
if
(
btnItem
)
{
btnItems
.
push
(
newMenu
);
}
return
newMenu
;
}
else
{
// 剔除 menuType = 2 的项
return
!
btnItem
?
newMenu
:
null
;
}
})
.
filter
((
menu
)
=>
menu
!==
null
);
// 过滤掉 null 项
return
menuType
?
btnItems
:
result
;
};
sample-form-manager-ui/admin/yarn.lock
View file @
43ff0178
...
@@ -931,13 +931,6 @@
...
@@ -931,13 +931,6 @@
dependencies:
dependencies:
regenerator-runtime "^0.13.4"
regenerator-runtime "^0.13.4"
"@babel/runtime@^7.3.1":
version "7.27.0"
resolved "https://registry.npmmirror.com/@babel/runtime/-/runtime-7.27.0.tgz#fbee7cf97c709518ecc1f590984481d5460d4762"
integrity sha512-VtPOkrdPHZsKc/clNqyi9WUA8TINkZ4cGk63UUE3u4pmB2k+ZMQRDuIOagv8UVd6j7k0T3+RRIb7beKTebNbcw==
dependencies:
regenerator-runtime "^0.14.0"
"@babel/template@^7.0.0", "@babel/template@^7.18.10":
"@babel/template@^7.0.0", "@babel/template@^7.18.10":
version "7.18.10"
version "7.18.10"
resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.10.tgz#6f9134835970d1dbf0835c0d100c9f38de0c5e71"
resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.10.tgz#6f9134835970d1dbf0835c0d100c9f38de0c5e71"
...
@@ -1115,20 +1108,6 @@
...
@@ -1115,20 +1108,6 @@
resolved "https://registry.yarnpkg.com/@polka/url/-/url-1.0.0-next.21.tgz#5de5a2385a35309427f6011992b544514d559aa1"
resolved "https://registry.yarnpkg.com/@polka/url/-/url-1.0.0-next.21.tgz#5de5a2385a35309427f6011992b544514d559aa1"
integrity sha512-a5Sab1C4/icpTZVzZc5Ghpz88yQtGOyNqYXcZgOssB2uuAr+wF/MvN6bgtW32q7HHrvBki+BsZ0OuNv6EV3K9g==
integrity sha512-a5Sab1C4/icpTZVzZc5Ghpz88yQtGOyNqYXcZgOssB2uuAr+wF/MvN6bgtW32q7HHrvBki+BsZ0OuNv6EV3K9g==
"@riophae/vue-treeselect@^0.4.0":
version "0.4.0"
resolved "https://registry.npmmirror.com/@riophae/vue-treeselect/-/vue-treeselect-0.4.0.tgz#0baed5a794cffc580b63591f35c125e51c0df241"
integrity sha512-J4atYmBqXQmiPFK/0B5sXKjtnGc21mBJEiyKIDZwk0Q9XuynVFX6IJ4EpaLmUgL5Tve7HAS7wkiGGSti6Uaxcg==
dependencies:
"@babel/runtime" "^7.3.1"
babel-helper-vue-jsx-merge-props "^2.0.3"
easings-css "^1.0.0"
fuzzysearch "^1.0.3"
is-promise "^2.1.0"
lodash "^4.0.0"
material-colors "^1.2.6"
watch-size "^2.0.0"
"@sideway/address@^4.1.3":
"@sideway/address@^4.1.3":
version "4.1.4"
version "4.1.4"
resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0"
resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0"
...
@@ -2102,7 +2081,7 @@ axios@^0.27.2:
...
@@ -2102,7 +2081,7 @@ axios@^0.27.2:
follow-redirects "^1.14.9"
follow-redirects "^1.14.9"
form-data "^4.0.0"
form-data "^4.0.0"
babel-helper-vue-jsx-merge-props@^2.0.0
, babel-helper-vue-jsx-merge-props@^2.0.3
:
babel-helper-vue-jsx-merge-props@^2.0.0:
version "2.0.3"
version "2.0.3"
resolved "https://registry.npmmirror.com/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-2.0.3.tgz#22aebd3b33902328e513293a8e4992b384f9f1b6"
resolved "https://registry.npmmirror.com/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-2.0.3.tgz#22aebd3b33902328e513293a8e4992b384f9f1b6"
integrity sha512-gsLiKK7Qrb7zYJNgiXKpXblxbV5ffSwR0f5whkPAaBAR4fhi6bwRZxX9wBlIc5M/v8CCkXUbXZL4N/nSE97cqg==
integrity sha512-gsLiKK7Qrb7zYJNgiXKpXblxbV5ffSwR0f5whkPAaBAR4fhi6bwRZxX9wBlIc5M/v8CCkXUbXZL4N/nSE97cqg==
...
@@ -3535,11 +3514,6 @@ duplexify@^3.4.2, duplexify@^3.6.0:
...
@@ -3535,11 +3514,6 @@ duplexify@^3.4.2, duplexify@^3.6.0:
readable-stream "^2.0.0"
readable-stream "^2.0.0"
stream-shift "^1.0.0"
stream-shift "^1.0.0"
easings-css@^1.0.0:
version "1.0.0"
resolved "https://registry.npmmirror.com/easings-css/-/easings-css-1.0.0.tgz#dde569003bb7a4a0c0b77878f5db3e0be5679c81"
integrity sha512-7Uq7NdazNfVtr0RNmPAys8it0zKCuaqxJStYKEl72D3j4gbvXhhaM7iWNbqhA4C94ygCye6VuyhzBRQC4szeBg==
easy-stack@1.0.1:
easy-stack@1.0.1:
version "1.0.1"
version "1.0.1"
resolved "https://registry.yarnpkg.com/easy-stack/-/easy-stack-1.0.1.tgz#8afe4264626988cabb11f3c704ccd0c835411066"
resolved "https://registry.yarnpkg.com/easy-stack/-/easy-stack-1.0.1.tgz#8afe4264626988cabb11f3c704ccd0c835411066"
...
@@ -3576,10 +3550,10 @@ element-china-area-data@^5.0.2:
...
@@ -3576,10 +3550,10 @@ element-china-area-data@^5.0.2:
china-area-data "^5.0.1"
china-area-data "^5.0.1"
lodash-es "^4.17.15"
lodash-es "^4.17.15"
element-ui@^2.15.1
4
:
element-ui@^2.15.1
0
:
version "2.15.1
4
"
version "2.15.1
0
"
resolved "https://registry.npmmirror.com/element-ui/-/element-ui-2.15.1
4.tgz#3c34df79467636592812d720d2e6784e7a6ec2ea
"
resolved "https://registry.npmmirror.com/element-ui/-/element-ui-2.15.1
0.tgz#fde0ff5cb4c30e8eb166d617f85916defe5948f1
"
integrity sha512-
2v9fHL0ZGINotOlRIAJD5YuVB8V7WKxrE9Qy7dXhRipa035+kF7WuU/z+tEmLVPBcJ0zt8mOu1DKpWcVzBK8IA
==
integrity sha512-
jmD++mU2wKXbisvx4fxOl2mHaU+HWHTAq/3Wf8x9Bwyu4GdDZPLABb+CGi3DWN6fPqdgRcd74aX39DO+YHObLw
==
dependencies:
dependencies:
async-validator "~1.8.1"
async-validator "~1.8.1"
babel-helper-vue-jsx-merge-props "^2.0.0"
babel-helper-vue-jsx-merge-props "^2.0.0"
...
@@ -4411,11 +4385,6 @@ functions-have-names@^1.2.2:
...
@@ -4411,11 +4385,6 @@ functions-have-names@^1.2.2:
resolved "https://registry.npmmirror.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834"
resolved "https://registry.npmmirror.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834"
integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==
integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==
fuzzysearch@^1.0.3:
version "1.0.3"
resolved "https://registry.npmmirror.com/fuzzysearch/-/fuzzysearch-1.0.3.tgz#dffc80f6d6b04223f2226aa79dd194231096d008"
integrity sha512-s+kNWQuI3mo9OALw0HJ6YGmMbLqEufCh2nX/zzV5CrICQ/y4AwPxM+6TIiF9ItFCHXFCyM/BfCCmN57NTIJuPg==
gauge@~2.7.3:
gauge@~2.7.3:
version "2.7.4"
version "2.7.4"
resolved "https://registry.npmmirror.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7"
resolved "https://registry.npmmirror.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7"
...
@@ -5333,11 +5302,6 @@ is-plain-object@^2.0.3, is-plain-object@^2.0.4:
...
@@ -5333,11 +5302,6 @@ is-plain-object@^2.0.3, is-plain-object@^2.0.4:
dependencies:
dependencies:
isobject "^3.0.1"
isobject "^3.0.1"
is-promise@^2.1.0:
version "2.2.2"
resolved "https://registry.npmmirror.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1"
integrity sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==
is-redirect@^1.0.0:
is-redirect@^1.0.0:
version "1.0.0"
version "1.0.0"
resolved "https://registry.npmmirror.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24"
resolved "https://registry.npmmirror.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24"
...
@@ -6005,7 +5969,7 @@ lodash.without@~4.4.0:
...
@@ -6005,7 +5969,7 @@ lodash.without@~4.4.0:
resolved "https://registry.npmmirror.com/lodash.without/-/lodash.without-4.4.0.tgz#3cd4574a00b67bae373a94b748772640507b7aac"
resolved "https://registry.npmmirror.com/lodash.without/-/lodash.without-4.4.0.tgz#3cd4574a00b67bae373a94b748772640507b7aac"
integrity sha512-M3MefBwfDhgKgINVuBJCO1YR3+gf6s9HNJsIiZ/Ru77Ws6uTb9eBuvrkpzO+9iLoAaRodGuq7tyrPCx+74QYGQ==
integrity sha512-M3MefBwfDhgKgINVuBJCO1YR3+gf6s9HNJsIiZ/Ru77Ws6uTb9eBuvrkpzO+9iLoAaRodGuq7tyrPCx+74QYGQ==
lodash@^4.
0.0, lodash@^4.
17.14, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.17.3:
lodash@^4.17.14, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.17.3:
version "4.17.21"
version "4.17.21"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c"
integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==
integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==
...
@@ -6122,11 +6086,6 @@ map-visit@^1.0.0:
...
@@ -6122,11 +6086,6 @@ map-visit@^1.0.0:
dependencies:
dependencies:
object-visit "^1.0.0"
object-visit "^1.0.0"
material-colors@^1.2.6:
version "1.2.6"
resolved "https://registry.npmmirror.com/material-colors/-/material-colors-1.2.6.tgz#6d1958871126992ceecc72f4bcc4d8f010865f46"
integrity sha512-6qE4B9deFBIa9YSpOc9O0Sgc43zTeVYbgDT5veRKSlB2+ZuHNoVVxA1L/ckMUayV9Ay9y7Z/SZCLcGteW9i7bg==
mdn-data@2.0.14:
mdn-data@2.0.14:
version "2.0.14"
version "2.0.14"
resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.14.tgz#7113fc4281917d63ce29b43446f701e68c25ba50"
resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.14.tgz#7113fc4281917d63ce29b43446f701e68c25ba50"
...
@@ -8031,11 +7990,6 @@ regenerator-runtime@^0.13.4:
...
@@ -8031,11 +7990,6 @@ regenerator-runtime@^0.13.4:
resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz#8925742a98ffd90814988d7566ad30ca3b263b52"
resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.9.tgz#8925742a98ffd90814988d7566ad30ca3b263b52"
integrity sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==
integrity sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==
regenerator-runtime@^0.14.0:
version "0.14.1"
resolved "https://registry.npmmirror.com/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz#356ade10263f685dda125100cd862c1db895327f"
integrity sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==
regenerator-transform@^0.15.0:
regenerator-transform@^0.15.0:
version "0.15.0"
version "0.15.0"
resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.15.0.tgz#cbd9ead5d77fae1a48d957cf889ad0586adb6537"
resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.15.0.tgz#cbd9ead5d77fae1a48d957cf889ad0586adb6537"
...
@@ -9685,11 +9639,6 @@ vuex@^3.6.2:
...
@@ -9685,11 +9639,6 @@ vuex@^3.6.2:
resolved "https://registry.yarnpkg.com/vuex/-/vuex-3.6.2.tgz#236bc086a870c3ae79946f107f16de59d5895e71"
resolved "https://registry.yarnpkg.com/vuex/-/vuex-3.6.2.tgz#236bc086a870c3ae79946f107f16de59d5895e71"
integrity sha512-ETW44IqCgBpVomy520DT5jf8n0zoCac+sxWnn+hMe/CzaSejb/eVw2YToiXYX+Ex/AuHHia28vWTq4goAexFbw==
integrity sha512-ETW44IqCgBpVomy520DT5jf8n0zoCac+sxWnn+hMe/CzaSejb/eVw2YToiXYX+Ex/AuHHia28vWTq4goAexFbw==
watch-size@^2.0.0:
version "2.0.0"
resolved "https://registry.npmmirror.com/watch-size/-/watch-size-2.0.0.tgz#096ee28d0365bd7ea03d9c8bf1f2f50a73be1474"
integrity sha512-M92R89dNoTPWyCD+HuUEDdhaDnh9jxPGOwlDc0u51jAgmjUvzqaEMynXSr3BaWs+QdHYk4KzibPy1TFtjLmOZQ==
watchpack@^2.4.0:
watchpack@^2.4.0:
version "2.4.0"
version "2.4.0"
resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d"
resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.0.tgz#fa33032374962c78113f93c7f2fb4c54c9862a5d"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment