feature:支持变量修改

This commit is contained in:
charlesxie
2023-04-12 16:39:46 +08:00
parent a6d2be985e
commit 5a1d91073f
6 changed files with 12 additions and 6 deletions

View File

@@ -9,7 +9,7 @@ from applications.utils.send import send
def update_music_info(music_id3_info, is_raw_thumbnail=False):
for each in music_id3_info:
f = music_tag.load_file(each["file_full_path"])
base_filename = each["filename"].split(".")[0]
base_filename = ".".join(each["filename"].split(".")[:-1])
var_dict = {
"title": f["title"].value,
"artist": f["artist"].value,

View File

@@ -129,11 +129,13 @@ class TaskViewSets(GenericViewSet):
continue
music_info.update({
"file_full_path": f"{file_full_path}/{each}",
"filename": each
})
music_id3_info.append(copy.deepcopy(music_info))
else:
music_info.update({
"file_full_path": f"{full_path}/{data.get('name')}",
"filename": data.get('name')
})
music_id3_info.append(copy.deepcopy(music_info))
update_music_info(music_id3_info)

View File

@@ -6,5 +6,5 @@ set -o nounset
python manage.py migrate
#exec gunicorn -w 2 -b 0.0.0.0:8001 django_vue_cli.wsgi:application --timeout 120
python manage.py runserver 0.0.0.0:8001
gunicorn -w 2 -b 0.0.0.0:8001 django_vue_cli.wsgi:application --timeout 120
#python manage.py runserver 0.0.0.0:8001

View File

@@ -8,4 +8,6 @@ gunicorn==20.1.0
gevent==21.12.0
djangorestframework-jwt==1.11.0
music-tag==0.4.3
Pillow==9.4.0
Pillow==9.4.0
pycryptodomex==3.17
Mako==1.0.6

View File

@@ -9,4 +9,5 @@ gevent==21.12.0
djangorestframework-jwt==1.11.0
music-tag==0.4.3
Pillow==9.4.0
pycryptodomex==3.17
pycryptodomex==3.17
Mako==1.0.6

View File

@@ -336,7 +336,8 @@
const titleClass = node.selected ? 'node-title node-selected' : 'node-title'
return <span>
<span class={titleClass} domPropsInnerHTML={node.title.slice(0, 30)}
onClick={() => { this.nodeClickOne(node) }} v-bk-tooltips={node.title}></span>
onClick={() => { this.nodeClickOne(node) }} v-bk-tooltips={node.title}>
</span>
</span>
},
backDir() {