mirror of
https://github.com/Babibubebon/isdn-python.git
synced 2024-09-22 17:24:20 +09:00
Fix types
This commit is contained in:
parent
9ab036275e
commit
9ca2afbe49
3 changed files with 4 additions and 4 deletions
|
@ -62,7 +62,7 @@ ISDNRecord(
|
||||||
author='専門',
|
author='専門',
|
||||||
shape='単行本',
|
shape='単行本',
|
||||||
contents='電子通信',
|
contents='電子通信',
|
||||||
price=100,
|
price=Decimal('100'),
|
||||||
price_unit='JPY',
|
price_unit='JPY',
|
||||||
barcode2='2923055001007',
|
barcode2='2923055001007',
|
||||||
product_comment=None,
|
product_comment=None,
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
import json
|
|
||||||
import os
|
import os
|
||||||
import time
|
import time
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import re
|
import re
|
||||||
from datetime import date
|
from datetime import date
|
||||||
|
from decimal import Decimal
|
||||||
|
|
||||||
from pydantic import Field, HttpUrl, root_validator, validator
|
from pydantic import Field, HttpUrl, root_validator, validator
|
||||||
from pydantic.dataclasses import dataclass
|
from pydantic.dataclasses import dataclass
|
||||||
|
@ -139,13 +140,13 @@ class ISDNRecord(BaseXmlModel, nsmap=NSMAP):
|
||||||
author: str | None = element(tag="author")
|
author: str | None = element(tag="author")
|
||||||
shape: str | None = element(tag="shape")
|
shape: str | None = element(tag="shape")
|
||||||
contents: str | None = element(tag="contents")
|
contents: str | None = element(tag="contents")
|
||||||
price: int | None = element(tag="price")
|
price: Decimal | None = element(tag="price")
|
||||||
price_unit: str | None = element(tag="price-unit")
|
price_unit: str | None = element(tag="price-unit")
|
||||||
barcode2: str | None = element(tag="barcode2")
|
barcode2: str | None = element(tag="barcode2")
|
||||||
product_comment: str | None = element(tag="product-comment")
|
product_comment: str | None = element(tag="product-comment")
|
||||||
product_style: str | None = element(tag="product-style")
|
product_style: str | None = element(tag="product-style")
|
||||||
product_size: str | None = element(tag="product-size")
|
product_size: str | None = element(tag="product-size")
|
||||||
product_capacity: int | None = element(tag="product-capacity")
|
product_capacity: Decimal | None = element(tag="product-capacity")
|
||||||
product_capacity_unit: str | None = element(tag="product-capacity-unit")
|
product_capacity_unit: str | None = element(tag="product-capacity-unit")
|
||||||
sample_image_uri: HttpUrl | None = element(tag="sample-image-uri")
|
sample_image_uri: HttpUrl | None = element(tag="sample-image-uri")
|
||||||
useroptions: list[UserOption] = Field(default_factory=list)
|
useroptions: list[UserOption] = Field(default_factory=list)
|
||||||
|
|
Loading…
Reference in a new issue