Дополнил данные по спутникам при добавлении
This commit is contained in:
@@ -141,6 +141,8 @@ def parse_transponders_from_xml(data_in: BytesIO, user=None):
|
|||||||
continue
|
continue
|
||||||
norad = sat.xpath('./ns:norad/text()', namespaces=ns)
|
norad = sat.xpath('./ns:norad/text()', namespaces=ns)
|
||||||
beams = sat.xpath('.//ns:BeamMemo', namespaces=ns)
|
beams = sat.xpath('.//ns:BeamMemo', namespaces=ns)
|
||||||
|
intl_code = sat.xpath('.//ns:internationalCode/text()', namespaces=ns)
|
||||||
|
sub_sat_point = sat.xpath('.//ns:subSatellitePoint/text()', namespaces=ns)
|
||||||
zones = {}
|
zones = {}
|
||||||
for zone in beams:
|
for zone in beams:
|
||||||
zone_name = zone.xpath('./ns:name/text()', namespaces=ns)[0] if zone.xpath('./ns:name/text()', namespaces=ns) else '-'
|
zone_name = zone.xpath('./ns:name/text()', namespaces=ns)[0] if zone.xpath('./ns:name/text()', namespaces=ns) else '-'
|
||||||
@@ -174,7 +176,9 @@ def parse_transponders_from_xml(data_in: BytesIO, user=None):
|
|||||||
sat_obj, _ = Satellite.objects.get_or_create(
|
sat_obj, _ = Satellite.objects.get_or_create(
|
||||||
name=name,
|
name=name,
|
||||||
defaults={
|
defaults={
|
||||||
"norad": int(norad[0]) if norad else -1
|
"norad": int(norad[0]) if norad else -1,
|
||||||
|
"international_code": intl_code[0],
|
||||||
|
"undersat_point": sub_sat_point[0]
|
||||||
})
|
})
|
||||||
trans_obj, created = Transponders.objects.get_or_create(
|
trans_obj, created = Transponders.objects.get_or_create(
|
||||||
polarization=pol_obj,
|
polarization=pol_obj,
|
||||||
|
|||||||
@@ -57,6 +57,17 @@ services:
|
|||||||
- ./nginx/nginx.conf:/etc/nginx/conf.d/default.conf:ro
|
- ./nginx/nginx.conf:/etc/nginx/conf.d/default.conf:ro
|
||||||
- static_volume:/usr/share/nginx/html/static
|
- static_volume:/usr/share/nginx/html/static
|
||||||
|
|
||||||
|
flaresolverr:
|
||||||
|
image: ghcr.io/flaresolverr/flaresolverr:latest
|
||||||
|
container_name: flaresolverr
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- "8191:8191"
|
||||||
|
environment:
|
||||||
|
- LOG_LEVEL=info
|
||||||
|
- LOG_HTML=false
|
||||||
|
- CAPTCHA_SOLVER=none
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
pgdata:
|
pgdata:
|
||||||
static_volume:
|
static_volume:
|
||||||
Reference in New Issue
Block a user