Commit dc0cb9cb authored by Andrey Vertiprahov's avatar Andrey Vertiprahov
Browse files

Merge branch 'fix-avs-qtech-qsw2800-inventory-import' into 'master'

Fix Qtech.QSW2800.get_inventory datetime import.

See merge request noc/noc!1987
parents d812cfac 3e98c403
......@@ -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