Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 60587f0

Browse files
更新了部分文档和代码
1 parent 3ef3721 commit 60587f0

106 files changed

Lines changed: 1143 additions & 2110 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎Day01-15/12.字符串和正则表达式.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
| \| | 分支 | foo\|bar | 可以匹配foo或者bar |
3333
| (?#) | 注释 | | |
3434
| (exp) | 匹配exp并捕获到自动命名的组中 | | |
35-
| (? <name>exp) | 匹配exp并捕获到名为name的组中 | | |
35+
| (?<name>exp) | 匹配exp并捕获到名为name的组中 | | |
3636
| (?:exp) | 匹配exp但是不捕获匹配的文本 | | |
3737
| (?=exp) | 匹配exp前面的位置 | \\b\\w+(?=ing) | 可以匹配I'm dancing中的danc |
3838
| (?<=exp) | 匹配exp后面的位置 | (?<=\\bdanc)\\w+\\b | 可以匹配I love dancing and reading中的第一个ing |

‎Day21-30/code/list_by_vue.html‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
</li>
6969
</ul>
7070
<div>
71-
<input @keydown.enter="addItem()" type="text" id="fname" v-model="fname">
71+
<input @keydown.enter="addItem()" type="text" id="fname" v-model.trim="fname">
7272
<button id="ok" @click="addItem()">确定</button>
7373
</div>
7474
</div>
@@ -82,8 +82,8 @@
8282
},
8383
methods: {
8484
addItem() {
85-
if (this.fname.trim().length > 0) {
86-
this.fruits.push(this.fname.trim())
85+
if (this.fname.length > 0) {
86+
this.fruits.push(this.fname)
8787
}
8888
this.fname = ''
8989
},
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
<div class="search">
6666
<!-- type属性是text的input标签代表文本框 可以接收用户输入 -->
6767
<!-- placeholder是文本框的输入提示 -->
68-
<input type="text" placeholder="请输入垃圾名字" v-model="word" @keydown.enter="search()">
68+
<input type="text" placeholder="请输入垃圾名字" v-model.trim="word" @keydown.enter="search()">
6969
<!-- button代表按钮 点击可以开始查询 -->
7070
<button @click="search()">查询</button>
7171
</div>
@@ -75,9 +75,9 @@
7575
<div v-for="result in results">
7676
<p>
7777
<!-- img是图像标签 可以用来实现图片-->
78-
<img :src="pictures[result.type]" width="56" :alt="types[result.type]">
78+
<img :src="'images/' + pictures[result.type]" width="56" :alt="types[result.type]">
7979
&nbsp;&nbsp;
80-
<!-- span是跨度标签 代表一个逻辑区域(不分段)-->
80+
<!-- span是跨度标签 代表一个逻辑区域-->
8181
<span>{{ result.name }}</span>
8282
&nbsp;&nbsp;
8383
<span class="pre" v-if="result.aipre == 1">(预测结果)</span>
@@ -102,7 +102,7 @@
102102
// 查询垃圾分类的函数
103103
search() {
104104
if (this.word.trim().length > 0) {
105-
let key = '9aeb28ee8858a167c1755f856f830e22'
105+
let key = '9636cec76ee2593ba6b195e5b770b394'
106106
let url = `http://api.tianapi.com/txapi/lajifenlei/?key=${key}&word=${this.word}`
107107
fetch(url)
108108
.then(resp => resp.json())

‎Day36-40/36-38.关系型数据库MySQL.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ MySQL在过去由于性能高、成本低、可靠性好,已经成为最流行
7474
```Shell
7575
rpm -ivh mysql-community-common-5.7.26-1.el7.x86_64.rpm
7676
rpm -ivh mysql-community-libs-5.7.26-1.el7.x86_64.rpm
77+
rpm -ivh mysql-community-libs-compat-5.7.26-1.el7.x86_64.rpm
78+
rpm -ivh mysql-community-devel-5.7.26-1.el7.x86_64.rpm
7779
rpm -ivh mysql-community-client-5.7.26-1.el7.x86_64.rpm
7880
rpm -ivh mysql-community-server-5.7.26-1.el7.x86_64.rpm
7981
```

‎Day36-40/code/HRS_create_and_init.sql‎

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
drop database if exists hrs;
2-
create database hrs default charset utf8;
2+
create database hrs default charset utf8mb4;
33

44
use hrs;
55

@@ -14,6 +14,8 @@ dloc varchar(20) not null comment '所在地',
1414
primary key (dno)
1515
);
1616

17+
-- alter table tb_dept add constraint pk_dept_dno primary key(dno);
18+
1719
insert into tb_dept values
1820
(10, '会计部', '北京'),
1921
(20, '研发部', '成都'),
@@ -29,11 +31,13 @@ mgr int comment '主管编号',
2931
sal int not null comment '员工月薪',
3032
comm int comment '每月补贴',
3133
dno int comment '所在部门编号',
32-
primary key (eno)
34+
primary key (eno),
35+
foreign key (dno) references tb_dept(dno),
36+
foreign key (mgr) references tb_emp(eno)
3337
);
3438

35-
alter table tb_emp add constraint fk_emp_mgr foreign key (mgr) references tb_emp (eno);
36-
alter table tb_emp add constraint fk_emp_dno foreign key (dno) references tb_dept (dno);
39+
--alter table tb_emp add constraint fk_emp_mgr foreign key (mgr) references tb_emp (eno);
40+
--alter table tb_emp add constraint fk_emp_dno foreign key (dno) references tb_dept (dno);
3741

3842
insert into tb_emp values
3943
(7800, '张三丰', '总裁', null, 9000, 1200, 20),
@@ -70,4 +74,4 @@ insert into tb_emp values
7074

7175
-- 查询主管的姓名和职位
7276

73-
-- 查询月薪排名4~6名的员工姓名和月薪
77+
-- 查询月薪排名4~6名的员工排名、姓名和月薪

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /