Skip to content

Commit

Permalink
Merge pull request #732 from liangliangyy/dev
Browse files Browse the repository at this point in the history
  • Loading branch information
liangliangyy committed Jul 15, 2024
2 parents 0cbeb78 + fb48180 commit 5a442b6
Show file tree
Hide file tree
Showing 7 changed files with 46 additions and 7 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,17 +121,17 @@ python manage.py compress --force
如果您觉得本项目对您有所帮助,欢迎您请我喝杯咖啡,您的支持是我最大的动力,您可以扫描下方二维码为我付款,谢谢。
### 支付宝:
<div>
<img src="https://resource.lylinux.net/image/2017/12/16/IMG_0207.jpg" width="150" height="150" />
<img src="/docs/imgs/alipay.jpg" width="150" height="150" />
</div>

### 微信:
<div>
<img src="https://resource.lylinux.net/image/2017/12/16/IMG_0206.jpg" width="150" height="150" />
<img src="/docs/imgs/wechat.jpg" width="150" height="150" />
</div>

---

感谢jetbrains
<div>
<a href="https://www.jetbrains.com/?from=DjangoBlog"><img src="https://resource.lylinux.net/image/2020/07/01/logo.png" width="150" height="150"></a>
<a href="https://www.jetbrains.com/?from=DjangoBlog"><img src="/docs/imgs/pycharm_logo.png" width="150" height="150"></a>
</div>
17 changes: 17 additions & 0 deletions blog/migrations/0006_alter_blogsettings_options.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 4.2.7 on 2024-01-26 02:41

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('blog', '0005_alter_article_options_alter_category_options_and_more'),
]

operations = [
migrations.AlterModelOptions(
name='blogsettings',
options={'verbose_name': 'Website configuration', 'verbose_name_plural': 'Website configuration'},
),
]
Binary file added docs/imgs/alipay.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/pycharm_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/wechat.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions oauth/migrations/0003_alter_oauthuser_nickname.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 4.2.7 on 2024-01-26 02:41

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('oauth', '0002_alter_oauthconfig_options_alter_oauthuser_options_and_more'),
]

operations = [
migrations.AlterField(
model_name='oauthuser',
name='nickname',
field=models.CharField(max_length=50, verbose_name='nick name'),
),
]
12 changes: 8 additions & 4 deletions owntracks/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,14 @@ def get_datas(request):
d = dict()
d["name"] = tid
paths = list()
locations = convert_to_amap(
sorted(item, key=lambda x: x.creation_time))
for i in locations.split(';'):
paths.append(i.split(','))
# 使用高德转换后的经纬度
# locations = convert_to_amap(
# sorted(item, key=lambda x: x.creation_time))
# for i in locations.split(';'):
# paths.append(i.split(','))
# 使用GPS原始经纬度
for location in sorted(item, key=lambda x: x.creation_time):
paths.append([str(location.lon), str(location.lat)])
d["path"] = paths
result.append(d)
return JsonResponse(result, safe=False)

0 comments on commit 5a442b6

Please sign in to comment.