| | |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.common.constant.factory.PageFactory; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | | import com.stylefeng.guns.core.util.SinataUtil; |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import com.stylefeng.guns.modular.system.model.TPubWithdrawal; |
| | | import com.stylefeng.guns.modular.system.model.TSystemNotice; |
| | | import com.stylefeng.guns.modular.system.model.TWithdrawal; |
| | | import com.stylefeng.guns.modular.system.service.ITPubWithdrawalService; |
| | | import com.stylefeng.guns.modular.system.service.ITSystemNoticeService; |
| | | import com.stylefeng.guns.modular.system.service.ITWithdrawalService; |
| | | import com.stylefeng.guns.modular.system.util.HttpRequestUtil; |
| | | import com.stylefeng.guns.modular.system.util.PushURL; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | import org.springframework.ui.Model; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import com.stylefeng.guns.modular.system.model.TPubWithdrawal; |
| | | import com.stylefeng.guns.modular.system.service.ITPubWithdrawalService; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | import java.util.HashMap; |
| | | import java.util.Map; |
| | |
| | | @RequestMapping("/tPubWithdrawal") |
| | | public class TPubWithdrawalController extends BaseController { |
| | | |
| | | private String PREFIX = "/system/tPubWithdrawal/"; |
| | | private String PREFIX = "/system/tWithdrawal/"; |
| | | |
| | | @Autowired |
| | | private ITPubWithdrawalService tPubWithdrawalService; |
| | | |
| | | |
| | | @Autowired |
| | | private ITSystemNoticeService tSystemNoticeService; |
| | | @Autowired |
| | | private ITWithdrawalService withdrawalService; |
| | | |
| | | /** |
| | | * 跳转到提现列表首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | | return PREFIX + "tPubWithdrawal.html"; |
| | | return PREFIX + "tWithdrawal.html"; |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | @RequestMapping("/tPubWithdrawal_immediately/{tPubWithdrawalId}") |
| | | public String tPubWithdrawalUpdate(@PathVariable Integer tPubWithdrawalId, Model model) { |
| | | model.addAttribute("tPubWithdrawalId",tPubWithdrawalId); |
| | | return PREFIX + "tPubWithdrawal_immediately.html"; |
| | | TWithdrawal tWithdrawal = withdrawalService.selectById(tPubWithdrawalId); |
| | | tWithdrawal.setWithdrawalTimeStr(new SimpleDateFormat("yyyy-MM-dd HH:mm").format(tWithdrawal.getWithdrawalTime())); |
| | | tWithdrawal.setWithdrawalTypeStr(tWithdrawal.getWithdrawalType()==1?"支付宝":"银行卡"); |
| | | model.addAttribute("item",tWithdrawal); |
| | | LogObjectHolder.me().set(tWithdrawal); |
| | | if(tWithdrawal.getStatus() == 1){ |
| | | return PREFIX + "tWithdrawal_edit.html"; |
| | | }else { |
| | | return PREFIX + "tWithdrawal_detail.html"; |
| | | } |
| | | } |
| | | |
| | | /** |
| | |
| | | @ResponseBody |
| | | public Object list(String insertTime, |
| | | String name, |
| | | Integer withdrawalType) { |
| | | Integer status) { |
| | | String beginTime = null; |
| | | String endTime = null; |
| | | if (SinataUtil.isNotEmpty(insertTime)){ |
| | |
| | | if (ShiroKit.getUser().getRoleType() != 1){ |
| | | page.setRecords(null); |
| | | }else{ |
| | | page.setRecords(tPubWithdrawalService.getWithdrawalList(page,beginTime,endTime,name,withdrawalType)); |
| | | page.setRecords(tPubWithdrawalService.getWithdrawalList(page,beginTime,endTime,name,status)); |
| | | } |
| | | return super.packForBT(page); |
| | | } |