| | |
| | | import com.xiaopeng.api.model.operation.XpAgreement; |
| | | import com.xiaopeng.common.core.domain.R; |
| | | import com.xiaopeng.common.core.web.controller.BaseController; |
| | | import com.xiaopeng.operation.dto.XpAgreementAppUserDto; |
| | | import com.xiaopeng.operation.dto.XpAgreementDTO; |
| | | import com.xiaopeng.operation.service.IXpLoginAgreementService; |
| | | import com.xiaopeng.operation.service.XpAgreementService; |
| | | import com.xiaopeng.operation.vo.XpAgreementVo; |
| | | import com.xiaopeng.unifiedverification.interceptor.XpClientCheck; |
| | |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.validation.Valid; |
| | | import java.util.List; |
| | | |
| | |
| | | public class XpAgreementController extends BaseController { |
| | | |
| | | private final XpAgreementService xpAgreementService; |
| | | |
| | | @Resource |
| | | private IXpLoginAgreementService xpLoginAgreementService; |
| | | |
| | | public XpAgreementController(XpAgreementService xpAgreementService) { |
| | | this.xpAgreementService = xpAgreementService; |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | @ApiOperation(value = "获取协议/隐私政策",tags = {"运维APP-个人中心"},response = XpAgreementVo.class) |
| | | @GetMapping("/base/v1/privacy/content/{type}") |
| | | @GetMapping("/maintenance-app/base/v1/privacy/content/{type}") |
| | | public R<XpAgreementVo> getAppContent(@ApiParam(name = "type", value = "类型 8=运维APP-小鹏Robotaxi自动驾驶出行运维隐私政策 9=运维APP-第三方共享信息清单 10=运维APP-个人信息收集清单 11=运维APP-权限调用") @PathVariable Integer type) { |
| | | return R.ok(xpAgreementService.getContentByType(type)); |
| | | } |
| | | |
| | | @ApiOperation(value = "获取登录协议", tags = {"运维APP-登录"}, response = XpAgreementVo.class) |
| | | @GetMapping("/maintenance-app/base/v1/loginAgreement/getLoginAgreementList") |
| | | public R<List<XpAgreementVo>> getLoginAgreementList() { |
| | | return R.ok(xpLoginAgreementService.getLoginAgreementList(2)); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "获取协议",tags = {"管理后台-内容中心"}) |
| | | @GetMapping("/api/v1/agreement/content/{type}") |
| | | public R<XpAgreement> getAgreementContent(@ApiParam(name = "type", value = "类型 1=小鹏Robotaxi隐私政策 2=个人信息收集清单 3=敏感个人信息处理情况说明 4=向第三方提供个人信息情况的说明 5=乘车须知 6=计费规则说明 7=权限说明 8=运维APP-小鹏Robotaxi自动驾驶出行运维隐私政策 9=运维APP-第三方共享信息清单 10=运维APP-个人信息收集清单 11=运维APP-权限调用") @PathVariable Integer type) { |
| | | return R.ok(xpAgreementService.getAgreementContent(type)); |
| | | } |
| | | |
| | | @ApiOperation(value = "保存协议",tags = {"管理后台-内容中心"}) |
| | | @PostMapping("/api/v1/agreement/save") |
| | | public R<?> saveAgreement(@RequestBody @Valid XpAgreementDTO dto){ |