Elizabeth's proactive approach involves introducing urinal toilet attachment , an ingenious concept that optimizes space and functionality.

stockModifyPrice.vue 27KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759
  1. <template>
  2. <div class="main-contain">
  3. <div class="position">
  4. <bread-crumb :crumbs="crumbs"></bread-crumb>
  5. </div>
  6. <div class="app-container">
  7. <div style="display: flex;align-items: center;justify-content: space-between;">
  8. <div>
  9. <el-input
  10. size="small"
  11. style="width: 200px;"
  12. class="filter-item"
  13. v-model.trim="searchKey"
  14. placeholder=""
  15. />
  16. <el-button
  17. size="small"
  18. class="filter-item"
  19. type="primary"
  20. icon="el-icon-search"
  21. @click="search"
  22. placeholder="请输入单据编号或操作人姓名"
  23. >搜索</el-button
  24. >
  25. <el-date-picker
  26. size="small"
  27. v-model="start_time"
  28. type="date"
  29. style="margin-left:5px;width:140px;"
  30. placeholder="选择日期">
  31. </el-date-picker>
  32. <el-date-picker
  33. size="small"
  34. v-model="end_time"
  35. type="date"
  36. style="margin-left:5px;width:140px;"
  37. placeholder="选择日期">
  38. </el-date-picker>
  39. </div>
  40. <div>
  41. <el-button size="small" type="primary" @click="dialogVisible = true">新增</el-button>
  42. <el-button size="small" type="primary" @click="toCheck">核对</el-button>
  43. <el-button size="small" type="primary" @click="print">打印</el-button>
  44. <el-button size="small" type="primary">导出</el-button>
  45. </div>
  46. </div>
  47. <div>
  48. <div style="width:100%;margin-right:10px;margin-top:10px">
  49. <el-table :data="tableList" border :height="tableHeight" :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }" @selection-change="changePrice">
  50. <el-table-column type="selection" width="55" align="center"> </el-table-column>
  51. <el-table-column prop="date" label="单据编码" width="100">
  52. <template slot-scope="scope" align="center">
  53. {{scope.row.warehousing_order}}
  54. </template>
  55. </el-table-column>
  56. <el-table-column label="耗材名称" width="100" align="center">
  57. <template slot-scope="scope">
  58. {{scope.row.good_name}}
  59. </template>
  60. </el-table-column>
  61. <el-table-column label="规格" width="100">
  62. <template slot-scope="scope">
  63. {{scope.row.specification_name}}
  64. </template>
  65. </el-table-column>
  66. <el-table-column label="单位" width="100">
  67. <template slot-scope="scope">
  68. {{scope.row.packing_unit}}
  69. </template>
  70. </el-table-column>
  71. <el-table-column label="调价数量" width="100">
  72. <template slot-scope="scope">
  73. {{scope.row.count}}
  74. </template>
  75. </el-table-column>
  76. <el-table-column label="原进货价" width="100">
  77. <template slot-scope="scope">
  78. {{scope.row.buy_price}}
  79. </template>
  80. </el-table-column>
  81. <el-table-column label="原零售价" width="100">
  82. <template slot-scope="scope">
  83. {{scope.row.packing_price}}
  84. </template>
  85. </el-table-column>
  86. <el-table-column label="生产厂商" width="100">
  87. <template slot-scope="scope">
  88. {{scope.row.manufacturer}}
  89. </template>
  90. </el-table-column>
  91. <el-table-column label="经销商" width="100">
  92. <template slot-scope="scope">
  93. {{scope.row.dealer}}
  94. </template>
  95. </el-table-column>
  96. <el-table-column label="操作人" width="100">
  97. <template slot-scope="scope">
  98. {{getDoctor(scope.row.creater)}}
  99. </template>
  100. </el-table-column>
  101. <el-table-column label="核对人" width="100">
  102. <template slot-scope="scope">
  103. {{getDoctor(scope.row.checker)}}
  104. </template>
  105. </el-table-column>
  106. <el-table-column label="状态" width="100">
  107. <template slot-scope="scope">
  108. <span v-if="scope.row.checker_status == 2">未核对</span>
  109. <span v-if="scope.row.checker_status == 1">已核对</span>
  110. </template>
  111. </el-table-column>
  112. <el-table-column prop="date" label="调价日期" width="100">
  113. <template slot-scope="scope">
  114. {{getTime(scope.row.start_time)}}
  115. </template>
  116. </el-table-column>
  117. <el-table-column label="备注" width="100">
  118. <template slot-scope="scope">
  119. {{scope.row.remark}}
  120. </template>
  121. </el-table-column>
  122. </el-table>
  123. </div>
  124. <!-- <el-table :data="tableData" border :height="tableHeight" :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }">
  125. <el-table-column
  126. fixed="left"
  127. prop="date"
  128. label="药品ID"
  129. width="80">
  130. </el-table-column>
  131. <el-table-column
  132. prop="date"
  133. label="药品名称"
  134. width="100">
  135. </el-table-column>
  136. <el-table-column
  137. prop="name"
  138. label="规格"
  139. width="100">
  140. </el-table-column>
  141. <el-table-column
  142. prop="name"
  143. label="生产厂家"
  144. width="100">
  145. </el-table-column>
  146. <el-table-column
  147. prop="name"
  148. label="批准文书"
  149. width="100">
  150. </el-table-column>
  151. <el-table-column
  152. prop="name"
  153. label="经销商"
  154. width="100">
  155. </el-table-column>
  156. <el-table-column
  157. prop="name"
  158. label="数量"
  159. width="100">
  160. </el-table-column>
  161. <el-table-column
  162. prop="name"
  163. label="原零价"
  164. width="100">
  165. </el-table-column>
  166. <el-table-column
  167. prop="name"
  168. label="现零价"
  169. width="100">
  170. </el-table-column>
  171. <el-table-column
  172. prop="name"
  173. label="进货价"
  174. width="100">
  175. </el-table-column>
  176. <el-table-column
  177. prop="name"
  178. label="零售总价"
  179. width="100">
  180. </el-table-column>
  181. <el-table-column
  182. prop="name"
  183. label="批号"
  184. width="100">
  185. </el-table-column>
  186. <el-table-column
  187. prop="name"
  188. label="生产日期"
  189. width="100">
  190. </el-table-column>
  191. <el-table-column
  192. prop="name"
  193. label="有效日期"
  194. width="100">
  195. </el-table-column>
  196. </el-table> -->
  197. </div>
  198. </div>
  199. <el-dialog
  200. title="库房调价"
  201. :visible.sync="dialogVisible"
  202. width="1200px">
  203. <el-form :model="form" class="modifyDialog" label-width="120px">
  204. <el-form-item label="耗材名称">
  205. <!-- <el-input v-model="form.name"></el-input> -->
  206. <el-autocomplete
  207. class="checkSearch"
  208. popper-class="my-autocomplete"
  209. v-model="form.good_name"
  210. :fetch-suggestions="querySearchAsync"
  211. :trigger-on-focus="true"
  212. placeholder="请输入耗材名称"
  213. @select="handleSelect"
  214. @input="changeGoodName(scope.$index)"
  215. style="width:160px;"
  216. >
  217. <i class="el-icon-search el-input__icon" slot="suffix"></i>
  218. <template slot-scope="{ item }">
  219. <div class="name">{{ item.good_name +" " +item.specification_name + " "+item.manufacturer }}</div>
  220. </template>
  221. </el-autocomplete>
  222. </el-form-item>
  223. <el-form-item label="原价格">
  224. <el-input v-model="form.packing_price"></el-input>
  225. </el-form-item>
  226. <el-form-item label="现价格">
  227. <el-input v-model="form.new_price"></el-input>
  228. </el-form-item>
  229. <el-form-item label="调价数量">
  230. <el-input v-model="form.count"></el-input>
  231. </el-form-item>
  232. <el-form-item label="备注" style="width:66%;">
  233. <div style="display:flex;">
  234. <el-input v-model="form.remark"></el-input>
  235. <el-button style="margin-left:5px;" type="primary" @click="addPrice">添加</el-button>
  236. </div>
  237. </el-form-item>
  238. </el-form>
  239. <el-table :data="tableData" border :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }">
  240. <el-table-column prop="date" label="单据编号" width="100" align="center">
  241. <template slot-scope="scope">
  242. {{scope.row.warehousing_order}}
  243. </template>
  244. </el-table-column>
  245. <el-table-column prop="date" label="耗材名称" width="100" align="center">
  246. <template slot-scope="scope">
  247. {{scope.row.good_name}}
  248. </template>
  249. </el-table-column>
  250. <el-table-column prop="name" label="规格" width="100" align="center">
  251. <template slot-scope="scope">
  252. {{scope.row.specification_name}}
  253. </template>
  254. </el-table-column>
  255. <el-table-column prop="name" label="单位" width="100" align="center">
  256. <template slot-scope="scope">
  257. {{scope.row.warehousing_unit}}
  258. </template>
  259. </el-table-column>
  260. <el-table-column prop="name" label="调价数量" width="100" align="center">
  261. <template slot-scope="scope">
  262. {{scope.row.count}}
  263. </template>
  264. </el-table-column>
  265. <el-table-column prop="name" label="原进货价" width="100" align="center">
  266. <template slot-scope="scope">
  267. {{scope.row.buy_price}}
  268. </template>
  269. </el-table-column>
  270. <el-table-column prop="name" label="原零售价" width="100" align="center">
  271. <template slot-scope="scope">
  272. {{scope.row.packing_price}}
  273. </template>
  274. </el-table-column>
  275. <el-table-column prop="name" label="新零售价" width="100" align="center">
  276. <template slot-scope="scope">
  277. {{scope.row.new_price}}
  278. </template>
  279. </el-table-column>
  280. <el-table-column prop="manufacturer" label="生产厂商" width="100" align="center">
  281. <template slot-scope="scope">
  282. {{scope.row.manufacturer}}
  283. </template>
  284. </el-table-column>
  285. <el-table-column prop="name" label="批准文号" width="100" align="center">
  286. <template slot-scope="scope">
  287. {{scope.row.license_number}}
  288. </template>
  289. </el-table-column>
  290. <el-table-column prop="name" label="经销商" width="100" align="center">
  291. <template slot-scope="scope">
  292. {{scope.row.dealer}}
  293. </template>
  294. </el-table-column>
  295. <el-table-column prop="name" label="备注" width="100" align="center">
  296. <template slot-scope="scope">
  297. {{scope.row.remark}}
  298. </template>
  299. </el-table-column>
  300. <el-table-column
  301. fixed="right"
  302. width="100"
  303. label="操作">
  304. <template slot-scope="scope">
  305. <el-button type="text" size="small" @click="deletePrice(scope.$index)">删除</el-button>
  306. <el-button type="text" size="small" @click="editPrice(scope.row)">编辑</el-button>
  307. </template>
  308. </el-table-column>
  309. </el-table>
  310. <span slot="footer" class="dialog-footer">
  311. <el-button @click="dialogVisible = false">取 消</el-button>
  312. <el-button type="primary" @click="saveAdjustPrice">确 定</el-button>
  313. </span>
  314. </el-dialog>
  315. <!-- 编辑调价 -->
  316. <el-dialog
  317. title="编辑"
  318. :visible.sync="editPriceDialogVisible"
  319. width="50%">
  320. <span>
  321. <el-form :model="form">
  322. <el-row>
  323. <el-col>
  324. <el-form-item label="耗材名称:">
  325. <el-autocomplete
  326. class="checkSearch"
  327. popper-class="my-autocomplete"
  328. v-model="form.good_name"
  329. :fetch-suggestions="querySearchAsync"
  330. :trigger-on-focus="true"
  331. placeholder="请输入耗材名称"
  332. @select="handleSelect"
  333. @input="changeGoodName(scope.$index)"
  334. style="width:160px;"
  335. >
  336. <i class="el-icon-search el-input__icon" slot="suffix"></i>
  337. <template slot-scope="{ item }">
  338. <div class="name">{{ item.good_name +" " +item.specification_name + " "+item.manufacturer }}</div>
  339. </template>
  340. </el-autocomplete>
  341. </el-form-item>
  342. <el-form-item label="原价格:">
  343. <el-input v-model="form.packing_price" style="width:200px"></el-input>
  344. </el-form-item>
  345. <el-form-item label="现价格:">
  346. <el-input v-model="form.new_price" style="width:200px"></el-input>
  347. </el-form-item>
  348. </el-col>
  349. </el-row>
  350. <el-row>
  351. <el-col>
  352. <el-form-item label="调价数量:">
  353. <el-input v-model="form.count" style="width:200px"></el-input>
  354. </el-form-item>
  355. <el-form-item label="备注:">
  356. <div style="display:flex;">
  357. <el-input v-model="form.remark" style="width:200px"></el-input>
  358. </div>
  359. </el-form-item>
  360. </el-col>
  361. </el-row>
  362. </el-form>
  363. </span>
  364. <span slot="footer" class="dialog-footer">
  365. <el-button @click="editPriceDialogVisible = false">取 消</el-button>
  366. <el-button type="primary" @click="upatePrice">保存</el-button>
  367. </span>
  368. </el-dialog>
  369. <el-dialog
  370. title="耗材调价核对"
  371. :visible.sync="checkDialogVisible"
  372. width="30%"
  373. >
  374. <span>
  375. <el-form :model="form">
  376. <el-row>
  377. <el-col>
  378. <el-form-item label="核对时间">
  379. <el-date-picker
  380. size="small"
  381. v-model="check_time"
  382. type="date"
  383. style="margin-left:5px;width:140px;"
  384. placeholder="选择日期">
  385. </el-date-picker>
  386. </el-form-item>
  387. </el-col>
  388. </el-row>
  389. <el-row>
  390. <el-col>
  391. <el-form-item label="核对人">
  392. <el-select v-model="checker" placeholder="请选择">
  393. <el-option
  394. v-for="item in doctorList"
  395. :key="item.admin_user_id"
  396. :label="item.user_name"
  397. :value="item.admin_user_id">
  398. </el-option>
  399. </el-select>
  400. </el-form-item>
  401. </el-col>
  402. </el-row>
  403. </el-form>
  404. </span>
  405. <span slot="footer" class="dialog-footer">
  406. <el-button @click="checkDialogVisible = false">取 消</el-button>
  407. <el-button type="primary" @click="SaveCheckedPrice">保 存</el-button>
  408. </span>
  409. </el-dialog>
  410. </div>
  411. </template>
  412. <script>
  413. import BreadCrumb from "../components/bread-crumb";
  414. import { postSearchGoodWarehouseList,saveAdjustPrice,getAllStockPrice,SaveCheckedPrice} from "@/api/stock"
  415. import { uParseTime } from '@/utils/tools'
  416. export default {
  417. name: "stockModifyPrice",
  418. components:{
  419. BreadCrumb
  420. },
  421. data() {
  422. return{
  423. crumbs: [
  424. { path: false, name: "库存管理" },
  425. { path: false, name: "耗材管理" },
  426. { path: false, name: "耗材调价" }
  427. ],
  428. tableHeight: '',
  429. fullHeight: document.documentElement.clientHeight,
  430. searchKey:'',
  431. value1:'',
  432. value2:'',
  433. tableData: [],
  434. dialogVisible:false,
  435. form: {
  436. id:"",
  437. good_name: '',
  438. packing_price:'',
  439. new_price:"",
  440. count:"",
  441. remark:"",
  442. warehousing_order:"",
  443. manufacturer:"",
  444. dealer:"",
  445. license_number:"",
  446. warehousing_unit:"",
  447. specification_name:"",
  448. buy_price:"",
  449. good_id:"",
  450. packing_unit:"",
  451. },
  452. goodList:[],
  453. manufacturerList:[],
  454. dealerList:[],
  455. currentIndex: 0,
  456. editPriceDialogVisible:false,
  457. tableList:[],
  458. doctorList:[],
  459. start_time:"",
  460. end_time:"",
  461. ids:"",
  462. check_time:new Date(),
  463. checker:this.$store.getters.xt_user.user.id,
  464. checkDialogVisible:false,
  465. }
  466. },
  467. methods:{
  468. search(){
  469. },
  470. print(){
  471. if(this.ids == ""){
  472. this.$message.error("请勾选打印数据")
  473. return
  474. }
  475. this.$router.push({path:'/stock/stockModifyPricePrint?ids='+this.ids})
  476. },
  477. querySearchAsync(keyword, cb) {
  478. let key = '';
  479. if (keyword != undefined) {
  480. key = keyword
  481. }
  482. postSearchGoodWarehouseList(key).then(response => {
  483. if (response.data.state == 1) {
  484. var list = response.data.data.list
  485. console.log("列表数据",list)
  486. this.goodList = list
  487. var manufacturerList = response.data.data.manufacturerList
  488. this.manufacturerList = manufacturerList
  489. var dealer = response.data.data.dealerList
  490. this.dealerList = dealer
  491. for(let i=0;i<this.goodList.length;i++){
  492. for(let j=0;j<this.manufacturerList.length;j++){
  493. if(this.goodList[i].manufacturer == this.manufacturerList[j].id){
  494. this.goodList[i].manufacturer = this.manufacturerList[j].manufacturer_name
  495. }
  496. }
  497. }
  498. for(let i=0;i<this.goodList.length;i++){
  499. for(let j=0;j<this.dealerList.length;j++){
  500. if(this.goodList[i].dealer == this.dealerList[j].id){
  501. this.goodList[i].dealer = this.dealerList[j].dealer_name
  502. }
  503. }
  504. }
  505. cb(this.goodList)
  506. } else {
  507. cb([])
  508. }
  509. })
  510. },
  511. changeGoodName(val){
  512. this.currentIndex = val
  513. },
  514. handleSelect(val){
  515. console.log("val23232323",val)
  516. this.form.id = val.id
  517. this.form.good_id = val.good_id,
  518. this.form.good_name = val.good_name
  519. this.form.packing_price = val.packing_price
  520. this.form.warehousing_order = val.warehousing_order
  521. this.form.license_number = val.license_number
  522. this.form.dealer = val.dealer
  523. this.form.manufacturer = val.manufacturer
  524. this.form.specification_name = val.specification_name
  525. this.form.remark = val.remark
  526. this.form.buy_price = val.buy_price
  527. this.form.warehousing_unit = val.packing_unit
  528. },
  529. handleClose(){
  530. },
  531. addPrice(){
  532. var obj = {
  533. id:this.form.id,
  534. good_name:this.form.good_name,
  535. specification_name:this.form.specification_name,
  536. warehousing_order:this.form.warehousing_order,
  537. good_name:this.form.good_name,
  538. packing_price:this.form.packing_price,
  539. license_number:this.form.license_number,
  540. dealer:this.form.dealer,
  541. manufacturer:this.form.manufacturer,
  542. warehousing_unit:this.form.warehousing_unit,
  543. start_time:this.getTime(new Date()),
  544. count:this.form.count,
  545. new_price:this.form.new_price,
  546. remark:this.form.remark,
  547. buy_price:this.form.buy_price,
  548. good_id:this.form.good_id,
  549. }
  550. this.tableData.push(obj)
  551. this.form.good_name = ""
  552. this.form.specification_name = ""
  553. this.form.warehousing_order = ""
  554. this.form.good_name = ""
  555. this.form.packing_price = ""
  556. this.form.license_number= ""
  557. this.form.dealer = ""
  558. this.form.manufacturer = ""
  559. this.form.warehousing_unit = ""
  560. this.form.count = ""
  561. this.form.new_price = ""
  562. this.form.remark = ""
  563. this.form.buy_price= ""
  564. },
  565. getTime(val) {
  566. if(val < 0){
  567. return ""
  568. }
  569. if(val == ""){
  570. return ""
  571. }else {
  572. return uParseTime(val, '{y}-{m}-{d}')
  573. }
  574. },
  575. deletePrice(index){
  576. this.tableData.splice(index,1)
  577. },
  578. editPrice(row){
  579. console.log("row232233223",row)
  580. this.form.good_name = row.good_name
  581. this.form.packing_price = row.packing_unit
  582. this.form.new_price = row.new_price
  583. this.form.count = row.count
  584. this.form.remark = row.remark
  585. this.form.id = row.id
  586. this.editPriceDialogVisible = true
  587. },
  588. upatePrice(){
  589. for(let i=0;i<this.tableData.length;i++){
  590. if(this.form.id == this.tableData[i].id){
  591. this.tableData[i].good_name = this.form.good_name
  592. this.tableData[i].packing_price = this.form.packing_price
  593. this.tableData[i].new_price = this.form.new_price
  594. this.tableData[i].count = this.form.count
  595. this.tableData[i].remark = this.form.remark
  596. }
  597. }
  598. this.editPriceDialogVisible = false
  599. },
  600. saveAdjustPrice(){
  601. for(let i=0;i<this.tableData.length;i++){
  602. this.tableData[i].buy_price = this.tableData[i].buy_price.toString()
  603. this.tableData[i].packing_price = this.tableData[i].packing_price.toString()
  604. this.tableData[i].new_price = this.tableData[i].new_price.toString()
  605. this.tableData[i].count = parseInt(this.tableData[i].count)
  606. }
  607. var params= {
  608. tableData:this.tableData,
  609. }
  610. console.log("parasm222",params)
  611. saveAdjustPrice(params).then(response=>{
  612. if(response.data.state == 1){
  613. var msg = response.data.data.msg
  614. console.log("msg",msg)
  615. this.$message.success("保存成功!")
  616. this.dialogVisible = false
  617. }
  618. })
  619. },
  620. getAllStockPrice(){
  621. var params = {
  622. keyword:this.searchKey,
  623. start_time:this.start_time,
  624. end_time:this.end_time,
  625. }
  626. console.log("params",params)
  627. getAllStockPrice(params).then(response=>{
  628. if(response.data.state == 1){
  629. var list = response.data.data.list
  630. console.log("zhognguoffs",list)
  631. this.tableList = list
  632. var doctor = response.data.data.doctor
  633. console.log("doctor",doctor)
  634. this.doctorList = doctor
  635. }
  636. })
  637. },
  638. getDoctor(id){
  639. var user_name = ""
  640. for(let i=0;i<this.doctorList.length;i++){
  641. if(id == this.doctorList[i].admin_user_id){
  642. user_name = this.doctorList[i].user_name
  643. }
  644. }
  645. return user_name
  646. },
  647. changePrice(val){
  648. console.log("val23232322323",val)
  649. var arr = []
  650. for(let i=0;i<val.length;i++){
  651. arr.push(val[i].id)
  652. }
  653. var str = arr.join(",")
  654. console.log("str",str)
  655. this.ids = str
  656. },
  657. toCheck(){
  658. if(this.ids.length <=0){
  659. this.$message.error("请勾选核对数据")
  660. return
  661. }else{
  662. this.checkDialogVisible = true
  663. }
  664. },
  665. SaveCheckedPrice(){
  666. var params = {
  667. ids:this.ids,
  668. check_time:this.getTime(this.check_time),
  669. checker:this.checker,
  670. }
  671. console.log("params",params)
  672. SaveCheckedPrice(params).then(response=>{
  673. if(response.data.state == 1){
  674. var adjustPrice = response.data.data.adjustPrice
  675. this.$message.success("保存成功")
  676. this.getAllStockPrice()
  677. this.checkDialogVisible = false
  678. }
  679. })
  680. }
  681. },
  682. created(){
  683. let tableHeight = document.body.clientHeight - 200;
  684. this.tableHeight = tableHeight
  685. this.getAllStockPrice()
  686. },
  687. mounted() {
  688. const that = this;
  689. window.onresize = () => {
  690. return (() => {
  691. window.fullHeight = document.documentElement.clientHeight;
  692. that.fullHeight = window.fullHeight
  693. })()
  694. }
  695. },
  696. watch: {
  697. fullHeight(val) {
  698. if (!this.timer) {
  699. this.fullHeight = val
  700. let tableHeight = val - 200
  701. this.tableHeight = tableHeight
  702. this.timer = true
  703. let that = this
  704. setTimeout(function() {
  705. that.timer = false
  706. }, 400)
  707. }
  708. }
  709. }
  710. };
  711. </script>
  712. <style rel="stylesheet/scss" lang="scss">
  713. .app-container {
  714. // margin: 20px;
  715. font-size: 15px;
  716. }
  717. .modifyDialog{
  718. display: flex;
  719. flex-wrap: wrap;
  720. margin-bottom: 10px;
  721. .el-form-item{
  722. width: 33%;
  723. }
  724. }
  725. .el-table td,
  726. .el-table th.is-leaf,
  727. .el-table--border,
  728. .el-table--group {
  729. border-color: #d0d3da;
  730. }
  731. .el-table--border::after,
  732. .el-table--group::after,
  733. .el-table::before {
  734. background-color: #d0d3da;
  735. }
  736. ::-webkit-scrollbar{
  737. height: 20px !important;
  738. }
  739. </style>