Skip to content

Commit 89fbad3

Browse files
committed
modified: composer.json
1 parent a1f84e3 commit 89fbad3

File tree

5 files changed

+10
-25
lines changed

5 files changed

+10
-25
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
/vendor
2+
composer.lock

app/config/config.sample.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
*/
1313

1414
define("DEFAULT_CONTROLLER_MAP", "home");
15-
define("BASE_URI", "localhost/wechat");
15+
define("BASE_URI", "wx.ustb806.cn");
1616

1717

1818
//wechat configuration
@@ -25,6 +25,6 @@
2525
define("DBHOST", "127.0.0.1");
2626
define("DBUSER", "root");
2727
define("DBPASS", "root");
28-
define("DBNAME", "kalen_mvc");
28+
define("DBNAME", "806wechat");
2929
define("DBPORT", 3306);
3030

app/model/Crawler.php

+6-6
Original file line numberDiff line numberDiff line change
@@ -23,42 +23,42 @@ function __construct($dao)
2323
function seam_classtable()
2424
{
2525
$info = $this->dao->get_seam_info();
26-
$request = \Requests::get("http://115.159.105.153:8879/teach?pattern=classtable&uname=".$info['uname']."&passwd=".$info['passwd']);
26+
$request = \Requests::get("http://wx.ustb806.cn:8879/teach?pattern=classtable&uname=".$info['uname']."&passwd=".$info['passwd']);
2727
return $request->body;
2828
}
2929

3030
function seam_semesters()
3131
{
3232
$info = $this->dao->get_seam_info();
33-
$request = \Requests::get("http://115.159.105.153:8879/teach?pattern=semester&uname=".$info['uname']."&passwd=".$info['passwd']);
33+
$request = \Requests::get("http://wx.ustb806.cn:8879/teach?pattern=semester&uname=".$info['uname']."&passwd=".$info['passwd']);
3434
return $request->body;
3535
}
3636

3737
function seam_scores($semester)
3838
{
3939
$info = $this->dao->get_seam_info();
40-
$request = \Requests::get("http://115.159.105.153:8879/teach?pattern=scores&uname=".$info['uname']."&passwd=".$info['passwd']."&semester=".$semester);
40+
$request = \Requests::get("http://wx.ustb806.cn:8879/teach?pattern=scores&uname=".$info['uname']."&passwd=".$info['passwd']."&semester=".$semester);
4141
return $request->body;
4242
}
4343

4444
function seam_innovative_score1()
4545
{
4646
$info = $this->dao->get_seam_info();
47-
$request = \Requests::get("http://115.159.105.153:8879/teach?pattern=innovative_score1&uname=".$info['uname']."&passwd=".$info['passwd']);
47+
$request = \Requests::get("http://wx.ustb806.cn:8879/teach?pattern=innovative_score1&uname=".$info['uname']."&passwd=".$info['passwd']);
4848
return $request->body;
4949
}
5050

5151
function seam_innovative_score2()
5252
{
5353
$info = $this->dao->get_seam_info();
54-
$request = \Requests::get("http://115.159.105.153:8879/teach?pattern=innovative_score2&uname=".$info['uname']."&passwd=".$info['passwd']);
54+
$request = \Requests::get("http://wx.ustb806.cn:8879/teach?pattern=innovative_score2&uname=".$info['uname']."&passwd=".$info['passwd']);
5555
return $request->body;
5656
}
5757

5858
function library_borrowed_books()
5959
{
6060
$info = $this->dao->get_library_info();
61-
$request = \Requests::get("http://115.159.105.153:8879/lib?&uname=".$info['uname']."&passwd=".$info['passwd']);
61+
$request = \Requests::get("http://wx.ustb806.cn:8879/lib?&uname=".$info['uname']."&passwd=".$info['passwd']);
6262
return $request->body;
6363
}
6464

cli/crawler/crawler.py

-16
Original file line numberDiff line numberDiff line change
@@ -85,19 +85,3 @@ def lib_borrowed_books(uname, passwd):
8585
retStr += "</tbody>"
8686
return retStr.replace('href="../', 'href="http://lib.ustb.edu.cn:8080/')
8787

88-
89-
#
90-
# s = requests.session()
91-
# lib_borrowed_books(s, "41357009", "950825")
92-
# teach_login(s, "41357009", "950825")
93-
# # # print teach_classtable(s)
94-
# teach_innovative_score1(s)
95-
96-
# data = {
97-
# "XNXQ": "all",
98-
# "Submit": ""
99-
# }
100-
# resp = s.post("http://seam.ustb.edu.cn:8080/jwgl/score.jsp?stu=41357009", data)
101-
# bsObj = BeautifulSoup(resp.content.decode('gbk'))
102-
# print bsObj.find('div', {"id": "maincontent"}).table.tr
103-

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22
"require": {
33
"overtrue/wechat": "~3.0",
44
"rmccue/requests": "^1.6",
5-
"joshcam/mysqli-database-class": "dev-master",
5+
"joshcam/mysqli-database-class": "dev-master"
66
}
77
}

0 commit comments

Comments
 (0)