App.vue 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211
  1. <template>
  2. <el-config-provider :locale="locale">
  3. <router-view v-slot="{ Component }">
  4. <keep-alive>
  5. <component :is="Component"/>
  6. </keep-alive>
  7. </router-view>
  8. </el-config-provider>
  9. </template>
  10. <script>
  11. import {defineComponent} from 'vue'
  12. import locale from 'element-plus/lib/locale/lang/zh-cn'
  13. import {useStore} from 'vuex'
  14. export default defineComponent({
  15. name: 'App',
  16. setup() {
  17. const store = useStore()
  18. let windowSize = getWindowSize()
  19. store.commit('app/setWindowSize', windowSize)
  20. store.commit('app/setJdt', {
  21. title: '数据上传',
  22. isOpen: false,
  23. abnormalClosing: false,
  24. })
  25. window.onresize = () => {
  26. store.commit('app/setWindowSize', getWindowSize())
  27. }
  28. return {
  29. locale,
  30. }
  31. },
  32. })
  33. function getWindowSize() {
  34. const w = window.innerWidth
  35. const h = window.innerHeight - 96
  36. return {w, h}
  37. }
  38. </script>
  39. <style>
  40. #app {
  41. font-family: Avenir, Helvetica, Arial, sans-serif;
  42. -webkit-font-smoothing: antialiased;
  43. -moz-osx-font-smoothing: grayscale;
  44. color: #2c3e50;
  45. width: 100%;
  46. height: 100vh;
  47. font-size: 13px;
  48. }
  49. .ellipsis-text {
  50. text-overflow: ellipsis;
  51. white-space: nowrap;
  52. overflow: hidden;
  53. }
  54. .sex-icon {
  55. width: 15px;
  56. height: 15px;
  57. }
  58. .el-table .cell {
  59. padding-left: 4px;
  60. padding-right: 4px;
  61. }
  62. .el-header {
  63. padding: 0 14px;
  64. }
  65. .el-main {
  66. padding: 0 14px;
  67. }
  68. .el-table__body tr.current-row > td,
  69. .el-table--striped .el-table__body tr.el-table__row--striped.current-row td {
  70. background-color: #a7d3ff !important;
  71. }
  72. .el-input.is-disabled .el-input__inner {
  73. color: blue;
  74. }
  75. .icon-shangxiatuodong {
  76. cursor: move;
  77. font-size: 12px;
  78. }
  79. .shangxiatuodong {
  80. cursor: move;
  81. }
  82. .el-checkbox__inner {
  83. width: 16px;
  84. height: 16px;
  85. border: 1px solid #000;
  86. border-radius: 4px;
  87. }
  88. .axios-loading2 {
  89. animation: axiosloading 1s;
  90. background-image: url('/src/assets/images/loading.gif');
  91. -webkit-background-image: url('/src/assets/images/loading.gif');
  92. background-repeat: no-repeat;
  93. background-position: center;
  94. }
  95. .el-dialog__header {
  96. border-bottom: 1px solid #ebeef5;
  97. background-color: #f8f8f8;
  98. border-radius: 4px;
  99. }
  100. .el-dialog {
  101. border-radius: 4px;
  102. }
  103. @keyframes axiosloading {
  104. 0% {
  105. opacity: 0;
  106. }
  107. 99% {
  108. opacity: 0;
  109. }
  110. 100% {
  111. opacity: 1;
  112. }
  113. }
  114. .component-box-wrapper__fullscreen {
  115. position: fixed;
  116. top: 0;
  117. left: 0;
  118. bottom: 0;
  119. right: 0;
  120. background: white;
  121. padding: 20px;
  122. z-index: 10000;
  123. height: 100%;
  124. overflow: auto;
  125. }
  126. .component-box-wrapper__half-transparent {
  127. position: fixed;
  128. top: 0;
  129. left: 0;
  130. bottom: 0;
  131. right: 0;
  132. background: rgba(0, 0, 0, 0.7);
  133. padding: 20px;
  134. z-index: 1000;
  135. height: 100%;
  136. overflow: auto;
  137. display: flex;
  138. align-items: flex-start;
  139. justify-content: center;
  140. }
  141. .component-content-box__dialog-like {
  142. width: 60%;
  143. padding: 20px;
  144. background: white;
  145. margin-top: 15vh;
  146. }
  147. .component-header-box {
  148. position: relative;
  149. width: 100%;
  150. display: flex;
  151. padding: 0 0 12px 0;
  152. }
  153. .component-header__title {
  154. width: 70%;
  155. font-size: 16px;
  156. display: flex;
  157. align-items: center;
  158. }
  159. .component-header__close-button {
  160. width: 30%;
  161. text-align: right;
  162. }
  163. table th.star div::before {
  164. content: '*';
  165. color: #f56c6cff;
  166. margin-right: 4px;
  167. }
  168. .bi_tian .el-form-item__label::before {
  169. content: '*';
  170. color: #f56c6cff;
  171. margin-right: 4px;
  172. }
  173. .el-select-dropdown__item.selected {
  174. background-color: #71abed66;
  175. }
  176. .el-select-dropdown__item.hover, .el-select-dropdown__item:hover {
  177. background-color: #fac44d;
  178. color: white;
  179. }
  180. </style>