├── .DS_Store
├── README.md
├── __init__.py
├── battle.py
├── bit_map.py
├── bit_map2.py
├── config.yaml
├── dayBit.py
├── index.wsgi
├── settings.py
├── static
├── .DS_Store
├── css
│ ├── .DS_Store
│ ├── bootstrap-theme.css
│ ├── bootstrap-theme.css.map
│ ├── bootstrap-theme.min.css
│ ├── bootstrap.css
│ ├── bootstrap.css.map
│ ├── bootstrap.min.css
│ └── index.css
├── fonts
│ ├── glyphicons-halflings-regular.eot
│ ├── glyphicons-halflings-regular.svg
│ ├── glyphicons-halflings-regular.ttf
│ └── glyphicons-halflings-regular.woff
└── js
│ ├── .DS_Store
│ ├── bootstrap.js
│ ├── bootstrap.min.js
│ ├── css.js
│ ├── index.js
│ └── jquery.min.js
├── templates
├── .DS_Store
├── choice.html
├── index.html
├── main.html
├── report.html
└── test.html
└── urls.py
/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/.DS_Store
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | #DayBit
2 | ---
3 |
4 | DayBit 是一个使用 Tornado 作为后台框架的文字交互游戏。
5 |
6 | Demo地址:[http://daybit.sinaapp.com](http://daybit.sinaapp.com)
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/__init__.py
--------------------------------------------------------------------------------
/battle.py:
--------------------------------------------------------------------------------
1 | # -*- coding: utf-8 -*-
2 | import random
3 | # 角色 玩家和NPC 名称 血量 攻击力 经验
4 | class Roles:
5 | def __init__ (self, a, b, c, d):
6 | self.name = a
7 | self.health = b
8 | self.vitality = c
9 | self.experience = c
10 | self.attack = d
11 | # 对战过程
12 | class Battle:
13 | def __init__(self, inputRole = Roles(u'Null', 0, 0, 0)):
14 | self.result = False
15 | self.outputProcess = ''
16 | self.expGet = 0
17 | self.role = inputRole
18 | # 剧本 {0}代表的玩家会获胜
19 | self.listProcess = [
20 | u'{0}与{1}的对战{0}使出全真气功
\
21 | 踢了{1}44加七七四十九下{1}被激怒了
\
22 | 一气之下把{0}冲到马桶里,观赏{0}和大便的对决
\
23 | 可怜的{0}拨电话65719372给伽利略求救
\
24 | 巴哈姆特以正在打英雄为由,拒绝救援
\
25 | 战火中,{1}仍不断逼近{0}
\
26 | {0}为了扭转情势,伺机施展平日所学在{1}脸上重重挥了一拳,
\
27 | {1}因不堪疼痛而败下阵来,'
28 | ,
29 | u'{1}向{0}发起攻击,{0}受到135点伤害
\
30 | {1}发动连击
\
31 | {1}向{0}发起攻击,但是被{0}闪开了
\
32 | {0}向{1}发起攻击,{1}受到136点伤害
\
33 | {1}向{0}发起攻击,{0}受到171点伤害
\
34 | {0}作出垂死抗争,所有数值上升
\
35 | {0}向{1}发起攻击,{1}受到317点伤害
\
36 | {1}被击败了'
37 | ,
38 | u'{1}向{0}发起攻击,{0}受到135点伤害
\
39 | {1}发动连击
\
40 | {1}向{0}发起攻击,但是被{0}闪开了
\
41 | {0}向{1}发起攻击,{1}受到136点伤害
\
42 | {1}向{0}发起攻击,{0}受到171点伤害
\
43 | {0}作出垂死抗争,所有数值上升
\
44 | {0}向{1}发起攻击,{1}受到317点伤害
\
45 | {1}被击败了'
46 | ,
47 | u'只见{0}阴测测的笑了几声,亮出了自己的九阴排骨手,
\
48 | 带着风声直直地向{1}头顶插去
\
49 | 在{0}那阴测测的笑声中,{1}一声惨叫,只见面门上出现了五个碗口大的窟窿
\
50 | 只见{1}突然从背后取出一物放到{0}面前,竟然是个MP4,里面正在播放着还珠格格.
\
51 | MP4正砸中{0}的面门,{0}怒道:看你也是一代宗师,怎的也用板砖
\
52 | 只见{0}对着{1}眉来眼去,笑颜如花,竟是江湖失传已久的郎情妾意剑
\
53 | {1}不禁狂吐不止,一个不留神将肝吐了一地,不禁赞道:好毒辣的郎情妾意剑.'
54 | ,
55 | u'下着小雨的白日,{0}在森林舞着刀走着,猛地,听到一声狂笑。
\
56 | {0}仔细一看,原来是一个大汉,端着钯冲向他。
\
57 | 很明显,{1}的目的,就是袭击他的头部。{0}赶紧往后一退,骂道你找死吗?
\
58 | {1}说我们的帐应该了断了!然后又挥着兵器往前逼近。
\
59 | {0}赶忙还击,轻轻一拨,但{1}身子十分灵活,看来这个对手挺厉害。
\
60 | {0}抖擞精神,使出吃奶的力气用自己的家伙一点。
\
61 | {1}不愠不火,用兵器使劲一击,二人混战在了一起。
\
62 | 连续大战了十个回合。{0}觉得体力不支,于是卖了个破绽。
\
63 | {1}大叫着扑了过来,{0}猛地反回一击,只听当的一声,兵器飞了。
\
64 | {1}死了,再看地上的死人,面目模糊.'
65 | ,
66 | u'{0}拿出了神秘的灵符,往{1}丢过去,
\
67 | {1}被灵符贴到额头以后动弹不得,只能任{0}对自己上下其手
\
68 | {1}把手伸到背后,拿出预先准备好的酒瓶,把{0}扁的是唏哩哗啦
\
69 | {0}对{1}施展了人体练成,把{1}变成了天真可爱小乌龟
\
70 | {1}用家传的小朋友捶胸拳娇柔的打向{0},
\
71 | {0}喊着:唉哟哟你打的人家好疼阿,娇喘几声以后倒地不起
\
72 | {0}用皮鞭抽打{1},凄惨的哀嚎声让隔壁老王都想来参一脚
\
73 | 经过一番激烈的战斗之后,{1}败下阵来,哭着去找妈妈'
74 | ,
75 | u'{0}对{1}告白,{1}受到了十分严重的精神伤害
\
76 | {1}使出了龟派气功,把{0}跟那美克星一起打爆,变成宇宙灰尘
\
77 | {0}用皮鞭抽打{1},{1}被鞭子打的遍体鳞伤,可是又有点舒服
\
78 | {1}对{0}告白,{0}受到了十分严重的精神伤害
\
79 | {0}一记漂亮的上勾拳,把{1}的假发打飞到擂台的边缘
\
80 | {1}开着砂石车往{0}辗过去,{0}被砂石车辗成豆腐乳
\
81 | {0}拿出了神秘的灵符,往{1}丟过去,{1}被灵符贴到额头以后动弹不得,只能任{0}对自己上下其手
\
82 | 经过一番激烈的战斗之后,{1}败下阵来,哭着去找自己的妈咪'
83 | ,
84 | u'{0}把手伸到背后,拿出预先准备好的酒瓶,把{1}扁的是唏哩哗啦
\
85 | {1}伸出左手的食指,用力的戳进{0}的鼻孔
\
86 | {0}一记漂亮的上勾拳,把{1}的花花可爱星星小短裤打飞到擂台的边缘
\
87 | {1}召唤巨大召唤兽巴哈姆特,巴哈姆特对{0}吐了一坨口水,{0}差点被淹死
\
88 | {0}拿出一颗手榴弹,塞进{1}的衣服里,把{1}的小可爱炸了个歪七扭八
\
89 | {1}肚子饿了,跟{0}手牵手一起去吃大餐,画面温馨感人
\
90 | {0}跟{1}合体,变成了宇宙最强的赛亚战士
\
91 | 经过一番激烈的战斗之后,{1}败下阵来,哭着去找自己的妈咪'
92 | ,
93 | u'{1}开着砂石车往{0}辗过去,{0}被砂石车辗成猪食。
\
94 | {0}使出了龟派气功,把{1}跟那美克星一起打爆,变成宇宙灰尘。
\
95 | {1}放出了魔法火球,烧掉了{0}的小裤裤,这让{0}十分害羞又开心。
\
96 | {0}拿出了男人必备的钻头,突破了{1}的天际。
\
97 | {1}跟{0}合体,变成了爱与正义的水手服战士。
\
98 | {0}听耶诞老人的话,一边施展金勾臂一边唱著「金勾臂~金勾臂~金勾殴了胃~」,
\
99 | {1}被金勾臂连击胃部,把昨天的早餐也吐了出来。
\
100 | {0}被击败了'
101 | ,
102 | u'{0}使用“无敌风火轮”攻击{1},{1}损失21点血
\
103 | {1}身子一颤,发出“暴雨梨花”射向{0}{0}损失22点血
\
104 | {1}掏出平底锅大力扔向{0}{0}损失21点血
\
105 | {1}一纵身,离地三尺,一招“万恶淫为手”攻击{0}{0}损失24点血
\
106 | {0}开始抽风突然发出一招“老太太无敌大臭脚”攻击{1},{1}损失23点血
\
107 | {0}使用“无敌风火轮”攻击{1},{1}损失26点血
\
108 | {1}身子一颤,发出“暴雨梨花”射向{0}{0}损失17点血
\
109 | {0}使用“无敌风火轮”攻击{1},损失25点血
\
110 | {0}突然一个后撤,发出乌龟冲击波攻击{1},{1}损失26点血
\
111 | {1}掏出平底锅大力扔向{0},{0}损失24点血
\
112 | {0}采用吐痰攻击,一口浓痰喷向{1}损失28点血
\
113 | {1}掏出平底锅大力扔向{0}{0}损失15点血
\
114 | {0}胜利,{1}被彻底击败了'
115 | ]
116 | self.centence =[
117 | u'{0}使出了龟派气功,把{1}跟那美克星一起打爆,变成宇宙灰尘
',
118 | u'{0}一记漂亮的上勾拳,把{1}的假发打飞到擂台的边缘。
',
119 | u'{0}听圣诞老人的話,一边施展金勾臂一边唱着「金勾臂~金勾臂~金勾毆了胃~」,悽凌的歌声让{1}开始后悔自己活在这个世界上。
',
120 | u'{0}叫來了太平洋上的台风,把{1}吹的是东倒西歪、尸橫遍野、血流成河,十分的涼爽。
',
121 | u'{0}把手伸到背后,拿出预先准备好的酒瓶,把{1}扁的是唏里哗啦。
',
122 | u'{0}拿出一颗手榴弹,塞进{1}的嘴里,把{1}炸了个歪七扭八。
',
123 | u'{0}跟{1}合体,变成了爱与正义的水手服战士。
',
124 | u'{0}说:「你要咖啡,茶,还是要我呢。」,{1}回答:「我想去死」
',
125 | u'{0}拿起霹雳神剑大喊「霹雳,霹雳,霹雳貓~」,然後把旁边的西瓜砸到{1}脸上。
',
126 | u'{0}对{1}告白,{1}受到了十分严重的精神伤害。
'
127 | ]
128 | # 名称 血量 经验 攻击力
129 | self.NPC = []
130 |
131 |
132 | def fight(self):
133 | # 随机一个NPC
134 | randomNPC = self.NPC[random.randint(0, len(self.NPC) - 1)]
135 | judge = random.randint(0, 15)
136 | self.outputProcess = ''
137 | # 随机剧本模式
138 | if judge > 13:
139 | if self.judgeWin(self.role, randomNPC):
140 | self.outputProcess = self.listProcess[random.randint(0, len(self.listProcess)-1)].format( self.role.name, randomNPC.name)
141 | self.expGet = randomNPC.experience
142 | else:
143 | self.outputProcess = self.listProcess[random.randint(0, len(self.listProcess)-1)].format(randomNPC.name, self.role.name)
144 | self.expGet = 0
145 | # 随机句子模式
146 | else:
147 | for num in range(0, 7):
148 | self.outputProcess = self.outputProcess + self.centence[random.randint(0, len(self.centence)-1)].format(randomNPC.name, self.role.name)
149 | if self.judgeWin(self.role, randomNPC):
150 | self.outputProcess = self.outputProcess + u'经过一番激烈的战斗之后,{0} 败下阵来'.format(randomNPC.name)
151 | self.expGet = randomNPC.experience
152 | else:
153 | self.outputProcess = self.outputProcess + u'经过一番激烈的战斗之后,{0} 败下阵来'.format(self.role.name)
154 | self.expGet = 0
155 |
156 | def getExperience(self):
157 | return self.expGet
158 |
159 | def getProcess(self):
160 | return self.outputProcess
161 |
162 |
163 | # 输赢判定
164 | def judgeWin(self, role1, role2):
165 | role1.health = role1.health - role2.attack
166 | role2.health = role2.health - role1.attack
167 | self.result = (role1.health > role2.health) and True or False
168 | return self.result
169 |
170 | def addNPC(self, name, health, vitality, attack):
171 | newNPC = Roles(name, health, vitality, attack)
172 | self.NPC.append(newNPC)
173 |
174 | def setRole(self, name, health, vitality, attack):
175 | self.role = Roles(name, health, vitality, attack)
176 |
177 | def getResult(self):
178 | return self.result
179 |
180 | if __name__ == '__main__':
181 | battle = Battle()
182 | # 血量 经验/蓝 攻击力
183 | battle.setRole(u'金科', 10, 50, 10)
184 | # 血量 经验/蓝 攻击力
185 | battle.addNPC(u'Boss', 10, 1000, 100)
186 | battle.fight()
187 | print battle.getProcess()
188 | print battle.getExperience()
189 | print (battle.getResult() == True ) and u'获胜' or u'失败'
190 |
--------------------------------------------------------------------------------
/bit_map.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # -*- coding: utf-8 -*-
3 | import random
4 |
5 |
6 | class Bit_Map:
7 | def __init__(self):
8 | self.points = [u'北校门',u'中食堂',u'良乡大学城北地铁站',u'南校门',u'理教',u'良乡大学城地铁站',
9 | u'物理实验室',u'化学实验室',u'操场',u'疏桐园',u'南食堂',
10 | u'博雅园',u'生物楼']
11 | self.lines = [[u'北校门',u'中食堂'],[u'中食堂',u'良乡大学城北地铁站'],[u'中食堂',u'南校门'],[u'南校门',u'理教'],
12 | [u'良乡大学城北地铁站',u'良乡大学城地铁站'],[u'理教',u'物理实验室'],[u'物理实验室',u'化学实验室'],
13 | [u'南校门',u'疏桐园'],[u'疏桐园',u'操场'],[u'操场',u'化学实验室'],[u'疏桐园',u'南食堂'],[u'操场',u'博雅园'],
14 | [u'南食堂',u'博雅园'],[u'博雅园',u'生物楼'],[u'南校门',u'操场']]
15 | self.birth_points = [u'疏桐园',u'博雅园']
16 | self.blood_points = [u'中食堂',u'南食堂']
17 |
18 | #返回地图所有位置
19 | def get_points(self):
20 | return self.points
21 |
22 | #返回出生点
23 | def get_birth_point(self, t = -1):
24 | if t == -1:
25 | return [u'疏桐园',u'博雅园']
26 | if t == 0:
27 | if random.randint(0,10) >= 5:
28 | return [u'疏桐园']
29 | else:
30 | return [u'博雅园']
31 | #判断name是否是出生点
32 | def is_birth_point(self,name):
33 | if name in self.birth_points:
34 | return True
35 | else:
36 | return False
37 |
38 | #返回回血点
39 | def get_blood_point(self):
40 | return self.blood_points
41 | #判断name是否是回血点
42 | def is_blood_point(self,name):
43 | if name in self.blood_points:
44 | return True
45 | else:
46 | return False
47 | #返回name的邻居节点名
48 | def get_point_neigh(self,name):
49 |
50 | if not name in self.points:
51 | return None
52 |
53 | point = []
54 | for ele in self.lines:
55 | if name in ele:
56 | if ele[0] == name:
57 | point.append(ele[1])
58 | elif ele[1] == name:
59 | point.append(ele[0])
60 | return point
61 |
62 |
63 | #打印地图 测试
64 | def porint_map(self):
65 | point = map.get_points()
66 | for ele1 in point:
67 | print ele1,'******'
68 | p = map.get_point_neigh(ele1)
69 | for ele2 in p:
70 | print ele2
71 | if __name__ == '__main__':
72 | map = Bit_Map()
73 |
--------------------------------------------------------------------------------
/bit_map2.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # -*- coding: utf-8 -*-
3 | import random
4 |
5 |
6 | class Bit_Map:
7 | def __init__(self):
8 | # 良乡地图
9 | self.points = [u'北校门',u'中食堂',u'良乡大学城北地铁站',u'南校门',u'理教',u'良乡大学城地铁站',
10 | u'物理实验室',u'化学实验室',u'操场',u'疏桐园',u'南食堂',
11 | u'博雅园',u'生物楼']
12 |
13 | # 中关村地图
14 | self.points2 = [u'6号教学楼',u'软件楼',u'1食堂',u'教工餐厅',u'远志楼',u'校医院',u'实验区',
15 | u'10号办公楼',u'求是楼',u'3号教学楼',u'2号办公楼',u'1号教学楼',
16 | u'体育馆',u'中心教学楼',u'中心花园',u'主楼',u'东门',u'地铁站',
17 | u'7号教学楼',u'号教学楼',u'图书馆',u'5号教学楼',
18 | u'1号学生公寓',u'8号教学楼']
19 |
20 | #良乡路线
21 | self.lines = [[u'北校门',u'中食堂'],[u'中食堂',u'良乡大学城北地铁站'],[u'中食堂',u'南校门'],[u'南校门',u'理教'],
22 | [u'良乡大学城北地铁站',u'良乡大学城地铁站'],[u'理教',u'物理实验室'],[u'物理实验室',u'化学实验室'],
23 | [u'南校门',u'疏桐园'],[u'疏桐园',u'操场'],[u'操场',u'化学实验室'],[u'疏桐园',u'南食堂'],[u'操场',u'博雅园'],
24 | [u'南食堂',u'博雅园'],[u'博雅园',u'生物楼'],[u'南校门',u'操场']]
25 |
26 | #中关村路线
27 |
28 | self.lines2 = [[u'软件楼',u'6号教学楼'],[u'软件楼',u'1食堂'],[u'1食堂',u'京工餐厅'],
29 | [u'京工餐厅',u'远志楼'],[u'远志楼',u'校医院'],[u'校医院',u'试验区'],
30 | [u'京工餐厅',u'10号楼'],[u'远志楼',u'求是楼'],[u'校医院',u'3号教学楼'],
31 | [u'实验区',u'2号办公楼'],[u'10号办公楼',u'求是楼'],[u'求是楼',u'3号教学楼'],
32 | [u'3号教学楼',u'2号办公楼'],[u'2号办公楼',u'1号教学楼'],[u'10号办公楼',u'体育馆'],
33 | [u'求是楼',u'中心教学楼'],[u'3号教学楼',u'中心教学楼'],[u'1号教学楼',u'主楼'],
34 | [u'体育馆',u'中心教学楼'],[u'中心教学楼',u'中心花园'],[u'中心花园',u'主楼'],
35 | [u'主楼',u'东门'],[u'东门',u'地铁站'],[u'中心教学楼',u'4号教学楼'],
36 | [u'主楼',u'5号教学楼'],[u'7号教学楼',u'4号教学楼'],[u'4号教学楼',u'图书馆'],
37 | [u'图书馆',u'5号教学楼'],[u'7号教学楼',u'1号学生公寓'],[u'7号教学楼',u'8号教学楼'],
38 | [u'1号学生公寓',u'8号教学楼'],[u'1号学生公寓',u'南门'],[u'南门烤翅',u'南门']
39 |
40 | ]
41 |
42 | #self.birth_points = [u'疏桐园',u'博雅园']
43 | self.birth_points = [u'疏桐园']
44 | self.blood_points = [u'中食堂',u'南食堂']
45 |
46 | self.birth_points2 = [u'1号学生公寓']
47 | self.blood_points2 = [u'京工餐厅',u'校医院',u'1食堂',u'南门烤翅']
48 |
49 | #返回地图所有位置
50 | def get_points(self,t = -1):
51 | if t == -1:
52 | return self.points
53 | else:
54 | return self.points2
55 |
56 | #返回出生点
57 | def get_birth_point(self, t = -1):
58 | if t == -1:
59 | return self.birth_points
60 | else:
61 | return self.birth_points2
62 |
63 | #判断name是否是出生点
64 | def is_birth_point(self,name,t = -1):
65 | if t == -1:
66 | if name in self.birth_points:
67 | return True
68 | else:
69 | return False
70 | else:
71 | if name in self.birth_points2:
72 | return True
73 | else:
74 | return False
75 |
76 | #返回回血点
77 | def get_blood_point(self,t = -1):
78 | if t == -1:
79 | return self.blood_points
80 | else:
81 | return self.blood_points2
82 | #判断name是否是回血点
83 | def is_blood_point(self,name,t = -1):
84 | if t == -1:
85 |
86 | if name in self.blood_points:
87 | return True
88 | else:
89 | return False
90 |
91 | else:
92 |
93 | if name in self.blood_points:
94 | return True
95 | else:
96 | return False
97 | #返回name的邻居节点名
98 | def get_point_neigh(self,name, t = -1):
99 | if t == -1:
100 | if not name in self.points:
101 | return None
102 |
103 | point = []
104 | for ele in self.lines:
105 | if name in ele:
106 | if ele[0] == name:
107 | point.append(ele[1])
108 | elif ele[1] == name:
109 | point.append(ele[0])
110 | return point
111 | else:
112 | if not name in self.points:
113 | return None
114 |
115 | point = []
116 | for ele in self.lines:
117 | if name in ele:
118 | if ele[0] == name:
119 | point.append(ele[1])
120 | elif ele[1] == name:
121 | point.append(ele[0])
122 | return point
123 |
124 |
125 | #打印地图 测试
126 | def porint_map(self,t = -1):
127 | if t == -1:
128 | point = map.get_points(t)
129 | for ele1 in point:
130 | print ele1,'******'
131 | p = map.get_point_neigh(ele1)
132 | for ele2 in p:
133 | print ele2
134 | else:
135 | point = map.get_points(t)
136 | for ele1 in point:
137 | print ele1,'******'
138 | p = map.get_point_neigh(ele1)
139 | for ele2 in p:
140 | print ele2
141 |
142 | def print_story(self,name):
143 | if name == u'软件楼':
144 | strr = u'北理最有名的鬼楼就是红楼了。红楼在5系系楼的后面,一片草丛之中十几棵百年老松拱卫着的两层红砖楼就是'
145 | strr+= u'红楼了。 \n在北理5系上了三年学都不知道这么一个教学楼的存在,因为一方面它太隐秘,另一方面它是成教的'
146 | strr+= u'课堂。 \n终于在大四知道它的存在是因为实习的缘故。实习的时候终于可以有了老师办公室的钥匙,也终于可'
147 | strr+= u'以在老师加班都走了以后,仍然可以留在办公室里。不是加班,是玩警察抓小偷,一个老掉牙的经典电脑游戏,'
148 | strr+= u'一个和俄罗斯方块同时代的游戏。 \n我玩游戏是很专注的,能把我从游戏中惊起的声音自然是很大的。那天深'
149 | strr+= u'夜风很大,想必是哪个教室的窗户被风吹得咣当而破。我从桌上抬起头,突然看见窗外两个眼睛正定定地看着我。'
150 | strr+= u' \n外面一片漆黑,风仍然在呜呜地咆哮,什么都没有,没有四肢,没有身体,也没有脸,只有两只眼!!!我全'
151 | strr+= u'身的血往头上涌,虽然身子仍钉在椅子上,心脏却使劲往后躲,似乎想跑出我的身体,找个旮旯躲起来。 \n看到我'
152 | strr+= u'抬头看它,那眼睛开始漂移,忽然就不见了。我缓过劲来,眨了眨眼,看见对面那个楼的二楼还亮着两盏灯。我不'
153 | strr+= u'禁有些疑惑,刚才是不是看花眼了? \n第二天白天,为了验证是不是花了眼,我叫了两个同学来到红楼。上了二楼,'
154 | strr+= u'正对楼梯的教室里玻璃撒了一地,应该是昨晚的那声音。从窗户望外望去,刚好可以看到我昨晚呆的办公室。那么那'
155 | strr+= u'两盏灯应该也是这个教室的了。知道没有鬼,我心里放松了许多。 \n中午吃饭时,同做一张桌的'
156 | if name == u'1号学生公寓':
157 | strr = u'我在三号楼住的四年里见证了多场北理北外男生之间的口水战,但是最经典那场还是04年'
158 | strr+= u'那次。那次的导火索是由于北外男生的挑衅,大声叫喊北理女生丑。我X,北理女生在北理'
159 | strr+= u'男生心目中可是神圣不可侵犯的,他们敢骂我们的女生那可恨之极简直比骂我们男生自己还'
160 | strr+= u'不可饶恕。广大北理男生在这个原则上保持了高度的统一后开始反击,于是双方骂娘的,问'
161 | strr+= u'候爹妈以及十八代祖宗的都出现了,两边吵吵嚷嚷已经乱成了一锅粥,酒瓶早已经准备好'
162 | strr+= u'了,但是一扔酒瓶警车就来,所以就等合适的时机吹冲锋号冲锋了。'
163 | if name == u'南操场':
164 | strr = u'北院为禁地,闲杂人等不得入内'
165 | strr+= u'此处成为禁地的原因得从作者大二的那个春天说起'
166 | strr+= u'北湖曾经一个美好的地方,有天鹅有小桥,景色别致'
167 | strr+= u'但是就在那个春天,发生了可怕的事情'
168 | strr+= u'此处马赛克……详情请自行百度'
169 | strr+= u'禁言禁语'
170 | if name == u'食堂':
171 | strr = u'北理的食堂是卫生评级为A的食堂\n'
172 | strr+= u'也是冒险爱好者复活的圣地\n'
173 | strr+= u'进入食堂后请谨慎选择食物,同时冒险者也有可能得到传中的黑暗料理\n'
174 | strr+= u'或者绝对新鲜的的节肢动物料理\n'
175 | strr+= u'此处设定为回血地点,但是请冒险者在现实中不要轻易尝试,正常情况下会得到满血复活的良好效果,或者遭受巫师或术士的攻击得到继续的中毒效果,持续时间最长为1星期,攻击名为食物中毒'
176 | if name ==u'南门':
177 | strr = u'走出小南门就可以见到传说中的南门烤翅了\n'
178 | strr += u'南门烤翅为北理长久以来永垂不朽的一完美回血点之一,这就是打广告!!!!(此处广告位招商)\n'
179 | strr += u'请特定时间小心经过,此处为校园外围环境,危险系数高,会遇到各种快递员,小摊贩,醉酒男醉酒女或醉酒大叔大妈级人物,请冒险者小心'
180 | strr += u'请尽量避开与北外口水战时间,小心误伤=。=……如果遇到意外或尴尬问题请大喊我是北航的自可化解一切危机。'
181 |
182 |
183 | if __name__ == '__main__':
184 | map = Bit_Map()
185 |
186 |
--------------------------------------------------------------------------------
/config.yaml:
--------------------------------------------------------------------------------
1 | name: dayBit
2 | version: 3
3 |
4 | worker: tornado
5 |
--------------------------------------------------------------------------------
/dayBit.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # -*- coding: utf-8 -*-
3 |
4 | import md5
5 | import re
6 | import os
7 | import datetime, time
8 | import cgi
9 | import random
10 |
11 | import bit_map
12 | import battle
13 |
14 | from settings import saedb
15 |
16 | import tornado.web
17 | import tornado.database
18 | from tornado.httpclient import AsyncHTTPClient
19 |
20 |
21 |
22 | class BaseHandler(tornado.web.RequestHandler):
23 | @property
24 | def db(self):
25 | dayBitdb = tornado.database.Connection(
26 | host = saedb['host'] + ":" + saedb['port'],
27 | database = saedb['db'],
28 | user = saedb['user'],
29 | password = saedb['password']
30 | )
31 | return dayBitdb
32 |
33 | def get_current_user(self):
34 | usrid = self.get_secure_cookie('usrid')
35 | if not usrid:
36 | return None
37 | me = self.db.get('select * from usertable where usrid = %s', usrid)
38 | return me
39 |
40 |
41 |
42 | def getRoleValue(self):
43 | usrid = self.current_user.usrid
44 | typeToName = {1:u'学神', 2:u'大牛', 3:u'弱菜'}
45 | roletableValue = self.db.query("select * from roletable where usrid = %s", usrid)
46 | roleValue = dict()
47 |
48 | roleValue['roleTypeID'] = roletableValue[0]['roletype']
49 | roleValue['roleType'] = typeToName[roleValue['roleTypeID']]
50 | roleValue['roleNick'] = roletableValue[0]['rolenick']
51 | roleValue['roleID'] = roletableValue[0]['roleid']
52 | roleValue['rolePostion'] = self.getPostionNow(roleValue['roleID'])
53 |
54 | attrValue = self.getAttrValue(roleValue['roleID'])
55 |
56 | roleValue['roleRank'] = attrValue['rank']
57 | roleValue['roleBaseHpVal'] = attrValue['hpval']
58 | roleValue['roleBaseMpVal'] = attrValue['mpval']
59 | roleValue['roleExpVal'] = attrValue['expval']
60 | roleValue['roleBaseAttVal'] = attrValue['attval']
61 |
62 | equValue = self.getEquValue(roleValue['roleID'])
63 |
64 | roleValue['coatName'] = equValue['coatName']
65 | roleValue['coatAttr'] = equValue['coatAttr']
66 |
67 | roleValue['laptopName'] = equValue['laptopName']
68 | roleValue['laptopAttr'] = equValue['laptopAttr']
69 |
70 | roleValue['bookName'] = equValue['bookName']
71 | roleValue['bookAttr'] = equValue['bookAttr']
72 |
73 | roleValue['bagName'] = equValue['bagName']
74 | roleValue['bagAttr'] = equValue['bagAttr']
75 |
76 | equList = ['coatAttr', 'laptopAttr', 'bookAttr', 'bagAttr']
77 |
78 | roleValue['roleHpVal'] = roleValue['roleBaseHpVal']
79 | roleValue['roleMpVal'] = roleValue['roleBaseMpVal']
80 | roleValue['roleAttVal'] = roleValue['roleBaseAttVal']
81 |
82 | for equ in equList:
83 | roleValue['roleHpVal'] += roleValue[equ]['dthp']
84 | roleValue['roleMpVal'] += roleValue[equ]['dtmp']
85 | roleValue['roleAttVal'] += roleValue[equ]['dtatt']
86 |
87 | fixedValue = self.getFixedValue(str(roleValue['roleTypeID']), roleValue['roleRank'])
88 | roleValue['roleExpNeed'] = fixedValue['exptonext']
89 |
90 | roleValue['roleBagID'] = self.getBagID(roleValue['roleID'])
91 |
92 |
93 | return roleValue
94 |
95 | def getBagID(self, roleID):
96 | bagID = self.db.query("select * from bagbelong where roleid = %s", roleID)
97 | bagID = bagID[0]['bagid']
98 | return bagID
99 |
100 | def getPostionNow(self, roleID):
101 | postionNowID = self.db.query("select locid from roleloc where roleid = %s", roleID)
102 | postionNowID = postionNowID[0]['locid']
103 | postionNow = self.db.query("select locname from loccata where locid = %s", postionNowID)
104 | postionNow = postionNow[0]['locname']
105 | return postionNow
106 |
107 | def getAttrValue(self, roleID):
108 | attrtableValue = self.db.query("select * from roleattr where roleid = %s", roleID)
109 | attrValue = attrtableValue[0]
110 | return attrValue
111 |
112 | def getEquValue(self, roleID):
113 | equIDValue = self.db.query("select * from roleequ where roleid = %s", roleID)
114 | coatid = equIDValue[0]['coatid']
115 | laptopid = equIDValue[0]['laptopid']
116 | bookid = equIDValue[0]['bookid']
117 | bagid = equIDValue[0]['bagid']
118 |
119 | equValue = dict()
120 |
121 | coatName = self.db.query("select * from itemcata where itemid = %s", coatid)
122 | equValue['coatName'] = coatName[0]['itemname']
123 | laptopName = self.db.query("select * from itemcata where itemid = %s", laptopid)
124 | equValue['laptopName'] = laptopName[0]['itemname']
125 | bookName = self.db.query("select * from itemcata where itemid = %s", bookid)
126 | equValue['bookName'] = bookName[0]['itemname']
127 | bagName = self.db.query("select * from itemcata where itemid = %s", bagid)
128 | equValue['bagName'] = bagName[0]['itemname']
129 |
130 | coatAttr = self.db.query("select * from equdelt where itemid = %s", coatid)
131 | equValue['coatAttr'] = coatAttr[0]
132 | laptopAttr = self.db.query("select * from equdelt where itemid = %s", laptopid)
133 | equValue['laptopAttr'] = laptopAttr[0]
134 | bookAttr = self.db.query("select * from equdelt where itemid = %s", bookid)
135 | equValue['bookAttr'] = bookAttr[0]
136 | bagAttr = self.db.query("select * from equdelt where itemid = %s", bagid)
137 | equValue['bagAttr'] = bagAttr[0]
138 |
139 | return equValue
140 |
141 |
142 | def getFixedValue(self, roleType, roleRank):
143 | #formFromRoleType = {'1':u'xueshenrank','2':u'daniurank','3':u'ruocairank'}
144 | if roleType == '1':
145 | answer = self.db.query("select * from xueshenrank where rank = %s",roleRank)
146 | #answer = (formFromRoleType[str(roleType)], str(roleRank))
147 | elif roleType == '2':
148 | answer = self.db.query("select * from daniurank where rank = %s",roleRank)
149 | elif roleType == '3':
150 | answer = self.db.query("select * from ruocairank where rank = %s",roleRank)
151 | fixedValue = answer[0]
152 | return fixedValue
153 |
154 |
155 | class IndexHandler(BaseHandler):
156 | def get(self):
157 | self.render("index.html", signUpInfo = [])
158 |
159 | class SignUpHandler(BaseHandler):
160 | def post(self):
161 | info = dict()
162 | info['name'] = self.get_argument('name', '')
163 | info['password'] = self.get_argument('password','')
164 | info['password'] = md5.new(info['password']).hexdigest()
165 | userNum = len(self.db.query('select * from usertable'))
166 | info['usrid'] = 100000 + userNum
167 | info['usrtype'] = 1
168 |
169 | if self.checkName(info):
170 | signUpInfo = [u'注册成功,请登录。']
171 | self.db.execute("insert into usertable (usrname, usrid, pwd, usrtype) values (%s, %s, %s, %s)",
172 | info['name'], info['usrid'], info['password'], info['usrtype'])
173 | else:
174 | signUpInfo = [u'用户名已存在,请直接登录。']
175 | self.render('index.html', signUpInfo = signUpInfo)
176 |
177 | def checkName(self, info):
178 | nameExist = self.db.get("select * from usertable where usrname = %s", info['name'])
179 | if nameExist or (len(info['name']) >= 15):
180 | return False
181 | else :
182 | return True
183 |
184 | class SignInHandler(BaseHandler):
185 | def post(self):
186 | info = dict()
187 | info['name'] = self.get_argument('name', '')
188 | info['password'] = self.get_argument('password','')
189 | userID = self.checkUser(info)
190 | if userID:
191 | self.set_secure_cookie('usrid', str(userID))
192 | self.redirect('/chooseRole')
193 | else:
194 | signUpInfo = [u'用户名或密码错误。']
195 | self.render('index.html', signUpInfo = signUpInfo)
196 |
197 | def checkUser(self, info):
198 | user = self.db.get("select * from usertable where usrname = %s", info['name'])
199 | if user:
200 | password = md5.new(info['password']).hexdigest()
201 | if password == user.pwd:
202 | return user.usrid
203 | else:
204 | return False
205 | else:
206 | return False
207 |
208 | class ChooseRoleHandler(BaseHandler):
209 | def get(self):
210 | if self.current_user:
211 | roleList = self.db.query('select * from roletable where usrid = %s', str(self.current_user.usrid))
212 | self.render('choice.html', roleList = roleList)
213 | else:
214 | self.redirect('/')
215 |
216 | class AddRoleHandler(BaseHandler):
217 | def post(self):
218 | info = dict()
219 | info['roletype'] = self.get_argument('roletype', '')
220 | info['rolenick'] = self.get_argument('rolenick', '')
221 |
222 | roleNum = len(self.db.query('select * from roletable'))
223 | info['roleid'] = 100000 + roleNum
224 |
225 | bagNum = len(self.db.query("select * from bagbelong"))
226 | info['bagid'] = 100000 + bagNum
227 |
228 | info['usrid'] = self.current_user.usrid
229 | if not self.db.query("select * from roletable where usrid = %s", info['usrid']):
230 | #message = [info]
231 | #self.render('test.html', message = message)
232 | roleValue = BaseHandler.getFixedValue(self, info['roletype'], '1')
233 | self.db.execute("insert into roletable (roleid, usrid, roletype, rolenick) values (%s, %s, %s, %s)",
234 | info['roleid'], info['usrid'], info['roletype'], info['rolenick'])
235 | self.db.execute("insert into roleloc (roleid, locid) values (%s, %s)", info['roleid'], 1)
236 | self.db.execute("insert into roleattr (roleid, hpval, mpval, expval, attval, rank) values (%s, %s, %s, %s, %s, %s)",
237 | info['roleid'], roleValue['hpval'], roleValue['mpval'], 0, roleValue['att'], roleValue['rank'])
238 | self.db.execute("insert into roleequ (roleid, coatid, laptopid, bookid, bagid) values (%s, %s, %s, %s, %s)",
239 | info['roleid'], 1, 39, 53, 82)
240 | self.db.execute("insert into bagbelong (roleid, bagid) values (%s, %s)",
241 | info['roleid'], info['bagid'])
242 | self.db.execute("insert into achiv (roleid, killenemy, killedbyenemy, getequip, totalexp) values (%s, %s, %s, %s, %s)",
243 | info['roleid'], 0, 0, 0, 0)
244 | self.redirect('/chooseRole')
245 |
246 |
247 | class DeleteRoleHandler(BaseHandler):
248 | def get(self):
249 | usrid = self.current_user.usrid
250 | #self.db.execute("delete from roletable set usrid = 0 where usrid = %s", usrid)
251 | self.db.execute("update roletable set usrid = 8088 where usrid = %s", usrid)
252 | self.redirect('/chooseRole')
253 |
254 | class MainHandler(BaseHandler):
255 | def get(self):
256 | if self.current_user:
257 | roleList = self.db.query('select * from roletable where usrid = %s', str(self.current_user.usrid))
258 | self.render('main.html', roleList = roleList)
259 | else:
260 | self.redirect('/')
261 |
262 | def post(self):
263 | usrid = self.current_user.usrid
264 | roletableValue = self.db.query("select * from roletable where usrid = %s", usrid)
265 | orderContent = self.get_argument('orderContent','').strip()
266 | bitmap = bit_map.Bit_Map()
267 | roleValue = BaseHandler.getRoleValue(self)
268 | #self.render('test.html', message = orderContent)
269 | #self.write(orderContent)
270 | if orderContent == u'帮助':
271 | answerStrList = [
272 | '1. 输入「开始」开始游戏
',
273 | '2. 输入「现在」查看角色目前位置
',
274 | '3. 输入「周围」查看角色周围地点
',
275 | '4. 输入「去##」让角色移动到 ##
',
276 | '5. 输入「所有」查看地图的所有位置
',
277 | '6. 输入「装备」查看角色身上装备
',
278 | '7. 输入「属性」查看角色各项属性值
',
279 | '8. 输入「背包」查看角色背包
',
280 | '9. 输入「穿##」让角色穿上某件装备
'
281 | ]
282 | for answerStr in answerStrList:
283 | self.write(answerStr)
284 |
285 | elif orderContent == u'开始':
286 | #answerStr = str(roleValue)
287 | answerStr = roleValue['roleType'] + ' ' + roleValue['roleNick'] + u' 您好,您现在在' +roleValue['rolePostion'] + u'。
'
288 | answerStr += u'角色等级为 ' + str(roleValue['roleRank']) + u' 级。
'
289 | answerStr += u'角色属性为: 血量:' + str(roleValue['roleHpVal']) + u',蓝量:' + str(roleValue['roleHpVal']) + u',攻击力:' + str(roleValue['roleAttVal']) + u',经验值:' + str(roleValue['roleExpVal']) + u'。
'
290 | answerStr += u'装备为: 外套:' + roleValue['coatName'] + u',电脑:' + roleValue['laptopName'] + u', 书本:' + roleValue['bookName'] + u',背包:' + roleValue['bagName']
291 | self.write(answerStr)
292 |
293 | elif orderContent == u'装备':
294 | answerStr = u'外套:' + roleValue['coatName'] + u',电脑:' + roleValue['laptopName'] + u', 书本:' + roleValue['bookName'] + u',背包:' + roleValue['bagName']
295 | self.write(answerStr)
296 |
297 | elif orderContent == u'属性':
298 | answerStr = u'等级:'+ str(roleValue['roleRank']) + u',血量:' + str(roleValue['roleHpVal']) + u',蓝量:' + str(roleValue['roleHpVal']) + u',攻击力:' + str(roleValue['roleAttVal']) + u',经验值:' + str(roleValue['roleExpVal'])
299 | self.write(answerStr)
300 |
301 | elif orderContent == u'现在':
302 | postionNow = roleValue['rolePostion']
303 | answerStr = u'现在您在' + postionNow
304 | self.write(answerStr)
305 |
306 | elif orderContent == u'周围':
307 | postionNow = roleValue['rolePostion']
308 | neighPostions = bitmap.get_point_neigh(postionNow)
309 | answerStr = u'您现在可以去:'
310 | for neighPostion in neighPostions:
311 | answerStr = answerStr + neighPostion +' '
312 | self.write(answerStr)
313 |
314 | elif orderContent == u'背包':
315 | bagID = roleValue['roleBagID']
316 | bagItem = self.db.query("select * from bagitem where bagid = %s", bagID)
317 | itemValue = dict()
318 | if bagItem:
319 | for item in bagItem:
320 | itemID = item['itemid']
321 | itemName = self.db.query("select * from itemcata where itemid = %s", itemID)
322 | itemValue[itemID] = itemName[0]['itemname']
323 |
324 | answerStr = u''
325 |
326 | for (itemID, itemName) in itemValue.items():
327 | #answerStr += str(itemID) + u' : ' + str(itemName) + u' '
328 | answerStr += str(itemID) + u':' + itemName + ' '
329 | else:
330 | answerStr = u'您的背包空无一物,快去刷刷刷!'
331 | self.write(answerStr)
332 |
333 | elif orderContent[:1] == u'穿':
334 | equToWearID = orderContent[1:]
335 | if self.db.query("select * from bagitem where bagid = %s and itemid = %s", roleValue['roleBagID'], equToWearID):
336 | #self.write('dfads')
337 |
338 | equToWearType = self.db.query("select * from itemcata where itemid = %s", equToWearID)
339 | equToWearType = equToWearType[0]['itemtype']
340 | typeToName = {'1':'coatid', '2':'laptopid', '3':'bookid', '4':'bagid'}
341 | equNow = self.db.query("select * from roleequ where roleid = %s", roleValue['roleID'])
342 | equNowID = equNow[0][typeToName[str(equToWearType)]]
343 | self.db.execute("update roleequ set {0} = %s where roleid = %s".format(typeToName[str(equToWearType)]),
344 | equToWearID, roleValue['roleID'])
345 | self.db.execute("delete from bagitem where bagid = %s and itemid = %s",
346 | roleValue['roleBagID'], equToWearID)
347 |
348 | if not self.db.query("select * from bagitem where bagid = %s and itemid = %s", roleValue['roleBagID'], equNowID):
349 | self.db.execute("insert into bagitem (bagid, itemid) values (%s, %s)", roleValue['roleBagID'], equNowID)
350 |
351 | self.write(u'装备已换上')
352 |
353 | else:
354 | self.write(u'你还没有该装备')
355 |
356 | elif orderContent[:1] == u'去':
357 | postionNow = roleValue['rolePostion']
358 | neighPostions = bitmap.get_point_neigh(postionNow)
359 | postionToGo = orderContent[1:]
360 | if postionToGo in neighPostions:
361 | if random.choice([1,1,0]):
362 | monsValue = self.getMonsValue()
363 |
364 | fight = battle.Battle()
365 | fight.setRole(roleValue['roleNick'], int(roleValue['roleHpVal']), int(roleValue['roleMpVal']), int(roleValue['roleAttVal']))
366 | fight.addNPC(monsValue['monsName'], monsValue['monsHp'], monsValue['monsExp'], monsValue['monsAtt'])
367 | fight.fight()
368 | fightStr = fight.getProcess()
369 | #expGet = fight.getExperience()
370 | resultStr = fight.getResult()
371 |
372 | answerStr = u'哈哈!您遇到了一只野生的 ' + monsValue['monsName'] + ' !
'
373 | self.write(answerStr)
374 | self.write(fightStr)
375 | if fight.getResult():
376 |
377 | killenemy = self.db.query("select killenemy from achiv where roleid = %s", roleValue['roleID'])
378 | killenemyNum = killenemy[0]['killenemy'] + 1
379 | self.db.execute("update achiv set killenemy = %s where roleid = %s", killenemyNum, roleValue['roleID'])
380 |
381 | #获取掉落
382 | if random.choice([1,1,1,0]):
383 | equDropID = random.randint(1, 98)
384 | equDropName = self.db.query("select * from itemcata where itemid = %s", equDropID)
385 | equDropName = equDropName[0]['itemname']
386 | if self.db.query("select * from bagitem where bagid = %s and itemid = %s",roleValue['roleBagID'], equDropID):
387 | pass
388 | else:
389 | getequip = self.db.query("select getequip from achiv where roleid = %s", roleValue['roleID'])
390 | getequipNum = getequip[0]['getequip'] + 1
391 | self.db.execute("update achiv set getequip = %s where roleid = %s", getequipNum, roleValue['roleID'])
392 |
393 | self.db.execute("insert into bagitem (bagid, itemid) values (%s, %s)",
394 | roleValue['roleBagID'], equDropID)
395 | answerStr = u'
怪物掉落了 ' + equDropName
396 | self.write(answerStr)
397 |
398 | else:
399 | self.write(u'怪物什么也没掉落')
400 |
401 | #获取经验
402 | expGet = fight.getExperience()
403 |
404 | totalexp = self.db.query("select totalexp from achiv where roleid = %s", roleValue['roleID'])
405 | totalexpNum = totalexp[0]['totalexp'] + expGet
406 | self.db.execute("update achiv set totalexp = %s where roleid = %s", totalexpNum, roleValue['roleID'])
407 |
408 |
409 | roleExpNow = roleValue['roleExpVal'] + expGet
410 | if roleExpNow >= roleValue['roleExpNeed']:
411 | roleRankNow = roleValue['roleRank'] + 1
412 | roleExpNow -= roleValue['roleExpNeed']
413 | roleFixedValue = BaseHandler.getFixedValue(self, str(roleValue['roleTypeID']), roleRankNow)
414 | self.db.execute("update roleattr set hpval = %s, mpval = %s, expval = %s, attval = %s, rank = %s where roleid = %s",
415 | roleFixedValue['hpval'], roleFixedValue['mpval'], roleExpNow, roleFixedValue['att'], roleRankNow, roleValue['roleID'])
416 | else:
417 | self.db.execute("update roleattr set expval = %s where roleid = %s",
418 | roleExpNow, roleValue['roleID'])
419 | self.write(u'
你赢了!
')
420 |
421 | postionToGo = orderContent[1:]
422 | postionToGoID = self.db.query("select locid from loccata where locname = %s", postionToGo)
423 | postionToGoID = str(postionToGoID[0]['locid'])
424 | self.db.execute("update roleloc set locid = %s where roleid = %s", postionToGoID ,roleValue['roleID'])
425 | answerStr = u'现在您在' + postionToGo
426 | self.write(answerStr)
427 | else :
428 | killedbyenemy = self.db.query("select killedbyenemy from achiv where roleid = %s", roleValue['roleID'])
429 | killedbyenemyNum = killedbyenemy[0]['killdebyenemy'] + 1
430 | self.db.execute("update achiv set killedbyenemy = %s where roleid = %s", killedbyenemyNum, roleValue['roleID'])
431 |
432 |
433 | self.db.execute("update roleloc set locid = 1 where roleid = %s", roleValue['roleID'])
434 | self.write(u'
你被打败了,已经回到出生点!
')
435 | else:
436 | self.write(u'没遇见怪物
')
437 | postionToGo = orderContent[1:]
438 | postionToGoID = self.db.query("select locid from loccata where locname = %s", postionToGo)
439 | postionToGoID = str(postionToGoID[0]['locid'])
440 | self.db.execute("update roleloc set locid = %s where roleid = %s", postionToGoID ,roleValue['roleID'])
441 | answerStr = u'现在您在' + postionToGo
442 | self.write(answerStr)
443 | else:
444 | self.write(u'你现在不能去那')
445 |
446 | elif orderContent == u'所有':
447 | allPostion = bitmap.get_points()
448 | answerStr = u'所有地点如下:'
449 | for postion in allPostion:
450 | answerStr = answerStr + postion + ' '
451 | self.write(answerStr)
452 |
453 | elif orderContent == u'测试':
454 | #answerStr = self.db.query("select itemcata.itemtype, equdelt.itemrank from itemcata, equdelt where itemid = 1")
455 | answerStr = 'adsfds'
456 | self.write(str(answerStr))
457 |
458 | else :
459 | answerStr = u'别乱输命令!'
460 | self.write(answerStr)
461 |
462 | def getMonsValue(self):
463 | monsValue = dict()
464 | monsValue['monsID'] = random.randint(1,14)
465 | monsName = self.db.query("select * from monscata where monsid = %s", monsValue['monsID'])
466 | monsValue['monsName'] = monsName[0]['monsname']
467 | monsAttr = self.db.query("select * from monsattr where monsid = %s", monsValue['monsID'])
468 | monsValue['monsHp'] = monsAttr[0]['monshp']
469 | monsValue['monsAtt'] = monsAttr[0]['monsatt']
470 | monsValue['monsExp'] = monsAttr[0]['monsexp']
471 | return monsValue
472 |
473 |
474 |
475 |
476 |
477 |
478 |
479 |
480 |
481 | class SignOutHandler(BaseHandler):
482 | def get(self):
483 | self.clear_cookie("usrid")
484 | self.redirect("/")
485 |
486 |
487 | class ShowFormsHandler(BaseHandler):
488 | def get(self):
489 | info = dict()
490 | roleValue = BaseHandler.getRoleValue(self)
491 | roleid = roleValue['roleID']
492 | info['roleName'] = roleValue['roleNick']
493 | achiv = self.db.query("select * from achiv where roleid = %s", roleid)
494 | achivInfo = achiv[0]
495 | info['roleKillEnemy'] = achivInfo['killenemy']
496 | info['roleKilledByEnemy'] = achivInfo['killedbyenemy']
497 | info['roleGetEquip'] = achivInfo['getequip']
498 | info['roleTotalExp'] = achivInfo['totalexp']
499 | self.render("report.html", info = info)
500 |
--------------------------------------------------------------------------------
/index.wsgi:
--------------------------------------------------------------------------------
1 | import tornado.web
2 | from tornado.httpclient import AsyncHTTPClient
3 |
4 | from urls import urls
5 | from settings import settings
6 |
7 | application = tornado.web.Application(urls, **settings)
--------------------------------------------------------------------------------
/settings.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # -*- coding: utf-8 -*-
3 |
4 | import os.path
5 | import sae.const
6 |
7 | settings = {
8 | "static_path" : os.path.join(os.path.dirname(__file__), "static"),
9 | "template_path" : os.path.join(os.path.dirname(__file__), "templates"),
10 | "cookie_secret" : "JVixFqkpQ9i8gdDJb3Zx0i/Wos5aqUZKtnDCM2mecFc=",
11 | "debug":True,
12 | }
13 |
14 |
15 | saedb = {
16 | "host": sae.const.MYSQL_HOST,
17 | "db": sae.const.MYSQL_DB,
18 | "port": sae.const.MYSQL_PORT,
19 | "user": sae.const.MYSQL_USER,
20 | "password": sae.const.MYSQL_PASS,
21 | }
--------------------------------------------------------------------------------
/static/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/.DS_Store
--------------------------------------------------------------------------------
/static/css/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/css/.DS_Store
--------------------------------------------------------------------------------
/static/css/bootstrap-theme.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap v3.2.0 (http://getbootstrap.com)
3 | * Copyright 2011-2014 Twitter, Inc.
4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
5 | */
6 |
7 | .btn-default,
8 | .btn-primary,
9 | .btn-success,
10 | .btn-info,
11 | .btn-warning,
12 | .btn-danger {
13 | text-shadow: 0 -1px 0 rgba(0, 0, 0, .2);
14 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
15 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
16 | }
17 | .btn-default:active,
18 | .btn-primary:active,
19 | .btn-success:active,
20 | .btn-info:active,
21 | .btn-warning:active,
22 | .btn-danger:active,
23 | .btn-default.active,
24 | .btn-primary.active,
25 | .btn-success.active,
26 | .btn-info.active,
27 | .btn-warning.active,
28 | .btn-danger.active {
29 | -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
30 | box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
31 | }
32 | .btn:active,
33 | .btn.active {
34 | background-image: none;
35 | }
36 | .btn-default {
37 | text-shadow: 0 1px 0 #fff;
38 | background-image: -webkit-linear-gradient(top, #fff 0%, #e0e0e0 100%);
39 | background-image: -o-linear-gradient(top, #fff 0%, #e0e0e0 100%);
40 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#e0e0e0));
41 | background-image: linear-gradient(to bottom, #fff 0%, #e0e0e0 100%);
42 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);
43 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
44 | background-repeat: repeat-x;
45 | border-color: #dbdbdb;
46 | border-color: #ccc;
47 | }
48 | .btn-default:hover,
49 | .btn-default:focus {
50 | background-color: #e0e0e0;
51 | background-position: 0 -15px;
52 | }
53 | .btn-default:active,
54 | .btn-default.active {
55 | background-color: #e0e0e0;
56 | border-color: #dbdbdb;
57 | }
58 | .btn-default:disabled,
59 | .btn-default[disabled] {
60 | background-color: #e0e0e0;
61 | background-image: none;
62 | }
63 | .btn-primary {
64 | background-image: -webkit-linear-gradient(top, #428bca 0%, #2d6ca2 100%);
65 | background-image: -o-linear-gradient(top, #428bca 0%, #2d6ca2 100%);
66 | background-image: -webkit-gradient(linear, left top, left bottom, from(#428bca), to(#2d6ca2));
67 | background-image: linear-gradient(to bottom, #428bca 0%, #2d6ca2 100%);
68 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff2d6ca2', GradientType=0);
69 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
70 | background-repeat: repeat-x;
71 | border-color: #2b669a;
72 | }
73 | .btn-primary:hover,
74 | .btn-primary:focus {
75 | background-color: #2d6ca2;
76 | background-position: 0 -15px;
77 | }
78 | .btn-primary:active,
79 | .btn-primary.active {
80 | background-color: #2d6ca2;
81 | border-color: #2b669a;
82 | }
83 | .btn-primary:disabled,
84 | .btn-primary[disabled] {
85 | background-color: #2d6ca2;
86 | background-image: none;
87 | }
88 | .btn-success {
89 | background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%);
90 | background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%);
91 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641));
92 | background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%);
93 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);
94 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
95 | background-repeat: repeat-x;
96 | border-color: #3e8f3e;
97 | }
98 | .btn-success:hover,
99 | .btn-success:focus {
100 | background-color: #419641;
101 | background-position: 0 -15px;
102 | }
103 | .btn-success:active,
104 | .btn-success.active {
105 | background-color: #419641;
106 | border-color: #3e8f3e;
107 | }
108 | .btn-success:disabled,
109 | .btn-success[disabled] {
110 | background-color: #419641;
111 | background-image: none;
112 | }
113 | .btn-info {
114 | background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
115 | background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
116 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2));
117 | background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%);
118 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);
119 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
120 | background-repeat: repeat-x;
121 | border-color: #28a4c9;
122 | }
123 | .btn-info:hover,
124 | .btn-info:focus {
125 | background-color: #2aabd2;
126 | background-position: 0 -15px;
127 | }
128 | .btn-info:active,
129 | .btn-info.active {
130 | background-color: #2aabd2;
131 | border-color: #28a4c9;
132 | }
133 | .btn-info:disabled,
134 | .btn-info[disabled] {
135 | background-color: #2aabd2;
136 | background-image: none;
137 | }
138 | .btn-warning {
139 | background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
140 | background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
141 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316));
142 | background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%);
143 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);
144 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
145 | background-repeat: repeat-x;
146 | border-color: #e38d13;
147 | }
148 | .btn-warning:hover,
149 | .btn-warning:focus {
150 | background-color: #eb9316;
151 | background-position: 0 -15px;
152 | }
153 | .btn-warning:active,
154 | .btn-warning.active {
155 | background-color: #eb9316;
156 | border-color: #e38d13;
157 | }
158 | .btn-warning:disabled,
159 | .btn-warning[disabled] {
160 | background-color: #eb9316;
161 | background-image: none;
162 | }
163 | .btn-danger {
164 | background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
165 | background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
166 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a));
167 | background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%);
168 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);
169 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
170 | background-repeat: repeat-x;
171 | border-color: #b92c28;
172 | }
173 | .btn-danger:hover,
174 | .btn-danger:focus {
175 | background-color: #c12e2a;
176 | background-position: 0 -15px;
177 | }
178 | .btn-danger:active,
179 | .btn-danger.active {
180 | background-color: #c12e2a;
181 | border-color: #b92c28;
182 | }
183 | .btn-danger:disabled,
184 | .btn-danger[disabled] {
185 | background-color: #c12e2a;
186 | background-image: none;
187 | }
188 | .thumbnail,
189 | .img-thumbnail {
190 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
191 | box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
192 | }
193 | .dropdown-menu > li > a:hover,
194 | .dropdown-menu > li > a:focus {
195 | background-color: #e8e8e8;
196 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
197 | background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
198 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
199 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
200 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
201 | background-repeat: repeat-x;
202 | }
203 | .dropdown-menu > .active > a,
204 | .dropdown-menu > .active > a:hover,
205 | .dropdown-menu > .active > a:focus {
206 | background-color: #357ebd;
207 | background-image: -webkit-linear-gradient(top, #428bca 0%, #357ebd 100%);
208 | background-image: -o-linear-gradient(top, #428bca 0%, #357ebd 100%);
209 | background-image: -webkit-gradient(linear, left top, left bottom, from(#428bca), to(#357ebd));
210 | background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%);
211 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0);
212 | background-repeat: repeat-x;
213 | }
214 | .navbar-default {
215 | background-image: -webkit-linear-gradient(top, #fff 0%, #f8f8f8 100%);
216 | background-image: -o-linear-gradient(top, #fff 0%, #f8f8f8 100%);
217 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f8f8f8));
218 | background-image: linear-gradient(to bottom, #fff 0%, #f8f8f8 100%);
219 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);
220 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
221 | background-repeat: repeat-x;
222 | border-radius: 4px;
223 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
224 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
225 | }
226 | .navbar-default .navbar-nav > .active > a {
227 | background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f3f3f3 100%);
228 | background-image: -o-linear-gradient(top, #ebebeb 0%, #f3f3f3 100%);
229 | background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f3f3f3));
230 | background-image: linear-gradient(to bottom, #ebebeb 0%, #f3f3f3 100%);
231 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff3f3f3', GradientType=0);
232 | background-repeat: repeat-x;
233 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
234 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
235 | }
236 | .navbar-brand,
237 | .navbar-nav > li > a {
238 | text-shadow: 0 1px 0 rgba(255, 255, 255, .25);
239 | }
240 | .navbar-inverse {
241 | background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222 100%);
242 | background-image: -o-linear-gradient(top, #3c3c3c 0%, #222 100%);
243 | background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222));
244 | background-image: linear-gradient(to bottom, #3c3c3c 0%, #222 100%);
245 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);
246 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
247 | background-repeat: repeat-x;
248 | }
249 | .navbar-inverse .navbar-nav > .active > a {
250 | background-image: -webkit-linear-gradient(top, #222 0%, #282828 100%);
251 | background-image: -o-linear-gradient(top, #222 0%, #282828 100%);
252 | background-image: -webkit-gradient(linear, left top, left bottom, from(#222), to(#282828));
253 | background-image: linear-gradient(to bottom, #222 0%, #282828 100%);
254 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222', endColorstr='#ff282828', GradientType=0);
255 | background-repeat: repeat-x;
256 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
257 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
258 | }
259 | .navbar-inverse .navbar-brand,
260 | .navbar-inverse .navbar-nav > li > a {
261 | text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
262 | }
263 | .navbar-static-top,
264 | .navbar-fixed-top,
265 | .navbar-fixed-bottom {
266 | border-radius: 0;
267 | }
268 | .alert {
269 | text-shadow: 0 1px 0 rgba(255, 255, 255, .2);
270 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
271 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
272 | }
273 | .alert-success {
274 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
275 | background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
276 | background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc));
277 | background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%);
278 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);
279 | background-repeat: repeat-x;
280 | border-color: #b2dba1;
281 | }
282 | .alert-info {
283 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
284 | background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
285 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0));
286 | background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%);
287 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);
288 | background-repeat: repeat-x;
289 | border-color: #9acfea;
290 | }
291 | .alert-warning {
292 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
293 | background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
294 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0));
295 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%);
296 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);
297 | background-repeat: repeat-x;
298 | border-color: #f5e79e;
299 | }
300 | .alert-danger {
301 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
302 | background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
303 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3));
304 | background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%);
305 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);
306 | background-repeat: repeat-x;
307 | border-color: #dca7a7;
308 | }
309 | .progress {
310 | background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
311 | background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
312 | background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5));
313 | background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%);
314 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);
315 | background-repeat: repeat-x;
316 | }
317 | .progress-bar {
318 | background-image: -webkit-linear-gradient(top, #428bca 0%, #3071a9 100%);
319 | background-image: -o-linear-gradient(top, #428bca 0%, #3071a9 100%);
320 | background-image: -webkit-gradient(linear, left top, left bottom, from(#428bca), to(#3071a9));
321 | background-image: linear-gradient(to bottom, #428bca 0%, #3071a9 100%);
322 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3071a9', GradientType=0);
323 | background-repeat: repeat-x;
324 | }
325 | .progress-bar-success {
326 | background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%);
327 | background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%);
328 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44));
329 | background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%);
330 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);
331 | background-repeat: repeat-x;
332 | }
333 | .progress-bar-info {
334 | background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
335 | background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
336 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5));
337 | background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%);
338 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);
339 | background-repeat: repeat-x;
340 | }
341 | .progress-bar-warning {
342 | background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
343 | background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
344 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f));
345 | background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%);
346 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);
347 | background-repeat: repeat-x;
348 | }
349 | .progress-bar-danger {
350 | background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%);
351 | background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%);
352 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c));
353 | background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%);
354 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);
355 | background-repeat: repeat-x;
356 | }
357 | .progress-bar-striped {
358 | background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
359 | background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
360 | background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
361 | }
362 | .list-group {
363 | border-radius: 4px;
364 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
365 | box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
366 | }
367 | .list-group-item.active,
368 | .list-group-item.active:hover,
369 | .list-group-item.active:focus {
370 | text-shadow: 0 -1px 0 #3071a9;
371 | background-image: -webkit-linear-gradient(top, #428bca 0%, #3278b3 100%);
372 | background-image: -o-linear-gradient(top, #428bca 0%, #3278b3 100%);
373 | background-image: -webkit-gradient(linear, left top, left bottom, from(#428bca), to(#3278b3));
374 | background-image: linear-gradient(to bottom, #428bca 0%, #3278b3 100%);
375 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3278b3', GradientType=0);
376 | background-repeat: repeat-x;
377 | border-color: #3278b3;
378 | }
379 | .panel {
380 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
381 | box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
382 | }
383 | .panel-default > .panel-heading {
384 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
385 | background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
386 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
387 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
388 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
389 | background-repeat: repeat-x;
390 | }
391 | .panel-primary > .panel-heading {
392 | background-image: -webkit-linear-gradient(top, #428bca 0%, #357ebd 100%);
393 | background-image: -o-linear-gradient(top, #428bca 0%, #357ebd 100%);
394 | background-image: -webkit-gradient(linear, left top, left bottom, from(#428bca), to(#357ebd));
395 | background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%);
396 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0);
397 | background-repeat: repeat-x;
398 | }
399 | .panel-success > .panel-heading {
400 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
401 | background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
402 | background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6));
403 | background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%);
404 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);
405 | background-repeat: repeat-x;
406 | }
407 | .panel-info > .panel-heading {
408 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
409 | background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
410 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3));
411 | background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%);
412 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);
413 | background-repeat: repeat-x;
414 | }
415 | .panel-warning > .panel-heading {
416 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
417 | background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
418 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc));
419 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%);
420 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);
421 | background-repeat: repeat-x;
422 | }
423 | .panel-danger > .panel-heading {
424 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
425 | background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
426 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc));
427 | background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%);
428 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);
429 | background-repeat: repeat-x;
430 | }
431 | .well {
432 | background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
433 | background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
434 | background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5));
435 | background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%);
436 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);
437 | background-repeat: repeat-x;
438 | border-color: #dcdcdc;
439 | -webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
440 | box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
441 | }
442 | /*# sourceMappingURL=bootstrap-theme.css.map */
443 |
--------------------------------------------------------------------------------
/static/css/bootstrap-theme.css.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"bootstrap-theme.css","sources":["less/theme.less","less/mixins/vendor-prefixes.less","bootstrap-theme.css","less/mixins/gradients.less","less/mixins/reset-filter.less"],"names":[],"mappings":"AAeA;;;;;;EAME,0CAAA;EC+CA,6FAAA;EACQ,qFAAA;EC5DT;AFiBC;;;;;;;;;;;;EC0CA,0DAAA;EACQ,kDAAA;EC7CT;AFqCC;;EAEE,wBAAA;EEnCH;AFwCD;EG/CI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EA+B2C,2BAAA;EAA2B,oBAAA;EE7BvE;AFAC;;EAEE,2BAAA;EACA,8BAAA;EEEH;AFCC;;EAEE,2BAAA;EACA,uBAAA;EECH;AFEC;;EAEE,2BAAA;EACA,wBAAA;EEAH;AFeD;EGhDI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EE0BD;AFxBC;;EAEE,2BAAA;EACA,8BAAA;EE0BH;AFvBC;;EAEE,2BAAA;EACA,uBAAA;EEyBH;AFtBC;;EAEE,2BAAA;EACA,wBAAA;EEwBH;AFRD;EGjDI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EEkDD;AFhDC;;EAEE,2BAAA;EACA,8BAAA;EEkDH;AF/CC;;EAEE,2BAAA;EACA,uBAAA;EEiDH;AF9CC;;EAEE,2BAAA;EACA,wBAAA;EEgDH;AF/BD;EGlDI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EE0ED;AFxEC;;EAEE,2BAAA;EACA,8BAAA;EE0EH;AFvEC;;EAEE,2BAAA;EACA,uBAAA;EEyEH;AFtEC;;EAEE,2BAAA;EACA,wBAAA;EEwEH;AFtDD;EGnDI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EEkGD;AFhGC;;EAEE,2BAAA;EACA,8BAAA;EEkGH;AF/FC;;EAEE,2BAAA;EACA,uBAAA;EEiGH;AF9FC;;EAEE,2BAAA;EACA,wBAAA;EEgGH;AF7ED;EGpDI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EAEA,wHAAA;ECnBF,qEAAA;EJ8BA,6BAAA;EACA,uBAAA;EE0HD;AFxHC;;EAEE,2BAAA;EACA,8BAAA;EE0HH;AFvHC;;EAEE,2BAAA;EACA,uBAAA;EEyHH;AFtHC;;EAEE,2BAAA;EACA,wBAAA;EEwHH;AF7FD;;ECbE,oDAAA;EACQ,4CAAA;EC8GT;AFvFD;;EGvEI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EHsEF,2BAAA;EE6FD;AF3FD;;;EG5EI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EH4EF,2BAAA;EEiGD;AFvFD;EG1FI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ECnBF,qEAAA;EJ4GA,oBAAA;EC9CA,6FAAA;EACQ,qFAAA;EC4IT;AFlGD;EG1FI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EF2CF,0DAAA;EACQ,kDAAA;ECqJT;AF/FD;;EAEE,gDAAA;EEiGD;AF7FD;EG5GI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ECnBF,qEAAA;EFgOD;AFrGD;EG5GI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EF2CF,yDAAA;EACQ,iDAAA;EC0KT;AF9GD;;EAWI,2CAAA;EEuGH;AFlGD;;;EAGE,kBAAA;EEoGD;AF1FD;EACE,+CAAA;EC3FA,4FAAA;EACQ,oFAAA;ECwLT;AFlFD;EGtJI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EH8IF,uBAAA;EE8FD;AFzFD;EGvJI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EH8IF,uBAAA;EEsGD;AFhGD;EGxJI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EH8IF,uBAAA;EE8GD;AFvGD;EGzJI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EH8IF,uBAAA;EEsHD;AFtGD;EGlKI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ED2QH;AFnGD;EG5KI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDkRH;AFzGD;EG7KI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDyRH;AF/GD;EG9KI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDgSH;AFrHD;EG/KI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDuSH;AF3HD;EGhLI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ED8SH;AF9HD;EGnJI,+MAAA;EACA,0MAAA;EACA,uMAAA;EDoRH;AF1HD;EACE,oBAAA;EC/IA,oDAAA;EACQ,4CAAA;EC4QT;AF3HD;;;EAGE,+BAAA;EGpME,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EHkMF,uBAAA;EEiID;AFvHD;ECjKE,mDAAA;EACQ,2CAAA;EC2RT;AFjHD;EG1NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ED8UH;AFvHD;EG3NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDqVH;AF7HD;EG5NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ED4VH;AFnID;EG7NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDmWH;AFzID;EG9NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;ED0WH;AF/ID;EG/NI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EDiXH;AF9ID;EGvOI,0EAAA;EACA,qEAAA;EACA,+FAAA;EAAA,wEAAA;EACA,6BAAA;EACA,wHAAA;EHqOF,uBAAA;EC1LA,2FAAA;EACQ,mFAAA;EC+UT","sourcesContent":["\n//\n// Load core variables and mixins\n// --------------------------------------------------\n\n@import \"variables.less\";\n@import \"mixins.less\";\n\n\n\n//\n// Buttons\n// --------------------------------------------------\n\n// Common styles\n.btn-default,\n.btn-primary,\n.btn-success,\n.btn-info,\n.btn-warning,\n.btn-danger {\n text-shadow: 0 -1px 0 rgba(0,0,0,.2);\n @shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 1px 1px rgba(0,0,0,.075);\n .box-shadow(@shadow);\n\n // Reset the shadow\n &:active,\n &.active {\n .box-shadow(inset 0 3px 5px rgba(0,0,0,.125));\n }\n}\n\n// Mixin for generating new styles\n.btn-styles(@btn-color: #555) {\n #gradient > .vertical(@start-color: @btn-color; @end-color: darken(@btn-color, 12%));\n .reset-filter(); // Disable gradients for IE9 because filter bleeds through rounded corners\n background-repeat: repeat-x;\n border-color: darken(@btn-color, 14%);\n\n &:hover,\n &:focus {\n background-color: darken(@btn-color, 12%);\n background-position: 0 -15px;\n }\n\n &:active,\n &.active {\n background-color: darken(@btn-color, 12%);\n border-color: darken(@btn-color, 14%);\n }\n\n &:disabled,\n &[disabled] {\n background-color: darken(@btn-color, 12%);\n background-image: none;\n }\n}\n\n// Common styles\n.btn {\n // Remove the gradient for the pressed/active state\n &:active,\n &.active {\n background-image: none;\n }\n}\n\n// Apply the mixin to the buttons\n.btn-default { .btn-styles(@btn-default-bg); text-shadow: 0 1px 0 #fff; border-color: #ccc; }\n.btn-primary { .btn-styles(@btn-primary-bg); }\n.btn-success { .btn-styles(@btn-success-bg); }\n.btn-info { .btn-styles(@btn-info-bg); }\n.btn-warning { .btn-styles(@btn-warning-bg); }\n.btn-danger { .btn-styles(@btn-danger-bg); }\n\n\n\n//\n// Images\n// --------------------------------------------------\n\n.thumbnail,\n.img-thumbnail {\n .box-shadow(0 1px 2px rgba(0,0,0,.075));\n}\n\n\n\n//\n// Dropdowns\n// --------------------------------------------------\n\n.dropdown-menu > li > a:hover,\n.dropdown-menu > li > a:focus {\n #gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%));\n background-color: darken(@dropdown-link-hover-bg, 5%);\n}\n.dropdown-menu > .active > a,\n.dropdown-menu > .active > a:hover,\n.dropdown-menu > .active > a:focus {\n #gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%));\n background-color: darken(@dropdown-link-active-bg, 5%);\n}\n\n\n\n//\n// Navbar\n// --------------------------------------------------\n\n// Default navbar\n.navbar-default {\n #gradient > .vertical(@start-color: lighten(@navbar-default-bg, 10%); @end-color: @navbar-default-bg);\n .reset-filter(); // Remove gradient in IE<10 to fix bug where dropdowns don't get triggered\n border-radius: @navbar-border-radius;\n @shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 1px 5px rgba(0,0,0,.075);\n .box-shadow(@shadow);\n\n .navbar-nav > .active > a {\n #gradient > .vertical(@start-color: darken(@navbar-default-bg, 5%); @end-color: darken(@navbar-default-bg, 2%));\n .box-shadow(inset 0 3px 9px rgba(0,0,0,.075));\n }\n}\n.navbar-brand,\n.navbar-nav > li > a {\n text-shadow: 0 1px 0 rgba(255,255,255,.25);\n}\n\n// Inverted navbar\n.navbar-inverse {\n #gradient > .vertical(@start-color: lighten(@navbar-inverse-bg, 10%); @end-color: @navbar-inverse-bg);\n .reset-filter(); // Remove gradient in IE<10 to fix bug where dropdowns don't get triggered\n\n .navbar-nav > .active > a {\n #gradient > .vertical(@start-color: @navbar-inverse-bg; @end-color: lighten(@navbar-inverse-bg, 2.5%));\n .box-shadow(inset 0 3px 9px rgba(0,0,0,.25));\n }\n\n .navbar-brand,\n .navbar-nav > li > a {\n text-shadow: 0 -1px 0 rgba(0,0,0,.25);\n }\n}\n\n// Undo rounded corners in static and fixed navbars\n.navbar-static-top,\n.navbar-fixed-top,\n.navbar-fixed-bottom {\n border-radius: 0;\n}\n\n\n\n//\n// Alerts\n// --------------------------------------------------\n\n// Common styles\n.alert {\n text-shadow: 0 1px 0 rgba(255,255,255,.2);\n @shadow: inset 0 1px 0 rgba(255,255,255,.25), 0 1px 2px rgba(0,0,0,.05);\n .box-shadow(@shadow);\n}\n\n// Mixin for generating new styles\n.alert-styles(@color) {\n #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 7.5%));\n border-color: darken(@color, 15%);\n}\n\n// Apply the mixin to the alerts\n.alert-success { .alert-styles(@alert-success-bg); }\n.alert-info { .alert-styles(@alert-info-bg); }\n.alert-warning { .alert-styles(@alert-warning-bg); }\n.alert-danger { .alert-styles(@alert-danger-bg); }\n\n\n\n//\n// Progress bars\n// --------------------------------------------------\n\n// Give the progress background some depth\n.progress {\n #gradient > .vertical(@start-color: darken(@progress-bg, 4%); @end-color: @progress-bg)\n}\n\n// Mixin for generating new styles\n.progress-bar-styles(@color) {\n #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 10%));\n}\n\n// Apply the mixin to the progress bars\n.progress-bar { .progress-bar-styles(@progress-bar-bg); }\n.progress-bar-success { .progress-bar-styles(@progress-bar-success-bg); }\n.progress-bar-info { .progress-bar-styles(@progress-bar-info-bg); }\n.progress-bar-warning { .progress-bar-styles(@progress-bar-warning-bg); }\n.progress-bar-danger { .progress-bar-styles(@progress-bar-danger-bg); }\n\n// Reset the striped class because our mixins don't do multiple gradients and\n// the above custom styles override the new `.progress-bar-striped` in v3.2.0.\n.progress-bar-striped {\n #gradient > .striped();\n}\n\n\n//\n// List groups\n// --------------------------------------------------\n\n.list-group {\n border-radius: @border-radius-base;\n .box-shadow(0 1px 2px rgba(0,0,0,.075));\n}\n.list-group-item.active,\n.list-group-item.active:hover,\n.list-group-item.active:focus {\n text-shadow: 0 -1px 0 darken(@list-group-active-bg, 10%);\n #gradient > .vertical(@start-color: @list-group-active-bg; @end-color: darken(@list-group-active-bg, 7.5%));\n border-color: darken(@list-group-active-border, 7.5%);\n}\n\n\n\n//\n// Panels\n// --------------------------------------------------\n\n// Common styles\n.panel {\n .box-shadow(0 1px 2px rgba(0,0,0,.05));\n}\n\n// Mixin for generating new styles\n.panel-heading-styles(@color) {\n #gradient > .vertical(@start-color: @color; @end-color: darken(@color, 5%));\n}\n\n// Apply the mixin to the panel headings only\n.panel-default > .panel-heading { .panel-heading-styles(@panel-default-heading-bg); }\n.panel-primary > .panel-heading { .panel-heading-styles(@panel-primary-heading-bg); }\n.panel-success > .panel-heading { .panel-heading-styles(@panel-success-heading-bg); }\n.panel-info > .panel-heading { .panel-heading-styles(@panel-info-heading-bg); }\n.panel-warning > .panel-heading { .panel-heading-styles(@panel-warning-heading-bg); }\n.panel-danger > .panel-heading { .panel-heading-styles(@panel-danger-heading-bg); }\n\n\n\n//\n// Wells\n// --------------------------------------------------\n\n.well {\n #gradient > .vertical(@start-color: darken(@well-bg, 5%); @end-color: @well-bg);\n border-color: darken(@well-bg, 10%);\n @shadow: inset 0 1px 3px rgba(0,0,0,.05), 0 1px 0 rgba(255,255,255,.1);\n .box-shadow(@shadow);\n}\n","// Vendor Prefixes\n//\n// All vendor mixins are deprecated as of v3.2.0 due to the introduction of\n// Autoprefixer in our Gruntfile. They will be removed in v4.\n\n// - Animations\n// - Backface visibility\n// - Box shadow\n// - Box sizing\n// - Content columns\n// - Hyphens\n// - Placeholder text\n// - Transformations\n// - Transitions\n// - User Select\n\n\n// Animations\n.animation(@animation) {\n -webkit-animation: @animation;\n -o-animation: @animation;\n animation: @animation;\n}\n.animation-name(@name) {\n -webkit-animation-name: @name;\n animation-name: @name;\n}\n.animation-duration(@duration) {\n -webkit-animation-duration: @duration;\n animation-duration: @duration;\n}\n.animation-timing-function(@timing-function) {\n -webkit-animation-timing-function: @timing-function;\n animation-timing-function: @timing-function;\n}\n.animation-delay(@delay) {\n -webkit-animation-delay: @delay;\n animation-delay: @delay;\n}\n.animation-iteration-count(@iteration-count) {\n -webkit-animation-iteration-count: @iteration-count;\n animation-iteration-count: @iteration-count;\n}\n.animation-direction(@direction) {\n -webkit-animation-direction: @direction;\n animation-direction: @direction;\n}\n.animation-fill-mode(@fill-mode) {\n -webkit-animation-fill-mode: @fill-mode;\n animation-fill-mode: @fill-mode;\n}\n\n// Backface visibility\n// Prevent browsers from flickering when using CSS 3D transforms.\n// Default value is `visible`, but can be changed to `hidden`\n\n.backface-visibility(@visibility){\n -webkit-backface-visibility: @visibility;\n -moz-backface-visibility: @visibility;\n backface-visibility: @visibility;\n}\n\n// Drop shadows\n//\n// Note: Deprecated `.box-shadow()` as of v3.1.0 since all of Bootstrap's\n// supported browsers that have box shadow capabilities now support it.\n\n.box-shadow(@shadow) {\n -webkit-box-shadow: @shadow; // iOS <4.3 & Android <4.1\n box-shadow: @shadow;\n}\n\n// Box sizing\n.box-sizing(@boxmodel) {\n -webkit-box-sizing: @boxmodel;\n -moz-box-sizing: @boxmodel;\n box-sizing: @boxmodel;\n}\n\n// CSS3 Content Columns\n.content-columns(@column-count; @column-gap: @grid-gutter-width) {\n -webkit-column-count: @column-count;\n -moz-column-count: @column-count;\n column-count: @column-count;\n -webkit-column-gap: @column-gap;\n -moz-column-gap: @column-gap;\n column-gap: @column-gap;\n}\n\n// Optional hyphenation\n.hyphens(@mode: auto) {\n word-wrap: break-word;\n -webkit-hyphens: @mode;\n -moz-hyphens: @mode;\n -ms-hyphens: @mode; // IE10+\n -o-hyphens: @mode;\n hyphens: @mode;\n}\n\n// Placeholder text\n.placeholder(@color: @input-color-placeholder) {\n &::-moz-placeholder { color: @color; // Firefox\n opacity: 1; } // See https://github.com/twbs/bootstrap/pull/11526\n &:-ms-input-placeholder { color: @color; } // Internet Explorer 10+\n &::-webkit-input-placeholder { color: @color; } // Safari and Chrome\n}\n\n// Transformations\n.scale(@ratio) {\n -webkit-transform: scale(@ratio);\n -ms-transform: scale(@ratio); // IE9 only\n -o-transform: scale(@ratio);\n transform: scale(@ratio);\n}\n.scale(@ratioX; @ratioY) {\n -webkit-transform: scale(@ratioX, @ratioY);\n -ms-transform: scale(@ratioX, @ratioY); // IE9 only\n -o-transform: scale(@ratioX, @ratioY);\n transform: scale(@ratioX, @ratioY);\n}\n.scaleX(@ratio) {\n -webkit-transform: scaleX(@ratio);\n -ms-transform: scaleX(@ratio); // IE9 only\n -o-transform: scaleX(@ratio);\n transform: scaleX(@ratio);\n}\n.scaleY(@ratio) {\n -webkit-transform: scaleY(@ratio);\n -ms-transform: scaleY(@ratio); // IE9 only\n -o-transform: scaleY(@ratio);\n transform: scaleY(@ratio);\n}\n.skew(@x; @y) {\n -webkit-transform: skewX(@x) skewY(@y);\n -ms-transform: skewX(@x) skewY(@y); // See https://github.com/twbs/bootstrap/issues/4885; IE9+\n -o-transform: skewX(@x) skewY(@y);\n transform: skewX(@x) skewY(@y);\n}\n.translate(@x; @y) {\n -webkit-transform: translate(@x, @y);\n -ms-transform: translate(@x, @y); // IE9 only\n -o-transform: translate(@x, @y);\n transform: translate(@x, @y);\n}\n.translate3d(@x; @y; @z) {\n -webkit-transform: translate3d(@x, @y, @z);\n transform: translate3d(@x, @y, @z);\n}\n.rotate(@degrees) {\n -webkit-transform: rotate(@degrees);\n -ms-transform: rotate(@degrees); // IE9 only\n -o-transform: rotate(@degrees);\n transform: rotate(@degrees);\n}\n.rotateX(@degrees) {\n -webkit-transform: rotateX(@degrees);\n -ms-transform: rotateX(@degrees); // IE9 only\n -o-transform: rotateX(@degrees);\n transform: rotateX(@degrees);\n}\n.rotateY(@degrees) {\n -webkit-transform: rotateY(@degrees);\n -ms-transform: rotateY(@degrees); // IE9 only\n -o-transform: rotateY(@degrees);\n transform: rotateY(@degrees);\n}\n.perspective(@perspective) {\n -webkit-perspective: @perspective;\n -moz-perspective: @perspective;\n perspective: @perspective;\n}\n.perspective-origin(@perspective) {\n -webkit-perspective-origin: @perspective;\n -moz-perspective-origin: @perspective;\n perspective-origin: @perspective;\n}\n.transform-origin(@origin) {\n -webkit-transform-origin: @origin;\n -moz-transform-origin: @origin;\n -ms-transform-origin: @origin; // IE9 only\n transform-origin: @origin;\n}\n\n\n// Transitions\n\n.transition(@transition) {\n -webkit-transition: @transition;\n -o-transition: @transition;\n transition: @transition;\n}\n.transition-property(@transition-property) {\n -webkit-transition-property: @transition-property;\n transition-property: @transition-property;\n}\n.transition-delay(@transition-delay) {\n -webkit-transition-delay: @transition-delay;\n transition-delay: @transition-delay;\n}\n.transition-duration(@transition-duration) {\n -webkit-transition-duration: @transition-duration;\n transition-duration: @transition-duration;\n}\n.transition-timing-function(@timing-function) {\n -webkit-transition-timing-function: @timing-function;\n transition-timing-function: @timing-function;\n}\n.transition-transform(@transition) {\n -webkit-transition: -webkit-transform @transition;\n -moz-transition: -moz-transform @transition;\n -o-transition: -o-transform @transition;\n transition: transform @transition;\n}\n\n\n// User select\n// For selecting text on the page\n\n.user-select(@select) {\n -webkit-user-select: @select;\n -moz-user-select: @select;\n -ms-user-select: @select; // IE10+\n user-select: @select;\n}\n",null,"// Gradients\n\n#gradient {\n\n // Horizontal gradient, from left to right\n //\n // Creates two color stops, start and end, by specifying a color and position for each color stop.\n // Color stops are not available in IE9 and below.\n .horizontal(@start-color: #555; @end-color: #333; @start-percent: 0%; @end-percent: 100%) {\n background-image: -webkit-linear-gradient(left, @start-color @start-percent, @end-color @end-percent); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(left, @start-color @start-percent, @end-color @end-percent); // Opera 12\n background-image: linear-gradient(to right, @start-color @start-percent, @end-color @end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n background-repeat: repeat-x;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=1)\",argb(@start-color),argb(@end-color))); // IE9 and down\n }\n\n // Vertical gradient, from top to bottom\n //\n // Creates two color stops, start and end, by specifying a color and position for each color stop.\n // Color stops are not available in IE9 and below.\n .vertical(@start-color: #555; @end-color: #333; @start-percent: 0%; @end-percent: 100%) {\n background-image: -webkit-linear-gradient(top, @start-color @start-percent, @end-color @end-percent); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(top, @start-color @start-percent, @end-color @end-percent); // Opera 12\n background-image: linear-gradient(to bottom, @start-color @start-percent, @end-color @end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n background-repeat: repeat-x;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)\",argb(@start-color),argb(@end-color))); // IE9 and down\n }\n\n .directional(@start-color: #555; @end-color: #333; @deg: 45deg) {\n background-repeat: repeat-x;\n background-image: -webkit-linear-gradient(@deg, @start-color, @end-color); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(@deg, @start-color, @end-color); // Opera 12\n background-image: linear-gradient(@deg, @start-color, @end-color); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n }\n .horizontal-three-colors(@start-color: #00b3ee; @mid-color: #7a43b6; @color-stop: 50%; @end-color: #c3325f) {\n background-image: -webkit-linear-gradient(left, @start-color, @mid-color @color-stop, @end-color);\n background-image: -o-linear-gradient(left, @start-color, @mid-color @color-stop, @end-color);\n background-image: linear-gradient(to right, @start-color, @mid-color @color-stop, @end-color);\n background-repeat: no-repeat;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=1)\",argb(@start-color),argb(@end-color))); // IE9 and down, gets no color-stop at all for proper fallback\n }\n .vertical-three-colors(@start-color: #00b3ee; @mid-color: #7a43b6; @color-stop: 50%; @end-color: #c3325f) {\n background-image: -webkit-linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-image: -o-linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-image: linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-repeat: no-repeat;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)\",argb(@start-color),argb(@end-color))); // IE9 and down, gets no color-stop at all for proper fallback\n }\n .radial(@inner-color: #555; @outer-color: #333) {\n background-image: -webkit-radial-gradient(circle, @inner-color, @outer-color);\n background-image: radial-gradient(circle, @inner-color, @outer-color);\n background-repeat: no-repeat;\n }\n .striped(@color: rgba(255,255,255,.15); @angle: 45deg) {\n background-image: -webkit-linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n background-image: linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n }\n}\n","// Reset filters for IE\n//\n// When you need to remove a gradient background, do not forget to use this to reset\n// the IE filter for IE9 and below.\n\n.reset-filter() {\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(enabled = false)\"));\n}\n"]}
--------------------------------------------------------------------------------
/static/css/bootstrap-theme.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap v3.2.0 (http://getbootstrap.com)
3 | * Copyright 2011-2014 Twitter, Inc.
4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
5 | */.btn-default,.btn-primary,.btn-success,.btn-info,.btn-warning,.btn-danger{text-shadow:0 -1px 0 rgba(0,0,0,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075)}.btn-default:active,.btn-primary:active,.btn-success:active,.btn-info:active,.btn-warning:active,.btn-danger:active,.btn-default.active,.btn-primary.active,.btn-success.active,.btn-info.active,.btn-warning.active,.btn-danger.active{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn:active,.btn.active{background-image:none}.btn-default{text-shadow:0 1px 0 #fff;background-image:-webkit-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-o-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#e0e0e0));background-image:linear-gradient(to bottom,#fff 0,#e0e0e0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#dbdbdb;border-color:#ccc}.btn-default:hover,.btn-default:focus{background-color:#e0e0e0;background-position:0 -15px}.btn-default:active,.btn-default.active{background-color:#e0e0e0;border-color:#dbdbdb}.btn-default:disabled,.btn-default[disabled]{background-color:#e0e0e0;background-image:none}.btn-primary{background-image:-webkit-linear-gradient(top,#428bca 0,#2d6ca2 100%);background-image:-o-linear-gradient(top,#428bca 0,#2d6ca2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#428bca),to(#2d6ca2));background-image:linear-gradient(to bottom,#428bca 0,#2d6ca2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff2d6ca2', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#2b669a}.btn-primary:hover,.btn-primary:focus{background-color:#2d6ca2;background-position:0 -15px}.btn-primary:active,.btn-primary.active{background-color:#2d6ca2;border-color:#2b669a}.btn-primary:disabled,.btn-primary[disabled]{background-color:#2d6ca2;background-image:none}.btn-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#419641));background-image:linear-gradient(to bottom,#5cb85c 0,#419641 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#3e8f3e}.btn-success:hover,.btn-success:focus{background-color:#419641;background-position:0 -15px}.btn-success:active,.btn-success.active{background-color:#419641;border-color:#3e8f3e}.btn-success:disabled,.btn-success[disabled]{background-color:#419641;background-image:none}.btn-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#2aabd2));background-image:linear-gradient(to bottom,#5bc0de 0,#2aabd2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#28a4c9}.btn-info:hover,.btn-info:focus{background-color:#2aabd2;background-position:0 -15px}.btn-info:active,.btn-info.active{background-color:#2aabd2;border-color:#28a4c9}.btn-info:disabled,.btn-info[disabled]{background-color:#2aabd2;background-image:none}.btn-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#eb9316));background-image:linear-gradient(to bottom,#f0ad4e 0,#eb9316 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#e38d13}.btn-warning:hover,.btn-warning:focus{background-color:#eb9316;background-position:0 -15px}.btn-warning:active,.btn-warning.active{background-color:#eb9316;border-color:#e38d13}.btn-warning:disabled,.btn-warning[disabled]{background-color:#eb9316;background-image:none}.btn-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c12e2a));background-image:linear-gradient(to bottom,#d9534f 0,#c12e2a 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#b92c28}.btn-danger:hover,.btn-danger:focus{background-color:#c12e2a;background-position:0 -15px}.btn-danger:active,.btn-danger.active{background-color:#c12e2a;border-color:#b92c28}.btn-danger:disabled,.btn-danger[disabled]{background-color:#c12e2a;background-image:none}.thumbnail,.img-thumbnail{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.dropdown-menu>li>a:hover,.dropdown-menu>li>a:focus{background-color:#e8e8e8;background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.dropdown-menu>.active>a,.dropdown-menu>.active>a:hover,.dropdown-menu>.active>a:focus{background-color:#357ebd;background-image:-webkit-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-o-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#428bca),to(#357ebd));background-image:linear-gradient(to bottom,#428bca 0,#357ebd 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0);background-repeat:repeat-x}.navbar-default{background-image:-webkit-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-o-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#f8f8f8));background-image:linear-gradient(to bottom,#fff 0,#f8f8f8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-radius:4px;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075)}.navbar-default .navbar-nav>.active>a{background-image:-webkit-linear-gradient(top,#ebebeb 0,#f3f3f3 100%);background-image:-o-linear-gradient(top,#ebebeb 0,#f3f3f3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#ebebeb),to(#f3f3f3));background-image:linear-gradient(to bottom,#ebebeb 0,#f3f3f3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff3f3f3', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.075);box-shadow:inset 0 3px 9px rgba(0,0,0,.075)}.navbar-brand,.navbar-nav>li>a{text-shadow:0 1px 0 rgba(255,255,255,.25)}.navbar-inverse{background-image:-webkit-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-o-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#3c3c3c),to(#222));background-image:linear-gradient(to bottom,#3c3c3c 0,#222 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x}.navbar-inverse .navbar-nav>.active>a{background-image:-webkit-linear-gradient(top,#222 0,#282828 100%);background-image:-o-linear-gradient(top,#222 0,#282828 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#222),to(#282828));background-image:linear-gradient(to bottom,#222 0,#282828 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222', endColorstr='#ff282828', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.25);box-shadow:inset 0 3px 9px rgba(0,0,0,.25)}.navbar-inverse .navbar-brand,.navbar-inverse .navbar-nav>li>a{text-shadow:0 -1px 0 rgba(0,0,0,.25)}.navbar-static-top,.navbar-fixed-top,.navbar-fixed-bottom{border-radius:0}.alert{text-shadow:0 1px 0 rgba(255,255,255,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05);box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05)}.alert-success{background-image:-webkit-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#c8e5bc));background-image:linear-gradient(to bottom,#dff0d8 0,#c8e5bc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);background-repeat:repeat-x;border-color:#b2dba1}.alert-info{background-image:-webkit-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#b9def0));background-image:linear-gradient(to bottom,#d9edf7 0,#b9def0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);background-repeat:repeat-x;border-color:#9acfea}.alert-warning{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#f8efc0));background-image:linear-gradient(to bottom,#fcf8e3 0,#f8efc0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);background-repeat:repeat-x;border-color:#f5e79e}.alert-danger{background-image:-webkit-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-o-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#e7c3c3));background-image:linear-gradient(to bottom,#f2dede 0,#e7c3c3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);background-repeat:repeat-x;border-color:#dca7a7}.progress{background-image:-webkit-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#ebebeb),to(#f5f5f5));background-image:linear-gradient(to bottom,#ebebeb 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x}.progress-bar{background-image:-webkit-linear-gradient(top,#428bca 0,#3071a9 100%);background-image:-o-linear-gradient(top,#428bca 0,#3071a9 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#428bca),to(#3071a9));background-image:linear-gradient(to bottom,#428bca 0,#3071a9 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3071a9', GradientType=0);background-repeat:repeat-x}.progress-bar-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#449d44));background-image:linear-gradient(to bottom,#5cb85c 0,#449d44 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);background-repeat:repeat-x}.progress-bar-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#31b0d5));background-image:linear-gradient(to bottom,#5bc0de 0,#31b0d5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);background-repeat:repeat-x}.progress-bar-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#ec971f));background-image:linear-gradient(to bottom,#f0ad4e 0,#ec971f 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);background-repeat:repeat-x}.progress-bar-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c9302c));background-image:linear-gradient(to bottom,#d9534f 0,#c9302c 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);background-repeat:repeat-x}.progress-bar-striped{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.list-group{border-radius:4px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.list-group-item.active,.list-group-item.active:hover,.list-group-item.active:focus{text-shadow:0 -1px 0 #3071a9;background-image:-webkit-linear-gradient(top,#428bca 0,#3278b3 100%);background-image:-o-linear-gradient(top,#428bca 0,#3278b3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#428bca),to(#3278b3));background-image:linear-gradient(to bottom,#428bca 0,#3278b3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3278b3', GradientType=0);background-repeat:repeat-x;border-color:#3278b3}.panel{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.05);box-shadow:0 1px 2px rgba(0,0,0,.05)}.panel-default>.panel-heading{background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.panel-primary>.panel-heading{background-image:-webkit-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-o-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#428bca),to(#357ebd));background-image:linear-gradient(to bottom,#428bca 0,#357ebd 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0);background-repeat:repeat-x}.panel-success>.panel-heading{background-image:-webkit-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#d0e9c6));background-image:linear-gradient(to bottom,#dff0d8 0,#d0e9c6 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);background-repeat:repeat-x}.panel-info>.panel-heading{background-image:-webkit-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#c4e3f3));background-image:linear-gradient(to bottom,#d9edf7 0,#c4e3f3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);background-repeat:repeat-x}.panel-warning>.panel-heading{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#faf2cc));background-image:linear-gradient(to bottom,#fcf8e3 0,#faf2cc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);background-repeat:repeat-x}.panel-danger>.panel-heading{background-image:-webkit-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-o-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#ebcccc));background-image:linear-gradient(to bottom,#f2dede 0,#ebcccc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);background-repeat:repeat-x}.well{background-image:-webkit-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#e8e8e8),to(#f5f5f5));background-image:linear-gradient(to bottom,#e8e8e8 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x;border-color:#dcdcdc;-webkit-box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1)}
--------------------------------------------------------------------------------
/static/css/index.css:
--------------------------------------------------------------------------------
1 | body{
2 | background:url('http://static.simpledesktops.com/uploads/desktops/2013/03/01/interlacement.png');
3 | }
4 | #main{
5 | background:white;
6 | box-shadow:0 0 20px black;
7 | width:920px;
8 | margin:0 auto;
9 | padding:10px;
10 | }
11 | .modal {
12 | margin-top: 100px;
13 | }
14 |
15 | button {
16 | margin: 10px 0;
17 | }
18 |
19 | #title {
20 | border-radius: 15px;
21 | margin: 0 auto;
22 | width: 300px;
23 | height:220px;
24 | text-align: center;
25 | }
26 |
27 | #title h1 {
28 | font-size: 100px;
29 | }
30 |
31 | #loginWindow{
32 | width:50%;
33 | margin:0 auto;
34 | }
35 | #myModalLabel{
36 | text-align: center;
37 | }
38 | #information{
39 | font-size: 20px;
40 | border: 1px solid black;
41 | width:100%;
42 | margin: 10px 0;
43 | overflow: auto;
44 | }
45 | #actions,#applyAction{
46 | display: inline-block;
47 | margin:0 auto;
48 | }
49 | #actions{
50 | width: 790px;
51 | height:40px;
52 | margin:0 5px 0 0;
53 | }
54 | #applyAction{
55 | width:100px;
56 | height:40px;
57 | }
58 | .progress{
59 | margin-top:5px;
60 | display: inline-block;
61 | width:297px;
62 | height: 20px;
63 | }
64 | #footer{
65 | position:absolute;
66 | bottom: 0px;
67 | }
68 | #deleteC,#createC{
69 | width:calc(50% - 2px);
70 | display: inline-block;
71 | }
72 | .btn-group{
73 | width:100%;
74 | margin:10px 0;
75 | }
76 | .btn-default{
77 | width:calc(100% / 3);
78 | }
79 | #introduce{
80 | width: 100%;
81 | height:200px;
82 | }
83 | #characterInfo{
84 | height:45px;
85 | line-height: 45px;
86 | display: inline-block;
87 | width:59%;
88 | font-size: 18px;
89 | text-align: center;
90 | margin:3px 0;
91 | }
92 | #logout,#report{
93 | width:20%;
94 | display: inline-block;
95 | }
96 | #characterChoice{
97 | width:70%;
98 | margin:0 auto;
99 | margin-top:150px;
100 | }
101 |
102 | #title h2{
103 | font-size:50px;
104 | }
--------------------------------------------------------------------------------
/static/fonts/glyphicons-halflings-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/fonts/glyphicons-halflings-regular.eot
--------------------------------------------------------------------------------
/static/fonts/glyphicons-halflings-regular.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/static/fonts/glyphicons-halflings-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/fonts/glyphicons-halflings-regular.ttf
--------------------------------------------------------------------------------
/static/fonts/glyphicons-halflings-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/fonts/glyphicons-halflings-regular.woff
--------------------------------------------------------------------------------
/static/js/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/static/js/.DS_Store
--------------------------------------------------------------------------------
/static/js/bootstrap.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap v3.2.0 (http://getbootstrap.com)
3 | * Copyright 2011-2014 Twitter, Inc.
4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
5 | */
6 | if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.2.0",d.prototype.close=function(b){function c(){f.detach().trigger("closed.bs.alert").remove()}var d=a(this),e=d.attr("data-target");e||(e=d.attr("href"),e=e&&e.replace(/.*(?=#[^\s]*$)/,""));var f=a(e);b&&b.preventDefault(),f.length||(f=d.hasClass("alert")?d:d.parent()),f.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one("bsTransitionEnd",c).emulateTransitionEnd(150):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.2.0",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),d[e](null==f[b]?this.options[b]:f[b]),setTimeout(a.proxy(function(){"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")&&(c.prop("checked")&&this.$element.hasClass("active")?a=!1:b.find(".active").removeClass("active")),a&&c.prop("checked",!this.$element.hasClass("active")).trigger("change")}a&&this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),c.preventDefault()})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b).on("keydown.bs.carousel",a.proxy(this.keydown,this)),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=this.sliding=this.interval=this.$active=this.$items=null,"hover"==this.options.pause&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.2.0",c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0},c.prototype.keydown=function(a){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.to=function(b){var c=this,d=this.getItemIndex(this.$active=this.$element.find(".item.active"));return b>this.$items.length-1||0>b?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){c.to(b)}):d==b?this.pause().cycle():this.slide(b>d?"next":"prev",a(this.$items[b]))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,c){var d=this.$element.find(".item.active"),e=c||d[b](),f=this.interval,g="next"==b?"left":"right",h="next"==b?"first":"last",i=this;if(!e.length){if(!this.options.wrap)return;e=this.$element.find(".item")[h]()}if(e.hasClass("active"))return this.sliding=!1;var j=e[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:g});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,f&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(e)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:g});return a.support.transition&&this.$element.hasClass("slide")?(e.addClass(b),e[0].offsetWidth,d.addClass(g),e.addClass(g),d.one("bsTransitionEnd",function(){e.removeClass([b,g].join(" ")).addClass("active"),d.removeClass(["active",g].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(1e3*d.css("transition-duration").slice(0,-1))):(d.removeClass("active"),e.addClass("active"),this.sliding=!1,this.$element.trigger(m)),f&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this},a(document).on("click.bs.carousel.data-api","[data-slide], [data-slide-to]",function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}}),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.collapse"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b);!e&&f.toggle&&"show"==b&&(b=!b),e||d.data("bs.collapse",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.transitioning=null,this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()};c.VERSION="3.2.0",c.DEFAULTS={toggle:!0},c.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},c.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var c=a.Event("show.bs.collapse");if(this.$element.trigger(c),!c.isDefaultPrevented()){var d=this.$parent&&this.$parent.find("> .panel > .in");if(d&&d.length){var e=d.data("bs.collapse");if(e&&e.transitioning)return;b.call(d,"hide"),e||d.data("bs.collapse",null)}var f=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[f](0),this.transitioning=1;var g=function(){this.$element.removeClass("collapsing").addClass("collapse in")[f](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return g.call(this);var h=a.camelCase(["scroll",f].join("-"));this.$element.one("bsTransitionEnd",a.proxy(g,this)).emulateTransitionEnd(350)[f](this.$element[0][h])}}},c.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"),this.transitioning=1;var d=function(){this.transitioning=0,this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(d,this)).emulateTransitionEnd(350):d.call(this)}}},c.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};var d=a.fn.collapse;a.fn.collapse=b,a.fn.collapse.Constructor=c,a.fn.collapse.noConflict=function(){return a.fn.collapse=d,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(c){var d,e=a(this),f=e.attr("data-target")||c.preventDefault()||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""),g=a(f),h=g.data("bs.collapse"),i=h?"toggle":e.data(),j=e.attr("data-parent"),k=j&&a(j);h&&h.transitioning||(k&&k.find('[data-toggle="collapse"][data-parent="'+j+'"]').not(e).addClass("collapsed"),e[g.hasClass("in")?"addClass":"removeClass"]("collapsed")),b.call(g,i)})}(jQuery),+function(a){"use strict";function b(b){b&&3===b.which||(a(e).remove(),a(f).each(function(){var d=c(a(this)),e={relatedTarget:this};d.hasClass("open")&&(d.trigger(b=a.Event("hide.bs.dropdown",e)),b.isDefaultPrevented()||d.removeClass("open").trigger("hidden.bs.dropdown",e))}))}function c(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.2.0",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=c(e),g=f.hasClass("open");if(b(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a('
').insertAfter(a(this)).on("click",b);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus"),f.toggleClass("open").trigger("shown.bs.dropdown",h)}return!1}},g.prototype.keydown=function(b){if(/(38|40|27)/.test(b.keyCode)){var d=a(this);if(b.preventDefault(),b.stopPropagation(),!d.is(".disabled, :disabled")){var e=c(d),g=e.hasClass("open");if(!g||g&&27==b.keyCode)return 27==b.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.divider):visible a",i=e.find('[role="menu"]'+h+', [role="listbox"]'+h);if(i.length){var j=i.index(i.filter(":focus"));38==b.keyCode&&j>0&&j--,40==b.keyCode&&j').appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus.call(this.$element[0]):this.hide.call(this))},this)),e&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;e?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(150):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var f=function(){c.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",f).emulateTransitionEnd(150):f()}else b&&b()},c.prototype.checkScrollbar=function(){document.body.clientWidth>=window.innerWidth||(this.scrollbarWidth=this.scrollbarWidth||this.measureScrollbar())},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.scrollbarWidth&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right","")},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b;(e||"destroy"!=b)&&(e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null,this.init("tooltip",a,b)};c.VERSION="3.2.0",c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(this.options.viewport.selector||this.options.viewport);for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show()},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide()},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var c=a.contains(document.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!c)return;var d=this,e=this.tip(),f=this.getUID(this.type);this.setContent(),e.attr("id",f),this.$element.attr("aria-describedby",f),this.options.animation&&e.addClass("fade");var g="function"==typeof this.options.placement?this.options.placement.call(this,e[0],this.$element[0]):this.options.placement,h=/\s?auto?\s?/i,i=h.test(g);i&&(g=g.replace(h,"")||"top"),e.detach().css({top:0,left:0,display:"block"}).addClass(g).data("bs."+this.type,this),this.options.container?e.appendTo(this.options.container):e.insertAfter(this.$element);var j=this.getPosition(),k=e[0].offsetWidth,l=e[0].offsetHeight;if(i){var m=g,n=this.$element.parent(),o=this.getPosition(n);g="bottom"==g&&j.top+j.height+l-o.scroll>o.height?"top":"top"==g&&j.top-o.scroll-l<0?"bottom":"right"==g&&j.right+k>o.width?"left":"left"==g&&j.left-kg.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;jg.width&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){return this.$tip=this.$tip||a(this.options.template)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.validate=function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){clearTimeout(this.timeout),this.hide().$element.off("."+this.type).removeData("bs."+this.type)};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||"destroy"!=b)&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.2.0",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:''}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").empty()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},c.prototype.tip=function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){var e=a.proxy(this.process,this);this.$body=a("body"),this.$scrollElement=a(a(c).is("body")?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",e),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.2.0",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b="offset",c=0;a.isWindow(this.$scrollElement[0])||(b="position",c=this.$scrollElement.scrollTop()),this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight();var d=this;this.$body.find(this.selector).map(function(){var d=a(this),e=d.data("target")||d.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[b]().top+c,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){d.offsets.push(this[0]),d.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<=e[0])return g!=(a=f[0])&&this.activate(a);for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(!e[a+1]||b<=e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,a(this.selector).parentsUntil(this.options.target,".active").removeClass("active");var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.2.0",c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a")[0],f=a.Event("show.bs.tab",{relatedTarget:e});if(b.trigger(f),!f.isDefaultPrevented()){var g=a(d);this.activate(b.closest("li"),c),this.activate(g,g.parent(),function(){b.trigger({type:"shown.bs.tab",relatedTarget:e})})}}},c.prototype.activate=function(b,c,d){function e(){f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),b.addClass("active"),g?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active"),d&&d()}var f=c.find("> .active"),g=d&&a.support.transition&&f.hasClass("fade");g?f.one("bsTransitionEnd",e).emulateTransitionEnd(150):e(),f.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this},a(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(c){c.preventDefault(),b.call(a(this),"show")})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=this.unpin=this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.2.0",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=a(document).height(),d=this.$target.scrollTop(),e=this.$element.offset(),f=this.options.offset,g=f.top,h=f.bottom;"object"!=typeof f&&(h=g=f),"function"==typeof g&&(g=f.top(this.$element)),"function"==typeof h&&(h=f.bottom(this.$element));var i=null!=this.unpin&&d+this.unpin<=e.top?!1:null!=h&&e.top+this.$element.height()>=b-h?"bottom":null!=g&&g>=d?"top":!1;if(this.affixed!==i){null!=this.unpin&&this.$element.css("top","");var j="affix"+(i?"-"+i:""),k=a.Event(j+".bs.affix");this.$element.trigger(k),k.isDefaultPrevented()||(this.affixed=i,this.unpin="bottom"==i?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(j).trigger(a.Event(j.replace("affix","affixed"))),"bottom"==i&&this.$element.offset({top:b-this.$element.height()-h}))}}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},d.offsetBottom&&(d.offset.bottom=d.offsetBottom),d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);
--------------------------------------------------------------------------------
/static/js/css.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by CQ on 14-9-14.
3 | */
4 | $("#title").css("top",$(window).height()/2-200+"px");
5 | $("#title").css("left",$(window).width()/2-150+"px");
6 | $("#information").css("height",$(window).height()-200+"px");
--------------------------------------------------------------------------------
/static/js/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by CQ on 14-9-14.
3 | */
4 | var username,password,remember;
5 | $(".jobChoose").click(function(){
6 | switch (this.value){
7 | case "1":
8 | $("#jobChose").val(1);
9 | $("#introduce").text("学神,让你学得笑,笑出声。");
10 | break;
11 | case "2":
12 | $("#jobChose").val(2);
13 | $("#introduce").text("大牛,比大神更大,岂止于大。");
14 | break;
15 | case "3":
16 | $("#jobChose").val(3);
17 | $("#introduce").text("弱菜,自己的大事,大块所有人心的大好事。");
18 | break;
19 | default :
20 | break;
21 | }
22 | })
23 | function msgAdd(msg){
24 | $("#information").append(""+msg+"
");
25 | document.getElementById("information").scrollTop = document.getElementById("information").scrollHeight;
26 | }
27 | $("#applyAction").click(function(){
28 | var command =$("#actions").val();
29 | msgAdd(command+"
");
30 | $("#actions").val("");
31 | $.post('/main',{orderContent:command}, function(data, textStatus){
32 | msgAdd(data+"
");
33 | });
34 | });
--------------------------------------------------------------------------------
/templates/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yichenluan/dayBit/9dbe822aafeee3a111c30a286fcb4a92d158fed5/templates/.DS_Store
--------------------------------------------------------------------------------
/templates/choice.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | dayBit
6 |
7 |
8 |
9 |
10 |
11 |
12 |
39 |
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/templates/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | dayBit
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
dayBit
14 |
15 |
16 |
17 |
20 |
21 |
27 |
30 |
31 | {% if signUpInfo %}
32 | {% for msg in signUpInfo %}
33 |
34 |
35 | {{ msg }}
36 |
37 | {% end %}
38 | {% end %}
39 |
40 |
41 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
--------------------------------------------------------------------------------
/templates/main.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | dayBit
6 |
7 |
8 |
9 |
10 |
11 |
12 |
角色信息
13 |
14 | {% if roleList %}
15 | {% for role in roleList %}
16 | {% if role.roletype == 1 %}
17 | 学神
18 | {% elif role.roletype == 2 %}
19 | 大牛
20 | {% elif role.roletype == 3 %}
21 | 弱菜
22 | {% end %}
23 |
24 | {{role.rolenick}}
25 |
26 | {% end %}
27 | {% end %}
28 |
29 |
登出
30 |
34 |
35 |
39 |
40 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
--------------------------------------------------------------------------------
/templates/report.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | dayBit
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
角色信息一览
14 |
15 |
16 |
17 |
18 |
19 | 角色名
20 |
21 | |
22 | {{ info['roleName'] }}
23 | |
24 |
25 |
26 | 杀怪数
27 |
28 | |
29 | {{ info['roleKillEnemy'] }}
30 | |
31 |
32 |
33 | 总获得经验值
34 |
35 | |
36 | {{ info['roleTotalExp'] }}
37 | |
38 |
39 |
40 | 总获得装备数
41 |
42 | |
43 | {{ info['roleGetEquip'] }}
44 | |
45 |
46 |
47 | 死亡次数
48 |
49 | |
50 | {{ info['roleKilledByEnemy'] }}
51 | |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
--------------------------------------------------------------------------------
/templates/test.html:
--------------------------------------------------------------------------------
1 |
2 | {% if message %}
3 | {% for msg in message %}
4 | {{msg}}
5 |
6 | {% end %}
7 | {% end %}
8 |
--------------------------------------------------------------------------------
/urls.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | # -*- coding: utf-8 -*-
3 |
4 | import dayBit
5 |
6 | urls = [
7 | (r"/", dayBit.IndexHandler),
8 | (r"/signIn", dayBit.SignInHandler),
9 | (r"/signUp", dayBit.SignUpHandler),
10 | (r"/chooseRole", dayBit.ChooseRoleHandler),
11 | (r"/addRole", dayBit.AddRoleHandler),
12 | (r"/main", dayBit.MainHandler),
13 | (r"/signOut", dayBit.SignOutHandler),
14 | (r"/deleteRole", dayBit.DeleteRoleHandler),
15 | (r"/showForms", dayBit.ShowFormsHandler),
16 | ]
--------------------------------------------------------------------------------