Browse Source

add fred TODO

ethan 6 years ago
parent
commit
385e376ae0
1 changed files with 19 additions and 2 deletions
  1. 19 2
      src/views/agnetManagement/gambleMemberManagement/index.vue

+ 19 - 2
src/views/agnetManagement/gambleMemberManagement/index.vue

95
               <span :style="moneyColor(scope.row.memberEarned)">{{scope.row.memberEarned}}</span>
95
               <span :style="moneyColor(scope.row.memberEarned)">{{scope.row.memberEarned}}</span>
96
             </template>
96
             </template>
97
           </el-table-column> -->
97
           </el-table-column> -->
98
+          <el-table-column label="莊家投注量抽水" align="center">
99
+            <template slot-scope="scope">
100
+              <span>{{0}}</span>
101
+            </template>
102
+          </el-table-column>
98
           <el-table-column label="莊家抽水" align="center">
103
           <el-table-column label="莊家抽水" align="center">
99
             <template slot-scope="scope">
104
             <template slot-scope="scope">
100
               <span>{{scope.row.bookieServiceFees}}</span>
105
               <span>{{scope.row.bookieServiceFees}}</span>
217
             totalPunishment: 0,
222
             totalPunishment: 0,
218
             bookieEarned: 0,
223
             bookieEarned: 0,
219
             memberEarned: 0,
224
             memberEarned: 0,
225
+            bookieWagerFee: 0,
220
             bookieServiceFees: 0,
226
             bookieServiceFees: 0,
221
             memberServiceFees: 0,
227
             memberServiceFees: 0,
222
             totalServiceFees: 0,
228
             totalServiceFees: 0,
229
             row.memberServiceFees = _.sumBy(bookie.false, 'serviceFees')*this.data.secondLayer.feeRatio/100;
235
             row.memberServiceFees = _.sumBy(bookie.false, 'serviceFees')*this.data.secondLayer.feeRatio/100;
230
           }
236
           }
231
           if (bookie.true) {
237
           if (bookie.true) {
238
+            console.log('ddd', bookie.true)
239
+            // TODO 請福哥加 此關總投著涼 bookie
240
+            //row.bookieWagerFee = _.sumBy(bookie.true, (item) => {
241
+            //  if(item.傯投注量>= item.wager上裝分數) {
242
+            //    return item.wagerServiceFees * this.data.secondLayer.feeRatio/100
243
+            //  } 
244
+            // if(item.總投注量<item.wager){
245
+            //   return item.總投注量 * * this.data.secondLayer.feeRatio/100
246
+            //
247
+            // }
248
+            //});
232
             row.bookieEarned = _.sumBy(bookie.true, 'earned');
249
             row.bookieEarned = _.sumBy(bookie.true, 'earned');
233
             row.bookieServiceFees = _.sumBy(bookie.true, (item) => { return item.serviceFees-item.FixedServiceFees })*this.data.secondLayer.feeRatio/100;
250
             row.bookieServiceFees = _.sumBy(bookie.true, (item) => { return item.serviceFees-item.FixedServiceFees })*this.data.secondLayer.feeRatio/100;
234
           }
251
           }
235
           row.totalServiceFees = new Decimal(row.bookieServiceFees).plus(row.memberServiceFees).valueOf()
252
           row.totalServiceFees = new Decimal(row.bookieServiceFees).plus(row.memberServiceFees).valueOf()
236
 
253
 
237
           let chipsLog = _.groupBy(member.GambleMemberChipsLogs, 'type')
254
           let chipsLog = _.groupBy(member.GambleMemberChipsLogs, 'type')
238
-          console.log('type', chipsLog)
255
+          // console.log('type', chipsLog)
239
           if (chipsLog['0'] || chipsLog['2']) {
256
           if (chipsLog['0'] || chipsLog['2']) {
240
             row.totalUp = _.sumBy(chipsLog['0'], (item) => { 
257
             row.totalUp = _.sumBy(chipsLog['0'], (item) => { 
241
               return item.chips > 0 ? item.chips : 0
258
               return item.chips > 0 ? item.chips : 0
257
               return item.chips < 0 ? item.chips : 0
274
               return item.chips < 0 ? item.chips : 0
258
             })
275
             })
259
           }
276
           }
260
-          console.log('www',row)
277
+          // console.log('www',row)
261
 
278
 
262
           this.combine.push(row)
279
           this.combine.push(row)
263
         })
280
         })