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

inventoryDetails.vue 7.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. <template>
  2. <div>
  3. <div style="display: flex;align-items: center;justify-content: space-between;margin-bottom:10px;">
  4. <div>
  5. <!-- 耗材类别:
  6. <el-select v-model="value" size="small" placeholder="请选择">
  7. <el-option
  8. v-for="item in options"
  9. :key="item.value"
  10. :label="item.label"
  11. :value="item.value">
  12. </el-option>
  13. </el-select>
  14. 停用状态:
  15. <el-select v-model="value" size="small" placeholder="请选择">
  16. <el-option
  17. v-for="item in options"
  18. :key="item.value"
  19. :label="item.label"
  20. :value="item.value">
  21. </el-option>
  22. </el-select> -->
  23. <el-input
  24. size="small"
  25. style="width: 200px;margin-left:10px;"
  26. class="filter-item"
  27. v-model.trim="searchKey"
  28. placeholder="请输入单据编号或操作人姓名"
  29. />
  30. <el-button
  31. size="small"
  32. class="filter-item"
  33. type="primary"
  34. icon="el-icon-search"
  35. @click="search"
  36. >搜索</el-button
  37. >
  38. </div>
  39. <!-- <div>
  40. <el-button size="small" type="primary" @click="print">打印</el-button>
  41. <el-button size="small" type="primary">导出</el-button>
  42. </div> -->
  43. </div>
  44. <el-table :data="tableData" border :header-cell-style="{ backgroundColor: 'rgb(245, 247, 250)' }">
  45. <el-table-column prop="date" label="药品名称" width="100" align="center">
  46. <template slot-scope="scope">
  47. {{scope.row.drug_name}}
  48. </template>
  49. </el-table-column>
  50. <el-table-column prop="name" label="规格" width="100" align="center">
  51. <template slot-scope="scope">
  52. {{scope.row.specification_name}}
  53. </template>
  54. </el-table-column>
  55. <el-table-column prop="name" label="单位" width="100" align="center">
  56. <template slot-scope="scope">
  57. {{scope.row.warehousing_unit}}
  58. </template>
  59. </el-table-column>
  60. <el-table-column prop="name" label="库存数量" width="100" align="center">
  61. <template slot-scope="scope">
  62. {{scope.row.total}}
  63. </template>
  64. </el-table-column>
  65. <el-table-column prop="name" label="进价" width="100" align="center">
  66. <template slot-scope="scope">
  67. {{scope.row.last_price}}
  68. </template>
  69. </el-table-column>
  70. <el-table-column prop="name" label="零售价" width="100" align="center">
  71. <template slot-scope="scope">
  72. {{scope.row.retail_price}}
  73. </template>
  74. </el-table-column>
  75. <el-table-column prop="name" label="零售总价" width="100" align="center">
  76. <template slot-scope="scope">
  77. {{scope.row.count * scope.row.retail_price}}
  78. </template>
  79. </el-table-column>
  80. <el-table-column prop="name" label="产地" width="100" align="center">
  81. <template slot-scope="scope">
  82. {{scope.row.drug_origin_place}}
  83. </template>
  84. </el-table-column>
  85. <el-table-column prop="name" label="生产厂商" width="100" align="center">
  86. <template slot-scope="scope">
  87. {{scope.row.manufacturer}}
  88. </template>
  89. </el-table-column>
  90. <el-table-column prop="name" label="实盘点" width="100" align="center">
  91. <template slot-scope="scope">
  92. {{scope.row.count}}
  93. </template>
  94. </el-table-column>
  95. <el-table-column prop="name" label="亏损价格" width="100" align="center">
  96. <template slot-scope="scope">
  97. </template>
  98. </el-table-column>
  99. <el-table-column prop="name" label="生产日期" width="100" align="center">
  100. <template slot-scope="scope">
  101. {{getTime(scope.row.product_date)}}
  102. </template>
  103. </el-table-column>
  104. <el-table-column prop="name" label="有效日期" width="100" align="center">
  105. <template slot-scope="scope">
  106. {{getTime(scope.row.expiry_date)}}
  107. </template>
  108. </el-table-column>
  109. <!-- <el-table-column
  110. fixed="right"
  111. width="100"
  112. label="操作">
  113. <template slot-scope="scope">
  114. <el-button type="text" size="small">删除</el-button>
  115. <el-button type="text" size="small">编辑</el-button>
  116. </template>
  117. </el-table-column> -->
  118. </el-table>
  119. <el-pagination
  120. @size-change="handleSizeChange"
  121. @current-change="handleCurrentChange"
  122. :page-sizes="[5, 10, 50, 100]"
  123. :page-size="5"
  124. background
  125. style="margin-top:20px;text-align: right"
  126. layout="total, sizes, prev, pager, next, jumper"
  127. :total="total"
  128. >
  129. </el-pagination>
  130. </div>
  131. </template>
  132. <script>
  133. import { uParseTime } from '@/utils/tools'
  134. import { getInventoryDetailList } from "@/api/drug/drug"
  135. export default {
  136. name: "inventory",
  137. data() {
  138. return{
  139. searchKey:'',
  140. value1:'',
  141. value2:'',
  142. tableData: [],
  143. dialogVisible:false,
  144. form: {
  145. name: '',
  146. },
  147. total: 0,
  148. limit:10,
  149. page:1,
  150. }
  151. },
  152. methods:{
  153. search(){
  154. },
  155. print(){
  156. this.$router.push({path:'/stock/drugs/inventoryPrint'})
  157. },
  158. handleSizeChange(val){
  159. this.limit = val
  160. this.getlist()
  161. },
  162. handleCurrentChange(val){
  163. this.page = val
  164. this.getlist()
  165. },
  166. getlist(){
  167. var params = {
  168. limit:this.limit,
  169. page:this.page,
  170. keyword:this.searchKey,
  171. }
  172. console.log("parasm232332323",params)
  173. getInventoryDetailList(params).then(response=>{
  174. if(response.data.state == 1){
  175. this.total = response.data.data.total
  176. this.tableData = response.data.data.list
  177. console.log("比阿哥",this.tableData)
  178. this.doctorList = response.data.data.doctorList
  179. }
  180. })
  181. },
  182. getTime(val) {
  183. console.log("val3233232322323",val)
  184. if(val == undefined){
  185. return ""
  186. }
  187. if(val < 0){
  188. return ""
  189. }
  190. if(val == ""){
  191. return ""
  192. }else {
  193. return uParseTime(val, '{y}-{m}-{d}')
  194. }
  195. },
  196. },
  197. created(){
  198. this.getlist()
  199. },
  200. mounted() {
  201. },
  202. };
  203. </script>