Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function getConnection(iden){
- var con;
- _connectionDBase().transaction(function(tx) {
- var con = tx.executeSql('SELECT id,connection_name,username,address,type,category,act_on_start,connection_commands \
- FROM Connections WHERE id=?', [iden]);
- })
- return con;
- }
- &&
- function populateList(){
- for (var i=0; i<DBase.countConnections(); i++){
- var component = Qt.createComponent("Connection.qml")
- var connection = DBase.getConnection(i)
- var mod = component.createObject(null, {
- section:"Connections",
- ident: connection.id,
- connection_name: connection.connection_name,
- username: connection.username,
- address: connection.address,
- type: connection.type,
- category: connection.category,
- activate_on_start: connection.act_on_start,
- connection_commands: connection.connection_commands
- })
- listModel.append(mod)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement