Navbar.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782
  1. <template>
  2. <div>
  3. <div class="navbar">
  4. <!-- 菜单展开缩起 -->
  5. <hamburger :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
  6. <div class="menu_module">
  7. <div class="menu_module_view">
  8. <v-scroll-view :x="true" :y="false" slidingBgClassName="slidingBgClassName"
  9. slidingBlockClassName="slidingBlockClassName">
  10. <div class="menu_module_fj">
  11. <div v-for="(item, index) in routes" :key="index" :class="{ item: true, select: path === item.path }"
  12. @click="path = item.path">
  13. {{ item.meta.title }}
  14. </div>
  15. </div>
  16. </v-scroll-view>
  17. </div>
  18. </div>
  19. <!-- 右侧 -->
  20. <div class="right-menu">
  21. <!-- <div class="right-menu-item">
  22. <el-autocomplete
  23. v-model="pathurl"
  24. :fetch-suggestions="querySearchAsync"
  25. placeholder="搜索菜单"
  26. @select="handleSelect"
  27. ></el-autocomplete>
  28. </div> -->
  29. <div style="margin-right: 20px; cursor: pointer" @click="
  30. getList()
  31. isShow = true
  32. ">
  33. <i class="el-icon-message-solid"></i>
  34. <el-badge :is-dot="isDot1 || isDot2"></el-badge>
  35. </div>
  36. <shortcut />
  37. <template v-if="device !== 'mobile'">
  38. <!-- 全屏控制 -->
  39. <screenfull id="screenfull" class="right-menu-item hover-effect" />
  40. </template>
  41. <el-dropdown class="user-container" trigger="click">
  42. <div class="user right-menu-item hover-effect">
  43. <div class="flex">
  44. <i class="el-icon-user-solid" />
  45. <span :class="name.length > 5 ? 'ellipsis' : ''">{{ name }}</span>
  46. </div>
  47. </div>
  48. <el-dropdown-menu slot="dropdown" class="user-dropdown">
  49. <router-link :to="{ name: 'profile' }">
  50. <el-dropdown-item>个人信息</el-dropdown-item>
  51. </router-link>
  52. <el-dropdown-item divided @click.native="logout">
  53. <span style="display: block">退出登录</span>
  54. </el-dropdown-item>
  55. </el-dropdown-menu>
  56. </el-dropdown>
  57. </div>
  58. </div>
  59. <notice-bar />
  60. <el-drawer title="系统消息" :visible.sync="isShow" :append-to-body="true" :with-header="false" direction="rtl" size="25%">
  61. <div class="message">
  62. <div class="head">
  63. <div class="flex_asb">
  64. <el-radio-group size="small" v-model="messageType" @change="getList">
  65. <el-badge :is-dot="isDot1" class="item">
  66. <el-radio-button
  67. :label="['WBI', 'WBK', 'CRE_ORDER', 'SEND_MALL', 'RP_MALL', 'CR_SALES']">系统消息</el-radio-button>
  68. </el-badge>
  69. <el-badge :is-dot="isDot2" class="item">
  70. <el-radio-button :label="['NOTICE']">平台公告</el-radio-button>
  71. </el-badge>
  72. </el-radio-group>
  73. <el-switch v-model="isOpen" @change="updateIsNotice" inactive-text="消息弹窗" active-color="#13ce66"
  74. inactive-color="#ff4949">
  75. </el-switch>
  76. </div>
  77. <el-radio-group size="mini" v-model="dateType" @change="getList" style="margin: 10px 0">
  78. <el-radio-button label="">全部</el-radio-button>
  79. <el-radio-button :label="0">今天</el-radio-button>
  80. <el-radio-button :label="1">昨天</el-radio-button>
  81. <el-radio-button :label="6">近7天</el-radio-button>
  82. <el-radio-button :label="29">近30天</el-radio-button>
  83. </el-radio-group>
  84. <div class="flex_asb">
  85. <el-radio-group size="mini" v-model="readFlag" @change="getList">
  86. <el-radio-button label="">全部</el-radio-button>
  87. <el-badge :hidden="count > 0 ? false : true" :value="count" class="item" style="margin: 0 10px">
  88. <el-radio-button label="NO">未读</el-radio-button>
  89. </el-badge>
  90. <el-badge :value="count" :hidden="true" class="item">
  91. <el-radio-button label="YES">已读</el-radio-button>
  92. </el-badge>
  93. </el-radio-group>
  94. <div style="color: #409eff; cursor: pointer" @click="confirmRead">
  95. <i class="el-icon-message-solid"></i>
  96. <span style="font-size: 14px">全部已读</span>
  97. </div>
  98. </div>
  99. </div>
  100. <el-card class="box-card" v-for="(item, index) in messageData" style="margin-top: 10px">
  101. <div @click="
  102. isShow = false
  103. toDetail(
  104. item.adminNoticeType,
  105. item.paidType,
  106. item.adminNoticeType == 'NOTICE' ? item.noticeId : item.orderId,
  107. item.id
  108. )
  109. ">
  110. <div v-if="item.adminNoticeType == 'NOTICE'">
  111. <div class="flex_asb item">
  112. <div>
  113. <span>公告类型:</span>
  114. <span>{{ statusFilter(item.adminNoticeType) }}</span>
  115. </div>
  116. <div class="read1" v-if="item.readFlag == 'NO'">未读</div>
  117. <div class="read2" v-if="item.readFlag == 'YES'">已读</div>
  118. </div>
  119. <div class="item">
  120. <div>
  121. <span>文件标题:</span>
  122. <span style="color: #409eff">{{ item.title }}</span>
  123. </div>
  124. </div>
  125. <div class="item">
  126. <div>
  127. <span>发布人:</span>
  128. <span>{{ item.issueNickName | '' }}</span>
  129. </div>
  130. </div>
  131. <div class="item">
  132. <div>
  133. <span>发布时间:</span>
  134. <span>{{ item.issueTime }}</span>
  135. </div>
  136. </div>
  137. <div v-if="item.readFlag == 'YES'" class="item">
  138. <span>阅读人:</span>
  139. <span>{{ item.adminNickName }} {{ item.readTime }}</span>
  140. </div>
  141. </div>
  142. <div v-else>
  143. <div class="flex_asb item">
  144. <div>
  145. <span>消息类型:</span>
  146. <span>{{ statusFilter(item.adminNoticeType) }}</span>
  147. </div>
  148. <div class="read1" v-if="item.readFlag == 'NO'">未读</div>
  149. <div class="read2" v-if="item.readFlag == 'YES'">已读</div>
  150. </div>
  151. <div class="item">
  152. <div>
  153. <span>订单编号:</span>
  154. <span style="color: #409eff">{{ item.orderId }}</span>
  155. </div>
  156. </div>
  157. <div class="item">
  158. <div>
  159. <span>消息内容:</span>
  160. <span>{{ item.content }}</span>
  161. </div>
  162. </div>
  163. <div class="item">
  164. <div>
  165. <span>创建时间:</span>
  166. <span>{{ item.createTime }}</span>
  167. </div>
  168. </div>
  169. <div v-if="item.readFlag == 'YES'" class="item">
  170. <span>阅读人:</span>
  171. <span>{{ item.adminNickName }} {{ item.readTime }}</span>
  172. </div>
  173. </div>
  174. </div>
  175. </el-card>
  176. <el-empty v-if="messageData.length == 0" description="暂无数据"></el-empty>
  177. <div class="flex_ac bottom">
  178. <el-pagination @current-change="handleCurrentChange" :current-page="currentPage" :page-size="pageSize"
  179. layout="prev, pager, next" background :total="listTotal"></el-pagination>
  180. </div>
  181. </div>
  182. </el-drawer>
  183. </div>
  184. </template>
  185. <script>
  186. import { mapGetters } from 'vuex'
  187. import Hamburger from '@/components/Hamburger'
  188. import Shortcut from '@/components/Shortcut'
  189. import Screenfull from '@/components/Screenfull'
  190. import NavMenu from '@/components/NavMenu'
  191. import vScrollView from 'v-scroll-view'
  192. import NoticeBar from '@/components/NoticeBar'
  193. import { pages } from '@/settings'
  194. import request from '@/utils/request'
  195. function getc(obj) {
  196. if (!obj.children || !obj.children.length) {
  197. return obj
  198. } else {
  199. return getc(obj.children[0])
  200. }
  201. }
  202. export default {
  203. components: {
  204. NoticeBar,
  205. Hamburger,
  206. Screenfull,
  207. NavMenu,
  208. Shortcut,
  209. vScrollView
  210. },
  211. data() {
  212. return {
  213. pathurl: '',
  214. visible: false,
  215. noticeCount: 0,
  216. path: `/${this.$route.path.split('/')[1] || ''}`,
  217. isShow: false,
  218. isOpen: true,
  219. checked: false,
  220. messageType: ['WBI', 'WBK', 'CRE_ORDER', 'SEND_MALL', 'RP_MALL', 'CR_SALES'],
  221. messageData: [],
  222. dateType: '',
  223. readFlag: '',
  224. timer: null,
  225. listTotal: 0,
  226. currentPage: 1, // 当前页码
  227. pageSize: 10, // 每页数量
  228. count: 0,
  229. isDot1: false,
  230. isDot2: false
  231. }
  232. },
  233. computed: {
  234. routes() {
  235. return global.antRouter.filter(item => item.meta)
  236. },
  237. noticeVisible() {
  238. return this.noticeCount > 0
  239. },
  240. ...mapGetters(['userid']),
  241. ...mapGetters(['sidebar', 'avatar', 'device', 'name', 'isNotice']),
  242. filterTime() {
  243. if (this.dateType === '') {
  244. return ['', '']
  245. } else {
  246. var date = new Date();
  247. var base = Date.parse(date); // 转换为时间戳
  248. var year = date.getFullYear(); //获取当前年份
  249. var mon = date.getMonth() + 1; //获取当前月份
  250. var day = date.getDate(); //获取当前日
  251. var oneDay = 24 * 3600 * 1000
  252. var daytimeArr = []
  253. var now = new Date((base - oneDay * this.dateType));
  254. var myear = now.getFullYear();
  255. var month = now.getMonth() + 1;
  256. var mday = now.getDate()
  257. if (this.dateType == 1) {
  258. return [`${myear}-${month > 9 ? month : '0' + month}-${mday > 9 ? mday : '0' + mday} 00:00:00`, `${myear}-${month > 9 ? month : '0' + month}-${mday > 9 ? mday : '0' + mday} 23:59:59`]
  259. } else {
  260. return [`${myear}-${month > 9 ? month : '0' + month}-${mday > 9 ? mday : '0' + mday} 00:00:00`, `${year}-${mon > 9 ? mon : '0' + mon}-${day > 9 ? day : '0' + day} 23:59:59`]
  261. }
  262. }
  263. },
  264. statusFilter() {
  265. return function (val) {
  266. const MAP = {
  267. NOTICE: '平台公告',
  268. WBI: '维保消息费用申请',
  269. WBK: '维保费用申请审批',
  270. CRE_ORDER: '创建工单',
  271. SEND_MALL: '商城订单发货',
  272. RP_MALL: '商城订单维权',
  273. CR_SALES: '订单支付成功'
  274. }
  275. return MAP[val]
  276. }
  277. },
  278. typeFilter() {
  279. return function (val, paidType) {
  280. const MAP = {
  281. NOTICE: 'systemMessage',
  282. WBI: 'applicationWithoutFee',
  283. WBK: 'applicationWithoutFee',
  284. CRE_ORDER: 'workOrderPool',
  285. SEND_MALL: 'order_detail',
  286. RP_MALL: 'order_refund_detail',
  287. CR_SALES: (paidType == 'M' ? 'auxiliarySalesOrder' : paidType == 'P' ? 'attachmentSalesOrder' : paidType == 'YB' ? 'orderSettleManag' : paidType == 'MALL' ? 'order_detail' : '')
  288. }
  289. return MAP[val]
  290. }
  291. }
  292. },
  293. watch: {
  294. $route() {
  295. this.path = `/${this.$route.path.split('/')[1] || ''}`
  296. },
  297. path(newVal) {
  298. this.$store.commit('app/SET_L1_PATH', newVal)
  299. if (
  300. !~this.$route.path
  301. .split('/')
  302. .map(str => `/${str}`)
  303. .indexOf(newVal)
  304. ) {
  305. var item = getc(this.routes.find(item => item.path === newVal))
  306. if (item) {
  307. this.$router.push(item.path)
  308. }
  309. }
  310. }
  311. },
  312. created() {
  313. clearInterval(this.timer)
  314. this.getUserInfo()
  315. this.redDot()
  316. },
  317. mounted() {
  318. this.$store.commit('app/SET_L1_PATH', this.path)
  319. },
  320. methods: {
  321. handlePage() {
  322. let link = null
  323. if (process.env.VUE_APP_ENV === 'production') {
  324. link = 'https://fw.gd-jxm.com/#/home'
  325. } else {
  326. link = 'https://jiasm.zfire.top/center/#/home'
  327. }
  328. window.open(link)
  329. },
  330. querySearchAsync(queryString, cb) {
  331. var data = pages.filter(item => ~item.meta.title.indexOf(queryString))
  332. cb(
  333. data.map(item => ({
  334. value: item.meta.title,
  335. path: item.path
  336. }))
  337. )
  338. },
  339. handleSelect(item) {
  340. if (item.path) {
  341. this.$router.push({
  342. path: item.path
  343. })
  344. }
  345. this.pathurl = ''
  346. },
  347. async logout() {
  348. await this.$store.dispatch('user/logout')
  349. this.$store.commit('tagsView/SET_RESET_VIES')
  350. this.$router.push(`/login`)
  351. },
  352. toggleSideBar() {
  353. this.$store.dispatch('app/toggleSideBar')
  354. },
  355. //获取最新消息并弹窗
  356. getMessageTips() {
  357. const that = this
  358. this.timer = setInterval(() => {
  359. request({
  360. url: `/notice/list/out`,
  361. method: 'get',
  362. params: {
  363. num: 30
  364. }
  365. }).then(res => {
  366. res.data.forEach(item => {
  367. this.$notify({
  368. title: '新消息',
  369. position: 'bottom-right',
  370. duration: 30000,
  371. message: that.$createElement(
  372. 'div',
  373. {
  374. style: 'cursor: pointer;',
  375. on: {
  376. click: that.toDetail.bind(
  377. that,
  378. item.adminNoticeType,
  379. item.paidType,
  380. item.adminNoticeType == 'NOTICE' ? item.noticeId : item.orderId,
  381. item.id
  382. )
  383. }
  384. },
  385. [
  386. that.$createElement('span', null, that.statusFilter(item.adminNoticeType) + ' '),
  387. that.$createElement(
  388. 'span',
  389. {
  390. style: 'color: #409EFF;'
  391. },
  392. ' ' + item.adminNoticeType == 'NOTICE' ? item.title : item.orderId
  393. ),
  394. that.$createElement('span', null, item.adminNoticeType == 'NOTICE' ? '' : item.content)
  395. // that.$createElement(
  396. // "el-checkbox",
  397. // {
  398. // on: {
  399. // change: that.updateIsNotice.bind(that)
  400. // },
  401. // }, '不再弹窗新消息'
  402. // )
  403. ]
  404. )
  405. })
  406. })
  407. })
  408. }, 30000)
  409. },
  410. getCount() {
  411. request({
  412. url: `/notice/list/count`,
  413. method: 'get',
  414. params: {
  415. noticeType: this.messageType.join(','),
  416. readFlag: 'NO'
  417. }
  418. }).then(res => {
  419. this.count = res.data
  420. })
  421. },
  422. redDot() {
  423. request({
  424. url: `/notice/list/count`,
  425. method: 'get',
  426. params: {
  427. noticeType: ['WBI', 'WBK', 'CRE_ORDER', 'SEND_MALL', 'RP_MALL', 'CR_SALES'].join(','),
  428. readFlag: 'NO'
  429. }
  430. }).then(res => {
  431. this.isDot1 = res.data > 0 ? true : false
  432. })
  433. request({
  434. url: `/notice/list/count`,
  435. method: 'get',
  436. params: {
  437. noticeType: ['NOTICE'].join(','),
  438. readFlag: 'NO'
  439. }
  440. }).then(res => {
  441. this.isDot2 = res.data > 0 ? true : false
  442. })
  443. },
  444. getUserInfo() {
  445. const that = this
  446. request({
  447. url: `/admin/user/detail`,
  448. method: 'get',
  449. params: {
  450. adminUserId: this.userid
  451. }
  452. }).then(res => {
  453. this.isOpen = res.data.isNotice == 'YES' ? true : false
  454. if (res.data.isNotice == 'NO') {
  455. clearInterval(this.timer)
  456. } else {
  457. clearInterval(this.timer)
  458. this.getMessageTips()
  459. }
  460. })
  461. },
  462. //全部已读
  463. confirmRead() {
  464. this.$confirm('是否全部设为已读, 是否继续?', '提示', {
  465. confirmButtonText: '确定',
  466. cancelButtonText: '取消',
  467. type: 'warning'
  468. })
  469. .then(() => {
  470. request({
  471. url: `/notice/mark/read/all`,
  472. method: 'post',
  473. data: {}
  474. }).then(res => {
  475. if (res.code == 200) {
  476. this.getList()
  477. this.$message.success('全部已读成功!')
  478. }
  479. })
  480. })
  481. .catch(() => {
  482. this.$message({
  483. type: 'info',
  484. message: '已取消'
  485. })
  486. })
  487. },
  488. //点击不再弹窗新消息
  489. updateIsNotice(e) {
  490. request({
  491. url: `/notice/updateIsNotice`,
  492. method: 'post',
  493. params: {
  494. isNotice: e ? 'YES' : 'NO'
  495. }
  496. }).then(res => {
  497. if (res.code == 200) {
  498. this.getUserInfo()
  499. this.$message.success(e ? '已开启弹窗消息提醒' : '已关闭弹窗消息提醒')
  500. if (!e) {
  501. clearInterval(this.timer)
  502. }
  503. }
  504. })
  505. },
  506. getList() {
  507. request({
  508. url: `/notice/list`,
  509. method: 'post',
  510. data: {
  511. pageNum: this.currentPage,
  512. pageSize: this.pageSize,
  513. params: [
  514. { param: 'nr.read_flag', compare: '=', value: this.readFlag },
  515. { param: 'nr.admin_notice_type', compare: '=', value: this.messageType },
  516. { param: 'nr.issue_time', compare: '>=', value: this.filterTime[0] },
  517. { param: 'nr.issue_time', compare: '<=', value: this.filterTime[1] }
  518. ]
  519. }
  520. }).then(res => {
  521. this.getCount()
  522. this.redDot()
  523. this.listTotal = res.data.total
  524. this.messageData = res.data.records
  525. })
  526. },
  527. // 更改当前页
  528. handleCurrentChange(val) {
  529. this.currentPage = val
  530. this.getList()
  531. },
  532. toDetail(type, paidType, orderId, id) {
  533. console.log(this.typeFilter(type, paidType))
  534. this.read(id)
  535. this.$router.push({
  536. name: this.typeFilter(type, paidType),
  537. params: {
  538. pageName: orderId,
  539. pageType: 'detail',
  540. pageCode: orderId
  541. },
  542. query: {
  543. id: orderId,
  544. orderId: orderId
  545. }
  546. })
  547. },
  548. read(id) {
  549. request({
  550. url: `/notice/mark/read`,
  551. method: 'post',
  552. params: {
  553. noticeIds: id
  554. }
  555. }).then(res => { })
  556. }
  557. }
  558. }
  559. </script>
  560. <style lang="scss" scoped>
  561. @import '~@/styles/variables.scss';
  562. // ::v-deep .el-drawer__container{
  563. // top: 50px;
  564. // }
  565. ::v-deep .is-fixed {
  566. right: 10px !important;
  567. }
  568. ::v-deep .slidingBgClassName {
  569. background: rgba(0, 0, 0, 0.01) !important;
  570. }
  571. ::v-deep .slidingBlockClassName {
  572. background: rgba(0, 0, 0, 0.05) !important;
  573. }
  574. .flex_asb {
  575. display: flex;
  576. justify-content: space-between;
  577. align-items: center;
  578. }
  579. .flex_ac {
  580. display: flex;
  581. justify-content: center;
  582. }
  583. .message {
  584. padding: 20px;
  585. position: relative;
  586. min-height: 100%;
  587. padding-bottom: 60px;
  588. padding-top: 150px;
  589. box-sizing: border-box;
  590. .head {
  591. width: 25%;
  592. position: fixed;
  593. top: 0;
  594. right: 0;
  595. background: #ffffff;
  596. padding: 20px;
  597. }
  598. .bottom {
  599. width: 25%;
  600. position: fixed;
  601. bottom: 0;
  602. right: 0;
  603. background: #ffffff;
  604. padding: 10px 0;
  605. }
  606. }
  607. .box-card {
  608. .item {
  609. cursor: pointer;
  610. margin-bottom: 6px;
  611. }
  612. .read1 {
  613. color: #f5680e;
  614. background: #fff2da;
  615. padding: 2px 4px;
  616. border-radius: 4px;
  617. font-size: 14px;
  618. }
  619. .read2 {
  620. color: #42b983;
  621. background: #d7fdde;
  622. padding: 2px 4px;
  623. border-radius: 4px;
  624. font-size: 14px;
  625. }
  626. }
  627. .navbar {
  628. width: 100%;
  629. height: 50px;
  630. overflow: hidden;
  631. background: #{$navbarBg};
  632. box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08);
  633. display: flex;
  634. flex-direction: row;
  635. align-items: center;
  636. .hamburger-container {
  637. line-height: 46px;
  638. height: 100%;
  639. color: #{$navbarText};
  640. cursor: pointer;
  641. transition: background 0.3s;
  642. -webkit-tap-highlight-color: transparent;
  643. border-right: 1px solid #eaeaea;
  644. &:hover {
  645. background: rgba(0, 0, 0, 0.025);
  646. }
  647. }
  648. .menu_module {
  649. height: 100%;
  650. flex: 1;
  651. position: relative;
  652. .menu_module_view {
  653. position: absolute;
  654. top: 0;
  655. left: 0;
  656. bottom: 0;
  657. right: 0;
  658. .menu_module_fj {
  659. height: 100%;
  660. width: fit-content;
  661. white-space: nowrap;
  662. box-sizing: border-box;
  663. padding: 0 10px;
  664. .item {
  665. display: inline-block;
  666. height: 100%;
  667. line-height: 50px;
  668. box-sizing: border-box;
  669. padding: 0 10px;
  670. cursor: pointer;
  671. }
  672. .select {
  673. border-bottom: 1px solid #000;
  674. }
  675. }
  676. }
  677. }
  678. .flex {
  679. display: flex;
  680. align-items: center;
  681. }
  682. .ellipsis {
  683. display: inline-block;
  684. width: (16px * 6);
  685. white-space: nowrap;
  686. overflow: hidden;
  687. text-overflow: ellipsis;
  688. }
  689. .right-menu {
  690. height: 100%;
  691. line-height: 50px;
  692. &>div {
  693. float: left;
  694. }
  695. &:focus {
  696. outline: none;
  697. }
  698. .user-container {
  699. height: 50px;
  700. .user {
  701. i {
  702. font-size: 18px;
  703. margin-right: 5px;
  704. }
  705. span {
  706. font-size: 16px;
  707. }
  708. }
  709. }
  710. .right-menu-item {
  711. display: inline-block;
  712. padding: 0 15px;
  713. height: 100%;
  714. font-size: 18px;
  715. color: #{$navbarText};
  716. vertical-align: text-bottom;
  717. border-left: 1px solid #eaeaea;
  718. &.hover-effect {
  719. cursor: pointer;
  720. transition: background 0.3s;
  721. &:hover {
  722. background: rgba(0, 0, 0, 0.025);
  723. }
  724. }
  725. .notice-icon {
  726. padding-top: 0;
  727. padding-bottom: 0;
  728. }
  729. .right-menu-item {
  730. .notice-icon>i {
  731. font-size: 18px;
  732. }
  733. sup {
  734. top: 12px;
  735. right: 25px;
  736. }
  737. }
  738. }
  739. }
  740. }
  741. ::v-deep .el-badge__content.is-fixed {
  742. z-index: 99;
  743. }
  744. </style>