index.vue 29 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078
  1. <!-- 首页模块 首页面 -->
  2. <template>
  3. <div class="home">
  4. <div class="body-middle"
  5. :class="{ 'body-middle-height': blockList[0].flag }">
  6. <div class="body-middle-left">
  7. <!-- 任务、消息、提醒、超期 -->
  8. <Panel :data-list="panelList"
  9. @click="gotoNewRw"></Panel>
  10. <div v-show="false">
  11. <el-input v-model="param"/>
  12. <el-button @click="openPort()">openPort</el-button>
  13. <el-button @click="closePort()">closePort</el-button>
  14. <div>{{text}}</div>
  15. </div>
  16. <img style='width:100%;margin-top:10px;' src="../../../public/img/tmt.gif" alt="">
  17. </div>
  18. </div>
  19. <div id="mapXY"></div>
  20. <!-- </ws-dialog> -->
  21. <!-- 第一次登陆的租户 -->
  22. <successfulDialog v-if="successfulDialog"
  23. :phone="phone"
  24. :successfulDialog="successfulDialog"
  25. @close="successfulDialogClose">
  26. </successfulDialog>
  27. <!-- 试用租户 -->
  28. <trialNotExpired v-if="trialNotExpired"
  29. :day="day"
  30. :phone="phone"
  31. :trialNotExpired="trialNotExpired"
  32. @close="trialNotExpiredClose">
  33. </trialNotExpired>
  34. </div>
  35. </template>
  36. <script>
  37. // import serialport from 'serialport'
  38. // 统计图start
  39. import maintenance from './components/maintenance'
  40. import shipCertificate from './components/shipCertificate'
  41. import sparePartsMaterial from './components/sparePartsMaterial'
  42. import procurement from './components/procurement'
  43. // 统计图end
  44. // 正式租户
  45. import successfulDialog from './components/successfulDialog'
  46. // 试用租户
  47. import trialNotExpired from './components/trialNotExpired'
  48. // 新 api
  49. import { noticeNumber, queryCircularManagementReceiveList, getStaffHomeShowList } from '@/model/home/index'
  50. import {
  51. getUserVesselList,
  52. findHottestRouting
  53. } from '@/model/indexRx'
  54. import News from './components/News'
  55. import ShipMap from './components/ShipMap'
  56. import { getCnCity, getCnWea } from './city'
  57. import { getLanguage } from '@/lang'
  58. import Panel from './components/Panel'
  59. import { getChangeLoginFlag } from '@/model/indexRx'
  60. import { zipDown } from '@/utils/batchDown'
  61. import { EventBus } from 'base-core-lib'
  62. import { mapActions, mapGetters, mapState } from 'vuex';
  63. export default {
  64. name: 'index',
  65. components: {
  66. News,
  67. ShipMap,
  68. Panel,
  69. successfulDialog,
  70. trialNotExpired,
  71. //统计图start
  72. maintenance,
  73. shipCertificate,
  74. sparePartsMaterial,
  75. procurement
  76. //统计图end
  77. },
  78. data () {
  79. return {
  80. showEchart: false,
  81. phone: '', // 正式租户电话号码
  82. day: '', //试用租户剩余天数
  83. trialNotExpired: false, //试用租户 剩余天数
  84. successfulDialog: false, //第一次登陆的弹窗
  85. mapXY: undefined,
  86. shipService: undefined,
  87. blockList: [
  88. {
  89. name: this.$t('home.shortcutEntrance'),
  90. flag: true
  91. },
  92. {
  93. name: this.$t('home.shipMap'),
  94. flag: true
  95. }
  96. ],
  97. newList: [],
  98. noticeList: [],
  99. routeList: [],
  100. showBlockList: [],
  101. shipList: [],
  102. setFlag: false,
  103. todoCount: '-',
  104. msgCount: '-',
  105. weather: undefined,
  106. ships: [],
  107. selectShip: undefined,
  108. isFullScreen: false,
  109. number: {
  110. task: 0,
  111. remind: 0,
  112. overdue: 0,
  113. news: 0
  114. },
  115. vesselBankFlag: sessionStorage.getItem('ws-pf_vesselBankFlag'),
  116. shezhiVal: '',
  117. text:'数据',
  118. reader:null,
  119. param:9600
  120. }
  121. },
  122. computed: {
  123. ...mapState({
  124. showVesslBankFlag: state => state.commonStore.showVesslBankFlag
  125. }),
  126. ...mapGetters(['userSetting']),
  127. /** 计算属性计算属性节点 */
  128. panelList () {
  129. return [
  130. {
  131. type: '0',
  132. task: this.$t('homeIndex.task'),
  133. url: require('@/assets/newhome/rw01.png'),
  134. number: this.number.task,
  135. background: require('@/assets/newhome/rw.png'),
  136. remark: '任务'
  137. },
  138. {
  139. type: 'message',
  140. task: this.$t('homeIndex.message'),
  141. url: require('@/assets/newhome/xx01.png'),
  142. number: this.number.news,
  143. background: require('@/assets/newhome/xx.png'),
  144. remark: '消息'
  145. },
  146. {
  147. type: '1',
  148. task: this.$t('homeIndex.remind'),
  149. url: require('@/assets/newhome/tx01.png'),
  150. number: this.number.remind,
  151. background: require('@/assets/newhome/tx.png'),
  152. remark: '提醒'
  153. },
  154. {
  155. type: '2',
  156. task: this.$t('homeIndex.beyond'),
  157. url: require('@/assets/newhome/cq01.png'),
  158. number: this.number.overdue,
  159. background: require('@/assets/newhome/cq.png'),
  160. remark: '超期'
  161. }
  162. ]
  163. },
  164. optionSingleHeightTime () {
  165. return {
  166. openWatch: true,
  167. limitMoveNum: -1, //启动无缝滚动最小数据量 this.dataList.length
  168. direction: 2,
  169. switchDelay: 1000
  170. }
  171. },
  172. getLanguage () {
  173. return this.$store.getters.language
  174. },
  175. isShowShipList () {
  176. return this.userSetting['shipMap'][0].showFlag && this.vesselBankFlag !== 'V' && this.permissionIf('map.mapManagement.view')
  177. },
  178. },
  179. async created () {
  180. //获取快捷路口列表
  181. this.getRouteList()
  182. // this.checkUserInfoDialog()
  183. },
  184. async mounted () {
  185. //获取新闻列表
  186. // this.getNewList()
  187. noticeNumber().toPromise().then(res => {
  188. const { task = 0, remind = 0, overdue = 0, news = 0 } = res
  189. this.number.task = task
  190. this.number.remind = remind
  191. this.number.overdue = overdue
  192. this.number.news = news
  193. })
  194. // if (this.vesselBankFlag !== 'V') {
  195. // EventBus.$emit('addShipScript', () => {
  196. // this.initShipMap()
  197. // })
  198. // }
  199. // setTimeout(() => {
  200. // this.showEchart = true
  201. // }, 900)
  202. // this.showBlockList = []
  203. // if (this.vesselBankFlag === 'V') {
  204. // this.$refs.noticeList.style.width = 'calc(50% - 7px)'
  205. // this.$refs.newsList.style.width = 'calc(50% - 7px)'
  206. // } else {
  207. // this.showBlockList = []
  208. // this.blockList[1].flag = false
  209. // this.$refs.noticeList.style.width = 'calc(50% - 7px)'
  210. // this.$refs.newsList.style.width = 'calc(50% - 7px)'
  211. // if (this.userSetting['shipMap'] && this.userSetting['shipMap'][0].showFlag) {
  212. // this.showBlockList.push('船舶动态')
  213. // this.blockList[1].flag = true
  214. // }
  215. // }
  216. },
  217. watch: {
  218. // getLanguage: function () {
  219. // this.getShipList()
  220. // }
  221. },
  222. methods: {
  223. ...mapActions('user', ['toSetShow', 'changeVesslBank']),
  224. // 下载通知通函
  225. downloadNotification (item) {
  226. zipDown({
  227. appendixIds: item.attachmentPath,
  228. baseUrl: this.$store.getters.baseInfo.fileUrl,
  229. zipName: item.theme
  230. })
  231. },
  232. /**
  233. * 校验各种弹框问题
  234. * @Desc 不是本人原意, 请不要骂我 谢谢. 请联系 "后台开发人员" 梳理逻辑
  235. */
  236. async checkUserInfoDialog () {
  237. const {
  238. statusFlag,
  239. loginInfo: { loginFlag = 0 },
  240. daysRemaining,
  241. customerServiceStaffPhone
  242. } = JSON.parse(sessionStorage.getItem('ws_login_getTenantInfoByUser'))
  243. if (statusFlag * 1 === 3) {
  244. // 判断后台返回的是空 还是 0 是空还是 0 的时候请求后台接口 不懂啥意思 为啥要这么弄
  245. if (!loginFlag && !sessionStorage.getItem('isShowTryUserDialog') * 1) {
  246. let newId = JSON.parse(sessionStorage.getItem('ws_login_accountId'))
  247. this.phone = customerServiceStaffPhone
  248. this.successfulDialog = true
  249. sessionStorage.setItem('isShowTryUserDialog', '1')
  250. await getChangeLoginFlag({ accountId: newId }).toPromise()
  251. }
  252. }
  253. // 试用租户
  254. const dayDialog = [30, 15, 7, 5, 3, 2, 1, 0]
  255. if (statusFlag * 1 === 2 && dayDialog.indexOf(daysRemaining) > -1 && !sessionStorage.getItem('isShowTryUserDialog') * 1) {
  256. this.day = daysRemaining
  257. this.phone = customerServiceStaffPhone
  258. this.trialNotExpired = true
  259. sessionStorage.setItem('isShowTryUserDialog', '1')
  260. }
  261. },
  262. trialNotExpiredClose () {
  263. this.trialNotExpired = false
  264. },
  265. //第一次登陆的弹窗
  266. successfulDialogClose () {
  267. this.successfulDialog = false
  268. },
  269. initShipMap () {
  270. var options = {
  271. ak: '57df9eaa033b44809d4bdaf919af457e',
  272. // 初始中心点坐标
  273. centerPoint: [30.171, 121.27],
  274. zoom: 3,
  275. minZoom: 2,
  276. maxZoom: 18,
  277. defaultMapType: 'MT_SEA', //默认海图
  278. // 公司版权信息( 支持html ),默认Elane Inc.
  279. attribution: {
  280. isShow: false,
  281. emptyString:
  282. '&copy;2019 <a class="shipxy_small"></a>&nbsp;<a>WinSea Inc.</a>'
  283. },
  284. measureCtrl: { isShow: false },
  285. mousePostionCtrl: { isShow: false },
  286. zoomControlElane: { isShow: true, position: 'bottomright' },
  287. zoomviewControl: { isShow: false, position: 'bottomright' },
  288. basemapsControl: { isShow: false, position: 'topright' },
  289. scaleCtrl: { isShow: true, position: 'bottomleft' }
  290. }
  291. // 创建地图示例
  292. // eslint-disable-next-line no-undef
  293. this.mapXY = new ShipxyAPI.Map('mapXY', options)
  294. // eslint-disable-next-line no-undef
  295. this.shipService = ShipxyAPI.ShipService(this.mapXY, {
  296. enableAreaShip: false,
  297. enableFleetShip: false,
  298. isAutoUpdateSrvtime: false,
  299. // delayTime: 5000,
  300. lableFont: ['500 12px Arial', '500 12px 宋体'], // 船舶名称,文字字体,默认值:["600 12px Arial", "500 12px Arial"]
  301. lableTxtColor: ['#fff', '#fff'], // 船舶名称,文字颜色,默认值:["#000","#fff"]
  302. lableLineColor: ['rgba(1, 30, 62, 0)', 'rgba(1, 30, 62, 0)'], // 边框颜色,默认值:["#000","#000"]
  303. lableLinefillColor: ['rgba(0, 0, 0, 0.6)', 'rgba(0, 0, 0, 0.6)'], // 框内填充颜色,默认值:[null,null]
  304. obliqueLineColor: ['#000', '#000'], // 船舶名称,斜线颜色,默认值:[null,null]
  305. dShipColor: '#FF6437', // D+船颜色,默认:#ff6347
  306. zoomLevel_data: 1,
  307. zoomLevel_base: 1,
  308. getAreaShipsCallBack: (call) => {
  309. // console.info(call, 'getAreaShipsCallBack')
  310. },
  311. drawShipsEndCallBack: (call) => {
  312. // console.info(call, 'drawShipsEndCallBack')
  313. }
  314. })
  315. this.shipService.setPointerEvents(true)
  316. window.shipService = this.shipService
  317. //获取船舶列表
  318. this.getShipList()
  319. },
  320. toRoute (url) {
  321. this.$router.push(url)
  322. },
  323. toSetShow () {
  324. this.showBlockList = []
  325. this.setFlag = true
  326. // getStaffHomeShowList({
  327. // staffId: sessionStorage.getItem('ws-pf_userId')
  328. // }).toPromise().then(data => {
  329. // for (let i = 0; i < data.length; i++) {
  330. // if (data[i].typeId === 'shipMap' && data[i].showFlag) {
  331. // this.showBlockList.push('船舶动态')
  332. // } else {
  333. // this.showBlockList = []
  334. // }
  335. // }
  336. // })
  337. },
  338. toMap () {
  339. this.$router.push('/map/trajectory_child')
  340. },
  341. goNews () {
  342. this.$router.push('/news/noticeType')
  343. },
  344. goNewsDetail (id) {
  345. this.$router.push('/news/noticeDetails?id=' + id)
  346. },
  347. goNotice (data) {
  348. this.$router.push({
  349. name: 'notificationItDetail',
  350. query: { id: data.id }
  351. })
  352. },
  353. goNoticeMore () {
  354. this.$router.push('/notice/notificationCircularReleasedIt_child')
  355. },
  356. toHide (index) {
  357. this.changeVesslBank([{
  358. id: this.userSetting['shipMap'][0].id,
  359. staffId: sessionStorage.getItem('ws-pf_userId'),
  360. typeId: 'shipMap',
  361. showFlag: false
  362. }])
  363. },
  364. getRouteList () {
  365. let data = {
  366. accountId: sessionStorage.getItem('ws-pf_userId'),
  367. pageSize: 30
  368. }
  369. findHottestRouting(data).toPromise().then(res => {
  370. this.routeList = res
  371. if (res.length == 0) {
  372. this.blockList[0].flag = false
  373. }
  374. })
  375. },
  376. //获取新闻
  377. getNewList () {
  378. let data = {
  379. currentPage: 1,
  380. pageSize: 2,
  381. loginUserId: sessionStorage.getItem('ws-pf_userId'),
  382. compId: sessionStorage.getItem('ws-pf_compId'),
  383. releaseFlag: 0
  384. }
  385. // queryHomePage(data).toPromise().then(resNewList => {
  386. // for (let i of resNewList) {
  387. // i.content = '<p>' + i.content.replace(/<[^>]+>/g, '') + '</p>'
  388. // }
  389. // this.newList = resNewList
  390. // for (let i of this.newList) {
  391. // if (i.ossCoverUrl && i.ossCoverUrl.length > 0) {
  392. // } else {
  393. // this.$set(
  394. // i,
  395. // 'imgUrl',
  396. // require('@/assets/images/page/home/noImg.png')
  397. // )
  398. // }
  399. // }
  400. // })
  401. },
  402. //获取通知通函
  403. // getNoticeList () {
  404. // let pagesize = Math.floor((this.$refs.noticeList.clientHeight - 44) / 80)
  405. // let data = {
  406. // currentPage: 1,
  407. // pageSize: pagesize || 3,
  408. // vesselDeptId:
  409. // sessionStorage.getItem('ws-pf_vesselBankFlag') === 'V'
  410. // ? sessionStorage.getItem('ws-pf_vesselId')
  411. // : sessionStorage.getItem('ws-pf_deptId'),
  412. // compId: sessionStorage.getItem('ws-pf_compId')
  413. // }
  414. // // TODO: 【此处有问题】接口变更的不对
  415. // queryCircularManagementReceiveList(data)
  416. // .toPromise()
  417. // .then(response => {
  418. // this.noticeList = response.records
  419. // })
  420. // },
  421. // 获取船舶状态
  422. getNaviStatusStr (t) {
  423. var array = [
  424. this.$t('home.navistatus0'),
  425. this.$t('home.navistatus1'),
  426. this.$t('home.navistatus2'),
  427. this.$t('home.navistatus3'),
  428. this.$t('home.navistatus4'),
  429. this.$t('home.navistatus5'),
  430. this.$t('home.navistatus6'),
  431. this.$t('home.navistatus7'),
  432. this.$t('home.navistatus8')
  433. ]
  434. if (t >= 0 && t <= 8) {
  435. return array[t]
  436. }
  437. return ''
  438. },
  439. // 获取船舶状态
  440. getNaviStatusBg (t) {
  441. var array = [
  442. 'bg0',
  443. 'bg1',
  444. 'bg2',
  445. 'bg3',
  446. 'bg4',
  447. 'bg5',
  448. 'bg6',
  449. 'bg7',
  450. 'bg8'
  451. ]
  452. if (t >= 0 && t <= 8) {
  453. return array[t]
  454. }
  455. return ''
  456. },
  457. getShipList () {
  458. getUserVesselList({ vesselStatus: 'UNDER_CONTROL' }).toPromise().then(res => {
  459. this.shipList = []
  460. let num = res.length > 10 ? 10 : res.length
  461. let obj = {}
  462. for (let i = 0; i < num; i++) {
  463. if (res[i].mmsiCode && res[i].mmsiCode.length > 0) {
  464. obj = this.shipService.getShipByMmsi(res[i].mmsiCode)
  465. ? this.shipService.getShipByMmsi(res[i].mmsiCode)
  466. : {}
  467. obj.vesselName = res[i].vesselName
  468. this.shipList.push(obj)
  469. }
  470. }
  471. //我想不出还有什么招了:临时解决办法
  472. const oldList = this.shipList
  473. for (let i = 1; i < 5; i++) {
  474. oldList.forEach(item => {
  475. this.shipList.push(item)
  476. })
  477. }
  478. })
  479. },
  480. onTodoClick () {
  481. this.$router.push({ name: 'workNotification' })
  482. },
  483. onMsgClick () {
  484. this.$router.push({ name: 'message' })
  485. },
  486. onChange (list) { },
  487. onShipMenuItemClick (ship) {
  488. this.selectShip = ship
  489. if (ship) {
  490. this.$refs.shipMap.selectShip(ship.id)
  491. } else {
  492. this.$refs.shipMap.unSelectShip()
  493. }
  494. },
  495. onFullScreen () {
  496. this.isFullScreen = !this.isFullScreen
  497. },
  498. onNoticeMoreBtnClick () {
  499. this.$router.push({
  500. name: 'notice'
  501. })
  502. },
  503. onShipSelectEvent (shipid) {
  504. this.selectShip = this.ships.find(item => {
  505. return item.id == shipid
  506. })
  507. },
  508. getCityName (encity) {
  509. if (getLanguage() === 'zh') {
  510. return getCnCity(encity)
  511. }
  512. return encity
  513. },
  514. getWeaName (enwea) {
  515. if (getLanguage() === 'zh') {
  516. return getCnWea(enwea)
  517. }
  518. return enwea
  519. },
  520. gotoNewRw (data) {
  521. if (data === 'message') {
  522. this.$router.push({ name: 'message', query: { types: data } })
  523. } else {
  524. this.$router.push({ name: 'workNotification', query: { types: data } })
  525. }
  526. },
  527. test(){
  528. console.log('testtesttesttest');
  529. },
  530. async test1(){
  531. console.log('testtesttesttest111111');
  532. },
  533. async openPort(){
  534. console.log('openPort',navigator);
  535. if ('serial' in navigator) {
  536. // The Web Serial API is supported.
  537. console.log('the Web Serial API is supported.');
  538. console.log(this.param);
  539. const port = await navigator.serial.requestPort();
  540. await port.open({ baudRate: this.param }); // set baud rate
  541. this.reader = port.readable.getReader();
  542. // 监听来自串行设备的数据
  543. while (true) {
  544. const { value, done } = await this.reader.read();
  545. if (done) {
  546. // 允许稍后关闭串口。
  547. this.reader.releaseLock();
  548. break;
  549. }
  550. console.log('value:',value);
  551. var result='';
  552. //2。获取16进制字符串
  553. // var receData = HexConvert.ByteToString(value);
  554. // console.log("receData",receData);
  555. var flag = false;
  556. for(var i=0;i<value.length;i++){
  557. console.log('value[0]',value[0])
  558. var tmp = String.fromCharCode(value[i])
  559. if(value[0] != 49 && value[0] != 2){
  560. break
  561. }
  562. if (tmp == String.fromCharCode(32) ) {
  563. flag = true
  564. }
  565. if (flag && result.length < 7 && tmp != String.fromCharCode(32)) {
  566. // if(i-1 >=0 &&tmp == String.fromCharCode(48) && value[i-1] == 32){
  567. // continue
  568. // }
  569. // if(i-2 >=0 &&tmp == String.fromCharCode(48) && value[i-2] == 32){
  570. // continue
  571. // }
  572. result += tmp
  573. }
  574. }
  575. setTimeout(1000)
  576. if(parseInt(result)){
  577. console.log('result:',result);
  578. this.text = parseInt(result)*100
  579. }
  580. console.log('this.text:',this.text);
  581. // value 是一个 Uint8Array
  582. }
  583. await port.close();
  584. }
  585. else{
  586. console.log('the Web Serial API is not supported.',navigator);
  587. }
  588. },
  589. async closePort(){
  590. console.log('closePort');
  591. this.reader.cancel()
  592. }
  593. }
  594. }
  595. </script>
  596. <style lang="scss" scoped>
  597. .home {
  598. padding: 10px;
  599. overflow-y: auto;
  600. // background-color: #eee;
  601. width: 100%;
  602. height: calc(100vh - 60px);
  603. .set-img {
  604. width: 25px;
  605. height: 25px;
  606. position: fixed;
  607. right: 0;
  608. bottom: 99px;
  609. z-index: 1000;
  610. }
  611. .shortcut-entrance {
  612. width: 100%;
  613. height: 60px;
  614. background: #fff;
  615. margin-bottom: 10px;
  616. padding: 0 20px;
  617. line-height: 60px;
  618. display: flex;
  619. justify-content: space-between;
  620. align-items: center;
  621. .shortcut-entrance-left {
  622. font-size: 16px;
  623. font-weight: bold;
  624. color: #333333;
  625. width: 50%;
  626. overflow: hidden;
  627. height: 100%;
  628. }
  629. .shortcut-entrance-right {
  630. width: 14px;
  631. height: 14px;
  632. }
  633. }
  634. .body-middle {
  635. display: flex;
  636. width: 100%;
  637. height: calc(100vh - 60px);
  638. .body-middle-left {
  639. width: 100%;
  640. // margin-right: 10px;
  641. .panel-list {
  642. display: flex;
  643. color: #ffffff;
  644. text-shadow: 0px 1px 1px rgba(111, 52, 0, 0.55);
  645. }
  646. .ship-list-body {
  647. position: relative;
  648. width: 300px;
  649. margin-top: 10px;
  650. .shipList-box {
  651. width: 85%;
  652. margin: 0 auto;
  653. .shipList-icon {
  654. position: absolute;
  655. top: 6px;
  656. left: 0px;
  657. }
  658. .shipList-name {
  659. cursor: context-menu;
  660. font-size: 16px;
  661. font-weight: bold;
  662. line-height: 26px;
  663. color: #333333;
  664. max-width: 100px;
  665. white-space: nowrap;
  666. overflow: hidden;
  667. text-overflow: ellipsis;
  668. }
  669. .shipList-address {
  670. cursor: context-menu;
  671. font-size: 14px;
  672. color: #666666;
  673. line-height: 35px;
  674. }
  675. .shipList-time {
  676. cursor: context-menu;
  677. font-size: 14px;
  678. color: #666666;
  679. line-height: 20px;
  680. }
  681. .ship-list-status {
  682. cursor: context-menu;
  683. margin-left: 20px;
  684. padding: 5px 10px;
  685. border-radius: 20px;
  686. color: #fff;
  687. max-width: 90px;
  688. white-space: nowrap;
  689. overflow: hidden;
  690. text-overflow: ellipsis;
  691. }
  692. .bg0 {
  693. background: #7ed321;
  694. }
  695. .bg1 {
  696. background: #ff8f00;
  697. }
  698. .bg2 {
  699. background: #495b61;
  700. }
  701. .bg3 {
  702. background: #4fc3f7;
  703. }
  704. .bg4 {
  705. background: #26a69a;
  706. }
  707. .bg5 {
  708. background: #9c7fee;
  709. }
  710. .bg6 {
  711. background: #ff5722;
  712. }
  713. .bg7 {
  714. background: #8d6e63;
  715. }
  716. .bg8 {
  717. background: #fadd60;
  718. }
  719. }
  720. }
  721. .notice-list {
  722. width: calc(50% - 7px);
  723. background: #fff;
  724. margin-top: 10px;
  725. // height: calc(100% - 180px);
  726. // min-height: 460px;
  727. border-radius: 4px;
  728. // float: left;
  729. }
  730. .news-list {
  731. width: calc(50% - 7px);
  732. // float: left;
  733. background: #fff;
  734. margin-top: 10px;
  735. // height: calc(100% - 180px);
  736. height: 285px;
  737. overflow: hidden;
  738. // min-height: 460px;
  739. border-radius: 4px;
  740. // margin-right: 10px;
  741. .new-list-box {
  742. padding: 0 10px;
  743. .new-list-body:first-child {
  744. padding-bottom: 20px;
  745. border-bottom: 1px solid #eeeeee;
  746. }
  747. .new-list-body:last-child {
  748. padding-top: 20px;
  749. }
  750. }
  751. .new-list-body {
  752. width: 100%;
  753. padding: 10px 0;
  754. display: flex;
  755. border-bottom: 1px solid #eeeeee;
  756. // height: 50%;
  757. overflow: hidden;
  758. // padding: 10px;
  759. // display: flex;
  760. .new-list-img {
  761. // height: 100%;
  762. width: 160px;
  763. height: 100px;
  764. position: relative;
  765. // margin-right: 20px;
  766. .newsTJ {
  767. position: absolute;
  768. width: 54px;
  769. height: 50px;
  770. left: 0;
  771. top: 0;
  772. }
  773. img {
  774. width: 100%;
  775. height: 100%;
  776. display: block;
  777. }
  778. }
  779. .new-list-title {
  780. color: #343434;
  781. line-height: 30px;
  782. font-size: 14px;
  783. font-weight: bold;
  784. overflow: hidden;
  785. text-overflow: ellipsis;
  786. white-space: nowrap;
  787. span {
  788. cursor: pointer;
  789. display: block;
  790. }
  791. }
  792. .new-list-content {
  793. color: #666666;
  794. font-size: 12px;
  795. line-height: 16px;
  796. display: -webkit-box;
  797. -webkit-box-orient: vertical;
  798. -webkit-line-clamp: 3;
  799. overflow: hidden;
  800. height: 48px;
  801. span {
  802. cursor: pointer;
  803. display: block;
  804. }
  805. }
  806. .new-list-date {
  807. color: #999999;
  808. font-size: 12px;
  809. text-align: right;
  810. line-height: 22px;
  811. span {
  812. cursor: pointer;
  813. display: block;
  814. }
  815. }
  816. }
  817. // .new-list-body:hover {
  818. // background: #e2edfa;
  819. // cursor: pointer;
  820. // }
  821. .no-line {
  822. border-bottom: 0px solid #eeeeee;
  823. }
  824. }
  825. .v-width {
  826. width: calc(50% - 7px);
  827. }
  828. }
  829. .body-middle-right {
  830. width: calc(30% - 10px);
  831. .notice-list {
  832. height: 50%;
  833. background: #fff;
  834. width: 100%;
  835. min-height: 300px;
  836. border-radius: 4px;
  837. .notice-list-body {
  838. border-bottom: 1px solid #eeeeee;
  839. padding: 20px 10px;
  840. .notice-list-title {
  841. color: #333333;
  842. font-size: 14px;
  843. font-weight: bold;
  844. line-height: 18px;
  845. overflow: hidden;
  846. text-overflow: ellipsis;
  847. white-space: nowrap;
  848. }
  849. .notice-list-type {
  850. margin: 9px 0 12px 0;
  851. color: #666666;
  852. }
  853. .notice-list-person {
  854. color: #666666;
  855. font-size: 12px;
  856. }
  857. .notice-list-date {
  858. color: #666666;
  859. font-size: 12px;
  860. margin-top: 10px;
  861. }
  862. }
  863. .notice-list-body:hover {
  864. background: #e2edfa;
  865. cursor: pointer;
  866. }
  867. .notice-body-height {
  868. height: 50%;
  869. }
  870. .notice-body-height1 {
  871. height: 20%;
  872. }
  873. }
  874. .notice-list-height {
  875. height: 100%;
  876. min-height: 638px;
  877. }
  878. .ship-list {
  879. height: calc(50% - 10px);
  880. margin-top: 10px;
  881. background: #fff;
  882. width: 100%;
  883. min-height: 327px;
  884. border-radius: 4px;
  885. .ship-list-body {
  886. padding: 20px 0;
  887. border-bottom: 1px solid #eeeeee;
  888. .ship-list-head {
  889. display: flex;
  890. img {
  891. width: 14px;
  892. height: 14px;
  893. }
  894. .ship-list-name {
  895. margin: 0 20px;
  896. font-weight: bold;
  897. }
  898. .ship-list-status {
  899. border-radius: 10px;
  900. padding: 4px 8px;
  901. color: #ffffff;
  902. }
  903. .bg0 {
  904. background: #7ed321;
  905. }
  906. .bg1 {
  907. background: #ff8f00;
  908. }
  909. .bg2 {
  910. background: #495b61;
  911. }
  912. .bg3 {
  913. background: #4fc3f7;
  914. }
  915. .bg4 {
  916. background: #26a69a;
  917. }
  918. .bg5 {
  919. background: #9c7fee;
  920. }
  921. .bg6 {
  922. background: #ff5722;
  923. }
  924. .bg7 {
  925. background: #8d6e63;
  926. }
  927. .bg8 {
  928. background: #fadd60;
  929. }
  930. }
  931. .ship-list-address {
  932. margin: 10px 0 10px 34px;
  933. color: #666666;
  934. }
  935. .ship-list-date {
  936. color: #666666;
  937. margin-left: 34px;
  938. }
  939. }
  940. /*.ship-list-body:hover{*/
  941. /* background: #e2edfa;*/
  942. /*}*/
  943. }
  944. }
  945. }
  946. .body-middle-height {
  947. height: calc(100vh - 70px);
  948. }
  949. .list-title {
  950. width: 100%;
  951. // background: #f3f9fe;
  952. background: url('~@/assets/newhome/titilebg.png') no-repeat;
  953. background-size: 100% 100%;
  954. height: 44px;
  955. padding: 0 20px;
  956. display: flex;
  957. line-height: 44px;
  958. justify-content: space-between;
  959. border-radius: 4px 4px 0 0;
  960. .list-title-name {
  961. font-size: 16px;
  962. font-weight: bold;
  963. color: #333333;
  964. }
  965. .list-title-more {
  966. font-size: 14px;
  967. color: #666666;
  968. cursor: pointer;
  969. display: flex;
  970. }
  971. }
  972. }
  973. .el-dropdown-menu {
  974. margin-top: -20px !important;
  975. /*left: 1872px !important;*/
  976. }
  977. .seamless-warp {
  978. // width: 100%;
  979. width: 100%;
  980. overflow: hidden;
  981. margin-top: 10px;
  982. }
  983. .home-tzthList:nth-of-type(3) {
  984. border: none;
  985. }
  986. .home-tzthList {
  987. display: flex;
  988. padding: 10px;
  989. border-bottom: 1px solid #eeeeee;
  990. .home-tzthList-type {
  991. width: 100%;
  992. display: flex;
  993. font-size: 14px;
  994. line-height: 28px;
  995. font-weight: bold;
  996. .home-tzthList-type-title {
  997. color: #343434;
  998. margin: 0;
  999. span {
  1000. cursor: pointer;
  1001. }
  1002. }
  1003. .home-tzthList-type-theme {
  1004. color: #666666;
  1005. margin: 0;
  1006. width: 80%;
  1007. overflow: hidden;
  1008. white-space: nowrap;
  1009. text-overflow: ellipsis;
  1010. span {
  1011. cursor: pointer;
  1012. }
  1013. }
  1014. }
  1015. .home-tzthList-people {
  1016. display: flex;
  1017. justify-content: space-between;
  1018. line-height: 22px;
  1019. .home-tzthList-Personnel,
  1020. .home-tzthList-timer {
  1021. font-size: 12px;
  1022. color: #666666;
  1023. span {
  1024. cursor: pointer;
  1025. }
  1026. }
  1027. }
  1028. }
  1029. .noMore {
  1030. position: absolute;
  1031. margin: auto;
  1032. top: 0;
  1033. bottom: 0;
  1034. left: 0;
  1035. right: 0;
  1036. }
  1037. .ship-list {
  1038. width: 100%;
  1039. border-radius: 4px;
  1040. background-color: #fff;
  1041. }
  1042. //新增的图表的样式
  1043. .chart {
  1044. display: flex;
  1045. flex-wrap: wrap;
  1046. justify-content: space-between;
  1047. margin-bottom: 10px;
  1048. }
  1049. .home-tzthList-timer-left {
  1050. width: 10%;
  1051. display: flex;
  1052. align-items: center;
  1053. img {
  1054. cursor: pointer;
  1055. width: 24px;
  1056. height: 24px;
  1057. display: block;
  1058. align-items: center;
  1059. margin: 0 auto;
  1060. }
  1061. }
  1062. </style>