LtModal.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806
  1. <template>
  2. <div class="modal-container">
  3. <div class="cover"></div>
  4. <div class="modal-box">
  5. <div class="modal-title">
  6. <span class="title-l">{{title}}{{tip}}</span>
  7. <a class="close" @click="closeModal()">×</a>
  8. </div>
  9. <div class="modal-body">
  10. <el-form
  11. :model="form"
  12. :rules="rules"
  13. label-position="right"
  14. label-width="145px"
  15. ref="relationForm"
  16. >
  17. <div class="AddChemicalAndCommonMappingBox clearfix">
  18. <div class="titleBox clearfix">
  19. <p class="title">医院术语</p>
  20. <p class="title">标准术语</p>
  21. </div>
  22. <div class="leftBox clearfix">
  23. <el-row>
  24. <el-col :span="16">
  25. <el-form-item :label="meal+':'" prop="hisName">
  26. <el-input
  27. v-model.trim="form.hisName"
  28. clearable
  29. style="minWidth: 240px"
  30. @input="onchange"
  31. @blur="onblur"
  32. ></el-input>
  33. </el-form-item>
  34. <el-form-item :label="meal+'预览:'">
  35. <span class="previewInfo" style="minWidth: 240px">{{form.hisName}}</span>
  36. </el-form-item>
  37. <el-form-item label="科室编码:" prop="hisCode" v-if="type==7">
  38. <el-input v-model.trim="form.hisCode" clearable style="minWidth: 240px"></el-input>
  39. </el-form-item>
  40. </el-col>
  41. <el-col :span="16" v-if="type == 1 || type == 2">
  42. <el-form-item :label="detail+':'" prop="hisDetailName">
  43. <el-input
  44. v-model.trim="form.hisDetailName"
  45. clearable
  46. style="minWidth: 240px"
  47. @input="onchange"
  48. @blur="onblur"
  49. @clear="clear"
  50. ></el-input>
  51. </el-form-item>
  52. <el-form-item :label="detail+'预览:'">
  53. <span class="previewInfo" style="minWidth: 240px">{{form.hisDetailName}}</span>
  54. </el-form-item>
  55. </el-col>
  56. </el-row>
  57. </div>
  58. <div class="midBox">
  59. <img class="midLogo" src="../../images/relation.png" alt />
  60. <p class="midTitle">相互关联</p>
  61. </div>
  62. <div class="rightBox">
  63. <el-row>
  64. <el-col :span="16">
  65. <el-form-item :label="standard+':'" prop="searchText">
  66. <el-select
  67. style="width:100%;minWidth: 240px"
  68. v-model="form.searchText"
  69. filterable
  70. remote
  71. clearable
  72. :loading="showDrop"
  73. loading-text="加载中..."
  74. @change="changeWord"
  75. @focus="handleFocus"
  76. @visible-change="handleVisible"
  77. placeholder="搜索"
  78. :remote-method="searchTerms"
  79. reserve-keyword
  80. >
  81. <el-option
  82. v-for="item in uniqueNameList"
  83. :key="item.icd10Code"
  84. :label="searchType == 2 ? `${item.uniqueName}(${item.name})` : item.name"
  85. :value="searchType == 2 ? `${item.uniqueName}` : item"
  86. :title="searchType == 2 ? `${item.uniqueName}(${item.name})` : item.name"
  87. @click.native="handleChoose(searchType == 2 ? `${item.uniqueName}` : item.name,item.id)"
  88. ></el-option>
  89. </el-select>
  90. </el-form-item>
  91. <el-form-item v-if="tableData.length >0">
  92. <el-table
  93. :header-row-style="{height:'40px'}"
  94. :header-cell-style="{height:'40px',padding:'0'}"
  95. :row-class-name="tableRowClassName"
  96. :row-style="selectedstyle"
  97. :data="tableData"
  98. @row-click="btn"
  99. class="tab"
  100. border
  101. >
  102. <el-table-column prop="name" :show-overflow-tooltip="true" label="词名"></el-table-column>
  103. <el-table-column prop="address" :show-overflow-tooltip="true" label="来源">
  104. <template slot-scope="scope">
  105. <p>{{scope.row.source == 1?'标准词匹配':scope.row.source == 2?'同义词匹配':scope.row.source == 5?'相似词匹配':''}}</p>
  106. </template>
  107. </el-table-column>
  108. </el-table>
  109. </el-form-item>
  110. <el-form-item :label="standard+'预览:'">
  111. <!-- <span class="previewInfo">{{!isEdit ? form.searchText.name : form.searchText}}</span> -->
  112. <span class="previewInfo" style="minWidth: 240px">{{form.searchText}}</span>
  113. </el-form-item>
  114. <el-form-item label="ICD编码:" v-if="type == 4">
  115. <span class="previewInfo" style="minWidth: 240px">{{form.icdCode}}</span>
  116. </el-form-item>
  117. <el-form-item :label="detail+':'" v-if="type == 12 || type == 13 || type == 6">
  118. <span class="previewInfo" style="minWidth: 240px">{{form.icdCode}}</span>
  119. </el-form-item>
  120. <el-form-item label="药品剂型:" v-if="type == 5">
  121. <el-select
  122. style="width:100%;minWidth: 240px"
  123. v-model="form.form"
  124. filterable
  125. remote
  126. clearable
  127. :loading="showDrop"
  128. loading-text="加载中..."
  129. @change="drugchangeWord"
  130. @focus="handleFocus"
  131. @visible-change="handleVisible"
  132. placeholder="搜索"
  133. :remote-method="searchDrug"
  134. reserve-keyword
  135. >
  136. <el-option
  137. v-for="item in drugList"
  138. :key="item.icd10Code"
  139. :label="item.name"
  140. :value="item"
  141. :title="item.name"
  142. ></el-option>
  143. </el-select>
  144. </el-form-item>
  145. </el-col>
  146. </el-row>
  147. </div>
  148. </div>
  149. </el-form>
  150. </div>
  151. <div class="mapList">
  152. 已关联标准术语:
  153. <span v-for="item in mapList" :key="item.id">
  154. <span v-if="item.uniqueName">{{item.uniqueName}}&nbsp;&nbsp;{{item.form}}{{item.hisCode}};</span>
  155. </span>
  156. </div>
  157. <div class="modal-footer">
  158. <button class="confirm btns" :disabled="saveDisable" @click="submitForm">确定</button>
  159. <button class="cancel btns" @click="closeModal">取消</button>
  160. </div>
  161. </div>
  162. </div>
  163. </template>
  164. <script>
  165. import api from '@api/cdss.js';
  166. import config from '@api/config.js';
  167. import utils from '@api/utils.js';
  168. export default {
  169. name: 'lt-modal',
  170. props: [
  171. 'modalVisiable',
  172. 'meal',
  173. 'detail',
  174. 'standard',
  175. 'type',
  176. 'data',
  177. 'hospitalId',
  178. 'tip'
  179. ],
  180. data() {
  181. return {
  182. form: {
  183. searchText: '', //搜索字段
  184. hisName: '',
  185. icdCode: '',
  186. hisDetailName: '',
  187. formConceptId: '',
  188. conceptId: '',
  189. form: '',
  190. hisCode: '',
  191. source: ''
  192. },
  193. showDrop: false, //下拉框显示文字
  194. saveDisable: false, //保存按钮禁止点击
  195. uniqueNameList: [],
  196. rules: {
  197. hisName: [
  198. { required: true, message: '请输入' + this.meal, trigger: 'change' },
  199. { max: 80, message: this.meal + '最多80字', trigger: 'change' }
  200. ],
  201. searchText: [
  202. { required: true, message: '请选择' + this.meal, trigger: 'change' }
  203. ]
  204. },
  205. isEdit: false,
  206. editId: '',
  207. drugList: [],
  208. tableData: [],
  209. mapList: [],
  210. getIndex: 6,
  211. ty: this.type,
  212. searchType: '',
  213. title: '添加'
  214. };
  215. },
  216. created() {
  217. //修改
  218. if (this.type == 1) {
  219. this.ty = 2; // 1-化验大项、2-化验小项
  220. }
  221. if (JSON.stringify(this.data) != '{}') {
  222. this.title = '修改';
  223. this.isEdit = true;
  224. this.editId = this.data.id;
  225. this.form.hisName = this.data.hisName;
  226. this.form.hisDetailName = this.data.hisDetailName
  227. ? this.data.hisDetailName
  228. : '';
  229. this.form.searchText = this.data.uniqueName;
  230. this.form.icdCode = this.data.code;
  231. this.form.conceptId = this.data.conceptId;
  232. this.form.formConceptId = this.data.formConceptId;
  233. this.form.form = this.data.form;
  234. this.form.source = this.data.source;
  235. this.form.hisCode = this.data.hisCode;
  236. let name;
  237. if (
  238. (this.data.hisDetailName == null || this.data.hisDetailName === '') &&
  239. this.data.hisName !== '' &&
  240. this.type == 1
  241. ) {
  242. this.ty = 1; // 1-化验大项、2-化验小项
  243. this.searchType = 1;
  244. name = this.data.hisName;
  245. } else if (
  246. this.data.hisName !== '' &&
  247. this.data.hisDetailName !== '' &&
  248. this.type == 1
  249. ) {
  250. this.ty = 2;
  251. this.searchType = 2;
  252. name = this.data.hisDetailName;
  253. }
  254. console.log(this.ty);
  255. this.getTermMatching(this.ty, name);
  256. this.getRelatedMapping();
  257. }
  258. },
  259. methods: {
  260. selectedstyle({ row, rowIndex }) {
  261. if (this.getIndex === rowIndex) {
  262. return {
  263. 'background-color': '#ECF9FB',
  264. color: '#48C5D7'
  265. };
  266. }
  267. },
  268. tableRowClassName({ row, rowIndex }) {
  269. row.index = rowIndex;
  270. },
  271. btn(row) {
  272. const { hisName, hisDetailName } = this.form;
  273. if (hisName !== '' && hisDetailName === '' && this.type == 1) {
  274. this.ty = 1;
  275. } else if (hisName !== '' && hisDetailName !== '' && this.type == 1) {
  276. this.ty = 2;
  277. }
  278. if (this.getIndex == row.index) {
  279. this.getIndex = 6;
  280. this.form.searchText = '';
  281. this.form.conceptId = '';
  282. this.form.icdCode = '';
  283. this.form.source = '';
  284. } else {
  285. this.getIndex = row.index;
  286. this.form.searchText = row.name;
  287. this.form.conceptId = row.id;
  288. this.form.icdCode = row.code;
  289. this.form.source = row.source;
  290. }
  291. },
  292. handleChoose(val, id) {
  293. this.form.searchTextPre = val;
  294. this.form.searchText = val;
  295. this.form.conceptId = id;
  296. },
  297. // 搜索列表
  298. searchTerms(query) {
  299. if (!query) {
  300. this.uniqueNameList = [];
  301. return;
  302. }
  303. const { hisName, hisDetailName } = this.form;
  304. if (
  305. hisName !== '' &&
  306. (this.data.hisDetailName == null || this.data.hisDetailName === '') &&
  307. this.type == 1
  308. ) {
  309. this.ty = 1;
  310. } else if (hisName !== '' && hisDetailName !== '' && this.type == 1) {
  311. this.ty = 2;
  312. }
  313. this.searchType = this.ty;
  314. this.showDrop = true;
  315. let params = {
  316. type: this.ty ? this.ty : this.type,
  317. inputStr: query,
  318. sex: 3,
  319. age: 0
  320. };
  321. api.retrievalSearch(params).then(res => {
  322. this.showDrop = false;
  323. if (res.data.code === '0') {
  324. if (this.ty == 2) {
  325. this.uniqueNameList = res.data.data.lisDetailNames;
  326. } else {
  327. this.uniqueNameList = res.data.data.nameList;
  328. }
  329. }
  330. });
  331. },
  332. searchDrug(query) {
  333. if (!query) {
  334. this.drugList = [];
  335. return;
  336. }
  337. this.showDrop = true;
  338. let params = {
  339. type: 15,
  340. inputStr: query,
  341. sex: 3,
  342. age: 0
  343. };
  344. api.retrievalSearch(params).then(res => {
  345. this.showDrop = false;
  346. if (res.data.code === '0') {
  347. this.drugList = res.data.data.nameList;
  348. }
  349. });
  350. },
  351. onchange() {
  352. this.getRelatedMapping();
  353. },
  354. getRelatedMapping() {
  355. const { hisName, hisDetailName } = this.form;
  356. let params = {
  357. type: this.type,
  358. hisDetailName: hisDetailName,
  359. hisName: hisName,
  360. hospitalId: this.hospitalId
  361. };
  362. api.getRelatedMapping(params).then(res => {
  363. this.showDrop = false;
  364. if (res.data.code === '0') {
  365. this.mapList = res.data.data;
  366. }
  367. });
  368. },
  369. changeWord(newValue) {
  370. this.form.searchText = newValue.name;
  371. this.form.icdCode = newValue.code;
  372. this.form.conceptId = newValue.id;
  373. this.getIndex = 6;
  374. },
  375. drugchangeWord(newValue) {
  376. this.form.formConceptId = newValue.id;
  377. this.form.form = newValue.name;
  378. },
  379. handleVisible(flag) {
  380. if (!flag) {
  381. this.uniqueNameList = [];
  382. }
  383. },
  384. // 获取焦点
  385. handleFocus() {},
  386. onblur() {
  387. let type, name;
  388. const { hisName, hisDetailName } = this.form;
  389. if (this.type == 1) {
  390. type = 1; // 1-化验大项、2-化验小项
  391. name = hisName;
  392. if (hisName !== '' && hisDetailName !== '') {
  393. type = 2;
  394. name = hisDetailName;
  395. }
  396. }
  397. this.getTermMatching(type, name);
  398. },
  399. clear() {
  400. const { hisName, hisDetailName } = this.form;
  401. this.getTermMatching(1, hisName);
  402. },
  403. getTermMatching(type, name) {
  404. let params = {
  405. type: type ? type : this.type,
  406. inputStr: name ? name : this.form.hisName
  407. };
  408. api.getTermMatching(params).then(res => {
  409. this.showDrop = false;
  410. if (res.data.code === '0') {
  411. this.tableData = res.data.data;
  412. this.getIndex = 6;
  413. }
  414. });
  415. },
  416. // 建立关联-参数处理
  417. submitForm() {
  418. this.$refs.relationForm.validate(valid => {
  419. if (valid) {
  420. const {
  421. searchText,
  422. hisName,
  423. hisDetailName,
  424. icdCode,
  425. conceptId,
  426. formConceptId,
  427. hisCode,
  428. source
  429. } = this.form;
  430. // 当标准术语是套餐时,细项必须为空
  431. console.log(hisDetailName);
  432. if (this.searchType === 1 && hisDetailName !== '') {
  433. console.log(123);
  434. this.warning('医院术语与标准术语类型不匹配,请修改');
  435. return;
  436. }
  437. // 当标准术语是细项时,医院术语套餐和细项均不能为空
  438. if (this.searchType === 2) {
  439. if (hisName === '') {
  440. this.warning('医院术语与标准术语类型不匹配,请修改');
  441. return;
  442. } else if (hisDetailName === '') {
  443. this.warning('医院术语与标准术语类型不匹配,请修改');
  444. return;
  445. }
  446. }
  447. let params = {
  448. hisName: hisName,
  449. uniqueName: searchText,
  450. hisDetailName: hisDetailName,
  451. type: this.type,
  452. conceptId: conceptId,
  453. formConceptId: formConceptId,
  454. hospitalId: this.hospitalId,
  455. hisCode: hisCode,
  456. source: source ? source : 1
  457. };
  458. this.showSaveDialog(params);
  459. } else {
  460. console.log('error submit!!');
  461. return false;
  462. }
  463. });
  464. },
  465. // 建立关联-映射关系是否已存在
  466. showSaveDialog(params) {
  467. this.saveDisable = true; //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
  468. api
  469. .diseaseIsExistRecord(params)
  470. .then(res => {
  471. if (!res.data.data) {
  472. // 不存在,创建新的关联
  473. // 如果是编辑时,需要携带id
  474. if (this.isEdit) {
  475. params = { ...params, id: this.editId };
  476. }
  477. this.saveLisMapping(params, '保存成功', 'success');
  478. } else {
  479. // 已存在,提示修改
  480. this.warning('该条关联已存在,无法添加');
  481. this.saveDisable = false;
  482. }
  483. })
  484. .catch(err => {
  485. if (err.code === '900010001') {
  486. return false;
  487. }
  488. this.warning(err);
  489. });
  490. },
  491. // 初始化表单数据
  492. initForm() {
  493. this.form.hisName = '';
  494. this.form.searchText = '';
  495. this.form.icdCode = '';
  496. this.form.hisDetailName = '';
  497. this.form.form = '';
  498. this.form.conceptId = '';
  499. this.form.source = '';
  500. },
  501. // 映射关系不存在-建立关联
  502. saveLisMapping(params, msg, type) {
  503. api.saveOrUpdateDiseaseRecord(params).then(res => {
  504. if (res.data.code === '0') {
  505. this.warning(res.data.msg || msg, type);
  506. this.initForm();
  507. this.$emit('func', 'updata');
  508. } else {
  509. this.warning(res.data.msg);
  510. }
  511. this.saveDisable = false;
  512. });
  513. },
  514. // 关联已存在模态框
  515. showConfirmDialog(msg, resolve) {
  516. this.$alert(msg, '提示', {
  517. // customClass: 'confirmRealation',
  518. confirmButtonText: '是',
  519. // cancelButtonText: '否',
  520. // cancelButtonClass: 'cancelButton',
  521. type: 'warning'
  522. })
  523. .then(() => {
  524. resolve();
  525. })
  526. .catch(() => {
  527. this.saveDisable = false;
  528. this.warning('建立失败', 'error');
  529. });
  530. },
  531. warning(msg, type) {
  532. this.$message({
  533. showClose: true,
  534. message: msg,
  535. type: type || 'warning',
  536. duration: '1000'
  537. });
  538. },
  539. closeModal() {
  540. this.$emit('func', 'close');
  541. }
  542. }
  543. };
  544. </script>
  545. <style lang="less" scoped>
  546. .modal-container {
  547. position: fixed;
  548. top: 0;
  549. left: 0;
  550. width: 100%;
  551. height: 100%;
  552. z-index: 21;
  553. .cover {
  554. background: #000;
  555. opacity: 0.2;
  556. width: 100%;
  557. height: 100%;
  558. }
  559. .modal-box {
  560. width: 950px;
  561. background: #fff;
  562. position: absolute;
  563. top: 50%;
  564. left: 50%;
  565. transform: translate(-50%, -50%);
  566. .modal-title {
  567. height: 40px;
  568. background: #e3eaf4;
  569. .close {
  570. float: right;
  571. margin: 3px 13px 0 0;
  572. font-size: 22px;
  573. color: #979797;
  574. cursor: pointer;
  575. }
  576. }
  577. .btns {
  578. display: inline-block;
  579. width: 70px;
  580. height: 34px;
  581. line-height: 34px;
  582. background: #48c5d7;
  583. border-radius: 4px;
  584. color: #fff;
  585. text-align: center;
  586. cursor: pointer;
  587. outline: none;
  588. border: none;
  589. }
  590. .cancel {
  591. background: #fff;
  592. color: #48c5d7;
  593. border: 1px #48c5d7 solid;
  594. margin-left: 40px;
  595. }
  596. .modal-body {
  597. padding: 34px 22px;
  598. }
  599. .modal-footer {
  600. margin-bottom: 60px;
  601. width: 100%;
  602. text-align: center;
  603. }
  604. }
  605. }
  606. .tab {
  607. max-width: 240px;
  608. min-width: 240px;
  609. // position: absolute;
  610. // top: 0;
  611. z-index: 999;
  612. margin-bottom: 15px;
  613. margin-top: -62px;
  614. }
  615. // .tabs {
  616. // max-width: 240px;
  617. // min-width: 240px;
  618. // position: absolute;
  619. // top: 0;
  620. // left: 250px;
  621. // }
  622. .mapList {
  623. padding: 0 20px 20px;
  624. font-size: 14px;
  625. line-height: 24px;
  626. & span {
  627. padding: 0 3px;
  628. }
  629. }
  630. .el-select-dropdown__list,
  631. .el-select-dropdown__item {
  632. width: 219px;
  633. cursor: pointer;
  634. }
  635. .el-dropdown-menu__item:focus,
  636. .el-checkbox__input.is-checked + .el-checkbox__label,
  637. .el-dropdown-menu__item:not(.is-disabled):hover,
  638. .el-button--text,
  639. .el-date-table td.today span,
  640. .el-radio__input.is-checked + .el-radio__label,
  641. .el-pagination.is-background .el-pager li:not(.disabled):hover,
  642. .el-select-dropdown__item.selected {
  643. font-size: 14px;
  644. padding: 0 20px;
  645. position: relative;
  646. white-space: nowrap;
  647. overflow: hidden;
  648. text-overflow: ellipsis;
  649. color: #606266;
  650. height: 34px;
  651. line-height: 34px;
  652. -webkit-box-sizing: border-box;
  653. box-sizing: border-box;
  654. width: 219px;
  655. cursor: pointer;
  656. }
  657. /deep/ .el-form-item__error {
  658. width: 150px;
  659. }
  660. /*********新增编辑***********/
  661. .topBack {
  662. top: 0;
  663. }
  664. .titleBox {
  665. padding: 0 0 10px 0px;
  666. }
  667. /deep/.el-table th {
  668. background: #f7f7f7;
  669. }
  670. /deep/ .el-table td,
  671. .el-table th.is-leaf {
  672. border-bottom: none;
  673. }
  674. .title-l {
  675. font-size: 14px;
  676. line-height: 40px;
  677. margin-left: 10px;
  678. }
  679. .title {
  680. width: 50%;
  681. float: left;
  682. font-size: 14px;
  683. }
  684. .leftBox,
  685. .midBox,
  686. .rightBox {
  687. width: 380px;
  688. float: left;
  689. height: 248px;
  690. font-size: 14px;
  691. }
  692. .midBox {
  693. width: 6%;
  694. padding: 50px 0 0 0;
  695. text-align: center;
  696. }
  697. .midTitle {
  698. width: 40px;
  699. margin: 0 auto;
  700. }
  701. .midLogo {
  702. margin: 0 auto;
  703. }
  704. .leftBox,
  705. .rightBox {
  706. border: 1px solid #dcdfe6;
  707. padding: 20px 10px;
  708. }
  709. .rightBox {
  710. padding-right: 33px;
  711. height: 248px;
  712. overflow-y: auto;
  713. }
  714. .itemLabel {
  715. width: 100%;
  716. min-height: 50px;
  717. line-height: 50px;
  718. position: relative;
  719. }
  720. .itemLabelName,
  721. .searchInput,
  722. .searchName {
  723. float: left;
  724. color: #606266;
  725. }
  726. .itemLabelName {
  727. width: 150px;
  728. }
  729. .isRequired::before {
  730. content: '*';
  731. color: red;
  732. }
  733. .searchInput,
  734. .mealNameItem {
  735. padding: 0 5px;
  736. }
  737. .searchInput,
  738. .searchName {
  739. display: inline-block;
  740. height: 32px;
  741. line-height: 32px;
  742. border: 1px solid #a9a9a9;
  743. margin: 8px 0 0 0;
  744. }
  745. .searchName {
  746. text-align: center;
  747. border-left: none;
  748. cursor: pointer;
  749. padding: 0 12px;
  750. font-size: 16px;
  751. }
  752. .itemList {
  753. position: absolute;
  754. background: #fff;
  755. width: 162px;
  756. max-height: 150px;
  757. border: 1px solid #a9a9a9;
  758. left: 150px;
  759. top: 42px;
  760. z-index: 2;
  761. overflow-y: auto;
  762. }
  763. .itemList {
  764. width: calc(100% - 131px);
  765. }
  766. .mealNameItem {
  767. height: 30px;
  768. line-height: 30px;
  769. font-size: 14px;
  770. cursor: pointer;
  771. }
  772. .mealNameItem:hover {
  773. background: #f5f7fa;
  774. }
  775. .previewInfo {
  776. padding-left: 4px;
  777. display: inline-block;
  778. margin-top: 8px;
  779. // width: calc(100% - 160px);s
  780. line-height: 24px;
  781. overflow: hidden;
  782. word-wrap: break-word;
  783. word-break: break-all;
  784. }
  785. .sumbit {
  786. position: absolute;
  787. display: inline-block;
  788. width: 80px;
  789. height: 30px;
  790. line-height: 30px;
  791. border: 1px solid #a9a9a9;
  792. text-align: center;
  793. right: 100px;
  794. }
  795. .confirmRealation {
  796. .cancelButton {
  797. border: 1px solid #a9a9a9;
  798. span {
  799. color: #606266;
  800. }
  801. }
  802. }
  803. </style>