浏览代码

生命之源打印单

XMLWAN 4 年前
父节点
当前提交
9d30d3bf0d
共有 3 个文件被更改,包括 81 次插入10 次删除
  1. 12 1
      src/api/manage.js
  2. 3 2
      src/xt_pages/dialysis/template/DialysisPrintOrderSeventeen.vue
  3. 66 7
      src/xt_pages/management/index.vue

+ 12 - 1
src/api/manage.js 查看文件

719
 }
719
 }
720
 
720
 
721
 export function GetUserTotalCount(id, params) {
721
 export function GetUserTotalCount(id, params) {
722
-  console.log('id====', id)
723
   return request({
722
   return request({
724
     url: '/api/manage/getusertotalcount?id=' + id,
723
     url: '/api/manage/getusertotalcount?id=' + id,
725
     method: 'Get',
724
     method: 'Get',
726
     params: params
725
     params: params
727
   })
726
   })
728
 }
727
 }
728
+
729
+export function deleteManageMent(id) {
730
+  const params = {
731
+    id: id
732
+  }
733
+  console.log('params', params)
734
+  return request({
735
+    url: '/api/manage/deletemanagement',
736
+    method: 'get',
737
+    params: params
738
+  })
739
+}

+ 3 - 2
src/xt_pages/dialysis/template/DialysisPrintOrderSeventeen.vue 查看文件

97
           </td>
97
           </td>
98
           <td style="text-align:left;" colspan="2">
98
           <td style="text-align:left;" colspan="2">
99
             <span style="display:inline-block;margin-left:15px;">
99
             <span style="display:inline-block;margin-left:15px;">
100
-              透后净体重:{{
100
+              <!-- 透后净体重:{{
101
               afterdialysis.weight_after
101
               afterdialysis.weight_after
102
               ? parseFloat(
102
               ? parseFloat(
103
               afterdialysis.weight_after -
103
               afterdialysis.weight_after -
104
               afterdialysis.additional_weight
104
               afterdialysis.additional_weight
105
               ).toFixed(1)
105
               ).toFixed(1)
106
               : "/"
106
               : "/"
107
-              }}kg
107
+              }}kg -->
108
+              kt/v:{{ monitors[0].ktv ? monitors[0].ktv : '' }}
108
             </span>
109
             </span>
109
           </td>
110
           </td>
110
           <td style="text-align:left;" colspan="3">
111
           <td style="text-align:left;" colspan="3">

+ 66 - 7
src/xt_pages/management/index.vue 查看文件

129
           <template slot-scope="scope">{{getTotal(scope.row.bed_id,scope.row.user_total) }}</template>
129
           <template slot-scope="scope">{{getTotal(scope.row.bed_id,scope.row.user_total) }}</template>
130
         </el-table-column>
130
         </el-table-column>
131
 
131
 
132
-        <el-table-column label="操作" width="120" align="center">
132
+        <el-table-column label="操作" width="200" align="center">
133
           <template slot-scope="scope">
133
           <template slot-scope="scope">
134
             <el-button
134
             <el-button
135
               @click="handleClick(scope.row.id, scope.$index, scope.row.bed_id)"
135
               @click="handleClick(scope.row.id, scope.$index, scope.row.bed_id)"
136
               type="primary"
136
               type="primary"
137
               size="small"
137
               size="small"
138
-              >查看</el-button
139
-            >
138
+              >查看</el-button>
139
+             <el-button
140
+              @click="deleManageMent(scope.row.id,scope.row.equiment_id,scope.$index)"
141
+                size="small"
142
+                type="danger"
143
+                icon="el-icon-delete"
144
+              >删除</el-button>
140
           </template>
145
           </template>
146
+        
141
         </el-table-column>
147
         </el-table-column>
142
       </el-table>
148
       </el-table>
143
 
149
 
162
 
168
 
163
 <script>
169
 <script>
164
 import BreadCrumb from "../components/bread-crumb";
170
 import BreadCrumb from "../components/bread-crumb";
