Add update-UserTable.sh
This commit is contained in:
parent
7d883432ac
commit
cfa40f96f6
|
@ -101,8 +101,7 @@ class User(db.Model):
|
|||
self.auth_method = auth_method
|
||||
|
||||
def __repr__(self):
|
||||
#return '<User %r>' % (self.username)
|
||||
return '<User %r beans %r>' % (self.username,self.beans)
|
||||
return '<User %r>' % (self.username)
|
||||
|
||||
#token will expire after 3600s
|
||||
def generate_auth_token(self, expiration = 3600):
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/bash
|
||||
|
||||
echo "Backup UserTable..."
|
||||
cp /opt/docklet/global/sys/UserTable.db /opt/docklet/global/sys/UserTable.db.backup
|
||||
|
||||
sed -i "75s/^ /#/g" ../src/model.py
|
||||
sed -i "95s/^ /#/g" ../src/model.py
|
||||
|
||||
echo "Alter UserTable..."
|
||||
python3 alterUserTable.py
|
||||
|
||||
git checkout -- ../
|
||||
|
Loading…
Reference in New Issue