public IHttpActionResult TestPush()
        {
            var curTime               = UnixTime.UtcNow();
            var currDatetime          = UnixTime.GetDateFromTimeStamp(curTime);
            var startRegistrationTime = _confederationService.StartRegistrationTime;
            var startVoteTime         = _confederationService.StartVoteTime;
            var endVoteTime           = _confederationService.EndVoteTime;

            var candidates      = _confederationService.GetCandidates(false);
            var candidatesCount = candidates.Count;

            var isVotePeriod = _confederationService.VotingInProgress;
            var periodName   = isVotePeriod ? "IsVotePeriod" : "isRegisterdPeriod";
            //todo  logic toggle
            var timeToNextUpgrage = isVotePeriod ? endVoteTime - curTime : startVoteTime - curTime;
            var activeOfficers    = new List <IOfficerOut>();

            try
            {
                activeOfficers = _confederationService.GetOfficers(true);
            }
            catch
            {
                // ignored
            }
            var activeOfficersCount = activeOfficers?.Count ?? 0;

            return(Json(new
            {
                periodName,
                timeToNextUpgrage,
                curTime = UnixTime.ConvertSecondToFormat(curTime, UnixTime.Format_dd_hh_mm),
                startRegistrationTime = UnixTime.ConvertSecondToFormat(startRegistrationTime, UnixTime.Format_dd_hh_mm),
                startVoteTime = UnixTime.ConvertSecondToFormat(startVoteTime, UnixTime.Format_dd_hh_mm),
                endVoteTime = UnixTime.ConvertSecondToFormat(endVoteTime, UnixTime.Format_dd_hh_mm),
                candidatesCount,
                activeOfficersCount
            }));
        }
 public void SetTime(int second)
 {
     Sec             = second;
     FormatedSeconds = UnixTime.ConvertSecondToFormat(second, UnixTime.Format_hh_mm_ss);
 }