Skip to content
This repository has been archived by the owner on Jul 25, 2019. It is now read-only.

pytatki.dbconnect.create_action()

Patryk Niedźwiedziński edited this page Nov 1, 2018 · 2 revisions

v1.0.1

create_action() - create new action on note i.e. "Edit note 'wild animals'"

create_action(
    conn,
    content,
    iduser,
    idnote)
  • conn - connection used to insert into db
  • content - action message
  • iduser - id of author
  • idnote - target of action

Examples

import pytatki

_, conn = pytatki.dbconnect.connection()
create_action(conn, "Open note 'wild animals'", 1, 1)
conn.commit()
create_action(conn, "Open note 'wild animals'", 2, 1)
conn.commit()
create_action(conn, "Open note 'wild animals'", 3, 1)
conn.commit()
_.close()
conn.close()

See also

pytatki.dbconnect.connection()