import httpClient from '@/services/http'
import { CommonFetchOptions } from '@/services/http/types'

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->新增、修改
 */
export function profitShareDeal(options: CommonFetchOptions<{ request: Model.ProfitShareDealReq; }>) {
    return httpClient.commonRequest('/profitShar/deal', 'post', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->删除
 */
export function profitShareDelete(options: CommonFetchOptions<{ request: Model.ProfitShareDeleteReq; }>) {
    return httpClient.commonRequest('/profitShar/delete', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->会员列表-->删除
 */
export function profitShareDeleteMember(options: CommonFetchOptions<{ request: Model.ProfitShareDeleteMemberReq; }>) {
    return httpClient.commonRequest('/profitShar/deleteMember', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分润配置-->删除
 */
export function profitShareDeleteSOrganSec(options: CommonFetchOptions<{ request: Model.ProfitShareDeleteSOrganSecReq; }>) {
    return httpClient.commonRequest('/profitShar/deleteSOrganSec', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分润配置-->新增、修改
 */
export function profitShareDelSOrganSec(options: CommonFetchOptions<{ request: Model.ProfitShareDelSOrganSecReq; }>) {
    return httpClient.commonRequest('/profitShar/delSOrganSec', 'post', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->会员列表-->机构获取
 */
export function profitShareGroupOrgan(options: CommonFetchOptions<{ response: Model.ProfitShareGroupOrganRsp[]; }>) {
    return httpClient.commonRequest('/profitShar/groupOrgan', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分润配置-->获取所有已配置信息
 */
export function initProfitShare(options: CommonFetchOptions<{ response: Model.InitProfitShareRsp; }>) {
    return httpClient.commonRequest('/profitShar/initProfitShar', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->会员列表-->新增
 */
export function profitShareMemberAdd(options: CommonFetchOptions<{ request: Model.ProfitShareMemberAddReq; }>) {
    return httpClient.commonRequest('/profitShar/memberAdd', 'post', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->会员列表
 */
export function profitShareMemberQuery(options: CommonFetchOptions<{ request: Model.ProfitShareMemberQueryReq; response: Model.ProfitShareMemberQueryRsp[]; }>) {
    return httpClient.commonRequest('/profitShar/memberQuery', 'get', options)
}

/**
 * 分润管理-->机构分润配置-->子机构分组管理-->获取列表
 */
export function profitShareQueryPage(options: CommonFetchOptions<{ request: Model.ProfitShareQueryPageReq; response: Model.ProfitShareQueryPageRsp[]; }>) {
    return httpClient.commonRequest('/profitShar/queryPage', 'get', options)
}