dataLists(new WithdrawRecordLists()); } /** * @notes 获取代理提现记录列表 * @return \think\response\Json * @author bd * @date 2024/01/31 14:07 */ public function agentLists() { return $this->dataLists(new AgentWithdrawRecordLists()); } /** * @notes 添加提现记录 * @return \think\response\Json * @author BD * @date 2024/02/25 12:35 */ public function add() { $params = (new WithdrawRecordValidate())->post()->goCheck('add'); $result = WithdrawRecordLogic::add($params); if (true === $result) { return $this->success('添加成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 编辑提现记录 * @return \think\response\Json * @author BD * @date 2024/02/25 12:35 */ public function edit() { $params = (new WithdrawRecordValidate())->post()->goCheck('edit'); $result = WithdrawRecordLogic::edit($params); if (true === $result) { return $this->success('编辑成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 删除提现记录 * @return \think\response\Json * @author BD * @date 2024/02/25 12:35 */ public function delete() { $params = (new WithdrawRecordValidate())->post()->goCheck('delete'); WithdrawRecordLogic::delete($params); return $this->success('删除成功', [], 1, 1); } /** * @notes 获取提现记录详情 * @return \think\response\Json * @author BD * @date 2024/02/25 12:35 */ public function detail() { $params = (new WithdrawRecordValidate())->goCheck('detail'); $result = WithdrawRecordLogic::detail($params); return $this->data($result); } /** * @notes udun代付 * @return \think\response\Json * @author bd * @date 2024/01/31 14:07 */ public function udunPay() { $params = (new WithdrawRecordValidate())->post()->goCheck('udunPay'); $result = WithdrawRecordLogic::udunPay($params); if ('success' === $result) { return $this->success('发起成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 同意提现 * @return \think\response\Json * @author bd * @date 2024/01/31 14:07 */ public function agree() { $params = (new WithdrawRecordValidate())->post()->goCheck('agree'); $result = WithdrawRecordLogic::agree($params); if (true === $result) { return $this->success('同意成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 拒绝提现 * @return \think\response\Json * @author bd * @date 2024/01/31 14:07 */ public function refuse() { $params = (new WithdrawRecordValidate())->post()->goCheck('refuse'); $result = WithdrawRecordLogic::refuse($params); if (true === $result) { return $this->success('拒绝成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 备注 * @return \think\response\Json * @author bd * @date 2024/01/31 14:07 */ public function remark() { $params = $this->request->post(); $params['admin_id'] = $this->adminId; $result = WithdrawRecordLogic::remark($params); if (true === $result) { return $this->success('备注成功', [], 1, 1); } return $this->fail(WithdrawRecordLogic::getError()); } /** * @notes 提现统计 * @return \think\response\Json * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author bd * @date 2024/01/31 14:07 */ public function stat() { $result = WithdrawRecordLogic::stat(); return $this->success('', $result); } }