only scrape with item, move after editing metadata
This commit is contained in:
parent
14ede9d1b1
commit
dcb0a16153
1 changed files with 4 additions and 1 deletions
|
@ -298,6 +298,8 @@ class Item(db.Model):
|
||||||
m.update_items()
|
m.update_items()
|
||||||
else:
|
else:
|
||||||
self.update_meta(data)
|
self.update_meta(data)
|
||||||
|
for f in self.files.all():
|
||||||
|
f.move()
|
||||||
|
|
||||||
def extract_preview(self):
|
def extract_preview(self):
|
||||||
path = self.get_path()
|
path = self.get_path()
|
||||||
|
@ -695,6 +697,7 @@ class Metadata(db.Model):
|
||||||
|
|
||||||
def update_items(self):
|
def update_items(self):
|
||||||
for f in Find.query.filter_by(key=self.key, value=self.value):
|
for f in Find.query.filter_by(key=self.key, value=self.value):
|
||||||
|
if f.item:
|
||||||
f.item.scrape()
|
f.item.scrape()
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
|
Loading…
Reference in a new issue