Commit 3e98c403 authored by Andrey Vertiprahov's avatar Andrey Vertiprahov
Browse files

Fix Qtech.QSW2800.get_inventory datetime import.

parent b64c2bad
......@@ -8,7 +8,7 @@
# Python modules
import re
import datetime
from datetime import datetime
# NOC modules
from noc.core.script.base import BaseScript
from noc.sa.interfaces.igetinventory import IGetInventory
......@@ -66,7 +66,7 @@ class Script(BaseScript):
"description": ""
}
try:
mfg_date = datetime.datetime.strptime(t.group("mfg_date"), "%b %d %Y")
mfg_date = datetime.strptime(t.group("mfg_date"), "%b %d %Y")
data["mfg_date"] = mfg_date.strftime("%Y-%m-%d")
except ValueError:
pass
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment