from django.urls import path, include
from django.views.decorators.csrf import csrf_exempt
from .views import WechatMiniProgramLoginView, UserInfoUpdateView, DashouXinxiAPIView, \
    ZaixianZhuangtaiAPIView, GuanshiXinxiView, ShangJiaXinXiView, ShangjiaNichengGengxinView, BossBiaoshiView, YaoqingmaView, \
    DashouZhuceView, GuanshiYaoqingDashouListView, TixianXinxiHuoquView, ShoukuanXinxiShangchuanView, \
    TixianShenqingView, TixianJiluHuoquViewV2, AdminLoginView, AdminFinancialDataView, AdGetOrderList, \
    AdGetOrderTypes, AdGuanLiYongHu, AdYaoQingDaShou, CfGuanLi, AdTongYiChuFa, AdckyhxqView, AdcjxgView, AddtxshView, \
    AdtixianqkView, DashouZiliaoHuoquView, DashouGengxinView,ShangjiaZhuceView,\
    PaihangbangGuanliQueryView,PaihangbangRiqiliebiaoView, WechatLoginAndDashouRegisterView, \
    YonghuTixianShenheXiugaiView, ChufaJiluHuoquView, DashouShensuView, ShangjiaChufaJiluHuoquView, \
    WeixinOfficialCallbackView,KefuLoginView, KefuStatsView, KefuGetOrderTypesView, KefuGetOrderListView, \
    KefuGetShangjiaOrderListView, KefuGetOrderDetailView, KefuChangeDashouView, KefuRecoverOrderView, \
    KefuPlatformRefundView, KefuRejectRefundView, KefuMerchantRefundView, KefuRejectSettlementView, \
    KefuTransferHallView, KefuCancelDesignationView, KefuUpdateOrderGrabRequirementView, \
    KefuBatchProductGrabRequirementView, KefuGetDashouListView, KefuGetDashouDetailView, \
    KefuUpdateDashouView, KefuPunishmentListView, KefuPunishmentActionView, KefuPunishmentDetailView, \
    KefuWithdrawListView, KefuWithdrawDetailView, KefuWithdrawActionView, KefuPunishView, AdKfglView, AdKftjView, \
    AdKfxgView,GuanshiRegisterView, WechatLoginAndGuanshiRegisterView,ZuzhangZhuceView, ZuzhangXinxiView,KefuForceCompleteView,HuoQuYaoQingRenView, DashouJianquanView, LaobanJianquanView,\
    FaKuanJiFenTongJiView, DaShouFaKuanLieBiaoView, ShangjiaCufaTongjiView, ShangjiaFakuanLieBiaoView,\
    FaKuanShenSuView, FaKuanPayView,FaKuanHuitiaoView, FaKuanPayPollView, FaKuanPayFailView,KaohePayView,KaohePayCallbackView, KaohePayPollView,KaohePayFailView, TixianAssetView, GuanshiContactView,TixianQueRenAutoView, TixianShenqingV3View, TixianCallbackV3View, \
    GetUserPhoneView, BindUserPhoneView, BossSearchDashouView, \
    FundFreezeMineView, FundFreezeMyLedgerView, FundFreezeMyLedgerDetailView, \
    RoleAgreementCurrentView, RoleAgreementMineView, RoleAgreementSignView, \
    GuanshiChangeZuzhangInfoView, GuanshiChangeZuzhangView
from .tixian_shenhe_views import TixianZddkshApplyView
from .paihang_views import PhbHqsjView
from .xzj_paihang_views import XzjPhbHqsjView
from rank.reward_views import PhbJlXxView, PhbJlWdView, PhbJlLqView, PhbJlPhbView, PhbJlClubListView
from .views.c_invite import CYaoqingmaView, CYaoqingBangdingView, CYaoqingListView, CYaoqingWodeView


