from django.contrib import admin from django.urls import include from django.urls import re_path from AdminController import UserManageController, RoleController, MenuController, TestServeController, \ ServeManagementController, LogManagementController, DeviceManagementController, VersionManagementController, \ AiServeController, SurveysManageController, SerialManageController, IcloudManagementController from Controller import FeedBack, EquipmentOTA, EquipmentInfo, AdminManage, AppInfo, \ Test, MealManage, DeviceManage, EquipmentStatus, SysManage, DeviceLog, LogAccess, \ AppColophon, DateController, \ EquipmentManager, LogManager, PermissionManager, OTAEquipment, shareUserPermission, UidSetController, \ UserManger, CheckUserData, \ UserController, CloudVod, OrderContrller, VodBucket, DetectController, DeviceShare, UserBrandController, \ StsOssController, UIDPreview, OssCrd, SysMsg, UidUser, EquipmentManagerV2, EquipmentManagerV3, PushDeploy, \ AppSetController, \ ApplicationController, UserExController, CloudStorage, TestApi, UserBrandControllerV2, \ StatisticsController, Alexa, FAQController, AppLogController, EquipmentVersionLimit, VoicePromptController, \ CDKController, \ DeviceTypeController, CloudTransfer, Cloudsum, IotCoreController, OperatingLogs, ProcessInfo, \ RegionCountryController, \ VerifyCodeController, FileController, UIDController, LogController, SalesController, \ OrderTaskController, HistoryUIDController, UIDManageUserController, SerialNumberController, CompanyController, \ RegionController, VPGController, LanguageController, TestController, DeviceConfirmRegion, S3GetStsController, \ DetectControllerV2, PcInfo, PctestController, DeviceDebug, PaymentCycle, \ DeviceLogController, CouponController, AiController, ShadowController, AppAccountManagement, InitController from Controller.Cron import CronTaskController from Controller.MessagePush import EquipmentMessagePush from Controller.SensorGateway import SensorGatewayController, EquipmentFamilyController from Controller.Surveys import CloudStorageController from Controller.UserDevice import UserDeviceShareController urlpatterns = [ re_path(r'init/(?P.*)', InitController.InitView.as_view()), re_path(r'^testApi/(?P.*)', TestApi.testView.as_view()), re_path(r'^account/authcode', UserController.authCodeView.as_view()), re_path(r'^v3/account/generatepictureCodeView/$', UserController.generatePictureCodeView.as_view()), re_path(r'^v3/account/imageCodeRegister/$', UserController.Image_Code_RegisterView.as_view()), re_path(r'^account/register$', UserController.registerView.as_view()), re_path(r'^account/login$', UserController.v2LoginView.as_view()), re_path(r'^account/logout$', UserController.LogoutView.as_view()), re_path(r'^account/noPasslogin$', UserController.noPasslogin.as_view()), re_path(r'^account/changePwd$', UserController.ChangePwdView.as_view()), re_path(r'^account/forget$', UserController.ForgetPwdView.as_view()), re_path(r'^account/email-re-pwd$', UserController.EmailResetPwdView.as_view()), re_path(r'^account/refreshTk$', UserController.refreshTokenView.as_view()), re_path(r'^v3/account/refreshTk$', UserController.refreshTokenViewV3.as_view()), re_path(r'^v3/account/deleteUser$', UserController.DeleteUser.as_view()), re_path(r'^favicon.ico$', UserManger.success, name=u'favicon.ico'), re_path(r'^account/showUserMore$', UserManger.showUserMoreView.as_view()), re_path(r'^account/perfectUserInfo$', UserManger.perfectUserInfoView.as_view()), re_path(r'^account/getAvatar/(?P.*)$', UserManger.getAvatarView.as_view()), re_path(r'^account/delUser$', UserManger.delUserInterface), re_path(r'^account/setUserValid$', UserManger.setUserValidView.as_view()), re_path(r'^account/showAllUser$', UserManger.showAllUserInterface), re_path(r'^account/help$', LogManager.HelpView.as_view()), re_path(r'^account/searchUser$', shareUserPermission.searchUserView.as_view()), re_path('accounts', AdminManage.search_user_by_content), # 多条件搜索用户信息admin re_path(r'^account/shareUserEquipment$', shareUserPermission.shareUserEquipmentView.as_view()), re_path(r'^account/unsharedUserEquipment$', shareUserPermission.unsharedUserEquipmentView.as_view()), re_path(r'^response/success$', UserManger.success), re_path(r'^equipment/queryUserEquipment$', EquipmentManager.queryUserEquipmentInterface), re_path(r'^equipment/addNewUserEquipment$', EquipmentManager.addNewUserEquipmentInterface), re_path(r'^equipment/delUserEquipment$', EquipmentManager.delUserEquipmentInterface), re_path(r'^equipment/modifyUserEquipment$', EquipmentManager.modifyUserEquipmentInterface), re_path(r'^equipment/showAllUserEquipment$', EquipmentManager.showAllUserEquipmentInterface), re_path(r'^equipment/findEquipmentInfo$', EquipmentManager.findEquipmentInfoInterface), re_path(r'^equipment/delete', EquipmentManager.deleteInterface), re_path(r'^equipment/batchDelete', EquipmentManager.batchDeleteInterface), re_path(r'^equipment/add', EquipmentManager.addInterface), re_path(r'^equipment/admin_add', EquipmentManager.admin_addInterface), re_path(r'^equipment/admin_modify', EquipmentManager.admin_modifyInterface), re_path(r'^equipment/query', EquipmentManager.queryInterface), re_path(r'^equipment/flow$', EquipmentManager.uid_status), re_path(r'^OTA/uploads$', OTAEquipment.getUploadFiletoDirView.as_view()), re_path(r'^OTA/download$', OTAEquipment.downloadUpdataFileUrl), re_path(r'^OTA/downloads/(\w+)/(\w+[\w+]*.+[^_w]*.\w+)$', OTAEquipment.downloadUpdataFileUrlInterface), re_path(r'^OTA/getEquipmentVersion$', OTAEquipment.getEquipmentVersionInterface), re_path(r'^OTA/getUpdataFileUrl$', OTAEquipment.getUpdataFileUrlInterface), re_path(r'^OTA/addNewEquipmentVersion$', OTAEquipment.addNewEquipmentVersionInterface), re_path(r'^roles/addNewRole$', PermissionManager.addNewRoleView.as_view()), re_path(r'^roles/queryRole$', PermissionManager.queryRoleView.as_view()), re_path(r'^roles/delRole$', PermissionManager.delRoleView.as_view()), re_path(r'^roles/modifyRole$', PermissionManager.modifyRoleView.as_view()), re_path(r'^perms/addNewPerms$', PermissionManager.addNewPermsView.as_view()), re_path(r'^perms/delPerms$', PermissionManager.delPermsView.as_view()), re_path(r'^perms/queryPerms$', PermissionManager.queryPermsView.as_view()), re_path(r'^perms/modifyPerms$', PermissionManager.modifyPermsView.as_view()), re_path(r'^permsManager/queryRolePerms$', PermissionManager.queryRolePermsView.as_view()), re_path(r'^uploads/upgrade$', OTAEquipment.getUploadFiletoDirView.as_view()), re_path(r'^upgrade/download/(\w+.[^_w]*\w+.\w+)$', CheckUserData.download_file), re_path(r'^downloads/upgrade/(\w+)/(\w+.[^_w]*\w+.\w+)$', OTAEquipment.downloadUpdataFileUrlInterface), re_path(r'^getOTAurl/getUpdataFileUrl$', OTAEquipment.getUpdataFileUrlInterface), re_path(r'^equipment/info', EquipmentInfo.EquipmentInfo.as_view()), re_path(r'^adminManage/manage', AdminManage.AdminManage.as_view()), re_path(r'^equipment/OTA', EquipmentOTA.EquipmentOTA.as_view()), re_path(r'^userbrandinfo/(?P.*)$', UserBrandController.UserBrandInfo.as_view()), re_path(r'^uidset/(?P.*)$', UidSetController.UidSetView.as_view()), re_path(r'^appInfo', AppInfo.AppInfo.as_view()), re_path(r'^meal/manage', MealManage.MealManage.as_view()), re_path(r'^device/manage$', DeviceManage.DeviceManage.as_view()), re_path(r'^device/online$', EquipmentStatus.EquipmentOnline), re_path(r'^device/offline$', EquipmentStatus.EquipmentOffline), re_path(r'^device/updateIP$', EquipmentStatus.updateIP), re_path(r'^sys/updateLog', SysManage.updateLog), re_path(r'^devices/(\w+)/logs$', DeviceLog.DeviceLog), re_path(r'^devices/(\w+)$', DeviceManage.Devices), re_path(r'^LogAccess$', LogAccess.LogAccess), re_path(r'^HelpCHM/upload$', LogManager.upload_help_chm), re_path(r'^admin/userIDs$', AdminManage.getUserIds), re_path('eq/delById', EquipmentInfo.deleteExpireEquipmentInfoById), re_path(r'^OTA/getNewVer', OTAEquipment.getNewVerInterface), re_path(r'^OTA/uploadsPack$', OTAEquipment.uploadOTAInterfaceView.as_view()), re_path(r'^OTA/downloadsPack/(?P[0-9\w/.\-]+)', OTAEquipment.downloadOTAInterface), re_path(r'^dlotapack/(?P[0-9\w/.\-]+)', OTAEquipment.downloadOTAInterfaceV2), re_path(r'^OTA/getDownLoadOTApackUrl$', OTAEquipment.getDownLoadOTApackUrl), re_path(r'^OTA/checkMaxVersion$', OTAEquipment.checkMaxVersion), re_path(r'^v2/account/authcode$', UserController.v2authCodeView.as_view()), re_path(r'^v2/account/register$', UserController.v2registerView.as_view()), re_path(r'^v2/account/forgetCode$', UserController.v2forgetPwdCodeView.as_view()), re_path(r'^v2/account/resetPwdByCode$', UserController.v2resetPwdByCodeView.as_view()), re_path(r'^v2/authcode/verify$', UserController.verifyAuthcode.as_view()), re_path(r'^v2/account/logout$', UserController.V2LogoutView.as_view()), re_path(r'^v2/account/login$', UserController.v3LoginView.as_view()), re_path(r'^v3/account/login$', UserController.v3LoginView.as_view()), re_path(r'^account/oneClickLogin$', UserController.oneClickLoginView.as_view()), re_path(r'^account/createPwd$', UserController.createPwd.as_view()), re_path(r'^account/delete$', UserController.deleteAccount), re_path(r'^user/confirmRegion$', UserController.confirmRegion), re_path(r'^account/loginCode$', UserController.loginCodeView.as_view()), re_path(r'^v3/account/loginByCode$', UserController.v3LoginByCodeView.as_view()), re_path(r'^v3/account/loginByFingerprint$', UserController.v3LoginByFingerprintView.as_view()), re_path(r'^v3/account/setFingerprint$', UserController.v3SetFingerprintView.as_view()), re_path(r'^detect/(?P.*)$', DetectController.DetectControllerView.as_view()), re_path(r'^detectV2/(?P.*)$', DetectControllerV2.DetectControllerViewV2.as_view()), re_path(r'^cloudVod/(?P.*)$', CloudVod.CloudVodView.as_view()), re_path(r'^meal/(?P.*)$', MealManage.MealView.as_view()), re_path(r'^order/(?P.*)$', OrderContrller.OrderView.as_view()), re_path(r'^appCol/(?P.*)$', AppColophon.AppColView.as_view()), re_path(r'^vodBucket/(?P.*)$', VodBucket.VodBucketView.as_view()), re_path(r'^UIDBucket/(?P.*)$', VodBucket.UidBucketView.as_view()), re_path(r'^EquipmentVersion/(?P.*)$', EquipmentOTA.EquipmentVersionView.as_view()), re_path(r'^deviceShare/(?P.*)$', DeviceShare.DeviceShareView.as_view()), re_path(r'^appVer/views$', AppInfo.AppVersionView.as_view()), re_path(r'^user/initInfo$', UserController.InitInfoView.as_view()), re_path(r'^user/information/(?P.*)$', UserController.InitUserInformationView.as_view()), re_path(r'^user/getSalt$', UserController.getPasswordSalt), re_path(r'^getTZ$', EquipmentStatus.getTZ), re_path(r'^stsOss/(?P.*)$', StsOssController.StsOssView.as_view()), re_path(r'^feedback/(?P.*)$', FeedBack.FeedBackView.as_view()), re_path(r'^uidpreview/(?P.*)$', UIDPreview.UIDPreview.as_view()), re_path(r'^sysmsg/(?P.*)$', SysMsg.SysMsgView.as_view()), re_path(r'^sysfile/(?P.*)$', SysManage.getStatView.as_view()), re_path(r'^equipment/flowUpdate', EquipmentManager.update_uid_set), re_path(r'^log/getUploadUrl', EquipmentStatus.getUploadLogUrl), re_path(r'^app/getIdData', AppInfo.AppIdDataView.as_view()), re_path(r'^wechat/authsign', UserController.wxAuthSignView.as_view()), re_path(r'^wechat/perfect', UserController.wxPerfectView.as_view()), re_path(r'^Test', Test.Test.as_view()), re_path(r'^oauth/authcode', UserController.OauthAuthCodeView.as_view()), re_path(r'^oauth/perfect', UserController.OauthPerfectView.as_view()), re_path(r'^oauth/unbunding', UserController.UnbundingWXView.as_view()), re_path(r'^equipment/judge', EquipmentManager.judgeInterface), re_path(r'^uiduser/add', UidUser.addInterface), re_path(r'^uiduser/query', UidUser.queryInterface), re_path(r'^uiduser/update', UidUser.updateInterface), re_path(r'^uiduser/delete', UidUser.deleteInterface), re_path(r'^uid_user/(?P.*)$', UidUser.UidUserView.as_view()), re_path(r'^v2/equipment/(?P.*)$', EquipmentManagerV2.EquipmentManagerV2.as_view()), re_path(r'^msg/init', SysManage.initMsgFunc), re_path(r'^oss_crd/(?P.*)$', OssCrd.OssCrdView.as_view()), re_path(r'^push_deploy/(?P.*)$', PushDeploy.PushDeployView.as_view()), re_path(r'^oalexa/auth', UserController.alexaAuthView.as_view()), re_path(r'^oalexa/discoveryuid', UserController.alexaUidView.as_view()), re_path(r'^oalexa/discoveryswitch', UserController.alexaSwitchView.as_view()), re_path('appset/(?P.*)', AppSetController.AppSetView.as_view()), re_path(r'^application/(?P.*)$', ApplicationController.ApplicationView.as_view()), re_path(r'^login/oauth/(?P.*)$', ApplicationController.AuthView.as_view()), re_path(r'^grant/code/(?P.*)$', ApplicationController.GrantCodeView.as_view()), re_path(r'^user/ex/(?P.*)$', UserExController.UserExView.as_view()), re_path(r'^v3/equipment/(?P.*)$', EquipmentManagerV3.EquipmentManagerV3.as_view()), re_path(r'^cloudstorage/(?P.*)$', CloudStorage.CloudStorageView.as_view()), re_path(r'^payCycle/(?P.*)$', PaymentCycle.PaypalCycleNotify.as_view()), re_path(r'^paypalCycleNotify/(?P.*)$', PaymentCycle.PaypalCycleNotify.as_view()), re_path(r'^paymentCycle/(?P.*)$', PaymentCycle.payCycle.as_view()), re_path(r'^AiService/(?P.*)$', AiController.AiView.as_view()), re_path(r'^app/setting/notification/(?P.*)$', EquipmentMessagePush.EquipmentMessagePushView.as_view()), re_path(r'^v3/account/changePwd$', UserController.v3ChangePwdView.as_view()), re_path(r'^v3/account/resetPwdByCode$', UserController.v3resetPwdByCodeView.as_view()), re_path(r'^v3/account/register$', UserController.v3registerView.as_view()), re_path(r'^v3/uiduser/add', UidUser.v3addInterface), re_path(r'^v3/uiduser/query', UidUser.v3queryInterface), re_path(r'^date/(?P.*)$', DateController.DateConView.as_view()), re_path(r'^equipment/flow_test$', EquipmentManager.uid_status_test), re_path(r'^account/appFrequency/(?P.*)$', UserController.UserAppFrequencyView.as_view()), re_path(r'^v2/userbrand/(?P.*)$', UserBrandControllerV2.UserBrandV2.as_view()), re_path(r'^statistcs/appFrequencyMonth$', StatisticsController.statistcsAppFrequency), re_path(r'^statistcs/appFrequencyYear$', StatisticsController.statistcsAppFrequencyYear), re_path(r'^statistcs/pushDay$', StatisticsController.statistcsPushDay), re_path(r'^statistcs/pushMonth$', StatisticsController.statistcsPushMonth), re_path(r'^alexa/(?P.*)$', Alexa.AlexaConnectNum.as_view()), re_path(r'^faq/upload', FAQController.FAQUploadView.as_view()), re_path(r'^faq/image/(?P.*)$', FAQController.getFAQImage.as_view()), re_path(r'^faq/(?P.*)$', FAQController.FAQView.as_view()), re_path(r'^ios/authsign', UserController.AppleAuthLogin.as_view()), re_path(r'^appLog/(?P.*)$', AppLogController.AppLogView.as_view()), re_path(r'deviceLog/(?P.*)$', DeviceLogController.DeviceLogView.as_view()), re_path(r'^local/(?P.*)$', UserController.LocalUserView.as_view()), re_path(r'^account/updateUserCountry', UserController.updateUserCountry), re_path(r'^equipmentVersionLimit/(?P.*)$', EquipmentVersionLimit.EquipmentVersionLimitView.as_view()), re_path(r'^account/subscribe$', UserController.SubscribeEmailView.as_view()), re_path(r'^account/subscribe/download$', UserController.SubscribeEmailView.as_view()), re_path(r'^voicePrompt/(?P.*)$', VoicePromptController.VoicePromptView.as_view()), re_path(r'^deviceType/(?P.*)$', DeviceTypeController.DeviceTypeView.as_view()), re_path(r'^cdk/(?P.*)$', CDKController.CDKView.as_view()), re_path(r'^cloudTransfer/(?P.*)$', CloudTransfer.cloudTestView.as_view()), re_path(r'^coupon/(?P.*)$', CouponController.CouponView.as_view()), re_path(r'^Cloudsum/(?P.*)$', Cloudsum.Cloudsum.as_view()), re_path(r'^device/StatisticsIpRegion$', DeviceConfirmRegion.StatisticsIpRegion.as_view()), re_path('iot/(?P.*)', IotCoreController.IotCoreView.as_view()), re_path(r's3_getsts/(?P.*)$', S3GetStsController.S3GetStsView.as_view()), re_path('admin/', admin.site.urls), re_path('user/(?P.*)', UIDManageUserController.UserView.as_view()), re_path('uid/(?P.*)', UIDController.UIDView.as_view()), re_path('history/(?P.*)', HistoryUIDController.HistoryUIDView.as_view()), re_path('^log/(?P.*)', LogController.LogView.as_view()), re_path('orderTask/(?P.*)', OrderTaskController.OrderTaskView.as_view()), re_path('^upload', FileController.UploadUIDFileView.as_view()), re_path('^download', FileController.DownloadUIDFileView.as_view()), re_path('^sales', SalesController.SalesView.as_view()), re_path('device/online', SalesController.DeviceOnlineView.as_view()), re_path('serialNumber/(?P.*)', SerialNumberController.SerialNumberView.as_view()), re_path('deviceShadow/updateV2', ShadowController.update_device_shadow), re_path('company/(?P.*)', CompanyController.CompanyView.as_view()), re_path('region/(?P.*)', RegionController.RegionView.as_view()), re_path('vpg/(?P.*)', VPGController.VPGView.as_view()), re_path('vpgUid/uid', VPGController.do_upload_uid), re_path('language/(?P.*)', LanguageController.LanguageView.as_view()), re_path('test/(?P.*)', TestController.TestView.as_view()), re_path(r'^OperatingLogs/(?P.*)$', OperatingLogs.OperatingLogsView.as_view()), re_path(r'^ProcessInfo/(?P.*)$', ProcessInfo.ProcessInfoView.as_view()), re_path(r'^Cloudsum/(?P.*)$', Cloudsum.Cloudsum.as_view()), re_path(r'regionCountry/(?P.*$)', RegionCountryController.RegionCountryView.as_view()), re_path(r'verifyCode/(?P.*$)', VerifyCodeController.VerifyCodeView.as_view()), re_path(r'^device/confirmRegion$', DeviceConfirmRegion.ConfirmRegion.as_view()), re_path(r'^device/confirmRegionV2$', DeviceConfirmRegion.ConfirmRegionV2.as_view()), re_path(r'^device/confirmCountry$', DeviceConfirmRegion.confirm_country_with_ip), re_path(r'^pcInfo/(?P.*)$', PcInfo.PcInfo.as_view()), re_path(r'^pcTest/(?P.*)$', PctestController.PcTest.as_view()), re_path('deviceDebug/(?P.*)', DeviceDebug.DeviceDebug.as_view()), re_path(r'^api/surveys/(?P.*)$', CloudStorageController.CloudStorageView.as_view()), re_path(r'^api/device/share/(?P.*)$', UserDeviceShareController.UserDeviceShareView.as_view()), re_path(r'^app/sensor/gateway/(?P.*)$', EquipmentFamilyController.EquipmentFamilyView.as_view()), re_path(r'^loocam/', include("Ansjer.server_urls.loocam_url")), re_path(r'^api/loocam/', include("Ansjer.server_urls.loocam_url")), re_path(r'^unicom/', include("Ansjer.server_urls.unicom_url")), re_path(r'^algorithm-shop/', include("Ansjer.server_urls.algorithm_shop_url")), re_path(r'^api/algorithm/', include("Ansjer.server_urls.algorithm_shop_url")), re_path(r'^kvs/', include("Ansjer.server_urls.kvs_url")), re_path(r'^icloud/', include("Ansjer.server_urls.icloud_url")), re_path('appAccout/(?P.*)', AppAccountManagement.AppAccoutView.as_view()), re_path('sensorGateway/(?P.*)', SensorGatewayController.SensorGateway.as_view()), re_path(r'^api/surveys/(?P.*)$', CloudStorageController.CloudStorageView.as_view()), re_path(r'^api/device/share/(?P.*)$', UserDeviceShareController.UserDeviceShareView.as_view()), re_path(r'^server/(?P[a-zA-Z0-9]+)/open/detect/(?P.*)$', DetectControllerV2.DetectControllerViewV2.as_view()), # 后台界面接口 ------------------------------------------------------------------------------------------------------- # 登录,用户信息,权限 re_path(r'^login$', UserManageController.LoginView.as_view()), re_path(r'^noPasslogin$', UserManageController.LoginView.as_view()), re_path(r'^userInfo$', UserManageController.GetPermissions.as_view()), re_path(r'^router/getList$', UserManageController.GetList.as_view()), # 角色管理 re_path('roleManagement/(?P.*)', RoleController.RoleView.as_view()), # 菜单管理 re_path('menuManagement/(?P.*)', MenuController.MenuView.as_view()), # 用户管理 re_path('userManagement/(?P.*)', UserManageController.UserManagement.as_view()), # 设备管理 re_path('deviceManagement/(?P.*)', DeviceManagementController.DeviceManagement.as_view()), # 版本管理 re_path('versionManagement/(?P.*)', VersionManagementController.VersionManagement.as_view()), # 服务管理 re_path('serveManagement/(?P.*)', ServeManagementController.serveManagement.as_view()), # 测试服务 re_path('testServe/(?P.*)', TestServeController.TestServeView.as_view()), # 日志管理 re_path('logManagement/(?P.*)', LogManagementController.LogManagementView.as_view()), # AI服务 re_path('aiServe/(?P.*)', AiServeController.AiServeView.as_view()), # 问卷调查管理 re_path(r'surveys/(?P.*)', SurveysManageController.SurveysView.as_view()), # 序列号管理 re_path(r'serial/(?P.*)', SerialManageController.SerialView.as_view()), # 数据系统模块 re_path(r'^dataManagement/', include("Ansjer.server_urls.datasystem_url")), # 数据系统模块 re_path(r'^icloudserve/(?P.*)', IcloudManagementController.IcloudServeView.as_view()), # 后台界面接口 ------------------------------------------------------------------------------------------------------- # 定时任务接口 re_path(r'^cron/del/(?P.*)', CronTaskController.CronDelDataView.as_view()), re_path(r'^cron/update/(?P.*)', CronTaskController.CronUpdateDataView.as_view()), re_path(r'^cron/collect/(?P.*)', CronTaskController.CronCollectDataView.as_view()), # 国内域名备案网站/错误路径 re_path('(?P.*)', LogManager.errorPath), ]