summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCranix <you@example.com>2013-03-19 17:47:20 -0400
committerCranix <you@example.com>2013-03-19 17:47:20 -0400
commit05e4f5b64a94ecc105e99db3ef37862da16aafb2 (patch)
treeb099173ccf5a38aedd8ce7e95e172cfc702d6820
parent8179e55fe0df90b3316a88b4f85073c11b43388e (diff)
downloadBiblioteka-05e4f5b64a94ecc105e99db3ef37862da16aafb2.tar.gz
Biblioteka-05e4f5b64a94ecc105e99db3ef37862da16aafb2.tar.bz2
Biblioteka-05e4f5b64a94ecc105e99db3ef37862da16aafb2.zip
Usunąłem zbędne pliki.
-rw-r--r--bin/a.dbbin3072 -> 0 bytes
-rwxr-xr-xbin/app.pl.backup63
-rw-r--r--bin/ksiazki.db.backupbin2048 -> 0 bytes
-rw-r--r--bin/ksiazki.db.backup1bin2048 -> 0 bytes
-rwxr-xr-xbin/test_sql.pl21
-rw-r--r--git1
-rw-r--r--ksiazki.db0
7 files changed, 0 insertions, 85 deletions
diff --git a/bin/a.db b/bin/a.db
deleted file mode 100644
index 3b19ecf..0000000
--- a/bin/a.db
+++ /dev/null
Binary files differ
diff --git a/bin/app.pl.backup b/bin/app.pl.backup
deleted file mode 100755
index f0df067..0000000
--- a/bin/app.pl.backup
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/usr/bin/env perl
-use warnings;
-use strict;
-use Dancer;
-use DBI;
-
-#Struktura bazy
-#id, int; isbn, int; tytul, string; autor, string; owner, string; state, bool (czy pozyczona, 0=dostepna, 1=wzieta); type, bool (mozna brac ze soba? 1=tak, 0=nie)
-
-my $dbfile = 'ksiazki.db';
-my $dbh = DBI->connect("dbi:SQLite:dbname=$dbfile", "", "");
-
-get '/' => sub
-{
- my $sth = $dbh->prepare("select * from ksiazki");
- $sth->execute();
-
- my @id;
- my @isbn;
- my @title;
- my @author;
- my @owner;
- my @state;
- my @type;
-
- my $result=''; #Poniewaz trzeba zwrocic string, wartosci kolejno pobierane z bazy,
- #beda dodawane do zmiennej ze stringiem, na razie pustym
- my $i=0;
-
- while (($id[$i],$isbn[$i],$title[$i],$author[$i],$owner[$i],$state[$i],$type[$i])=$sth->fetchrow_array)
- {
- $result=$result.$id[$i].'|'.$isbn[$i].'|'.$title[$i].'|'.$author[$i].'|'.$owner[$i].'|'.$state[$i].'|'.$type[$i].'<br>'."\n";
- $i++;
- }
-
- return $result;
-};
-
-get '/req/:book' => sub
-{
- my $id=params->{book};
- my $sth;
-
- $sth=$dbh->prepare("select type from ksiazki where id=$id");
- $sth->execute();
- my $type = $sth->fetchrow_array;
- if ($type == 1)
- {
- $sth = $dbh->prepare("update ksiazki set state=not state where id=?");
- $sth->execute($id);
- return 0;
- }
- elsif ($type == 0)
- {
- return 1;
- }
- else #Stalo sie cos dziwnego...
- {
- return "OMGLOLWTF";
- }
-};
-
-dance;
diff --git a/bin/ksiazki.db.backup b/bin/ksiazki.db.backup
deleted file mode 100644
index a4d24f2..0000000
--- a/bin/ksiazki.db.backup
+++ /dev/null
Binary files differ
diff --git a/bin/ksiazki.db.backup1 b/bin/ksiazki.db.backup1
deleted file mode 100644
index f6880b5..0000000
--- a/bin/ksiazki.db.backup1
+++ /dev/null
Binary files differ
diff --git a/bin/test_sql.pl b/bin/test_sql.pl
deleted file mode 100755
index 5c4b2a3..0000000
--- a/bin/test_sql.pl
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/usr/bin/perl
-
-use DBI;
-
-my $dbfile = 'a.db';
-my $dbh = DBI->connect("dbi:SQLite:dbname=$dbfile", "", "");
-
-#$dbh->do("create table abc (int a)");
-#$dbh->do("insert into abc values (7)");
-#print $dbh->do("select * from abc");
-
-
-#my $sth = $dbh->prepare("select * from abc"); # prepare the query
-#$sth->execute(); # execute the query
-#my @row;
-#while (@row = $sth->fetchrow_array) { # retrieve one row
-# print join("\n", @row), "\n";
-#}
-
-my $sth = $dbh->prepare ("update qwe set liczba=20 where id=2");
-$sth->execute();
diff --git a/git b/git
deleted file mode 100644
index 40ff70f..0000000
--- a/git
+++ /dev/null
@@ -1 +0,0 @@
-http://git-scm.com/book/en/Getting-Started
diff --git a/ksiazki.db b/ksiazki.db
deleted file mode 100644
index e69de29..0000000
--- a/ksiazki.db
+++ /dev/null