POST api/package/SavePackage

Request Information

URI Parameters

None.

Body Parameters

PackageMain
NameDescriptionTypeAdditional information
parent

Package

None.

child

Collection of PackageEmployee

None.

child_id2Delete

Collection of integer

None.

Request Formats

application/json, text/json

Sample:
{
  "parent": {
    "package_num": 1,
    "package_name": "sample string 2",
    "active": "sample string 3",
    "day_of_package": 1,
    "description": "sample string 4",
    "oper_in_package": 1,
    "frequency_type_code": 1,
    "oper_code": 1
  },
  "child": [
    {
      "PackageEmployee_Id": 1,
      "package_num": 2,
      "function_code": 3,
      "form_code": 1,
      "operCode": 1,
      "frequency_code": 1,
      "firstEnter_code": 1
    },
    {
      "PackageEmployee_Id": 1,
      "package_num": 2,
      "function_code": 3,
      "form_code": 1,
      "operCode": 1,
      "frequency_code": 1,
      "firstEnter_code": 1
    }
  ],
  "child_id2Delete": [
    1,
    2
  ]
}

application/xml, text/xml

Sample:
<PackageMain xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BLMedical.PackageMengement">
  <child xmlns:d2p1="http://schemas.datacontract.org/2004/07/CustDemog">
    <d2p1:PackageEmployee>
      <d2p1:PackageEmployee_Id>1</d2p1:PackageEmployee_Id>
      <d2p1:firstEnter_code>1</d2p1:firstEnter_code>
      <d2p1:form_code>1</d2p1:form_code>
      <d2p1:frequency_code>1</d2p1:frequency_code>
      <d2p1:function_code>3</d2p1:function_code>
      <d2p1:operCode>1</d2p1:operCode>
      <d2p1:package_num>2</d2p1:package_num>
    </d2p1:PackageEmployee>
    <d2p1:PackageEmployee>
      <d2p1:PackageEmployee_Id>1</d2p1:PackageEmployee_Id>
      <d2p1:firstEnter_code>1</d2p1:firstEnter_code>
      <d2p1:form_code>1</d2p1:form_code>
      <d2p1:frequency_code>1</d2p1:frequency_code>
      <d2p1:function_code>3</d2p1:function_code>
      <d2p1:operCode>1</d2p1:operCode>
      <d2p1:package_num>2</d2p1:package_num>
    </d2p1:PackageEmployee>
  </child>
  <child_id2Delete xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </child_id2Delete>
  <parent xmlns:d2p1="http://schemas.datacontract.org/2004/07/CustDemog">
    <d2p1:active>sample string 3</d2p1:active>
    <d2p1:day_of_package>1</d2p1:day_of_package>
    <d2p1:description>sample string 4</d2p1:description>
    <d2p1:frequency_type_code>1</d2p1:frequency_type_code>
    <d2p1:oper_code>1</d2p1:oper_code>
    <d2p1:oper_in_package>1</d2p1:oper_in_package>
    <d2p1:package_name>sample string 2</d2p1:package_name>
    <d2p1:package_num>1</d2p1:package_num>
  </parent>
</PackageMain>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'PackageMain'.

application/bson

Sample:
Binary JSON content. See http://bsonspec.org for details.

Response Information

Resource Description

PackageMain
NameDescriptionTypeAdditional information
parent

Package

None.

child

Collection of PackageEmployee

None.

child_id2Delete

Collection of integer

None.

Response Formats

application/json, text/json

Sample:
{
  "parent": {
    "package_num": 1,
    "package_name": "sample string 2",
    "active": "sample string 3",
    "day_of_package": 1,
    "description": "sample string 4",
    "oper_in_package": 1,
    "frequency_type_code": 1,
    "oper_code": 1
  },
  "child": [
    {
      "PackageEmployee_Id": 1,
      "package_num": 2,
      "function_code": 3,
      "form_code": 1,
      "operCode": 1,
      "frequency_code": 1,
      "firstEnter_code": 1
    },
    {
      "PackageEmployee_Id": 1,
      "package_num": 2,
      "function_code": 3,
      "form_code": 1,
      "operCode": 1,
      "frequency_code": 1,
      "firstEnter_code": 1
    }
  ],
  "child_id2Delete": [
    1,
    2
  ]
}

application/xml, text/xml

Sample:
<PackageMain xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BLMedical.PackageMengement">
  <child xmlns:d2p1="http://schemas.datacontract.org/2004/07/CustDemog">
    <d2p1:PackageEmployee>
      <d2p1:PackageEmployee_Id>1</d2p1:PackageEmployee_Id>
      <d2p1:firstEnter_code>1</d2p1:firstEnter_code>
      <d2p1:form_code>1</d2p1:form_code>
      <d2p1:frequency_code>1</d2p1:frequency_code>
      <d2p1:function_code>3</d2p1:function_code>
      <d2p1:operCode>1</d2p1:operCode>
      <d2p1:package_num>2</d2p1:package_num>
    </d2p1:PackageEmployee>
    <d2p1:PackageEmployee>
      <d2p1:PackageEmployee_Id>1</d2p1:PackageEmployee_Id>
      <d2p1:firstEnter_code>1</d2p1:firstEnter_code>
      <d2p1:form_code>1</d2p1:form_code>
      <d2p1:frequency_code>1</d2p1:frequency_code>
      <d2p1:function_code>3</d2p1:function_code>
      <d2p1:operCode>1</d2p1:operCode>
      <d2p1:package_num>2</d2p1:package_num>
    </d2p1:PackageEmployee>
  </child>
  <child_id2Delete xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </child_id2Delete>
  <parent xmlns:d2p1="http://schemas.datacontract.org/2004/07/CustDemog">
    <d2p1:active>sample string 3</d2p1:active>
    <d2p1:day_of_package>1</d2p1:day_of_package>
    <d2p1:description>sample string 4</d2p1:description>
    <d2p1:frequency_type_code>1</d2p1:frequency_type_code>
    <d2p1:oper_code>1</d2p1:oper_code>
    <d2p1:oper_in_package>1</d2p1:oper_in_package>
    <d2p1:package_name>sample string 2</d2p1:package_name>
    <d2p1:package_num>1</d2p1:package_num>
  </parent>
</PackageMain>

application/bson

Sample:
Binary JSON content. See http://bsonspec.org for details.