165
-import { getAllMachineInfo, getAllSubregion,getUserMachTotalCount } from "@/api/manage";
171
+import { getAllMachineInfo, getAllSubregion,getUserMachTotalCount,deleteManageMent } from "@/api/manage";
166
 import ManageForm from "./components/ManageForm";
172
 import ManageForm from "./components/ManageForm";
167
 
173
 
168
 export default {
174
 export default {
256
       ).then(response => {
262
       ).then(response => {
257
         if (response.data.state === 1) {
263
         if (response.data.state === 1) {
258
           var addmahcer = response.data.data.addmahcer;
264
           var addmahcer = response.data.data.addmahcer;
259
-          console.log("addmacher", addmahcer);
265
+          // console.log("addmacher", addmahcer);
260
           for (let index = 0; index < addmahcer.length; index++) {
266
           for (let index = 0; index < addmahcer.length; index++) {
261
             if (addmahcer[index].device_type === 1) {
267
             if (addmahcer[index].device_type === 1) {
262
               addmahcer[index].device_type = "透析机";
268
               addmahcer[index].device_type = "透析机";
286
             }
292
             }
287
           }
293
           }
288
           this.tableData = addmahcer;
294
           this.tableData = addmahcer;
289
-          // console.log('addmacher', addmahcer)
295
+          console.log('addmacher', addmahcer)
290
           var total = response.data.data.total;
296
           var total = response.data.data.total;
291
           // console.log('total', total)
297
           // console.log('total', total)
292
           this.total = total;
298
           this.total = total;
319
         getUserMachTotalCount().then(response=>{
325
         getUserMachTotalCount().then(response=>{
320
            if(response.data.state == 1){
326
            if(response.data.state == 1){
321
              var count = response.data.data.count
327
              var count = response.data.data.count
322
-             console.log("count",count)
328
+            //  console.log("count",count)
323
              this.count = count
329
              this.count = count
324
            }
330
            }
325
         })
331
         })
336
        }
342
        }
337
       //  console.log("count",count)
343
       //  console.log("count",count)
338
        return count
344
        return count
345
+    },
346
+    deleManageMent(id,equimentid){
347
+        if(equimentid != 0){
348
+          this.$confirm(
349
+          '该设备已有使用记录,确认要删除吗? <br>删除后,信息将无法恢复',
350
+          '删除提示',
351
+          {
352
+            dangerouslyUseHTMLString: true,
353
+            confirmButtonText: '确定',
354
+            cancelButtonText: '取消',
355
+            type: 'warning'
356
+          }
357
+        ).then(() => {
358
+            deleteManageMent(id).then(response => {
359
+              // eslint-disable-next-line eqeqeq
360
+              if (response.data.state == 1) {
361
+                var msg =  response.data.data.msg
362
+                 this.getAllMachineInfo()
363
+                 this.$message.success("删除成功")
364
+              } else {
365
+                this.$message.error('删除失败')
366
+              }
367
+            }).catch(e => {})
368
+          }).catch(() => {
369
+            return false
370
+          })
371
+        }
372
+        if(equimentid ==0){
373
+           this.$confirm(
374
+          '确认要删除所选设备吗? <br>删除后,信息将无法恢复',
375
+          '删除提示',
376
+          {
377
+            dangerouslyUseHTMLString: true,
378
+            confirmButtonText: '确定',
379
+            cancelButtonText: '取消',
380
+            type: 'warning'
381
+          }
382
+        ).then(() => {
383
+            deleteManageMent(id).then(response => {
384
+              // eslint-disable-next-line eqeqeq
385
+              if (response.data.state == 1) {
386
+                var msg =  response.data.data.msg
387
+                this.getAllMachineInfo()
388
+                this.$message.success('删除成功')
389
+              } else {
390
+                 this.$message.error('删除失败')
391
+              }
392
+            }).catch(e => {})
393
+          }).catch(() => {
394
+            return false
395
+          })
396
+        }
397
+      
339
     }
398
     }
340
   },
399
   },
341
   created() {
400
   created() {