package com.gree.mall.manager.controller.workerorder;

import com.gree.mall.manager.annotation.ApiNotAuth;
import com.gree.mall.manager.bean.SyncOrderDto;
import com.gree.mall.manager.bean.workorder.ChangeAppointmentVO;
import com.gree.mall.manager.bean.workorder.ChangeWorkerVO;
import com.gree.mall.manager.bean.workorder.PgOrderProductDetailVO;
import com.gree.mall.manager.bean.workorder.WorkerOrderDetail;
import com.gree.mall.manager.helper.ResponseHelper;
import com.gree.mall.manager.logic.workorder.ChangeOrderLogic;
import com.gree.mall.manager.logic.workorder.OrderBaseExcelLogic;
import com.gree.mall.manager.plus.entity.PgOrderProductDetail;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;
import java.text.ParseException;
import java.util.List;

@Slf4j
@RestController
@Api(value = "同步订单sync", tags = {"同步订单sync"})
@RequestMapping(value = "/sync", produces = "application/json; charset=utf-8")
public class SyncOrderController {

    @Autowired
    private OrderBaseExcelLogic orderBaseExcelLogic;


    @ApiNotAuth
    @PostMapping("/sync")
    @ApiOperation("修改预约时间")
    public ResponseHelper changeAppointmentTime(
            @RequestBody SyncOrderDto syncOrderDto,
            HttpServletRequest request
    ) throws ParseException {



        orderBaseExcelLogic.saveThreeOrder(syncOrderDto);

        return ResponseHelper.success();
    }


}
