const prefix = '/api/channel'

const apis = {
  user: {
    current: {
      url: `${prefix}/current`,
      method: 'GET',
      action: 'channel',
    },
    login: {
      url: `${prefix}/signin`,
      method: 'POST',
      action: 'channel',
      login: true
    },
    logoff: {
      url: `${prefix}/signout`,
      method: 'POST',
      action: 'channel',
      logout: true
    },
  },
  member: {
    list: {
      url: `${prefix}/taUser`,
      method: 'GET',
      action: 'channel',
    },
    get: {
      url: `${prefix}/taUser/:id`,
      method: 'GET',
      action: 'channel',
    },
    save: {
      url: `${prefix}/taUser`,
      method: 'POST',
      action: 'channel',
    },
    update: {
      url: `${prefix}/taUser/:id`,
      method: 'PUT',
      action: 'channel',
    },
  },
  channel: {
    list: {
      url: `${prefix}/taChannel`,
      method: 'GET',
      action: 'channel',
    },
    put: {
      url: `${prefix}/taChannel/:id`,
      method: 'PUT',
      action: 'channel',
    },
    post: {
      url: `${prefix}/taChannel`,
      method: 'POST',
      action: 'channel',
    },
    get: {
      url: `${prefix}/taChannel/:id`,
      method: 'GET',
      action: 'channel',
    },
  },
  sample: {
    list: {
      url: `${prefix}/taH5Demand`,
      method: 'GET',
      action: 'channel',
    },
    put: {
      url: `${prefix}/taH5Demand/batch`,
      method: 'PUT',
      action: 'channel',
    },
    get: {
      url: `${prefix}/taH5Demand/:id`,
      method: 'GET',
      action: 'channel',
    },
    update: {
      url: `${prefix}/taH5Demand/update/:id`,
      method: 'PUT',
      action: 'channel',
    },
    h5list: {
      url: `${prefix}/h5Sample/list`,
      method: 'GET',
      action: 'channel',
    },
    addh5: {
      url: `${prefix}/h5Sample/add`,
      method: 'POST',
      action: 'channel',
    },
    geth5: {
      url: `${prefix}/get/h5Sample/:id`,
      method: 'GET',
      action: 'channel',
    },
    updateh5: {
      url: `${prefix}/update/h5Sample/:id`,
      method: 'PUT',
      action: 'channel',
    },
    puth5: {
      url: `${prefix}/put/h5Sample/:id`,
      method: 'PUT',
      action: 'channel',
    },
    h5Template: {
      url: `${prefix}/taH5Template`,
      method: 'GET',
      action: 'channel',
    },
  },
  image: {
    uploadForAnt: {
      url: `${prefix}/antd/image`,
      method: 'POST',
      action: 'channel',
    },
    upload: {
      url: `${prefix}/image`,
      method: 'POST',
      action: 'channel',
    },
  },
  openScreen: {
    list: {
      url: `${prefix}/listNoticeByCondition`,
      method: 'GET',
      action: 'channel',
    },
    post: {
      url: `${prefix}/taNotice`,
      method: 'post',
      action: 'channel',
    },
    // /api/admin/taNotice/{id}
    put: {
      url: `${prefix}/taNotice/:id`,
      method: 'put',
      action: 'channel',
    },


    get: {
      url: `${prefix}/taNotice/:id`,
      method: 'GET',
      action: 'channel',
    },
    delete: {
      url: `${prefix}/taNotice/batchDelete`,
      method: 'put',
      action: 'channel',
    },
    getSample: {
      url: `${prefix}/listH5SampleByCondition`,
      method: 'GET',
      action: 'channel',
    }
    // /api/admin/ListH5SampleByCondition
  },

  contact: {
    listContactByCondition: {
      url: `${prefix}/listContactByCondition`,
      method: 'GET',
      action: 'channel',
    },
    taContactAdd: {
      url: `${prefix}/taContact`,
      method: 'POST',
      action: 'channel',
    },
    batchDeleteContact: {
      url: `${prefix}/taContact/batchDelete`,
      method: 'PUT',
      action: 'channel',
    },
    taContactGet: {
      url: `${prefix}/taContact/:id`,
      method: 'GET',
      action: 'channel',
    },
    taContactUpdate: {
      url: `${prefix}/taContact/:id`,
      method: 'PUT',
      action: 'channel',
    },
    list: {
      url: `${prefix}/taContact`,
      method: 'GET',
      action: 'channel',
    },
  },
  fund: {
    account: {
      url: `${prefix}/taOrgAccount`,
      method: 'GET',
      action: 'channel',
    },
    accountDetail: {
      url: `${prefix}/taOrgAccount/:id`,
      method: 'GET',
      action: 'channel',
    },
    taOrgOrder: {
      url: `${prefix}/taOrgOrder`,
      method: 'GET',
      action: 'channel',
    },
    refund: {
      url: `${prefix}/taOrgOrder/refund/:id`,
      method: 'PUT',
      action: 'channel',
    },
    reject: {
      url: `${prefix}/taOrgOrder/reject/:id`,
      method: 'PUT',
      action: 'channel',
    },
    receiveInfo: {
      url: `${prefix}/receiveInfo`,
      method: 'GET',
      action: 'channel',
    },
    recharge: {
      url: `${prefix}/taOrgAccount/recharge/:id`,
      method: 'PUT',
      action: 'channel',
    },
    accoutRefund: {
      url: `${prefix}/taOrgAccount/refund/:id`,
      method: 'PUT',
      action: 'channel',
    },
    addContact: {
      url: `${prefix}/taContactFinance/:id`,
      method: 'PUT',
      action: 'channel',
    },
    delContact: {
      url: `${prefix}/taContactFinanceDel`,
      method: 'PUT',
      action: 'channel',
    },
    contactList: {
      url: `${prefix}/listContactByCondition`,
      method: 'GET',
      action: 'channel',
    },
    rechargeOrderExport: {
      url: `${prefix}/taOrgOrder/rechargeOrderExport`,
      method: 'GET',
      action: 'channel',
    },
    consumeOrderExport: {
      url: `${prefix}/taOrgOrder/consumeOrderExport`,
      method: 'GET',
      action: 'channel',
    },
    refundOrderExport: {
      url: `${prefix}/taOrgOrder/refundOrderExport`,
      method: 'GET',
      action: 'channel',
    },
    accountExport: {
      url: `${prefix}/taOrgAccount/taOrgAccountListExport`,
      method: 'GET',
      action: 'channel',
    },
  },
  relatedOrganization: {
    get: {
      url: `${prefix}/contract/listCompanyOrg`,
      method: 'GET',
      action: 'channel',
    },
    listCompany: {
      url: `${prefix}/contract/listCompany`,
      method: 'GET',
      action: 'channel',
    },
    listOrg: {
      url: `${prefix}/contract/listOrg`,
      method: 'GET',
      action: 'channel',
    },
    post: {
      url: `${prefix}/contract/taCompanyOrg`,
      method: 'post',
      action: 'channel',
    },
    delete: {
      url: `${prefix}/taCompanyOrg/:id`,
      method: 'delete',
      action: 'channel',

    },

  },
  signedContract: {
    get: {
      url: `${prefix}/contract/list`,
      method: 'GET',
      action: 'channel',
    },
    check: {
      url: `${prefix}/contract/checkBeforeBatchUpdatePrice`,
      method: 'post',
      action: 'channel',
    },
    put: {
      url: `${prefix}/contract/batchUpdatePrice`,
      method: 'put',
      action: 'channel',
    },
  },

  company: {
    list: {
      url: `${prefix}/company/list`,
      method: 'GET',
      action: 'channel',
    },
    add: {
      url: `${prefix}/company/add`,
      method: 'POST',
      action: 'channel',
    },
    get: {
      url: `${prefix}/company/:id`,
      method: 'GET',
      action: 'channel',
    },
    update: {
      url: `${prefix}/company/:id`,
      method: 'PUT',
      action: 'channel',
    },
    companyById: {
      url: `${prefix}/taCompany/:id`,
      method: 'GET',
      action: 'channel',
    },
    autoAuthSeal: {
      url: `${prefix}/company/autoAuthCompany/:id`,
      method: 'PUT',
      action: 'channel',
    },
    getAuthStatus: {
      url: `${prefix}/company/getAuthStatus/:id`,
      method: 'GET',
      action: 'channel',
    },
    taCompanyList: {
      url: `${prefix}/taCompanyList`,
      method: 'GET',
      action: 'channel',
    },
    refresh: {
      url: `${prefix}/company/fdd/:id`,
      method: 'GET',
      action: 'channel',
    },
    delete: {
      url: `${prefix}/company/delete`,
      method: 'DELETE',
      action: 'channel',
    }
  },

  seal: {
    listByCompanyId: {
      url: `${prefix}/taCompanySeal`,
      method: 'GET',
      action: 'channel',
    },
    addSeal: {
      url: `${prefix}/taCompanySeal`,
      method: 'POST',
      action: 'channel',
    },
    taSealById: {
      url: `${prefix}/taCompanySeal/:id`,
      method: 'GET',
      action: 'channel',
    },
    updateSealById: {
      url: `${prefix}/taCompanySeal/:id`,
      method: 'PUT',
      action: 'channel',
    },
    delSealById: {
      url: `${prefix}/deleteCompanySeal/:id`,
      method: 'PUT',
      action: 'channel',
    },
    refresh: {
      url: `${prefix}/company/fdd/:id`,
      method: 'GET',
      action: 'channel',
    },
    delete: {
      url: `${prefix}/company/delete`,
      method: 'DELETE',
      action: 'channel',
    },
    setDefaultSealById: {
      url: `${prefix}/company/setDefaultSeal/:id`,
      method: 'POST',
      action: 'channel',
    }
  },
  officenews: {
    list: {
      url: `${prefix}/taOfficeNews`,
      method: 'GET',
      action: 'channel',
    },
    get: {
      url: `${prefix}/taOfficeNews/:id`,
      method: 'GET',
      action: 'channel',
    },
    update: {
      url: `${prefix}/taOfficeNews/:id`,
      method: 'PUT',
      action: 'channel',
    },
    save: {
      url: `${prefix}/taOfficeNews`,
      method: 'POST',
      action: 'channel',
    },
  },
  promote: {
    list: {
      url: `${prefix}/taOfficeContact`,
      method: 'GET',
      action: 'channel',
    },
    update: {
      url: `${prefix}/taOfficeContact/:id`,
      method: 'PUT',
      action: 'channel',
    },
  },
}

export default apis;