urlpatterns = [
    path('wechatlogin', WechatMiniProgramLoginView.as_view(), name='用户一键微信登录'),
    path('xiugai', UserInfoUpdateView.as_view(), name='用户信息修改'),
    path('hqshouji', GetUserPhoneView.as_view(), name='获取用户手机号认证状态'),
    path('rzwlsjh', BindUserPhoneView.as_view(), name='一键认证手机号'),
    path('sousuodashou', BossSearchDashouView.as_view(), name='点单端搜索可指定打手'),
    # 打手信息接口
    path('dashouxinxi', DashouXinxiAPIView.as_view(), name='打手信息查询'),
    # 更改在线状态接口
    path('zaixianzhuangtai', ZaixianZhuangtaiAPIView.as_view(), name='打手在线状态更改'),
    path('guanshixinxi', GuanshiXinxiView.as_view(), name='获取管事信息'),
    path('shangjiaxinxi', ShangJiaXinXiView.as_view(), name='获取商家信息'),
    path('shangjiagxnc', ShangjiaNichengGengxinView.as_view(), name='商家修改昵称'),
    path('bossbiaoshi', BossBiaoshiView.as_view(), name='获取老板标识'),
    path('yaoqingma', YaoqingmaView.as_view(), name='管事生成邀请码'),
    path('cyaoqingma', CYaoqingmaView.as_view(), name='点单端生成邀请码'),
    path('cyaoqingbd', CYaoqingBangdingView.as_view(), name='点单端绑定邀请人'),
    path('cwyqr', CYaoqingListView.as_view(), name='点单端我邀请的人'),
    path('cyqwd', CYaoqingWodeView.as_view(), name='点单端我的邀请摘要'),
    path('dashouzhuce',DashouZhuceView.as_view(), name='打手邀请码注册'),
    path('gshqyqds', GuanshiYaoqingDashouListView.as_view(), name='管事获取邀请打手'),
    path('tixianhq', TixianXinxiHuoquView.as_view(), name='获取体现缓存信息'),  # 获取提现信息
    path('sksc', ShoukuanXinxiShangchuanView.as_view(), name='上传提现相关数据或收款码'),  # 上传收款信息
    path('tixian', TixianShenqingView.as_view(), name='提现申请'),  # 提交提现申请
    path('tixianjiluhq', TixianJiluHuoquViewV2.as_view(), name='打手提现记录查询'),
    path('adlog', AdminLoginView.as_view(), name='管理元登录'),
    path('adhq', AdminFinancialDataView.as_view(), name='管理元获取收支记录'),
    path('adgetordertypes', AdGetOrderTypes.as_view(), name='管理员获取订单类型'),

    # 订单列表获取接口
    path('adddhq', AdGetOrderList.as_view(), name='管理员获取订单列表'),
    path('adyqds', AdYaoQingDaShou.as_view(), name='管理员获取邀请码'),

    # 用户管理列表接口
    path('adgl', AdGuanLiYongHu.as_view(), name='管理员获取用户'),
    path('cfgl', CfGuanLi.as_view(), name='处罚记录获取'),
    path('adtycf', AdTongYiChuFa.as_view(), name='同意或拒绝处罚'),
    path('adckyhxq', AdckyhxqView.as_view(), name='管理员获取用户具体数据'),

    # 修改用户信息接口
    path('adcjxg',AdcjxgView.as_view(), name='管理员修改用户数据'),
    path('addtxsh', AddtxshView.as_view(), name='管理员获取提现审核'),

    # 处理提现申请接口
    path('adtixianqk', AdtixianqkView.as_view(), name='管理员提现修改'),
    # 打手资料获取
    path('dszjxxhq', DashouZiliaoHuoquView.as_view(), name='打手获取自己信息'),

    # 打手信息更新
    path('dsgxxx', DashouGengxinView.as_view(), name='打手修改自己信息'),
    path('shangjiahuce', ShangjiaZhuceView.as_view(), name='商家注册'),
    path('paihangbang', PaihangbangGuanliQueryView.as_view(), name='管理查询排行榜'),
    path('adhqphrq', PaihangbangRiqiliebiaoView.as_view(), name='管理原获取排行榜日期'),


    path('wdlyhdl', WechatLoginAndDashouRegisterView.as_view(), name='打手扫码注册'),
    path('yonghutxshxg', YonghuTixianShenheXiugaiView.as_view(), name='用户自己体现修改'),
    path('dshqcfjl', ChufaJiluHuoquView.as_view(), name='打手处罚记录获取'),
    # 打手申诉接口
    path('dscfss', DashouShensuView.as_view(), name='打手处罚上诉申请'),
    path('sjcfjlhq', ShangjiaChufaJiluHuoquView.as_view(), name='商家处罚记录获取'),
    path('officialcallback', csrf_exempt(WeixinOfficialCallbackView.as_view()), name='用户关注取关服务号回调'),



    path('kefujinru', KefuLoginView.as_view(), name='客服登录'),
    path('kfjrhqzl', KefuStatsView.as_view(), name='客服获取数据'),
    path('kfhqptddlx', KefuGetOrderTypesView.as_view(), name='客服获取订单类型'),
    path('kfhqddlb', KefuGetOrderListView.as_view(), name='客服获取订单列表'),

    path('kfhqsjddlb', KefuGetShangjiaOrderListView.as_view(),name='客服获取商家订单列表'),
    path('kefuhqddxq', KefuGetOrderDetailView.as_view(), name='获取订单详情页面'),
    path('kefughds', KefuChangeDashouView.as_view(), name='客服更换打手'),
    path('kefuhf', KefuRecoverOrderView.as_view(), name='客服恢复订单'),
    path('kefupttk', KefuPlatformRefundView.as_view(), name='客服给平台订单退款'),
    path('kefujjtk', KefuRejectRefundView.as_view(), name='客服拒绝商家退款'),
    path('kefusjtk', KefuMerchantRefundView.as_view(), name='客服同意商家退款'),
    path('kefujjjs', KefuRejectSettlementView.as_view(), name='客服拒绝结算'),
    path('kefuzydt', KefuTransferHallView.as_view(), name='客服订单返回大厅'),
    path('kefuqxzd', KefuCancelDesignationView.as_view(), name='客服取消指定'),
    path('kefu_gai_qiangdan_yaoqiu', KefuUpdateOrderGrabRequirementView.as_view(), name='客服改订单抢单要求'),
    path('kefu_batch_qiangdan_yaoqiu', KefuBatchProductGrabRequirementView.as_view(), name='客服批量改商品抢单要求'),
    path('kefuhqdslb', KefuGetDashouListView.as_view(), name='客服获取打手数据'),
    path('kefuhqdsxq', KefuGetDashouDetailView.as_view(), name='客服获取打手具体信息'),
    path('kefuxgds', KefuUpdateDashouView.as_view(), name='客服修改打手数据'),
    path('kefu_cfgl', KefuPunishmentListView.as_view(), name='客服获取处罚记录'),
    path('kefu_cf_detail', KefuPunishmentDetailView.as_view(), name='kefu_cf_detail'),
    path('kefu_cf_action', KefuPunishmentActionView.as_view(), name='客服处理处罚'),
    path('kefuqiangzhijiedan', KefuForceCompleteView.as_view(), name='客服强制结单'),


    path('kefu_txsh_list', KefuWithdrawListView.as_view(), name='客服获取体现数据'),
    path('kefu_txsh_detail', KefuWithdrawDetailView.as_view(), name='客服获取体现详情数据'),

    path('kefu_txsh_action', KefuWithdrawActionView.as_view(), name='客服处理体现'),
    path('kefuchufa', KefuPunishView.as_view(), name='客服申请出发打手'),
    path('adkfgl', AdKfglView.as_view(), name='管理员获取客服数据'),
    path('adkftj', AdKftjView.as_view(), name='管理添加客服'),
    path('adkfxg', AdKfxgView.as_view(), name='管理修改客服'),

    # 已登录用户注册管事
    #path('guanshizhuce', GuanshiRegisterView.as_view(), name='管事注册，已经登陆'),
    path('guanshizhuce', GuanshiRegisterView.as_view(), name='管事注册，已经登陆'),
    
    # 未登录用户微信登录+管事注册
    path('zuzhangyqmzc', WechatLoginAndGuanshiRegisterView.as_view(), name='管事注册，没有登录'),

    # 管事自助更换组长
    path('gs_huan_zuzhang_info', GuanshiChangeZuzhangInfoView.as_view(), name='管事换组长信息'),
    path('gs_huan_zuzhang', GuanshiChangeZuzhangView.as_view(), name='管事换组长提交'),

    path('zuzhangzhuce', ZuzhangZhuceView.as_view(), name='组长注册'),
    path('zuzhangxinxi', ZuzhangXinxiView.as_view(), name='组长刷新获取信息'),

    path('hqwdyqr', HuoQuYaoQingRenView.as_view(), name='打手联系获取管事'),

    path('dshqltqx', DashouJianquanView.as_view(), name='前端鉴权打手是否有使用消息功能'),    # 打手鉴权
    path('lbhqltqx', LaobanJianquanView.as_view(), name='鉴权老板是否有使用消息功能'),     # 老板鉴权


   # 获取罚款 + 积分处罚综合统计
    path('cffktjhq', FaKuanJiFenTongJiView.as_view(), name='获取罚款 + 积分处罚综合统计'),

    # 获取打手自己的罚款列表
    path('dsfklbhq', DaShouFaKuanLieBiaoView.as_view(), name='获取打手自己的罚款列表'),

    # 商家端处罚统计 / 金额罚单列表
    path('sjcftjhq', ShangjiaCufaTongjiView.as_view(), name='商家处罚统计'),
    path('sjfklbhq', ShangjiaFakuanLieBiaoView.as_view(), name='商家罚款列表'),

    # 提交罚款申诉
    path('fkss', FaKuanShenSuView.as_view(), name='提交罚款申诉'),


    path('fkjn', FaKuanPayView.as_view(), name='提交罚款微信支付申请'),            # 下单
    path('fk_huitiao', csrf_exempt(FaKuanHuitiaoView.as_view()), name='提交罚款微信支付回调'),  # 回调
    path('fkzffc', FaKuanPayPollView.as_view(), name='提交罚款申微信支付成功轮询'),      # 轮询
    path('fkzfsb', FaKuanPayFailView.as_view(), name='提交罚款微信支付失败'),      # 失败

    path('khzf', KaohePayView.as_view(), name='考核支付下单'),
    path('kh_huitiao', csrf_exempt(KaohePayCallbackView.as_view()), name='考核支付回调'),
    path('khzffc', KaohePayPollView.as_view(), name='考核支付复查轮询'),
    path('khzfsb', KaohePayFailView.as_view(), name='考核支付失败'),

    path('tixianzichan', TixianAssetView.as_view(), name='小程序提现数据获取'),
    path('fund-freeze-mine', FundFreezeMineView.as_view(), name='小程序冻结资金汇总'),
    path('fund-freeze-ledger', FundFreezeMyLedgerView.as_view(), name='小程序冻结资金明细'),
    path('fund-freeze-ledger-detail', FundFreezeMyLedgerDetailView.as_view(), name='小程序冻结单详情'),
    path('role-agreement/current', RoleAgreementCurrentView.as_view(), name='小程序角色协议当前'),
    path('role-agreement/mine', RoleAgreementMineView.as_view(), name='小程序角色协议列表'),
    path('role-agreement/sign', RoleAgreementSignView.as_view(), name='小程序角色协议签署'),
    path('guanshi_contact', GuanshiContactView.as_view(), name='获取组长'),



    path('zddksh', TixianZddkshApplyView.as_view(), name='自动提现审核申请'),
    path('tixiansq', TixianShenqingV3View.as_view(), name='自动提现收款'),
    path('tixianqr', TixianQueRenAutoView.as_view(), name='自动提现确认'),
    path('tixiancallback', csrf_exempt(TixianCallbackV3View.as_view()), name='提现回调'),
    path('phbhqsj', PhbHqsjView.as_view(), name='排行榜数据'),
    path('xzjphbhqsj', XzjPhbHqsjView.as_view(), name='星之界排行榜数据'),
    path('phbjlxx', PhbJlXxView.as_view(), name='排行榜奖励信息'),
    path('phbjlwd', PhbJlWdView.as_view(), name='排行榜待领取列表'),
    path('phbjllq', PhbJlLqView.as_view(), name='排行榜奖励领取'),
    path('phbjlphb', PhbJlPhbView.as_view(), name='排行榜俱乐部集团榜'),
    path('phbjljlb', PhbJlClubListView.as_view(), name='排行榜奖励俱乐部列表'),
    path('merchant-staff/', include('merchant_ops.urls')),
]