public async Task <List <_Tablename_DTO> > Handle(_Tablename_GetManyQuery request, CancellationToken cancellationToken)
        {
            ParamCommAnd paramCommAnd = new ParamCommAnd();

            paramCommAnd.Add("id", request.ids, "in");

            string where; Dictionary <string, object> param;
            paramCommAnd.CreateWhere(out where, out param);

            var items = await _Tablename_.GetModelList(where, param).GetList();

            return(this.mapper.Map <List <_Tablename_DTO> >(items));
        }
        public async Task <_Tablename_GetListQueryDTO> Handle(_Tablename_GetListQuery request, CancellationToken cancellationToken)
        {
            ParamCommAnd paramCommAnd = new ParamCommAnd();

            if (request.id != null)
            {
                paramCommAnd.Add("id", request.id);
            }

            string where; Dictionary <string, object> param;
            paramCommAnd.CreateWhere(out where, out param);

            PagerEx <_Tablename_> pager = _Tablename_.Pager(where, param, request._page, request._pagesize, request._sort, request._order);
            var list = await pager.GetDataList();

            return(new _Tablename_GetListQueryDTO()
            {
                data = this.mapper.Map <List <_Tablename_DTO> >(list), total = pager.RecordCount
            });
        }