device.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811
  1. <template>
  2. <div class="device-layout">
  3. <div class="d-header">
  4. <ul class="tab-list">
  5. <li @click="tabActive = item.id" :class="{active:tabActive === item.id}" v-for="(item,i) in langDevices.tabList" :key="i">
  6. {{item.name}}({{i===0?allTotal:xiezuoNum}})
  7. </li>
  8. </ul>
  9. <div class="rig-con">
  10. <div class="btns" v-if="tabActive===4&&!isImgType">
  11. <span class="button" @click="addDevice"><i class="iconfont icon-jiahao"></i>{{langDevices.add}}</span>
  12. <span class="button" @click="multCop">{{langDevices.fenpei}}</span>
  13. <span class="button default" @click="multDel">{{langDevices.unbind}}</span>
  14. </div>
  15. <div class="tab-search" :style="{marginRight:isWide?'0':'149px'}">
  16. <input v-model="searchKey" @keyup.enter="getList(searchKey)" type="text" :placeholder="langDevices.placeholder.searchID">
  17. <i class="iconfont icon-sousuo" @click="getList(searchKey)"></i>
  18. </div>
  19. <div class="main-list" v-if="tabActive===4">
  20. <i @click="changeType(true)" class="iconfont icon-main_grid" :title="langDevices.pictle" :class="{active:isImgType}"></i>
  21. <i @click="changeType(false)" class="iconfont icon-main_list" :title="langDevices.listtle" :class="{active:!isImgType}"></i>
  22. </div>
  23. </div>
  24. </div>
  25. <div class="d-con" v-if="isImgType||tabActive===0">
  26. <div class="edit-item item" @click="addDevice">
  27. <div class="plus-con">
  28. <div class="iconplus">
  29. <span></span>
  30. <span></span>
  31. </div>
  32. <p>{{langDevices.add}}</p>
  33. </div>
  34. </div>
  35. <template v-if="!loading" >
  36. <div class="d-item item" :style="{padding:language==='en'?'10px 16px':'10px 24px 10px 30px'}" v-for="(item,i) in mydevice.list" :key="i">
  37. <template v-if="tabActive===4">
  38. <div v-if="item.isExpire&&(item.usedSpace<=item.totalSpace)" class="tag expire">{{langDevices.jijiang}}</div>
  39. <div v-if="item.usedSpace>item.totalSpace" class="tag full">{{langDevices.rongliang}}</div>
  40. </template>
  41. <div class="i-left" :style="{marginTop:tabActive===4?'15px':'25px'}">
  42. <template v-if="tabActive===4">
  43. <p class="d-id" :title="item.snCode||(item.childName&&item.childName.replace('4DKKPRO_',''))||'--'">S/N: {{item.snCode||(item.childName&&item.childName.replace('4DKKPRO_',''))||'--'}} </p>
  44. <p class="p-sub" style="padding-left: 26px;" :title="`${item.usedSpaceStr} / ${item.totalSpaceStr}`">
  45. <img :src="`${$cdn}images/icon-cloud.png`" alt="">
  46. {{item.usedSpaceStr}} / {{item.totalSpaceStr}}
  47. </p>
  48. <div class="capacity">
  49. <div class="c-line">
  50. <div class="active" :style="{width:getBar(item.usedSpace,item.totalSpace),background:getColor(item.usedSpace,item.totalSpace)}"></div>
  51. </div>
  52. </div>
  53. <p class="p-sub">{{langDevices.expand}}{{item.spaceStr||'--'}}</p>
  54. <p class="p-sub">{{langDevices.expire}}{{item.spaceEndStr||'--'}}</p>
  55. <p class="p-sub" :title="item.cooperationUserName" v-if="item.cooperationUserName">{{langDevices.xiezuo}}{{item.cooperationUserName||'--'}}</p>
  56. <div class="oper-con">
  57. <div class="oper">
  58. <div>
  59. <span class="spot"></span>
  60. </div>
  61. <ul :style="{minWidth: language==='en'?'150px': '90px'}">
  62. <li @click="$router.push({name:'introduce',params:{id:item.childName}})">
  63. {{langDevices.capacity}}
  64. </li>
  65. <li @click="unbind(item)">{{langDevices.unbind}}</li>
  66. <li v-if="item.status !== 0" @click="handleCooperation(item)">{{langDevices.fenpei}}</li>
  67. </ul>
  68. </div>
  69. </div>
  70. </template>
  71. <template v-else>
  72. <p class="d-id">ID: {{item.childName}}</p>
  73. <p class="p-sub">剩余点数:{{item.balance}}</p>
  74. <div class="d-edit" :class="{'dtow-edit':tabActive!==4}">
  75. <router-link class="primary" :to="{name:'introtow',params:{id:item.childName}}"><span>{{langDevices.recharge}}</span></router-link>
  76. <div>
  77. <span @click="unbind(item)">{{langDevices.unbind}}</span>
  78. </div>
  79. </div>
  80. </template>
  81. </div>
  82. <div class="i-right">
  83. <img @click="gotoScene(item)" :src="tabActive===4?`${$cdn}images/banner_pro.png`:`${$cdn}images/t_product.png`" alt="">
  84. </div>
  85. </div>
  86. </template>
  87. </div>
  88. <tableList v-else @selection-change="data=>{selectedArr=data}" :header='tabHeader' :showLine='true' :selection='true' :data='mydevice.list' class="table-list" >
  89. <div slot-scope="{data}" slot="header">
  90. {{language==='en'?data.en:data.name}}
  91. </div>
  92. <div slot-scope="{data,type,canclick,item}" slot="item" style="width:100%">
  93. <template v-if="canclick">
  94. <router-link class="edit" target="_blank" :to="{name:'introduce',params:{id:item.childName}}">{{langDevices.capacity}}</router-link>
  95. <span class="edit" @click="handleCooperation(item)" v-if="item.status !== 0" >{{langDevices.fenpei}}</span>
  96. </template>
  97. <span v-else-if="type==='qingkuang'">{{item.usedSpaceStr}} / {{item.totalSpaceStr}}</span>
  98. <span v-else>{{data||'-'}}</span>
  99. </div>
  100. </tableList>
  101. <div class="paging" v-if="total">
  102. <Paging @clickHandle="pageChange" :current="currentPage" :total="total" :equable="pageSize" />
  103. </div>
  104. </div>
  105. </template>
  106. <script>
  107. import { mapState } from 'vuex'
  108. import Paging from '@/components/Paging'
  109. import tableList from '@/components/table'
  110. import {device} from './idevice'
  111. export default {
  112. components: {Paging, tableList},
  113. data () {
  114. let tabList = [
  115. {
  116. name: '四维看看Pro',
  117. id: 4
  118. }, {
  119. name: '四维看看Lite',
  120. id: 0
  121. }
  122. ]
  123. let isImgType = localStorage.getItem('isImgTypeForDevice') === '' ? true : (localStorage.getItem('isImgTypeForDevice') === 'true')
  124. return {
  125. tabHeader: device,
  126. lock: false,
  127. selectedArr: [],
  128. tabList,
  129. allTotal: 0,
  130. xiezuoNum: 0,
  131. tabActive: 4,
  132. currentPage: 1,
  133. total: 0,
  134. isImgType: isImgType,
  135. searchKey: '',
  136. pageSize: 8,
  137. isWide: window.innerWidth > 1300,
  138. loading: false
  139. }
  140. },
  141. computed: {
  142. ...mapState({
  143. language: state => state.language.current,
  144. token: state => state.user.token,
  145. langToast: state => state.language.home.toast,
  146. langDevices: state => state.language.home.manage.myDevices,
  147. mydevice: state => {
  148. let type = Object.prototype.toString.call(state.user.mydevice)
  149. if (type === '[object Object]') {
  150. return state.user.mydevice
  151. }
  152. let condition = state.user.mydevice && state.user.mydevice !== 'null' && type !== '[object Array]'
  153. return (condition ? JSON.parse(state.user.mydevice) : {})
  154. }
  155. })
  156. },
  157. watch: {
  158. currentPage () {
  159. this.getList()
  160. },
  161. tabActive (newVal) {
  162. this.loading = true
  163. this.currentPage === 1 ? this.getList() : this.currentPage = 1
  164. }
  165. },
  166. mounted () {
  167. this.getEMTotal()
  168. this.getList()
  169. },
  170. methods: {
  171. changeType (status) {
  172. this.isImgType = status
  173. localStorage.setItem('isImgTypeForDevice', status)
  174. },
  175. checkSelect () {
  176. let pass = this.selectedArr.length <= 0
  177. if (pass) {
  178. return this.$toast.show('warn', `${this.language === 'en' ? 'Please select at least one.' : '请至少勾选一项'}`)
  179. }
  180. return true
  181. },
  182. multCop () {
  183. if (this.checkSelect()) {
  184. let ids = this.selectedArr.map(item => {
  185. return item.id
  186. })
  187. this.$toast.showCooperation({
  188. ids: ids.join(','),
  189. type: 'device'
  190. }, () => {
  191. this.getList()
  192. })
  193. }
  194. },
  195. multDel () {
  196. if (this.checkSelect()) {
  197. let ids = this.selectedArr.map(item => {
  198. return item.id
  199. })
  200. this.unbind(ids.join(','), true)
  201. }
  202. },
  203. async getEMTotal () {
  204. let res = await this.$http({
  205. method: 'post',
  206. data: {
  207. cameraType: 0,
  208. childName: '',
  209. pageNum: this.currentPage,
  210. pageSize: this.pageSize
  211. },
  212. headers: {
  213. token: this.token
  214. },
  215. url: '/user/camera/list'
  216. })
  217. this.xiezuoNum = res.data.data.total
  218. },
  219. async handleCooperation (item) {
  220. this.$toast.showCooperation({
  221. num: item.id,
  222. cooName: item.cooperationUserName,
  223. type: 'device'
  224. }, () => {
  225. this.getList()
  226. })
  227. },
  228. gotoScene (item) {
  229. this.$router.push({
  230. name: 'scene',
  231. query: {
  232. cameraid: item.snCode || item.childName || ''
  233. }
  234. })
  235. },
  236. getBar (a, b) {
  237. if (a === 0) {
  238. return 0
  239. }
  240. let temp = (a / b) * 100
  241. if (temp < 1) {
  242. return '1%'
  243. }
  244. return temp > 100 ? 100 : Math.round(temp) + '%'
  245. },
  246. getColor (a, b) {
  247. let temp = (a / b) * 100
  248. let point = 80
  249. let color = ''
  250. switch (true) {
  251. case temp < point:
  252. color = '#1fe4dc'
  253. break
  254. default:
  255. color = '#ff0000'
  256. break
  257. }
  258. return color
  259. },
  260. async unbind (item, multi = false) {
  261. this.$toast.showConfirm('warn', this.langToast['26'], async () => {
  262. let params = {
  263. }
  264. multi ? (params['ids'] = item) : (params['cameraId'] = item.id)
  265. let res = await this.$http({
  266. method: 'post',
  267. data: params,
  268. headers: {
  269. token: this.token
  270. },
  271. url: '/user/camera/unbind'
  272. })
  273. let data = res.data
  274. if (data.code === 0) {
  275. return this.$toast.show('warn', this.langToast['33'], () => {
  276. this.getList()
  277. })
  278. }
  279. return this.$toast.show('error', this.langToast[data.code])
  280. })
  281. },
  282. pageChange (data) {
  283. this.currentPage = data
  284. },
  285. addDevice () {
  286. let val = this.tabActive === 4 ? 1 : 0
  287. this.$toast.showBinding(val, () => {
  288. this.getList()
  289. })
  290. },
  291. async getList (searchKey = '') {
  292. window.scrollTo(0, 0)
  293. let params = {
  294. cameraType: this.tabActive,
  295. childName: searchKey.trim(),
  296. pageNum: searchKey ? 1 : this.currentPage,
  297. pageSize: this.pageSize
  298. }
  299. await this.$store.dispatch('getUserDevice', params)
  300. if (!this.mydevice.total && searchKey) {
  301. return this.$toast.show('warn', this.language === 'en' ? 'No corresponding device found.' : '没有找到对应的设备', () => {
  302. this.getList()
  303. })
  304. }
  305. this.pageSize = this.mydevice.pageSize
  306. this.total = this.mydevice.total || 0
  307. this.loading = false
  308. if (!this.lock && !this.allTotal) {
  309. this.lock = true
  310. this.allTotal = this.total
  311. }
  312. }
  313. }
  314. }
  315. </script>
  316. <style lang="scss" scoped>
  317. $theme-color: #1fe4dc;
  318. $font-color: #2d2d2d;
  319. .device-layout{
  320. margin: 30px 0 30px 0;
  321. width: 995px;
  322. color: $font-color;
  323. .d-header{
  324. margin-left: 40px;
  325. height: 30px;
  326. .tab-list{
  327. display: inline-block;
  328. li{
  329. display: inline-block;
  330. margin-right: 40px;
  331. cursor: pointer;
  332. font-size: 14px;
  333. line-height: 1.5;
  334. }
  335. .active{
  336. color: $theme-color;
  337. border-bottom: 1px solid $theme-color;
  338. }
  339. }
  340. .rig-con{
  341. margin-right: 40px;
  342. float: right;
  343. display: flex;
  344. align-items: center;
  345. .btns{
  346. margin-right: 20px;
  347. .button{
  348. line-height: 30px;
  349. height: 30px;
  350. min-width: 80px;
  351. padding: 0 10px;
  352. text-align: center;
  353. vertical-align: middle;
  354. font-size: 14px;
  355. color: #202020;
  356. margin-left: 10px;
  357. cursor: pointer;
  358. .iconfont{
  359. font-size: 14px;
  360. margin-right: 4px;
  361. }
  362. }
  363. .default{
  364. background: #E4E4E4;
  365. }
  366. }
  367. .tab-search{
  368. float: right;
  369. position: relative;
  370. width: 230px;
  371. padding-left: 10px;
  372. border: 1px solid #ccc;
  373. display: flex;
  374. .iconfont{
  375. width: 28px;
  376. height: 28px;
  377. padding: 6px;
  378. cursor: pointer;
  379. background: #e4e4e4;
  380. }
  381. input{
  382. width: 100%;
  383. font-size: 14px;
  384. appearance: none;
  385. line-height: 28px;
  386. height: 28px;
  387. border: 0;
  388. }
  389. }
  390. .main-list{
  391. display: inline-block;
  392. margin-left: 35px;
  393. .iconfont{
  394. cursor: pointer;
  395. font-size: 20px;
  396. margin-left: 5px;
  397. }
  398. .active{
  399. color: #1fe4dc;
  400. }
  401. }
  402. }
  403. }
  404. .d-con{
  405. margin-left: 40px;
  406. display: inline-block;
  407. .item{
  408. display: inline-block;
  409. box-shadow: 0 4px 4px rgba($color: #000000, $alpha: 0.1);
  410. position: relative;
  411. width: 280px;
  412. height: 180px;
  413. margin: 36px 36px 0 0;
  414. }
  415. .edit-item{
  416. cursor: pointer;
  417. vertical-align: top;
  418. .plus-con{
  419. position: absolute;
  420. text-align: center;
  421. transform: translate(-50%,-50%);
  422. top: 50%;
  423. left: 50%;
  424. .iconplus{
  425. position: relative;
  426. width: 50px;
  427. height: 50px;
  428. margin: 0 auto;
  429. span{
  430. position: absolute;
  431. transform: translate(-50%,-50%);
  432. top: 50%;
  433. left: 50%;
  434. display: inline-block;
  435. width: 50px;
  436. height: 6px;
  437. background: $font-color;
  438. &:last-child{
  439. transform: translate(-50%,-50%) rotate(90deg)
  440. }
  441. }
  442. }
  443. p{
  444. margin-top: 28px;
  445. font-weight: bold;
  446. }
  447. }
  448. }
  449. .d-item{
  450. padding: 10px 24px 10px 30px;
  451. position: relative;
  452. .tag{
  453. position: absolute;
  454. top: 0;
  455. left: 0;
  456. min-width: 80px;
  457. height: 18px;
  458. line-height: 18px;
  459. font-size: 10px;
  460. border-radius: 4px 0 18px 0;
  461. text-align: center;
  462. color: #fff;
  463. padding: 0 10px;
  464. }
  465. .expire{
  466. background: #fed228;
  467. }
  468. .full{
  469. background: #f90217;
  470. }
  471. .i-left{
  472. display: inline-block;
  473. vertical-align: top;
  474. width: 145px;
  475. margin-top: 25px;
  476. .d-id{
  477. font-size: 14px;
  478. font-weight: bold;
  479. margin-bottom: 5px;
  480. word-break: break-all;
  481. text-overflow: ellipsis;
  482. overflow: hidden;
  483. white-space: nowrap;
  484. }
  485. .capacity{
  486. margin: 5px 0;
  487. .c-line{
  488. width: 100%;
  489. height: 10px;
  490. background-color: #ccc;
  491. .active{
  492. background-color:$theme-color;
  493. height: 100%;
  494. }
  495. }
  496. }
  497. .p-sub{
  498. color: #969696;
  499. font-size: 14px;
  500. text-overflow: ellipsis;
  501. overflow: hidden;
  502. white-space: nowrap;
  503. position: relative;
  504. img{
  505. position: absolute;
  506. left: 0;
  507. top: 50%;
  508. transform: translateY(-50%);
  509. width: 22px;
  510. height: 22px;
  511. vertical-align: middle;
  512. }
  513. }
  514. .d-edit{
  515. margin-top: 10px;
  516. font-size: 14px;
  517. position: absolute;
  518. bottom: 22px;
  519. div,a {
  520. display: inline-block;
  521. background: #fff;
  522. color: #000;
  523. border: 1px solid #777777;
  524. border-radius: 2px;
  525. font-size: 12px;
  526. width: 50px;
  527. height: 22px;
  528. line-height: 22px;
  529. text-align: center;
  530. vertical-align: middle;
  531. margin-right: 4px;
  532. box-sizing: border-box;
  533. cursor: pointer;
  534. position: relative;
  535. span{
  536. position: absolute;
  537. top: 50%;
  538. left: 50%;
  539. transform: translate(-50%,-50%);
  540. width: 100%;
  541. }
  542. }
  543. .primary{
  544. background: #1fe4dc;
  545. border: 1px solid #1fe4dc;
  546. }
  547. }
  548. .oper-con{
  549. flex: 1;
  550. .oper {
  551. width: 26px;
  552. cursor: pointer;
  553. display: inline-block;
  554. position: relative;
  555. line-height: 30px;
  556. height: 30px;
  557. font-size: 14px;
  558. &:hover{
  559. >ul{
  560. display: block;
  561. }
  562. }
  563. >div {
  564. text-align: right;
  565. display: inline-block;
  566. width: 100%;
  567. .spot{
  568. width: 4px;
  569. height: 4px;
  570. display: inline-block;
  571. background-color: #202020;
  572. border-radius: 50%;
  573. position: relative;
  574. margin-right: 10px;
  575. &::after,&::before{
  576. content: '';
  577. position: absolute;
  578. width: 4px;
  579. height: 4px;
  580. display: inline-block;
  581. background-color: #202020;
  582. border-radius: 50%;
  583. left: -8px;
  584. top: 50%;
  585. transform: translateY(-50%);
  586. }
  587. &::before{
  588. right: -8px;
  589. left: unset;
  590. }
  591. }
  592. }
  593. >ul{
  594. display: none;
  595. position: absolute;
  596. top: 30px;
  597. z-index: 9;
  598. left: 0;
  599. background: #F7F7F7;
  600. min-width: 90px;
  601. box-shadow:0px 1px 6px rgba(0,0,0,0.16);
  602. >li{
  603. text-align: left;
  604. width: 100%;
  605. line-height: 2.5;
  606. padding: 0 10px;
  607. color: #202020;
  608. &:hover{
  609. background-color: #EBEBEB;
  610. }
  611. }
  612. }
  613. .b_default{
  614. display: inline-block;
  615. background: #fff;
  616. color: #000;
  617. border: 1px solid #777;
  618. border-radius: 2px;
  619. font-size: 12px;
  620. width: 52px;
  621. height: 22px;
  622. line-height: 22px;
  623. text-align: center;
  624. vertical-align: middle;
  625. margin-left: 4px;
  626. -webkit-box-sizing: border-box;
  627. box-sizing: border-box;
  628. cursor: pointer;
  629. position: relative;
  630. >span{
  631. position: absolute;
  632. top: 50%;
  633. left: 50%;
  634. -webkit-transform: translate(-50%,-50%);
  635. transform: translate(-50%,-50%);
  636. width: 100%;
  637. }
  638. }
  639. }
  640. }
  641. .dtow-edit{
  642. bottom: 40px;
  643. }
  644. }
  645. .i-right{
  646. vertical-align: top;
  647. float: right;
  648. height: 100%;
  649. position: relative;
  650. img{
  651. height:150px;
  652. cursor: pointer;
  653. }
  654. }
  655. }
  656. }
  657. .table-list{
  658. width: calc(100% - 80px);
  659. margin: 30px auto;
  660. }
  661. .scene-nothing{
  662. padding: 42px 0 150px 0;
  663. text-align: center;
  664. img{
  665. padding-bottom: 22px;
  666. text-align: center;
  667. }
  668. div{
  669. font-size: 16px;
  670. color: #969696;
  671. text-align: center;
  672. width: 230px;
  673. margin: 0 auto;
  674. }
  675. }
  676. .paging {
  677. // border-left: #e5e5e5 1px solid;
  678. height: 100%;
  679. margin: 40px 0;
  680. & /deep/ .layout {
  681. text-align: left;
  682. margin-top: 0;
  683. margin-left: 30px;
  684. }
  685. & /deep/ .layout a:not(:last-child) {
  686. margin: 10px 8px;
  687. font-size: 16px;
  688. display: inline-block;
  689. font-weight: 500;
  690. cursor: pointer;
  691. user-select: none;
  692. color: #999;
  693. position: relative;
  694. transition: color 0.3s;
  695. }
  696. & /deep/ .layout a:last-child {
  697. position: relative;
  698. top: -5px;
  699. display: -ms-inline-flexbox;
  700. display: inline-flex;
  701. -ms-flex-align: center;
  702. align-items: center;
  703. height: 22px;
  704. padding: 0 9.6px;
  705. padding: 0 0.6rem;
  706. }
  707. & /deep/ .layout a:last-child::before,
  708. & /deep/ .layout a:last-child::after {
  709. content: "";
  710. display: inline-block;
  711. will-change: transform;
  712. transition: transform 0.3s;
  713. }
  714. & /deep/ .layout a:not(:last-child).active::after,
  715. & /deep/ .layout a:not(:last-child).active,
  716. & /deep/ .layout a:not(:last-child):hover,
  717. & /deep/ .layout a:not(:last-child):hover::after {
  718. color: #111111;
  719. transform: scaleX(1);
  720. }
  721. & /deep/ .layout a:not(:last-child)::after {
  722. content: "";
  723. height: 3px;
  724. width: 140%;
  725. background-color: #111;
  726. display: block;
  727. margin-left: -20%;
  728. margin-top: 3px;
  729. transform-origin: 50% 50%;
  730. transform: scaleX(0);
  731. will-change: transform;
  732. transition: transform 0.3s;
  733. }
  734. }
  735. }
  736. @media screen and (min-width: 2000px) {
  737. .device-layout {
  738. width: 75%;
  739. }
  740. }
  741. @media screen and (max-width: 1700px){
  742. .device-layout {
  743. width: 95%;
  744. .d-con{
  745. .item{
  746. width: 280px;
  747. margin: 36px 36px 0 0;
  748. }
  749. }
  750. }
  751. }
  752. @media screen and (max-width: 1400px){
  753. .device-layout {
  754. width: 98%;
  755. .d-header{
  756. .tab-search{
  757. margin-right: 60px!important;
  758. }
  759. }
  760. .d-con{
  761. .item{
  762. width: 265px;
  763. margin: 20px 20px 0 0;
  764. padding: 10px 16px!important;
  765. }
  766. }
  767. }
  768. }
  769. @media screen and (max-width: 1300px){
  770. .device-layout {
  771. width: 100%;
  772. .d-header{
  773. .tab-search{
  774. margin-right: 20px!important;
  775. }
  776. }
  777. .d-con{
  778. .item{
  779. width: 235px;
  780. margin: 10px 11px 0 0;
  781. padding: 10px 13px!important;
  782. }
  783. }
  784. }
  785. }
  786. </style>