| 123456789101112131415161718192021222324252627282930313233343536373839 |
- <?php
- namespace app\extra\service\blue;
- use app\extra\basic\Service;
- use app\model\blue\BlueWithdrawLog;
- class WithdrawLogService extends Service
- {
- /**
- * 列表
- * @param array $param
- */
- public function getList(array $param = [],string $field = "*")
- {
- $this->mode = new BlueWithdrawLog();
- return $this->searchVal($param,$this->searchFilter($param))->with(['bank' => function ($query) {
- $query->field("id,bank_code,bank_name")->append(['bank_img'])->withAttr(['bank_img' => function($data,$resp){
- return "https://apimg.alipay.com/combo.png?d=cashier&t={$resp['bank_code']}";
- }]);
- }])->field($field)->paginate([
- "list_rows" => $param['pageSize'],
- "page" => $param['page']
- ]);
- }
- /**
- *
- * @param array $param
- * @return array
- */
- public function searchFilter(array $param = []): array
- {
- $filter = [];
- !empty($param['openid']) && $filter[] = ["openid", '=', $param['openid']];
- return $filter;
- }
- }
|