App.vue 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336
  1. <template>
  2. <div id="app">
  3. <router-view v-if="isRouterAlive"></router-view>
  4. </div>
  5. </template>
  6. <script>
  7. // import { loginconf } from "api/api.js";
  8. export default {
  9. name: "app",
  10. provide() {
  11. //父组件中通过provide来提供变量,在子组件中通过inject来注入变量。
  12. return {
  13. reload: this.reload,
  14. };
  15. },
  16. data() {
  17. return {
  18. isRouterAlive: true, //控制视图是否显示的变量
  19. };
  20. },
  21. methods: {
  22. reload() {
  23. this.isRouterAlive = false; //先关闭,
  24. this.$nextTick(function () {
  25. this.isRouterAlive = true; //再打开
  26. });
  27. },
  28. },
  29. };
  30. </script>
  31. <style lang="scss">
  32. @import "~scss_global";
  33. body {
  34. margin: 0px !important;
  35. padding: 0px;
  36. font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB,
  37. Microsoft YaHei, SimSun, sans-serif;
  38. font-size: 14px;
  39. -webkit-font-smoothing: antialiased;
  40. }
  41. .fr-second-toolbar {
  42. display: none !important;
  43. }
  44. img {
  45. object-fit: contain !important;
  46. image-rendering: -moz-crisp-edges;
  47. image-rendering: -o-crisp-edges;
  48. image-rendering: -webkit-optimize-contrast;
  49. image-rendering: crisp-edges;
  50. -ms-interpolation-mode: nearest-neighbor;
  51. }
  52. #app {
  53. position: absolute;
  54. top: 0px;
  55. bottom: 0px;
  56. left:0;
  57. right:0;
  58. }
  59. .el-submenu [class^="fa"] {
  60. vertical-align: baseline;
  61. margin-right: 10px;
  62. }
  63. .el-menu-item [class^="fa"] {
  64. vertical-align: baseline;
  65. margin-right: 10px;
  66. }
  67. .toolbar {
  68. font: 14px "微软雅黑";
  69. color: $color-primary;
  70. background: #fff;
  71. padding: 10px 15px;
  72. margin: 10px 0px;
  73. .el-form-item {
  74. margin-bottom: 10px;
  75. }
  76. }
  77. .headTip {
  78. padding: 10px 15px;
  79. margin: 10px auto;
  80. font: 14px "微软雅黑";
  81. color: #fff;
  82. background: $color-primary;
  83. }
  84. .fade-enter-active,
  85. .fade-leave-active {
  86. transition: all 0.2s ease;
  87. }
  88. .fade-enter,
  89. .fade-leave-active {
  90. opacity: 0;
  91. }
  92. p[data-f-id="pbf"] {
  93. display: none;
  94. }
  95. iframe {
  96. border: none;
  97. }
  98. .el-table .success-row {
  99. background: #eaeaea;
  100. }
  101. .editsty {
  102. font-size: 14px;
  103. color: #0052D9;
  104. cursor: pointer;
  105. margin-right: 5px;
  106. }
  107. .deletesty {
  108. font-size: 14px;
  109. color: #C54322;
  110. cursor: pointer;
  111. }
  112. .disty {
  113. font-size: 14px;
  114. color: #999;
  115. cursor: not-allowed;
  116. }
  117. .warnsty {
  118. font-size: 14px;
  119. color: #ff9900;
  120. }
  121. .successty {
  122. font-size: 14px;
  123. color: #1bb940;
  124. }
  125. .el-card__header {
  126. border: none !important;
  127. box-shadow: 0 3px 6px rgba(37, 37, 239, 0.1) !important;
  128. }
  129. .el-pagination.is-background .el-pager li {
  130. background: #fff;
  131. // border: 1px solid #8F9BB3;
  132. }
  133. .el-pagination.is-background .el-pager li:not(.disabled).active {
  134. border-color: #0052D9;
  135. }
  136. .el-pagination.is-background .btn-next,
  137. .el-pagination.is-background .btn-prev {
  138. // border: 1px solid #8F9BB3;
  139. background: #fff;
  140. }
  141. .clearfix:after {
  142. content: "";
  143. height: 0;
  144. clear: both;
  145. visibility: hidden;
  146. display: block;
  147. zoom: 1;
  148. }
  149. .text_oneLine {
  150. overflow: hidden;
  151. text-overflow: ellipsis;
  152. white-space: nowrap;
  153. }
  154. /* 控制文字显示两行 */
  155. .text_twoLine {
  156. overflow: hidden;
  157. text-overflow: ellipsis;
  158. display: -webkit-box;
  159. -webkit-box-orient: vertical;
  160. -webkit-line-clamp: 2;
  161. }
  162. /* .el-popover */
  163. .el-checkbox__input.is-disabled + span.el-checkbox__label {
  164. color: #666 !important;
  165. }
  166. .el-form-item__label {
  167. font-size: 14px;
  168. }
  169. .el-collapse-item__header {
  170. border: none;
  171. font-size: 14px;
  172. color: #333;
  173. font-weight: bold;
  174. position: relative;
  175. margin-bottom: 20px;
  176. }
  177. /* 省市选择禁用统一element样式 */
  178. .distpicker-address-wrapper select:disabled {
  179. cursor: not-allowed;
  180. background: #f5f7fa;
  181. border-color: #e4e7ed;
  182. color: #c0c4cc;
  183. opacity: 1;
  184. }
  185. .distpicker-address-wrapper select {
  186. font-size: 14px !important;
  187. }
  188. /* img preview */
  189. .el-image-viewer__mask {
  190. opacity: 0.8;
  191. }
  192. .el-image-viewer__canvas .el-image-viewer__img {
  193. position: absolute;
  194. // left: 40%;
  195. // top: 40%;
  196. // transform: translate(-50%,-50%);
  197. width: 1200px;
  198. max-height: 100vh;
  199. overflow-y: scroll;
  200. }
  201. .el-image-viewer__next,
  202. .el-image-viewer__prev {
  203. width: 62px;
  204. height: 110px;
  205. border: none;
  206. font-size: 80px;
  207. background: transparent;
  208. color: #858585;
  209. }
  210. .el-image-viewer__close {
  211. width: 66px;
  212. height: 66px;
  213. color: #fff;
  214. font-size: 48px;
  215. }
  216. .el-popconfirm .el-popconfirm__action {
  217. margin-top: 10px;
  218. }
  219. /*修改滚动条样式 chrome edge safari*/
  220. div::-webkit-scrollbar {
  221. width: 6px;
  222. height: 6px;
  223. }
  224. div::-webkit-scrollbar-track {
  225. background: rgb(239, 239, 239);
  226. border-radius: 2px;
  227. }
  228. div::-webkit-scrollbar-thumb {
  229. background: #ccc;
  230. border-radius: 10px;
  231. }
  232. div::-webkit-scrollbar-thumb:hover {
  233. background: #888;
  234. }
  235. div::-webkit-scrollbar-corner {
  236. background: #666;
  237. }
  238. /*firefox*/
  239. div{
  240. scrollbar-width: thin;
  241. }
  242. .customName:hover {
  243. text-decoration: underline;
  244. }
  245. /**/
  246. .el-select-dropdown__wrap {
  247. max-height: 358px !important;
  248. }
  249. /* 日期选择 */
  250. .mx-datepicker {
  251. width: 280px !important;
  252. }
  253. .mx-calendar-content .cell.active {
  254. background-color: #0052D9 !important;
  255. }
  256. .mx-datepicker .mx-input {
  257. height: 40px;
  258. border-color: #dcdfe6;
  259. box-shadow: none;
  260. }
  261. .mx-input {
  262. &::placeholder {
  263. color: #bbb;
  264. }
  265. &:hover {
  266. border-color: #c0c4cc !important;
  267. }
  268. }
  269. /*修改滚动条样式 chrome edge safari*/
  270. ul::-webkit-scrollbar {
  271. width: 6px;
  272. height: 6px;
  273. }
  274. ul::-webkit-scrollbar-track {
  275. background: rgb(239, 239, 239);
  276. border-radius: 2px;
  277. }
  278. ul::-webkit-scrollbar-thumb {
  279. background: #ccc;
  280. border-radius: 10px;
  281. }
  282. ul::-webkit-scrollbar-thumb:hover {
  283. background: #888;
  284. }
  285. ul::-webkit-scrollbar-corner {
  286. background: #666;
  287. }
  288. /*firefox*/
  289. ul{
  290. scrollbar-width: thin;
  291. }
  292. textarea {
  293. font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB",
  294. "Microsoft YaHei", "微软雅黑", Arial, sans-serif;
  295. }
  296. // .el-dialog {
  297. // display: flex;
  298. // flex-direction: column;
  299. // margin: 0 !important;
  300. // position: absolute;
  301. // top: 50%;
  302. // left: 50%;
  303. // transform: translate(-50%, -50%);
  304. // max-height: calc(100% - 30px);
  305. // max-width: calc(100% - 30px);
  306. // }
  307. // .el-dialog .el-dialog__body {
  308. // flex: 1;
  309. // overflow: auto;
  310. // }
  311. .el-color-predefine {
  312. .el-color-predefine__color-selector {
  313. box-shadow: 0 0 1px 1px #999;
  314. }
  315. }
  316. //图表搜索select
  317. .chart-search-popper {
  318. min-width: 300px !important;
  319. width: auto !important;
  320. }
  321. //数据管理下的输入框
  322. .el-autocomplete-suggestion-data-entry {
  323. width: auto !important;
  324. }
  325. </style>