PUT api/TimeSheet/User

Редактирование табеля пользователя за указанную дату или интервал дат

Request Information

URI Parameters

None.

Body Parameters

TimeSheetPeriodRowViewModel
NameDescriptionTypeAdditional information
UserId

Идентифкатор пользователя

integer

None.

DateStart

Дата старта даты

date

None.

DateEnd

Дата окончания даты

date

Элемент является необязательным при сохранении

TimeBegin

Начало рабочего дня в минутах

integer

Элемент является необязательным при сохранении

TimeEnd

Окончание рабочего дня в минутах

integer

Элемент является необязательным при сохранении

TimeSheetDayType

Тип периода

TimeSheetDayType

None.

Request Formats

application/json, text/json

Sample:
{
  "UserId": 1,
  "DateStart": "2022-08-17T04:50:35+03:00",
  "DateEnd": "2022-08-17T04:50:35+03:00",
  "TimeBegin": 1,
  "TimeEnd": 1,
  "TimeSheetDayType": 1
}

text/html, multipart/form-data

Sample:
{"UserId":1,"DateStart":"2022-08-17T04:50:35+03:00","DateEnd":"2022-08-17T04:50:35+03:00","TimeBegin":1,"TimeEnd":1,"TimeSheetDayType":1}

application/xml, text/xml

Sample:
<TimeSheetPeriodRowViewModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AGAT.TSSM.API.Models.TimeSheet">
  <DateEnd>2022-08-17T04:50:35.9807029+03:00</DateEnd>
  <DateStart>2022-08-17T04:50:35.9807029+03:00</DateStart>
  <TimeBegin>1</TimeBegin>
  <TimeEnd>1</TimeEnd>
  <TimeSheetDayType>Holiday</TimeSheetDayType>
  <UserId>1</UserId>
</TimeSheetPeriodRowViewModel>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Success Resource Description

Collection of TimeSheetRowResult
NameDescriptionTypeAdditional information
Data

None.

Collection of TimeSheetRow

None.

Status

None.

TimeSheetResultStatus

None.

Error Resource Description (Реализовано не везде)

OperationResult
NameDescriptionTypeAdditional information
Target

Возвращаемый объект

Object

None.

Status

Статус операции

ResultStatus

None.

Error

Детализация ошибки

Error

None.

Response Formats

application/json, text/json

Sample:
[
  {
    "Data": [
      {
        "UserId": 1,
        "Date": "2022-08-17T04:50:35+03:00",
        "TimeBegin": 3,
        "TimeEnd": 4,
        "TimeSheetType": 1
      },
      {
        "UserId": 1,
        "Date": "2022-08-17T04:50:35+03:00",
        "TimeBegin": 3,
        "TimeEnd": 4,
        "TimeSheetType": 1
      }
    ],
    "Status": 0
  },
  {
    "Data": [
      {
        "UserId": 1,
        "Date": "2022-08-17T04:50:35+03:00",
        "TimeBegin": 3,
        "TimeEnd": 4,
        "TimeSheetType": 1
      },
      {
        "UserId": 1,
        "Date": "2022-08-17T04:50:35+03:00",
        "TimeBegin": 3,
        "TimeEnd": 4,
        "TimeSheetType": 1
      }
    ],
    "Status": 0
  }
]

text/html, multipart/form-data

Sample:
[{"Data":[{"UserId":1,"Date":"2022-08-17T04:50:35+03:00","TimeBegin":3,"TimeEnd":4,"TimeSheetType":1},{"UserId":1,"Date":"2022-08-17T04:50:35+03:00","TimeBegin":3,"TimeEnd":4,"TimeSheetType":1}],"Status":0},{"Data":[{"UserId":1,"Date":"2022-08-17T04:50:35+03:00","TimeBegin":3,"TimeEnd":4,"TimeSheetType":1},{"UserId":1,"Date":"2022-08-17T04:50:35+03:00","TimeBegin":3,"TimeEnd":4,"TimeSheetType":1}],"Status":0}]

application/xml, text/xml

Sample:
<ArrayOfTimeSheetRowResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AGAT.TSSM.Logic.Domain.ServicesDto.TimeSheet">
  <TimeSheetRowResult>
    <Data>
      <TimeSheetRow>
        <Date>2022-08-17T04:50:35.9962544+03:00</Date>
        <TimeBegin>3</TimeBegin>
        <TimeEnd>4</TimeEnd>
        <TimeSheetType>Holiday</TimeSheetType>
        <UserId>1</UserId>
      </TimeSheetRow>
      <TimeSheetRow>
        <Date>2022-08-17T04:50:35.9962544+03:00</Date>
        <TimeBegin>3</TimeBegin>
        <TimeEnd>4</TimeEnd>
        <TimeSheetType>Holiday</TimeSheetType>
        <UserId>1</UserId>
      </TimeSheetRow>
    </Data>
    <Status>Success</Status>
  </TimeSheetRowResult>
  <TimeSheetRowResult>
    <Data>
      <TimeSheetRow>
        <Date>2022-08-17T04:50:35.9962544+03:00</Date>
        <TimeBegin>3</TimeBegin>
        <TimeEnd>4</TimeEnd>
        <TimeSheetType>Holiday</TimeSheetType>
        <UserId>1</UserId>
      </TimeSheetRow>
      <TimeSheetRow>
        <Date>2022-08-17T04:50:35.9962544+03:00</Date>
        <TimeBegin>3</TimeBegin>
        <TimeEnd>4</TimeEnd>
        <TimeSheetType>Holiday</TimeSheetType>
        <UserId>1</UserId>
      </TimeSheetRow>
    </Data>
    <Status>Success</Status>
  </TimeSheetRowResult>
</ArrayOfTimeSheetRowResult>