Exemple #1
0
        public async Task <MessageListApiModel> PostAsync([FromBody] QueryApiModel body)
        {
            string[] deviceIds = body.Devices == null
                ? new string[0]
                : body.Devices.ToArray();

            return(await this.ListMessagesHelper(body.From, body.To, body.Order, body.Skip, body.Limit, deviceIds));
        }
        public AlarmListApiModel Post([FromBody] QueryApiModel body)
        {
            string[] deviceIds = body.Devices == null
                ? new string[0]
                : body.Devices.ToArray();

            return(this.ListHelper(
                       body.From,
                       body.To,
                       body.Order,
                       body.Skip,
                       body.Limit,
                       deviceIds));
        }
Exemple #3
0
        public async Task <AlarmListByRuleApiModel> Post(
            [FromRoute] string id,
            [FromBody] QueryApiModel body)
        {
            string[] deviceIds = body.Devices == null
                ? new string[0]
                : body.Devices.ToArray();

            return(await this.GetAlarmListByRuleHelper(
                       id,
                       body.From,
                       body.To,
                       body.Order,
                       body.Skip,
                       body.Limit,
                       deviceIds));
        }