ListItem.vue 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781
  1. <template>
  2. <div class="data-fill-list-box">
  3. <el-collapse v-model="ActiveKey" accordion @change="CollapseChange">
  4. <template v-for="(item,index) in listDatas" :key="item?.pkeyId">
  5. <el-collapse-item :name="`item-${index}-${item?.pkeyId}`" :disabled="item['isBussShow'] === 2" :id="`item-${index}-${item?.pkeyId}`">
  6. <template #title>
  7. <div class="hc-collapse-item-header">
  8. <div class="text-lg truncate item-title">{{item.deptName}}</div>
  9. <div class="hc-extra-text-box">
  10. <HcTooltip keys="wbs_del_table" v-if="item['isCopeTab'] === 2">
  11. <el-button type="danger" plain :disabled="item['isBussShow'] === 2" @click.stop="delClick(item,index)">删除本表</el-button>
  12. </HcTooltip>
  13. <HcTooltip keys="wbs_copy_table">
  14. <el-button type="primary" plain :disabled="item['isBussShow'] === 2" @click.stop="copyClick(item,index)">复制本表</el-button>
  15. </HcTooltip>
  16. <HcTooltip keys="wbs_hide_table">
  17. <el-button type="primary" plain @click.stop="hideClick(item,index)">
  18. <template v-if="item['isBussShow'] === 1">隐藏本表</template>
  19. <template v-else>显示本表</template>
  20. </el-button>
  21. </HcTooltip>
  22. <HcTooltip keys="wbs_preview_table">
  23. <el-button type="primary" plain :disabled="item['isBussShow'] === 2 || item['isTabPdf'] === 1" @click.stop="previewClick(item,index)">预览</el-button>
  24. </HcTooltip>
  25. <HcTooltip keys="wbs_upload_table">
  26. <el-button :type="item['tabFileType'] === 2?'success':'primary'" plain :disabled="item['isBussShow'] === 2" @click.stop="uploadClick(item,index)">
  27. <template v-if="item['tabFileType'] === 2">已上传</template>
  28. <template v-else>上传</template>
  29. </el-button>
  30. </HcTooltip>
  31. </div>
  32. </div>
  33. </template>
  34. <div class="data-fill-list-item-content">
  35. <div class="data-fill-table-form-box">
  36. <div :id="`table-form-${item?.pkeyId}`"/>
  37. <div class="hc-no-table-form" v-if="item?.isTableForm === false">
  38. <div class="table-form-no">
  39. <img :src="notableform" alt=""/>
  40. <div class="desc">暂无表单数据</div>
  41. </div>
  42. </div>
  43. </div>
  44. <div class="data-fill-table-tip-box">
  45. <div class="text-orange tip-title">
  46. <HcIcon name="error" fill ui="text-2xl"/>
  47. <span class="ml-1">提示</span>
  48. </div>
  49. <div class="text-gray-400 tip-item">1、灰色框代表可通过系统识别计算,公式自动引用,可通过公式计算少量数据,(表头数据及简单),也可只填写白色框数据</div>
  50. <div class="text-gray-400 tip-item">2、系统支持键盘中,shift + tab键向上一个填报框切换,tab向下一个填报框切换。暂不支持上下按键切换输入框</div>
  51. <div class="table-tip-foot">
  52. <div class="tip-left-btn">
  53. <HcTooltip keys="wbs_import_table">
  54. <div class="text-gray-400 dow-text">
  55. <HcIcon name="publish" ui="text-lg"/>
  56. <span class="ml-1">导入列表数据</span>
  57. </div>
  58. </HcTooltip>
  59. <HcTooltip keys="wbs_download_table">
  60. <div class="text-main dow-text">
  61. <HcIcon name="file_download" ui="text-lg"/>
  62. <span class="ml-1">下载导入模板</span>
  63. </div>
  64. </HcTooltip>
  65. </div>
  66. <div class="tip-right-btn">
  67. <HcTooltip keys="wbs_save_table">
  68. <el-button type="primary" hc-btn size="large" @click="tableFormSaveClick(item,index)">保存</el-button>
  69. </HcTooltip>
  70. </div>
  71. </div>
  72. </div>
  73. </div>
  74. </el-collapse-item>
  75. </template>
  76. </el-collapse>
  77. </div>
  78. <!--右键菜单-->
  79. <HcContextMenu ref="contextMenuRef" :datas="tableFormMenu" @item-click="handleMenuSelect"></HcContextMenu>
  80. <!--上传文件-->
  81. <el-dialog v-model="uploadModal" title="上传文件" width="38rem" class="hc-modal-border">
  82. <HcUpload :fileList="fileListData" :datas="uploadData" @change='uploadChange'/>
  83. </el-dialog>
  84. <!--插入设计值/频率-->
  85. <el-dialog v-model="IDVFModal" title="插入设计值/频率" width="600px" class="hc-modal-border">
  86. <el-alert title="填写完设计值和频率,系统自动计算实测值" type="warning" :closable="false"/>
  87. <el-form ref="formIDVFRef" :model="formIDVFModel" :rules="formIDVFRules" label-width="auto" size="large">
  88. <el-form-item label="设计值" prop="designValue">
  89. <el-input v-model="formIDVFModel.designValue" placeholder="请输入设计值"/>
  90. </el-form-item>
  91. <el-form-item label="频率" prop="frequency">
  92. <el-input v-model="formIDVFModel.frequency" placeholder="请输入频率"/>
  93. </el-form-item>
  94. </el-form>
  95. <template #footer>
  96. <div class="dialog-footer">
  97. <el-button size="large" @click="IDVFModal = false">取消</el-button>
  98. <el-button type="primary" hc-btn @click="IDVFModal = false">确认插入</el-button>
  99. </div>
  100. </template>
  101. </el-dialog>
  102. <!--插入特殊字符-->
  103. <el-dialog v-model="specialModal" title="插入特殊字符" width="600px" class="hc-modal-border">
  104. <el-form ref="specialFormRef" :model="specialFormModel" :rules="specialFormRules" label-width="0px" size="large" class="mb-6">
  105. <el-form-item prop="val" class="special-form-item">
  106. <el-input v-model="specialFormModel.val" ref="specialRef" id="specialId" placeholder="请选择特殊字符代码" clearable @blur="specialInputBlur"/>
  107. </el-form-item>
  108. </el-form>
  109. <el-row :gutter="20" style="margin: -10px;">
  110. <el-col :span="3" style="padding: 10px;" v-for="item in specialCharacters">
  111. <div class="special-box" @click="specialClick">
  112. <span class="font-EUDC" :title="`字符代码(C):${item !== 'K̅'?item.slice(2,7):'K̅'}`" v-html="item"/>
  113. </div>
  114. </el-col>
  115. </el-row>
  116. <template #footer>
  117. <div class="dialog-footer">
  118. <el-button size="large" @click="specialModal = false">取消</el-button>
  119. <el-button type="primary" hc-btn @click="specialNodeClick">确认插入</el-button>
  120. </div>
  121. </template>
  122. </el-dialog>
  123. <!--关联试验数据-->
  124. <el-dialog v-model="CTDModal" title="关联试验数据" width="850px" class="hc-modal-border">
  125. 开发中...
  126. <template #footer>
  127. <div class="dialog-footer">
  128. <el-button size="large" @click="CTDModal = false">取消</el-button>
  129. <el-button type="primary" hc-btn @click="CTDModal = false">确认</el-button>
  130. </div>
  131. </template>
  132. </el-dialog>
  133. </template>
  134. <script setup>
  135. import {ref,watch,nextTick} from "vue";
  136. import notableform from '~src/assets/view/notableform.svg';
  137. import {HTableForm} from "~src/plugins/HTableForm"
  138. import wbsApi from "~api/data-fill/wbs"
  139. import HcUpload from "./HcUpload.vue"
  140. import {utilsText, isType, toParse, formValidate,deepClone} from "vue-utils-plus"
  141. //初始
  142. const props = defineProps({
  143. datas: {
  144. type: Array,
  145. default: () => ([])
  146. },
  147. classify: {
  148. type: [String,Number],
  149. default: ''
  150. },
  151. status: {
  152. type: [String,Number],
  153. default: ''
  154. },
  155. })
  156. const {isString, getObjNullValue, getArrValue} = isType()
  157. const {setPosInsert, setPosRange} = utilsText()
  158. const listDatas = ref(props.datas)
  159. const classify = ref(props.classify)
  160. const isStatus = ref(props.status)
  161. //监听
  162. watch(() => [
  163. props.datas,
  164. props.classify,
  165. ], ([datas, classifyVal]) => {
  166. listDatas.value = datas
  167. classify.value = classifyVal
  168. setFormDataNum(datas)
  169. })
  170. //监听
  171. watch(() => [
  172. props.status
  173. ], ([val]) => {
  174. //1 未填报,2待上报,3已上报
  175. isStatus.value = val
  176. })
  177. //渲染完成
  178. nextTick(() => {
  179. setFormDataNum(props.datas)
  180. })
  181. //获取表单初始数据
  182. const getFormDataInit = (item, pkeyId) => {
  183. return {
  184. projectId: item?.projectId,
  185. contractId: item?.contractId,
  186. classify: classify.value,
  187. pkeyId: pkeyId ? pkeyId + '' : '',
  188. }
  189. }
  190. //设置表单对象的数量
  191. const formData = ref([])
  192. const setFormDataNum = (datas) => {
  193. let newArr = [];
  194. for (let i = 0; i < datas.length; i++) {
  195. newArr.push(getFormDataInit(datas[i], datas[i].pkeyId))
  196. }
  197. formData.value = newArr
  198. }
  199. //展开事件
  200. const ActiveKey = ref('')
  201. const CollapseChange = (name) => {
  202. ActiveKey.value = name
  203. const names = name ? name.split('-') : []
  204. if (names.length > 0) {
  205. getOffsetTop(name)
  206. const index = names[1]
  207. const item = listDatas.value[index]
  208. if (!item.isTableFormRender) {
  209. //渲染表单
  210. getExcelHtml(item,index)
  211. //获取已填写的数据
  212. getBussDataInfo(item,item.pkeyId, index)
  213. }
  214. } else {
  215. getOffsetTop()
  216. }
  217. }
  218. //获取模板标签数据
  219. const getExcelHtml = async (item,index) => {
  220. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  221. if (pkeyIds) {
  222. const {error, code, data} = await wbsApi.getExcelHtml({pkeyId: pkeyIds}, false)
  223. const resData = isString(data) ? data || '' : ''
  224. if (!error && code === 200 && resData) {
  225. item.isTableForm = true
  226. //渲染表单
  227. HTableForm({
  228. template: resData,
  229. tableForm: formData.value[index],
  230. appId: `#table-form-${pkeyIds}`,
  231. onRight: (event, KeyName) => {
  232. onRightClick(event, KeyName, index)
  233. }
  234. })
  235. item.isTableFormRender = true
  236. } else {
  237. item.isTableForm = false
  238. window?.$message?.warning('暂无表单')
  239. }
  240. } else {
  241. item.isTableForm = false
  242. window?.$message?.warning('pkeyId为空')
  243. }
  244. }
  245. //获取已填写的数据
  246. const getBussDataInfo = async (item,pkeyId, index) => {
  247. const pkeyIds = pkeyId ? pkeyId + '' : ''
  248. if (pkeyIds) {
  249. const {error, code, data} = await wbsApi.getBussDataInfo({pkeyId: pkeyIds}, false)
  250. const resData = getObjNullValue(data)
  251. if (!error && code === 200 && resData) {
  252. //处理日期范围数据
  253. const pickerKey = resData['pickerKey'] || ''
  254. const pickerKeys = pickerKey.split(',')
  255. for (let i = 0; i < pickerKeys.length; i++) {
  256. const val = resData[pickerKeys[i]] || ''
  257. if (val) {
  258. const data = val.replace(/'/g,'"');
  259. resData[pickerKeys[i]] = toParse(data) || []
  260. } else {
  261. resData[pickerKeys[i]] = []
  262. }
  263. }
  264. //有数据,关联数据
  265. const InitObj = getFormDataInit(item, pkeyId)
  266. formData.value[index] = { ...resData, ...InitObj}
  267. } else {
  268. formData.value[index] = getFormDataInit(item, pkeyId)
  269. }
  270. } else {
  271. window?.$message?.warning('pkeyId为空')
  272. }
  273. }
  274. //单个保存
  275. const tableFormSaveClick = async (item,index) => {
  276. if (isStatus.value !== '3') {
  277. const res = await saveExcelBussData(item,index)
  278. if (res) {
  279. await getBussPdfInfo(item)
  280. renewData()
  281. }
  282. } else {
  283. window?.$message?.warning('已上报的资料,不允许保存。')
  284. }
  285. }
  286. //保存表单数据
  287. const saveExcelBussData = async (item, index, showTip = true) => {
  288. const InitObj = getFormDataInit(item, item.pkeyId)
  289. const {error, code, data} = await wbsApi.saveExcelBussData({
  290. ...formData.value[index],
  291. ...InitObj
  292. }, false)
  293. //处理数据
  294. if (!error && code === 200) {
  295. if(showTip) window?.$message?.success('保存成功')
  296. return true
  297. } else {
  298. if(showTip) window?.$message?.warning(data.msg || '保存失败')
  299. return false
  300. }
  301. }
  302. //预览PDF
  303. const getBussPdfInfo = async (item, showTip = true) => {
  304. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  305. if (pkeyIds) {
  306. const {error, code, data} = await wbsApi.getBussPdfInfo({
  307. pkeyId: pkeyIds
  308. },false)
  309. if (!error && code === 200) {
  310. if (data) {
  311. window.open(data, '_blank')
  312. } else if(showTip) {
  313. window?.$message?.warning('PDF错误')
  314. }
  315. } else {
  316. if(showTip) {
  317. window?.$message?.warning(data.msg || '获取PDF失败')
  318. }
  319. }
  320. } else {
  321. window?.$message?.warning('pkeyId为空')
  322. }
  323. }
  324. //删除本表
  325. const delClick = async (item) => {
  326. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  327. if (pkeyIds) {
  328. if (isStatus.value !== '3') {
  329. const {error, code} = await wbsApi.removeBussTabInfo({
  330. pkeyid: pkeyIds,
  331. classify: classify.value,
  332. })
  333. if (!error && code === 200) {
  334. window?.$message?.warning('操作成功')
  335. renewData()
  336. }
  337. } else {
  338. window?.$message?.warning('已上报的资料,不允许删除')
  339. }
  340. } else {
  341. window?.$message?.warning('pkeyId为空')
  342. }
  343. }
  344. //复制本表
  345. const copyClick = async (item,index) => {
  346. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  347. if (pkeyIds) {
  348. if (isStatus.value !== '3') {
  349. const res = await saveExcelBussData(item,index,false)
  350. if (res) {
  351. const {error, code} = await wbsApi.copeBussTab({pkeyId: pkeyIds})
  352. if (!error && code === 200) {
  353. window?.$message?.warning('操作成功')
  354. renewData()
  355. }
  356. } else {
  357. window?.$message?.warning('复制本表操作失败')
  358. }
  359. } else {
  360. window?.$message?.warning('已上报的资料,不允许复制')
  361. }
  362. } else {
  363. window?.$message?.warning('pkeyId为空')
  364. }
  365. }
  366. //隐藏本表
  367. const hideClick = async (item) => {
  368. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  369. if (pkeyIds) {
  370. if (isStatus.value !== '3') {
  371. const isBussShow = item['isBussShow'] === 2 ? 1 : 2 //状态(1显示 2隐藏)
  372. const {error, code} = await wbsApi.showBussTab({
  373. pkeyId: pkeyIds,
  374. status: isBussShow
  375. })
  376. if (!error && code === 200) {
  377. window?.$message?.warning('操作成功')
  378. renewData()
  379. }
  380. } else {
  381. window?.$message?.warning('已上报的资料,不允许隐藏')
  382. }
  383. } else {
  384. window?.$message?.warning('pkeyId为空')
  385. }
  386. }
  387. //预览
  388. const previewClick = async (item,index) => {
  389. await getBussPdfInfo(item)
  390. }
  391. //上传变量
  392. const uploadModal = ref(false)
  393. const fileListData = ref([]);
  394. const uploadData = ref({})
  395. //上传被点击
  396. const uploadClick = (item) => {
  397. const pkeyIds = item.pkeyId ? item.pkeyId + '' : ''
  398. if (pkeyIds) {
  399. if (isStatus.value !== '3') {
  400. uploadModal.value = true
  401. uploadData.value = getFormDataInit(item,pkeyIds)
  402. //获取文件列表
  403. getBussFileList(pkeyIds)
  404. } else {
  405. window?.$message?.warning('已上报的资料,不允许上传')
  406. }
  407. } else {
  408. window?.$message?.warning('pkeyId为空')
  409. }
  410. }
  411. //获取文件列表
  412. const getBussFileList = async (pkeyId) => {
  413. const {error, code, data} = await wbsApi.getBussFileList({
  414. pkeyid: pkeyId
  415. })
  416. if (!error && code === 200) {
  417. fileListData.value = getArrValue(data)
  418. } else {
  419. fileListData.value = []
  420. }
  421. }
  422. //上传文件
  423. const uploadChange = async ({type}) => {
  424. if(type === 'success') {
  425. uploadModal.value = false
  426. renewData()
  427. } else if (type === 'del') {
  428. renewData()
  429. }
  430. }
  431. //相关变量
  432. const tableFormItemNode = ref({})
  433. //菜单数据
  434. const tableFormMenu = ref([
  435. {label: '插入设计值/频率', key: "IDVF"},
  436. {label: '插入特殊字符', key: "special"},
  437. {label: '关联试验数据', key: "CTD"},
  438. ])
  439. //鼠标右键事件
  440. const contextMenuRef = ref(null)
  441. const onRightClick = (event, KeyName, index) => {
  442. //取光标位置
  443. const specialDom = document.getElementById(KeyName + "")
  444. const startPos = specialDom?.selectionStart || 0
  445. const endPos = specialDom?.selectionEnd || 0
  446. //存储临时信息
  447. tableFormItemNode.value = {KeyName, index, startPos, endPos}
  448. contextMenuRef.value?.showMenu(event) //展开菜单
  449. }
  450. //鼠标右键菜单被点击
  451. const handleMenuSelect = ({key}) => {
  452. if (key === 'IDVF') {
  453. IDVFModal.value = true
  454. } else if (key === 'special') {
  455. specialModalShow()
  456. } else if (key === 'CTD') {
  457. CTDModal.value = true
  458. }
  459. }
  460. //插入设计值
  461. const IDVFModal = ref(false)
  462. const formIDVFRef = ref(null)
  463. const formIDVFModel = ref({designValue: '', frequency: ''})
  464. const formIDVFRules = {
  465. designValue: {
  466. required: true,
  467. trigger: "blur",
  468. message: "请输入设计值"
  469. },
  470. frequency: {
  471. required: true,
  472. trigger: "blur",
  473. message: "请输入频率"
  474. }
  475. }
  476. //插入特殊字符
  477. const specialModal = ref(false)
  478. const specialCharacters = ref([
  479. '&#57344;', "&#57345;", "&#57346;", "&#57347;", '&#8804;', '&#8805;', '&#8451;',
  480. '&#9312;', '&#9313;', '&#9314;', '&#9315;', '&#9316;', '&#9317;', '&#9318;', '&#9319;', '&#9320;', '&#9321;', '&#9322;', '&#9323;',
  481. '&#9324;', '&#9325;', '&#9326;', '&#9327;', '&#9328;', '&#9329;', '&#9330;', '&#9331;',
  482. "&#8544;", "&#8545;", "&#8546;", "&#8547;", "&#8548;", "&#8549;", "&#8550;", "&#8551;", "&#8552;", "&#8553;", "&#8554;", "&#8555;","K̅"
  483. ])
  484. //输入框验证
  485. const specialFormRef = ref(null)
  486. const specialFormModel = ref({val: ''})
  487. const specialFormRules = {
  488. val: {
  489. required: true,
  490. trigger: "blur",
  491. message: "请选择特殊字符代码"
  492. }
  493. }
  494. //显示插入特殊字符
  495. const specialRef = ref(null)
  496. const specialModalShow = () => {
  497. specialFormModel.value.val = ''
  498. specialModal.value = true
  499. nextTick(() => {
  500. specialRef.value?.focus();
  501. })
  502. }
  503. //失去焦点
  504. const specialPos = ref({start: 0, end: 0})
  505. const specialInputBlur = (e) => {
  506. specialPos.value = {
  507. start: e?.target?.selectionStart || 0,
  508. end: e?.target?.selectionEnd || 0
  509. }
  510. }
  511. //点击符号
  512. const specialClick = (event) => {
  513. const text = event?.target?.innerText ?? ''
  514. const start = specialPos.value.start
  515. const end = specialPos.value.end
  516. const form = specialFormModel.value.val
  517. specialFormModel.value.val = setPosInsert(start, end, form, text)
  518. specialRef.value?.focus();
  519. let posVal = start + text.length;
  520. nextTick(() => {
  521. setPosRange('specialId', posVal)
  522. })
  523. }
  524. //确认插入
  525. const specialNodeClick = async () => {
  526. const res = await formValidate(specialFormRef.value)
  527. if (res) {
  528. const item = tableFormItemNode.value
  529. const form = formData.value[item.index]
  530. const val = specialFormModel.value.val ?? ''
  531. formData.value[item.index][item.KeyName] = setPosInsert(item.startPos, item.endPos, form[item.KeyName], val)
  532. specialModal.value = false
  533. specialRef.value?.focus();
  534. let posVal = item.startPos + val.length;
  535. nextTick(() => {
  536. setPosRange(item.KeyName, posVal)
  537. })
  538. }
  539. }
  540. //关联试验数据
  541. const CTDModal = ref(false)
  542. //事件
  543. const emit = defineEmits(['renew','offsetTop'])
  544. //被点击
  545. const getOffsetTop = (key = '') => {
  546. if (key) {
  547. const dom = document.getElementById(key)
  548. emit('offsetTop', dom.offsetTop)
  549. } else {
  550. emit('offsetTop', 0)
  551. }
  552. }
  553. //通知数据更新
  554. const renewData = () => {
  555. emit('renew')
  556. ActiveKey.value = ''
  557. }
  558. //获取表单数据
  559. const getFormData = () => {
  560. const formArr = deepClone(formData.value);
  561. return formArr.filter((item) => {
  562. return (item.pkeyId??'') !== '';
  563. })
  564. }
  565. // 暴露出去
  566. defineExpose({
  567. getFormData
  568. })
  569. </script>
  570. <style lang="scss" scoped>
  571. .data-fill-list-box {
  572. position: relative;
  573. .hc-collapse-item-header {
  574. flex: 1;
  575. position: relative;
  576. margin-left: 46px;
  577. display: flex;
  578. align-items: center;
  579. .item-title {
  580. flex: 1;
  581. position: relative;
  582. user-select: none;
  583. color: #50545E;
  584. font-size: 16px;
  585. font-weight: 400;
  586. cursor: pointer;
  587. }
  588. .hc-extra-text-box {
  589. position: relative;
  590. padding-right: 24px;
  591. }
  592. }
  593. .data-fill-list-item-content {
  594. position: relative;
  595. display: flex;
  596. height: calc(100vh - 386px);
  597. .data-fill-table-form-box {
  598. position: relative;
  599. padding: 24px 20px;
  600. height: 100%;
  601. overflow: auto;
  602. flex: 1;
  603. .hc-no-table-form {
  604. position: relative;
  605. height: 100%;
  606. display: flex;
  607. justify-content: center;
  608. align-items: center;
  609. .table-form-no {
  610. position: relative;
  611. img {
  612. width: 350px;
  613. }
  614. .desc {
  615. text-align: center;
  616. font-size: 20px;
  617. color: #aaa;
  618. }
  619. }
  620. }
  621. }
  622. .data-fill-table-tip-box {
  623. width: 240px;
  624. position: relative;
  625. border-left: 1px solid #E9E9E9;
  626. padding: 20px 15px 80px;
  627. .tip-title {
  628. font-size: 16px;
  629. margin-bottom: 10px;
  630. display: flex;
  631. align-items: center;
  632. }
  633. .tip-item {
  634. margin-bottom: 20px;
  635. }
  636. .table-tip-foot {
  637. position: absolute;
  638. bottom: 15px;
  639. right: 0;
  640. left: 0;
  641. display: flex;
  642. align-items: center;
  643. padding: 0 15px;
  644. .tip-left-btn {
  645. flex: 1;
  646. .dow-text {
  647. cursor: pointer;
  648. display: flex;
  649. align-items: center;
  650. }
  651. }
  652. }
  653. }
  654. }
  655. }
  656. .special-box {
  657. position: relative;
  658. display: flex;
  659. justify-content: center;
  660. align-items: center;
  661. border: 1px solid #eee;
  662. border-radius: 3px;
  663. height: 52px;
  664. width: 52px;
  665. cursor: pointer;
  666. user-select: none;
  667. transition: color .3s, background-color .3s;
  668. &:hover {
  669. color: var(--el-color-primary);
  670. background-color: var(--el-color-primary-light-8);
  671. }
  672. .font-EUDC {
  673. font-size: 22px;
  674. }
  675. }
  676. </style>
  677. <style lang="scss">
  678. .data-fill-list-box {
  679. .el-collapse {
  680. --el-collapse-header-height: 60px;
  681. border: 0;
  682. .el-collapse-item {
  683. margin: 0 0 16px;
  684. background-color: #f1f5f8;
  685. border: 1px solid #E9E9E9;
  686. border-radius: 4px;
  687. }
  688. .el-collapse-item__header {
  689. background-color: transparent;
  690. font-weight: 400;
  691. border-bottom: 0;
  692. cursor: default;
  693. font-size: 14px;
  694. .el-collapse-item__arrow {
  695. position: absolute;
  696. color: #50545E;
  697. cursor: pointer;
  698. left: 20px;
  699. margin: 0;
  700. }
  701. }
  702. .el-collapse-item.is-active .el-collapse-item__header.is-active {
  703. background-color: #E7EEF4;
  704. }
  705. .el-collapse-item__wrap {
  706. background-color: transparent;
  707. border-bottom: 0;
  708. .el-collapse-item__content {
  709. position: relative;
  710. padding-bottom: 0;
  711. font-size: 14px;
  712. color: #50545E;
  713. line-height: initial;
  714. }
  715. }
  716. }
  717. //设置表单样式
  718. .data-fill-table-form-box {
  719. td {
  720. padding: 6px;
  721. .el-input {
  722. background-color: #ffffff !important;
  723. border-radius: 3px;
  724. .el-input__wrapper {
  725. background-color: inherit;
  726. }
  727. .el-input__wrapper.is-focus, .el-input__wrapper:hover {
  728. box-shadow: 0 0 0 1.5px var(--el-input-focus-border-color) inset;
  729. background-color: #eddac4;
  730. }
  731. //公式 #dcdcdc
  732. //焦点 #eddac4
  733. }
  734. }
  735. }
  736. }
  737. //插入特殊字符弹窗的输入框
  738. .data-fill-list-box .data-fill-table-form-box td,
  739. .data-fill-list-box .data-fill-table-form-box td .el-input .el-input__wrapper .el-input__inner,
  740. .el-form-item.special-form-item .el-form-item__content .el-input .el-input__wrapper .el-input__inner {
  741. font-family: "EUDC", 宋体, v-sans, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  742. }
  743. </style>