コード例 #1
0
        private async void btnGetEnpointsCommands_ClickAsync(object sender, EventArgs e)
        {
            Initialize();

            APIEndpointCommandRequestModels.GetEndpointCommandsList model = new APIEndpointCommandRequestModels.GetEndpointCommandsList();
            model.LoadEndpoint = true;

            model.PageNumber = 1; model.PageSize = 1; model.Token = Guid.Parse(txtToken.Text);

            APIEndpointCommandResponseModels.GetEndpointCommandsList cmds = await uow.EndPointCommandsService.GetEndPointsListAsync(model);

            gv1.DataSource = cmds.EndpointCommands;
        }
コード例 #2
0
        public async Task <APIEndpointCommandResponseModels.GetEndpointCommandsList> GetEndPointsListAsync(APIEndpointCommandRequestModels.GetEndpointCommandsList rm)
        {
            string strResult = await HttpPost("/api/EndPointCommands/GetEndPointCommandsList", JsonConvert.SerializeObject(rm));

            APIEndpointCommandResponseModels.GetEndpointCommandsList result = (APIEndpointCommandResponseModels.GetEndpointCommandsList)JsonConvert.DeserializeObject(strResult, typeof(APIEndpointCommandResponseModels.GetEndpointCommandsList));
            return(result);
        }