package cn.pluss.platform.controller.merchant.move;


import cn.pluss.platform.api.Result;
import cn.pluss.platform.base.BaseModelController;
import cn.pluss.platform.entity.MerchantMoveRecords;
import cn.pluss.platform.merchant.move.MerchantMoveRecordsService;
import com.baomidou.mybatisplus.core.metadata.OrderItem;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * <p>
 * 商户动态码生成记录 前端控制器
 * </p>
 *
 * @author bzg
 * @since 2021-07-30
 */
@Controller
@RequestMapping("/merchantMoveRecords")
public class MerchantMoveRecordsController extends BaseModelController<MerchantMoveRecordsService, MerchantMoveRecords> {

    @RequestMapping(method = {RequestMethod.GET, RequestMethod.POST}, value = "/index")
    public String index() {
        return "merchantMoveRecords/list";
    }

    @Override
    public Result<Page<MerchantMoveRecords>> page(Page<MerchantMoveRecords> page, MerchantMoveRecords condition, OrderItem orderItem) {
        orderItem.setColumn("createTime");
        orderItem.setAsc(false);
        return super.page(page, condition, orderItem);
    }
}
