create and delete events
This commit is contained in:
parent
27cd83db3c
commit
400241ec6a
34 changed files with 1346 additions and 614 deletions
|
@ -290,44 +290,44 @@ Page{
|
|||
|
||||
else {errormessage=""}
|
||||
if (errormessage=="") {
|
||||
Helperjs.friendicaRequest(userconfig,"/api/account/verify_credentials?skip_status=true",root,function(obj){
|
||||
Helperjs.friendicaRequest(userconfig,"/api/account/verify_credentials.json?skip_status=true",root,function(obj){
|
||||
accountBusy.running=false;
|
||||
var credentials=JSON.parse(obj);
|
||||
if (credentials.hasOwnProperty('status')){
|
||||
Helperjs.showMessage(qsTr("Error"),qsTr("Wrong password!"),root)
|
||||
}
|
||||
else{
|
||||
if (users.length==0){Service.setDefaultOptions(db);}
|
||||
if(userconfig.imagestore == filesystem.homePath+"/"+username.text+"/")
|
||||
{
|
||||
filesystem.makePath(filesystem.homePath+"/"+username.text);
|
||||
}
|
||||
filesystem.Directory=imagestoredir //userconfig.imagestore;
|
||||
filesystem.makeDir("contacts");
|
||||
filesystem.makeDir("albums");
|
||||
userconfig.accountId=credentials.id
|
||||
Service.storeConfig(db,userconfig);
|
||||
Service.readConfig(db,function(userconfig){
|
||||
Helperjs.readData(db,"config","",function(storedUsers){
|
||||
storedUsers.sort(function(obj1, obj2) {
|
||||
return obj1.isActive - obj2.isActive;
|
||||
});
|
||||
accountPage.users=storedUsers});
|
||||
//reset values
|
||||
login=userconfig;
|
||||
news=[];
|
||||
contactlist=[];
|
||||
rootstack.currentIndex=0;
|
||||
newstypeSignal("refresh");
|
||||
},"isActive",0);
|
||||
try{var credentials=JSON.parse(obj);
|
||||
if (credentials.hasOwnProperty('error')){
|
||||
Helperjs.showMessage(qsTr("Error"),qsTr("Wrong password!"),root)
|
||||
}
|
||||
else{
|
||||
if (users.length==0){Service.setDefaultOptions(db);}
|
||||
if(userconfig.imagestore == filesystem.homePath+"/"+username.text+"/")
|
||||
{
|
||||
filesystem.makePath(filesystem.homePath+"/"+username.text);
|
||||
}
|
||||
filesystem.Directory=imagestoredir //userconfig.imagestore;
|
||||
filesystem.makeDir("contacts");
|
||||
filesystem.makeDir("albums");
|
||||
userconfig.accountId=credentials.id
|
||||
Service.storeConfig(db,userconfig);
|
||||
Service.readConfig(db,function(userconfig){
|
||||
Helperjs.readData(db,"config","",function(storedUsers){
|
||||
storedUsers.sort(function(obj1, obj2) {
|
||||
return obj1.isActive - obj2.isActive;
|
||||
});
|
||||
accountPage.users=storedUsers});
|
||||
//reset values
|
||||
login=userconfig;
|
||||
news=[];
|
||||
contactlist=[];
|
||||
rootstack.currentIndex=0;
|
||||
newstypeSignal("refresh");
|
||||
},"isActive",0);
|
||||
|
||||
//Service.requestProfile(userconfig,db,root,function(nc){root.newContacts=nc});
|
||||
Helperjs.showMessage(qsTr("Success"),qsTr("Name")+": "+credentials.name+"\nScreen Name: "+credentials.screen_name,root)
|
||||
rootstackView.pop()
|
||||
}
|
||||
});
|
||||
//Service.requestProfile(userconfig,db,root,function(nc){root.newContacts=nc});
|
||||
Helperjs.showMessage(qsTr("Success"),qsTr("Name")+": "+credentials.name+"\nScreen Name: "+credentials.screen_name,root)
|
||||
rootstackView.pop()
|
||||
}
|
||||
}catch(e){Helperjs.showMessage(qsTr("Error"),qsTr("Wrong password!"),root)};
|
||||
|
||||
}
|
||||
})}
|
||||
else {Helperjs.showMessage(qsTr("Error"), errormessage,root)}
|
||||
}}
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ Page{
|
|||
font.pointSize: osSettings.systemFontSize
|
||||
color:Material.primaryTextColor
|
||||
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
|
||||
text: "<b>Friendiqa v0.6.5 </b><br>Licensed under GPL 3 with the exception of OpenSSL <br> "+
|
||||
text: "<b>Friendiqa v0.6.6 </b><br>Licensed under GPL 3 with the exception of OpenSSL <br> "+
|
||||
"Website <a href='https://friendiqa.ma-nic.de'>https://friendiqa.ma-nic.de</a><br>"+
|
||||
"Sourcecode: <a href='https://git.friendi.ca/LubuWest/Friendiqa'>https://git.friendi.ca/LubuWest/Friendiqa</a><br>"+
|
||||
"Privacy Policy: <a href='https://git.friendi.ca/lubuwest/Friendiqa/src/branch/master/PrivacyPolicy.md'>http://git.friendi.ca/lubuwest/Friendiqa/src/branch/master/PrivacyPolicy.md</a><br>"+
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue