package com.bc_chat.circle.dataSource

import com.bc_chat.bc_base.entity.contact.UserCircleDetailModel
import com.bc_chat.bc_base.http.Encryption
import com.bc_chat.bc_base.http.RetrofitHelper
import com.zhaohaoting.framework.abs.datasource.RxDataSource
import com.zhaohaoting.framework.abs.entity.ResultEntity
import io.reactivex.Flowable
import java.util.*

/**
 * author：Created by zhaohaoting on 2019/2/27
 * email：526309416@qq.com
 * desc：
 */
class UserCircleDataSource(val cuid: String) : RxDataSource<UserCircleDetailModel.Topic, UserCircleDetailModel>() {

    override fun loadListFromNetWork(params: HashMap<String, Any?>): Flowable<ResultEntity<UserCircleDetailModel>> {
        params.put("cuid", cuid)
        return RetrofitHelper.api.getUserCircle(Encryption.encryption(params))
    }
}
