Kaynağa Gözat

518合并代码

XMLWAN 2 yıl önce
ebeveyn
işleme
4c2a8f9163

+ 3 - 4
src/xt_pages/outpatientTool/components/detailStatistics.vue Dosyayı Görüntüle

183
        if(response.data.state == 1){
183
        if(response.data.state == 1){
184
           var list =  response.data.data.list
184
           var list =  response.data.data.list
185
           this.tableData = []
185
           this.tableData = []
186
-          console.log("list23232332232322323",list)
186
+          // console.log("list23232332232322323",list)
187
           for(let i=0;i<list.length;i++){
187
           for(let i=0;i<list.length;i++){
188
             for(let j=0;j<list[i].orders.length;j++){
188
             for(let j=0;j<list[i].orders.length;j++){
189
               for(let z=0;z<list[i].orders[j].order_info.length;z++){
189
               for(let z=0;z<list[i].orders[j].order_info.length;z++){
203
           obj.total_price = (obj.total_price).toFixed(2)
203
           obj.total_price = (obj.total_price).toFixed(2)
204
           this.tableData.push(obj)
204
           this.tableData.push(obj)
205
           
205
           
206
-          console.log("tabledata",this.tableData)
206
+          // console.log("tabledata",this.tableData)
207
        }
207
        }
208
      })
208
      })
209
     },
209
     },
210
     getAllPice(){
210
     getAllPice(){
211
-      console.log("hhhhh",this.tableData)
212
       var total_price = 0
211
       var total_price = 0
213
       for(let i=0;i<this.tableData.length;i++){
212
       for(let i=0;i<this.tableData.length;i++){
214
         if(this.tableData[i].index =="合计"){
213
         if(this.tableData[i].index =="合计"){
219
     }
218
     }
220
   },
219
   },
221
   created() {
220
   created() {
222
-   // this.getHisSummaryDetailList()
221
+    this.getHisSummaryDetailList()
223
   },
222
   },
224
   watch:{
223
   watch:{
225
     "patient_id":function(){
224
     "patient_id":function(){

+ 60 - 7
src/xt_pages/outpatientTool/components/gatherStatistics.vue Dosyayı Görüntüle

43
       <div>
43
       <div>
44
       </div>
44
       </div>
45
     </div>
45
     </div>
46
-    <el-table :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
46
+    <el-table :data="tableList" border :row-style="{ color: '#303133' }" ref="table"
47
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
47
               :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
48
               show-summary
48
               show-summary
49
               max-height="600"
49
               max-height="600"
50
               v-loading="detail_loading"
50
               v-loading="detail_loading"
51
               highlight-current-row>
51
               highlight-current-row>
52
-      <el-table-column type="index" label="序号" width="60px" align="center"></el-table-column>
52
+      <el-table-column type="index" label="序号" width="60px" align="center">
53
+           <template slot-scope="scope">{{scope.row.index}}</template>
54
+      </el-table-column>
53
       <el-table-column align="center" prop="name" label="处方日期">
55
       <el-table-column align="center" prop="name" label="处方日期">
54
         <template slot-scope="scope"></template>
56
         <template slot-scope="scope"></template>
55
       </el-table-column>
57
       </el-table-column>
56
       <el-table-column align="center" prop="name" label="费用分类">
58
       <el-table-column align="center" prop="name" label="费用分类">
57
-        <template slot-scope="scope"></template>
59
+        <template slot-scope="scope">
60
+
61
+        </template>
58
       </el-table-column>
62
       </el-table-column>
59
       <el-table-column align="center" prop="name" label="项目名称">
63
       <el-table-column align="center" prop="name" label="项目名称">
60
-        <template slot-scope="scope"></template>
64
+        <template slot-scope="scope">
65
+           <span v-if="scope.row.advice_id > 0 ">{{getAdviceName(scope.row.advice_id)}}</span>
66
+           <span v-if="scope.row.project_id > 0 ">{{getProjectName(scope.row.project_id)}}</span>
67
+        </template>
61
       </el-table-column>
68
       </el-table-column>
62
       <el-table-column align="center" prop="name" label="规格型号">
69
       <el-table-column align="center" prop="name" label="规格型号">
63
         <template slot-scope="scope"></template>
70
         <template slot-scope="scope"></template>
109
       sameRowArr: [],
116
       sameRowArr: [],
110
       keywords: '',
117
       keywords: '',
111
       tableData: [],
118
       tableData: [],
119
+      tableList:[],
112
       chargeDate: [moment(new Date()).add('year', 0).format('YYYY-MM-DD'), moment(new Date()).add('year', 0).format('YYYY-MM-DD')],
120
       chargeDate: [moment(new Date()).add('year', 0).format('YYYY-MM-DD'), moment(new Date()).add('year', 0).format('YYYY-MM-DD')],
113
       item_type: '0',
121
       item_type: '0',
114
       items: [
122
       items: [
117
         { id: 2, name: '项目' }
125
         { id: 2, name: '项目' }
118
 
126
 
119
       ]
127
       ]
120
-
128
+     
121
     }
129
     }
122
   },
130
   },
123
   methods: {
131
   methods: {
143
       }
151
       }
144
      getGatherDetailList(params).then(response=>{
152
      getGatherDetailList(params).then(response=>{
145
        if(response.data.state == 1){
153
        if(response.data.state == 1){
146
-         var detailList = response.data.data.detailList
147
-         console.log("detailist232323322332",detailList)
154
+         var projectlist = response.data.data.projectlist
155
+         for(let i=0;i<projectlist.length;i++){
156
+          this.tableList.push(projectlist[i])
157
+         }
158
+         console.log("detailist232323322332",projectlist)
159
+         var advicelist = response.data.data.advicelist
160
+         for(let i=0;i<advicelist.length;i++){
161
+           this.tableList.push(advicelist[i])
162
+         }
163
+         for(let i=0;i<this.tableData.length;i++){
164
+           this.tableList[i].index = i +1
165
+         }
166
+         console.log("advicelist332233323232323232",this.tableList)
167
+      
148
          var list = response.data.data.list
168
          var list = response.data.data.list
149
          console.log("list233223232323",list)
169
          console.log("list233223232323",list)
170
+         for(let i=0;i<list.length;i++){
171
+            for(let j=0;j<list[i].orders.length;j++){
172
+              for(let z=0;z<list[i].orders[j].order_info.length;z++){
173
+                  list[i].orders[j].order_info[z].record_date = list[i].orders[j].settle_accounts_date
174
+                  list[i].orders[j].order_info[z].number = list[i].orders[j].number
175
+                  this.tableData.push(list[i].orders[j].order_info[z])
176
+               }
177
+            }
178
+          }
179
+        for(let i=0;i<this.tableData.length;i++){
180
+          this.tableData[i].index = i+1
181
+          this.tableData[i].total_price = 0
182
+          this.tableData[i].total_price = (this.tableData[i].cnt * this.tableData[i].pric).toFixed(2)
183
+        }
184
+        console.log("322323232323322323",this.tableData)
150
        }
185
        }
151
      })
186
      })
152
 
187
 
153
 
188
 
154
     },
189
     },
