index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809
  1. <!-- 农林植保 -->
  2. <template>
  3. <el-container style="height: 100%">
  4. <el-header height="80px">
  5. <div class="headMenu">
  6. <!-- {{currTopMenuId}} -->
  7. <!-- logo -->
  8. <div class="logoinfo">
  9. <div>
  10. <img :src="$imghost + logoIcon" width="40" alt v-if="!loginInfo.role_logo" />
  11. <img :src="loginInfo.role_logo" v-else width="40px" />
  12. <span>{{ loginInfo.role_header || "河南省高标准农田管理系统" }}</span>
  13. </div>
  14. <!-- {{menuTabs}} -->
  15. </div>
  16. <!-- 菜单 -->
  17. <ul class="topMenu">
  18. <li
  19. v-for="(item,index) in menuList"
  20. :key="item.index"
  21. :class="{'active':item.name==currTopMenuId}"
  22. :id="'nav' + index"
  23. v-trigger="(that)"
  24. @click="topMenuClick(item,index)"
  25. >
  26. <div class="navContent">
  27. <div class="a1">
  28. <div class="blueMenu">
  29. <img src="../../static/images/indexTab.png" alt="" >
  30. </div>
  31. </div>
  32. <div class="a2">
  33. <div class="blueMenu indexTabActive">
  34. <img src="../../static/images/indexTabActive.png" alt="" >
  35. </div>
  36. </div>
  37. <div class="navTxt">{{item.name}}</div>
  38. </div>
  39. </li>
  40. <!-- <li
  41. v-for="(item,index) in menuList"
  42. :key="item.index"
  43. :class="{'active':item.name==currTopMenuId}"
  44. :id="'nav' + index"
  45. v-trigger
  46. @click="topMenuClick(item,index)"
  47. >
  48. <img v-if="item.id" :src="iconimgs[item.id]" alt />
  49. <div>{{item.name}}</div>
  50. </li> -->
  51. </ul>
  52. <div class="userInfo">
  53. 欢迎您!
  54. <el-dropdown @command="dropdownHandle" >
  55. <span class="el-dropdown-link">
  56. {{username}}
  57. <i class="el-icon-arrow-down el-icon--right"></i>
  58. </span>
  59. <el-dropdown-menu slot="dropdown">
  60. <el-dropdown-item command="personMsg">个人中心</el-dropdown-item>
  61. <el-dropdown-item command="editPwd">修改密码</el-dropdown-item>
  62. </el-dropdown-menu>
  63. </el-dropdown>
  64. <div class="exit" @click="outSys()">
  65. <i class="iconfont icon-exit"></i>
  66. </div>
  67. <!-- <div> -->
  68. <!-- <button></button> -->
  69. <!-- <el-button type="primary" icon="el-icon-search">搜索</el-button> -->
  70. <!-- </div> -->
  71. </div>
  72. </div>
  73. </el-header>
  74. <!-- 修改密码对话框 -->
  75. <el-dialog
  76. title="修改密码"
  77. :visible.sync="resetPassDialogVisible"
  78. width="500px"
  79. top="180px"
  80. @close="resetPassDialogClosed"
  81. >
  82. <el-form
  83. ref="resetPassFormRef"
  84. :model="resetPassForm"
  85. label-width="104px"
  86. :rules="resetPassFormRules"
  87. >
  88. <el-form-item label="原始密码 : " prop="oldPass">
  89. <el-input type="password" v-model="resetPassForm.oldPass"></el-input>
  90. </el-form-item>
  91. <el-form-item label="新密码 : " prop="newPass">
  92. <el-input type="password" v-model="resetPassForm.newPass"></el-input>
  93. </el-form-item>
  94. <el-form-item label="确认新密码 : " prop="checkNewPass">
  95. <el-input
  96. type="password"
  97. v-model="resetPassForm.checkNewPass"
  98. ></el-input>
  99. </el-form-item>
  100. </el-form>
  101. <span slot="footer" class="dialog-footer">
  102. <el-button @click="resetPassDialogVisible = false">取 消</el-button>
  103. <el-button type="primary" @click="resetPassSubm">确认</el-button>
  104. </span>
  105. </el-dialog>
  106. <el-container style="overflow: auto">
  107. <el-aside width="85px">
  108. <ul class="leftMenu">
  109. <li
  110. v-for="(item, index) in leftMenuList"
  111. :key="item.path"
  112. :class="{'active':item.name==currLeftMenuId}"
  113. @click="leftMenuClick(item,index)"
  114. >
  115. <i :class="['iconfont', iconimgs[item.pur_id]]"></i>
  116. <div>{{item.name}}</div>
  117. </li>
  118. </ul>
  119. </el-aside>
  120. <el-main>
  121. <div class="tabsNav">
  122. <el-tabs v-model="menuTabsValue" type="card" closable @tab-click="clickTab" @tab-remove="removeTab">
  123. <el-tab-pane
  124. v-for="(item, index) in menuTabs"
  125. :key="item.path"
  126. :label="item.name"
  127. :name="item.name"
  128. ></el-tab-pane>
  129. </el-tabs>
  130. </div>
  131. <div class="content">
  132. <!-- <div>{{menuTabsValue}}</div> -->
  133. <!-- <keep-alive> -->
  134. <!-- <router-view></router-view> -->
  135. <!-- </keep-alive> -->
  136. <keep-alive>
  137. <router-view v-if="$route.meta.keepAlive"></router-view>
  138. </keep-alive>
  139. <router-view v-if="!$route.meta.keepAlive"></router-view>
  140. </div>
  141. </el-main>
  142. </el-container>
  143. </el-container>
  144. </template>
  145. <script>
  146. //这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
  147. //例如:import 《组件名称》 from '《组件路径》';
  148. import '@/plugin/flexible.js'
  149. export default {
  150. //import引入的组件需要注入到对象中才能使用
  151. components: {},
  152. data() {
  153. var validateNewPass = (rule, value, callback) => {
  154. if (value === "") {
  155. callback(new Error("请输入新密码"));
  156. } else {
  157. if (this.resetPassForm.checkPass !== "") {
  158. this.$refs.resetPassFormRef.validateField("checkNewPass");
  159. }
  160. callback();
  161. }
  162. };
  163. var validateCheckPass = (rule, value, callback) => {
  164. if (value === "") {
  165. callback(new Error("请再次输入密码"));
  166. } else if (value !== this.resetPassForm.newPass) {
  167. callback(new Error("两次输入密码不一致!"));
  168. } else {
  169. callback();
  170. }
  171. };
  172. //这里存放数据
  173. return {
  174. that: this,
  175. logoIcon: "/images/logo.png",
  176. menuList: [],
  177. leftMenuList: [],
  178. currTopMenuId: '农林植保',
  179. currLeftMenuId: '设备列表',
  180. iconimgs: {
  181. "1": 'icon-dingdianxuncha',
  182. "2": 'icon-dingdianxuncha',
  183. "100": 'icon-dingdianxuncha',
  184. "3": 'icon-shipinwulian',
  185. "4": 'icon-shipinwulian',
  186. "5": 'icon-yujing',
  187. "101": 'icon-yujing',
  188. "6": 'icon-yujing',
  189. "7": 'icon-shebeibaoyan',
  190. "8": 'icon-xingxiang',
  191. "9": 'icon-rizhi',
  192. "10": 'icon-shuizhi',
  193. "102": 'icon-shuizhi',
  194. "11": 'icon-shuizhi',
  195. "12": 'icon-rizhi',
  196. "13": 'icon-yujing',
  197. "14": 'icon-1',
  198. "15": 'icon-1',
  199. "16": 'icon-yen-2',
  200. "17": 'icon-inbox-1',
  201. "18": 'icon-inbox-1',
  202. "19": 'icon-inbox-1',
  203. "20": 'icon-yonghu2',
  204. "21": 'icon-yonghu2',
  205. "22": 'icon-moxingguanli',
  206. "23": 'icon-shiming',
  207. "24": 'icon-BIM',
  208. },
  209. //动态标签
  210. // menuTabs:[{ "path": "/plantGuard/base", "name": "设备列表", "par": "农林植保", "order": 0 } ],
  211. menuTabs:[],
  212. menuTabsValue:'',
  213. username:"",
  214. // 用户信息
  215. loginInfo:{},
  216. resetPassDialogVisible:false,
  217. resetPassForm: {
  218. oldPass: "",
  219. newPass: "",
  220. checkNewPass: "",
  221. },
  222. resetPassFormRules: {
  223. oldPass: [
  224. { required: true, message: "请输入原始密码", trigger: "blur" },
  225. ],
  226. newPass: [
  227. { required: true, message: "请输入新密码" },
  228. { validator: validateNewPass, trigger: "blur" },
  229. ],
  230. checkNewPass: [
  231. { required: true, message: "请确认密码" },
  232. { validator: validateCheckPass, trigger: "blur" },
  233. ],
  234. },
  235. };
  236. },
  237. //监听属性 类似于data概念
  238. computed: {},
  239. //监控data中的数据变化
  240. watch: {
  241. '$route' (to, from) {
  242. console.log('--------------');
  243. console.log(to.meta.keepAlive);
  244. let flag = false
  245. for (let item of this.menuTabs) {
  246. if (item.name === to.meta.navname) {
  247. this.menuTabsValue = to.meta.navname
  248. flag = true
  249. break
  250. }
  251. }
  252. console.log(this.menuList);
  253. if (!flag) {
  254. var breakFlag = false;
  255. for(var i = 0 ;i<this.menuList.length;i++){
  256. if(!this.menuList[i].children){
  257. continue;
  258. }
  259. for(var j = 0 ;j<this.menuList[i].children.length;j++){
  260. if(this.menuList[i].children[j].name == to.meta.navname){
  261. console.log(i);
  262. var order = i;
  263. breakFlag = true;
  264. break;
  265. }
  266. }
  267. if(breakFlag){
  268. break;
  269. }
  270. }
  271. this.add_tabs({path: to.path, name: to.meta.navname,par:to.meta.title,order:order})
  272. this.menuTabsValue = to.meta.navname
  273. }
  274. sessionStorage.setItem("menuTabs", JSON.stringify(this.menuTabs));
  275. sessionStorage.setItem("menuTabsValue", this.menuTabsValue);
  276. }
  277. },
  278. //vue自定义指令
  279. directives: {
  280. trigger: {
  281. inserted(el, binging) {
  282. var menuTabsValue = sessionStorage.getItem("menuTabsValue");
  283. var menuTabs = sessionStorage.getItem("menuTabs");
  284. if(menuTabs){
  285. binging.value.that.menuTabs = JSON.parse(menuTabs)
  286. binging.value.that.menuTabsValue = menuTabsValue
  287. binging.value.that.leftMenuList = JSON.parse(sessionStorage.getItem("leftMenuList"));
  288. binging.value.that.currLeftMenuId = sessionStorage.getItem("currLeftMenuId");
  289. }else{
  290. el.id == "nav0" ? el.click() : null; // 只点击第一个,id是在循环中手动添加的
  291. console.log(2);
  292. }
  293. },
  294. },
  295. },
  296. //方法集合
  297. methods: {
  298. topMenuClick(item, index) {
  299. // console.log(item);
  300. // console.log(this.$router.options.routes);
  301. if(item.children){
  302. this.$router.options.routes.forEach(route => {
  303. if(route.children && route.children.length){
  304. route.children.forEach(child => {
  305. if(child.meta){
  306. if(child.meta.navname == item.children[0].name){
  307. child.meta.keepAlive = false;
  308. }
  309. }
  310. })
  311. }
  312. })
  313. this.currTopMenuId = item.name;
  314. this.leftMenuList = item.children;
  315. this.currLeftMenuId = item.children[0].name;
  316. sessionStorage.setItem("leftMenuList", JSON.stringify(item.children));
  317. sessionStorage.setItem("currLeftMenuId", item.children[0].name);
  318. this.$router.push({ path: '/plantGuard/'+item.children[0].path });
  319. }else if(item.name == '产品溯源'){
  320. // var routeUrl = this.$router.resolve({
  321. // path: '/index/farmBaseManger'
  322. // })
  323. // window.open(routeUrl.href, '_blank')
  324. window.open('http://182.92.193.64/#/syLogin')
  325. }else{
  326. this.$message({
  327. message: '系统开发中',
  328. type: 'warning'
  329. });
  330. }
  331. },
  332. leftMenuClick(item, index) {
  333. console.log(item);
  334. this.$router.options.routes.forEach(route => {
  335. if(route.children && route.children.length){
  336. route.children.forEach(child => {
  337. if(child.meta){
  338. if(child.meta.navname == item.name){
  339. child.meta.keepAlive = false;
  340. }
  341. }
  342. })
  343. }
  344. })
  345. this.currLeftMenuId = item.name;
  346. sessionStorage.setItem("currLeftMenuId", item.name);
  347. console.log(item)
  348. if(item.path=="operatData"){
  349. this.$store.commit('setData',{
  350. name:'ele_operat_id',
  351. val:''
  352. })
  353. }
  354. this.$router.push({ path: '/plantGuard/'+item.path });
  355. },
  356. //添加tab标签
  357. add_tabs (data) {
  358. this.menuTabs.push(data)
  359. },
  360. //移除tab标签
  361. removeTab(targetName) {
  362. let tabs = this.menuTabs;
  363. let activeName = this.menuTabsValue;
  364. if (activeName === targetName) {
  365. tabs.forEach((tab, index) => {
  366. if (tab.name === targetName) {
  367. let nextTab = tabs[index + 1] || tabs[index - 1];
  368. if (nextTab) {
  369. activeName = nextTab.name;
  370. this.$router.push({ path: nextTab.path });
  371. this.menuList.forEach((item)=>{
  372. if(item.name == nextTab.par){
  373. this.leftMenuList = item.children;
  374. sessionStorage.setItem("leftMenuList", JSON.stringify(item.children));
  375. }
  376. })
  377. this.currTopMenuId=nextTab.par;
  378. this.currLeftMenuId=nextTab.name;
  379. sessionStorage.setItem("currLeftMenuId", nextTab.name);
  380. }
  381. }
  382. });
  383. }
  384. this.menuTabsValue = activeName;
  385. this.menuTabs = tabs.filter(tab => tab.name !== targetName);
  386. },
  387. //切换标签
  388. clickTab(tab) {
  389. console.log('tab')
  390. console.log(tab)
  391. this.$router.options.routes.forEach(route => {
  392. if(route.children && route.children.length){
  393. route.children.forEach(child => {
  394. if(child.meta){
  395. if(child.meta.navname == this.menuTabs[tab.index].name){
  396. child.meta.keepAlive = true;
  397. }
  398. }
  399. })
  400. }
  401. })
  402. this.$router.push({path: this.menuTabs[tab.index].path})
  403. this.menuList.forEach((item)=>{
  404. if(item.name == this.menuTabs[tab.index].par){
  405. this.leftMenuList = item.children;
  406. sessionStorage.setItem("leftMenuList", JSON.stringify(item.children));
  407. }
  408. })
  409. this.menuTabsValue = this.menuTabs[tab.index].name
  410. this.currTopMenuId=this.menuTabs[tab.index].par;
  411. this.currLeftMenuId=this.menuTabs[tab.index].name;
  412. sessionStorage.setItem("currLeftMenuId", this.menuTabs[tab.index].name);
  413. },
  414. // 获取用户主题
  415. getUserInfo() {
  416. this.$axios({
  417. method: "POST",
  418. url: "/api/api_gateway?method=home.homes.user_theme",
  419. }).then((res) => {
  420. if (res.data.message == "") {
  421. this.loginInfo = res.data.data[0];
  422. } else {
  423. this.$message.error(res.data.message);
  424. }
  425. });
  426. },
  427. // 获取用户菜单列表
  428. getNavList() {
  429. this.$axios({
  430. method: "POST",
  431. url: "/api/api_gateway?method=user.login.user_login_info",
  432. }).then((res) => {
  433. if (res.data.message == "") {
  434. var menuLists=res.data.data.children;
  435. let userType = res.data.data.myuser_type; //用户类型 管理员1 普通用户4
  436. let userName = res.data.data.username; //用户名
  437. let myuid = res.data.data.myuid; //用户id
  438. this.$store.commit('setData',{
  439. name:'myuser_type',
  440. val:userType
  441. })
  442. this.$store.commit('setData',{
  443. name:'user_id',
  444. val:myuid
  445. })
  446. console.log(menuLists);
  447. if(userType == 4){
  448. menuLists.forEach((item,index)=>{
  449. console.log(item);
  450. console.log(index);
  451. if(item.name == '农林植保'){
  452. item.children = [{
  453. "name": "植保示范点",
  454. "path": "base",
  455. "pur_id": "100"
  456. }]
  457. }
  458. if(item.name == '灾害预警'){
  459. item.children = [{
  460. "name": "预警示范点",
  461. "path": "disasterWarn",
  462. "pur_id": "101"
  463. }]
  464. }
  465. if(item.name == '智能灌溉'){
  466. item.children = [{
  467. "name": "灌溉示范点",
  468. "path": "irrigate",
  469. "pur_id": "102"
  470. }]
  471. }
  472. })
  473. console.log(menuLists);
  474. if(menuLists[0].children){
  475. var path = "/plantGuard/"+menuLists[0].children[0].path;
  476. var name = menuLists[0].children[0].name;
  477. var parName = menuLists[0].name;
  478. this.menuTabs = [{ "path": path, "name": name, "par": parName, "order": 0}]
  479. }else{
  480. for(var i = 0;i<menuLists.length;i++){
  481. if(menuLists[i].children){
  482. var path = "/plantGuard/"+menuLists[i].children[0].path;
  483. var name = menuLists[i].children[0].name;
  484. var parName = menuLists[i].name;
  485. this.menuTabs = [{ "path": path, "name": name, "par": parName, "order": i}];
  486. break;
  487. }
  488. }
  489. }
  490. }else{
  491. var path = "/plantGuard/"+menuLists[0].children[0].path;
  492. var name = menuLists[0].children[0].name;
  493. var parName = menuLists[0].name;
  494. this.menuTabs = [{ "path": path, "name": name, "par": parName, "order": 0}]
  495. }
  496. // if(menuLists[0].name=='农林植保'){
  497. // if(userType == 4){
  498. // menuLists[0].children= [
  499. // {
  500. // "name": "植保示范点",
  501. // "path": "base",
  502. // "id": "2"
  503. // }
  504. // ]
  505. // this.menuTabs = [{ "path": "/plantGuard/base", "name": "植保示范点", "par": "农林植保", "order": 0 }]
  506. // }else{
  507. // menuLists[0].children= [
  508. // {
  509. // "name": "植保监测",
  510. // "path": "baseAll",
  511. // "id": "19"
  512. // },
  513. // ]
  514. // this.menuTabs = [{ "path": "/plantGuard/baseAll", "name": "植保监测", "par": "农林植保", "order": 0 }]
  515. // }
  516. // }
  517. this.menuList = menuLists;
  518. console.log(this.menuList);
  519. }
  520. });
  521. },
  522. dropdownHandle(command) {
  523. if (command == "editPwd") {
  524. this.changePass();
  525. } else if (command == "outSys") {
  526. this.outSys();
  527. } else {
  528. this.$router.push({ path: "/plantGuard/personMsg" });
  529. }
  530. },
  531. outSys() {
  532. this.$axios({
  533. method: "POST",
  534. url: "/api/api_gateway?method=user.login.logout_user",
  535. }).then((res) => {
  536. if (res.data.message == "") {
  537. window.sessionStorage.clear()
  538. window.localStorage.clear()
  539. this.$router.push("/login");
  540. }
  541. });
  542. },
  543. changePass() {
  544. this.resetPassDialogVisible = true;
  545. },
  546. resetPassSubm() {
  547. this.$refs.resetPassFormRef.validate((valid) => {
  548. if (!valid) return;
  549. this.$axios({
  550. method: "POST",
  551. url: "/api/api_gateway?method=user.login.changepwd",
  552. data: this.qs.stringify({
  553. old_password: this.resetPassForm.oldPass,
  554. new_password: this.resetPassForm.newPass,
  555. confirm_password: this.resetPassForm.checkNewPass,
  556. }),
  557. }).then((res) => {
  558. if (res.data.message == "") {
  559. this.$message({
  560. message: "密码修改成功!",
  561. type: "success",
  562. });
  563. this.resetPassDialogVisible = false;
  564. }
  565. });
  566. });
  567. },
  568. resetPassDialogClosed() {},
  569. },
  570. //生命周期 - 创建完成(可以访问当前this实例)
  571. created() {},
  572. //生命周期 - 挂载完成(可以访问DOM元素)
  573. mounted() {
  574. this.getNavList();
  575. this.getUserInfo();
  576. this.username = localStorage.getItem("cUsername");
  577. // window.addEventListener('beforeunload', e => this.beforeunloadHandler(e))
  578. },
  579. beforeCreate() {}, //生命周期 - 创建之前
  580. beforeMount() {}, //生命周期 - 挂载之前
  581. beforeUpdate() {}, //生命周期 - 更新之前
  582. updated() {}, //生命周期 - 更新之后
  583. beforeDestroy() {}, //生命周期 - 销毁之前
  584. destroyed() {
  585. // window.removeEventListener('beforeunload', e => this.beforeunloadHandler(e))
  586. }, //生命周期 - 销毁完成
  587. activated() {} //如果页面有keep-alive缓存功能,这个函数会触发
  588. };
  589. </script>
  590. <style scoped lang="less">
  591. @keyframes step {
  592. 0% {
  593. -webkit-transform: translateX(0);
  594. transform: translateX(0)
  595. }
  596. to {
  597. -webkit-transform: translate3d(-41.625rem, 0, 0);
  598. transform: translate3d(-41.625rem, 0, 0)
  599. }
  600. }
  601. .el-header {
  602. background-color: #182037;
  603. color: #eee;
  604. z-index: 3500;
  605. .headMenu {
  606. height: 80px;
  607. display: flex;
  608. justify-content: space-between;
  609. align-items: center;
  610. .logoinfo {
  611. >div{
  612. display: flex;
  613. align-items: center;
  614. }
  615. img {
  616. vertical-align: top;
  617. }
  618. span {
  619. font-size: .3rem;
  620. letter-spacing: .0375rem;
  621. margin-left: .125rem;
  622. }
  623. }
  624. .topMenu {
  625. height: 80px;
  626. display: flex;
  627. justify-content: space-between;
  628. align-items: center;
  629. li {
  630. cursor: pointer;
  631. // padding: 10px 0;
  632. // width: 100px;
  633. width: 1.3875rem;
  634. // text-align: center;
  635. margin: 0 .125rem;
  636. // line-height: 20px;
  637. height: 100%;
  638. display: flex;
  639. align-items: center;
  640. .navContent{
  641. width: 100%;
  642. position: relative;
  643. }
  644. .blueMenu{
  645. position: absolute;
  646. width: 100%;
  647. height: .4875rem;
  648. overflow: hidden;
  649. // background: url(../../../static/images/indexTab.png);
  650. img{
  651. width: 41.625rem;
  652. animation: step 5s steps(30) infinite;
  653. }
  654. }
  655. // .indexTabActive{
  656. // display: none;
  657. // }
  658. .a2{
  659. // display: none;
  660. visibility:hidden
  661. }
  662. .navTxt{
  663. line-height: .4875rem;
  664. padding-left: .375rem;
  665. font-size: .175rem;
  666. }
  667. }
  668. .active {
  669. // background: #0195ff;
  670. .a1{
  671. // display: none;
  672. visibility:hidden
  673. }
  674. .a2{
  675. // display: block;
  676. visibility:visible
  677. }
  678. }
  679. li:hover {
  680. .a1{
  681. // display: none;
  682. visibility:hidden
  683. }
  684. .a2{
  685. // display: block;
  686. visibility:visible
  687. }
  688. // background: #003e66;
  689. }
  690. }
  691. .userInfo {
  692. font-size: .175rem;
  693. .el-dropdown {
  694. color: #fff;
  695. cursor: pointer;
  696. margin-right: .125rem;
  697. }
  698. .exit {
  699. display: inline-block;
  700. font-size: .3rem;
  701. border-left: 1px solid #727272;
  702. padding-left: .1875rem;
  703. cursor: pointer;
  704. i{
  705. font-size: .25rem;
  706. }
  707. i:hover{
  708. color: #0195ff;
  709. }
  710. }
  711. }
  712. }
  713. }
  714. .el-aside {
  715. background-color: #182037;
  716. color: #eee;
  717. .leftMenu {
  718. text-align: center;
  719. li {
  720. padding: .125rem 0;
  721. cursor: pointer;
  722. line-height: .275rem;
  723. i{
  724. font-size: .325rem;
  725. line-height: 27px;
  726. }
  727. }
  728. li:hover {
  729. background: #000;
  730. }
  731. .active {
  732. background: #000;
  733. }
  734. }
  735. }
  736. .el-main {
  737. background-color: #fff;
  738. color: #333;
  739. padding: 0!important;
  740. .tabsNav{
  741. position: fixed;
  742. background: #fff;
  743. z-index: 3000;
  744. width: 100%;
  745. }
  746. .content{
  747. padding-top: 56px;
  748. height: calc(100vh - 136px);
  749. .innerMargin{
  750. padding: 0px 20px 20px;
  751. }
  752. }
  753. }
  754. /deep/.el-tabs__nav .el-tabs__item:nth-child(1) span{
  755. display: none;
  756. }
  757. /deep/.el-tabs__item.is-active,
  758. /deep/.el-tabs__item:hover{
  759. color: #0295ff;
  760. }
  761. /deep/.el-radio__input.is-checked .el-radio__inner{
  762. border-color: #0195ff;
  763. background: #0195ff;
  764. }
  765. /deep/.el-radio__input.is-checked + .el-radio__label {
  766. color: #0195ff;
  767. }
  768. .el-dropdown-menu{
  769. z-index:99999 !important
  770. }
  771. .el-dropdown-menu__item:not(.is-disabled):hover, .el-dropdown-menu__item:focus {
  772. background-color: #dff1ff;
  773. color: #0295ff;
  774. }
  775. </style>