hd-idevvue3 3.0.0 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +22 -191
- package/dist/index.html +17 -0
- package/package.json +13 -9
- package/pnpm-lock.yaml +5593 -0
- package/src/App.vue +15 -0
- package/src/assets/sound/notify.wav +0 -0
- package/src/demo/demo.vue +43 -0
- package/src/demo/dropdemo.vue +43 -0
- package/src/demo/extsets.vue +107 -0
- package/src/demo/formedit.vue +145 -0
- package/src/demo/hightquery.vue +169 -0
- package/src/demo/inlineedit.vue +88 -0
- package/src/demo/selfdrop.vue +41 -0
- package/src/demo//350/241/214/345/206/205/347/272/247/350/201/224.txt +2 -0
- package/src/directive/el-dragDialog/drag.js +124 -0
- package/src/directive/el-dragDialog/index.js +13 -0
- package/src/errorLog.js +14 -0
- package/src/hdcom/BigGrid.js +173 -0
- package/src/hdcom/BillShow.vue +90 -0
- package/src/hdcom/BillUpload.vue +253 -0
- package/src/hdcom/BtnRight.vue +98 -0
- package/src/hdcom/ErrHint.vue +30 -0
- package/src/hdcom/ExtendColumn.vue +108 -0
- package/src/hdcom/ExtendCommon.js +29 -0
- package/src/hdcom/ExtendForm.vue +114 -0
- package/src/hdcom/FacePicUpload.vue +71 -0
- package/src/hdcom/FaceRecTest.vue +104 -0
- package/src/hdcom/GridChart.vue +194 -0
- package/src/hdcom/GridExField.vue +281 -0
- package/src/hdcom/GridShow.vue +238 -0
- package/src/hdcom/HdAside.vue +178 -0
- package/src/hdcom/HdBtn.vue +113 -0
- package/src/hdcom/HdButton.vue +137 -0
- package/src/hdcom/HdComFaceRec.vue +58 -0
- package/src/hdcom/HdComGrid.vue +776 -0
- package/src/hdcom/HdComQuery.vue +273 -0
- package/src/hdcom/HdComQueryDetail.vue +161 -0
- package/src/hdcom/HdComSortDetail.vue +155 -0
- package/src/hdcom/HdDatePicker.vue +78 -0
- package/src/hdcom/HdDialog.vue +63 -0
- package/src/hdcom/HdDrop.vue +163 -0
- package/src/hdcom/HdFileUpload.vue +148 -0
- package/src/hdcom/HdFilterBox.vue +90 -0
- package/src/hdcom/HdFooter.vue +149 -0
- package/src/hdcom/HdForm.vue +278 -0
- package/src/hdcom/HdFormBtn.vue +89 -0
- package/src/hdcom/HdFormItem.vue +35 -0
- package/src/hdcom/HdGctosGrid +0 -0
- package/src/hdcom/HdGrid.vue +825 -0
- package/src/hdcom/HdGridEditBtn.vue +44 -0
- package/src/hdcom/HdGridExt.js +219 -0
- package/src/hdcom/HdGridSel.vue +223 -0
- package/src/hdcom/HdHeader.vue +148 -0
- package/src/hdcom/HdHotKey.vue +81 -0
- package/src/hdcom/HdInputHint.vue +49 -0
- package/src/hdcom/HdMain.vue +43 -0
- package/src/hdcom/HdMessage.vue +192 -0
- package/src/hdcom/HdNum.vue +69 -0
- package/src/hdcom/HdPopSel.vue +58 -0
- package/src/hdcom/HdRightMenu.vue +61 -0
- package/src/hdcom/HdSel/SelGridFieldcod.vue +36 -0
- package/src/hdcom/HdTableColumn.vue +334 -0
- package/src/hdcom/HdTempSave.vue +140 -0
- package/src/hdcom/HdTree.vue +86 -0
- package/src/hdcom/HdTreeTable/eval.js +32 -0
- package/src/hdcom/HdTreeTable/index.vue +174 -0
- package/src/hdcom/ImportExcel.vue +143 -0
- package/src/hdcom/PdfShow.vue +266 -0
- package/src/hdcom/index.js +80 -0
- package/src/idev.common.js +72 -0
- package/src/index.js +13 -0
- package/src/utils/HdQuery.js +54 -0
- package/src/utils/comutils.js +98 -0
- package/src/utils/utils.js +105 -0
- package/src/vendor/Blob.js +179 -0
- package/src/vendor/Export2Excel.js +220 -0
- package/src/vendor/Export2Zip.js +22 -0
- package/src/views/layout/AppMain.vue +32 -0
- package/src/views/layout/HdLayout.vue +78 -0
- package/src/views/layout/header/ElasticSearch.vue +225 -0
- package/src/views/layout/header/HZRecorder.js +231 -0
- package/src/views/layout/header/HeaderSearch.vue +198 -0
- package/src/views/layout/header/Levelbar.vue +49 -0
- package/src/views/layout/header/MainHeader.vue +271 -0
- package/src/views/layout/header/Navbar.vue +105 -0
- package/src/views/layout/header/ScrollPane.vue +81 -0
- package/src/views/layout/header/TagsView.vue +210 -0
- package/src/views/layout/header/VocRec.vue +97 -0
- package/src/views/layout/header/changepswform.vue +96 -0
- package/src/views/layout/index.js +12 -0
- package/src/views/layout/menu/Hamburger.vue +45 -0
- package/src/views/layout/menu/HdMenu.vue +167 -0
- package/src/views/layout/menu/css/menu.css +288 -0
- package/src/views/layout/menu/index.vue +25 -0
- package/src/views/privilege/commsg/commsg.vue +78 -0
- package/src/views/privilege/commsg/commsgOrgn.vue +42 -0
- package/src/views/privilege/commsg/commsgRole.vue +149 -0
- package/src/views/privilege/commsg/commsgform.vue +160 -0
- package/src/views/privilege/commsg/commsgiframe.vue +33 -0
- package/src/views/privilege/commsg/commsgto.vue +120 -0
- package/src/views/privilege/commsg/commsgtoform.vue +108 -0
- package/src/views/privilege/commsg/commsgtrans.vue +155 -0
- package/src/views/privilege/exfield/comexcolumn.vue +71 -0
- package/src/views/privilege/exfield/comexcolumnform.vue +101 -0
- package/src/views/privilege/exfield/comexfield.vue +31 -0
- package/src/views/privilege/exfield/comexfieldform.vue +94 -0
- package/src/views/privilege/exfield/comexfieldsub.vue +72 -0
- package/src/views/privilege/index.js +42 -0
- package/src/views/privilege/menu/comMenu.vue +41 -0
- package/src/views/privilege/menu/menu.vue +133 -0
- package/src/views/privilege/menu/menuinfo.vue +56 -0
- package/src/views/privilege/menu/rolelist.vue +47 -0
- package/src/views/privilege/menu/userlist.vue +49 -0
- package/src/views/privilege/mobile/authmobileupdate.vue +69 -0
- package/src/views/privilege/mobile/authmobileupdateform.vue +90 -0
- package/src/views/privilege/orgDept/authOrgn.vue +96 -0
- package/src/views/privilege/orgDept/authorgnform.vue +145 -0
- package/src/views/privilege/orgDept/orgDept.vue +37 -0
- package/src/views/privilege/orgDept/orgTree.vue +88 -0
- package/src/views/privilege/orgDept/orgnselect.vue +134 -0
- package/src/views/privilege/personDept/authuser.vue +123 -0
- package/src/views/privilege/personDept/authuserform.vue +154 -0
- package/src/views/privilege/personDept/facerec.vue +117 -0
- package/src/views/privilege/personDept/orgncascader.vue +125 -0
- package/src/views/privilege/personDept/personDept.vue +31 -0
- package/src/views/privilege/quartz/comquartzjob.vue +65 -0
- package/src/views/privilege/quartz/comquartzjobform.vue +99 -0
- package/src/views/privilege/quartz/comquartzlog.vue +59 -0
- package/src/views/privilege/role/btnRole.vue +117 -0
- package/src/views/privilege/role/menuRole.vue +64 -0
- package/src/views/privilege/role/orgnRole.vue +56 -0
- package/src/views/privilege/role/role.vue +67 -0
- package/src/views/privilege/role/rolelist.vue +67 -0
- package/src/views/privilege/role/roleselect.vue +57 -0
- package/src/views/privilege/search/comsearch.vue +105 -0
- package/src/views/privilege/search/menu.vue +52 -0
- package/src/views/privilege/syscode/syscode.vue +103 -0
- package/src/views/privilege/syscode/sysfield.vue +66 -0
- package/src/views/privilege/syscode/sysfieldframe.vue +30 -0
- package/src/views/privilege/syslog/menulog.vue +52 -0
- package/src/views/privilege/syslog/syslog.vue +115 -0
- package/src/views/privilege/syslog/syslogconfig.vue +61 -0
- package/src/views/privilege/syslog/syslogform.vue +83 -0
- package/src/views/privilege/syslog/syslogframe.vue +26 -0
- package/src/views/privilege/userRole/userRole.vue +122 -0
- package/src/views/privilege.zip +0 -0
- package/vite.config.js +118 -0
- package/.babelrc +0 -17
- package/.editorconfig +0 -14
- package/.eslintignore +0 -3
- package/.npminstall.done +0 -1
- package/.postcssrc.js +0 -8
- package/LICENSE +0 -21
- package/Listening +0 -28
- package/build/build.js +0 -70
- package/build/check-versions.js +0 -45
- package/build/config.js +0 -81
- package/build/dev-client.js +0 -9
- package/build/dev-server.js +0 -93
- package/build/utils.js +0 -78
- package/build/vue-loader.conf.js +0 -12
- package/build/webpack.common.js +0 -37
- package/build/webpack.component.js +0 -36
- package/build/webpack.prod.conf.js +0 -38
- package/components.json +0 -8
- package/conf.js +0 -42
- package/config/dev.env.js +0 -6
- package/config/index.js +0 -43
- package/config/prod.env.js +0 -6
- package/config/sit.env.js +0 -6
- package/favicon.ico +0 -0
- package/jsdoc-vue.js +0 -12
- package/lib/0.index.js +0 -12573
- package/lib/1.index.js +0 -6
- package/lib/2.index.js +0 -2
- package/lib/idev.common.js +0 -1
- package/lib/idv8.common.js +0 -1
- package/lib/index.js +0 -49170
- package/lib/js/ErrHint.js +0 -1
- package/lib/js/HdAside.js +0 -1
- package/lib/js/HdBtn.js +0 -1
- package/lib/js/HdButton.js +0 -1
- package/lib/js/HdComFaceRec.js +0 -1
- package/lib/js/HdComGrid.js +0 -1
- package/lib/js/HdDatePicker.js +0 -1
- package/lib/js/HdDialog.js +0 -1
- package/lib/js/HdDrop.js +0 -1
- package/lib/js/HdFileUpload.js +0 -1
- package/lib/js/HdFooter.js +0 -1
- package/lib/js/HdForm.js +0 -1
- package/lib/js/HdFormBtn.js +0 -1
- package/lib/js/HdFormItem.js +0 -1
- package/lib/js/HdGrid.js +0 -1
- package/lib/js/HdGridEditBtn.js +0 -1
- package/lib/js/HdGridSel.js +0 -1
- package/lib/js/HdHeader.js +0 -1
- package/lib/js/HdHotkey.js +0 -1
- package/lib/js/HdLayout.js +0 -1
- package/lib/js/HdMain.js +0 -1
- package/lib/js/HdMessage.js +0 -1
- package/lib/js/HdNum.js +0 -1
- package/lib/js/HdPopSel.js +0 -1
- package/lib/js/HdSearch.js +0 -1
- package/lib/js/HdTableColumn.js +0 -1
- package/lib/js/HdTempSave.js +0 -1
- package/lib/js/HdTree.js +0 -1
- package/lib/js/HdTreeTable.js +0 -1
- package/lib/js/authmobileupdate.js +0 -1
- package/lib/js/comexfield.js +0 -1
- package/lib/js/commsg.js +0 -1
- package/lib/js/commsgto.js +0 -1
- package/lib/js/comquartzjob.js +0 -1
- package/lib/js/comquartzlog.js +0 -1
- package/lib/js/comsearch.js +0 -1
- package/lib/js/menu.js +0 -1
- package/lib/js/menuinfo.js +0 -1
- package/lib/js/orgDept.js +0 -1
- package/lib/js/orgTree.js +0 -1
- package/lib/js/personDept.js +0 -1
- package/lib/js/role.js +0 -1
- package/lib/js/sysfieldframe.js +0 -1
- package/lib/js/syslog.js +0 -1
- package/lib/js/syslogframe.js +0 -1
- package/lib/js/userRole.js +0 -1
- package/npminstall-debug.log +0 -200
- package/ytgvue.rar +0 -0
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<div class="headerLogo"></div>
|
|
4
|
+
<div class="headerIcon">
|
|
5
|
+
<a @click="logout" class="headerIconLink5" href="javascript:void(0)"><!--退出--></a>
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
<el-dropdown class="avatar-container right-menu-item" style="float: right" trigger="click">
|
|
9
|
+
<a class="headerIconLink7" href="javascript:void(0)">
|
|
10
|
+
<el-badge :hidden="$store.state.user.messageNum==0" :max="99" :value="$store.state.user.messageNum"
|
|
11
|
+
style="float: left;"></el-badge>
|
|
12
|
+
<!--<el-badge :value="$store.state.user.messageNum" :hidden="$store.state.user.messageNum==0" :max="99">-->
|
|
13
|
+
<div class="avatar-wrapper" style="float: left;">
|
|
14
|
+
<span class="headerIconFontColor"> {{name}}</span>
|
|
15
|
+
</div>
|
|
16
|
+
</a>
|
|
17
|
+
|
|
18
|
+
<el-dropdown-menu slot="dropdown">
|
|
19
|
+
<router-link to="/">
|
|
20
|
+
<el-dropdown-item>
|
|
21
|
+
{{$t('首页')}}
|
|
22
|
+
</el-dropdown-item>
|
|
23
|
+
</router-link>
|
|
24
|
+
<el-dropdown-item>
|
|
25
|
+
<span @click="changePsw" style="display:block;"> {{$t('修改密码')}}</span>
|
|
26
|
+
</el-dropdown-item>
|
|
27
|
+
<el-dropdown-item>
|
|
28
|
+
<span @click="editBoard" style="display:block;"> {{$t('修改首页')}}</span>
|
|
29
|
+
</el-dropdown-item>
|
|
30
|
+
<el-dropdown-item>
|
|
31
|
+
|
|
32
|
+
<span @click="showMessage" style="display:block;">
|
|
33
|
+
{{$t('查看消息')}}
|
|
34
|
+
<el-badge :hidden="$store.state.user.messageNum==0" :max="99"
|
|
35
|
+
:value="$store.state.user.messageNum" style="margin-top: -5px" type="warning"/>
|
|
36
|
+
</span>
|
|
37
|
+
|
|
38
|
+
</el-dropdown-item>
|
|
39
|
+
|
|
40
|
+
<!--<el-dropdown-item>
|
|
41
|
+
<span @click="chgLanguage" style="display:block;">{{nextLanguage}}</span>
|
|
42
|
+
</el-dropdown-item>-->
|
|
43
|
+
</el-dropdown-menu>
|
|
44
|
+
</el-dropdown>
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
<el-dropdown class="avatar-container right-menu-item" style="float: right" trigger="click">
|
|
48
|
+
<a class="headerIconLink3" href="javascript:void(0)">
|
|
49
|
+
<div class="avatar-wrapper">
|
|
50
|
+
<i class="el-icon-caret-bottom headerIconFontColor"></i>
|
|
51
|
+
</div>
|
|
52
|
+
</a>
|
|
53
|
+
<el-dropdown-menu slot="dropdown">
|
|
54
|
+
<el-dropdown-item>
|
|
55
|
+
<span @click="changeStyle('metro-orange')" style="display:block;"> {{$t('橙色')}}</span>
|
|
56
|
+
</el-dropdown-item>
|
|
57
|
+
<el-dropdown-item>
|
|
58
|
+
|
|
59
|
+
<span @click="changeStyle('metro-green')" style="display:block;"> {{$t('绿色')}}</span>
|
|
60
|
+
</el-dropdown-item>
|
|
61
|
+
<el-dropdown-item>
|
|
62
|
+
<span @click="changeStyle('metro-mauves')" style="display:block;"> {{$t('紫色')}}</span>
|
|
63
|
+
</el-dropdown-item>
|
|
64
|
+
<el-dropdown-item>
|
|
65
|
+
<span @click="changeStyle('metro-blue')" style="display:block;"> {{$t('蓝色')}}</span>
|
|
66
|
+
</el-dropdown-item>
|
|
67
|
+
</el-dropdown-menu>
|
|
68
|
+
</el-dropdown>
|
|
69
|
+
|
|
70
|
+
<el-dropdown class="avatar-container right-menu-item" style="float: right" trigger="hover">
|
|
71
|
+
<a :class="colorStyle" href="javascript:void(0)">
|
|
72
|
+
<div class="avatar-wrapper">
|
|
73
|
+
<i class="el-icon-caret-bottom headerIconFontColor"></i>
|
|
74
|
+
</div>
|
|
75
|
+
</a>
|
|
76
|
+
<el-dropdown-menu slot="dropdown">
|
|
77
|
+
<el-dropdown-item>
|
|
78
|
+
<span @click="changeLanguage('zh')" style="display:block;">中文</span>
|
|
79
|
+
<!--<span @click="chgLanguage" style="display:block;">{{nextLanguage}}</span>-->
|
|
80
|
+
</el-dropdown-item>
|
|
81
|
+
<el-dropdown-item>
|
|
82
|
+
<span @click="changeLanguage('en')" style="display:block;">English</span>
|
|
83
|
+
</el-dropdown-item>
|
|
84
|
+
</el-dropdown-menu>
|
|
85
|
+
</el-dropdown>
|
|
86
|
+
|
|
87
|
+
<div class="avatar-container right-menu-item" style="float: right" trigger="click">
|
|
88
|
+
<a class="mike" href="javascript:void(0)">
|
|
89
|
+
<div @shortkey="vocHotKey" v-shortkey.push="['ctrl','`']">
|
|
90
|
+
</div>
|
|
91
|
+
</a>
|
|
92
|
+
</div>
|
|
93
|
+
|
|
94
|
+
<search class="avatar-container right-menu-item" style="float: right"></search>
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
<changepswform ref="changepswform"></changepswform>
|
|
98
|
+
</div>
|
|
99
|
+
</div>
|
|
100
|
+
</template>
|
|
101
|
+
|
|
102
|
+
<script>
|
|
103
|
+
import {mapGetters} from 'vuex'
|
|
104
|
+
import search from './ElasticSearch'
|
|
105
|
+
import changepswform from './changepswform'
|
|
106
|
+
import VocRec from './VocRec'
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
export default {
|
|
110
|
+
name: 'mainHeader',
|
|
111
|
+
mixins: [VocRec],
|
|
112
|
+
components: {
|
|
113
|
+
changepswform,
|
|
114
|
+
search
|
|
115
|
+
},
|
|
116
|
+
data() {
|
|
117
|
+
return {
|
|
118
|
+
show: false,
|
|
119
|
+
params: {
|
|
120
|
+
entityId: this.$store.getters.token,
|
|
121
|
+
entityName: 'avatar'
|
|
122
|
+
},
|
|
123
|
+
headers: {
|
|
124
|
+
smail: '*_~'
|
|
125
|
+
},
|
|
126
|
+
imgDataUrl: '', // the datebase64 url of created image
|
|
127
|
+
style: this.$store.state.user.skin,
|
|
128
|
+
//log: errLogStore.state.errLog
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
mounted() {
|
|
132
|
+
//this.screenShotFn = screenShot([16, 65], 27);
|
|
133
|
+
if (this.$store.state.user.nextChgId == "1") {
|
|
134
|
+
this.changePsw();
|
|
135
|
+
}
|
|
136
|
+
this.$i18n.locale = this.$store.state.user.language || 'zh';
|
|
137
|
+
this.placeholderChg()
|
|
138
|
+
},
|
|
139
|
+
computed: {
|
|
140
|
+
...mapGetters([
|
|
141
|
+
'sidebar',
|
|
142
|
+
'name',
|
|
143
|
+
'avatar',
|
|
144
|
+
'language'
|
|
145
|
+
]),
|
|
146
|
+
nextLanguage() {
|
|
147
|
+
if (this.$i18n.locale == 'zh') {
|
|
148
|
+
return 'English'
|
|
149
|
+
} else {
|
|
150
|
+
return '中文'
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
colorStyle() {
|
|
154
|
+
if (this.$i18n.locale == 'zh') {
|
|
155
|
+
return 'zhjack'
|
|
156
|
+
} else {
|
|
157
|
+
return 'enjack'
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
methods: {
|
|
162
|
+
// toggleSideBar() {
|
|
163
|
+
// this.$store.dispatch('toggleSideBar')
|
|
164
|
+
// },
|
|
165
|
+
// handleSetLanguage(lang) {
|
|
166
|
+
// this.$i18n.locale = lang
|
|
167
|
+
// this.$store.dispatch('setLanguage', lang)
|
|
168
|
+
// this.$message({
|
|
169
|
+
// message: 'switch language success',
|
|
170
|
+
// type: 'success'
|
|
171
|
+
// })
|
|
172
|
+
// },
|
|
173
|
+
|
|
174
|
+
editBoard() {
|
|
175
|
+
this.$router.push({
|
|
176
|
+
path: '/dashboard',
|
|
177
|
+
query: {
|
|
178
|
+
isEdit: '1'
|
|
179
|
+
}
|
|
180
|
+
})
|
|
181
|
+
},
|
|
182
|
+
logout() {
|
|
183
|
+
this.$store.dispatch('LogOut').then(() => {
|
|
184
|
+
location.reload()// 为了重新实例化vue-router对象 避免bug
|
|
185
|
+
})
|
|
186
|
+
},
|
|
187
|
+
changePsw() {
|
|
188
|
+
this.$refs['changepswform'].show()
|
|
189
|
+
},
|
|
190
|
+
changeAvatar() {
|
|
191
|
+
this.show = !this.show
|
|
192
|
+
},
|
|
193
|
+
/**
|
|
194
|
+
* crop success
|
|
195
|
+
*
|
|
196
|
+
* [param] imgDataUrl
|
|
197
|
+
* [param] field
|
|
198
|
+
*/
|
|
199
|
+
cropSuccess(imgDataUrl, field) {
|
|
200
|
+
// console.log('-------- crop success --------')
|
|
201
|
+
// this.imgDataUrl = imgDataUrl
|
|
202
|
+
// store.getters.avatar = imgDataUrl
|
|
203
|
+
this.$store.state.user.avatar = imgDataUrl;
|
|
204
|
+
},
|
|
205
|
+
/**
|
|
206
|
+
* upload success
|
|
207
|
+
*
|
|
208
|
+
* [param] jsonData 服务器返回数据,已进行json转码
|
|
209
|
+
* [param] field
|
|
210
|
+
*/
|
|
211
|
+
cropUploadSuccess(jsonData, field) {
|
|
212
|
+
// console.log('-------- upload success --------')
|
|
213
|
+
// console.log(jsonData)
|
|
214
|
+
// console.log('field: ' + field)
|
|
215
|
+
// this.imgDataUrl = 'webresources/login/com/comfileupload/download?uploadId=' + jsonData.message
|
|
216
|
+
},
|
|
217
|
+
/**
|
|
218
|
+
* upload fail
|
|
219
|
+
*
|
|
220
|
+
* [param] status server api return error status, like 500
|
|
221
|
+
* [param] field
|
|
222
|
+
*/
|
|
223
|
+
cropUploadFail(status, field) {
|
|
224
|
+
// console.log('-------- upload fail --------')
|
|
225
|
+
// console.log(status)
|
|
226
|
+
// console.log('field: ' + field)
|
|
227
|
+
},
|
|
228
|
+
changeStyle(style) {
|
|
229
|
+
this.$store.state.user.skin = style;
|
|
230
|
+
this.$http.get(`/webresources/login/privilege/AuthUser/updateUserStyleCss/${style}?stylecss=${style}`).then(response => {
|
|
231
|
+
const data = response.data
|
|
232
|
+
|
|
233
|
+
})
|
|
234
|
+
},
|
|
235
|
+
showMessage() {
|
|
236
|
+
this.$router.push({path: '/privilege/commsgto'})
|
|
237
|
+
},
|
|
238
|
+
changeLanguage(val) {
|
|
239
|
+
this.$i18n.locale = val
|
|
240
|
+
this.$store.state.user.language = val;
|
|
241
|
+
this.placeholderChg()
|
|
242
|
+
this.$http.get(`/webresources/login/privilege/AuthUser/updateUserLanguage/${val}`).then(response => {
|
|
243
|
+
const data = response.datas
|
|
244
|
+
})
|
|
245
|
+
},
|
|
246
|
+
placeholderChg() {
|
|
247
|
+
this.$date.placeholder = this.$t('选择日期')
|
|
248
|
+
this.$time.placeholder = this.$t('选择时间')
|
|
249
|
+
this.$simdate.placeholder = this.$t('选择日期')
|
|
250
|
+
this.$simtime.placeholder = this.$t('选择时间')
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
</script>
|
|
255
|
+
<style rel="stylesheet/scss" lang="scss" scoped>
|
|
256
|
+
|
|
257
|
+
.right-menu-item {
|
|
258
|
+
display: inline-block;
|
|
259
|
+
margin: 0 8px;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.item {
|
|
263
|
+
position: absolute;
|
|
264
|
+
z-index: 2000;
|
|
265
|
+
margin-left: -10px;
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
.el-icon-caret-bottom:before {
|
|
269
|
+
content: "" !important;
|
|
270
|
+
}
|
|
271
|
+
</style>
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<el-menu class="navbar" mode="horizontal">
|
|
3
|
+
<tags-view style="width: calc(100%);height: 100%;"></tags-view>
|
|
4
|
+
</el-menu>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script>
|
|
8
|
+
import TagsView from './TagsView'
|
|
9
|
+
|
|
10
|
+
export default {
|
|
11
|
+
components: {
|
|
12
|
+
TagsView
|
|
13
|
+
},
|
|
14
|
+
data() {
|
|
15
|
+
return {}
|
|
16
|
+
},
|
|
17
|
+
computed: {},
|
|
18
|
+
methods: {
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
</script>
|
|
22
|
+
|
|
23
|
+
<style rel="stylesheet/scss" lang="scss" scoped>
|
|
24
|
+
.navbar {
|
|
25
|
+
height: 30px; //jianglinghao 513
|
|
26
|
+
line-height: 40px;
|
|
27
|
+
border-radius: 0px !important;
|
|
28
|
+
|
|
29
|
+
.hamburger-container {
|
|
30
|
+
/*line-height: 40px;*/
|
|
31
|
+
/*height: 40px;*/
|
|
32
|
+
float: left;
|
|
33
|
+
padding: 0 10px;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.breadcrumb-container {
|
|
37
|
+
float: left;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.errLog-container {
|
|
41
|
+
display: inline-block;
|
|
42
|
+
vertical-align: top;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.right-menu {
|
|
46
|
+
float: right;
|
|
47
|
+
height: 100%;
|
|
48
|
+
|
|
49
|
+
&:focus {
|
|
50
|
+
outline: none;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.right-menu-item {
|
|
54
|
+
display: inline-block;
|
|
55
|
+
margin: 0 8px;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.screenfull {
|
|
59
|
+
vertical-align: middle;
|
|
60
|
+
height: 40px;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.international {
|
|
64
|
+
vertical-align: top;
|
|
65
|
+
|
|
66
|
+
.international-icon {
|
|
67
|
+
font-size: 20px;
|
|
68
|
+
cursor: pointer;
|
|
69
|
+
vertical-align: -5px;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.theme-switch {
|
|
74
|
+
vertical-align: 15px;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.avatar-container {
|
|
78
|
+
height: 40px;
|
|
79
|
+
margin-right: 30px;
|
|
80
|
+
|
|
81
|
+
.avatar-wrapper {
|
|
82
|
+
cursor: pointer;
|
|
83
|
+
margin-top: 5px;
|
|
84
|
+
position: relative;
|
|
85
|
+
|
|
86
|
+
.user-avatar {
|
|
87
|
+
width: 30px;
|
|
88
|
+
height: 30px;
|
|
89
|
+
border-radius: 10px;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.el-icon-caret-bottom {
|
|
93
|
+
position: absolute;
|
|
94
|
+
right: -20px;
|
|
95
|
+
top: 25px;
|
|
96
|
+
font-size: 12px;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
</style>
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="scroll-container" ref="scrollContainer" @mousewheel="handleScroll" @DOMMouseScroll="handleFoxScroll">
|
|
3
|
+
<div class="scroll-wrapper" ref="scrollWrapper" :style="{left: left + 'px'}">
|
|
4
|
+
<slot></slot>
|
|
5
|
+
</div>
|
|
6
|
+
</div>
|
|
7
|
+
</template>
|
|
8
|
+
|
|
9
|
+
<script>
|
|
10
|
+
export default {
|
|
11
|
+
name: 'scrollPane',
|
|
12
|
+
data() {
|
|
13
|
+
return {
|
|
14
|
+
left: 0,
|
|
15
|
+
tmpWrapperWidth: 0
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
updated: function () {
|
|
19
|
+
if (this.tmpWrapperWidth != this.$refs.scrollWrapper.offsetWidth) {
|
|
20
|
+
this.tmpWrapperWidth = this.$refs.scrollWrapper.offsetWidth;
|
|
21
|
+
if (this.$refs.scrollContainer.offsetWidth - this.$refs.scrollWrapper.offsetWidth < 100) {
|
|
22
|
+
this.left = this.$refs.scrollContainer.offsetWidth - this.$refs.scrollWrapper.offsetWidth - 100;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
methods: {
|
|
27
|
+
handleScroll(e) {
|
|
28
|
+
e.preventDefault()
|
|
29
|
+
const $container = this.$refs.scrollContainer
|
|
30
|
+
const $containerWidth = $container.offsetWidth
|
|
31
|
+
const $wrapper = this.$refs.scrollWrapper
|
|
32
|
+
const $wrapperWidth = $wrapper.offsetWidth
|
|
33
|
+
if (e.wheelDelta > 0) {
|
|
34
|
+
this.left = Math.min(0, this.left + e.wheelDelta)
|
|
35
|
+
} else {
|
|
36
|
+
if ($containerWidth - 100 < $wrapperWidth) {
|
|
37
|
+
if (this.left < -($wrapperWidth - $containerWidth + 100)) {
|
|
38
|
+
this.left = this.left
|
|
39
|
+
} else {
|
|
40
|
+
this.left = Math.max(this.left + e.wheelDelta, $containerWidth - $wrapperWidth - 100)
|
|
41
|
+
}
|
|
42
|
+
} else {
|
|
43
|
+
this.left = 0
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
handleFoxScroll(e) {
|
|
48
|
+
e.preventDefault()
|
|
49
|
+
const $container = this.$refs.scrollContainer
|
|
50
|
+
const $containerWidth = $container.offsetWidth
|
|
51
|
+
const $wrapper = this.$refs.scrollWrapper
|
|
52
|
+
const $wrapperWidth = $wrapper.offsetWidth
|
|
53
|
+
let pos = e.detail * (-10);
|
|
54
|
+
if (pos > 0) {
|
|
55
|
+
this.left = Math.min(0, this.left + pos)
|
|
56
|
+
} else {
|
|
57
|
+
if ($containerWidth - 100 < $wrapperWidth) {
|
|
58
|
+
if (this.left < -($wrapperWidth - $containerWidth + 100)) {
|
|
59
|
+
this.left = this.left
|
|
60
|
+
} else {
|
|
61
|
+
this.left = Math.max(this.left + pos, $containerWidth - $wrapperWidth - 100)
|
|
62
|
+
}
|
|
63
|
+
} else {
|
|
64
|
+
this.left = 0
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
</script>
|
|
71
|
+
|
|
72
|
+
<style rel="stylesheet/scss" lang="scss" scoped>
|
|
73
|
+
.scroll-container {
|
|
74
|
+
white-space: nowrap;
|
|
75
|
+
position: relative;
|
|
76
|
+
overflow: hidden;
|
|
77
|
+
.scroll-wrapper {
|
|
78
|
+
position: absolute;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
</style>
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="tags-view-container">
|
|
3
|
+
<scroll-pane class="tags-view-container" ref="scrollPane">
|
|
4
|
+
<router-link
|
|
5
|
+
:class="isActive(tag)?'active':''"
|
|
6
|
+
:key="tag.name"
|
|
7
|
+
:to="{ name: tag.name, params: tag.addQuery}"
|
|
8
|
+
@click.middle.native="closeSelectedTag(tag)"
|
|
9
|
+
@contextmenu.prevent.native="openMenu(tag,$event)"
|
|
10
|
+
class="tags-view-item"
|
|
11
|
+
ref="tag"
|
|
12
|
+
v-for="tag in Array.from(visitedViews)"> <!--name是menuId -->
|
|
13
|
+
{{ $i18n.locale == 'zh' ? tag.title : tag.enTitle }}
|
|
14
|
+
<span @click.stop="closeViewTags(tag,$event)" class="el-icon-close"/>
|
|
15
|
+
</router-link>
|
|
16
|
+
<div @click="headerToggle()" style="position: fixed;right: 20px"><i :class="showHeaderCls"
|
|
17
|
+
style="font-size:20px;color: #4d90fe"></i>
|
|
18
|
+
</div>
|
|
19
|
+
</scroll-pane>
|
|
20
|
+
<ul :style="{left:left+'px',top:top+'px'}" class="context-menu" v-show="visible">
|
|
21
|
+
<li @click="refreshSelectedTag()">{{ $t('tagsView.refresh') }}</li>
|
|
22
|
+
<li @click="closeOthersTags">{{ $t('tagsView.closeOthers') }}</li>
|
|
23
|
+
<li @click="closeAllTags">{{ $t('tagsView.closeAll') }}</li>
|
|
24
|
+
<li @click="openInNewWin()">{{ $t('tagsView.openNew') }}</li>
|
|
25
|
+
</ul>
|
|
26
|
+
|
|
27
|
+
</div>
|
|
28
|
+
</template>
|
|
29
|
+
|
|
30
|
+
<script>
|
|
31
|
+
import ScrollPane from './ScrollPane'
|
|
32
|
+
|
|
33
|
+
export default {
|
|
34
|
+
components: {ScrollPane},
|
|
35
|
+
data() {
|
|
36
|
+
return {
|
|
37
|
+
visible: false,
|
|
38
|
+
top: 0,
|
|
39
|
+
left: 0,
|
|
40
|
+
showHeaderCls: 'el-icon-upload2'
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
computed: {
|
|
44
|
+
visitedViews() {
|
|
45
|
+
return this.$store.state.app.visitedViews
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
watch: {
|
|
49
|
+
|
|
50
|
+
$route() {
|
|
51
|
+
this.addViewTags()
|
|
52
|
+
},
|
|
53
|
+
visible(value) {
|
|
54
|
+
if (value) {
|
|
55
|
+
document.body.addEventListener('click', this.closeMenu)
|
|
56
|
+
} else {
|
|
57
|
+
document.body.removeEventListener('click', this.closeMenu)
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
mounted() {
|
|
62
|
+
this.addViewTags()
|
|
63
|
+
},
|
|
64
|
+
methods: {
|
|
65
|
+
headerToggle() {
|
|
66
|
+
let st = this.$store.state.app.headerShow
|
|
67
|
+
if (st === false) {
|
|
68
|
+
this.showHeaderCls = 'el-icon-upload2'
|
|
69
|
+
this.$set(this.$store.state.app, 'headerShow', true)
|
|
70
|
+
} else {
|
|
71
|
+
this.showHeaderCls = 'el-icon-download'
|
|
72
|
+
this.$set(this.$store.state.app, 'headerShow', false)
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
closeViewTags(view, $event) {
|
|
76
|
+
this.$store.dispatch('delView', view).then((views) => {
|
|
77
|
+
if (this.isActive(view)) {
|
|
78
|
+
const latestView = views.slice(-1)[0]
|
|
79
|
+
if (latestView) {
|
|
80
|
+
this.$router.push(latestView.path)
|
|
81
|
+
} else {
|
|
82
|
+
this.$router.push('/')
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
})
|
|
86
|
+
$event.preventDefault()
|
|
87
|
+
},
|
|
88
|
+
generateRoute() {
|
|
89
|
+
if (this.$route.name) {
|
|
90
|
+
return this.$route
|
|
91
|
+
}
|
|
92
|
+
return false
|
|
93
|
+
},
|
|
94
|
+
addViewTags() {
|
|
95
|
+
const route = this.generateRoute()
|
|
96
|
+
if (!route) {
|
|
97
|
+
return false
|
|
98
|
+
}
|
|
99
|
+
this.$store.dispatch('addView', route)
|
|
100
|
+
},
|
|
101
|
+
isActive(route) {
|
|
102
|
+
return route.name === this.$route.name
|
|
103
|
+
},
|
|
104
|
+
refreshSelectedTag() {
|
|
105
|
+
this.$store.dispatch('refreshView', this.$store.state.app.selectedView)
|
|
106
|
+
},
|
|
107
|
+
closeOthersTags() {
|
|
108
|
+
this.$router.push(this.$store.state.app.selectedView)
|
|
109
|
+
this.$store.dispatch('delOthersViews', this.$store.state.app.selectedView).then(() => {
|
|
110
|
+
})
|
|
111
|
+
},
|
|
112
|
+
closeAllTags() {
|
|
113
|
+
this.$store.dispatch('delAllViews')
|
|
114
|
+
this.$router.push('/')
|
|
115
|
+
},
|
|
116
|
+
openMenu(tag, e) {
|
|
117
|
+
const menuMinWidth = 105
|
|
118
|
+
const offsetLeft = this.$el.getBoundingClientRect().left // container margin left
|
|
119
|
+
const offsetWidth = this.$el.offsetWidth // container width
|
|
120
|
+
const maxLeft = offsetWidth - menuMinWidth // left boundary
|
|
121
|
+
const left = e.clientX - offsetLeft + 15 // 15: margin right
|
|
122
|
+
if (left > maxLeft) {
|
|
123
|
+
this.left = maxLeft
|
|
124
|
+
} else {
|
|
125
|
+
this.left = left
|
|
126
|
+
}
|
|
127
|
+
this.top = e.clientY - 40
|
|
128
|
+
this.visible = true
|
|
129
|
+
this.$store.state.app.selectedView = tag
|
|
130
|
+
console.log(this.$store.state.app.selectedView)
|
|
131
|
+
},
|
|
132
|
+
closeMenu() {
|
|
133
|
+
this.visible = false
|
|
134
|
+
},
|
|
135
|
+
openInNewWin() {
|
|
136
|
+
const view = this.$store.state.app.selectedView;
|
|
137
|
+
const routeData = this.$router.resolve({
|
|
138
|
+
name: view.name,
|
|
139
|
+
params: view.params,
|
|
140
|
+
query: {onlycontent: 1}
|
|
141
|
+
})
|
|
142
|
+
window.open(routeData.href, view.name)
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
</script>
|
|
147
|
+
|
|
148
|
+
<style rel="stylesheet/scss" lang="scss" scoped>
|
|
149
|
+
.tags-view-container {
|
|
150
|
+
.tags-view-item {
|
|
151
|
+
display: inline-block;
|
|
152
|
+
position: relative;
|
|
153
|
+
height: 26px;
|
|
154
|
+
line-height: 26px;
|
|
155
|
+
border: 1px solid #d8dce5;
|
|
156
|
+
color: #495060;
|
|
157
|
+
background: #fff;
|
|
158
|
+
padding: 0 8px;
|
|
159
|
+
font-size: 12px;
|
|
160
|
+
margin-left: 5px;
|
|
161
|
+
margin-top: 4px;
|
|
162
|
+
|
|
163
|
+
&:first-of-type {
|
|
164
|
+
margin-left: 15px;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
&.active {
|
|
168
|
+
background-color: #409EFF;
|
|
169
|
+
color: #fff;
|
|
170
|
+
border-color: #409EFF;
|
|
171
|
+
|
|
172
|
+
&::before {
|
|
173
|
+
content: '';
|
|
174
|
+
background: #fff;
|
|
175
|
+
display: inline-block;
|
|
176
|
+
width: 8px;
|
|
177
|
+
height: 8px;
|
|
178
|
+
border-radius: 50%;
|
|
179
|
+
position: relative;
|
|
180
|
+
margin-right: 2px;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.tags-view-container {
|
|
187
|
+
.tags-view-item {
|
|
188
|
+
.el-icon-close {
|
|
189
|
+
width: 16px;
|
|
190
|
+
height: 16px;
|
|
191
|
+
vertical-align: 2px;
|
|
192
|
+
border-radius: 50%;
|
|
193
|
+
text-align: center;
|
|
194
|
+
transition: all .3s cubic-bezier(.645, .045, .355, 1);
|
|
195
|
+
transform-origin: 100% 50%;
|
|
196
|
+
|
|
197
|
+
&:before {
|
|
198
|
+
transform: scale(.6);
|
|
199
|
+
display: inline-block;
|
|
200
|
+
vertical-align: -3px;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
&:hover {
|
|
204
|
+
background-color: #b4bccc;
|
|
205
|
+
color: #fff;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
</style>
|