using MadRunFabric.Model;
using MadRunFabric.Common;
using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace EquipmentApi.IRepositories
{
    public interface IWo_Repair_BaseRepository : IRepository<Wo_Repair_Base, string>
    {
        /// <summary>
        /// 根据多个条件查询列表 Linq 关联查询
        /// </summary>
        /// <param name="phone">电话</param>
        /// <param name="provinceid">省</param>
        /// <param name="cityid">市</param>
        /// <param name="protypeid">项目类型id</param>
        /// <param name="projectid">项目名称id</param>
        /// <param name="replace">报修地点</param>
        /// <param name="serviceman">维修人</param>
        /// <param name="sysnameid">系统名称id</param>
        /// <param name="equipmentid">设备名称id</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="createuser">创建人</param>
        /// <param name="daytype">日期类型</param>
        /// <param name="state">工单状态</param>
        /// <param name="stime"></param>
        /// <param name="etime"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="recordCount"></param>
        /// <returns></returns>
        IEnumerable<object> GetListsByPage(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
            string replace, string systemid, string equipmentid, string usercode, string stime, string etime,string channel,string Jwocode, int state, int wxstate,
            string nowusercode, UserAccountInfoModel userinfo, 
            //string nowrolecode,
            int pageindex, int pagesize, out int recordcount, 
            out int totalcount, out int wzpcount,  out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);

        IEnumerable<object> GetListsByPageglhsz(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
        string replace, string systemid, string equipmentid, string usercode, string stime, string etime, string channel, string Jwocode, int state, int wxstate,
        string nowusercode, UserAccountInfoModel userinfo,
        //string nowrolecode,
        int pageindex, int pagesize, out int recordcount,
        out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);

        IEnumerable<object> excelwocodelhsz(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
       string replace, string systemid, string equipmentid, string usercode, string stime, string etime, string channel, string Jwocode, int state, int wxstate,
       string nowusercode, UserAccountInfoModel userinfo,
       //string nowrolecode,
       int pageindex, int pagesize, out int recordcount,
       out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);

        IEnumerable<object> GetListsByPagerolebz(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
         string replace, string systemid, string equipmentid, string usercode, string stime, string etime, int state, int wxstate,
         string nowusercode, UserAccountInfoModel userinfo,
         //string nowrolecode,
         int pageindex, int pagesize, string rolename, out int recordcount,
         out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);

        IEnumerable<object> GetListsByPagerole(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
           string replace, string systemid, string equipmentid, string usercode, string stime, string etime, int state, int wxstate,
           string nowusercode, UserAccountInfoModel userinfo,
           //string nowrolecode,
           int pageindex, int pagesize,string rolename, out int recordcount,
           out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);
        

        /// <summary>
        /// 根据多个条件查询列表 Linq 关联查询
        /// </summary>
        /// <param name="phone">电话</param>
        /// <param name="provinceid">省</param>
        /// <param name="cityid">市</param>
        /// <param name="protypeid">项目类型id</param>
        /// <param name="projectid">项目名称id</param>
        /// <param name="replace">报修地点</param>
        /// <param name="serviceman">维修人</param>
        /// <param name="sysnameid">系统名称id</param>
        /// <param name="equipmentid">设备名称id</param>
        /// <param name="wocode">工单编号</param>
        /// <param name="createuser">创建人</param>
        /// <param name="daytype">日期类型</param>
        /// <param name="state">工单状态</param>
        /// <param name="stime"></param>
        /// <param name="etime"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="recordCount"></param>
        /// <returns></returns>
        IEnumerable<object> GetAppListsByPage(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
            string replace, string systemid, string equipmentid, string usercode, string stime, string etime, int state, 
            string nowusercode, UserAccountInfoModel userinfo,
            //string nowrolecode,
            int pageindex, int pagesize, out int recordcount,
            out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);
        IEnumerable<object> GetAppListsByPagemy(string phone, string wocode, string province, string city, string projectid, string protypeid, string buildid, string floorid,
          string replace, string username, string systemid, string equipmentid, string usercode, string stime, string etime, int state,
          string nowusercode, UserAccountInfoModel userinfo,
          //string nowrolecode,
          int pageindex, int pagesize, out int recordcount,
          out int totalcount, out int wzpcount, out int yjdcount, out int dpjcount, out int ygqcount, out int ywjcount, out int yqxcount);
        /// <summary>
        /// 获取维修工单详情 by id
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        object GetDetails(string id);

        /// <summary>
        /// 获取项目信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        object GetProjectInfo(string id);

        /// <summary>
        /// 获取维修工接单限制数量
        /// </summary>
        /// <param name="usercode"></param>
        /// <returns></returns>
        int GetLimitCount(string usercode);

        /// <summary>
        /// 获取评价规定时间间隔
        /// </summary>
        /// <returns></returns>
        int GetEvaluateHour();

        /// <summary>
        /// 获取维修工
        /// </summary>
        /// <param name="wocode"></param>
        /// <returns></returns>
        object GetRepairUser(string wocode,string  role_name);

        /// <summary>
        /// 获取协助维修工
        /// </summary>
        /// <param name="usercode"></param>
        /// <returns></returns>
        object GetAssistRepairUser(string projectid,string usercode, int isxyzg);

    }
}
