今天完成了用户界面的绝大部分

 

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
</head>
<body>
<div id="app">

<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="用户管理" name="first">
<!-- 个人信息界面-->

<span slot="label"><i class="el-icon-date"></i> 个人信息</span>

<el-descriptions class="margin-top" title="带边框列表" :column="3" :size="size" border style="margin-left: 8%;margin-right: 8%">
<template slot="extra">
<el-button type="primary" size="small">操作</el-button>
</template>
<el-descriptions-item>
<template slot="label">
<i class="el-icon-user"></i>
姓名
</template>
{{seeker.name}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
<i class="el-icon-mobile-phone"></i>
手机号
</template>
{{seeker.phone}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
<!-- <i class="el-icon-location-outline"></i>-->
出生日期
</template>
{{seeker.birthday}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
<i class="el-icon-tickets"></i>
学历
</template>

{{seeker.degree}}
</el-descriptions-item>


<el-descriptions-item>
<template slot="label">
<i class="el-icon-tickets"></i>
意向岗位
</template>

{{seeker.hopePost}}
</el-descriptions-item>

<el-descriptions-item>
<template slot="label">
<i class="el-icon-tickets"></i>
期望薪资
</template>

{{seeker.hopeSalary}}
</el-descriptions-item>


<el-descriptions-item>
<template slot="label">
<i class="el-icon-tickets"></i>
实习经历
</template>
{{seeker.experienced}}
</el-descriptions-item>

<el-descriptions-item>
<template slot="label">
<i class="el-icon-tickets"></i>
专业技能
</template>

{{seeker.skill}}
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
<i class="el-icon-office-building"></i>
个人优势
</template>
{{seeker.advantage}}
</el-descriptions-item>
</el-descriptions>
</el-tab-pane>






<!-- <el-tab-pane label="公司推荐" name="second">公司推荐-->
<!-- <template>-->
<!-- <el-table-->
<!-- :data="tableData"-->
<!-- style="width: 100%"-->
<!-- :row-class-name="tableRowClassName"-->
<!-- @selection-change="handleSelectionChange"-->
<!-- >-->
<!-- <el-table-column-->
<!-- type="selection"-->
<!-- width="55">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- type="index"-->
<!-- width="50">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- prop="brandName"-->
<!-- label="品牌名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="companyName"-->
<!-- label="企业名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="ordered"-->
<!-- align="center"-->
<!-- label="排序">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="status"-->
<!-- align="center"-->
<!-- label="当前状态">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- align="center"-->
<!-- label="操作">-->

<!-- <el-row>-->
<!-- <el-button type="primary">查看</el-button>-->
<!-- <el-button type="danger">收藏</el-button>-->
<!-- </el-row>-->

<!-- </el-table-column>-->

<!-- </el-table>-->
<!-- </template>-->
<!-- </el-tab-pane>-->


<!-- <el-tab-pane label="我的收藏" name="third">我的收藏-->
<!-- <template>-->
<!-- <el-table-->
<!-- :data="tableData"-->
<!-- style="width: 100%"-->
<!-- :row-class-name="tableRowClassName"-->
<!-- @selection-change="handleSelectionChange"-->
<!-- >-->
<!-- <el-table-column-->
<!-- type="selection"-->
<!-- width="55">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- type="index"-->
<!-- width="50">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- prop="brandName"-->
<!-- label="品牌名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="companyName"-->
<!-- label="企业名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="ordered"-->
<!-- align="center"-->
<!-- label="排序">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="status"-->
<!-- align="center"-->
<!-- label="当前状态">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- align="center"-->
<!-- label="操作">-->

<!-- <el-row>-->
<!-- <el-button type="primary">查看</el-button>-->
<!-- <el-button type="danger">收藏</el-button>-->
<!-- </el-row>-->

<!-- </el-table-column>-->

<!-- </el-table>-->
<!-- </template>-->
<!-- </el-tab-pane>-->



<!-- <el-tab-pane label="我的消息" name="fourth">我的消息-->
<!-- <template>-->
<!-- <el-table-->
<!-- :data="tableData"-->
<!-- style="width: 100%"-->
<!-- :row-class-name="tableRowClassName"-->
<!-- @selection-change="handleSelectionChange"-->
<!-- >-->
<!-- <el-table-column-->
<!-- type="selection"-->
<!-- width="55">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- type="index"-->
<!-- width="50">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- prop="brandName"-->
<!-- label="品牌名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="companyName"-->
<!-- label="企业名称"-->
<!-- align="center"-->
<!-- >-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="ordered"-->
<!-- align="center"-->
<!-- label="排序">-->
<!-- </el-table-column>-->
<!-- <el-table-column-->
<!-- prop="status"-->
<!-- align="center"-->
<!-- label="当前状态">-->
<!-- </el-table-column>-->

<!-- <el-table-column-->
<!-- align="center"-->
<!-- label="操作">-->

<!-- <el-row>-->
<!-- <el-button type="primary">查看</el-button>-->
<!-- <el-button type="danger">收藏</el-button>-->
<!-- </el-row>-->

<!-- </el-table-column>-->

<!-- </el-table>-->
<!-- </template>-->
<!-- </el-tab-pane>-->
</el-tabs>


</div>
<script src="js/vue.js"></script>
<script src="js/axios-0.18.0.js"></script>
<script src="element-ui/lib/index.js"></script>
<!--<link rel="stylesheet" href="element-ui/lib/theme-chalk/index.css">-->
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
<!-- 引入组件库 -->
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
<script>
new Vue({
el: "#app",
mounted(){
var _this = this;
this.loginForm.username = localStorage.getItem("username"); //获取指定key本地存储的值
this.loginForm.password = localStorage.getItem("password"); //获取指定key本地存储的值
this.loginForm.type = localStorage.getItem("用户"); //获取指定key本地存储的值
axios({
method:"post",
url:"http://localhost:8080/jianli/seeker/loginSeeker",
data:_this.loginForm
}).then(function (resp){
_this.seeker = resp.data;
console.log("sdass"+_this.seeker)
})
},
methods: {
handleClick(tab, event) {
console.log(tab, event);
}
},
data() {
return {
loginForm: {
username: "", //账号
password: "", //密码
type:""//种类
},
//个人数据模型
seeker: {
id:'',
name:'',
phone:'',
birthday:'',
degree:'',
password:'',
workingHours:'',
hopePost:'',
hopeSalary:'6000-8000',
skill:'XXXXXXX',
advantage:'XXXXXXX',
experienced:'XXXXXXX'
},

input: '',
size: '',
activeName: 'second',
// 表格数据
tableData: [{
brandName: '华为',
companyName: '华为科技有限公司',
ordered: '100',
status: "1"
}, {
brandName: '华为',
companyName: '华为科技有限公司',
ordered: '100',
status: "1"
}, {
brandName: '华为',
companyName: '华为科技有限公司',
ordered: '100',
status: "1"
}, {
brandName: '华为',
companyName: '华为科技有限公司',
ordered: '100',
status: "1"
}]

}

}
})

</script>

</body>
</html>



package com.itheima.web;

import com.alibaba.fastjson.JSON;
import com.itheima.pojo.PageBeen;
import com.itheima.pojo.Seeker;
import com.itheima.service.PeopleService;
import com.itheima.service.impl.PeopleServiceImpl;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.BufferedReader;
import java.io.IOException;

@WebServlet("/seeker/*")
public class SeekerServlet extends BaseServlet{
private PeopleService service = new PeopleServiceImpl();

public void loginSeeker(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException {
System.out.println("seeker login...");

BufferedReader br = request.getReader();
String params = br.readLine();
PageBeen pageBeen = JSON.parseObject(params, PageBeen.class);

Seeker seeker = service.loginSeeker(pageBeen.getUsername(), pageBeen.getPassword());
System.out.println(seeker);
response.setContentType("text/json;charset=utf-8");

if(seeker != null){
String jsonString = JSON.toJSONString(seeker);
response.getWriter().write(jsonString);
}else{
System.out.println("error");
response.getWriter().write("error");
}
}
public void seekerRegister(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException {
System.out.println("seekerRegister...");

BufferedReader br = request.getReader();
String params = br.readLine();
Seeker seeker = JSON.parseObject(params, Seeker.class);
System.out.println(params);
service.insertSeeker(seeker);

response.setContentType("text/json;charset=utf-8");
response.getWriter().write("success");
}
}