# 新增一条单元数据

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /unit/add-unit:
    post:
      summary: 新增一条单元数据
      deprecated: false
      description: ''
      operationId: addUnit
      tags:
        - c1/房产管理/房屋管理
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              type: object
              x-apifox-refs:
                01JX0BY4NREAMYZ49D2X3E0R5Y:
                  $ref: '#/components/schemas/UnitDTO'
                  x-apifox-overrides:
                    unit_num: &ref_1
                      type: string
                      description: 单元编号
                    b_id: &ref_0
                      type: string
                      description: 业务ID
                    layer_count: &ref_2
                      type: integer
                      description: 总层数
                      minimum: -2147483648
                      maximum: 2147483647
                    unit_area: &ref_4
                      type: string
                      description: 单元面积
                    lift: &ref_3
                      type: string
                      description: 电梯状态
                  required:
                    - unit_num
                    - layer_count
                    - unit_area
                    - lift
              x-apifox-orders:
                - 01JX0BY4NREAMYZ49D2X3E0R5Y
              properties:
                b_id: *ref_0
                unit_num: *ref_1
                floor_id:
                  type: string
                  description: 楼ID
                layer_count: *ref_2
                lift: *ref_3
                user_id:
                  type: string
                  description: 用户ID
                remark:
                  type: string
                  description: 备注
                status_cd:
                  type: string
                  description: 数据状态
                unit_area: *ref_4
                unit_id:
                  type: string
                  description: 单元ID
                create_time:
                  type: string
                  description: 创建时间
              required:
                - unit_num
                - layer_count
                - lift
                - unit_area
              x-apifox-ignore-properties:
                - b_id
                - unit_num
                - floor_id
                - layer_count
                - lift
                - user_id
                - remark
                - status_cd
                - unit_area
                - unit_id
                - create_time
            examples: {}
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/StringJsonVO'
          headers: {}
          x-apifox-name: 成功
      security: []
      x-apifox-folder: c1/房产管理/房屋管理
      x-apifox-status: integrating
      x-run-in-apifox: https://app.apifox.com/web/project/6386631/apis/api-303296044-run
components:
  schemas:
    UnitDTO:
      type: object
      properties:
        b_id:
          type: string
          description: 业务ID
        unit_num:
          type: string
          description: 单元编号
        floor_id:
          type: string
          description: 楼ID
        layer_count:
          type: integer
          description: 总层数
          minimum: -2147483648
          maximum: 2147483647
        lift:
          type: string
          description: 电梯状态
        user_id:
          type: string
          description: 用户ID
        remark:
          type: string
          description: 备注
        status_cd:
          type: string
          description: 数据状态
        unit_area:
          type: string
          description: 单元面积
        unit_id:
          type: string
          description: 单元ID
        create_time:
          type: string
          description: 创建时间
      x-apifox-orders:
        - b_id
        - unit_num
        - floor_id
        - layer_count
        - lift
        - user_id
        - remark
        - status_cd
        - unit_area
        - unit_id
        - create_time
      x-apifox-ignore-properties: []
      x-apifox-folder: ''
    StringJsonVO:
      type: object
      properties:
        code:
          type: integer
          description: 状态码
          default: 10000
          minimum: -2147483648
          maximum: 2147483647
        message:
          type: string
          description: 提示信息
          default: success
        data:
          type: string
          description: 数据对象
      required:
        - code
        - message
      x-apifox-orders:
        - code
        - message
        - data
      x-apifox-ignore-properties: []
      x-apifox-folder: ''
  securitySchemes:
    bearer_auth:
      type: jwt
      description: Default HTTP Bearer Authorization
      name: Authorization
      in: header
      scheme: bearer
      bearerFormat: JWT
    Authorization:
      type: apikey
      name: Authorization
      in: header
servers: []
security: []

```
