DefaultPage.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992
  1. <template>
  2. <div class="main">
  3. <div class="topBox">
  4. <div class="upload" v-if="isSearch">
  5. <el-upload
  6. class="upload-show"
  7. :file-list="fileArr"
  8. :limit="1"
  9. :on-change="upBefore"
  10. :show-file-list="false"
  11. drag
  12. :http-request="onSuccess"
  13. multiple
  14. element-loading-text="上传中..."
  15. element-loading-background="rgba(255, 255, 255, 0.8)"
  16. v-loading="loadingUpload"
  17. >
  18. <img src="@/assets/images/newIndex/yunBlack.png" alt="" />
  19. <span class="text1">上传文件</span>
  20. <p class="text2">
  21. 将文件拖到此处或 <span class="blueT">选择文件</span>
  22. </p>
  23. </el-upload>
  24. <div class="right">
  25. <div class="line">|</div>
  26. <img
  27. src="@/assets/images/newIndex/scan.png"
  28. @click="scannerFile"
  29. class="scanImg"
  30. alt=""
  31. />
  32. </div>
  33. </div>
  34. <div class="search hoverColor" :class="{ showSearch: isSearch }">
  35. <input
  36. type="text"
  37. class="search_input"
  38. v-model="searchText"
  39. @keyup.enter="searchBtn"
  40. placeholder="输入关键词或文件名(≥2字)"
  41. />
  42. <div class="searchBtn" @click="searchBtn">
  43. <img src="@/assets/images/newIndex/search.png" alt="" />
  44. <span>全域瞬搜</span>
  45. </div>
  46. </div>
  47. </div>
  48. <div v-if="isSearch" class="searchBtm">
  49. <div class="highSearch">
  50. <div v-loading="highLoading" v-if="highLoading" class="lodingBox"></div>
  51. <div v-else class="mainBox">
  52. <div class="title">共查询到{{ props.hightDataTotal }}个相关结果</div>
  53. <div class="list">
  54. <div
  55. class="oneBox"
  56. v-for="item in hightData"
  57. :key="item.id"
  58. @click="toFile(item.content.docInfo)"
  59. >
  60. <span class="fileName">{{ item.content.docInfo.fileName }}</span>
  61. <div class="flieTime">
  62. <span>创建时间:</span>
  63. <span>{{ item.content.docInfo.createTime }}</span>
  64. <div class="position">
  65. <span>文件位置:</span>
  66. <span>{{ item.content.docInfo.dir.dirPath }}</span>
  67. </div>
  68. </div>
  69. <div
  70. class="flieContent"
  71. v-for="par in item.highlightFields.content"
  72. :key="par"
  73. v-html="par"
  74. ></div>
  75. </div>
  76. </div>
  77. </div>
  78. </div>
  79. <div class="allSearch">
  80. <div v-loading="allLoading" v-if="allLoading" class="lodingBox"></div>
  81. <div v-else>
  82. <div class="title"><span>文件名匹配结果</span></div>
  83. <div class="num">共查询到{{ props.allDataTotal }}个相关结果</div>
  84. <el-table
  85. :data="allData"
  86. style="width: 100%"
  87. ref="container"
  88. height="584"
  89. scrollbar-always-on
  90. @row-click="toFile"
  91. >
  92. <el-table-column type="index" width="70" />
  93. <el-table-column label="名称" width="200">
  94. <template #default="scope">
  95. <div class="flie_name">
  96. <img
  97. class="table_icon"
  98. :src="setIcon(scope.row.fileType)"
  99. alt=""
  100. style=""
  101. />
  102. <span v-html="scope.row.fileName"></span>
  103. </div>
  104. </template>
  105. </el-table-column>
  106. <el-table-column prop="dir.dirPath" label="所属空间" width="210" />
  107. <el-table-column prop="fileType" label="类型" width="100" />
  108. <el-table-column prop="createTime" label="时间" width="200" />
  109. <el-table-column prop="fileSize" label="大小" width="100">
  110. <template #default="scope">
  111. <div>{{ formatFileSize(scope.row.fileSize) }}</div>
  112. </template>
  113. </el-table-column>
  114. </el-table>
  115. </div>
  116. </div>
  117. </div>
  118. <div v-else class="btmBox">
  119. <div class="upFile" @paste="copyFile">
  120. <el-upload
  121. class="upload-demo"
  122. :file-list="fileArr"
  123. :limit="1"
  124. :on-change="upBefore"
  125. :show-file-list="false"
  126. drag
  127. :http-request="onSuccess"
  128. multiple
  129. element-loading-text="上传中..."
  130. element-loading-background="rgba(255, 255, 255, 0.8)"
  131. v-loading="loadingUpload"
  132. >
  133. <img
  134. src="@/assets/images/newIndex/upFolderLogo.png"
  135. class="upImg"
  136. alt=""
  137. />
  138. <span class="text1">上传你的文件</span>
  139. </el-upload>
  140. <p class="text2">将文件拖到此处或 <span>选择文件</span></p>
  141. <div class="line"></div>
  142. <img
  143. src="@/assets/images/newIndex/scan.png"
  144. @click="scannerFile"
  145. class="scanImg"
  146. alt=""
  147. />
  148. <div class="text3">扫描文件</div>
  149. </div>
  150. <div class="recent">
  151. <div class="top">
  152. <span>最近文件</span>
  153. </div>
  154. <div class="list">
  155. <div
  156. v-for="item in tableFileData"
  157. :key="item"
  158. @click="toFile(item)"
  159. class="oneBox"
  160. >
  161. <div class="imgBox">
  162. <img :src="setImg(item == null ? '' : item.fileType)" alt="" />
  163. </div>
  164. <div class="rightBox">
  165. <div class="text">{{ item.fileName }}</div>
  166. <div class="time">{{ item.createTime }}</div>
  167. </div>
  168. <img
  169. class="openArrow"
  170. src="@/assets/images/newIndex/CaretRight.png"
  171. alt=""
  172. />
  173. </div>
  174. </div>
  175. </div>
  176. </div>
  177. </div>
  178. <ImgPreview
  179. :previewData="previewData"
  180. :copyFileType="copyFileType"
  181. :showPreview="showPreview"
  182. @closeImgPreview="closeImgPreview"
  183. ></ImgPreview>
  184. <!-- 扫描文档 -->
  185. <ScanFile
  186. v-if="openScan"
  187. :openScan="openScan"
  188. :scannerFiles="scannerFiles"
  189. @saveScanFile="saveScanFile"
  190. @closeOpen="closeOpen"
  191. ></ScanFile>
  192. <!-- 可用扫描仪信息 -->
  193. <div>
  194. <el-dialog v-model="checkScanner" title="扫描仪" width="30%">
  195. <div
  196. v-for="item in scannerList"
  197. :key="item.scannerId"
  198. @click="checkScanFn(item)"
  199. id="Onescan"
  200. :class="{ checkScan: item.scannerId == checkScanId }"
  201. >
  202. <img src="@/assets/images/scanImg.png" alt="" />
  203. {{ item.scannerName }}
  204. </div>
  205. <template #footer>
  206. <span class="dialog-footer">
  207. <el-button @click="closeCheckScanner">取消</el-button>
  208. <el-button type="primary" @click="sureScaner">确认</el-button>
  209. </span>
  210. </template>
  211. </el-dialog>
  212. </div>
  213. <!-- 扫描文件移动到 -->
  214. <MoveTo
  215. v-if="openScanMove"
  216. :spaceType="3"
  217. :scanFileArr="scanFileArr"
  218. :thisFolder="thisFolder"
  219. :openScanMove="openScanMove"
  220. :spaceId="spaceId"
  221. @closeOpenScanMove="closeOpenScanMove"
  222. ></MoveTo>
  223. <div
  224. v-loading.fullscreen="loadingPreview"
  225. v-if="loadingPreview"
  226. class="lodingBox"
  227. ></div>
  228. </template>
  229. <script setup>
  230. import { onMounted, ref, toRaw, inject, watchEffect } from "vue";
  231. import { getInfo, getInfoByDirId } from "@/api/biz/info";
  232. import { listRecent, getRecent } from "@/api/biz/recent";
  233. import { setIcon, canPreviewFile } from "@/utils/index.js";
  234. import { preview } from "@/api/common/common.js";
  235. import { ElMessage, ElLoading, ElMessageBox } from "element-plus";
  236. import ImgPreview from "@/components/ImgPreview/ImgPreview.vue";
  237. import { getConfigKey } from "@/api/system/config.js";
  238. import ScanFile from "@/components/ScanFile/ScanFile.vue";
  239. import MoveTo from "@/components/MoveTo/MoveTo.vue";
  240. import myfile from "@/api/myfile/myfile";
  241. import { listInfo, selectInfo, getFileByScanerId } from "@/api/scanner/info.js";
  242. import documents from "@/api/document/document";
  243. import uploadApi from "@/api/upload/upload";
  244. import bus from "@/utils/bus.js";
  245. const tableFileData = ref([]);
  246. const copyFileType = ref();
  247. const previewData = ref();
  248. const loadingPreview = ref(false);
  249. const showPreview = ref(false);
  250. let fileArr = ref([]);
  251. const useSpace = ref();
  252. let fileBig = ref(0);
  253. const allSpace = ref();
  254. const maxFileSize = ref(); //能上传的最大size
  255. const loadingUpload = ref(false);
  256. const topDirId = ref(); //我的文件顶层的目录id
  257. const topSpaceId = ref(); //我的文件顶层的目录id
  258. const scannerList = ref(); // 扫描仪数据
  259. const checkScanId = ref(); // 选中的scan的id
  260. const checkScanner = ref(false); //显示扫描仪选择框
  261. const scannerFiles = ref([]); //选择的扫描仪的文件
  262. const openScanMove = ref(false);
  263. const openScan = ref(false); //控制扫描文档显示
  264. const scanFileArr = ref([]); //认领的扫描文件数组
  265. const isSearch = ref(props.showSearch);
  266. const searchText = ref(); // 搜索内容
  267. const hightData = ref([]); // 高级搜索数据
  268. const allData = ref([]); // 全域搜索数据
  269. const canSearch = ref(true);
  270. const allLoading = ref(false);
  271. const highLoading= ref(false);
  272. const emit = defineEmits(["openMaxmin", "changeSearch"]);
  273. const props = defineProps({
  274. showSearch: {
  275. type: Boolean,
  276. default: false,
  277. },
  278. hightData: {
  279. type: Array,
  280. default: () => [],
  281. },
  282. allData: {
  283. type: Array,
  284. default: () => [],
  285. },
  286. hightDataTotal: {
  287. type: Number,
  288. default: 0,
  289. },
  290. allDataTotal: {
  291. type: Number,
  292. default: 0,
  293. },
  294. highSearching: {
  295. type: Boolean,
  296. default: false,
  297. },
  298. allSearching: {
  299. type: Boolean,
  300. default: false,
  301. },
  302. });
  303. //搜索事件
  304. const searchBtn = () => {
  305. // console.log("searchText", searchText.value);
  306. if (!canSearch.value) {
  307. return;
  308. } else {
  309. canSearch.value = false;
  310. setTimeout(() => {
  311. canSearch.value = true;
  312. }, 3000);
  313. }
  314. if (!searchText.value) {
  315. ElMessage({
  316. message: "请输入关键字",
  317. type: "error",
  318. });
  319. return;
  320. }
  321. emit("changeSearch", true, searchText.value);
  322. };
  323. // 获取数据
  324. const getList = async () => {
  325. const resN = await listRecent({ isFolder: "N" });
  326. if (resN.code === 200) {
  327. tableFileData.value.length = resN.rows.length;
  328. for (let index = 0; index < resN.rows.length; index++) {
  329. getInfo(resN.rows[index].relaId).then(async (res) => {
  330. // tableFileData.value.push(res.data);
  331. tableFileData.value.splice(index, 1, res.data);
  332. index++;
  333. });
  334. }
  335. // console.log('tableFileData',tableFileData.value);
  336. // 将tableFileData里的数据按照createTime排序
  337. // tableFileData.value = tableFileData.value.sort((a, b) => {
  338. // return new Date(b.createTime) - new Date(a.createTime);
  339. // });
  340. // resN.rows.map(async (item) => {
  341. // const detail = await getInfo(item.relaId);
  342. // tableFileData.value.push(detail.data);
  343. // });
  344. }
  345. };
  346. // 打开最近文件
  347. const toFile = async (row) => {
  348. copyFileType.value = row.fileType;
  349. // console.log("row", row);
  350. loadingPreview.value = true;
  351. const filePreview = canPreviewFile(row.fileType);
  352. if (filePreview) {
  353. loadingPreview.value = false;
  354. emit(
  355. "openMaxmin",
  356. row.fileName,
  357. `${window.location.origin}/fileEdit?clickRowId=${row.docId}&canEdit=0&canCopy=0&history=0&fileId=0`
  358. );
  359. } else {
  360. const res = await preview(row.docId);
  361. showPreview.value = true;
  362. previewData.value = URL.createObjectURL(res);
  363. loadingPreview.value = false;
  364. }
  365. };
  366. // 设置icon
  367. const setImg = (type) => {
  368. return setIcon(type);
  369. };
  370. //关闭图片预览事件
  371. const closeImgPreview = () => {
  372. // console.log('close');
  373. showPreview.value = false;
  374. };
  375. // 限制上传文件大小
  376. const upBefore = (file, files) => {
  377. const maxSize = (maxFileSize.value - 0) * 1024 * 1024;
  378. // console.log('maxSize',maxSize);
  379. if (file.size > maxSize) {
  380. files.pop();
  381. ElMessage({
  382. message:
  383. file.name + "上传失败,上传文件大小最大为" + maxFileSize.value + "M",
  384. type: "error",
  385. });
  386. } else {
  387. fileBig.value = file.size + fileBig.value;
  388. // fileArr.value.push(file.raw)
  389. }
  390. // console.log('filesend',files);
  391. };
  392. // 我的文件的空间信息
  393. function getSpaceList() {
  394. myfile.fileType(3).then((res) => {
  395. useSpace.value = res.data.usedCap;
  396. allSpace.value = res.data.spaceCap;
  397. });
  398. }
  399. //获取我的文件顶层的目录id
  400. const getDirId = () => {
  401. documents.getTop(3).then((res) => {
  402. topDirId.value = res.dirId;
  403. topSpaceId.value = res.spaceId;
  404. });
  405. };
  406. function onSuccess(files, val) {
  407. // console.log('suFiles',files);
  408. const maxSize = (maxFileSize.value - 0) * 1024 * 1024;
  409. if (files.file.size < maxSize) {
  410. fileArr.value.push(files.file);
  411. }
  412. sureUpload();
  413. }
  414. // 确认上传
  415. function sureUpload() {
  416. loadingUpload.value = true;
  417. if (
  418. useSpace.value * 1024 * 1024 + fileBig.value / 1024 >
  419. allSpace.value * 1024 * 1024
  420. ) {
  421. ElMessage({
  422. message: "超过最大容量,请联系管理员扩容",
  423. type: "error",
  424. });
  425. loadingUpload.value = false;
  426. return;
  427. } else {
  428. if (fileArr.value.length > 0) {
  429. // console.log('fileArr',fileArr.value);
  430. let form = new FormData();
  431. for (var i = 0; i < fileArr.value.length; i++) {
  432. form.append("files", fileArr.value[i]);
  433. }
  434. form.append("spaceId", topSpaceId.value);
  435. form.append("dirId", topDirId.value);
  436. // console.error(fileArr.value);
  437. uploadApi
  438. .uploadFileMany(form)
  439. .then((res) => {
  440. if (res.code === 200) {
  441. ElMessage({
  442. message: "上传文件成功",
  443. type: "success",
  444. });
  445. // getAllTop()
  446. refreshFile();
  447. uploadModal.value = false;
  448. loadingUpload.value = false;
  449. fileArr.value = [];
  450. fileBig.value = 0;
  451. }
  452. })
  453. .catch((err) => {
  454. loadingUpload.value = false;
  455. fileArr.value = [];
  456. });
  457. } else {
  458. loadingUpload.value = false;
  459. return ElMessage({ message: "请选择文件", type: "error" });
  460. }
  461. }
  462. }
  463. //获取扫描仪列表
  464. const scannerFile = async () => {
  465. const res = await selectInfo();
  466. scannerList.value = res.rows;
  467. checkScanner.value = true;
  468. checkScanId.value = null;
  469. // console.log('scanner',res);
  470. };
  471. // 选择扫描仪
  472. const checkScanFn = (item) => {
  473. checkScanId.value = item.scannerId;
  474. };
  475. // 确认选择扫描仪 获取扫描仪下文件列表
  476. const sureScaner = async () => {
  477. if (!checkScanId.value) return;
  478. const res = await getFileByScanerId(checkScanId.value);
  479. // console.log("sureScanerres", res);
  480. scannerFiles.value = res.data;
  481. checkScanner.value = false;
  482. openScan.value = true;
  483. };
  484. // 关闭窗口
  485. const closeCheckScanner = () => {
  486. checkScanner.value = false;
  487. };
  488. const closeOpen = () => {
  489. openScan.value = false;
  490. };
  491. // 移动到事件
  492. const saveScanFile = (arr) => {
  493. // console.log("arr", arr);
  494. openScan.value = false;
  495. scanFileArr.value = arr;
  496. openScanMove.value = true;
  497. };
  498. // 关闭窗口
  499. const closeOpenScanMove = () => {
  500. openScanMove.value = false;
  501. // refreshFile();
  502. };
  503. //粘贴文件上传
  504. const copyFile = (event) => {
  505. const items = (event.clipboardData || window.clipboardData).items;
  506. // console.log("event", event);
  507. let file = null;
  508. if (!items || items.length === 0) {
  509. ElMessage({
  510. message: "请选当前浏览器不支持本地或请打开图片再复制择文件",
  511. type: "error",
  512. });
  513. return;
  514. }
  515. // // 搜索剪切板items
  516. // for (let i = 0; i < items.length; i++) {
  517. // if (items[i].type.indexOf("image") !== -1) {
  518. // file = items[i].getAsFile();
  519. // break;
  520. // }
  521. // }
  522. };
  523. function formatFileSize(fileSize) {
  524. if (fileSize >= 1024 * 1024 * 1024) {
  525. // 大于等于1GB,显示GB
  526. return (fileSize / (1024 * 1024 * 1024)).toFixed(2) + "GB";
  527. } else if (fileSize >= 1024 * 1024) {
  528. // 大于等于1MB,显示MB
  529. return (fileSize / (1024 * 1024)).toFixed(2) + "MB";
  530. } else if (fileSize >= 1024) {
  531. // 大于等于1KB,显示KB
  532. return (fileSize / 1024).toFixed(2) + "KB";
  533. } else {
  534. // 小于1KB,显示字节
  535. return fileSize + "B";
  536. }
  537. }
  538. watchEffect(() => {
  539. if (props.showSearch) {
  540. isSearch.value = true;
  541. } else {
  542. isSearch.value = false;
  543. }
  544. });
  545. watch(
  546. () => props.hightData,
  547. (newValue, oldValue) => {
  548. // console.log('iFrameData 发生改变了', newValue, oldValue);
  549. hightData.value = newValue;
  550. },
  551. {
  552. immediate: true,
  553. deep: true,
  554. }
  555. );
  556. watch(
  557. () => props.allData,
  558. (newValue, oldValue) => {
  559. // console.log('iFrameData 发生改变了', newValue, oldValue);
  560. allData.value = newValue;
  561. },
  562. {
  563. immediate: true,
  564. deep: true,
  565. }
  566. );
  567. watch(
  568. () => props.highSearching,
  569. (newValue, oldValue) => {
  570. highLoading.value = newValue;
  571. },
  572. {
  573. immediate: true,
  574. deep: true,
  575. }
  576. );
  577. watch(
  578. () => props.allSearching,
  579. (newValue, oldValue) => {
  580. allLoading.value = newValue;
  581. },
  582. {
  583. immediate: true,
  584. deep: true,
  585. }
  586. );
  587. onMounted(() => {
  588. getList();
  589. getSpaceList();
  590. getDirId();
  591. getConfigKey("file.size.limit").then((response) => {
  592. // console.log('response',response);
  593. maxFileSize.value = response.msg;
  594. });
  595. });
  596. </script>
  597. <style lang="scss" scoped>
  598. .main {
  599. width: 100%;
  600. height: calc(100vh - 160px);
  601. display: flex;
  602. padding: 0 16px;
  603. flex-direction: column;
  604. justify-content: center;
  605. align-items: center;
  606. }
  607. .topBox {
  608. width: 100%;
  609. display: flex;
  610. justify-content: center;
  611. .upload {
  612. width: 448px;
  613. height: 64px;
  614. border-radius: 86px 86px 86px 86px;
  615. background-color: #fff;
  616. margin-right: 16px;
  617. padding: 0 24px;
  618. display: flex;
  619. align-items: center;
  620. justify-content: space-between;
  621. .right {
  622. margin-top: 12px;
  623. width: 50px;
  624. display: flex;
  625. justify-content: space-between;
  626. align-items: center;
  627. .line {
  628. height: 100%;
  629. width: 1px;
  630. color: #dbdbdb;
  631. line-height: 40px;
  632. }
  633. .scanImg {
  634. width: 32px;
  635. height: 32px;
  636. cursor: pointer;
  637. }
  638. }
  639. img {
  640. width: 40px;
  641. height: 40px;
  642. }
  643. .text1 {
  644. margin-left: 8px;
  645. font-weight: bold;
  646. font-size: 18px;
  647. color: #030102;
  648. }
  649. .text2 {
  650. margin-left: 24px;
  651. font-weight: 400;
  652. font-size: 16px;
  653. color: #7c808d;
  654. .blueT {
  655. font-weight: 500;
  656. font-size: 16px;
  657. color: #2e8bf6;
  658. text-decoration-line: underline;
  659. }
  660. }
  661. .upload-show {
  662. width: 100px;
  663. height: 40px;
  664. }
  665. :deep(.el-upload) {
  666. width: 350px !important;
  667. display: flex !important;
  668. align-items: center !important;
  669. // height: 40px !important;
  670. }
  671. :deep(.el-upload-dragger) {
  672. padding: 0;
  673. border: none;
  674. display: flex;
  675. justify-content: flex-start !important;
  676. align-items: center !important;
  677. flex-direction: row !important;
  678. }
  679. }
  680. }
  681. .search {
  682. width: 1232px;
  683. // width: 600px;
  684. height: 64px;
  685. background-color: #2e8bf6;
  686. border-radius: 86px 86px 86px 86px;
  687. display: flex;
  688. justify-content: space-between;
  689. padding-right: 24px;
  690. .search_input {
  691. width: 1080px;
  692. height: 100%;
  693. border: none;
  694. outline: none;
  695. background-color: #fff;
  696. padding-left: 20px;
  697. border-radius: 86px 86px 86px 86px;
  698. }
  699. .searchBtn {
  700. color: #fff;
  701. font-size: 18px;
  702. cursor: pointer;
  703. display: flex;
  704. justify-content: center;
  705. align-items: center;
  706. span {
  707. margin-left: 8px;
  708. }
  709. }
  710. }
  711. .showSearch {
  712. width: 1424px !important;
  713. .search_input {
  714. width: 1272px !important;
  715. }
  716. }
  717. // 主页
  718. .btmBox {
  719. margin-top: 16px;
  720. width: 1232px;
  721. height: 624px;
  722. display: flex;
  723. justify-content: space-between;
  724. .upFile {
  725. width: 494px;
  726. height: 100%;
  727. background-color: #fff;
  728. border-radius: 16px 16px 16px 16px;
  729. display: flex;
  730. flex-direction: column;
  731. align-items: center;
  732. justify-content: center;
  733. .upImg {
  734. width: 194px;
  735. height: 128px;
  736. }
  737. .text1 {
  738. font-style: 18px;
  739. color: #030102;
  740. font-weight: bold;
  741. margin-top: 16px;
  742. margin-bottom: 8px;
  743. }
  744. .text2 {
  745. font-weight: 400;
  746. font-size: 16px;
  747. color: #7c808d;
  748. span {
  749. font-weight: 500;
  750. font-size: 16px;
  751. color: #2e8bf6;
  752. text-decoration-line: underline;
  753. }
  754. }
  755. .text3 {
  756. font-weight: 400;
  757. font-size: 14px;
  758. color: #7c808d;
  759. margin-top: 8px;
  760. }
  761. .line {
  762. margin-top: 16px;
  763. width: 124px;
  764. height: 1px;
  765. border-top: 1px solid #dbdbdb;
  766. }
  767. .scanImg {
  768. width: 32px;
  769. height: 32px;
  770. margin-top: 16px;
  771. cursor: pointer;
  772. }
  773. }
  774. .recent {
  775. width: 722px;
  776. height: 100%;
  777. background-color: #fff;
  778. border-radius: 16px 16px 16px 16px;
  779. padding: 24px;
  780. .top {
  781. width: 100%;
  782. height: 42px;
  783. border-bottom: 1px solid #dbdbdb;
  784. span {
  785. font-weight: bold;
  786. font-size: 18px;
  787. color: #030102;
  788. }
  789. }
  790. .list {
  791. width: 100%;
  792. height: calc(624px - 42px - 1px - 24px);
  793. overflow-y: auto;
  794. // padding-top: 12px;
  795. box-sizing: border-box;
  796. .oneBox {
  797. width: 100%;
  798. height: 60px;
  799. padding: 8px 22px;
  800. box-sizing: border-box;
  801. border-radius: 12px 12px 12px 12px;
  802. display: flex;
  803. align-items: center;
  804. .imgBox {
  805. width: 44px;
  806. height: 44px;
  807. border-radius: 8px 8px 8px 8px;
  808. border: 1px solid #d0d6e6;
  809. display: flex;
  810. justify-content: center;
  811. align-items: center;
  812. img {
  813. width: 32px;
  814. height: 32px;
  815. }
  816. }
  817. .rightBox {
  818. margin-left: 12px;
  819. width: calc(100% - 44px - 12px);
  820. display: flex;
  821. flex-direction: column;
  822. justify-content: space-between;
  823. .text {
  824. font-weight: bold;
  825. font-size: 16px;
  826. color: #030102;
  827. }
  828. .time {
  829. font-weight: 500;
  830. font-size: 12px;
  831. color: #7c808d;
  832. }
  833. }
  834. .openArrow {
  835. width: 20px;
  836. height: 20px;
  837. }
  838. &:hover {
  839. background: #f6f6f6;
  840. .imgBox {
  841. border: 1px solid #2e8bf6;
  842. }
  843. }
  844. }
  845. }
  846. }
  847. }
  848. // 搜索结果页面
  849. .searchBtm {
  850. width: 100%;
  851. height: 699px;
  852. margin-top: 16px;
  853. display: flex;
  854. justify-content: space-between;
  855. .highSearch {
  856. width: 936px;
  857. height: 699px;
  858. border-radius: 16px 16px 16px 16px;
  859. background: #ffffff;
  860. padding: 24px;
  861. .mainBox{
  862. width: 100%;
  863. height: 100%;
  864. }
  865. .title {
  866. width: 100%;
  867. height: 22px;
  868. font-weight: 400;
  869. font-size: 14px;
  870. line-height: 22px;
  871. }
  872. .list {
  873. margin-top: 12px;
  874. height: calc(100% - 48px - 12px);
  875. overflow-y: auto;
  876. .oneBox {
  877. width: 100%;
  878. // height: 120px;
  879. border-bottom: 1px dashed #c1cce3;
  880. padding-bottom: 16px;
  881. padding-top: 16px;
  882. .fileName {
  883. font-size: 16px;
  884. color: #2e6bc8;
  885. text-decoration: underline;
  886. font-family: Inter-SemiBold;
  887. cursor: pointer;
  888. }
  889. .flieTime {
  890. font-size: 12px;
  891. font-weight: 400;
  892. color: #7c808d;
  893. // line-height: 20px;
  894. vertical-align: middle;
  895. display: flex;
  896. align-items: center;
  897. margin: 4px 0;
  898. span {
  899. margin-left: 4px;
  900. }
  901. }
  902. .flieContent {
  903. width: 100%;
  904. font-size: 14px;
  905. color: #000000;
  906. font-weight: 400;
  907. line-height: 22px;
  908. display: -webkit-box;
  909. -webkit-box-orient: vertical;
  910. text-overflow: ellipsis;
  911. -webkit-line-clamp: 3; //超过3行显示省略号
  912. overflow: hidden;
  913. }
  914. }
  915. }
  916. }
  917. .allSearch {
  918. width: 936px;
  919. height: 699px;
  920. border-radius: 16px 16px 16px 16px;
  921. background: #ffffff;
  922. padding: 24px;
  923. .title {
  924. width: 100%;
  925. height: 42px;
  926. border-bottom: 1px solid #dbdbdb;
  927. span {
  928. font-weight: bold;
  929. font-size: 18px;
  930. color: #030102;
  931. }
  932. }
  933. .num {
  934. font-size: 14px;
  935. font-weight: 400;
  936. color: #555d72;
  937. margin-top: 12px;
  938. }
  939. .table_icon {
  940. height: 27px;
  941. width: 27px;
  942. vertical-align: middle;
  943. }
  944. //表格文本超出隐藏
  945. :deep(.flie_name, .folder) {
  946. /*第一步: 溢出隐藏 */
  947. overflow: hidden;
  948. /* 第二步:让文本不会换行, 在同一行继续 */
  949. white-space: nowrap;
  950. /* 第三步:用省略号来代表未显示完的文本 */
  951. text-overflow: ellipsis;
  952. }
  953. }
  954. }
  955. .lodingBox {
  956. position: relative;
  957. width: 100%;
  958. height: 100%;
  959. z-index: 10000000;
  960. }
  961. .checkScan {
  962. background-color: #f5f7f9;
  963. }
  964. #Onescan {
  965. height: 48px;
  966. line-height: 48px;
  967. font-size: 14px;
  968. display: flex;
  969. align-items: center;
  970. }
  971. ::v-deep .el-upload-dragger {
  972. display: flex;
  973. flex-direction: column;
  974. justify-content: center;
  975. }
  976. //关键字背景色
  977. :deep(em) {
  978. background: #fff0ba !important;
  979. }
  980. .hoverColor {
  981. &:hover {
  982. background-color: #236ec3;
  983. }
  984. }
  985. </style>