190
+    getAdviceName(id){
191
+      var drug_name = ""
192
+      for(let i= 0;i<this.tableData.length;i++){
193
+         if(id == this.tableData[i].advice_id){
194
+           drug_name = this.tableData[i].advice.advice_name
195
+         }
196
+      }
197
+      return drug_name
198
+    },
199
+    getProjectName(id){
200
+     var project_name = ""
201
+     for(let i=0;i<this.tableData.length;i++){
202
+       if(id == this.tableData[i].project_id){
203
+         project_name = this.tableData[i].project.project.project_name
204
+       }
205
+     }
206
+     return project_name
207
+    }
155
   },
208
   },
156
   created() {
209
   created() {
157
     this.getGatherDetailList()
210
     this.getGatherDetailList()

+ 4 - 4
src/xt_pages/stock/drugs/inventory.vue Dosyayı Görüntüle

78
               </el-table-column>
78
               </el-table-column>
79
               <el-table-column prop="name" label="盘点前数量" width="180"  align="center">
79
               <el-table-column prop="name" label="盘点前数量" width="180"  align="center">
80
                 <template slot-scope="scope">
80
                 <template slot-scope="scope">
81
-                    <span><el-input style="width:50px" v-model="scope.row.stock_max_number" :disabled="true"></el-input>{{scope.row.max_unit}}</span> 
82
-                    <span v-if="scope.row.XtBaseDrug.max_unit!=scope.row.XtBaseDrug.min_unit"><el-input style="width:50px" v-model="scope.row.stock_min_number" :disabled="true"></el-input>{{scope.row.min_unit}}</span> 
81
+                    <span><el-input style="width:100px" v-model="scope.row.stock_max_number" :disabled="true"></el-input>{{scope.row.max_unit}}</span> 
82
+                    <span v-if="scope.row.XtBaseDrug.max_unit!=scope.row.XtBaseDrug.min_unit"><el-input style="width:100px" v-model="scope.row.stock_min_number" :disabled="true"></el-input>{{scope.row.min_unit}}</span> 
83
                   </template> 
83
                   </template> 
84
               </el-table-column>
84
               </el-table-column>
85
 
85
 
86
              <el-table-column prop="name" label="盘点后数量" width="180"  align="center">
86
              <el-table-column prop="name" label="盘点后数量" width="180"  align="center">
87
                 <template slot-scope="scope">
87
                 <template slot-scope="scope">
88
-                  <el-input style="width:50px" v-model="scope.row.last_stock_max_number"></el-input>{{scope.row.max_unit}}
89
-                 <span v-if="scope.row.XtBaseDrug.max_unit!=scope.row.XtBaseDrug.min_unit"><el-input style="width:50px" v-model="scope.row.last_stock_min_number"></el-input>{{scope.row.min_unit}}</span> 
88
+                  <el-input style="width:100px" v-model="scope.row.last_stock_max_number"></el-input>{{scope.row.max_unit}}
89
+                 <span v-if="scope.row.XtBaseDrug.max_unit!=scope.row.XtBaseDrug.min_unit"><el-input style="width:100px" v-model="scope.row.last_stock_min_number"></el-input>{{scope.row.min_unit}}</span> 
90
                  </template> 
90
                  </template> 
91
               </el-table-column>
91
               </el-table-column>
92
 
92