from django.views.decorators.http import require_http_methods

from backend.Service.KbmService import KbmService

#查询所有bucket信息
@require_http_methods(['POST'])
def selectBucketInfo(request):
    return KbmService.selectBucketInfo(request)

#获取bucket内信息
@require_http_methods(['POST'])
def getFileInfo(request):
    return KbmService.getFileInfo(request)

#修改名称
@require_http_methods(['POST'])
def updateName(request):
    return KbmService.updateName(request)
#逻辑删除
@require_http_methods(['POST'])
def deleteDocument(request):
    return KbmService.deleteDocument(request)

#获取文件的url
@require_http_methods(['POST'])
def getUrl(request):
    return KbmService.getUrl(request)
#分片文件
@require_http_methods(['POST'])
def analysis(request):
    return KbmService.analysis(request)

@require_http_methods(['POST'])
def searchTaskInfo(request):
    return KbmService.searchTaskInfo(request)

@require_http_methods(['POST'])
def deleteBucket(request):
    return KbmService.deleteBucket(request)

@require_http_methods(['POST'])
def getRunStatus(request):
    return KbmService.getRunStatus(request)

@require_http_methods(['POST'])
def batchAnalysis(request):
    return KbmService.batchAnalysis(request)

@require_http_methods(['POST'])
def getSuffixName(request):
    return KbmService.getSuffixName(request)


@require_http_methods(['POST'])
def batchMove(request):
    return KbmService.batchMove(request)

@require_http_methods(['POST'])
def updateKbm(request):
    return KbmService.updateKbm(request)