Commit 680dfdeb authored by 郝聪敏's avatar 郝聪敏

添加eslint

parent c4c3cb8f
/build/ node_modules/*
/config/ build/*
/dist/ config/*
/*.js dist/*
lib/*
static/*
\ No newline at end of file
// https://eslint.org/docs/user-guide/configuring
module.exports = { module.exports = {
root: true, root: true,
parserOptions: { parserOptions: {
parser: 'babel-eslint' parser: 'babel-eslint',
}, },
env: { env: {
browser: true, browser: true,
}, },
// https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevention extends: [
// consider switching to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for stricter rules. 'plugin:vue/essential',
extends: ['plugin:vue/essential', 'airbnb-base'], 'standard',
// required to lint *.vue files ],
plugins: [ plugins: [
'vue' 'vue',
], ],
// check if imports actually resolve
settings: {
'import/resolver': {
webpack: {
config: 'build/webpack.base.conf.js'
}
}
},
// add your custom rules here
rules: { rules: {
// don't require .vue extension when importing
'import/extensions': ['error', 'always', {
js: 'never',
vue: 'never'
}],
// disallow reassignment of function parameters
// disallow parameter object manipulation except for specific exclusions
'no-param-reassign': ['error', {
props: true,
ignorePropertyModificationsFor: [
'state', // for vuex state
'acc', // for reduce accumulators
'e' // for e.returnvalue
]
}],
// allow optionalDependencies
'import/no-extraneous-dependencies': ['error', {
optionalDependencies: ['test/unit/index.js']
}],
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'global-require': 'off',
// allow async-await
'generator-star-spacing': 'off',
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
// 防止iview的标签报错 // 防止iview的标签报错
"vue/no-parsing-error": [1, { "x-invalid-end-tag": false }], "vue/no-parsing-error": [2, { "x-invalid-end-tag": false }],
"linebreak-style": 0, },
'indent': [0, 2],
"comma-dangle": 0,
"semi": 0,
"max-len": 0,
"no-tabs": 0,
"no-mixed-spaces-and-tabs": 0,
"eol-last": 0,
"key-spacing": 0
}
} }
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
"scripts": { "scripts": {
"dev": "webpack-dev-server --inline --progress --config build/webpack.dev.conf.js", "dev": "webpack-dev-server --inline --progress --config build/webpack.dev.conf.js",
"start": "npm run dev", "start": "npm run dev",
"lint": "eslint --ext .js,.vue src", "lint": "eslint --fix --cache --ext .js,.vue src",
"build": "node build/build.js" "build": "node build/build.js"
}, },
"dependencies": { "dependencies": {
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
"devDependencies": { "devDependencies": {
"autoprefixer": "^7.1.2", "autoprefixer": "^7.1.2",
"babel-core": "^6.22.1", "babel-core": "^6.22.1",
"babel-eslint": "^8.2.1", "babel-eslint": "^8.2.6",
"babel-helper-vue-jsx-merge-props": "^2.0.3", "babel-helper-vue-jsx-merge-props": "^2.0.3",
"babel-loader": "^7.1.1", "babel-loader": "^7.1.1",
"babel-plugin-syntax-jsx": "^6.18.0", "babel-plugin-syntax-jsx": "^6.18.0",
...@@ -39,13 +39,17 @@ ...@@ -39,13 +39,17 @@
"chalk": "^2.0.1", "chalk": "^2.0.1",
"copy-webpack-plugin": "^4.0.1", "copy-webpack-plugin": "^4.0.1",
"css-loader": "^0.28.0", "css-loader": "^0.28.0",
"eslint": "^4.15.0", "eslint": "^5.16.0",
"eslint-config-airbnb-base": "^11.3.0", "eslint-config-airbnb-base": "^11.3.0",
"eslint-config-standard": "^14.1.0",
"eslint-friendly-formatter": "^3.0.0", "eslint-friendly-formatter": "^3.0.0",
"eslint-import-resolver-webpack": "^0.8.3", "eslint-import-resolver-webpack": "^0.8.3",
"eslint-loader": "^1.7.1", "eslint-loader": "^1.9.0",
"eslint-plugin-import": "^2.7.0", "eslint-plugin-import": "^2.19.1",
"eslint-plugin-vue": "^4.0.0", "eslint-plugin-node": "^10.0.0",
"eslint-plugin-promise": "^4.2.1",
"eslint-plugin-standard": "^4.0.1",
"eslint-plugin-vue": "^6.0.1",
"extract-text-webpack-plugin": "^3.0.0", "extract-text-webpack-plugin": "^3.0.0",
"file-loader": "^1.1.4", "file-loader": "^1.1.4",
"friendly-errors-webpack-plugin": "^1.6.1", "friendly-errors-webpack-plugin": "^1.6.1",
...@@ -69,7 +73,8 @@ ...@@ -69,7 +73,8 @@
"webpack": "^3.6.0", "webpack": "^3.6.0",
"webpack-bundle-analyzer": "^2.9.0", "webpack-bundle-analyzer": "^2.9.0",
"webpack-dev-server": "^2.9.1", "webpack-dev-server": "^2.9.1",
"webpack-merge": "^4.1.0" "webpack-merge": "^4.1.0",
"husky": "^3.1.0"
}, },
"engines": { "engines": {
"node": ">= 6.0.0", "node": ">= 6.0.0",
...@@ -79,5 +84,10 @@ ...@@ -79,5 +84,10 @@
"> 1%", "> 1%",
"last 2 versions", "last 2 versions",
"not ie <= 8" "not ie <= 8"
] ],
"husky": {
"hooks": {
"pre-commit": "npm run lint"
}
}
} }
\ No newline at end of file
...@@ -5,21 +5,21 @@ ...@@ -5,21 +5,21 @@
</template> </template>
<script> <script>
window.onload = function() { window.onload = function () {
  document.addEventListener('touchstart', function(event) { document.addEventListener('touchstart', function (event) {
    if (event.touches.length > 1) { if (event.touches.length > 1) {
      event.preventDefault() event.preventDefault()
    } }
  }) })
  document.addEventListener('gesturestart', function(event) { document.addEventListener('gesturestart', function (event) {
    event.preventDefault() event.preventDefault()
  }) })
} }
export default { export default {
name: 'App', name: 'App',
data() { data () {
return { return {
appClass: 'pc', appClass: 'pc'
} }
}, },
created: function () { created: function () {
...@@ -27,7 +27,7 @@ export default { ...@@ -27,7 +27,7 @@ export default {
this.appClass = 'mobile' this.appClass = 'mobile'
} }
} }
}; }
</script> </script>
<style> <style>
...@@ -48,7 +48,6 @@ export default { ...@@ -48,7 +48,6 @@ export default {
-ms-user-select: text !important; /*IE10*/ -ms-user-select: text !important; /*IE10*/
user-select: text !important; user-select: text !important;
} }
.pc { .pc {
height: 100%; height: 100%;
......
...@@ -4,34 +4,44 @@ import { ...@@ -4,34 +4,44 @@ import {
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
// 获取个人信息 // 获取个人信息
export function getpersonMassage(params) { export function getpersonMassage (params) {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.get(`${sapi}/api/login/me`,params,{headers: { return axios.get(`${sapi}/api/login/me`, params, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 用户退出 // 用户退出
export function loginOUT() { export function loginOUT () {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.get(`${sapi}/api/login/logout`,{headers: { return axios.get(`${sapi}/api/login/logout`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//通过某一来源查询简历信息 // 通过某一来源查询简历信息
export function adoptOneSeeResumeList(parmars) { export function adoptOneSeeResumeList (parmars) {
return axios.post(`${sapi}/api/resume/findListBySource`,parmars,{headers: { return axios.post(`${sapi}/api/resume/findListBySource`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//通过渠道机简历信息 // 通过渠道机简历信息
export function getChannelMassage() { export function getChannelMassage () {
return axios.get(`${sapi}/api/resume/getSourceList`,{headers: { return axios.get(`${sapi}/api/resume/getSourceList`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 判断是否为超级管理员 // 判断是否为超级管理员
export function judeAdmin() { export function judeAdmin () {
return axios.get(`${sapi}/api/user/isAdmin`,{headers: { return axios.get(`${sapi}/api/user/isAdmin`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
...@@ -4,69 +4,89 @@ import { ...@@ -4,69 +4,89 @@ import {
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
// 更改约面信息 // 更改约面信息
export function changeinterviewMassage(parmars) { export function changeinterviewMassage (parmars) {
return axios.post(`${sapi}/api/resumeInterview/update`,parmars,{headers: { return axios.post(`${sapi}/api/resumeInterview/update`, parmars, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
// 重启面试 // 重启面试
export function oppenInterview(tid,tstatus) { export function oppenInterview (tid, tstatus) {
console.log(tid,tstatus) console.log(tid, tstatus)
return axios.post(`${sapi}/api/resumeFlow/reset/${tid}/${tstatus}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/reset/${tid}/${tstatus}`, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
// 终止面试 // 终止面试
export function SInterview(tid) { export function SInterview (tid) {
return axios.post(`${sapi}/api/resumeFlow/end/${tid}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/end/${tid}`, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
// 面试管理查询 // 面试管理查询
export function SerchList(parmars, status) { export function SerchList (parmars, status) {
return axios.post(`${sapi}/api/interview/findListByQueryVO`,parmars,{headers: { return axios.post(`${sapi}/api/interview/findListByQueryVO`, parmars, {
'Content-Type':'application/json;', headers: {
'X-Requested-With':'XMLHttpRequest', 'Content-Type': 'application/json;',
'X-Requested-With': 'XMLHttpRequest',
status status
}}) }
})
} }
//查看简历详情页 // 查看简历详情页
export function seedetail (parmars) { export function seedetail (parmars) {
return axios.get(`${sapi}/api/html/get/${parmars.uid}`,{headers: { return axios.get(`${sapi}/api/html/get/${parmars.uid}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//面试官查询 // 面试官查询
export function Serchinterviewor() { export function Serchinterviewor () {
return axios.get(`${sapi}/api/interview/findInterviewerList`) return axios.get(`${sapi}/api/interview/findInterviewerList`)
} }
//邀约人查询 // 邀约人查询
export function SerchInvitationOwer() { export function SerchInvitationOwer () {
return axios.post(`${sapi}/api/interview/findInviterList`,{headers: { return axios.post(`${sapi}/api/interview/findInviterList`, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
//新增约面信息 // 新增约面信息
export function NewAddInterview(parmars) { export function NewAddInterview (parmars) {
return axios.post(`${sapi}/api/resumeInterview/add`,parmars,{headers: { return axios.post(`${sapi}/api/resumeInterview/add`, parmars, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
// 查询记录 // 查询记录
export function recodeLIST (parmars) { export function recodeLIST (parmars) {
return axios.post(`${sapi}/api/resumeFlow/history/${parmars.resumeId}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/history/${parmars.resumeId}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 变更状态 // 变更状态
export function changestatus (tid,tstatus) { export function changestatus (tid, tstatus) {
return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${tid}/${tstatus}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${tid}/${tstatus}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 获取终止面试前的前一个状态 // 获取终止面试前的前一个状态
export function formstatus (parmars) { export function formstatus (parmars) {
return axios.post(`${sapi}/api/resumeFlow/getPreReset/${parmars.resumeId}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/getPreReset/${parmars.resumeId}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
...@@ -3,17 +3,21 @@ import { ...@@ -3,17 +3,21 @@ import {
sapi sapi
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
//登录 // 登录
export function login(params) { export function login (params) {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.post(`${sapi}/api/login/doLogin`,params,{headers: { return axios.post(`${sapi}/api/login/doLogin`, params, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//修改密码 // 修改密码
export function updatePsd(params) { export function updatePsd (params) {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.post(`${sapi}/api/login/modifyPassword`,params,{headers: { return axios.post(`${sapi}/api/login/modifyPassword`, params, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
...@@ -4,156 +4,201 @@ import { ...@@ -4,156 +4,201 @@ import {
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
// 查询简历列表 // 查询简历列表
export function serchList(parmars){ export function serchList (parmars) {
return axios.post(`${sapi}/api/resume/findList`,parmars,{headers: { return axios.post(`${sapi}/api/resume/findList`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 下载简历(单条) // 下载简历(单条)
export function downloadone (parmars) { export function downloadone (parmars) {
parmars=qs.stringify(parmars) parmars = qs.stringify(parmars)
return axios.post(`${sapi}/api/resumeFile/download/formatted/one`,parmars,{headers: { return axios.post(`${sapi}/api/resumeFile/download/formatted/one`, parmars, {
'Content-Type':'application/x-www-form-urlencoded' headers: {
}}) 'Content-Type': 'application/x-www-form-urlencoded'
}
})
} }
// 搜索 // 搜索
export function sousuoList (parmars, status) { export function sousuoList (parmars, status) {
return axios.post(`${sapi}/api/resume/findListByQueryVO`,parmars,{headers: { return axios.post(`${sapi}/api/resume/findListByQueryVO`, parmars, {
'Content-Type':'application/json', headers: {
'Content-Type': 'application/json',
status status
}}) }
})
} }
//查看简历详情页 // 查看简历详情页
export function seedetail (parmars) { export function seedetail (parmars) {
return axios.get(`${sapi}/api/html/get/${parmars.uid}`,{headers: { return axios.get(`${sapi}/api/html/get/${parmars.uid}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 简历pass // 简历pass
export function PASS (parmars) { export function PASS (parmars) {
return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`,'',{headers: { return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`, '', {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//待处理 // 待处理
export function TODORes (parmars) { export function TODORes (parmars) {
return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`,'',{headers: { return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`, '', {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 备选 // 备选
export function OPTION (parmars) { export function OPTION (parmars) {
return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`,'',{headers: { return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`, '', {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 删除简历 // 删除简历
export function deleteREsume (deleteallArr) { export function deleteREsume (deleteallArr) {
return axios.post(`${sapi}/api/resume/delete`,JSON.stringify(deleteallArr),{headers: { return axios.post(`${sapi}/api/resume/delete`, JSON.stringify(deleteallArr), {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 单条下载简历 // 单条下载简历
export function downloadOne (parmars) { export function downloadOne (parmars) {
return axios.get(`${sapi}/api/resume/download/formatted/one?resumeId=${parmars.resumeId}`,{headers: { return axios.get(`${sapi}/api/resume/download/formatted/one?resumeId=${parmars.resumeId}`, {
headers: {
// 'Content-Type':'application/x-www-form-urlencoded' // 'Content-Type':'application/x-www-form-urlencoded'
}}) }
})
} }
// 批量下载简历 // 批量下载简历
export function downloadALL () { export function downloadALL () {
return axios.get(`${sapi}/api/resumeFile/download/formatted/compress`,{headers: { return axios.get(`${sapi}/api/resumeFile/download/formatted/compress`, {
'Content-Type':'application/x-www-form-urlencoded' headers: {
}}) 'Content-Type': 'application/x-www-form-urlencoded'
}
})
} }
// 导出列表 // 导出列表
export function exportLIST (parmars) { export function exportLIST (parmars) {
return axios.get(`${sapi}/api/excel/output?optSource=${parmars.optSource}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}`, return axios.get(`${sapi}/api/excel/output?optSource=${parmars.optSource}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}`,
{headers: { {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 操作记录 // 操作记录
export function recodeLIST (parmars) { export function recodeLIST (parmars) {
return axios.post(`${sapi}/api/resumeFlow/history/${parmars.resumeId}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/history/${parmars.resumeId}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//通过某一来源查询简历信息 // 通过某一来源查询简历信息
export function adoptOneSeeResumeList(parmars) { export function adoptOneSeeResumeList (parmars) {
return axios.post(`${sapi}/api/resume/findListBySource`,parmars,{headers: { return axios.post(`${sapi}/api/resume/findListBySource`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 新增约面信息 // 新增约面信息
export function addinterview(parmars) { export function addinterview (parmars) {
return axios.post(`${sapi}/api/resumeInterview/add`,parmars,{headers: { return axios.post(`${sapi}/api/resumeInterview/add`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 修改流程状态 // 修改流程状态
export function updatastatus(parmars) { export function updatastatus (parmars) {
return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`,{headers: { return axios.post(`${sapi}/api/resumeFlow/uploadStatus/${parmars.id}/${parmars.status}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
} }
//获取邮件模板 })
export function getEmailMoo() { }
return axios.post(`${sapi}/api/emailTemplate/getAllTemplateList`,{headers: { // 获取邮件模板
'Content-Type':'application/json' export function getEmailMoo () {
}}) return axios.post(`${sapi}/api/emailTemplate/getAllTemplateList`, {
} headers: {
//根据获取id邮件模板内容 'Content-Type': 'application/json'
export function getEmailContent(parmars) { }
return axios.post(`${sapi}/api/emailTemplate/loadTemplate`,parmars,{headers: { })
'Content-Type':'application/json' }
}}) // 根据获取id邮件模板内容
} export function getEmailContent (parmars) {
//上传图片 return axios.post(`${sapi}/api/emailTemplate/loadTemplate`, parmars, {
export function uploadimage() { headers: {
return axios.get(`${sapi}/api/ckeditor/uploadImage`,{headers: { 'Content-Type': 'application/json'
'Content-Type':'application/json' }
}}) })
}
// 上传图片
export function uploadimage () {
return axios.get(`${sapi}/api/ckeditor/uploadImage`, {
headers: {
'Content-Type': 'application/json'
}
})
} }
// 发送邮件 // 发送邮件
export function sendEmail(parmars) { export function sendEmail (parmars) {
return axios.post(`${sapi}/api/sendMail/sendEmailTemplate`,parmars,{headers: { return axios.post(`${sapi}/api/sendMail/sendEmailTemplate`, parmars, {
'Content-Type':'multipart/form-data', headers: {
'Content-Type': 'multipart/form-data'
// 'Content-Disposition':'multipart/form-data' // 'Content-Disposition':'multipart/form-data'
// 'Content-Type':'application/json' // 'Content-Type':'application/json'
}}) }
})
} }
export function findCompanyEmailByKey(key) { //公司通讯录 export function findCompanyEmailByKey (key) { // 公司通讯录
return axios.get(`${sapi}/api/companyEmail/findCompanyEmailByKey?key=${key}`) return axios.get(`${sapi}/api/companyEmail/findCompanyEmailByKey?key=${key}`)
} }
// 转发邮箱通知 // 转发邮箱通知
export function forwardResume(params) { export function forwardResume (params) {
return axios.post(`${sapi}/api/resume/forwardResume`,params, {headers: { return axios.post(`${sapi}/api/resume/forwardResume`, params, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
export function getPdf(parmars) { export function getPdf (parmars) {
return axios.get(`${sapi}/api/resume/getResumePdfByResumeId/${parmars.uid}`,{ return axios.get(`${sapi}/api/resume/getResumePdfByResumeId/${parmars.uid}`, {
responseType: 'arraybuffer', responseType: 'arraybuffer',
headers: { headers: {
'Content-Type':'application/json' 'Content-Type': 'application/json'
} }
}) })
} }
// 是否展示原件的PDF // 是否展示原件的PDF
export function isShowPDF(parmars) { export function isShowPDF (parmars) {
return axios.get(`${sapi}/api/resume/isShowOriPdf/${parmars.uid}`, {headers: { return axios.get(`${sapi}/api/resume/isShowOriPdf/${parmars.uid}`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
} }
export function getpdfUrl(parmars) { })
return axios.get(`${sapi}/api/resume/getResumePdfUrl/${parmars.uid}`, {headers: { }
'Content-Type':'application/json' export function getpdfUrl (parmars) {
}}) return axios.get(`${sapi}/api/resume/getResumePdfUrl/${parmars.uid}`, {
} headers: {
//获取职位列表 'Content-Type': 'application/json'
export function getlist(parmars) { }
return axios.get(`${sapi}/api/resume/findPositionList?optSourceCode=${parmars.optSourceCode}`, {headers: { })
'Content-Type':'application/json' }
}}) // 获取职位列表
} export function getlist (parmars) {
return axios.get(`${sapi}/api/resume/findPositionList?optSourceCode=${parmars.optSourceCode}`, {
headers: {
'Content-Type': 'application/json'
}
})
}
...@@ -3,75 +3,99 @@ import { ...@@ -3,75 +3,99 @@ import {
sapi sapi
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
//账号列表查询 // 账号列表查询
export function queryaccountList(params) { export function queryaccountList (params) {
return axios.post(`${sapi}/api/user/findList`,params,{headers: { return axios.post(`${sapi}/api/user/findList`, params, {
'Content-Type':'application/json;', headers: {
}}) 'Content-Type': 'application/json;'
}
})
} }
//添加账户 // 添加账户
export function addAccount (params) { export function addAccount (params) {
return axios.post(`${sapi}/api/user/add`,params,{headers: { return axios.post(`${sapi}/api/user/add`, params, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//删除单条账户 // 删除单条账户
export function Delateaccount(parmars){ export function Delateaccount (parmars) {
return axios.get(`${sapi}/api/user/delete/${parmars.id}`,{headers: { return axios.get(`${sapi}/api/user/delete/${parmars.id}`, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//批量删除 // 批量删除
export function delateAllAccount(DelateARR){ export function delateAllAccount (DelateARR) {
return axios.post(`${sapi}//api/user/delete`,JSON.stringify(DelateARR),{headers: { return axios.post(`${sapi}//api/user/delete`, JSON.stringify(DelateARR), {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//恢复初始密码 // 恢复初始密码
export function recoveryPassword(parmars){ export function recoveryPassword (parmars) {
return axios.post(`${sapi}/api/user/initial/${parmars.id}`,{headers: { return axios.post(`${sapi}/api/user/initial/${parmars.id}`, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//查询邮箱列表 // 查询邮箱列表
export function queryemailList(parmars){ export function queryemailList (parmars) {
return axios.post(`${sapi}/api/email/list`,parmars,{headers: { return axios.post(`${sapi}/api/email/list`, parmars, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 同步邮箱 // 同步邮箱
export function Synchronization(parmars){ export function Synchronization (parmars) {
return axios.post(`${sapi}/api/email/bindAndSync`,parmars,{headers: { return axios.post(`${sapi}/api/email/bindAndSync`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 解绑邮箱 // 解绑邮箱
export function jiebangEmail(id){ export function jiebangEmail (id) {
return axios.post(`${sapi}/api/email/unbind/${id}`,{headers: { return axios.post(`${sapi}/api/email/unbind/${id}`, {
'Content-Type':'application/x-www-form-urlencoded' headers: {
}}) 'Content-Type': 'application/x-www-form-urlencoded'
}
})
} }
// 修改邮箱并重新绑定 // 修改邮箱并重新绑定
export function updateemailTWO(parmars){ export function updateemailTWO (parmars) {
return axios.post(`${sapi}/api/email/modify`,parmars,{headers: { return axios.post(`${sapi}/api/email/modify`, parmars, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
} }
})
}
// 批量解绑邮箱 // 批量解绑邮箱
export function UntyingAll(UntyingAllARR){ export function UntyingAll (UntyingAllARR) {
return axios.post(`${sapi}/api/email/unbind/batch`,JSON.stringify(UntyingAllARR),{headers: { return axios.post(`${sapi}/api/email/unbind/batch`, JSON.stringify(UntyingAllARR), {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 获取二维码 // 获取二维码
export function getErcode(){ export function getErcode () {
return axios.get(`${sapi}/api/qrCode/getInterviewQrcode`,{headers: { return axios.get(`${sapi}/api/qrCode/getInterviewQrcode`, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// //修改账户 // //修改账户
export function updateAccount(parmars){ export function updateAccount (parmars) {
return axios.post(`${sapi}/api/user/modify/${parmars.id}`,parmars,{headers: { return axios.post(`${sapi}/api/user/modify/${parmars.id}`, parmars, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
...@@ -4,8 +4,9 @@ import { ...@@ -4,8 +4,9 @@ import {
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
// 提交应聘登记表 // 提交应聘登记表
export function submitMassage(params) { export function submitMassage (params) {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.post(`${sapi}/api/interview/arrive`,params,{headers: { return axios.post(`${sapi}/api/interview/arrive`, params, {
'Content-Type':'application/json' }}) headers: { 'Content-Type': 'application/json' }
})
} }
...@@ -4,36 +4,46 @@ import { ...@@ -4,36 +4,46 @@ import {
} from '../config' } from '../config'
import qs from 'qs' import qs from 'qs'
// 获取上传批次号 // 获取上传批次号
export function getuploadNumber() { export function getuploadNumber () {
// params=qs.stringify(params) // params=qs.stringify(params)
return axios.get(`${sapi}/api/resume/upload/batchNum`,{headers: { return axios.get(`${sapi}/api/resume/upload/batchNum`, {
'Content-Type':'application/json' headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
//上传文件 // 上传文件
export function uploadfile(parmars) { export function uploadfile (parmars) {
return axios.post(`${sapi}/api/resume/upload`,parmars,{headers: { return axios.post(`${sapi}/api/resume/upload`, parmars, {
headers: {
// 'Content-Type':'multipart/form-data', // 'Content-Type':'multipart/form-data',
processData : false, processData: false,
contentType : false, contentType: false,
async: false, async: false
}}) }
})
} }
// 查询上传列表记录 // 查询上传列表记录
export function serchList(parmars) { export function serchList (parmars) {
return axios.post(`${sapi}/api/resume/upload/history`,parmars,{headers: { return axios.post(`${sapi}/api/resume/upload/history`, parmars, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 查询简历详情 // 查询简历详情
export function serchRESUMEdetail(parmars) { export function serchRESUMEdetail (parmars) {
return axios.get(`${sapi}/api/html/get/${parmars.uid}`,{headers: { return axios.get(`${sapi}/api/html/get/${parmars.uid}`, {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
// 查询简历详情 // 查询简历详情
export function deleteREsumeUPLOad(deleteallArr) { export function deleteREsumeUPLOad (deleteallArr) {
return axios.post(`${sapi}/api/resume/delete`,JSON.stringify(deleteallArr),{headers: { return axios.post(`${sapi}/api/resume/delete`, JSON.stringify(deleteallArr), {
'Content-Type':'application/json', headers: {
}}) 'Content-Type': 'application/json'
}
})
} }
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
</div> </div>
</template> </template>
<script type="text/ecmascript-6"> <script type="text/ecmascript-6">
import CKEDITOR from 'CKEDITOR'; import CKEDITOR from 'CKEDITOR'
export default { export default {
name: 'ckeditor', name: 'ckeditor',
props: { props: {
height: { height: {
...@@ -29,24 +29,24 @@ ...@@ -29,24 +29,24 @@
default: '' default: ''
} }
}, },
data() { data () {
return { return {
isInit: false isInit: false
}; }
}, },
watch: { watch: {
value:{ value: {
deep: true, deep: true,
immediate:true, immediate: true,
handler(value) { handler (value) {
this.isInit&&this.editor.setData(value.value) this.isInit && this.editor.setData(value.value)
} }
} }
}, },
mounted() { mounted () {
this.init() this.init()
}, },
beforeDestroy() { beforeDestroy () {
}, },
methods: { methods: {
init () { init () {
...@@ -57,18 +57,18 @@ ...@@ -57,18 +57,18 @@
lang: 'zh-cn', lang: 'zh-cn',
filebrowserImageUploadUrl: this.uploadUrl, filebrowserImageUploadUrl: this.uploadUrl,
filebrowserUploadMethod: 'form' filebrowserUploadMethod: 'form'
}); })
this.editor = CKEDITOR.instances.editor; this.editor = CKEDITOR.instances.editor
setTimeout(()=> { setTimeout(() => {
this.isInit = true this.isInit = true
}, 1000) }, 1000)
}, },
getValue(){ getValue () {
return this.editor.getData() return this.editor.getData()
} }
}, },
components: {} components: {}
}; }
</script> </script>
<style lang="less" rel="stylesheet/less" scoped> <style lang="less" rel="stylesheet/less" scoped>
......
...@@ -27,11 +27,11 @@ ...@@ -27,11 +27,11 @@
</div> </div>
</template> </template>
<script> <script>
import editor from './ckeditor.vue' import editor from './ckeditor.vue'
import {sapi} from '../config/index.js' import { sapi } from '../config/index.js'
import localStorage from '../service/localstorage.service.js' import localStorage from '../service/localstorage.service.js'
export default { export default {
data () { data () {
return { return {
modal: true, modal: true,
...@@ -49,9 +49,16 @@ ...@@ -49,9 +49,16 @@
}, },
ruleInline: { ruleInline: {
user: [ user: [
{ required: false, message: 'Please fill in the user name', trigger: 'blur', pattern:/^1[3456789]\d{9}$/, validator: function(rule, value, call){ {
required: false,
message: 'Please fill in the user name',
trigger: 'blur',
pattern: /^1[3456789]\d{9}$/,
validator: function (rule, value, call) {
console.log(rule, value) console.log(rule, value)
return call(new Error()) } } return call(new Error())
}
}
], ],
password: [ password: [
{ required: true, message: 'Please fill in the password.', trigger: 'blur' }, { required: true, message: 'Please fill in the password.', trigger: 'blur' },
...@@ -60,17 +67,17 @@ ...@@ -60,17 +67,17 @@
} }
} }
}, },
watch:{}, watch: {},
components: { components: {
editor editor
}, },
// manually control the data synchronization // manually control the data synchronization
// 如果需要手动控制数据同步,父组件需要显式地处理changed事件 // 如果需要手动控制数据同步,父组件需要显式地处理changed事件
methods: { methods: {
getInfo(value) { getInfo (value) {
console.log(value) console.log(value)
}, },
handleSubmit(name) { handleSubmit (name) {
// this.$refs[name].validate((valid) => { // this.$refs[name].validate((valid) => {
// if (valid) { // if (valid) {
// this.$Message.success('Success!'); // this.$Message.success('Success!');
...@@ -86,7 +93,7 @@ ...@@ -86,7 +93,7 @@
}, },
computed: { computed: {
}, },
mounted() { mounted () {
}
} }
</script> }
\ No newline at end of file </script>
...@@ -3,24 +3,23 @@ ...@@ -3,24 +3,23 @@
</template> </template>
<script> <script>
function GetQueryString(name) { function GetQueryString (name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i"); var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i')
var r = window.location.search.substr(1).match(reg); //获取url中"?"符后的字符串并正则匹配 var r = window.location.search.substr(1).match(reg) // 获取url中"?"符后的字符串并正则匹配
var context = ""; var context = ''
if (r != null) if (r != null) { context = r[2] }
context = r[2]; reg = null
reg = null; r = null
r = null; return context == null || context == '' || context == 'undefined' ? '' : decodeURIComponent(context)
return context == null || context == "" || context == "undefined" ? "" : decodeURIComponent(context); }
} export default {
export default{
data () { data () {
return {} return {}
}, },
mounted() { mounted () {
console.log(777) console.log(777)
window.parent.CKEDITOR.tools.callFunction(GetQueryString("CKEditorFuncNum"),GetQueryString("ImageUrl"),GetQueryString("Message")) window.parent.CKEDITOR.tools.callFunction(GetQueryString('CKEditorFuncNum'), GetQueryString('ImageUrl'), GetQueryString('Message'))
}
} }
}
</script> </script>
...@@ -38,30 +38,31 @@ ...@@ -38,30 +38,31 @@
</Row> </Row>
</template> </template>
<script> <script>
import {getpersonMassage,loginOUT,adoptOneSeeResumeList,getChannelMassage,judeAdmin} from '../api/home.server.js' import { getpersonMassage, loginOUT, adoptOneSeeResumeList, getChannelMassage, judeAdmin } from '../api/home.server.js'
import localstorage from '../service/localstorage.service.js' import localstorage from '../service/localstorage.service.js'
import loading from '../components/loading.vue' import loading from '../components/loading.vue'
import {mapState} from 'vuex' import { mapState } from 'vuex'
export default{ export default {
data() { data () {
return { return {
massage:'', massage: '',
isAdmin: false, isAdmin: false,
arr:[], arr: [],
biaoshi:'', biaoshi: '',
channelARR:[], channelARR: [],
isadmin:'', isadmin: '',
pageindex:0, pageindex: 0,
pageSize:10, pageSize: 10,
condition:'', condition: '',
xiabiao:'', xiabiao: '',
itemSelect:'', itemSelect: '',
type:'', type: '',
levelOneName: '1', levelOneName: '1',
levelTwoName: ['1-1', '2-1', '3-1', '4-1'], levelTwoName: ['1-1', '2-1', '3-1', '4-1'],
levelThreeName: '1-1-1', levelThreeName: '1-1-1',
menuList: [ menuList: [
{ name: '1', {
name: '1',
item: '简历管理', item: '简历管理',
loadMenu: true, loadMenu: true,
child: [ child: [
...@@ -72,44 +73,51 @@ import {mapState} from 'vuex' ...@@ -72,44 +73,51 @@ import {mapState} from 'vuex'
child: [ child: [
{ {
name: '1-1-1', name: '1-1-1',
item:'全部简历', item: '全部简历',
route: '/allResume' route: '/allResume'
} }
] ]
}, },
{ name: '1-2', {
name: '1-2',
item: '渠道简历', item: '渠道简历',
icon: 'ios-list', icon: 'ios-list',
child: [] child: []
}] }]
}, },
{ name: '2', {
name: '2',
item: '面试管理', item: '面试管理',
child: [ child: [
{ name: '2-1', {
name: '2-1',
item: '面试管理', item: '面试管理',
icon: 'ios-paper-outline', icon: 'ios-paper-outline',
child: [ child: [
{ name: '2-1-1', {
item:'全部简历', name: '2-1-1',
item: '全部简历',
route: '/interview' route: '/interview'
}] }]
}] }]
}, },
{ name: '3', {
name: '3',
item: '上传简历', item: '上传简历',
child: [{ child: [{
name: '3-1', name: '3-1',
item: '上传简历', item: '上传简历',
icon: 'ios-cloud-upload-outline', icon: 'ios-cloud-upload-outline',
child: [ child: [
{ name: '3-1-1', {
item:'上传简历', name: '3-1-1',
item: '上传简历',
route: '/upload' route: '/upload'
}] }]
}] }]
}, },
{ name: '4', {
name: '4',
item: '系统管理', item: '系统管理',
isAdmin: true, isAdmin: true,
child: [{ child: [{
...@@ -119,38 +127,43 @@ import {mapState} from 'vuex' ...@@ -119,38 +127,43 @@ import {mapState} from 'vuex'
show: true, show: true,
child: [{ child: [{
name: '4-1-1', name: '4-1-1',
item:'账户管理', item: '账户管理',
route: '/account' route: '/account'
}] }]
}, },
{ name: '4-2', {
name: '4-2',
item: '邮箱管理', item: '邮箱管理',
icon:'ios-mail-outline', icon: 'ios-mail-outline',
child: [{ child: [{
name: '4-2-1', name: '4-2-1',
item:'邮箱管理', item: '邮箱管理',
route: '/emailMange' route: '/emailMange'
}]}, }]
{ name: '4-3', },
{
name: '4-3',
item: '二维码管理', item: '二维码管理',
icon: 'ios-qr-scanner', icon: 'ios-qr-scanner',
child: [ child: [
{ name: '4-3-1', {
item:'二维码管理', name: '4-3-1',
item: '二维码管理',
route: '/QRcode' route: '/QRcode'
}]} }]
}
] }, ]
}
], ],
childMenu: [] childMenu: []
} }
}, },
watch:{ watch: {
$route(to,from){ $route (to, from) {
if (to.params.fromInterview){ if (to.params.fromInterview) {
this.getActiveName() this.getActiveName()
} }
} }
}, },
computed: { computed: {
...@@ -162,7 +175,7 @@ import {mapState} from 'vuex' ...@@ -162,7 +175,7 @@ import {mapState} from 'vuex'
loading loading
}, },
methods: { methods: {
go(name) { go (name) {
this.levelThreeName = name this.levelThreeName = name
this.childMenu.map(par => { this.childMenu.map(par => {
par.child.map(child => { par.child.map(child => {
...@@ -172,64 +185,64 @@ import {mapState} from 'vuex' ...@@ -172,64 +185,64 @@ import {mapState} from 'vuex'
}) })
}) })
}, },
async selectMenu(name, refesh) { async selectMenu (name, refesh) {
// // refesh是否为刷新页面 // // refesh是否为刷新页面
this.levelOneName = name this.levelOneName = name
const menus = this.menuList.filter(v => name === v.name) const menus = this.menuList.filter(v => name === v.name)
this.childMenu = menus.length >0? menus[0].child : this.menuList[0].child this.childMenu = menus.length > 0 ? menus[0].child : this.menuList[0].child
if (!refesh) { // 点击菜单默认展示第一个菜单 if (!refesh) { // 点击菜单默认展示第一个菜单
this.levelTwoName = [] this.levelTwoName = []
let initName = this.getInitName(name, menus[0]) const initName = this.getInitName(name, menus[0])
this.levelTwoName.push(initName.levelTwoName) this.levelTwoName.push(initName.levelTwoName)
this.levelThreeName = initName.levelThreeName this.levelThreeName = initName.levelThreeName
} }
if (menus[0].loadMenu) { // 简历管理模块需要加载渠道简历 if (menus[0].loadMenu) { // 简历管理模块需要加载渠道简历
await this.getChannelMenu() await this.getChannelMenu()
} }
if (refesh&&this.$route.path.indexOf('channel') > -1) { if (refesh && this.$route.path.indexOf('channel') > -1) {
this.levelThreeName = this.$route.path.split('/')[2] this.levelThreeName = this.$route.path.split('/')[2]
} }
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.subMenu.updateOpened(); this.$refs.subMenu.updateOpened()
this.$refs.subMenu.updateActiveName(); this.$refs.subMenu.updateActiveName()
}) })
this.go(this.levelThreeName) this.go(this.levelThreeName)
}, },
// 获取个人信息 // 获取个人信息
getmassage(){ getmassage () {
getpersonMassage().then(res=>{ getpersonMassage().then(res => {
this.massage=res.data.body&&res.data.body.userName || '' this.massage = res.data.body && res.data.body.userName || ''
}) })
}, },
// 用户退出 // 用户退出
loginOut(){ loginOut () {
loginOUT().then(res=>{ loginOUT().then(res => {
if(res.data.success==true){ if (res.data.success == true) {
localstorage.remove('token') localstorage.remove('token')
localstorage.remove('isADMIN') localstorage.remove('isADMIN')
this.$router.replace('/login') this.$router.replace('/login')
} }
}) })
}, },
getChannelMenu(){ getChannelMenu () {
this.menuList[0].child[1].child = [] this.menuList[0].child[1].child = []
return getChannelMassage().then(res=>{ return getChannelMassage().then(res => {
if (res.data.status == false || !res.data.success) { if (res.data.status == false || !res.data.success) {
return return
} }
this.channelARR=res.data.body || [] this.channelARR = res.data.body || []
this.channelARR.map((item,index) => { this.channelARR.map((item, index) => {
var obj = { var obj = {
name: `${item.sourceName}`, name: `${item.sourceName}`,
item: item.sourceName, item: item.sourceName,
route: `/channel/${item.sourceCode}?handUpload=${item.handUpload==null?'':item.handUpload}` route: `/channel/${item.sourceCode}?handUpload=${item.handUpload == null ? '' : item.handUpload}`
} }
this.menuList[0].child[1].child.push(obj) this.menuList[0].child[1].child.push(obj)
}) })
}) })
}, },
getActiveName (change) { getActiveName (change) {
let pathName = this.$route.path const pathName = this.$route.path
if (pathName.indexOf('channel') > -1) { if (pathName.indexOf('channel') > -1) {
this.levelOneName = '1' this.levelOneName = '1'
this.levelThreeName = pathName.split('/')[2] this.levelThreeName = pathName.split('/')[2]
...@@ -248,30 +261,29 @@ import {mapState} from 'vuex' ...@@ -248,30 +261,29 @@ import {mapState} from 'vuex'
this.levelTwoName.push(child.name) this.levelTwoName.push(child.name)
} }
}) })
}) })
}) })
this.selectMenu(this.levelOneName, 'refresh') this.selectMenu(this.levelOneName, 'refresh')
}, },
getInitName (name, menu, child) { getInitName (name, menu, child) {
// 超级管理员 // 超级管理员
let isAdmin = menu.isAdmin const isAdmin = menu.isAdmin
let hightMenu = { const hightMenu = {
levelTwoName: '', levelTwoName: '',
levelThreeName: '' levelThreeName: ''
} }
if (isAdmin || isAdmin == undefined) { // 默认展示一级菜单 if (isAdmin || isAdmin == undefined) { // 默认展示一级菜单
hightMenu.levelTwoName = menu.child[0].name hightMenu.levelTwoName = menu.child[0].name
hightMenu.levelThreeName = menu.child[0].child[0].name hightMenu.levelThreeName = menu.child[0].child[0].name
} else if(isAdmin == false){ //展示二级菜单 } else if (isAdmin == false) { // 展示二级菜单
hightMenu.levelTwoName = menu.child[1].name hightMenu.levelTwoName = menu.child[1].name
hightMenu.levelThreeName = menu.child[1].child[0].name hightMenu.levelThreeName = menu.child[1].child[0].name
} }
return hightMenu return hightMenu
}, },
// 判断是否为超级管理员 // 判断是否为超级管理员
judgeadmin(){ judgeadmin () {
judeAdmin().then(res=>{ judeAdmin().then(res => {
this.isAdmin = res.data.body this.isAdmin = res.data.body
this.menuList[3].isAdmin = this.isAdmin this.menuList[3].isAdmin = this.isAdmin
}) })
...@@ -280,19 +292,19 @@ import {mapState} from 'vuex' ...@@ -280,19 +292,19 @@ import {mapState} from 'vuex'
this.getActiveName() this.getActiveName()
} }
}, },
mounted() { mounted () {
this.getmassage() this.getmassage()
this.getActiveName() this.getActiveName()
this.judgeadmin() this.judgeadmin()
if (window.history && window.history.pushState) { if (window.history && window.history.pushState) {
history.pushState(null, null, document.URL); history.pushState(null, null, document.URL)
window.addEventListener('popstate', this.goBack, false); window.addEventListener('popstate', this.goBack, false)
} }
}, },
destroyed(){ destroyed () {
window.removeEventListener('popstate', this.goBack, false); window.removeEventListener('popstate', this.goBack, false)
}
} }
}
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
</div> </div>
</template> </template>
<script> <script>
export default{ export default {
name: 'loading', name: 'loading',
props: { props: {
width: { width: {
......
const sapi = "http://recruitapi-ai3.liangkebang.net" const sapi = 'http://recruitapi-ai3.liangkebang.net'
export { export {
sapi sapi
} }
// The Vue build version to load with the `import` command // The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias. // (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'; import Vue from 'vue'
import iView from 'iview'; import { Notice } from iView from 'iview'
import 'iview/dist/styles/iview.css'; import 'iview/dist/styles/iview.css'
import App from './App'; import App from './App'
import router from './router'; import router from './router'
import initRouter from './service/init.service.js' import initRouter from './service/init.service.js'
import 'vue-happy-scroll/docs/happy-scroll.css' import 'vue-happy-scroll/docs/happy-scroll.css'
import {Notice} from 'iview'
import store from '../src/store' import store from '../src/store'
Vue.use(iView); Vue.use(iView)
Vue.use(Notice) Vue.use(Notice)
Vue.config.productionTip = false; Vue.config.productionTip = false
initRouter.init(router) initRouter.init(router)
/* eslint-disable no-new */ /* eslint-disable no-new */
new Vue({ new Vue({
...@@ -19,5 +19,5 @@ new Vue({ ...@@ -19,5 +19,5 @@ new Vue({
router, router,
store, store,
components: { App }, components: { App },
template: '<App/>', template: '<App/>'
}); })
...@@ -232,12 +232,12 @@ ...@@ -232,12 +232,12 @@
</template> </template>
<script> <script>
import moment from 'moment' import moment from 'moment'
import {changeinterviewMassage,SerchList,Serchinterviewor,SerchInvitationOwer,NewAddInterview,SInterview,oppenInterview,recodeLIST,changestatus,seedetail,formstatus} from '../../api/interview.server.js' import { changeinterviewMassage, SerchList, Serchinterviewor, SerchInvitationOwer, NewAddInterview, SInterview, oppenInterview, recodeLIST, changestatus, seedetail, formstatus } from '../../api/interview.server.js'
import {findCompanyEmailByKey} from '../../api/resume.server.js' import { findCompanyEmailByKey } from '../../api/resume.server.js'
export default { export default {
data(){ data () {
return{ return {
pageT:'', pageT: '',
statusValue: '0', statusValue: '0',
ruleInline: { ruleInline: {
UpdateOWER: [ UpdateOWER: [
...@@ -247,506 +247,503 @@ export default { ...@@ -247,506 +247,503 @@ export default {
{ required: true, message: '面试时间不能为空', trigger: 'date' } { required: true, message: '面试时间不能为空', trigger: 'date' }
], ],
UpdateVIEW: [ UpdateVIEW: [
{ required: true,message: '面试官不能为空', trigger: 'blur' } { required: true, message: '面试官不能为空', trigger: 'blur' }
], ]
}, },
formInline:{ formInline: {
UpdateOWER:'', UpdateOWER: '',
UpdateTIME:'', UpdateTIME: '',
UpdateVIEW:'' UpdateVIEW: ''
}, },
recordModal:false, recordModal: false,
modal2:false, modal2: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
modal5:false, modal5: false,
interdeTailSta:"", interdeTailSta: '',
changestatuss:'', changestatuss: '',
spinShow:true, spinShow: true,
Ishow:[], Ishow: [],
aaaaa:'', aaaaa: '',
detailID:'', detailID: '',
nowstate:[{value:'已邀约',label:'已邀约'},{value:'邀约失败',label:'邀约失败'},{value:'面试淘汰',label:'面试淘汰'},{value:'待offer',label:'待offer'},{value:'已发offer',label:'已发offer'},{value:'待入职',label:'待入职'},{value:'未入职',label:'未入职'},{value:'已入职',label:'已入职'},], nowstate: [{ value: '已邀约', label: '已邀约' }, { value: '邀约失败', label: '邀约失败' }, { value: '面试淘汰', label: '面试淘汰' }, { value: '待offer', label: '待offer' }, { value: '已发offer', label: '已发offer' }, { value: '待入职', label: '待入职' }, { value: '未入职', label: '未入职' }, { value: '已入职', label: '已入职' }],
keywords:'', keywords: '',
recordList:[], recordList: [],
oppenInterviewStatus:'TO_DO', oppenInterviewStatus: 'TO_DO',
oppenInterviewID:'', oppenInterviewID: '',
OPPeninterviewSTA:'', OPPeninterviewSTA: '',
toseename:'', toseename: '',
clickIndex1: 0, clickIndex1: 0,
clickIndex2: 0, clickIndex2: 0,
clickIndex3: 0, clickIndex3: 0,
// UpdateOWER:'', // UpdateOWER:'',
// UpdateTIME:'', // UpdateTIME:'',
// UpdateVIEW:'', // UpdateVIEW:'',
UpdateID:'', UpdateID: '',
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() <Date.now()-3600*24*1000; return date && date.valueOf() < Date.now() - 3600 * 24 * 1000
} }
}, },
Interviewer:[], Interviewer: [],
Inviter:[], Inviter: [],
stopinterviewID:'', stopinterviewID: '',
Interviewoperation:0, Interviewoperation: 0,
UpdateOWERNEW:'', UpdateOWERNEW: '',
UpdateTIMENEW:'', UpdateTIMENEW: '',
UpdateVIEWNEW:'', UpdateVIEWNEW: '',
highestDegreeNum:'', highestDegreeNum: '',
emailName:'', emailName: '',
flowStatusList:[], flowStatusList: [],
inviterName:'',//邀约人 inviterName: '', // 邀约人
interviewerName:'',//面试官 interviewerName: '', // 面试官
changestatusSTATUS:'', changestatusSTATUS: '',
pageIndex:1, pageIndex: 1,
pageSize:30, pageSize: 30,
totalSize:null, totalSize: null,
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
STA:[], STA: []
}, },
Education2:[{Num2:'',status2:'不限'},{Num2:"0",status2:'专科以下'},{Num2:'1',status2:'专科及以上'},{Num2:'2',status2:'本科及以上'},{Num2:'3',status2:'硕士及以上'},{Num2:'4',status2:'博士及以上'},{Num2:'99',status2:'985/211'}], Education2: [{ Num2: '', status2: '不限' }, { Num2: '0', status2: '专科以下' }, { Num2: '1', status2: '专科及以上' }, { Num2: '2', status2: '本科及以上' }, { Num2: '3', status2: '硕士及以上' }, { Num2: '4', status2: '博士及以上' }, { Num2: '99', status2: '985/211' }],
state:[{Num3:[],status3:'不限',sta:true},{Num3:'HAS_SEE',status3:'已邀约',sta:false},{Num3:'SEE_FAIL',status3:'邀约失败',sta:false}, state: [{ Num3: [], status3: '不限', sta: true }, { Num3: 'HAS_SEE', status3: '已邀约', sta: false }, { Num3: 'SEE_FAIL', status3: '邀约失败', sta: false },
{Num3:'INTERVIEW_FAIL',status3:'面试淘汰',sta:false},{Num3:'TO_SENT_OFFER',status3:'待Offer',sta:false},{Num3:'HAS_SENT_OFFER',status3:'已发offer',sta:false},{Num3:'HAS_ENTRY',status3:'已入职',sta:false},{Num3:'NO_ENTRY',status3:'未入职',sta:false},{Num3:'END',status3:'终止面试',sta:false},], { Num3: 'INTERVIEW_FAIL', status3: '面试淘汰', sta: false }, { Num3: 'TO_SENT_OFFER', status3: '待Offer', sta: false }, { Num3: 'HAS_SENT_OFFER', status3: '已发offer', sta: false }, { Num3: 'HAS_ENTRY', status3: '已入职', sta: false }, { Num3: 'NO_ENTRY', status3: '未入职', sta: false }, { Num3: 'END', status3: '终止面试', sta: false }],
OPtionData:[{value:'0',label:'面试淘汰'}], OPtionData: [{ value: '0', label: '面试淘汰' }],
activeName:'', activeName: '',
Essentialinformation:[], Essentialinformation: [],
serchData:[], serchData: [],
serchData2:[], serchData2: [],
options: [], options: [],
loading1: false loading1: false
} }
}, },
methods: { methods: {
// 变更状态 // 变更状态
selectFn2(e) { selectFn2 (e) {
if(e.target.value==5){ if (e.target.value == 5) {
this.modal5=true this.modal5 = true
} }
}, },
// 操作记录查询 // 操作记录查询
RecordSEE(RID,sname){ RecordSEE (RID, sname) {
this.toseename=sname this.toseename = sname
this.recordModal=true this.recordModal = true
let parmars={ const parmars = {
resumeId:RID resumeId: RID
} }
recodeLIST(parmars).then(res=>{ recodeLIST(parmars).then(res => {
this.ownerName=res.data.body.ownerName this.ownerName = res.data.body.ownerName
this.recordList=res.data.body.map((item,index)=>{ this.recordList = res.data.body.map((item, index) => {
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.approveUserName=item.approveUserName item.approveUserName = item.approveUserName
item.dateTime=item.dateTime item.dateTime = item.dateTime
item.previousState=item.previousState item.previousState = item.previousState
item.afterState=item.afterState item.afterState = item.afterState
return item return item
}) })
}) })
}, },
//更改面试信息弹出框 // 更改面试信息弹出框
updateInterview(InterID,InterOWOR,InterTime,InterVIEW){ updateInterview (InterID, InterOWOR, InterTime, InterVIEW) {
this.formInline.UpdateOWER=InterVIEW, this.formInline.UpdateOWER = InterVIEW,
this.formInline.UpdateVIEW=InterOWOR, this.formInline.UpdateVIEW = InterOWOR,
this.formInline.UpdateTIME=InterTime, this.formInline.UpdateTIME = InterTime,
this.UpdateID=InterID this.UpdateID = InterID
this.modal2=true this.modal2 = true
}, },
selectTime(b){ selectTime (b) {
this.UpdateTIME=b this.UpdateTIME = b
}, },
//准备约面取消 // 准备约面取消
StopInterview(){ StopInterview () {
this.status=status this.status = status
this.modal2=false this.modal2 = false
}, },
//终止面试弹出框 // 终止面试弹出框
Stopinterview(sid){ Stopinterview (sid) {
this.stopinterviewID=sid this.stopinterviewID = sid
this.modal3=true this.modal3 = true
}, },
//重启面试 // 重启面试
OPPeninterview(tid,sta4){ OPPeninterview (tid, sta4) {
this.oppenInterviewID=tid this.oppenInterviewID = tid
let parmars={ const parmars = {
resumeId:tid resumeId: tid
} }
formstatus(parmars).then(res=>{ formstatus(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.OPPeninterviewSTA=res.data.body.workFlow this.OPPeninterviewSTA = res.data.body.workFlow
} }
}) })
this.modal4=true this.modal4 = true
}, },
//操作状态 // 操作状态
UpdateStatus(LLL){ UpdateStatus (LLL) {
let STATUS=LLL; const STATUS = LLL
if(this.STATUS=='终止面试'){ if (this.STATUS == '终止面试') {
this.modal3=true this.modal3 = true
} }
if(this.STATUS=='重启面试'){ if (this.STATUS == '重启面试') {
this.modal4=true this.modal4 = true
} }
}, },
// 更改约面信息 // 更改约面信息
changeUpdate(){ changeUpdate () {
let parmars={ const parmars = {
resumeId:this.UpdateID, resumeId: this.UpdateID,
inviterName:this.formInline.UpdateOWER, inviterName: this.formInline.UpdateOWER,
seeTime:moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm'), seeTime: moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm'),
interviewerName:this.formInline.UpdateVIEW, interviewerName: this.formInline.UpdateVIEW,
email:this.emailName email: this.emailName
} }
if(this.formInline.UpdateOWER==''||this.formInline.UpdateTIME==""||this.formInline.UpdateVIEW==''){ if (this.formInline.UpdateOWER == '' || this.formInline.UpdateTIME == '' || this.formInline.UpdateVIEW == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写完整的约面信息' desc: '请您填写完整的约面信息'
}); })
return return
} }
changeinterviewMassage(parmars).then(res=>{ changeinterviewMassage(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.formInline.UpdateTIME=="" this.formInline.UpdateTIME == ''
this.formInline.UpdateVIEW=='' this.formInline.UpdateVIEW == ''
this.formInline.UpdateOWER=='' this.formInline.UpdateOWER == ''
this.modal2=false; this.modal2 = false
this.Sousuo( this.pageT) this.Sousuo(this.pageT)
} }
}) })
}, },
// 查询面试信息 // 查询面试信息
serchListInterview(page,status) { serchListInterview (page, status) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter:{ parameter: {
keywordString:'', keywordString: '',
highestDegreeNum:'', highestDegreeNum: '',
flowStatusList:[], flowStatusList: [],
interviewerName:'', interviewerName: '',
inviterName:'', inviterName: ''
} }
} }
SerchList(parmars,status).then(res=>{ SerchList(parmars, status).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.spinShow=false this.spinShow = false
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.Essentialinformation=res.data.body.items.map((item,index)=>{ this.Essentialinformation = res.data.body.items.map((item, index) => {
item.id=item.id item.id = item.id
item.flowStatus=item.flowStatus item.flowStatus = item.flowStatus
item.interviewerName= item.interviewerName item.interviewerName = item.interviewerName
item.inviterName=item.inviterName item.inviterName = item.inviterName
item.modifier=item.modifier item.modifier = item.modifier
item.c=item.modifier==''?item.modifier:item.modifier.split('_') item.c = item.modifier == '' ? item.modifier : item.modifier.split('_')
item.d=item.c[0] item.d = item.c[0]
item.modifyTime=item.modifyTime item.modifyTime = item.modifyTime
item.ownerExpectTitles=item.ownerExpectTitles item.ownerExpectTitles = item.ownerExpectTitles
item.ownerMobile=item.ownerMobile item.ownerMobile = item.ownerMobile
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.seeTime=item.seeTime item.seeTime = item.seeTime
item.uid=item.uid item.uid = item.uid
return item return item
}) })
} }
}) })
}, },
// 面试官查询 // 面试官查询
SerchlistinterviewList(){ SerchlistinterviewList () {
Serchinterviewor().then(res=>{ Serchinterviewor().then(res => {
this.Interviewer=res.data.body this.Interviewer = res.data.body
this.Interviewer.unshift('不限') this.Interviewer.unshift('不限')
}) })
}, },
// 邀约人查询 // 邀约人查询
SerchInvitation(){ SerchInvitation () {
SerchInvitationOwer().then(res=>{ SerchInvitationOwer().then(res => {
if (!res.data.success) { if (!res.data.success) {
return return
} }
this.Inviter= res.data.body this.Inviter = res.data.body
this.Inviter.unshift('不限') this.Inviter.unshift('不限')
}) })
}, },
//新增约面信息 // 新增约面信息
newaddInterview(){ newaddInterview () {
let parmars={ const parmars = {
resumeId:this.UpdateOWERNEW, resumeId: this.UpdateOWERNEW,
inviterName:this.UpdateTIMENEW, inviterName: this.UpdateTIMENEW,
interviewerName:this.UpdateVIEWNEW, interviewerName: this.UpdateVIEWNEW,
seeTime:this.UpdateTIMENEW seeTime: this.UpdateTIMENEW
} }
NewAddInterview(parmars).then(res=>{ NewAddInterview(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Message.success('新增约面信息成功') this.$Message.success('新增约面信息成功')
} }
}) })
}, },
// 终止面试 // 终止面试
STOPinterview(){ STOPinterview () {
SInterview(this.stopinterviewID).then(res=>{ SInterview(this.stopinterviewID).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal3=false this.modal3 = false
this.Sousuo(this.pageT) this.Sousuo(this.pageT)
} }
}) })
}, },
// 操作重启时选择的状态 // 操作重启时选择的状态
selectFnelement(e){ selectFnelement (e) {
if(e.target.value==1){ if (e.target.value == 1) {
this.oppenInterviewStatus='TO_DO' this.oppenInterviewStatus = 'TO_DO'
} }
if(e.target.value==2){ if (e.target.value == 2) {
this.oppenInterviewStatus='PASS' this.oppenInterviewStatus = 'PASS'
} }
if(e.target.value==3){ if (e.target.value == 3) {
this.oppenInterviewStatus='OPTION' this.oppenInterviewStatus = 'OPTION'
} }
if(e.target.value==4){ if (e.target.value == 4) {
this.oppenInterviewStatus='OPTION' this.oppenInterviewStatus = 'OPTION'
} }
if(e.target.value==5){ if (e.target.value == 5) {
this.oppenInterviewStatus='HAS_SEE' this.oppenInterviewStatus = 'HAS_SEE'
} }
if(e.target.value==6){ if (e.target.value == 6) {
this.oppenInterviewStatus='SEE_FAIL' this.oppenInterviewStatus = 'SEE_FAIL'
} }
if(e.target.value==10){ if (e.target.value == 10) {
this.oppenInterviewStatus='INTERVIEW_FAIL' this.oppenInterviewStatus = 'INTERVIEW_FAIL'
} }
if(e.target.value==11){ if (e.target.value == 11) {
this.oppenInterviewStatus='TO_SENT_OFFER' this.oppenInterviewStatus = 'TO_SENT_OFFER'
} }
if(e.target.value==12){ if (e.target.value == 12) {
this.oppenInterviewStatus='HAS_SENT_OFFER' this.oppenInterviewStatus = 'HAS_SENT_OFFER'
} }
if(e.target.value==13){ if (e.target.value == 13) {
this.oppenInterviewStatus='TO_ENTRY' this.oppenInterviewStatus = 'TO_ENTRY'
} }
}, },
//重启面试 // 重启面试
OPPinterview(){ OPPinterview () {
oppenInterview(this.oppenInterviewID,this.oppenInterviewStatus).then(res=>{ oppenInterview(this.oppenInterviewID, this.oppenInterviewStatus).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '已成功重启流程' desc: '已成功重启流程'
}); })
this.serchListInterview() this.serchListInterview()
} }
}) })
this.modal4=false this.modal4 = false
}, },
// 选择变更状态时的元素 // 选择变更状态时的元素
selectchangeElement(e,SID){ selectchangeElement (e, SID) {
if(e.target.value==1){ if (e.target.value == 1) {
this.changestatusSTATUS='HAS_SEE' this.changestatusSTATUS = 'HAS_SEE'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==2){ if (e.target.value == 2) {
this.changestatusSTATUS='HAS_SEE' this.changestatusSTATUS = 'HAS_SEE'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==3){ if (e.target.value == 3) {
this.changestatusSTATUS='SEE_FAIL' this.changestatusSTATUS = 'SEE_FAIL'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==4){ if (e.target.value == 4) {
this.changestatusSTATUS='INTERVIEW_FAIL' this.changestatusSTATUS = 'INTERVIEW_FAIL'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==5){ if (e.target.value == 5) {
this.changestatusSTATUS='TO_SENT_OFFER' this.changestatusSTATUS = 'TO_SENT_OFFER'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==6){ if (e.target.value == 6) {
this.changestatusSTATUS='HAS_SENT_OFFER' this.changestatusSTATUS = 'HAS_SENT_OFFER'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==7){ if (e.target.value == 7) {
this.changestatusSTATUS='TO_ENTRY' this.changestatusSTATUS = 'TO_ENTRY'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==8){ if (e.target.value == 8) {
this.changestatusSTATUS='NO_ENTRY' this.changestatusSTATUS = 'NO_ENTRY'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
if(e.target.value==9){ if (e.target.value == 9) {
this.changestatusSTATUS='HAS_ENTRY' this.changestatusSTATUS = 'HAS_ENTRY'
changestatus(SID, this.changestatusSTATUS).then(res=>{ changestatus(SID, this.changestatusSTATUS).then(res => {
this.serchListInterview(this.pageT,'init') this.serchListInterview(this.pageT, 'init')
}) })
} }
this.statusValue = '0' this.statusValue = '0'
}, },
selectElement3(tItem,Tindex,status3,sta3){ selectElement3 (tItem, Tindex, status3, sta3) {
sta3=!sta3 sta3 = !sta3
this.state[Tindex].sta=sta3 this.state[Tindex].sta = sta3
if(Tindex==0){ if (Tindex == 0) {
this.searchInfo.STA=[] this.searchInfo.STA = []
this.state.map((item,index)=>{ this.state.map((item, index) => {
if(index!==0){ if (index !== 0) {
item.sta=false item.sta = false
} }
if(index==0){ if (index == 0) {
item.sta=true item.sta = true
} }
return item return item
}) })
return return
} }
if(Tindex!==0){ if (Tindex !== 0) {
this.state[0].sta=false this.state[0].sta = false
} }
if(sta3==true){ if (sta3 == true) {
this.searchInfo.STA.push(tItem) this.searchInfo.STA.push(tItem)
} }
if(sta3==false){ if (sta3 == false) {
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
this.searchInfo.STA.remove(tItem) this.searchInfo.STA.remove(tItem)
} }
}, },
Seedetail(Tid,Uid,sta){ Seedetail (Tid, Uid, sta) {
this.DOWNID=Uid this.DOWNID = Uid
this.detailID=Tid this.detailID = Tid
this.interdeTailSta=sta this.interdeTailSta = sta
let newpage = this.$router.resolve({ const newpage = this.$router.resolve({
name: 'resumeDetail', name: 'resumeDetail',
params:{}, params: {},
query:{id:this.DOWNID,noShowBtn:'',ID:this.detailID,status:this.interdeTailSta} query: { id: this.DOWNID, noShowBtn: '', ID: this.detailID, status: this.interdeTailSta }
}) })
window.open(newpage.href, '_blank'); window.open(newpage.href, '_blank')
}, },
//搜索 // 搜索
Sousuo(page){ Sousuo (page) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter:{ parameter: {
keywordString:this.keywords, keywordString: this.keywords,
highestDegreeNum:this.highestDegreeNum, highestDegreeNum: this.highestDegreeNum,
flowStatusList:this.searchInfo.STA, flowStatusList: this.searchInfo.STA,
interviewerName:this.interviewerName, interviewerName: this.interviewerName,
inviterName:this.inviterName, inviterName: this.inviterName,
handUpload:'' handUpload: ''
} }
} }
SerchList(parmars).then(res=>{ SerchList(parmars).then(res => {
let Ishow=res.data.items const Ishow = res.data.items
if(res.data.success==true){ if (res.data.success == true) {
this.spinShow=false this.spinShow = false
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.Essentialinformation=res.data.body.items.map((item,index)=>{ this.Essentialinformation = res.data.body.items.map((item, index) => {
item.id=item.id item.id = item.id
item.flowStatus=item.flowStatus item.flowStatus = item.flowStatus
item.interviewerName= item.interviewerName item.interviewerName = item.interviewerName
item.inviterName=item.inviterName item.inviterName = item.inviterName
item.modifier=item.modifier item.modifier = item.modifier
item.c=item.modifier==''?item.modifier:item.modifier.split('_') item.c = item.modifier == '' ? item.modifier : item.modifier.split('_')
item.d=item.c[0] item.d = item.c[0]
item.modifyTime=item.modifyTime item.modifyTime = item.modifyTime
item.ownerExpectTitles=item.ownerExpectTitles item.ownerExpectTitles = item.ownerExpectTitles
item.ownerMobile=item.ownerMobile item.ownerMobile = item.ownerMobile
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.seeTime=item.seeTime item.seeTime = item.seeTime
item.uid=item.uid item.uid = item.uid
return item return item
}) })
} }
}) })
}, },
// 选择要搜索的元素 // 选择要搜索的元素
selectSeeElement(Titem,Tindex){ selectSeeElement (Titem, Tindex) {
this.highestDegreeNum=Titem this.highestDegreeNum = Titem
this.clickIndex1=Tindex this.clickIndex1 = Tindex
}, },
selectinterviewElement(e){ selectinterviewElement (e) {
if(e.value=='不限'){ if (e.value == '不限') {
this.interviewerName='' this.interviewerName = ''
}else{ } else {
this.interviewerName=e.value this.interviewerName = e.value
} }
}, },
selectinterviewElement2(e){ selectinterviewElement2 (e) {
if(e.label=='不限'){ if (e.label == '不限') {
this.inviterName='' this.inviterName = ''
}else{ } else {
this.inviterName=e.label this.inviterName = e.label
} }
}, },
//改变页码 // 改变页码
pageChange(page){ pageChange (page) {
this.pageT=page this.pageT = page
this.Sousuo(this.pageT) this.Sousuo(this.pageT)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.Sousuo() this.Sousuo()
}, },
remoteMethod: function(query){ remoteMethod: function (query) {
if (query !== '') { if (query !== '') {
this.loading1 = true; this.loading1 = true
setTimeout(() => { setTimeout(() => {
this.loading1 = false; this.loading1 = false
let list = [] let list = []
query = query.split('(')[0] query = query.split('(')[0]
findCompanyEmailByKey(query).then(res => { findCompanyEmailByKey(query).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
list = res list = res
this.options = list.data.body || [] this.options = list.data.body || []
this.options.map(item=>{ this.options.map(item => {
this.emailName=item.email this.emailName = item.email
}) })
} else{ } else {
this.options=[] this.options = []
} }
// this.options.push({name: '不限', email: ''}) // this.options.push({name: '不限', email: ''})
}) })
}, 200); }, 200)
} else { } else {
this.options = []; this.options = []
}
} }
},
}, },
mounted(){ mounted () {
this.serchListInterview(null, 'init') this.serchListInterview(null, 'init')
// this.Serchlistinterview() // this.Serchlistinterview()
this.SerchInvitation() this.SerchInvitation()
......
...@@ -38,72 +38,71 @@ ...@@ -38,72 +38,71 @@
</template> </template>
<script> <script>
import { login} from '../../api/login.server.js' import { login } from '../../api/login.server.js'
import localstorage from '../../service/localstorage.service.js' import localstorage from '../../service/localstorage.service.js'
export default { export default {
data () { data () {
return { return {
channelarr:[], channelarr: [],
notecontent:'', notecontent: '',
noteconTime:false, noteconTime: false,
ISIDMIN:'', ISIDMIN: '',
formInline: { formInline: {
user: '', user: '',
password: '' password: ''
}, },
ruleInline: { ruleInline: {
user: [ user: [
{ required: true, pattern:/\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' } { required: true, pattern: /\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' }
], ],
password: [ password: [
{ required: true, message: '请输入正确的密码', trigger: 'blur' }, { required: true, message: '请输入正确的密码', trigger: 'blur' }
// { type: 'string', min: 4, message: '请输入正确的密码', trigger: 'blur' } // { type: 'string', min: 4, message: '请输入正确的密码', trigger: 'blur' }
] ]
} }
} }
}, },
methods: { methods: {
handleSubmit(name) { handleSubmit (name) {
this.$refs[name].validate((valid) => { this.$refs[name].validate((valid) => {
if (valid) { if (valid) {
this.$Message.success('Success!'); this.$Message.success('Success!')
} else { } else {
this.$Message.error('Fail!'); this.$Message.error('Fail!')
} }
}) })
}, },
login(){ login () {
let params={ const params = {
userCode:this.formInline.user, userCode: this.formInline.user,
password:this.formInline.password password: this.formInline.password
} }
if(this.formInline.user==''||this.formInline.password==''){ if (this.formInline.user == '' || this.formInline.password == '') {
return return
} }
login(params).then(res=>{ login(params).then(res => {
if(res.data.body.code=='100'){ if (res.data.body.code == '100') {
this.$router.push({name:'update',params:{userCode:this.formInline.user}}) this.$router.push({ name: 'update', params: { userCode: this.formInline.user } })
return return
} }
if(res.data.success==true){ if (res.data.success == true) {
this.ISIDMIN=res.data.body this.ISIDMIN = res.data.body
localstorage.set('token', res.data.body.token) localstorage.set('token', res.data.body.token)
this.$router.push({name:"allResume"}) this.$router.push({ name: 'allResume' })
localstorage.set('isADMIN',JSON.stringify(this.ISIDMIN)) localstorage.set('isADMIN', JSON.stringify(this.ISIDMIN))
return return
} }
if(res.data.success==false){ if (res.data.success == false) {
this.noteconTime=true this.noteconTime = true
this.notecontent=res.data.body.message this.notecontent = res.data.body.message
setTimeout(() => { setTimeout(() => {
this.noteconTime=false this.noteconTime = false
}, 3000) }, 3000)
return
} }
}) })
} }
} }
} }
</script> </script>
<style scoped> <style scoped>
.login{ .login{
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
</template> </template>
<script> <script>
import { updatePsd} from '../../api/login.server.js' import { updatePsd } from '../../api/login.server.js'
export default { export default {
data () { data () {
return { return {
...@@ -46,122 +46,116 @@ export default { ...@@ -46,122 +46,116 @@ export default {
passwordTwo: '', passwordTwo: '',
password: '' password: ''
}, },
fistcontent:true, fistcontent: true,
twocontent:false, twocontent: false,
twocontentmessage:'', twocontentmessage: '',
channelarr:[], channelarr: [],
Massage:'', Massage: '',
ISIDMIN:'', ISIDMIN: ''
} }
}, },
methods: { methods: {
handleSubmit(name) { handleSubmit (name) {
this.$refs[name].validate((valid) => { this.$refs[name].validate((valid) => {
if (valid) { if (valid) {
this.$Message.success('Success!'); this.$Message.success('Success!')
} else { } else {
this.$Message.error('Fail!'); this.$Message.error('Fail!')
} }
}) })
}, },
loginT(){ loginT () {
let params={ const params = {
userCode:this.$route.params.userCode, userCode: this.$route.params.userCode,
password:this.formInline.password, password: this.formInline.password,
confirmPassWord:this.formInline.passwordTwo confirmPassWord: this.formInline.passwordTwo
} }
if(this.formInline.passwordTwo!==this.formInline.password){ if (this.formInline.passwordTwo !== this.formInline.password) {
this.twocontentmessage='输入密码不一致,请重新输入' this.twocontentmessage = '输入密码不一致,请重新输入'
this.twocontent=true this.twocontent = true
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
if(this.formInline.passwordTwo.length<4||this.formInline.password.length<4){ if (this.formInline.passwordTwo.length < 4 || this.formInline.password.length < 4) {
this.twocontentmessage='请输入4-20位密码' this.twocontentmessage = '请输入4-20位密码'
this.twocontent=true this.twocontent = true
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
if(this.formInline.password.length>20){ if (this.formInline.password.length > 20) {
this.twocontentmessage='请输入4-20位密码' this.twocontentmessage = '请输入4-20位密码'
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
if(this.formInline.password.length<4){ if (this.formInline.password.length < 4) {
this.twocontentmessage='请输入4-20位密码' this.twocontentmessage = '请输入4-20位密码'
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
if(this.formInline.password.length==0){ if (this.formInline.password.length == 0) {
this.twocontentmessage='密码不能为空' this.twocontentmessage = '密码不能为空'
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
if(this.formInline.passwordTwo.length==0){ if (this.formInline.passwordTwo.length == 0) {
this.twocontentmessage='请输入相同的确认密码' this.twocontentmessage = '请输入相同的确认密码'
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
return return
} }
updatePsd(params).then(res=>{ updatePsd(params).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.ISIDMIN=res.data.body this.ISIDMIN = res.data.body
localStorage.setItem('isADMIN',JSON.stringify(this.ISIDMIN)) localStorage.setItem('isADMIN', JSON.stringify(this.ISIDMIN))
localStorage.setItem('token',res.data.body.token) localStorage.setItem('token', res.data.body.token)
this.$router.replace({name:'allResume'}) this.$router.replace({ name: 'allResume' })
} }
if(res.data.success==false){ if (res.data.success == false) {
this.Massage=res.data.body.message this.Massage = res.data.body.message
this.twocontent=true this.twocontent = true
this.twocontentmessage=this.Massage this.twocontentmessage = this.Massage
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
} }
}) })
}, },
verification(){ verification () {
if(this.formInline.password==123456){ if (this.formInline.password == 123456) {
this.twocontentmessage='输入密码与初始密码相同,请重新输入' this.twocontentmessage = '输入密码与初始密码相同,请重新输入'
setTimeout(() => { setTimeout(() => {
this.twocontent=false this.twocontent = false
}, 3000) }, 3000)
} }
if(this.formInline.password.length==0){ if (this.formInline.password.length == 0) {
this.fistcontent=true this.fistcontent = true
} }
if(this.formInline.password==''){ if (this.formInline.password == '') {
this.fistcontent=true this.fistcontent = true
} }
if(this.formInline.password.length<4){ if (this.formInline.password.length < 4) {
this.fistcontent=true this.fistcontent = true
} }
if(this.formInline.password.length>4){ if (this.formInline.password.length > 4) {
this.fistcontent=false this.fistcontent = false
} }
if(this.formInline.password.length>20){ if (this.formInline.password.length > 20) {
this.fistcontent=true this.fistcontent = true
} }
},
} }
} }
}
</script> </script>
<style scoped> <style scoped>
.updatePsd{ .updatePsd{
......
...@@ -406,203 +406,203 @@ ...@@ -406,203 +406,203 @@
</template> </template>
<script> <script>
import moment from 'moment' import moment from 'moment'
import { serchList,downloadone,sousuoList,seedetail,PASS,OPTION,deleteREsume,downloadOne,exportLIST,recodeLIST,addinterview,updatastatus,getlist,TODORes,sendEmail,getEmailMoo,getEmailContent,uploadimage, findCompanyEmailByKey,forwardResume} from '../../api/resume.server' import { serchList, downloadone, sousuoList, seedetail, PASS, OPTION, deleteREsume, downloadOne, exportLIST, recodeLIST, addinterview, updatastatus, getlist, TODORes, sendEmail, getEmailMoo, getEmailContent, uploadimage, findCompanyEmailByKey, forwardResume } from '../../api/resume.server'
import {Serchinterviewor} from '../../api/interview.server.js' import { Serchinterviewor } from '../../api/interview.server.js'
import qs from 'qs' import qs from 'qs'
import { import {
sapi sapi
} from '../../config' } from '../../config'
import{_debounce,_throttle,emailValidata, emailRule, vidte, validator} from '../../service/util.js' import { _debounce, _throttle, emailValidata, emailRule, vidte, validator } from '../../service/util.js'
import localStorage from '../../service/localstorage.service' import localStorage from '../../service/localstorage.service'
import Router from 'vue-router'; import Router from 'vue-router'
import ckeditor from '../../components/ckeditor' import ckeditor from '../../components/ckeditor'
import {mapState} from 'vuex' import { mapState } from 'vuex'
export default { export default {
data () { data () {
return { return {
modal11: false, modal11: false,
errorInfo: '', errorInfo: '',
interviewee: [], interviewee: [],
interviewerNameList: [], interviewerNameList: [],
position:[], position: [],
handUploadCode:'', handUploadCode: '',
positionArr:[ positionArr: [
], ],
tip: false, tip: false,
tipInfo: '输入多个邮箱地址以英文”;“分隔', tipInfo: '输入多个邮箱地址以英文”;“分隔',
sad:'', sad: '',
loading1: false, loading1: false,
selectElementValue:'', selectElementValue: '',
options: [], options: [],
editorObject: {type: '', value: ''}, editorObject: { type: '', value: '' },
ruleInline: { ruleInline: {
UpdateOWER: [ UpdateOWER: [
{ required: true, message: '邀约人不能为空', trigger: 'blur',validator: emailValidata.bind(this)} { required: true, message: '邀约人不能为空', trigger: 'blur', validator: emailValidata.bind(this) }
], ],
UpdateTIME: [ UpdateTIME: [
{ required: true, message: '面试时间不能为空', trigger: 'change', type:'date', validator: emailValidata.bind(this)} { required: true, message: '面试时间不能为空', trigger: 'change', type: 'date', validator: emailValidata.bind(this) }
], ],
UpdateVIEW: [ UpdateVIEW: [
{ required: true,message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this), type: String} { required: true, message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this), type: String }
] ]
}, },
emailruleInline: { emailruleInline: {
receiveEmail: [{required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this)}], receiveEmail: [{ required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this) }],
theme: [{required: true, trigger: 'blur',message: '主题不能为空', validator: emailValidata.bind(this)}], theme: [{ required: true, trigger: 'blur', message: '主题不能为空', validator: emailValidata.bind(this) }],
copyname: [{required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true}] copyname: [{ required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true }]
}, },
formInline:{ formInline: {
UpdateOWER:'', UpdateOWER: '',
UpdateTIME:'', UpdateTIME: '',
UpdateVIEW:'', UpdateVIEW: '',
sendWeixin: true sendWeixin: true
}, },
resumeDetailSta:'', resumeDetailSta: '',
emailInline:{ emailInline: {
moo:'', moo: '',
modalArr:[], modalArr: [],
copyname:'', copyname: '',
receiveEmail:'',//收件人 receiveEmail: '', // 收件人
theme:'',//主题 theme: '', // 主题
Enclosure:[],//附件 Enclosure: [], // 附件
templateContent:'',//模板内容 templateContent: ''// 模板内容
}, },
// selectFn1Element:'1', // selectFn1Element:'1',
// selectFn2Element:'1', // selectFn2Element:'1',
// selectFn3Element:'1', // selectFn3Element:'1',
// selectFn4Element:'1', // selectFn4Element:'1',
selectFn1STA:'', selectFn1STA: '',
selectFn2STA:'', selectFn2STA: '',
selectFn3STA:'', selectFn3STA: '',
selectFn4STA:'', selectFn4STA: '',
limentName:0, limentName: 0,
errorMassage:'', errorMassage: '',
errorCode:'', errorCode: '',
isShowRep:false, isShowRep: false,
emailMassage:false, emailMassage: false,
allEmailVilitor:false, allEmailVilitor: false,
emailContent:'', emailContent: '',
emailFlowStatus:'', emailFlowStatus: '',
fileList:[], fileList: [],
UpdateTIMETwo:'', UpdateTIMETwo: '',
uploadFileList:[], uploadFileList: [],
temp:'', temp: '',
uploadurl:`${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`, uploadurl: `${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`,
isShowAll:false, isShowAll: false,
isShowTwo:false, isShowTwo: false,
isLimitSize:false, isLimitSize: false,
isDisable:true, isDisable: true,
disabledSingle:true, disabledSingle: true,
emailId:'', emailId: '',
RescopyArr:[], RescopyArr: [],
interelement:'1', interelement: '1',
emailIdArr:[], emailIdArr: [],
attachFileList:[], attachFileList: [],
flowStatusTT:'', flowStatusTT: '',
emailCode:'', emailCode: '',
resumePushId:'', resumePushId: '',
modal1:false, modal1: false,
modal2:false, modal2: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
modal5:false, modal5: false,
modal6:false, modal6: false,
modal7:false, modal7: false,
modal8: false, modal8: false,
modal12:false, modal12: false,
modal13:false, modal13: false,
modal14:false, modal14: false,
modal15:false, modal15: false,
modal17:false, modal17: false,
modal16:false, modal16: false,
errorNotice:'', errorNotice: '',
transpondFrom: { transpondFrom: {
interviewerName: '' interviewerName: ''
}, },
transpondRule: { transpondRule: {
interviewerName: [{required: true, trigger: 'blur', validator: validator.bind(this)}] interviewerName: [{ required: true, trigger: 'blur', validator: validator.bind(this) }]
}, },
interviewerList: [{name: 'test', value: '1'}], interviewerList: [{ name: 'test', value: '1' }],
modal10:false, modal10: false,
title:'', title: '',
emailMOdal:false, emailMOdal: false,
DOSTA:'', DOSTA: '',
DOWNLOAD:'', DOWNLOAD: '',
detailID:'', detailID: '',
spinShow: true, spinShow: true,
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() <Date.now()-3600*24*1000; return date && date.valueOf() < Date.now() - 3600 * 24 * 1000
} }
}, },
checkboxList:[], checkboxList: [],
Black:false, Black: false,
ownerName:'', ownerName: '',
midStr:'', midStr: '',
toseename:'', toseename: '',
// UpdateOWER:'', // UpdateOWER:'',
// UpdateTIME:'', // UpdateTIME:'',
// UpdateVIEW:'', // UpdateVIEW:'',
DOWNID:'', DOWNID: '',
resume:[],//简历基本详情 resume: [], // 简历基本详情
riList:[],//实习经历列表 riList: [], // 实习经历列表
roList:[],//工作经历列表 roList: [], // 工作经历列表
rpList:[],//项目经历列表 rpList: [], // 项目经历列表
reList:[],//教育经历列表 reList: [], // 教育经历列表
a:[], a: [],
interviewIsShow:false, interviewIsShow: false,
beforeBtu:false, beforeBtu: false,
checked: false, checked: false,
activeClass: 0, activeClass: 0,
clickIndex1: 0, clickIndex1: 0,
clickIndex2: 0, clickIndex2: 0,
clickIndex3:0, clickIndex3: 0,
keywords:'', keywords: '',
recordList:[], recordList: [],
all:'all', all: 'all',
lrgs:'', lrgs: '',
a:'', a: '',
ITEMSTA:'', ITEMSTA: '',
pageT:'', pageT: '',
toseeid:'', toseeid: '',
item:[], item: [],
STATE:'', STATE: '',
delateARRALL:[], delateARRALL: [],
delateARRALL2:[], delateARRALL2: [],
delateARRALL3:[], delateARRALL3: [],
flowStatusarr:[], flowStatusarr: [],
flowStatusarr2:[], flowStatusarr2: [],
reResumeName:'', reResumeName: '',
DELATEARR:[], DELATEARR: [],
quanxuan:[], quanxuan: [],
orignarr:['TO_SEE','HAS_SEE','SEE_FAIL','INTERVIEW_FAIL','TO_SENT_OFFER','TO_ENTRY','HAS_ENTRY','NO_ENTRY','END','ARRIVED'], orignarr: ['TO_SEE', 'HAS_SEE', 'SEE_FAIL', 'INTERVIEW_FAIL', 'TO_SENT_OFFER', 'TO_ENTRY', 'HAS_ENTRY', 'NO_ENTRY', 'END', 'ARRIVED'],
totalSize:null, totalSize: null,
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
id:'', id: '',
SEX:'', SEX: '',
Edu:'', Edu: '',
ccc:'', ccc: '',
STA:[], STA: [],
status:"", status: '',
ownerWorkYears1:'', ownerWorkYears1: '',
ownerWorkYears2:'', ownerWorkYears2: ''
}, },
arr:[], arr: [],
bg:'', bg: '',
sexs:[{Num1:'',status1:'不限'},{Num1:'0',status1:""},{Num1:'0',status1:''}], sexs: [{ Num1: '', status1: '不限' }, { Num1: '0', status1: '' }, { Num1: '0', status1: '' }],
Education:[{Num2:'',status2:'不限'},{Num2:"0",status2:'专科以下'},{Num2:'1',status2:'专科及以上'},{Num2:'2',status2:'本科及以上'},{Num2:'3',status2:'硕士及以上'},{Num2:'4',status2:'博士及以上'},{Num2:'99',status2:'985/211'}], Education: [{ Num2: '', status2: '不限' }, { Num2: '0', status2: '专科以下' }, { Num2: '1', status2: '专科及以上' }, { Num2: '2', status2: '本科及以上' }, { Num2: '3', status2: '硕士及以上' }, { Num2: '4', status2: '博士及以上' }, { Num2: '99', status2: '985/211' }],
state:[{Num3:[],status3:'不限',sta:true},{Num3:'TO_DO',status3:'待处理',sta:false},{Num3:'OPTION',status3:'备选',sta:false},{Num3:'PASS',status3:'Pass',sta:false},{Num3:'HAS_SEE',status3:'已邀约',sta:false},{Num3:'SEE_FAIL',status3:'邀约失败',sta:false}, state: [{ Num3: [], status3: '不限', sta: true }, { Num3: 'TO_DO', status3: '待处理', sta: false }, { Num3: 'OPTION', status3: '备选', sta: false }, { Num3: 'PASS', status3: 'Pass', sta: false }, { Num3: 'HAS_SEE', status3: '已邀约', sta: false }, { Num3: 'SEE_FAIL', status3: '邀约失败', sta: false },
{Num3:'INTERVIEW_FAIL',status3:'面试淘汰',sta:false},{Num3:'TO_SENT_OFFER',status3:'待Offer',sta:false},{Num3:'HAS_SENT_OFFER',status3:'已发offer',sta:false},{Num3:'HAS_ENTRY',status3:'已入职',sta:false},{Num3:'NO_ENTRY',status3:'未入职',sta:false},{Num3:'END',status3:'终止面试',sta:false},], { Num3: 'INTERVIEW_FAIL', status3: '面试淘汰', sta: false }, { Num3: 'TO_SENT_OFFER', status3: '待Offer', sta: false }, { Num3: 'HAS_SENT_OFFER', status3: '已发offer', sta: false }, { Num3: 'HAS_ENTRY', status3: '已入职', sta: false }, { Num3: 'NO_ENTRY', status3: '未入职', sta: false }, { Num3: 'END', status3: '终止面试', sta: false }],
active:'', active: '',
ownerWorkYears1:[{value:'',label:'不限'},{value:0,label:'0'},{value:1,label:'1'},{value:2,label:'2'},{value:3,label:'3'},{value:4,label:'4'},{value:5,label:'5'}, ownerWorkYears1: [{ value: '', label: '不限' }, { value: 0, label: '0' }, { value: 1, label: '1' }, { value: 2, label: '2' }, { value: 3, label: '3' }, { value: 4, label: '4' }, { value: 5, label: '5' },
{value:6,label:'6'},{value:7,label:'7'},{value:8,label:'8'},{value:9,label:'9'},{value:10,label:'10'}], { value: 6, label: '6' }, { value: 7, label: '7' }, { value: 8, label: '8' }, { value: 9, label: '9' }, { value: 10, label: '10' }],
ownerWorkYears2:[{value:'',label:'不限'},{value:0,label:'0'},{value:1,label:'1'},{value:2,label:'2'},{value:3,label:'3'},{value:4,label:'4'},{value:5,label:'5'}, ownerWorkYears2: [{ value: '', label: '不限' }, { value: 0, label: '0' }, { value: 1, label: '1' }, { value: 2, label: '2' }, { value: 3, label: '3' }, { value: 4, label: '4' }, { value: 5, label: '5' },
{value:6,label:'6'},{value:7,label:'7'},{value:8,label:'8'},{value:9,label:'9'},{value:10,label:'10'}], { value: 6, label: '6' }, { value: 7, label: '7' }, { value: 8, label: '8' }, { value: 9, label: '9' }, { value: 10, label: '10' }],
value:[], value: [],
ajaxData: [], ajaxData: [],
checkData: [] // 双向数据绑定的数组 checkData: [] // 双向数据绑定的数组
} }
...@@ -610,306 +610,302 @@ import {mapState} from 'vuex' ...@@ -610,306 +610,302 @@ import {mapState} from 'vuex'
watch: { watch: {
checkboxList: { checkboxList: {
handler: function (val, oldVal) { handler: function (val, oldVal) {
if(this.delateARRALL.length==30 || (this.ajaxData.length!=0&&this.checkboxList.length === this.ajaxData.length)){ if (this.delateARRALL.length == 30 || (this.ajaxData.length != 0 && this.checkboxList.length === this.ajaxData.length)) {
this.checked=true this.checked = true
} } else {
else { this.checked = false
this.checked=false;
} }
}, },
deep: true deep: true
} }
}, },
components:{ components: {
ckeditor ckeditor
}, },
computed:{ computed: {
}, },
methods: { methods: {
//全选与反选 // 全选与反选
checkedAll: function() { checkedAll: function () {
if (this.checked) {//实现反选 if (this.checked) { // 实现反选
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.removeInterviewee(item) this.removeInterviewee(item)
this.checkboxList = []; this.checkboxList = []
this.delateARRALL=[]; this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
item.STATES=false item.STATES = false
}); })
} else { //实现全选 } else { // 实现全选
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.addInterviewee(item) this.addInterviewee(item)
this.checkboxList.push(item.id); this.checkboxList.push(item.id)
this.delateARRALL.push(item.id); this.delateARRALL.push(item.id)
this.flowStatusarr.push(item.flowStatus) this.flowStatusarr.push(item.flowStatus)
item.STATES=true item.STATES = true
}); })
} }
}, },
// 准备约面 // 准备约面
tosee(){ tosee () {
let parmars={ const parmars = {
status:"TO_SEE", status: 'TO_SEE',
id:this.toseeid, id: this.toseeid
} }
TOSEE(parmars).then(res=>{ TOSEE(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal2=false this.modal2 = false
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
}) })
}, },
//操作处理面试状态 // 操作处理面试状态
changeFlowstatus(e,SID,itemsta,orsta){ changeFlowstatus (e, SID, itemsta, orsta) {
this.toseeid=SID this.toseeid = SID
this.emailId=SID this.emailId = SID
this.emailIdArr=[] this.emailIdArr = []
this.emailIdArr.push(SID) this.emailIdArr.push(SID)
this.isShowTwo=true this.isShowTwo = true
this.ITEMSTA=itemsta this.ITEMSTA = itemsta
if(e.target.value=='TO_SEE'){ if (e.target.value == 'TO_SEE') {
this.emailFlowStatus='TO_SEE' this.emailFlowStatus = 'TO_SEE'
this.isShowTwo=true this.isShowTwo = true
this.sendEmail('',orsta,SID) this.sendEmail('', orsta, SID)
} }
if(e.target.value=='PASS'){ if (e.target.value == 'PASS') {
let parmars={ const parmars = {
status:"PASS", status: 'PASS',
id:SID, id: SID
} }
PASS(parmars).then(res=>{ PASS(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
if(e.target.value=='OPTION'){ if (e.target.value == 'OPTION') {
let parmars={ const parmars = {
status:"OPTION", status: 'OPTION',
id:SID, id: SID
} }
OPTION(parmars).then(res=>{ OPTION(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
if(e.target.value=='TO_DO'){ if (e.target.value == 'TO_DO') {
let parmars={ const parmars = {
status:"TO_DO", status: 'TO_DO',
id:SID, id: SID
} }
TODORes(parmars).then(res=>{ TODORes(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
}, },
addINTERVIEW(){ addINTERVIEW () {
let parmars={ const parmars = {
resumeId: this.toseeid, resumeId: this.toseeid,
inviterName:this.formInline.UpdateOWER, inviterName: this.formInline.UpdateOWER,
intervieweeName:this.formInline.UpdateVIEW, intervieweeName: this.formInline.UpdateVIEW,
seeTime:moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm'), seeTime: moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm')
} }
if(this.formInline.UpdateOWER==''||this.formInline.UpdateVIEW==''||this.formInline.UpdateTIME==''){ if (this.formInline.UpdateOWER == '' || this.formInline.UpdateVIEW == '' || this.formInline.UpdateTIME == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写完整的约面信息' desc: '请您填写完整的约面信息'
}); })
return return
} }
addinterview(parmars).then(res=>{ addinterview(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal2=false this.modal2 = false
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.body.code==0){ if (res.data.body.code == 0) {
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
}) })
}, },
getpositionList(){ getpositionList () {
let parmars={ const parmars = {
optSourceCode:'' optSourceCode: ''
} }
getlist(parmars).then(res=>{ getlist(parmars).then(res => {
this.positionArr=res.data.body this.positionArr = res.data.body
}) })
}, },
//选择搜索元素 // 选择搜索元素
selectElement1(tItem,Tindex){ selectElement1 (tItem, Tindex) {
this.searchInfo.SEX=Tindex==0?'':tItem; this.searchInfo.SEX = Tindex == 0 ? '' : tItem
this.clickIndex1=Tindex this.clickIndex1 = Tindex
}, },
selectElement2(tItem,Tindex){ selectElement2 (tItem, Tindex) {
this.searchInfo.Edu=tItem; this.searchInfo.Edu = tItem
this.clickIndex2=Tindex this.clickIndex2 = Tindex
}, },
selectElement3(tItem,Tindex,status3,sta3){ selectElement3 (tItem, Tindex, status3, sta3) {
sta3=!sta3 sta3 = !sta3
this.state[Tindex].sta=sta3 this.state[Tindex].sta = sta3
if(Tindex==0){ if (Tindex == 0) {
this.searchInfo.STA=[] this.searchInfo.STA = []
this.state.map((item,index)=>{ this.state.map((item, index) => {
if(index!==0){ if (index !== 0) {
item.sta=false item.sta = false
} }
if(index==0){ if (index == 0) {
item.sta=true item.sta = true
} }
return item return item
}) })
return return
} }
if(Tindex!==0){ if (Tindex !== 0) {
this.state[0].sta=false this.state[0].sta = false
} }
if(sta3==true){ if (sta3 == true) {
this.searchInfo.STA.push(tItem) this.searchInfo.STA.push(tItem)
} }
if(sta3==false){ if (sta3 == false) {
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
this.searchInfo.STA.remove(tItem) this.searchInfo.STA.remove(tItem)
} }
}, },
//获取option的值 // 获取option的值
selectElement4(){ selectElement4 () {
}, },
//搜索 // 搜索
SouSuo(page, status){ SouSuo (page, status) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
this.interviewee = [] this.interviewee = []
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter:{ parameter: {
optSourceCode:'', optSourceCode: '',
keywordString:this.keywords==''?'':this.keywords, keywordString: this.keywords == '' ? '' : this.keywords,
company:this.lrgs==''?'':this.lrgs, company: this.lrgs == '' ? '' : this.lrgs,
ownerSex:this.searchInfo.SEX, ownerSex: this.searchInfo.SEX,
highestDegreeNum:this.searchInfo.Edu, highestDegreeNum: this.searchInfo.Edu,
flowStatusList:this.searchInfo.STA, flowStatusList: this.searchInfo.STA,
ownerWorkYears1:this.searchInfo.ownerWorkYears1, ownerWorkYears1: this.searchInfo.ownerWorkYears1,
ownerWorkYears2:this.searchInfo.ownerWorkYears2, ownerWorkYears2: this.searchInfo.ownerWorkYears2,
ownerExpectTitlesList:this.position, ownerExpectTitlesList: this.position,
handUpload:'' handUpload: ''
} }
} }
this.ajaxData=[] this.ajaxData = []
this.checkboxList = []
sousuoList(parmars, status).then(res => {
const Ishow = res.data.items
if (res.data.success == true) {
this.checkboxList = [] this.checkboxList = []
sousuoList(parmars,status).then(res=>{ this.spinShow = false
let Ishow=res.data.items this.totalSize = res.data.body.totalNumber
if(res.data.success==true){ const data = res.data.body.items || []
this.checkboxList=[] this.ajaxData = res.data.body.items.map((item, index) => {
this.spinShow=false item.id = item.id
this.totalSize=res.data.body.totalNumber item.ownerName = item.ownerName
let data = res.data.body.items || [] item.ownerSex = item.ownerSex
this.ajaxData=res.data.body.items.map((item,index)=>{ item.belongs = item.belongs
item.id=item.id item.emailSendtime = item.emailSendtime
item.ownerName=item.ownerName item.ownerMobile = item.ownerMobile
item.ownerSex=item.ownerSex item.ownerHighestDegree = item.ownerHighestDegree
item.belongs=item.belongs item.ownerExpectTitles = item.ownerExpectTitles
item.emailSendtime=item.emailSendtime item.flowStatus = item.flowStatus
item.ownerMobile=item.ownerMobile item.ownerAge = item.ownerAge
item.ownerHighestDegree=item.ownerHighestDegree item.ownerWorkYears = item.ownerWorkYears
item.ownerExpectTitles=item.ownerExpectTitles item.modifyTime = item.modifyTime
item.flowStatus=item.flowStatus item.srcSite = item.srcSite
item.ownerAge=item.ownerAge item.hasForward = item.hasForward
item.ownerWorkYears=item.ownerWorkYears item.optSource = item.optSource
item.modifyTime=item.modifyTime item.STATES = false
item.srcSite=item.srcSite item.isShow = false
item.hasForward=item.hasForward item.modifier = item.modifier
item.optSource=item.optSource item.uid = item.uid
item.STATES=false item.originValue = item.flowStatus
item.isShow=false item.hasRead = item.hasRead
item.modifier=item.modifier item.c = item.modifier == '' ? item.modifier : item.modifier.split('_')
item.uid=item.uid item.d = item.c[0]
item.originValue=item.flowStatus
item.hasRead=item.hasRead
item.c=item.modifier==''?item.modifier:item.modifier.split('_')
item.d=item.c[0]
return item return item
}) })
} }
}) })
}, },
// 判断输入年限的大小 // 判断输入年限的大小
judge1(value){ judge1 (value) {
this.searchInfo.ownerWorkYears1=value.value this.searchInfo.ownerWorkYears1 = value.value
}, },
judge2(value){ judge2 (value) {
this.searchInfo.ownerWorkYears2=value.value this.searchInfo.ownerWorkYears2 = value.value
if(this.searchInfo.ownerWorkYears1>this.searchInfo.ownerWorkYears2){ if (this.searchInfo.ownerWorkYears1 > this.searchInfo.ownerWorkYears2) {
this.Black=true this.Black = true
let t1=setTimeout(() => { const t1 = setTimeout(() => {
this.Black=false this.Black = false
}, 3000) }, 3000)
} }
}, },
// 操作记录查询 // 操作记录查询
RecordSEE(RID,sname){ RecordSEE (RID, sname) {
this.toseename=sname this.toseename = sname
this.modal1=true this.modal1 = true
let parmars={ const parmars = {
resumeId:RID resumeId: RID
} }
recodeLIST(parmars).then(res=>{ recodeLIST(parmars).then(res => {
this.ownerName=res.data.body.ownerName this.ownerName = res.data.body.ownerName
this.recordList=res.data.body.map((item,index)=>{ this.recordList = res.data.body.map((item, index) => {
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.approveUserName=item.approveUserName item.approveUserName = item.approveUserName
item.dateTime=item.dateTime item.dateTime = item.dateTime
item.previousState=item.previousState item.previousState = item.previousState
item.afterState=item.afterState item.afterState = item.afterState
return item return item
}) })
}) })
}, },
// 选择input元素 // 选择input元素
selectInputElement(index,doID,doStatus,sss, item){ selectInputElement (index, doID, doStatus, sss, item) {
this.DOWNLOAD=doID this.DOWNLOAD = doID
this.emailIdArr = [] this.emailIdArr = []
sss=!sss sss = !sss
this.ajaxData[index].STATES=sss this.ajaxData[index].STATES = sss
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
if(sss==true){ if (sss == true) {
this.emailIdArr.push(doID) this.emailIdArr.push(doID)
// this.emailId=doID // this.emailId=doID
this.delateARRALL.push(doID) this.delateARRALL.push(doID)
...@@ -917,7 +913,7 @@ import {mapState} from 'vuex' ...@@ -917,7 +913,7 @@ import {mapState} from 'vuex'
this.flowStatusarr.push(doStatus) this.flowStatusarr.push(doStatus)
this.addInterviewee(item) this.addInterviewee(item)
} }
if(sss==false){ if (sss == false) {
this.delateARRALL.remove(doID) this.delateARRALL.remove(doID)
this.delateARRALL2.remove(doID) this.delateARRALL2.remove(doID)
this.flowStatusarr.remove(doStatus) this.flowStatusarr.remove(doStatus)
...@@ -925,60 +921,60 @@ import {mapState} from 'vuex' ...@@ -925,60 +921,60 @@ import {mapState} from 'vuex'
this.emailIdArr.remove(doID) this.emailIdArr.remove(doID)
} }
}, },
//查看简历详情 // 查看简历详情
Seedetail(Tid,Uid,STATUS){ Seedetail (Tid, Uid, STATUS) {
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
this.DOWNID=Uid this.DOWNID = Uid
this.detailID=Tid this.detailID = Tid
this.resumeDetailSta=STATUS this.resumeDetailSta = STATUS
let newpage = this.$router.resolve({ const newpage = this.$router.resolve({
name: 'resumeDetail', name: 'resumeDetail',
params:{}, params: {},
query:{id:this.DOWNID,noShowBtn:'',ID:this.detailID,status:this.resumeDetailSta} query: { id: this.DOWNID, noShowBtn: '', ID: this.detailID, status: this.resumeDetailSta }
}) })
window.open(newpage.href, '_blank'); window.open(newpage.href, '_blank')
}, },
//下载单条简历 // 下载单条简历
downloadONE(downID){ downloadONE (downID) {
window.location.href=`${sapi}/api/resume/download/formatted/one?resumeId=${downID}` window.location.href = `${sapi}/api/resume/download/formatted/one?resumeId=${downID}`
}, },
// 批量下载简历 // 批量下载简历
downloadAll(){ downloadAll () {
if(this.checkboxList==''){ if (this.checkboxList == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空' desc: '选项不能为空'
}); })
return return
} }
let url=`${sapi}/api/resume/download/formatted/compress` let url = `${sapi}/api/resume/download/formatted/compress`
this.checkboxList.map((item,index)=>{ this.checkboxList.map((item, index) => {
url+=index==0?`?resumeId=${item}`:`&resumeId=${item}` url += index == 0 ? `?resumeId=${item}` : `&resumeId=${item}`
}) })
window.location.href=url window.location.href = url
// this.checkboxList=[] // this.checkboxList=[]
}, },
// 可删除状态下点击 // 可删除状态下点击
delateR(delateid){ delateR (delateid) {
this.delateARRALL3 = [] this.delateARRALL3 = []
this.delateARRALL3.push(delateid) this.delateARRALL3.push(delateid)
this.modal3=true this.modal3 = true
}, },
// 删除单条简历 // 删除单条简历
delateONE(){ delateONE () {
deleteREsume(this.delateARRALL3).then(res=>{ deleteREsume(this.delateARRALL3).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.delateARRALL3.map(item => { this.delateARRALL3.map(item => {
this.removeInterviewee({id:item}) this.removeInterviewee({ id: item })
}) })
this.modal3=false this.modal3 = false
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
}, },
changeTime(b){ changeTime (b) {
this.UpdateTIME=b this.UpdateTIME = b
if (!b){ if (!b) {
this.editorObject = { this.editorObject = {
type: this.temp, type: this.temp,
value: this.emailInline.templateContent value: this.emailInline.templateContent
...@@ -1001,445 +997,439 @@ import {mapState} from 'vuex' ...@@ -1001,445 +997,439 @@ import {mapState} from 'vuex'
} }
}, },
// 不可删除状态下点击 // 不可删除状态下点击
undelate(){ undelate () {
this.modal4=true this.modal4 = true
}, },
// 批量删除 // 批量删除
delateAll(){ delateAll () {
var array1 = this.orignarr;//数组1 var array1 = this.orignarr// 数组1
var array2 = this.flowStatusarr;//数组2 var array2 = this.flowStatusarr// 数组2
var tempArray1 = [];//临时数组1 var tempArray1 = []// 临时数组1
var tempArray2 = [];//临时数组2 var tempArray2 = []// 临时数组2
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
for(var i=0;i<array2.length;i++){ for (var i = 0; i < array2.length; i++) {
tempArray1[array2[i]]=true;//将数array2 中的元素值作为tempArray1 中的键,值为true; tempArray1[array2[i]] = true// 将数array2 中的元素值作为tempArray1 中的键,值为true;
} }
for(var i=0;i<array1.length;i++){ for (var i = 0; i < array1.length; i++) {
if(tempArray1[array1[i]]){ if (tempArray1[array1[i]]) {
tempArray2.push(array1[i]);//过滤array1 中与array2 相同的元素; tempArray2.push(array1[i])// 过滤array1 中与array2 相同的元素;
} }
} }
if(tempArray2.length!==0){ if (tempArray2.length !== 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '您选中的简历中包含不可删除简历' desc: '您选中的简历中包含不可删除简历'
}); })
} }
if(this.delateARRALL.length==0){ if (this.delateARRALL.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空' desc: '选项不能为空'
}); })
return return
} }
if(tempArray2.length==0){ if (tempArray2.length == 0) {
this.modal7=true this.modal7 = true
} }
}, },
//确认批量删除 // 确认批量删除
cofdelateAll(){ cofdelateAll () {
var array1 = this.orignarr;//数组1 var array1 = this.orignarr// 数组1
var array2 = this.flowStatusarr;//数组2 var array2 = this.flowStatusarr// 数组2
var tempArray1 = [];//临时数组1 var tempArray1 = []// 临时数组1
var tempArray2 = [];//临时数组2 var tempArray2 = []// 临时数组2
for(var i=0;i<array2.length;i++){ for (var i = 0; i < array2.length; i++) {
tempArray1[array2[i]]=true;//将数array2 中的元素值作为tempArray1 中的键,值为true; tempArray1[array2[i]] = true// 将数array2 中的元素值作为tempArray1 中的键,值为true;
} }
for(var i=0;i<array1.length;i++){ for (var i = 0; i < array1.length; i++) {
if(tempArray1[array1[i]]){ if (tempArray1[array1[i]]) {
tempArray2.push(array1[i]);//过滤array1 中与array2 相同的元素; tempArray2.push(array1[i])// 过滤array1 中与array2 相同的元素;
} }
} }
if(tempArray2.length!==0){ if (tempArray2.length !== 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '您选中的简历中包含不可删除简历' desc: '您选中的简历中包含不可删除简历'
}); })
} }
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
this.DELATEARR=this.delateARRALL this.DELATEARR = this.delateARRALL
deleteREsume(this.DELATEARR).then(res=>{ deleteREsume(this.DELATEARR).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal7=false this.modal7 = false
this.delateARRALL.map(item => { this.delateARRALL.map(item => {
this.removeInterviewee({id:item}) this.removeInterviewee({ id: item })
}) })
this.delateARRALL=[] this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
}) })
}, },
// 批量导出 // 批量导出
allexport(){ allexport () {
let parmars={ const parmars = {
optSourceCode:'', optSourceCode: '',
keywordString:this.keywords==''?'':this.keywords, keywordString: this.keywords == '' ? '' : this.keywords,
company:this.lrgs==''?'':this.lrgs, company: this.lrgs == '' ? '' : this.lrgs,
ownerSex:this.searchInfo.SEX, ownerSex: this.searchInfo.SEX,
highestDegreeNum:this.searchInfo.Edu, highestDegreeNum: this.searchInfo.Edu,
flowStatusList:this.clickIndex3=0?this.searchInfo.STA=[]:this.searchInfo.STA, flowStatusList: this.clickIndex3 = 0 ? this.searchInfo.STA = [] : this.searchInfo.STA,
ownerWorkYears1:this.searchInfo.ownerWorkYears1, ownerWorkYears1: this.searchInfo.ownerWorkYears1,
ownerWorkYears2:this.searchInfo.ownerWorkYears2, ownerWorkYears2: this.searchInfo.ownerWorkYears2
} }
window.location.href=`${sapi}/api/excel/output?optSourceCode=${parmars.optSourceCode}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}` window.location.href = `${sapi}/api/excel/output?optSourceCode=${parmars.optSourceCode}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}`
}, },
//改变页码 // 改变页码
pageChange(page){ pageChange (page) {
this.pageT=page this.pageT = page
this.delateARRALL=[] this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
this.searchInfo.ownerWorkYears1='' this.searchInfo.ownerWorkYears1 = ''
this.searchInfo.ownerWorkYears2='' this.searchInfo.ownerWorkYears2 = ''
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.SouSuo() this.SouSuo()
}, },
// 跳转到面试管理 // 跳转到面试管理
tointerview(){ tointerview () {
this.$router.push({name:'interview',params:{fromInterview:true}}) this.$router.push({ name: 'interview', params: { fromInterview: true } })
}, },
// 刷新列表 // 刷新列表
pushlist(){ pushlist () {
this.modal2=false this.modal2 = false
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
}, },
// 鼠标滑过事件 // 鼠标滑过事件
ahove(index,vvv){ ahove (index, vvv) {
this.ajaxData[index].isShow=true this.ajaxData[index].isShow = true
}, },
movleave(index,vvv){ movleave (index, vvv) {
this.ajaxData[index].isShow=false this.ajaxData[index].isShow = false
}, },
// 发送邮件 // 发送邮件
sendEmail(type,status,SID){ sendEmail (type, status, SID) {
this.selectElementValue=status this.selectElementValue = status
this.resumePushId=SID this.resumePushId = SID
if(this.checkboxList.length == 0&&type) { if (this.checkboxList.length == 0 && type) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '你尚未选择简历,请先选择简历' desc: '你尚未选择简历,请先选择简历'
}) })
return return
} }
if (this.checkboxList.length > 1&&type){ if (this.checkboxList.length > 1 && type) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: ' 不能选择多份简历,请选择单份简历' desc: ' 不能选择多份简历,请选择单份简历'
}) })
return return
} }
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.$refs.emailInline.resetFields() this.$refs.emailInline.resetFields()
this.$refs.formInline.resetFields() this.$refs.formInline.resetFields()
this.emailInline.moo = 'TEMP_0001' this.emailInline.moo = 'TEMP_0001'
this.options=[] this.options = []
this.emailMOdal=true this.emailMOdal = true
getEmailMoo().then(res=>{ getEmailMoo().then(res => {
this.emailInline.modalArr=res.data.body this.emailInline.modalArr = res.data.body
}) })
this.getEmailContentValue(this.emailInline.moo) this.getEmailContentValue(this.emailInline.moo)
}, },
getEmailContentValue(value){ getEmailContentValue (value) {
if (!value){ if (!value) {
return return
} }
this.isDisable=true this.isDisable = true
this.temp=value this.temp = value
if(this.isShowTwo==true){ if (this.isShowTwo == true) {
this.isShowAll=true this.isShowAll = true
this.interviewIsShow=true this.interviewIsShow = true
}else{ } else {
if(this.emailIdArr.length>1&&(value=='TEMP_0001'||value=='TEMP_0005'||value=='TEMP_0006')){ if (this.emailIdArr.length > 1 && (value == 'TEMP_0001' || value == 'TEMP_0005' || value == 'TEMP_0006')) {
this.allEmailVilitor=true this.allEmailVilitor = true
}else { } else {
this.allEmailVilitor=false this.allEmailVilitor = false
if(this.temp=='TEMP_0001'){ if (this.temp == 'TEMP_0001') {
this.isShowAll=true this.isShowAll = true
}else{ } else {
this.isShowAll=false this.isShowAll = false
} }
} }
if(value=='TEMP_0001'){ if (value == 'TEMP_0001') {
this.interviewIsShow=true this.interviewIsShow = true
this.isShowAll=true this.isShowAll = true
}else{ } else {
this.interviewIsShow=false this.interviewIsShow = false
this.isShowAll=false this.isShowAll = false
} }
this.emailId=this.emailIdArr.length==0?'':this.emailIdArr[0] this.emailId = this.emailIdArr.length == 0 ? '' : this.emailIdArr[0]
if(value=='TEMP_0001' &&this.emailId==''){ if (value == 'TEMP_0001' && this.emailId == '') {
this.interviewBtu=true this.interviewBtu = true
this.isShowAll=true this.isShowAll = true
this.emailMassage=true this.emailMassage = true
} } else if (value == 'TEMP_0005' && this.emailId == '') {
else if(value=='TEMP_0005' && this.emailId==''){ this.emailMassage = true
this.emailMassage=true } else if (value == 'TEMP_0006' && this.emailId == '') {
} this.emailMassage = true
else if(value=='TEMP_0006' && this.emailId==''){ } else {
this.emailMassage=true if (value == 'TEMP_0001') { this.isShowAll = true } else { this.isShowAll = false }
} this.interviewBtu = false
else{
if(value=='TEMP_0001'){this.isShowAll=true}else{this.isShowAll=false}
this.interviewBtu=false
this.emailMassage=false this.emailMassage = false
} }
} }
this.emailCode=value this.emailCode = value
let params={ const params = {
resumeId:this.emailId==''?'':this.emailId, resumeId: this.emailId == '' ? '' : this.emailId,
templateCode:this.emailCode templateCode: this.emailCode
} }
getEmailContent(params).then(res=>{ getEmailContent(params).then(res => {
this.emailInline.theme=res.data.body.templateSubject this.emailInline.theme = res.data.body.templateSubject
this.emailInline.receiveEmail=res.data.body.receiveEmail this.emailInline.receiveEmail = res.data.body.receiveEmail
this.emailInline.templateContent=res.data.body.templateContent this.emailInline.templateContent = res.data.body.templateContent
this.editorObject = { this.editorObject = {
type: value, type: value,
value: this.emailInline.templateContent || '' value: this.emailInline.templateContent || ''
} }
if(res.data.body&&res.data.body.resumeInterviewVO){ if (res.data.body && res.data.body.resumeInterviewVO) {
this.formInline.UpdateOWER=res.data.body.resumeInterviewVO.inviterName this.formInline.UpdateOWER = res.data.body.resumeInterviewVO.inviterName
this.formInline.UpdateVIEW=res.data.body.resumeInterviewVO.interviewerName this.formInline.UpdateVIEW = res.data.body.resumeInterviewVO.interviewerName
this.formInline.UpdateTIME=res.data.body.resumeInterviewVO.seeTime this.formInline.UpdateTIME = res.data.body.resumeInterviewVO.seeTime
this.changeTime(this.formInline.UpdateTIME) this.changeTime(this.formInline.UpdateTIME)
}else{ } else {
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
} }
}) })
}, },
uploadFile(){ uploadFile () {
// this.uploadFileList=[] // this.uploadFileList=[]
this.limentName=0 this.limentName = 0
}, },
beforUpload(uploadFile){ beforUpload (uploadFile) {
let isLiment=false let isLiment = false
if(uploadFile.size/1024 > 10240){ if (uploadFile.size / 1024 > 10240) {
isLiment=true isLiment = true
this.limentName+=1 this.limentName += 1
if(this.limentName==1){ if (this.limentName == 1) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '单个文件不能大于10M' desc: '单个文件不能大于10M'
}) })
} }
}else{ } else {
this.fileList.push(uploadFile.name) this.fileList.push(uploadFile.name)
this.uploadFileList.push(uploadFile) this.uploadFileList.push(uploadFile)
} }
return false return false
}, },
emailModalPush(){ emailModalPush () {
this.$refs.emailInline.resetFields() this.$refs.emailInline.resetFields()
this.$refs.formInline.resetFields() this.$refs.formInline.resetFields()
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.uploadFileList=[] this.uploadFileList = []
// this.clearInterviewee() // this.clearInterviewee()
this.ajaxData.map(item=>{ this.ajaxData.map(item => {
if(item.id==this.resumePushId){ if (item.id == this.resumePushId) {
item.flowStatus=item.originValue item.flowStatus = item.originValue
} }
}) })
}, },
getEditorValue(value){ // 调编辑器组件方法获取数据 getEditorValue (value) { // 调编辑器组件方法获取数据
return this.$refs.editor.getValue() return this.$refs.editor.getValue()
}, },
delateFile(index){ delateFile (index) {
this.fileList.splice(index,1) this.fileList.splice(index, 1)
this.uploadFileList.splice(index,1) this.uploadFileList.splice(index, 1)
}, },
// 确认发送邮件 // 确认发送邮件
confireSendEmail:_debounce(function(){ confireSendEmail: _debounce(function () {
this.sad = this.getEditorValue() this.sad = this.getEditorValue()
if(this.sad==''){ if (this.sad == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if(this.emailInline.moo==''){ if (this.emailInline.moo == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0001')&&(this.emailInline.moo==''||this.emailInline.receiveEmail==''||this.emailInline.theme==''||this.formInline.UpdateOWER==''||this.formInline.UpdateVIEW==''||this.formInline.UpdateTIME=='')){ if ((this.temp == 'TEMP_0001') && (this.emailInline.moo == '' || this.emailInline.receiveEmail == '' || this.emailInline.theme == '' || this.formInline.UpdateOWER == '' || this.formInline.UpdateVIEW == '' || this.formInline.UpdateTIME == '')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0002'||this.temp=='TEMP_0003'||this.temp=='TEMP_0004'||this.temp=='TEMP_0005'||this.temp=='TEMP_0006')&&(this.emailInline.moo==''||this.emailInline.receiveEmail==''||this.emailInline.theme=='')){ if ((this.temp == 'TEMP_0002' || this.temp == 'TEMP_0003' || this.temp == 'TEMP_0004' || this.temp == 'TEMP_0005' || this.temp == 'TEMP_0006') && (this.emailInline.moo == '' || this.emailInline.receiveEmail == '' || this.emailInline.theme == '')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0001'|| this.temp=='TEMP_0005'|| this.temp=='TEMP_0006')&&this.emailId==''){ if ((this.temp == 'TEMP_0001' || this.temp == 'TEMP_0005' || this.temp == 'TEMP_0006') && this.emailId == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请先选择简历' desc: '请先选择简历'
}); })
return return
} }
if(this.emailInline.copyname!==''&&!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))){ if (this.emailInline.copyname !== '' && !(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
if(!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))){ if (!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
this.attachFileList = this.uploadFileList.length == 0 ? '' : this.uploadFileList
this.attachFileList=this.uploadFileList.length==0?'':this.uploadFileList this.flowStatusTT = this.emailFlowStatus == '' ? '' : 'TO_SEE'
this.flowStatusTT=this.emailFlowStatus==''?'':'TO_SEE' this.UpdateTIMETwo = this.formInline.UpdateTIME == '' ? '' : this.formInline.UpdateTIME
this.UpdateTIMETwo=this.formInline.UpdateTIME==''?'':this.formInline.UpdateTIME if (this.temp == 'TEMP_0001') {
if(this.temp=='TEMP_0001'){ var formData = new FormData()
var formData= new FormData() if (this.attachFileList.length !== 0) {
if(this.attachFileList.length!==0){ this.attachFileList.map(item => {
this.attachFileList.map(item=>{ formData.append('attachFileList', item)
formData.append('attachFileList',item)
}) })
}else{ } else {
formData.append('attachFileList','') formData.append('attachFileList', '')
} }
formData.append('resumeId',this.emailId) formData.append('resumeId', this.emailId)
formData.append('templateCode',this.emailCode) formData.append('templateCode', this.emailCode)
formData.append('subject',this.emailInline.theme) formData.append('subject', this.emailInline.theme)
formData.append('toEmail',this.emailInline.receiveEmail) formData.append('toEmail', this.emailInline.receiveEmail)
formData.append('ccEmail',this.emailInline.copyname) formData.append('ccEmail', this.emailInline.copyname)
formData.append('emailContent',this.sad) formData.append('emailContent', this.sad)
formData.append('resumeInterviewVO.resumeId',this.emailId) formData.append('resumeInterviewVO.resumeId', this.emailId)
formData.append('resumeInterviewVO.inviterName',this.formInline.UpdateOWER==''?'':this.formInline.UpdateOWER) formData.append('resumeInterviewVO.inviterName', this.formInline.UpdateOWER == '' ? '' : this.formInline.UpdateOWER)
formData.append('resumeInterviewVO.interviewerName',this.formInline.UpdateVIEW==''?'':this.formInline.UpdateVIEW) formData.append('resumeInterviewVO.interviewerName', this.formInline.UpdateVIEW == '' ? '' : this.formInline.UpdateVIEW)
let info = this.options.find(item => item.name == this.formInline.UpdateVIEW) const info = this.options.find(item => item.name == this.formInline.UpdateVIEW)
formData.append('resumeInterviewVO.email',(info&&info.email) || '') formData.append('resumeInterviewVO.email', (info && info.email) || '')
formData.append('sendWeixin',this.formInline.sendWeixin==true ? 1 : 0) formData.append('sendWeixin', this.formInline.sendWeixin == true ? 1 : 0)
formData.append('resumeInterviewVO.seeTime',moment( this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm')) formData.append('resumeInterviewVO.seeTime', moment(this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm'))
formData.append(' flowStatus',this.flowStatusTT) formData.append(' flowStatus', this.flowStatusTT)
this.isDisable=false this.isDisable = false
sendEmail(formData).then(res=>{ sendEmail(formData).then(res => {
this.isDisable=true this.isDisable = true
if(res.data.success==true){ if (res.data.success == true) {
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '发送邮件成功' desc: '发送邮件成功'
}) })
}, 500) }, 500)
this.emailMOdal=false this.emailMOdal = false
this.modal10=false this.modal10 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal10 = false this.modal10 = false
this.modal11 = true this.modal11 = true
this.errorInfo = res.data.body.message this.errorInfo = res.data.body.message
} }
}) })
}else{ } else {
var formData= new FormData() var formData = new FormData()
if(this.attachFileList.length!==0){ if (this.attachFileList.length !== 0) {
this.attachFileList.map(item=>{ this.attachFileList.map(item => {
formData.append('attachFileList',item) formData.append('attachFileList', item)
}) })
}else{ } else {
formData.append('attachFileList','') formData.append('attachFileList', '')
} }
formData.append('resumeId',this.emailId) formData.append('resumeId', this.emailId)
formData.append('templateCode',this.emailCode) formData.append('templateCode', this.emailCode)
formData.append('subject',this.emailInline.theme) formData.append('subject', this.emailInline.theme)
formData.append('toEmail',this.emailInline.receiveEmail) formData.append('toEmail', this.emailInline.receiveEmail)
formData.append('ccEmail',this.emailInline.copyname) formData.append('ccEmail', this.emailInline.copyname)
formData.append('emailContent',this.sad) formData.append('emailContent', this.sad)
formData.append(' flowStatus',this.flowStatusTT) formData.append(' flowStatus', this.flowStatusTT)
this.isDisable=false this.isDisable = false
sendEmail(formData).then(res=>{ sendEmail(formData).then(res => {
this.isDisable=true this.isDisable = true
if(res.data.success==true){ if (res.data.success == true) {
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
...@@ -1447,40 +1437,40 @@ import {mapState} from 'vuex' ...@@ -1447,40 +1437,40 @@ import {mapState} from 'vuex'
}) })
}, 500) }, 500)
this.emailMOdal=false this.emailMOdal = false
this.modal10=false this.modal10 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.emailInline.copyname='' this.emailInline.copyname = ''
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal10 = false this.modal10 = false
this.modal11 = true this.modal11 = true
this.errorInfo = res.data.body.message this.errorInfo = res.data.body.message
} }
}) })
} }
},800), }, 800),
removeInterviewee (value) { removeInterviewee (value) {
this.interviewee.map((item, index) => { this.interviewee.map((item, index) => {
if (value&&item.id == value.id) { if (value && item.id == value.id) {
this.interviewee.splice(index, 1) this.interviewee.splice(index, 1)
} }
}) })
...@@ -1488,9 +1478,8 @@ import {mapState} from 'vuex' ...@@ -1488,9 +1478,8 @@ import {mapState} from 'vuex'
addInterviewee (data) { addInterviewee (data) {
let flag = false let flag = false
this.interviewee.map(item => { this.interviewee.map(item => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
flag = true flag = true
return
} }
}) })
if (!flag) { if (!flag) {
...@@ -1506,20 +1495,20 @@ import {mapState} from 'vuex' ...@@ -1506,20 +1495,20 @@ import {mapState} from 'vuex'
item.STATES = false item.STATES = false
}) })
}, },
transpond() { //打开转发简历的modal transpond () { // 打开转发简历的modal
if(this.interviewee.length == 0) { if (this.interviewee.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请选择您要转发的简历' desc: '请选择您要转发的简历'
}); })
return return
} }
this.$refs.transpondFrom.resetFields() this.$refs.transpondFrom.resetFields()
this.modal8= true this.modal8 = true
}, },
delInterviewee (item) { delInterviewee (item) {
this.removeInterviewee(item) this.removeInterviewee(item)
let indexOf = this.checkboxList.indexOf(item.id) const indexOf = this.checkboxList.indexOf(item.id)
if (indexOf < 0) return if (indexOf < 0) return
this.checkboxList.splice(indexOf, 1) this.checkboxList.splice(indexOf, 1)
this.delateARRALL.splice(indexOf, 1) this.delateARRALL.splice(indexOf, 1)
...@@ -1533,20 +1522,20 @@ import {mapState} from 'vuex' ...@@ -1533,20 +1522,20 @@ import {mapState} from 'vuex'
} }
}) })
}, },
sendNotice:_debounce(function() { sendNotice: _debounce(function () {
this.$refs.transpondFrom.validate(valid => { this.$refs.transpondFrom.validate(valid => {
if(!this.transpondFrom.interviewerName){ if (!this.transpondFrom.interviewerName) {
return return
} }
if (this.interviewee.length < 1) { if (this.interviewee.length < 1) {
this.$Notice.warning({title: '提示',desc: '发送内容为空,请勾选您要发送的简历'}) this.$Notice.warning({ title: '提示', desc: '发送内容为空,请勾选您要发送的简历' })
return return
} }
let resumeIdList = [] const resumeIdList = []
this.interviewee.map(item => { this.interviewee.map(item => {
resumeIdList.push(item.id) resumeIdList.push(item.id)
}) })
let params = { const params = {
resumeIdList, resumeIdList,
email: this.transpondFrom.interviewerName email: this.transpondFrom.interviewerName
} }
...@@ -1554,7 +1543,7 @@ import {mapState} from 'vuex' ...@@ -1554,7 +1543,7 @@ import {mapState} from 'vuex'
if (res.data.success == true) { if (res.data.success == true) {
this.clearInterviewee() this.clearInterviewee()
this.modal8 = false this.modal8 = false
this.isShowRep=false this.isShowRep = false
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
...@@ -1563,107 +1552,104 @@ import {mapState} from 'vuex' ...@@ -1563,107 +1552,104 @@ import {mapState} from 'vuex'
}, 300) }, 300)
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.body.code=='40009'){ if (res.data.body.code == '40009') {
this.reResumeName=res.data.body.message this.reResumeName = res.data.body.message
this.isShowRep=true this.isShowRep = true
return return
} }
if(res.data.body.code=='0'){ if (res.data.body.code == '0') {
this.modal8=false this.modal8 = false
this.isShowRep=false this.isShowRep = false
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: res.data.body.message desc: res.data.body.message
}) })
return return
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal8=false this.modal8 = false
this.modal12=true this.modal12 = true
this.isShowRep=false this.isShowRep = false
this.errorNotice=res.data.body.message this.errorNotice = res.data.body.message
} }
}) })
}) })
},800), }, 800),
pushSendNotice(){ pushSendNotice () {
this.modal8=false, this.modal8 = false,
this.isShowRep=false this.isShowRep = false
}, },
remoteMethod: async function(query){ remoteMethod: async function (query) {
if (query !== '') { if (query !== '') {
this.loading1 = true; this.loading1 = true
setTimeout(async () => { setTimeout(async () => {
this.loading1 = false; this.loading1 = false
query = query.split('(')[0] query = query.split('(')[0]
let list = await findCompanyEmailByKey(query) const list = await findCompanyEmailByKey(query)
this.options = list.data.body || [] this.options = list.data.body || []
}, 200); }, 200)
} else { } else {
this.options = []; this.options = []
} }
}, },
changenotice(a){ changenotice (a) {
}, },
receiveEmail(){ receiveEmail () {
if(!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))){ if (!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))) {
this.tipInfo = '请正确填写邮箱地址' this.tipInfo = '请正确填写邮箱地址'
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
copyname(){ copyname () {
if(this.emailInline.copyname!==''&&!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))){ if (this.emailInline.copyname !== '' && !(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
theme(){ theme () {
if(this.emailInline.theme==''){ if (this.emailInline.theme == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写主题' desc: '请填写主题'
}); })
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
UpdateOWER(){ UpdateOWER () {
if(this.formInline.UpdateOWER==''){ if (this.formInline.UpdateOWER == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
UpdateTIME(){ UpdateTIME () {
if(this.formInline.UpdateTIME==''){ if (this.formInline.UpdateTIME == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
UpdateVIEW(){ UpdateVIEW () {
if(this.formInline.UpdateVIEW==''){ if (this.formInline.UpdateVIEW == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
getfocus(form, name, e){ getfocus (form, name, e) {
let vm = this; const vm = this
let value = this[form][name] const value = this[form][name]
if(name == 'receiveEmail') { if (name == 'receiveEmail') {
this.tip&&this.$refs[form].fields.forEach(function (e) { this.tip && this.$refs[form].fields.forEach(function (e) {
if (e.prop == name) { if (e.prop == name) {
e.resetField() e.resetField()
vm[form][name] = value vm[form][name] = value
...@@ -1671,11 +1657,11 @@ import {mapState} from 'vuex' ...@@ -1671,11 +1657,11 @@ import {mapState} from 'vuex'
} }
}) })
} else { } else {
if (name=='UpdateTIME'&&e==false){ // 时间选择器关闭弹框的时候 if (name == 'UpdateTIME' && e == false) { // 时间选择器关闭弹框的时候
this.$refs.formInline.validateField('UpdateTIME', (e) => {}) this.$refs.formInline.validateField('UpdateTIME', (e) => {})
return return
} }
if (name=='UpdateVIEW'&&e==false){ // 选择关闭弹框的时候 if (name == 'UpdateVIEW' && e == false) { // 选择关闭弹框的时候
this.$refs.formInline.validateField('UpdateVIEW', (e) => { this.$refs.formInline.validateField('UpdateVIEW', (e) => {
}) })
return return
...@@ -1687,64 +1673,61 @@ import {mapState} from 'vuex' ...@@ -1687,64 +1673,61 @@ import {mapState} from 'vuex'
} }
}) })
} }
}, },
submit() { submit () {
let flag = false let flag = false
this.$refs.emailInline.validate(val => { this.$refs.emailInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
this.$refs.formInline.validate(val => { this.$refs.formInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
if (!flag){ if (!flag) {
this.modal10=true this.modal10 = true
} }
}, },
SerchlistinterviewList(){ SerchlistinterviewList () {
Serchinterviewor().then(res=>{ Serchinterviewor().then(res => {
this.interviewerNameList=res.data.body this.interviewerNameList = res.data.body
}) })
}, },
cancelSubmit(){ cancelSubmit () {
this.emailMOdal=false this.emailMOdal = false
this.modal11=false this.modal11 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
}, },
sendFail(){ sendFail () {
this.modal11 = false this.modal11 = false
} }
}, },
mounted(){ mounted () {
this.SouSuo(null, 'init') this.SouSuo(null, 'init')
this.getpositionList() this.getpositionList()
document.addEventListener('visibilitychange',()=>{ document.addEventListener('visibilitychange', () => {
var isHidden = document.hidden; var isHidden = document.hidden
if(isHidden){ if (isHidden) {
document.title = '思坦途' document.title = '思坦途'
} else { } else {
document.title = '思坦途' document.title = '思坦途'
...@@ -1752,7 +1735,7 @@ import {mapState} from 'vuex' ...@@ -1752,7 +1735,7 @@ import {mapState} from 'vuex'
} }
}) })
} }
} }
</script> </script>
<style scoped lang='less'> <style scoped lang='less'>
.allResume{ .allResume{
......
...@@ -403,304 +403,303 @@ ...@@ -403,304 +403,303 @@
</template> </template>
<script> <script>
import moment from 'moment' import moment from 'moment'
import {adoptOneSeeResumeList, serchList,downloadone,sousuoList,getlist,seedetail,PASS,OPTION,deleteREsume,downloadOne,exportLIST,recodeLIST,addinterview,TODORes,getEmailMoo,getEmailContent, sendEmail,findCompanyEmailByKey,forwardResume } from '../../api/resume.server.js' import { adoptOneSeeResumeList, serchList, downloadone, sousuoList, getlist, seedetail, PASS, OPTION, deleteREsume, downloadOne, exportLIST, recodeLIST, addinterview, TODORes, getEmailMoo, getEmailContent, sendEmail, findCompanyEmailByKey, forwardResume } from '../../api/resume.server.js'
import {Serchinterviewor} from '../../api/interview.server.js' import { Serchinterviewor } from '../../api/interview.server.js'
import { import {
sapi sapi
} from '../../config' } from '../../config'
import{_debounce,_throttle, emailValidata, emailRule, vidte, validator} from '../../service/util.js' import { _debounce, _throttle, emailValidata, emailRule, vidte, validator } from '../../service/util.js'
import ckeditor from '../../components/ckeditor' import ckeditor from '../../components/ckeditor'
import {mapState} from 'vuex' import { mapState } from 'vuex'
import localStorage from '../../service/localstorage.service' import localStorage from '../../service/localstorage.service'
export default { export default {
data(){ data () {
return { return {
modal11: false, modal11: false,
interviewee: [], interviewee: [],
tip: false, tip: false,
tipInfo: '输入多个邮箱地址以英文”;“分隔', tipInfo: '输入多个邮箱地址以英文”;“分隔',
errorInfo: '', errorInfo: '',
position:[], position: [],
isShowRep:false, isShowRep: false,
positionArr:[ positionArr: [
], ],
ruleInline: { ruleInline: {
UpdateOWER: [ UpdateOWER: [
{ required: true, message: '邀约人不能为空', trigger: 'blur', validator: emailValidata.bind(this)} { required: true, message: '邀约人不能为空', trigger: 'blur', validator: emailValidata.bind(this) }
], ],
UpdateTIME: [ UpdateTIME: [
{ required: true, message: '面试时间不能为空', trigger: 'change', type:'date', validator: emailValidata.bind(this)} { required: true, message: '面试时间不能为空', trigger: 'change', type: 'date', validator: emailValidata.bind(this) }
], ],
UpdateVIEW: [ UpdateVIEW: [
{ required: true,message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this)} { required: true, message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this) }
] ]
}, },
emailruleInline: { emailruleInline: {
receiveEmail: [{required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this)}], receiveEmail: [{ required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this) }],
theme: [{required: true, trigger: 'blur',message: '主题不能为空', validator: emailValidata.bind(this)}], theme: [{ required: true, trigger: 'blur', message: '主题不能为空', validator: emailValidata.bind(this) }],
copyname: [{required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true}] copyname: [{ required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true }]
}, },
formInline:{ formInline: {
UpdateOWER:'', UpdateOWER: '',
UpdateTIME:'', UpdateTIME: '',
UpdateVIEW:'', UpdateVIEW: '',
sendWeixin: true sendWeixin: true
}, },
editorObject: {type: '', value: ''}, editorObject: { type: '', value: '' },
emailInline:{ emailInline: {
moo:'', moo: '',
modalArr:[], modalArr: [],
copyname:'', copyname: '',
receiveEmail:'',//收件人 receiveEmail: '', // 收件人
theme:'',//主题 theme: '', // 主题
Enclosure:[],//附件 Enclosure: [], // 附件
templateContent:'',//模板内容 templateContent: ''// 模板内容
}, },
transpondFrom: { transpondFrom: {
interviewerName: '' interviewerName: ''
}, },
transpondRule: { transpondRule: {
interviewerName: [{required: true, trigger: 'blur', validator: validator.bind(this)}] interviewerName: [{ required: true, trigger: 'blur', validator: validator.bind(this) }]
}, },
interviewerList: [{name: 'test', value: '1'}], interviewerList: [{ name: 'test', value: '1' }],
loading1: false, loading1: false,
options: [], options: [],
limentName:0, limentName: 0,
emailMassage:false, emailMassage: false,
allEmailVilitor:false, allEmailVilitor: false,
emailContent:'', emailContent: '',
emailFlowStatus:'', emailFlowStatus: '',
fileList:[], fileList: [],
UpdateTIMETwo:'', UpdateTIMETwo: '',
uploadFileList:[], uploadFileList: [],
detailID:'', detailID: '',
temp:'', temp: '',
uploadurl:`${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`, uploadurl: `${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`,
isShowAll:false, isShowAll: false,
isShowTwo:false, isShowTwo: false,
isLimitSize:false, isLimitSize: false,
isDisable:true, isDisable: true,
disabledSingle:true, disabledSingle: true,
emailId:'', emailId: '',
RescopyArr:[], RescopyArr: [],
errorMassage:'', errorMassage: '',
interelement:'1', interelement: '1',
emailIdArr:[], emailIdArr: [],
attachFileList:[], attachFileList: [],
flowStatusTT:'', flowStatusTT: '',
sad:'', sad: '',
interviewIsShow:false, interviewIsShow: false,
emailMOdal:false, emailMOdal: false,
a:[], a: [],
checked: false, checked: false,
activeClass: 0, activeClass: 0,
clickIndex1: 0, clickIndex1: 0,
clickIndex2: 0, clickIndex2: 0,
clickIndex3:0, clickIndex3: 0,
pageT:'', pageT: '',
spinShow:true, spinShow: true,
keywords:'', keywords: '',
biaoshi:'', biaoshi: '',
toseeid:'', toseeid: '',
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() <Date.now()-3600*24*1000; return date && date.valueOf() < Date.now() - 3600 * 24 * 1000
} }
}, },
Black:false, Black: false,
recordList:[], recordList: [],
all:'all', all: 'all',
lrgs:'', lrgs: '',
a:'', a: '',
id:'', id: '',
pageT:'', pageT: '',
resumeDetailSta:'', resumeDetailSta: '',
modal1:false, modal1: false,
modal2:false, modal2: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
modal5:false, modal5: false,
modal7:false, modal7: false,
modal8: false, modal8: false,
modal10:false, modal10: false,
modal12:false, modal12: false,
modal13:false, modal13: false,
modal14:false, modal14: false,
modal15:false, modal15: false,
modal16:false, modal16: false,
modal17:false, modal17: false,
errorNotice:'', errorNotice: '',
resumePushId:'', resumePushId: '',
reResumeName:'', reResumeName: '',
optcode:'', optcode: '',
toseename:'', toseename: '',
// UpdateOWER:'', // UpdateOWER:'',
// UpdateTIME:'', // UpdateTIME:'',
// UpdateVIEW:'', // UpdateVIEW:'',
item:[], item: [],
delateARRALL:[], delateARRALL: [],
delateARRALL2:[], delateARRALL2: [],
flowStatusarr:[], flowStatusarr: [],
quanxuan:[], quanxuan: [],
orignarr:['TO_SEE','HAS_SEE','SEE_FAIL','INTERVIEW_FAIL','TO_SENT_OFFER','TO_ENTRY','HAS_ENTRY','NO_ENTRY','END','ARRIVED'], orignarr: ['TO_SEE', 'HAS_SEE', 'SEE_FAIL', 'INTERVIEW_FAIL', 'TO_SENT_OFFER', 'TO_ENTRY', 'HAS_ENTRY', 'NO_ENTRY', 'END', 'ARRIVED'],
totalSize:0, totalSize: 0,
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
id:'', id: '',
SEX:'', SEX: '',
Edu:'', Edu: '',
ccc:'', ccc: '',
itemSelect:'', itemSelect: '',
STA:[], STA: [],
status:"", status: '',
ownerWorkYears1:'', ownerWorkYears1: '',
ownerWorkYears2:'', ownerWorkYears2: ''
}, },
arr:[], arr: [],
sexs:[{Num1:'',status1:'不限'},{Num1:'0',status1:""},{Num1:'0',status1:''}], sexs: [{ Num1: '', status1: '不限' }, { Num1: '0', status1: '' }, { Num1: '0', status1: '' }],
Education:[{Num2:'',status2:'不限'},{Num2:"0",status2:'专科以下'},{Num2:'1',status2:'专科及以上'},{Num2:'2',status2:'本科及以上'},{Num2:'3',status2:'硕士及以上'},{Num2:'4',status2:'博士及以上'},{Num2:'99',status2:'985/211'}], Education: [{ Num2: '', status2: '不限' }, { Num2: '0', status2: '专科以下' }, { Num2: '1', status2: '专科及以上' }, { Num2: '2', status2: '本科及以上' }, { Num2: '3', status2: '硕士及以上' }, { Num2: '4', status2: '博士及以上' }, { Num2: '99', status2: '985/211' }],
state:[{Num3:[],status3:'不限',sta:true},{Num3:'TO_DO',status3:'待处理',sta:false},{Num3:'OPTION',status3:'备选',sta:false},{Num3:'PASS',status3:'Pass',sta:false},{Num3:'HAS_SEE',status3:'已邀约',sta:false},{Num3:'SEE_FAIL',status3:'邀约失败',sta:false}, state: [{ Num3: [], status3: '不限', sta: true }, { Num3: 'TO_DO', status3: '待处理', sta: false }, { Num3: 'OPTION', status3: '备选', sta: false }, { Num3: 'PASS', status3: 'Pass', sta: false }, { Num3: 'HAS_SEE', status3: '已邀约', sta: false }, { Num3: 'SEE_FAIL', status3: '邀约失败', sta: false },
{Num3:'INTERVIEW_FAIL',status3:'面试淘汰',sta:false},{Num3:'TO_SENT_OFFER',status3:'待Offer',sta:false},{Num3:'HAS_SENT_OFFER',status3:'已发offer',sta:false},{Num3:'HAS_ENTRY',status3:'已入职',sta:false},{Num3:'NO_ENTRY',status3:'未入职',sta:false},{Num3:'END',status3:'终止面试',sta:false},], { Num3: 'INTERVIEW_FAIL', status3: '面试淘汰', sta: false }, { Num3: 'TO_SENT_OFFER', status3: '待Offer', sta: false }, { Num3: 'HAS_SENT_OFFER', status3: '已发offer', sta: false }, { Num3: 'HAS_ENTRY', status3: '已入职', sta: false }, { Num3: 'NO_ENTRY', status3: '未入职', sta: false }, { Num3: 'END', status3: '终止面试', sta: false }],
active:'', active: '',
ownerWorkYears1:[{value:'',label:'不限'},{value:0,label:'0'},{value:1,label:'1'},{value:2,label:'2'},{value:3,label:'3'},{value:4,label:'4'},{value:5,label:'5'}, ownerWorkYears1: [{ value: '', label: '不限' }, { value: 0, label: '0' }, { value: 1, label: '1' }, { value: 2, label: '2' }, { value: 3, label: '3' }, { value: 4, label: '4' }, { value: 5, label: '5' },
{value:6,label:'6'},{value:7,label:'7'},{value:8,label:'8'},{value:9,label:'9'},{value:10,label:'10'}], { value: 6, label: '6' }, { value: 7, label: '7' }, { value: 8, label: '8' }, { value: 9, label: '9' }, { value: 10, label: '10' }],
ownerWorkYears2:[{value:'',label:'不限'},{value:0,label:'0'},{value:1,label:'1'},{value:2,label:'2'},{value:3,label:'3'},{value:4,label:'4'},{value:5,label:'5'}, ownerWorkYears2: [{ value: '', label: '不限' }, { value: 0, label: '0' }, { value: 1, label: '1' }, { value: 2, label: '2' }, { value: 3, label: '3' }, { value: 4, label: '4' }, { value: 5, label: '5' },
{value:6,label:'6'},{value:7,label:'7'},{value:8,label:'8'},{value:9,label:'9'},{value:10,label:'10'}], { value: 6, label: '6' }, { value: 7, label: '7' }, { value: 8, label: '8' }, { value: 9, label: '9' }, { value: 10, label: '10' }],
value:[], value: [],
ajaxData: [], ajaxData: [],
checkData: [], checkData: [],
checkboxList:[], checkboxList: [],
delateARRALL3: [] delateARRALL3: []
} }
}, },
computed:{ computed: {
}, },
components:{ components: {
ckeditor ckeditor
}, },
methods:{ methods: {
// 判断输入年限的大小 // 判断输入年限的大小
judge1(value){ judge1 (value) {
this.searchInfo.ownerWorkYears1=value.value this.searchInfo.ownerWorkYears1 = value.value
}, },
judge2(value){ judge2 (value) {
this.searchInfo.ownerWorkYears2=value.value this.searchInfo.ownerWorkYears2 = value.value
if(this.searchInfo.ownerWorkYears1>this.searchInfo.ownerWorkYears2){ if (this.searchInfo.ownerWorkYears1 > this.searchInfo.ownerWorkYears2) {
this.Black=true this.Black = true
setInterval(() => { setInterval(() => {
this.Black=false this.Black = false
}, 3000) }, 3000)
} }
}, },
//全选与反选 // 全选与反选
checkedAll: function() { checkedAll: function () {
if (this.checked) {//实现反选 if (this.checked) { // 实现反选
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.removeInterviewee(item) this.removeInterviewee(item)
this.checkboxList = []; this.checkboxList = []
this.delateARRALL=[]; this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
item.STATES=false item.STATES = false
}); })
} else { // 实现全选
} else { //实现全选 if (this.ajaxData.length == 0) {
if(this.ajaxData.length==0){ this.checkboxList = []
this.checkboxList=[]
} }
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.addInterviewee(item) this.addInterviewee(item)
this.checkboxList.push(item.id); this.checkboxList.push(item.id)
this.delateARRALL.push(item.id); this.delateARRALL.push(item.id)
this.flowStatusarr.push(item.flowStatus) this.flowStatusarr.push(item.flowStatus)
item.STATES=true item.STATES = true
}); })
} }
}, },
//操作处理面试状态 // 操作处理面试状态
changeFlowstatus(e,SID,itemsta,orsta){ changeFlowstatus (e, SID, itemsta, orsta) {
this.toseeid=SID this.toseeid = SID
this.emailId=SID this.emailId = SID
this.emailIdArr=[] this.emailIdArr = []
this.emailIdArr.push(SID) this.emailIdArr.push(SID)
this.isShowTwo=true this.isShowTwo = true
this.ITEMSTA=itemsta this.ITEMSTA = itemsta
if(e.target.value=='TO_SEE'){ if (e.target.value == 'TO_SEE') {
this.emailFlowStatus='TO_SEE' this.emailFlowStatus = 'TO_SEE'
this.isShowTwo=true this.isShowTwo = true
this.sendEmail('',orsta,SID) this.sendEmail('', orsta, SID)
} }
if(e.target.value=='PASS'){ if (e.target.value == 'PASS') {
let parmars={ const parmars = {
status:"PASS", status: 'PASS',
id:SID, id: SID
} }
PASS(parmars).then(res=>{ PASS(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
if(e.target.value=='OPTION'){ if (e.target.value == 'OPTION') {
let parmars={ const parmars = {
status:"OPTION", status: 'OPTION',
id:SID, id: SID
} }
OPTION(parmars).then(res=>{ OPTION(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
if(e.target.value=='TO_DO'){ if (e.target.value == 'TO_DO') {
let parmars={ const parmars = {
status:"TO_DO", status: 'TO_DO',
id:SID, id: SID
} }
TODORes(parmars).then(res=>{ TODORes(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
} }
}, },
addINTERVIEW(){ addINTERVIEW () {
let parmars={ const parmars = {
resumeId: this.toseeid, resumeId: this.toseeid,
inviterName:this.formInline.UpdateOWER, inviterName: this.formInline.UpdateOWER,
interviewerName:this.formInline.UpdateVIEW, interviewerName: this.formInline.UpdateVIEW,
seeTime:moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm'), seeTime: moment(this.formInline.UpdateTIME).format('YYYY-MM-DD HH:mm')
} }
if(this.formInline.UpdateOWER==''||this.formInline.UpdateVIEW==''||this.formInline.UpdateTIME==''){ if (this.formInline.UpdateOWER == '' || this.formInline.UpdateVIEW == '' || this.formInline.UpdateTIME == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写完整的约面信息' desc: '请您填写完整的约面信息'
}); })
return return
} }
addinterview(parmars).then(res=>{ addinterview(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal2=false this.modal2 = false
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.body.code==0){ if (res.data.body.code == 0) {
this.SouSuo(this.pageT,'init') this.SouSuo(this.pageT, 'init')
} }
}) })
}, },
changeTime(b){ changeTime (b) {
this.UpdateTIME=b this.UpdateTIME = b
if (!b){ if (!b) {
this.editorObject = { this.editorObject = {
type: this.temp, type: this.temp,
value: this.emailInline.templateContent value: this.emailInline.templateContent
...@@ -720,102 +719,102 @@ export default { ...@@ -720,102 +719,102 @@ export default {
} }
}, },
// 查看简历详情 // 查看简历详情
Seedetail(Tid,Uid,STATUS){ Seedetail (Tid, Uid, STATUS) {
this.detailID=Tid this.detailID = Tid
this.DOWNID=Uid this.DOWNID = Uid
this.resumeDetailSta=STATUS this.resumeDetailSta = STATUS
let newpage = this.$router.resolve({ const newpage = this.$router.resolve({
name: 'resumeDetail', name: 'resumeDetail',
params:{}, params: {},
query:{id:this.DOWNID,noShowBtn:'',ID:this.detailID,status:this.resumeDetailSta} query: { id: this.DOWNID, noShowBtn: '', ID: this.detailID, status: this.resumeDetailSta }
}) })
window.open(newpage.href, '_blank'); window.open(newpage.href, '_blank')
}, },
pageChange(page){ pageChange (page) {
this.pageT=page this.pageT = page
this.delateARRALL=[] this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
this.searchInfo.ownerWorkYears1='' this.searchInfo.ownerWorkYears1 = ''
this.searchInfo.ownerWorkYears2='' this.searchInfo.ownerWorkYears2 = ''
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.SouSuo() this.SouSuo()
}, },
// 跳转到面试管理 // 跳转到面试管理
tointerview(){ tointerview () {
this.$router.push('/interview') this.$router.push('/interview')
}, },
downloadAll(){ downloadAll () {
if(this.checkboxList==''){ if (this.checkboxList == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空' desc: '选项不能为空'
}); })
return return
} }
let url=`${sapi}/api/resume/download/formatted/compress` let url = `${sapi}/api/resume/download/formatted/compress`
this.checkboxList.map((item,index)=>{ this.checkboxList.map((item, index) => {
url+=index==0?`?resumeId=${item}`:`&resumeId=${item}` url += index == 0 ? `?resumeId=${item}` : `&resumeId=${item}`
}) })
window.location.href=url window.location.href = url
this.checkboxList=[] this.checkboxList = []
}, },
// 可删除状态下点击 // 可删除状态下点击
delateR(delateid){ delateR (delateid) {
this.delateARRALL3 = [] this.delateARRALL3 = []
this.delateARRALL3.push(delateid) this.delateARRALL3.push(delateid)
this.modal3=true this.modal3 = true
}, },
// 删除单条简历 // 删除单条简历
delateONE(){ delateONE () {
deleteREsume(this.delateARRALL3).then(res=>{ deleteREsume(this.delateARRALL3).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.delateARRALL3.map(item => { this.delateARRALL3.map(item => {
this.removeInterviewee({id:item}) this.removeInterviewee({ id: item })
}) })
this.modal3=false this.modal3 = false
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
}) })
}, },
getpositionList(){ getpositionList () {
let parmars={ const parmars = {
optSourceCode:this.$route.params.channelname optSourceCode: this.$route.params.channelname
} }
getlist(parmars).then(res=>{ getlist(parmars).then(res => {
this.positionArr=[] this.positionArr = []
this.positionArr=res.data.body this.positionArr = res.data.body
}) })
}, },
// 选择input元素 // 选择input元素
selectInputElement(index,doID,doStatus,sss, item){ selectInputElement (index, doID, doStatus, sss, item) {
sss=!sss sss = !sss
this.emailIdArr=[] this.emailIdArr = []
this.emailId=doID this.emailId = doID
this.ajaxData[index].STATES=sss this.ajaxData[index].STATES = sss
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
if(sss==true){ if (sss == true) {
this.delateARRALL.push(doID) this.delateARRALL.push(doID)
this.delateARRALL2.push(doID) this.delateARRALL2.push(doID)
this.flowStatusarr.push(doStatus) this.flowStatusarr.push(doStatus)
this.addInterviewee(item) this.addInterviewee(item)
this.emailIdArr.push(doID) this.emailIdArr.push(doID)
} }
if(sss==false){ if (sss == false) {
this.delateARRALL.remove(doID) this.delateARRALL.remove(doID)
this.delateARRALL2.remove(doID) this.delateARRALL2.remove(doID)
this.flowStatusarr.remove(doStatus) this.flowStatusarr.remove(doStatus)
...@@ -823,200 +822,199 @@ export default { ...@@ -823,200 +822,199 @@ export default {
this.emailIdArr.remove(doID) this.emailIdArr.remove(doID)
} }
}, },
//选择搜索元素 // 选择搜索元素
selectElement1(tItem,Tindex){ selectElement1 (tItem, Tindex) {
this.searchInfo.SEX=Tindex==0?'':tItem; this.searchInfo.SEX = Tindex == 0 ? '' : tItem
this.clickIndex1=Tindex this.clickIndex1 = Tindex
}, },
selectElement2(tItem,Tindex){ selectElement2 (tItem, Tindex) {
this.searchInfo.Edu=tItem; this.searchInfo.Edu = tItem
this.clickIndex2=Tindex this.clickIndex2 = Tindex
}, },
selectElement3(tItem,Tindex,status3,sta3){ selectElement3 (tItem, Tindex, status3, sta3) {
sta3=!sta3 sta3 = !sta3
this.state[Tindex].sta=sta3 this.state[Tindex].sta = sta3
if(Tindex==0){ if (Tindex == 0) {
this.searchInfo.STA=[] this.searchInfo.STA = []
this.state.map((item,index)=>{ this.state.map((item, index) => {
if(index!==0){ if (index !== 0) {
item.sta=false item.sta = false
} }
if(index==0){ if (index == 0) {
item.sta=true item.sta = true
} }
return item return item
}) })
return return
} }
if(Tindex!==0){ if (Tindex !== 0) {
this.state[0].sta=false this.state[0].sta = false
} }
if(sta3==true){ if (sta3 == true) {
this.searchInfo.STA.push(tItem) this.searchInfo.STA.push(tItem)
} }
if(sta3==false){ if (sta3 == false) {
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
this.searchInfo.STA.remove(tItem) this.searchInfo.STA.remove(tItem)
} }
}, },
// 不可删除状态下点击 // 不可删除状态下点击
undelate(){ undelate () {
this.modal4=true this.modal4 = true
}, },
// 批量删除 // 批量删除
delateAll(){ delateAll () {
var array1 = this.orignarr;//数组1 var array1 = this.orignarr// 数组1
var array2 = this.flowStatusarr;//数组2 var array2 = this.flowStatusarr// 数组2
var tempArray1 = [];//临时数组1 var tempArray1 = []// 临时数组1
var tempArray2 = [];//临时数组2 var tempArray2 = []// 临时数组2
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
for(var i=0;i<array2.length;i++){ for (var i = 0; i < array2.length; i++) {
tempArray1[array2[i]]=true;//将数array2 中的元素值作为tempArray1 中的键,值为true; tempArray1[array2[i]] = true// 将数array2 中的元素值作为tempArray1 中的键,值为true;
} }
for(var i=0;i<array1.length;i++){ for (var i = 0; i < array1.length; i++) {
if(tempArray1[array1[i]]){ if (tempArray1[array1[i]]) {
tempArray2.push(array1[i]);//过滤array1 中与array2 相同的元素; tempArray2.push(array1[i])// 过滤array1 中与array2 相同的元素;
} }
} }
if(tempArray2.length!==0){ if (tempArray2.length !== 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '您选中的简历中包含不可删除简历' desc: '您选中的简历中包含不可删除简历'
}); })
return return
} }
if(this.delateARRALL.length==0){ if (this.delateARRALL.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空' desc: '选项不能为空'
}); })
return return
} }
if(tempArray2.length==0){ if (tempArray2.length == 0) {
this.modal7=true this.modal7 = true
} }
}, },
//确认批量删除 // 确认批量删除
cofdelateAll(){ cofdelateAll () {
var array1 = this.orignarr;//数组1 var array1 = this.orignarr// 数组1
var array2 = this.flowStatusarr;//数组2 var array2 = this.flowStatusarr// 数组2
var tempArray1 = [];//临时数组1 var tempArray1 = []// 临时数组1
var tempArray2 = [];//临时数组2 var tempArray2 = []// 临时数组2
for(var i=0;i<array2.length;i++){ for (var i = 0; i < array2.length; i++) {
tempArray1[array2[i]]=true;//将数array2 中的元素值作为tempArray1 中的键,值为true; tempArray1[array2[i]] = true// 将数array2 中的元素值作为tempArray1 中的键,值为true;
} }
for(var i=0;i<array1.length;i++){ for (var i = 0; i < array1.length; i++) {
if(tempArray1[array1[i]]){ if (tempArray1[array1[i]]) {
tempArray2.push(array1[i]);//过滤array1 中与array2 相同的元素; tempArray2.push(array1[i])// 过滤array1 中与array2 相同的元素;
} }
} }
if(tempArray2.length!==0){ if (tempArray2.length !== 0) {
this.modal5=true this.modal5 = true
} }
Array.prototype.indexOf = function(val) { Array.prototype.indexOf = function (val) {
for (var i = 0; i < this.length; i++) { for (var i = 0; i < this.length; i++) {
if (this[i] == val) return i; if (this[i] == val) return i
} }
return -1; return -1
} }
Array.prototype.remove = function(val) { Array.prototype.remove = function (val) {
var index = this.indexOf(val); var index = this.indexOf(val)
if (index > -1) { if (index > -1) {
this.splice(index, 1); this.splice(index, 1)
} }
} }
this.DELATEARR=this.delateARRALL this.DELATEARR = this.delateARRALL
deleteREsume(this.DELATEARR).then(res=>{ deleteREsume(this.DELATEARR).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal7=false this.modal7 = false
this.delateARRALL.map(item => { this.delateARRALL.map(item => {
this.removeInterviewee({id:item}) this.removeInterviewee({ id: item })
}) })
this.delateARRALL=[] this.delateARRALL = []
this.flowStatusarr=[] this.flowStatusarr = []
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
}) })
}, },
// 刷新列表 // 刷新列表
pushlist(){ pushlist () {
this.modal2=false this.modal2 = false
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
}, },
// 批量导出 // 批量导出
allexport(){ allexport () {
this.optcode=this.$route.params.channelname this.optcode = this.$route.params.channelname
let parmars={ const parmars = {
optSourceCode:this.optcode, optSourceCode: this.optcode,
keywordString:this.keywords==''?'':this.keywords, keywordString: this.keywords == '' ? '' : this.keywords,
company:this.lrgs==''?'':this.lrgs, company: this.lrgs == '' ? '' : this.lrgs,
ownerSex:this.searchInfo.SEX, ownerSex: this.searchInfo.SEX,
highestDegreeNum:this.searchInfo.Edu, highestDegreeNum: this.searchInfo.Edu,
flowStatusList:this.clickIndex3=0?this.searchInfo.STA=[]:this.searchInfo.STA, flowStatusList: this.clickIndex3 = 0 ? this.searchInfo.STA = [] : this.searchInfo.STA,
ownerWorkYears1:this.searchInfo.ownerWorkYears1, ownerWorkYears1: this.searchInfo.ownerWorkYears1,
ownerWorkYears2:this.searchInfo.ownerWorkYears2, ownerWorkYears2: this.searchInfo.ownerWorkYears2
} }
if(this.searchInfo.ownerWorkYears1>this.searchInfo.ownerWorkYears2){ if (this.searchInfo.ownerWorkYears1 > this.searchInfo.ownerWorkYears2) {
this.$Message.error('最低年限不能大于最高年限') this.$Message.error('最低年限不能大于最高年限')
return return
} }
if(this.searchInfo.ownerWorkYears2<this.searchInfo.ownerWorkYears1){ if (this.searchInfo.ownerWorkYears2 < this.searchInfo.ownerWorkYears1) {
this.$Message.error('最高年限不能小于最小年限') this.$Message.error('最高年限不能小于最小年限')
return return
} }
window.location.href=`${sapi}/api/excel/output?optSourceCode=${parmars.optSourceCode}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}` window.location.href = `${sapi}/api/excel/output?optSourceCode=${parmars.optSourceCode}&keywordString=${parmars.keywordString}&company=${parmars.company}&ownerSex=${parmars.ownerSex}&highestDegreeNum=${parmars.highestDegreeNum}&flowStatusList=${parmars.flowStatusList}&ownerWorkYears1=${parmars.ownerWorkYears1}&ownerWorkYears2=${parmars.ownerWorkYears2}`
}, },
//下载单条简历 // 下载单条简历
downloadONE(downID){ downloadONE (downID) {
window.location.href=`${sapi}/api/resume/download/formatted/one?resumeId=${downID}` window.location.href = `${sapi}/api/resume/download/formatted/one?resumeId=${downID}`
}, },
// 操作记录查询 // 操作记录查询
RecordSEE(RID,sname){ RecordSEE (RID, sname) {
this.toseename=sname this.toseename = sname
this.modal1=true this.modal1 = true
let parmars={ const parmars = {
resumeId:RID resumeId: RID
} }
recodeLIST(parmars).then(res=>{ recodeLIST(parmars).then(res => {
this.ownerName=res.data.body.ownerName this.ownerName = res.data.body.ownerName
this.recordList=res.data.body.map((item,index)=>{ this.recordList = res.data.body.map((item, index) => {
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.approveUserName=item.approveUserName item.approveUserName = item.approveUserName
item.dateTime=item.dateTime item.dateTime = item.dateTime
item.previousState=item.previousState item.previousState = item.previousState
item.afterState=item.afterState item.afterState = item.afterState
return item return item
}) })
}) })
}, },
delInterviewee (item) { delInterviewee (item) {
this.removeInterviewee(item) this.removeInterviewee(item)
let indexOf = this.checkboxList.indexOf(item.id) const indexOf = this.checkboxList.indexOf(item.id)
if (indexOf < 0) return if (indexOf < 0) return
this.checkboxList.splice(indexOf, 1) this.checkboxList.splice(indexOf, 1)
this.delateARRALL.splice(indexOf, 1) this.delateARRALL.splice(indexOf, 1)
...@@ -1030,71 +1028,71 @@ export default { ...@@ -1030,71 +1028,71 @@ export default {
} }
}) })
}, },
//搜索 // 搜索
SouSuo(page, status){ SouSuo (page, status) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
this.interviewee = [] this.interviewee = []
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter:{ parameter: {
optSourceCode:this.$route.params.channelname, optSourceCode: this.$route.params.channelname,
keywordString:this.keywords==''?'':this.keywords, keywordString: this.keywords == '' ? '' : this.keywords,
company:this.lrgs==''?'':this.lrgs, company: this.lrgs == '' ? '' : this.lrgs,
ownerSex:this.searchInfo.SEX, ownerSex: this.searchInfo.SEX,
highestDegreeNum:this.searchInfo.Edu, highestDegreeNum: this.searchInfo.Edu,
flowStatusList:this.clickIndex3=0?this.searchInfo.STA=[]:this.searchInfo.STA, flowStatusList: this.clickIndex3 = 0 ? this.searchInfo.STA = [] : this.searchInfo.STA,
ownerWorkYears1:this.searchInfo.ownerWorkYears1, ownerWorkYears1: this.searchInfo.ownerWorkYears1,
ownerWorkYears2:this.searchInfo.ownerWorkYears2, ownerWorkYears2: this.searchInfo.ownerWorkYears2,
ownerExpectTitlesList:this.position, ownerExpectTitlesList: this.position,
handUpload:this.$route.query.handUpload==null?'':this.$route.query.handUpload handUpload: this.$route.query.handUpload == null ? '' : this.$route.query.handUpload
} }
} }
this.ajaxData=[] this.ajaxData = []
if(this.searchInfo.ownerWorkYears1>this.searchInfo.ownerWorkYears2){ if (this.searchInfo.ownerWorkYears1 > this.searchInfo.ownerWorkYears2) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '最高年限不能小于最低年限' desc: '最高年限不能小于最低年限'
}); })
return return
} }
sousuoList(parmars, status).then(res=>{ sousuoList(parmars, status).then(res => {
let Ishow=res.data.items const Ishow = res.data.items
if(res.data.success==true){ if (res.data.success == true) {
this.checkboxList=[] this.checkboxList = []
if(res.data.body.totalNumber==0){ if (res.data.body.totalNumber == 0) {
this.totalSize=0 this.totalSize = 0
} }
this.spinShow=false this.spinShow = false
this.ajaxData=res.data.body.items.map((item,index)=>{ this.ajaxData = res.data.body.items.map((item, index) => {
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
item.id=item.id item.id = item.id
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.ownerSex=item.ownerSex item.ownerSex = item.ownerSex
item.belongs=item.belongs item.belongs = item.belongs
item.emailSendtime=item.emailSendtime item.emailSendtime = item.emailSendtime
item.ownerMobile=item.ownerMobile item.ownerMobile = item.ownerMobile
item.ownerHighestDegree=item.ownerHighestDegree item.ownerHighestDegree = item.ownerHighestDegree
item.ownerExpectTitles=item.ownerExpectTitles item.ownerExpectTitles = item.ownerExpectTitles
item.flowStatus=item.flowStatus item.flowStatus = item.flowStatus
item.ownerAge=item.ownerAge item.ownerAge = item.ownerAge
item.ownerWorkYears=item.ownerWorkYears item.ownerWorkYears = item.ownerWorkYears
item.modifyTime=item.modifyTime item.modifyTime = item.modifyTime
item.srcSite=item.srcSite item.srcSite = item.srcSite
item.STATES=false item.STATES = false
item.isShow=false item.isShow = false
item.optSource=item.optSource item.optSource = item.optSource
item.modifier=item.modifier item.modifier = item.modifier
item.originValue=item.flowStatus item.originValue = item.flowStatus
item.uid=item.uid item.uid = item.uid
item.hasRead=item.hasRead item.hasRead = item.hasRead
item.c=item.modifier==''?item.modifier:item.modifier.split('_') item.c = item.modifier == '' ? item.modifier : item.modifier.split('_')
item.d=item.c[0] item.d = item.c[0]
if (item.STATES) { //以选中 if (item.STATES) { // 以选中
this.checkboxList.push(item.id) this.checkboxList.push(item.id)
this.delateARRALL.push(item.id); this.delateARRALL.push(item.id)
this.flowStatusarr.push(item.flowStatus) this.flowStatusarr.push(item.flowStatus)
} }
return item return item
...@@ -1103,449 +1101,442 @@ export default { ...@@ -1103,449 +1101,442 @@ export default {
}) })
}, },
// 刷新列表 // 刷新列表
pushlist(){ pushlist () {
this.modal2=false this.modal2 = false
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
}, },
// 鼠标滑过事件 // 鼠标滑过事件
ahove(index,vvv){ ahove (index, vvv) {
this.ajaxData[index].isShow=true this.ajaxData[index].isShow = true
}, },
movleave(index,vvv){ movleave (index, vvv) {
this.ajaxData[index].isShow=false this.ajaxData[index].isShow = false
}, },
// 发送邮件 // 发送邮件
sendEmail(type,status,SID){ sendEmail (type, status, SID) {
this.selectElementValue=status this.selectElementValue = status
this.resumePushId=SID this.resumePushId = SID
if(this.checkboxList.length == 0&&type) { if (this.checkboxList.length == 0 && type) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '你尚未选择简历,请先选择简历' desc: '你尚未选择简历,请先选择简历'
}) })
return return
} }
if (this.checkboxList.length > 1&&type){ if (this.checkboxList.length > 1 && type) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '不能选择多份简历,请选择单份简历' desc: '不能选择多份简历,请选择单份简历'
}) })
return return
} }
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.$refs.emailInline.resetFields() this.$refs.emailInline.resetFields()
this.$refs.formInline.resetFields() this.$refs.formInline.resetFields()
this.options=[] this.options = []
this.emailMOdal=true this.emailMOdal = true
getEmailMoo().then(res=>{ getEmailMoo().then(res => {
this.emailInline.modalArr=res.data.body this.emailInline.modalArr = res.data.body
}) })
this.emailInline.moo = 'TEMP_0001' this.emailInline.moo = 'TEMP_0001'
this.getEmailContentValue(this.emailInline.moo) this.getEmailContentValue(this.emailInline.moo)
}, },
getEmailContentValue(value){ getEmailContentValue (value) {
if (!value){ if (!value) {
return return
} }
this.isDisable=true this.isDisable = true
this.temp=value this.temp = value
if(this.isShowTwo==true){ if (this.isShowTwo == true) {
this.isShowAll=true this.isShowAll = true
this.interviewIsShow=true this.interviewIsShow = true
}else{ } else {
if(this.emailIdArr.length>1&&(value=='TEMP_0001'||value=='TEMP_0005'||value=='TEMP_0006')){ if (this.emailIdArr.length > 1 && (value == 'TEMP_0001' || value == 'TEMP_0005' || value == 'TEMP_0006')) {
this.allEmailVilitor=true this.allEmailVilitor = true
}else { } else {
this.allEmailVilitor=false this.allEmailVilitor = false
if(this.temp=='TEMP_0001'){ if (this.temp == 'TEMP_0001') {
this.isShowAll=true this.isShowAll = true
}else{ } else {
this.isShowAll=false this.isShowAll = false
} }
} }
if(value=='TEMP_0001'){ if (value == 'TEMP_0001') {
this.interviewIsShow=true this.interviewIsShow = true
this.isShowAll=true this.isShowAll = true
}else{ } else {
this.interviewIsShow=false this.interviewIsShow = false
this.isShowAll=false this.isShowAll = false
} }
this.emailId=this.emailIdArr.length==0?'':this.emailIdArr[0] this.emailId = this.emailIdArr.length == 0 ? '' : this.emailIdArr[0]
if(value=='TEMP_0001' &&this.emailId==''){ if (value == 'TEMP_0001' && this.emailId == '') {
this.interviewBtu=true this.interviewBtu = true
this.isShowAll=true this.isShowAll = true
this.emailMassage=true this.emailMassage = true
} } else if (value == 'TEMP_0005' && this.emailId == '') {
else if(value=='TEMP_0005' && this.emailId==''){ this.emailMassage = true
this.emailMassage=true } else if (value == 'TEMP_0006' && this.emailId == '') {
} this.emailMassage = true
else if(value=='TEMP_0006' && this.emailId==''){ } else {
this.emailMassage=true if (value == 'TEMP_0001') { this.isShowAll = true } else { this.isShowAll = false }
} this.interviewBtu = false
else{
if(value=='TEMP_0001'){this.isShowAll=true}else{this.isShowAll=false}
this.interviewBtu=false
this.emailMassage=false this.emailMassage = false
}} }
this.emailCode=value }
let parmars={ this.emailCode = value
resumeId:this.emailId==''?'':this.emailId, const parmars = {
templateCode:this.emailCode resumeId: this.emailId == '' ? '' : this.emailId,
} templateCode: this.emailCode
getEmailContent(parmars).then(res=>{ }
this.emailInline.theme=res.data.body.templateSubject getEmailContent(parmars).then(res => {
this.emailInline.receiveEmail=res.data.body.receiveEmail this.emailInline.theme = res.data.body.templateSubject
this.emailInline.templateContent=res.data.body.templateContent this.emailInline.receiveEmail = res.data.body.receiveEmail
this.emailInline.templateContent = res.data.body.templateContent
this.editorObject = { this.editorObject = {
type: value, type: value,
value: this.emailInline.templateContent || '' value: this.emailInline.templateContent || ''
} }
if(res.data.body&&res.data.body.resumeInterviewVO){ if (res.data.body && res.data.body.resumeInterviewVO) {
this.formInline.UpdateOWER=res.data.body.resumeInterviewVO.inviterName this.formInline.UpdateOWER = res.data.body.resumeInterviewVO.inviterName
this.formInline.UpdateVIEW=res.data.body.resumeInterviewVO.interviewerName this.formInline.UpdateVIEW = res.data.body.resumeInterviewVO.interviewerName
this.formInline.UpdateTIME=res.data.body.resumeInterviewVO.seeTime this.formInline.UpdateTIME = res.data.body.resumeInterviewVO.seeTime
this.changeTime(this.formInline.UpdateTIME) this.changeTime(this.formInline.UpdateTIME)
}else{ } else {
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
} }
}) })
}, },
uploadFile(){ uploadFile () {
// this.uploadFileList=[] // this.uploadFileList=[]
this.limentName=0 this.limentName = 0
}, },
beforUpload(uploadFile){ beforUpload (uploadFile) {
let isLiment=false let isLiment = false
if(uploadFile.size/1024 > 10240){ if (uploadFile.size / 1024 > 10240) {
isLiment=true isLiment = true
this.limentName+=1 this.limentName += 1
if(this.limentName==1){ if (this.limentName == 1) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '单个文件不能大于10M' desc: '单个文件不能大于10M'
}) })
} }
}else{ } else {
this.fileList.push(uploadFile.name) this.fileList.push(uploadFile.name)
this.uploadFileList.push(uploadFile) this.uploadFileList.push(uploadFile)
} }
return false return false
}, },
// 发送全部内容 // 发送全部内容
sendContent(){}, sendContent () {},
emailModalPush(){ emailModalPush () {
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.uploadFileList=[] this.uploadFileList = []
// this.SouSuo(this.pageT,'init') // this.SouSuo(this.pageT,'init')
// this.clearInterviewee() // this.clearInterviewee()
this.ajaxData.map(item=>{ this.ajaxData.map(item => {
if(item.id==this.resumePushId){ if (item.id == this.resumePushId) {
item.flowStatus=item.originValue item.flowStatus = item.originValue
} }
}) })
}, },
getEditorValue(){ // 调编辑器组件方法获取数据 getEditorValue () { // 调编辑器组件方法获取数据
return this.$refs.editor.getValue() return this.$refs.editor.getValue()
}, },
delateFile(index){ delateFile (index) {
this.fileList.splice(index,1) this.fileList.splice(index, 1)
this.uploadFileList.splice(index,1) this.uploadFileList.splice(index, 1)
// this.isLimitSize=false // this.isLimitSize=false
}, },
// 确认发送邮件 // 确认发送邮件
confireSendEmail:_debounce(function(){ confireSendEmail: _debounce(function () {
this.sad=this.getEditorValue() this.sad = this.getEditorValue()
if(this.sad==''){ if (this.sad == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if(this.emailInline.moo==''){ if (this.emailInline.moo == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0001')&&(this.emailInline.moo==''||this.emailInline.receiveEmail==''||this.emailInline.theme==''||this.formInline.UpdateOWER==''||this.formInline.UpdateVIEW==''||this.formInline.UpdateTIME=='')){ if ((this.temp == 'TEMP_0001') && (this.emailInline.moo == '' || this.emailInline.receiveEmail == '' || this.emailInline.theme == '' || this.formInline.UpdateOWER == '' || this.formInline.UpdateVIEW == '' || this.formInline.UpdateTIME == '')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0002'||this.temp=='TEMP_0003'||this.temp=='TEMP_0004'||this.temp=='TEMP_0005'||this.temp=='TEMP_0006')&&(this.emailInline.moo==''||this.emailInline.receiveEmail==''||this.emailInline.theme=='')){ if ((this.temp == 'TEMP_0002' || this.temp == 'TEMP_0003' || this.temp == 'TEMP_0004' || this.temp == 'TEMP_0005' || this.temp == 'TEMP_0006') && (this.emailInline.moo == '' || this.emailInline.receiveEmail == '' || this.emailInline.theme == '')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0001'|| this.temp=='TEMP_0005'|| this.temp=='TEMP_0006')&&this.emailId==''){ if ((this.temp == 'TEMP_0001' || this.temp == 'TEMP_0005' || this.temp == 'TEMP_0006') && this.emailId == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请先选择简历' desc: '请先选择简历'
}); })
return return
} }
if(this.emailInline.copyname!==''&&!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))){ if (this.emailInline.copyname !== '' && !(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
if(!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))){ if (!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
if((this.emailIdArr.length>1)&&(this.temp=='TEMP_0001'|| this.temp=='TEMP_0005'|| this.temp=='TEMP_0006')){ if ((this.emailIdArr.length > 1) && (this.temp == 'TEMP_0001' || this.temp == 'TEMP_0005' || this.temp == 'TEMP_0006')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '不能选择多份简历,请选择单份简历' desc: '不能选择多份简历,请选择单份简历'
}); })
return return
} }
this.attachFileList=this.uploadFileList.length==0?'':this.uploadFileList this.attachFileList = this.uploadFileList.length == 0 ? '' : this.uploadFileList
this.flowStatusTT=this.emailFlowStatus==''?'':'TO_SEE' this.flowStatusTT = this.emailFlowStatus == '' ? '' : 'TO_SEE'
this.UpdateTIMETwo=this.formInline.UpdateTIME==''?'':this.formInline.UpdateTIME this.UpdateTIMETwo = this.formInline.UpdateTIME == '' ? '' : this.formInline.UpdateTIME
if(this.temp=='TEMP_0001'){ if (this.temp == 'TEMP_0001') {
var formData= new FormData() var formData = new FormData()
if(this.attachFileList.length!==0){ if (this.attachFileList.length !== 0) {
this.attachFileList.map(item=>{ this.attachFileList.map(item => {
formData.append('attachFileList',item) formData.append('attachFileList', item)
}) })
}else{ } else {
formData.append('attachFileList','') formData.append('attachFileList', '')
} }
formData.append('resumeId',this.emailId) formData.append('resumeId', this.emailId)
formData.append('templateCode',this.emailCode) formData.append('templateCode', this.emailCode)
formData.append('subject',this.emailInline.theme) formData.append('subject', this.emailInline.theme)
formData.append('toEmail',this.emailInline.receiveEmail) formData.append('toEmail', this.emailInline.receiveEmail)
formData.append('ccEmail',this.emailInline.copyname) formData.append('ccEmail', this.emailInline.copyname)
formData.append('emailContent',this.sad) formData.append('emailContent', this.sad)
formData.append('resumeInterviewVO.resumeId',this.emailId) formData.append('resumeInterviewVO.resumeId', this.emailId)
formData.append('resumeInterviewVO.inviterName',this.formInline.UpdateOWER==''?'':this.formInline.UpdateOWER) formData.append('resumeInterviewVO.inviterName', this.formInline.UpdateOWER == '' ? '' : this.formInline.UpdateOWER)
formData.append('resumeInterviewVO.interviewerName',this.formInline.UpdateVIEW==''?'':this.formInline.UpdateVIEW) formData.append('resumeInterviewVO.interviewerName', this.formInline.UpdateVIEW == '' ? '' : this.formInline.UpdateVIEW)
let info = this.options.find(item => item.name == this.formInline.UpdateVIEW) const info = this.options.find(item => item.name == this.formInline.UpdateVIEW)
formData.append('resumeInterviewVO.email',(info&&info.email) || '') formData.append('resumeInterviewVO.email', (info && info.email) || '')
formData.append('sendWeixin',this.formInline.sendWeixin==true? 1:0) formData.append('sendWeixin', this.formInline.sendWeixin == true ? 1 : 0)
formData.append('resumeInterviewVO.seeTime',moment( this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm')) formData.append('resumeInterviewVO.seeTime', moment(this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm'))
formData.append(' flowStatus',this.flowStatusTT) formData.append(' flowStatus', this.flowStatusTT)
sendEmail(formData).then(res=>{ sendEmail(formData).then(res => {
this.isDisable=true this.isDisable = true
if(res.data.success==true){ if (res.data.success == true) {
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '发送邮件成功' desc: '发送邮件成功'
}) })
}, 500) }, 500)
this.emailMOdal=false this.emailMOdal = false
this.modal10=false this.modal10 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal10 = false this.modal10 = false
this.modal11 = true this.modal11 = true
this.errorInfo = res.data.body.message this.errorInfo = res.data.body.message
} }
}) })
}else{ } else {
var formData= new FormData() var formData = new FormData()
if(this.attachFileList.length!==0){ if (this.attachFileList.length !== 0) {
this.attachFileList.map(item=>{ this.attachFileList.map(item => {
formData.append('attachFileList',item) formData.append('attachFileList', item)
}) })
}else{ } else {
formData.append('attachFileList','') formData.append('attachFileList', '')
} }
formData.append('resumeId',this.emailId) formData.append('resumeId', this.emailId)
formData.append('templateCode',this.emailCode) formData.append('templateCode', this.emailCode)
formData.append('subject',this.emailInline.theme) formData.append('subject', this.emailInline.theme)
formData.append('toEmail',this.emailInline.receiveEmail) formData.append('toEmail', this.emailInline.receiveEmail)
formData.append('ccEmail',this.emailInline.copyname) formData.append('ccEmail', this.emailInline.copyname)
formData.append('emailContent',this.sad) formData.append('emailContent', this.sad)
formData.append(' flowStatus',this.flowStatusTT) formData.append(' flowStatus', this.flowStatusTT)
this.isDisable=false this.isDisable = false
sendEmail(formData).then(res=>{ sendEmail(formData).then(res => {
this.isDisable=true this.isDisable = true
if(res.data.success==true){ if (res.data.success == true) {
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '发送邮件成功' desc: '发送邮件成功'
}) })
}, 500) }, 500)
this.emailMOdal=false this.emailMOdal = false
this.modal10=false this.modal10 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.emailInline.copyname='' this.emailInline.copyname = ''
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal10 = false this.modal10 = false
this.modal11 = true this.modal11 = true
this.errorInfo = res.data.body.message this.errorInfo = res.data.body.message
} }
}) })
} }
},800), }, 800),
changenotice(a){ changenotice (a) {
}, },
receiveEmail(){ receiveEmail () {
if(!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))){ if (!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
copyname(){ copyname () {
if(this.emailInline.copyname!==''&&!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))){ if (this.emailInline.copyname !== '' && !(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
theme(){ theme () {
if(this.emailInline.theme==''){ if (this.emailInline.theme == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写主题' desc: '请填写主题'
}); })
this.isDisable=false this.isDisable = false
return } else {
}else{ this.isDisable = true
this.isDisable=true
} }
}, },
UpdateOWER(){ UpdateOWER () {
if(this.formInline.UpdateOWER==''){ if (this.formInline.UpdateOWER == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
UpdateTIME(){ UpdateTIME () {
if(this.formInline.UpdateTIME==''){ if (this.formInline.UpdateTIME == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
UpdateVIEW(){ UpdateVIEW () {
if(this.formInline.UpdateVIEW==''){ if (this.formInline.UpdateVIEW == '') {
this.isDisable=false this.isDisable = false
}else{ } else {
this.isDisable=true this.isDisable = true
} }
}, },
delateFile(index){ delateFile (index) {
this.fileList.splice(index,1) this.fileList.splice(index, 1)
}, },
transpond() { //打开转发简历的modal transpond () { // 打开转发简历的modal
if(this.interviewee.length == 0) { if (this.interviewee.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请选择您要转发的简历' desc: '请选择您要转发的简历'
}); })
return return
} }
this.$refs.transpondFrom.resetFields() this.$refs.transpondFrom.resetFields()
this.modal8= true this.modal8 = true
}, },
sendNotice:_debounce( function() { sendNotice: _debounce(function () {
this.$refs.transpondFrom.validate(valid => { this.$refs.transpondFrom.validate(valid => {
if(!this.transpondFrom.interviewerName){ if (!this.transpondFrom.interviewerName) {
return return
} }
if (this.interviewee.length < 1) { if (this.interviewee.length < 1) {
this.$Notice.warning({title: '提示',desc: '发送内容为空,请勾选您要发送的简历'}) this.$Notice.warning({ title: '提示', desc: '发送内容为空,请勾选您要发送的简历' })
return return
} }
let resumeIdList = [] const resumeIdList = []
this.interviewee.map(item => { this.interviewee.map(item => {
resumeIdList.push(item.id) resumeIdList.push(item.id)
}) })
let params = { const params = {
resumeIdList, resumeIdList,
email: this.transpondFrom.interviewerName email: this.transpondFrom.interviewerName
} }
...@@ -1553,7 +1544,7 @@ export default { ...@@ -1553,7 +1544,7 @@ export default {
if (res.data.success == true) { if (res.data.success == true) {
this.clearInterviewee() this.clearInterviewee()
this.modal8 = false this.modal8 = false
this.isShowRep=false this.isShowRep = false
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
...@@ -1562,52 +1553,52 @@ export default { ...@@ -1562,52 +1553,52 @@ export default {
}, 500) }, 500)
this.SouSuo(this.pageT) this.SouSuo(this.pageT)
} }
if(res.data.body.code=='40009'){ if (res.data.body.code == '40009') {
this.reResumeName=res.data.body.message this.reResumeName = res.data.body.message
this.isShowRep=true this.isShowRep = true
return return
} }
if(res.data.body.code=='0'){ if (res.data.body.code == '0') {
this.modal8=false this.modal8 = false
this.isShowRep=false this.isShowRep = false
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: res.data.body.message desc: res.data.body.message
}) })
return return
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal8=false this.modal8 = false
this.modal12=true this.modal12 = true
this.isShowRep=false this.isShowRep = false
this.errorNotice=res.data.body.message this.errorNotice = res.data.body.message
} }
}) })
}) })
},800), }, 800),
pushSendNotice(){ pushSendNotice () {
this.modal8=false, this.modal8 = false,
this.isShowRep=false this.isShowRep = false
}, },
remoteMethod: function(query){ remoteMethod: function (query) {
if (query !== '') { if (query !== '') {
this.loading1 = true; this.loading1 = true
setTimeout(() => { setTimeout(() => {
this.loading1 = false; this.loading1 = false
let list = [] let list = []
query = query.split('(')[0] query = query.split('(')[0]
findCompanyEmailByKey(query).then(res => { findCompanyEmailByKey(query).then(res => {
list = res list = res
this.options = list.data.body || [] this.options = list.data.body || []
}, 200); }, 200)
}) })
} else { } else {
this.options = []; this.options = []
} }
}, },
removeInterviewee (value) { removeInterviewee (value) {
this.interviewee.map((item, index) => { this.interviewee.map((item, index) => {
if (value&&item.id == value.id) { if (value && item.id == value.id) {
this.interviewee.splice(index, 1) this.interviewee.splice(index, 1)
} }
}) })
...@@ -1615,9 +1606,8 @@ export default { ...@@ -1615,9 +1606,8 @@ export default {
addInterviewee (data) { addInterviewee (data) {
let flag = false let flag = false
this.interviewee.map(item => { this.interviewee.map(item => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
flag = true flag = true
return
} }
}) })
if (!flag) { if (!flag) {
...@@ -1633,11 +1623,11 @@ export default { ...@@ -1633,11 +1623,11 @@ export default {
item.STATES = false item.STATES = false
}) })
}, },
getfocus(form, name, e){ getfocus (form, name, e) {
let vm = this; const vm = this
let value = this[form][name] const value = this[form][name]
if(name == 'receiveEmail') { if (name == 'receiveEmail') {
this.tip&&this.$refs[form].fields.forEach(function (e) { this.tip && this.$refs[form].fields.forEach(function (e) {
if (e.prop == name) { if (e.prop == name) {
e.resetField() e.resetField()
vm[form][name] = value vm[form][name] = value
...@@ -1645,11 +1635,11 @@ export default { ...@@ -1645,11 +1635,11 @@ export default {
} }
}) })
} else { } else {
if (name=='UpdateTIME'&&e==false){ // 时间选择器关闭弹框的时候 if (name == 'UpdateTIME' && e == false) { // 时间选择器关闭弹框的时候
this.$refs.formInline.validateField('UpdateTIME', (e) => {}) this.$refs.formInline.validateField('UpdateTIME', (e) => {})
return return
} }
if (name=='UpdateVIEW'&&e==false){ // 选择关闭弹框的时候 if (name == 'UpdateVIEW' && e == false) { // 选择关闭弹框的时候
this.$refs.formInline.validateField('UpdateVIEW', (e) => {}) this.$refs.formInline.validateField('UpdateVIEW', (e) => {})
return return
} }
...@@ -1660,119 +1650,116 @@ export default { ...@@ -1660,119 +1650,116 @@ export default {
} }
}) })
} }
}, },
submit() { submit () {
let flag = false let flag = false
this.$refs.emailInline.validate(val => { this.$refs.emailInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
this.$refs.formInline.validate(val => { this.$refs.formInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
if (!flag){ if (!flag) {
this.modal10=true this.modal10 = true
} }
}, },
cancelSubmit(){ cancelSubmit () {
this.modal11= false this.modal11 = false
this.emailMOdal=false this.emailMOdal = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
} }
}, },
watch: { watch: {
'$route' (to, from) { '$route' (to, from) {
this.searchInfo={ this.searchInfo = {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
id:'', id: '',
SEX:'', SEX: '',
Edu:'', Edu: '',
ccc:'', ccc: '',
itemSelect:'', itemSelect: '',
STA:[], STA: [],
status:"", status: '',
ownerWorkYears1:'', ownerWorkYears1: '',
ownerWorkYears2:'', ownerWorkYears2: ''
} }
this.activeClass = 0 this.activeClass = 0
this.clickIndex1 = 0 this.clickIndex1 = 0
this.clickIndex2 = 0 this.clickIndex2 = 0
this.lickIndex3 = 0 this.lickIndex3 = 0
this.keywords='' this.keywords = ''
this.lrgs='' this.lrgs = ''
this.position=[] this.position = []
this.state.map(item => { this.state.map(item => {
item.sta = item.status3=='不限' ?true:false item.sta = item.status3 == '不限'
}) })
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter:{ parameter: {
sourceCode:this.$route.params.channelname, sourceCode: this.$route.params.channelname,
handUpload:this.$route.query.handUpload==null?'':this.$route.query.handUpload handUpload: this.$route.query.handUpload == null ? '' : this.$route.query.handUpload
} }
} }
this.getpositionList() this.getpositionList()
this.ajaxData=[] this.ajaxData = []
this.interviewee = [] this.interviewee = []
adoptOneSeeResumeList(parmars).then(res=>{ adoptOneSeeResumeList(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.checkboxList=[] this.checkboxList = []
if(res.data.body.totalNumber==0){ if (res.data.body.totalNumber == 0) {
this.totalSize=0 this.totalSize = 0
} }
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.quanxuan.push(res.data.body.items.id) this.quanxuan.push(res.data.body.items.id)
this.ajaxData=res.data.body.items.map((item,index)=>{ this.ajaxData = res.data.body.items.map((item, index) => {
item.id=item.id item.id = item.id
item.ownerName=item.ownerName item.ownerName = item.ownerName
item.ownerSex=item.ownerSex item.ownerSex = item.ownerSex
item.deliveryTime=item.deliveryTime item.deliveryTime = item.deliveryTime
item.belongs=item.belongs item.belongs = item.belongs
item.emailSendtime=item.emailSendtime item.emailSendtime = item.emailSendtime
item.ownerMobile=item.ownerMobile item.ownerMobile = item.ownerMobile
item.ownerHighestDegree=item.ownerHighestDegree item.ownerHighestDegree = item.ownerHighestDegree
item.ownerExpectTitles=item.ownerExpectTitles item.ownerExpectTitles = item.ownerExpectTitles
item.flowStatus=item.flowStatus item.flowStatus = item.flowStatus
item.ownerAge=item.ownerAge item.ownerAge = item.ownerAge
item.ownerWorkYears=item.ownerWorkYears item.ownerWorkYears = item.ownerWorkYears
item.modifyTime=item.modifyTime item.modifyTime = item.modifyTime
item.srcSite=item.srcSite item.srcSite = item.srcSite
item.STATES=false item.STATES = false
item.isShow=false item.isShow = false
item.hasRead=item.hasRead item.hasRead = item.hasRead
item.optSource=item.optSource item.optSource = item.optSource
item.originValue=item.flowStatus item.originValue = item.flowStatus
item.modifier=item.modifier item.modifier = item.modifier
item.uid=item.uid item.uid = item.uid
item.c=item.modifier==''?item.modifier:item.modifier.split('_') item.c = item.modifier == '' ? item.modifier : item.modifier.split('_')
item.d=item.c[0] item.d = item.c[0]
return item return item
}) })
} }
...@@ -1780,35 +1767,34 @@ export default { ...@@ -1780,35 +1767,34 @@ export default {
}, },
checkboxList: { checkboxList: {
handler: function (val, oldVal) { handler: function (val, oldVal) {
if(this.ajaxData.length==0){ if (this.ajaxData.length == 0) {
this.checked=false this.checked = false
return return
} }
if(this.delateARRALL.length==30){ if (this.delateARRALL.length == 30) {
this.checked=true this.checked = true
return return
} }
if(this.delateARRALL.length!==30){ if (this.delateARRALL.length !== 30) {
this.checked=false this.checked = false
return return
} }
if (this.checkboxList.length === this.ajaxData.length) { if (this.checkboxList.length === this.ajaxData.length) {
this.checked=true; this.checked = true
} } else {
else { this.checked = false
this.checked=false;
} }
}, },
deep: true deep: true
} }
}, },
mounted(){ mounted () {
this.SouSuo(null, 'init') this.SouSuo(null, 'init')
this.getpositionList() this.getpositionList()
document.addEventListener('visibilitychange',()=>{ document.addEventListener('visibilitychange', () => {
var isHidden = document.hidden; var isHidden = document.hidden
if(isHidden){ if (isHidden) {
document.title = '思坦途' document.title = '思坦途'
} else { } else {
document.title = '思坦途' document.title = '思坦途'
......
...@@ -135,43 +135,43 @@ ...@@ -135,43 +135,43 @@
</div> </div>
</template> </template>
<script> <script>
import {seedetail} from '../../api/resume.server' import { seedetail } from '../../api/resume.server'
import localStorage from '../../service/localstorage.service.js' import localStorage from '../../service/localstorage.service.js'
import { import {
sapi sapi
}from '../../config' } from '../../config'
export default { export default {
data(){ data () {
return { return {
resume:{}, resume: {},
riList:[], riList: [],
roList:[], roList: [],
rpList:[], rpList: [],
reList:[], reList: [],
downresume:'', downresume: '',
detialID:'', detialID: '',
showBtn:'', showBtn: ''
} }
}, },
methods: { methods: {
getDETAIL(){ getDETAIL () {
this.detialID=this.$route.query.ID this.detialID = this.$route.query.ID
this.showBtn=this.$route.query.noShowBtn this.showBtn = this.$route.query.noShowBtn
let token = this.$route.query.token || '' const token = this.$route.query.token || ''
let parmars={ const parmars = {
uid:this.$route.query.id uid: this.$route.query.id
// uid:"0646215721cc43ccb51ff3e979959e35" // uid:"0646215721cc43ccb51ff3e979959e35"
} }
seedetail(parmars).then(res=>{ seedetail(parmars).then(res => {
this.resume=res.data.body.resume this.resume = res.data.body.resume
this.riList=res.data.body.riList this.riList = res.data.body.riList
this.roList=res.data.body.roList this.roList = res.data.body.roList
this.rpList=res.data.body.rpList this.rpList = res.data.body.rpList
this.reList=res.data.body.reList this.reList = res.data.body.reList
}) })
}
}, },
}, mounted () {
mounted(){
this.getDETAIL() this.getDETAIL()
} }
} }
...@@ -329,4 +329,3 @@ export default { ...@@ -329,4 +329,3 @@ export default {
/* border: 1px solid red */ /* border: 1px solid red */
} }
</style> </style>
...@@ -317,204 +317,221 @@ ...@@ -317,204 +317,221 @@
<script> <script>
import moment from 'moment' import moment from 'moment'
import pdf from 'vue-pdf' import pdf from 'vue-pdf'
// import moment from '../../../static/1.pdf'
require('../../../static/pdf/pdf.js')
// let mammoth = require("mammoth"); // let mammoth = require("mammoth");
import {seedetail,updatastatus,TODORes,sendEmail,getEmailMoo,getEmailContent,uploadimage, findCompanyEmailByKey,forwardResume,getPdf,isShowPDF,getpdfUrl} from '../../api/resume.server' import { seedetail, updatastatus, TODORes, sendEmail, getEmailMoo, getEmailContent, uploadimage, findCompanyEmailByKey, forwardResume, getPdf, isShowPDF, getpdfUrl } from '../../api/resume.server'
import localStorage from '../../service/localstorage.service.js' import localStorage from '../../service/localstorage.service.js'
import { import {
sapi sapi
}from '../../config' } from '../../config'
import ckeditor from '../../components/ckeditor' import ckeditor from '../../components/ckeditor'
import{_debounce,_throttle,emailValidata, emailRule, vidte, validator} from '../../service/util.js' import { _debounce, _throttle, emailValidata, emailRule, vidte, validator } from '../../service/util.js'
// import moment from '../../../static/1.pdf'
require('../../../static/pdf/pdf.js')
export default { export default {
data(){ data () {
return { return {
resume:{}, resume: {},
riList:[], riList: [],
roList:[], roList: [],
rpList:[], rpList: [],
reList:[], reList: [],
name:'', name: '',
detailSta:'', detailSta: '',
pdfUrl:'', pdfUrl: '',
emailMOdal:false, emailMOdal: false,
tip: false, tip: false,
loading1: false, loading1: false,
modal8:false, modal8: false,
modal10:false, modal10: false,
modal11:false, modal11: false,
modal12:false, modal12: false,
modal13:false, modal13: false,
modal14:false, modal14: false,
modal15:false, modal15: false,
modal16:false, modal16: false,
modal17:false, modal17: false,
boxIsShow:false, boxIsShow: false,
resumeBTn:false, resumeBTn: false,
isShowPdf:true, isShowPdf: true,
errorNotice:'', errorNotice: '',
px:1200, px: 1200,
showOriginalDisabled:true, showOriginalDisabled: true,
OriginalContent:'', OriginalContent: '',
StandardContent:'', StandardContent: '',
showStandardDisabled:false, showStandardDisabled: false,
errorMassage:'', errorMassage: '',
interviewee: [], interviewee: [],
contentName:'', contentName: '',
a:{'a_b':'hjbjhbjbh','b':'4'}, a: { a_b: 'hjbjhbjbh', b: '4' },
detailStatus:{'TO_DO':'待处理','INTERVIEW_OK':'面试合适','INTERVIEW_FAIL':'面试淘汰','END':'终止面试','SEE_FAIL':'约面失败','NO_ENTRY':'未入职', detailStatus: {
'TO_SEE':'准备约面','END':'终止面试','SEE_FAIL':'约面失败','NO_ENTRY':'未入职','HAS_SEE':'已邀约','OPTION':'备选','TO_SENT_OFFER':'待Offer','HAS_SENT_OFFER':'已发offer', TO_DO: '待处理',
'TO_ENTRY':'待入职', 'HAS_ENTRY':'已入职', 'PASS':'PASS', 'RESET':'重启面试','ARRIVED':'已到达'}, INTERVIEW_OK: '面试合适',
INTERVIEW_FAIL: '面试淘汰',
END: '终止面试',
SEE_FAIL: '约面失败',
NO_ENTRY: '未入职',
TO_SEE: '准备约面',
END: '终止面试',
SEE_FAIL: '约面失败',
NO_ENTRY: '未入职',
HAS_SEE: '已邀约',
OPTION: '备选',
TO_SENT_OFFER: '待Offer',
HAS_SENT_OFFER: '已发offer',
TO_ENTRY: '待入职',
HAS_ENTRY: '已入职',
PASS: 'PASS',
RESET: '重启面试',
ARRIVED: '已到达'
},
// detailStatus:[{sta:'TO_DO',detailSta:'待处理'},{sta:'INTERVIEW_OK',detailSta:'面试合适'},{sta:'INTERVIEW_FAIL',detailSta:'面试淘汰'}, // detailStatus:[{sta:'TO_DO',detailSta:'待处理'},{sta:'INTERVIEW_OK',detailSta:'面试合适'},{sta:'INTERVIEW_FAIL',detailSta:'面试淘汰'},
// {sta:'END',detailSta:'终止面试'},{sta:'SEE_FAIL',detailSta:'约面失败'},{sta:'NO_ENTRY',detailSta:'未入职'},{sta:'TO_SEE',detailSta:'准备约面'}, // {sta:'END',detailSta:'终止面试'},{sta:'SEE_FAIL',detailSta:'约面失败'},{sta:'NO_ENTRY',detailSta:'未入职'},{sta:'TO_SEE',detailSta:'准备约面'},
// {sta:'HAS_SEE',detailSta:'已邀约'},{sta:'OPTION',detailSta:'备选'},{sta:'TO_SENT_OFFER',detailSta:'待Offer'},{sta:'HAS_SENT_OFFER',detailSta:'已发offer'},{sta:'TO_ENTRY',detailSta:'待入职'}, // {sta:'HAS_SEE',detailSta:'已邀约'},{sta:'OPTION',detailSta:'备选'},{sta:'TO_SENT_OFFER',detailSta:'待Offer'},{sta:'HAS_SENT_OFFER',detailSta:'已发offer'},{sta:'TO_ENTRY',detailSta:'待入职'},
// {sta:'HAS_ENTRY',detailSta:'已入职'},{sta:'PASS',detailSta:'PASS'},{sta:'RESET',detailSta:'重启面试'},{sta:'ARRIVED',detailSta:'已到达'}], // {sta:'HAS_ENTRY',detailSta:'已入职'},{sta:'PASS',detailSta:'PASS'},{sta:'RESET',detailSta:'重启面试'},{sta:'ARRIVED',detailSta:'已到达'}],
emailId:'', emailId: '',
transpondFrom: { transpondFrom: {
interviewerName: '' interviewerName: ''
}, },
transpondRule: { transpondRule: {
interviewerName: [{required: true, trigger: 'blur', validator: validator.bind(this)}] interviewerName: [{ required: true, trigger: 'blur', validator: validator.bind(this) }]
}, },
options: [], options: [],
todoDisabled:false, todoDisabled: false,
passDisabled:false, passDisabled: false,
optionDisabled:false, optionDisabled: false,
editorObject: {type: '', value: ''}, editorObject: { type: '', value: '' },
tipInfo: '输入多个邮箱地址以英文”;“分隔', tipInfo: '输入多个邮箱地址以英文”;“分隔',
fileList:[], fileList: [],
UpdateTIMETwo:'', UpdateTIMETwo: '',
uploadFileList:[], uploadFileList: [],
temp:'', temp: '',
uploadurl:`${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`, uploadurl: `${sapi}/api/ckeditor/uploadImage?token=${localStorage.get('token')}&&backUrl=/getimage`,
downresume:'', downresume: '',
detialID:'', detialID: '',
showBtn:'', showBtn: '',
errorInfo:'', errorInfo: '',
isShowAll:false, isShowAll: false,
isShowTwo:false, isShowTwo: false,
interviewIsShow:false, interviewIsShow: false,
reResumeName:'', reResumeName: '',
isShowRep:false, isShowRep: false,
hasINterview:false, hasINterview: false,
resumeIdList:[], resumeIdList: [],
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() <Date.now()-3600*24*1000; return date && date.valueOf() < Date.now() - 3600 * 24 * 1000
} }
}, },
ruleInline: { ruleInline: {
UpdateOWER: [ UpdateOWER: [
{ required: true, message: '邀约人不能为空', trigger: 'blur',validator: emailValidata.bind(this)} { required: true, message: '邀约人不能为空', trigger: 'blur', validator: emailValidata.bind(this) }
], ],
UpdateTIME: [ UpdateTIME: [
{ required: true, message: '面试时间不能为空', trigger: 'change', type:'date', validator: emailValidata.bind(this)} { required: true, message: '面试时间不能为空', trigger: 'change', type: 'date', validator: emailValidata.bind(this) }
], ],
UpdateVIEW: [ UpdateVIEW: [
{ required: true,message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this), type: String} { required: true, message: '面试官不能为空', trigger: 'change', validator: emailValidata.bind(this), type: String }
] ]
}, },
emailruleInline: { emailruleInline: {
receiveEmail: [{required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this)}], receiveEmail: [{ required: true, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this) }],
theme: [{required: true, trigger: 'blur',message: '主题不能为空', validator: emailValidata.bind(this)}], theme: [{ required: true, trigger: 'blur', message: '主题不能为空', validator: emailValidata.bind(this) }],
copyname: [{required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true}] copyname: [{ required: false, trigger: 'blur', pattern: emailRule, validator: emailValidata.bind(this), empty: true }]
}, },
formInline:{ formInline: {
UpdateOWER:'', UpdateOWER: '',
UpdateTIME:'', UpdateTIME: '',
UpdateVIEW:'', UpdateVIEW: '',
sendWeixin: true sendWeixin: true
}, },
emailInline:{ emailInline: {
moo:'', moo: '',
modalArr:[], modalArr: [],
copyname:'', copyname: '',
receiveEmail:'',//收件人 receiveEmail: '', // 收件人
theme:'',//主题 theme: '', // 主题
Enclosure:[],//附件 Enclosure: [], // 附件
templateContent:'',//模板内容 templateContent: ''// 模板内容
}, }
} }
}, },
components:{ components: {
ckeditor, ckeditor,
pdf pdf
}, },
methods: { methods: {
getDETAIL(){ getDETAIL () {
this.detialID=this.$route.query.ID this.detialID = this.$route.query.ID
this.resumeIdList.push(this.$route.query.ID) this.resumeIdList.push(this.$route.query.ID)
this.emailId=this.$route.query.ID this.emailId = this.$route.query.ID
this.detailSta=this.$route.query.status this.detailSta = this.$route.query.status
this.showBtn=this.$route.query.noShowBtn this.showBtn = this.$route.query.noShowBtn
let token = this.$route.query.token || '' const token = this.$route.query.token || ''
let parmars={ const parmars = {
uid:this.$route.query.id uid: this.$route.query.id
} }
seedetail(parmars).then(res=>{ seedetail(parmars).then(res => {
this.resume=res.data.body.resume this.resume = res.data.body.resume
this.riList=res.data.body.riList this.riList = res.data.body.riList
this.roList=res.data.body.roList this.roList = res.data.body.roList
this.rpList=res.data.body.rpList this.rpList = res.data.body.rpList
this.reList=res.data.body.reList this.reList = res.data.body.reList
this.name=res.data.body.resume.ownerName this.name = res.data.body.resume.ownerName
}) })
}, },
// 下载简历 // 下载简历
downloadONE(doid){ downloadONE (doid) {
window.location.href=`${sapi}/api/resume/download/formatted/one?resumeId=${doid}` window.location.href = `${sapi}/api/resume/download/formatted/one?resumeId=${doid}`
}, },
// 发送邮件 // 发送邮件
sendEmail(type){ sendEmail (type) {
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.$refs.emailInline.resetFields() this.$refs.emailInline.resetFields()
this.$refs.formInline.resetFields() this.$refs.formInline.resetFields()
this.emailInline.moo = 'TEMP_0001' this.emailInline.moo = 'TEMP_0001'
this.options=[] this.options = []
this.emailMOdal=true this.emailMOdal = true
getEmailMoo().then(res=>{ getEmailMoo().then(res => {
this.emailInline.modalArr=res.data.body this.emailInline.modalArr = res.data.body
}) })
this.getEmailContentValue(this.emailInline.moo) this.getEmailContentValue(this.emailInline.moo)
}, },
getEmailContentValue(value){ getEmailContentValue (value) {
if (!value){ if (!value) {
return return
} }
this.isDisable=true this.isDisable = true
this.temp=value this.temp = value
this.emailCode=value this.emailCode = value
let params={ const params = {
resumeId:this.emailId==''?'':this.emailId, resumeId: this.emailId == '' ? '' : this.emailId,
templateCode:this.emailCode templateCode: this.emailCode
} }
getEmailContent(params).then(res=>{ getEmailContent(params).then(res => {
this.emailInline.theme=res.data.body.templateSubject this.emailInline.theme = res.data.body.templateSubject
this.emailInline.receiveEmail=res.data.body.receiveEmail this.emailInline.receiveEmail = res.data.body.receiveEmail
this.emailInline.templateContent=res.data.body.templateContent this.emailInline.templateContent = res.data.body.templateContent
this.editorObject = { this.editorObject = {
type: value, type: value,
value: this.emailInline.templateContent || '' value: this.emailInline.templateContent || ''
} }
if(res.data.body&&res.data.body.resumeInterviewVO){ if (res.data.body && res.data.body.resumeInterviewVO) {
this.formInline.UpdateOWER=res.data.body.resumeInterviewVO.inviterName this.formInline.UpdateOWER = res.data.body.resumeInterviewVO.inviterName
this.formInline.UpdateVIEW=res.data.body.resumeInterviewVO.interviewerName this.formInline.UpdateVIEW = res.data.body.resumeInterviewVO.interviewerName
this.formInline.UpdateTIME=res.data.body.resumeInterviewVO.seeTime this.formInline.UpdateTIME = res.data.body.resumeInterviewVO.seeTime
this.changeTime(this.formInline.UpdateTIME) this.changeTime(this.formInline.UpdateTIME)
}else{ } else {
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
} }
}) })
}, },
getfocus(form, name, e){ getfocus (form, name, e) {
let vm = this; const vm = this
let value = this[form][name] const value = this[form][name]
if(name == 'receiveEmail') { if (name == 'receiveEmail') {
this.tip&&this.$refs[form].fields.forEach(function (e) { this.tip && this.$refs[form].fields.forEach(function (e) {
if (e.prop == name) { if (e.prop == name) {
e.resetField() e.resetField()
vm[form][name] = value vm[form][name] = value
...@@ -522,11 +539,11 @@ export default { ...@@ -522,11 +539,11 @@ export default {
} }
}) })
} else { } else {
if (name=='UpdateTIME'&&e==false){ // 时间选择器关闭弹框的时候 if (name == 'UpdateTIME' && e == false) { // 时间选择器关闭弹框的时候
this.$refs.formInline.validateField('UpdateTIME', (e) => {}) this.$refs.formInline.validateField('UpdateTIME', (e) => {})
return return
} }
if (name=='UpdateVIEW'&&e==false){ // 选择关闭弹框的时候 if (name == 'UpdateVIEW' && e == false) { // 选择关闭弹框的时候
this.$refs.formInline.validateField('UpdateVIEW', (e) => { this.$refs.formInline.validateField('UpdateVIEW', (e) => {
}) })
return return
...@@ -539,9 +556,9 @@ export default { ...@@ -539,9 +556,9 @@ export default {
}) })
} }
}, },
changeTime(b){ changeTime (b) {
this.UpdateTIME=b this.UpdateTIME = b
if (!b){ if (!b) {
this.editorObject = { this.editorObject = {
type: this.temp, type: this.temp,
value: this.emailInline.templateContent value: this.emailInline.templateContent
...@@ -563,78 +580,76 @@ export default { ...@@ -563,78 +580,76 @@ export default {
value: this.emailInline.templateContent.replace(reg, content) value: this.emailInline.templateContent.replace(reg, content)
} }
}, },
remoteMethod: async function(query){ remoteMethod: async function (query) {
if (query !== '') { if (query !== '') {
this.loading1 = true; this.loading1 = true
setTimeout(async () => { setTimeout(async () => {
this.loading1 = false; this.loading1 = false
query = query.split('(')[0] query = query.split('(')[0]
let list = await findCompanyEmailByKey(query) const list = await findCompanyEmailByKey(query)
this.options = list.data.body || [] this.options = list.data.body || []
}, 200); }, 200)
} else { } else {
this.options = []; this.options = []
} }
}, },
beforUpload(uploadFile){ beforUpload (uploadFile) {
let isLiment=false let isLiment = false
if(uploadFile.size/1024 > 10240){ if (uploadFile.size / 1024 > 10240) {
isLiment=true isLiment = true
this.limentName+=1 this.limentName += 1
if(this.limentName==1){ if (this.limentName == 1) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '单个文件不能大于10M' desc: '单个文件不能大于10M'
}) })
} }
}else{ } else {
this.fileList.push(uploadFile.name) this.fileList.push(uploadFile.name)
this.uploadFileList.push(uploadFile) this.uploadFileList.push(uploadFile)
} }
return false return false
}, },
uploadFile(){ uploadFile () {
this.limentName=0 this.limentName = 0
}, },
emailModalPush(){ emailModalPush () {
this.$refs.emailInline.resetFields() this.$refs.emailInline.resetFields()
this.$refs.formInline.resetFields() this.$refs.formInline.resetFields()
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.isLimitSize=false this.isLimitSize = false
this.uploadFileList=[] this.uploadFileList = []
}, },
submit() { submit () {
let flag = false let flag = false
this.$refs.emailInline.validate(val => { this.$refs.emailInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
this.$refs.formInline.validate(val => { this.$refs.formInline.validate(val => {
if (!val) { if (!val) {
flag = true flag = true
return
} }
}) })
if (!flag){ if (!flag) {
this.modal10=true this.modal10 = true
} }
}, },
clearInterviewee (value) { clearInterviewee (value) {
...@@ -643,20 +658,20 @@ export default { ...@@ -643,20 +658,20 @@ export default {
this.delateARRALL = [] this.delateARRALL = []
this.flowStatusarr = [] this.flowStatusarr = []
}, },
sendNotice: _debounce( function() { sendNotice: _debounce(function () {
this.$refs.transpondFrom.validate(valid => { this.$refs.transpondFrom.validate(valid => {
if(!this.transpondFrom.interviewerName){ if (!this.transpondFrom.interviewerName) {
return return
} }
let params = { const params = {
resumeIdList:this.resumeIdList, resumeIdList: this.resumeIdList,
email: this.transpondFrom.interviewerName email: this.transpondFrom.interviewerName
} }
forwardResume(params).then(res => { forwardResume(params).then(res => {
if (res.data.success == true) { if (res.data.success == true) {
this.clearInterviewee() this.clearInterviewee()
this.modal8 = false this.modal8 = false
this.isShowRep=false this.isShowRep = false
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
...@@ -664,286 +679,286 @@ export default { ...@@ -664,286 +679,286 @@ export default {
}) })
}, 300) }, 300)
} }
if(res.data.body.code=='40009'){ if (res.data.body.code == '40009') {
this.reResumeName=res.data.body.message this.reResumeName = res.data.body.message
this.isShowRep=true this.isShowRep = true
return return
} }
if(res.data.body.code=='0'){ if (res.data.body.code == '0') {
this.modal8=false this.modal8 = false
this.isShowRep=false this.isShowRep = false
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: res.data.body.message desc: res.data.body.message
}) })
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal8=false this.modal8 = false
this.modal12=true this.modal12 = true
this.isShowRep=false this.isShowRep = false
this.errorNotice=res.data.body.message this.errorNotice = res.data.body.message
} }
}) })
}) })
},800), }, 800),
pushSendNotice(){ pushSendNotice () {
this.modal8=false, this.modal8 = false,
this.isShowRep=false this.isShowRep = false
}, },
transpond() { //打开转发简历的modal transpond () { // 打开转发简历的modal
this.$refs.transpondFrom.resetFields() this.$refs.transpondFrom.resetFields()
this.modal8= true this.modal8 = true
this.contentName=this.name this.contentName = this.name
}, },
delInterviewee(name){ delInterviewee (name) {
this.contentName='' this.contentName = ''
}, },
showOriginal(){ showOriginal () {
// this.showPDF() // this.showPDF()
this.isShowPdf=true this.isShowPdf = true
this.showOriginalDisabled=true this.showOriginalDisabled = true
this.showStandardDisabled=false this.showStandardDisabled = false
}, },
showStandard(){ showStandard () {
this.isShowPdf=false this.isShowPdf = false
// this.clearPDF() // this.clearPDF()
this.showStandardDisabled=true this.showStandardDisabled = true
this.showOriginalDisabled=false this.showOriginalDisabled = false
}, },
judeShowPdf(){ judeShowPdf () {
let parmars={ const parmars = {
uid:this.$route.query.id uid: this.$route.query.id
} }
isShowPDF(parmars).then(res=>{ isShowPDF(parmars).then(res => {
if(res.data.body==true){ if (res.data.body == true) {
this.isShowPdf=true this.isShowPdf = true
this.resumeBTn=true this.resumeBTn = true
}else{ } else {
this.isShowPdf=false this.isShowPdf = false
this.resumeBTn=false this.resumeBTn = false
} }
}) })
}, },
getPdfUrl(){ getPdfUrl () {
let parmars={ const parmars = {
uid:this.$route.query.id uid: this.$route.query.id
} }
getpdfUrl(parmars).then(res=>{ getpdfUrl(parmars).then(res => {
this.pdfUrl=res.data this.pdfUrl = res.data
}) })
}, },
// 确认发送邮件 // 确认发送邮件
confireSendEmail: _debounce(function(){ confireSendEmail: _debounce(function () {
this.sad = this.getEditorValue() this.sad = this.getEditorValue()
if(this.sad==''){ if (this.sad == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if(this.emailInline.moo==''){ if (this.emailInline.moo == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if((this.temp=='TEMP_0001')&&(this.emailInline.moo==''||this.emailInline.receiveEmail==''||this.emailInline.theme==''||this.formInline.UpdateOWER==''||this.formInline.UpdateVIEW==''||this.formInline.UpdateTIME=='')){ if ((this.temp == 'TEMP_0001') && (this.emailInline.moo == '' || this.emailInline.receiveEmail == '' || this.emailInline.theme == '' || this.formInline.UpdateOWER == '' || this.formInline.UpdateVIEW == '' || this.formInline.UpdateTIME == '')) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请填写完整的信息' desc: '请填写完整的信息'
}); })
return return
} }
if(this.emailInline.copyname!==''&&!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))){ if (this.emailInline.copyname !== '' && !(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.copyname))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
if(!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))){ if (!(/^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/.test(this.emailInline.receiveEmail))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请正确填写邮箱地址' desc: '请正确填写邮箱地址'
}); })
return return
} }
this.attachFileList=this.uploadFileList.length==0?'':this.uploadFileList this.attachFileList = this.uploadFileList.length == 0 ? '' : this.uploadFileList
this.flowStatusTT=this.emailFlowStatus==''?'':'TO_SEE' this.flowStatusTT = this.emailFlowStatus == '' ? '' : 'TO_SEE'
this.UpdateTIMETwo=this.formInline.UpdateTIME==''?'':this.formInline.UpdateTIME this.UpdateTIMETwo = this.formInline.UpdateTIME == '' ? '' : this.formInline.UpdateTIME
if(this.temp=='TEMP_0001'){ if (this.temp == 'TEMP_0001') {
var formData= new FormData() var formData = new FormData()
if(this.attachFileList.length!==0){ if (this.attachFileList.length !== 0) {
this.attachFileList.map(item=>{ this.attachFileList.map(item => {
formData.append('attachFileList',item) formData.append('attachFileList', item)
}) })
}else{ } else {
formData.append('attachFileList','') formData.append('attachFileList', '')
} }
formData.append('resumeId',this.emailId) formData.append('resumeId', this.emailId)
formData.append('templateCode',this.emailCode) formData.append('templateCode', this.emailCode)
formData.append('subject',this.emailInline.theme) formData.append('subject', this.emailInline.theme)
formData.append('toEmail',this.emailInline.receiveEmail) formData.append('toEmail', this.emailInline.receiveEmail)
formData.append('ccEmail',this.emailInline.copyname) formData.append('ccEmail', this.emailInline.copyname)
formData.append('emailContent',this.sad) formData.append('emailContent', this.sad)
formData.append('resumeInterviewVO.resumeId',this.emailId) formData.append('resumeInterviewVO.resumeId', this.emailId)
formData.append('resumeInterviewVO.inviterName',this.formInline.UpdateOWER==''?'':this.formInline.UpdateOWER) formData.append('resumeInterviewVO.inviterName', this.formInline.UpdateOWER == '' ? '' : this.formInline.UpdateOWER)
formData.append('resumeInterviewVO.interviewerName',this.formInline.UpdateVIEW==''?'':this.formInline.UpdateVIEW) formData.append('resumeInterviewVO.interviewerName', this.formInline.UpdateVIEW == '' ? '' : this.formInline.UpdateVIEW)
let info = this.options.find(item => item.name == this.formInline.UpdateVIEW) const info = this.options.find(item => item.name == this.formInline.UpdateVIEW)
formData.append('resumeInterviewVO.email',(info&&info.email) || '') formData.append('resumeInterviewVO.email', (info && info.email) || '')
formData.append('sendWeixin',this.formInline.sendWeixin==true ? 1 : 0) formData.append('sendWeixin', this.formInline.sendWeixin == true ? 1 : 0)
formData.append('resumeInterviewVO.seeTime',moment( this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm')) formData.append('resumeInterviewVO.seeTime', moment(this.UpdateTIMETwo).format('YYYY/MM/DD HH:mm'))
formData.append(' flowStatus',this.flowStatusTT) formData.append(' flowStatus', this.flowStatusTT)
this.isDisable=false this.isDisable = false
sendEmail(formData).then(res=>{ sendEmail(formData).then(res => {
this.isDisable=true this.isDisable = true
if(res.data.success==true){ if (res.data.success == true) {
setTimeout(() => { setTimeout(() => {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '发送邮件成功' desc: '发送邮件成功'
}) })
}, 500) }, 500)
this.detailSta='HAS_SEE' this.detailSta = 'HAS_SEE'
this.hasINterview=true this.hasINterview = true
this.emailMOdal=false this.emailMOdal = false
this.modal10=false this.modal10 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal10 = false this.modal10 = false
this.modal11 = true this.modal11 = true
this.errorInfo = res.data.body.message this.errorInfo = res.data.body.message
} }
}) })
} }
},800), }, 800),
getEditorValue(value){ // 调编辑器组件方法获取数据 getEditorValue (value) { // 调编辑器组件方法获取数据
return this.$refs.editor.getValue() return this.$refs.editor.getValue()
}, },
// 判断按钮的显示与隐藏 // 判断按钮的显示与隐藏
judeBtn(){ judeBtn () {
if(this.detailSta == 'TO_DO'|| this.detailSta == 'PASS' || this.detailSta == 'OPTION'){ if (this.detailSta == 'TO_DO' || this.detailSta == 'PASS' || this.detailSta == 'OPTION') {
this.hasINterview=false this.hasINterview = false
}else{ } else {
this.hasINterview=true this.hasINterview = true
} }
if(this.detailSta == 'TO_DO'){ if (this.detailSta == 'TO_DO') {
this.todoDisabled=true this.todoDisabled = true
} }
if(this.detailSta == 'PASS'){ if (this.detailSta == 'PASS') {
this.passDisabled=true this.passDisabled = true
} }
if(this.detailSta == 'OPTION'){ if (this.detailSta == 'OPTION') {
this.optionDisabled=true this.optionDisabled = true
} }
}, },
cancelSubmit(){ cancelSubmit () {
this.emailMOdal=false this.emailMOdal = false
this.modal11=false this.modal11 = false
this.emailInline.modalArr=[] this.emailInline.modalArr = []
this.emailInline.theme='' this.emailInline.theme = ''
this.emailInline.receiveEmail='' this.emailInline.receiveEmail = ''
this.emailInline.templateContent='' this.emailInline.templateContent = ''
this.sad='' this.sad = ''
this.fileList=[] this.fileList = []
this.emailInline.moo='' this.emailInline.moo = ''
this.emailMOdal=false this.emailMOdal = false
this.emailMassage=false this.emailMassage = false
this.emailIdArr=[] this.emailIdArr = []
this.emailFlowStatus='' this.emailFlowStatus = ''
this.formInline.UpdateOWER='' this.formInline.UpdateOWER = ''
this.formInline.UpdateVIEW='' this.formInline.UpdateVIEW = ''
this.formInline.UpdateTIME='' this.formInline.UpdateTIME = ''
this.formInline.sendWeixin=true this.formInline.sendWeixin = true
this.emailInline.copyname='' this.emailInline.copyname = ''
this.isShowTwo=false this.isShowTwo = false
this.uploadFileList=[] this.uploadFileList = []
this.clearInterviewee() this.clearInterviewee()
}, },
sendFail(){ sendFail () {
this.modal11 = false this.modal11 = false
}, },
// 待处理 // 待处理
todo(){ todo () {
let parmars={ const parmars = {
id: this.detialID, id: this.detialID,
status:'TO_DO' status: 'TO_DO'
} }
updatastatus(parmars).then(res=>{ updatastatus(parmars).then(res => {
this.detailSta='TO_DO' this.detailSta = 'TO_DO'
this.todoDisabled=true this.todoDisabled = true
this.passDisabled=false this.passDisabled = false
this.optionDisabled=false this.optionDisabled = false
}) })
}, },
// 备选 // 备选
option(){ option () {
let parmars={ const parmars = {
id: this.detialID, id: this.detialID,
status:'OPTION' status: 'OPTION'
} }
updatastatus(parmars).then(res=>{ updatastatus(parmars).then(res => {
this.detailSta='OPTION' this.detailSta = 'OPTION'
this.todoDisabled=false this.todoDisabled = false
this.passDisabled=false this.passDisabled = false
this.optionDisabled=true this.optionDisabled = true
}) })
}, },
// PASS // PASS
pass(){ pass () {
let parmars={ const parmars = {
id: this.detialID, id: this.detialID,
status:'PASS' status: 'PASS'
} }
updatastatus(parmars).then(res=>{ updatastatus(parmars).then(res => {
this.detailSta='PASS' this.detailSta = 'PASS'
this.todoDisabled=false this.todoDisabled = false
this.passDisabled=true this.passDisabled = true
this.optionDisabled=false this.optionDisabled = false
}) })
}, },
addCss(){ addCss () {
document.querySelector('#app').style['overflow-x']='hidden' document.querySelector('#app').style['overflow-x'] = 'hidden'
}, },
remove(){ remove () {
document.querySelector('#app').style.removeProperty('overflow-x') document.querySelector('#app').style.removeProperty('overflow-x')
}
}, },
}, // created(){
// created(){ //     this.src = pdf.createLoadingTask(this.src)
//     this.src = pdf.createLoadingTask(this.src) //    },
//    }, async mounted () {
async mounted(){
this.getPdfUrl() this.getPdfUrl()
this.getDETAIL() this.getDETAIL()
this.boxIsShow=true this.boxIsShow = true
this.judeBtn() this.judeBtn()
this.addCss() this.addCss()
// await this.getData() // await this.getData()
// this.clearPDF() // this.clearPDF()
await this.judeShowPdf() await this.judeShowPdf()
}, },
beforeDestroy(){ beforeDestroy () {
this.remove() this.remove()
} }
} }
...@@ -1166,4 +1181,3 @@ export default { ...@@ -1166,4 +1181,3 @@ export default {
/* border: 1px solid red */ /* border: 1px solid red */
} }
</style> </style>
...@@ -67,53 +67,53 @@ ...@@ -67,53 +67,53 @@
</template> </template>
<script> <script>
import moment from 'moment' import moment from 'moment'
import {submitMassage} from '../../api/sweepCode.server.js' import { submitMassage } from '../../api/sweepCode.server.js'
export default { export default {
data(){ data () {
return { return {
docmHeight: '0', docmHeight: '0',
showHeight: '0', showHeight: '0',
loading: false, loading: false,
hidshow:true, hidshow: true,
isResize:false, isResize: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
ruleInline: { ruleInline: {
Inviter: [ Inviter: [
{ required: true, message: '请输入邀约人', trigger: 'blur' } { required: true, message: '请输入邀约人', trigger: 'blur' }
], ],
time: [ time: [
{ required: true,message: '面试时间不能为空', trigger: 'date' }, { required: true, message: '面试时间不能为空', trigger: 'date' }
], ],
// InviterPhoneNumber: [ // InviterPhoneNumber: [
// { required: false, pattern:/^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' } // { required: false, pattern:/^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' }
// ], // ],
position: [ position: [
{ required: true,message: '请输入应聘职位', trigger: 'blur' } { required: true, message: '请输入应聘职位', trigger: 'blur' }
], ],
model1: [ model1: [
{ required: true,message: '请输入应聘来源', trigger: 'blur' } { required: true, message: '请输入应聘来源', trigger: 'blur' }
], ],
name: [ name: [
{ required: true,message: '请输入姓名', trigger: 'blur' } { required: true, message: '请输入姓名', trigger: 'blur' }
], ],
phoneNUmber: [ phoneNUmber: [
{ required: true,message: '请输入正确的手机号码', trigger: 'blur' }, { required: true, message: '请输入正确的手机号码', trigger: 'blur' },
{ required: true, pattern:/^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' } { required: true, pattern: /^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' }
], ],
model2: [ model2: [
{ required: true,message: '请选择是否携带简历', trigger: 'blur' } { required: true, message: '请选择是否携带简历', trigger: 'blur' }
], ]
}, },
saleDate:'', saleDate: '',
isV:false, isV: false,
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() <Date.now()-3600*24*1000|| date.valueOf() >Date.now(); return date && date.valueOf() < Date.now() - 3600 * 24 * 1000 || date.valueOf() > Date.now()
} }
}, },
origen:[ origen: [
{ {
value: '智联招聘', value: '智联招聘',
label: '智联招聘' label: '智联招聘'
...@@ -141,9 +141,9 @@ export default { ...@@ -141,9 +141,9 @@ export default {
{ {
value: '其他', value: '其他',
label: '其他' label: '其他'
}, }
], ],
isGET:[ isGET: [
{ {
value: '', value: '',
label: '' label: ''
...@@ -151,129 +151,129 @@ export default { ...@@ -151,129 +151,129 @@ export default {
{ {
value: '', value: '',
label: '' label: ''
}, }
], ],
formInline:{ formInline: {
model1:'', model1: '',
model2:'', model2: '',
Inviter:'', Inviter: '',
InviterPhoneNumber:'', InviterPhoneNumber: '',
date:'', date: '',
time:'', time: '',
position:'', position: '',
phoneNUmber:'', phoneNUmber: '',
name:'', name: ''
}, },
isV:false, isV: false,
hh:['01',"02","03","04","05","06","07","08","09","10","11","12"], hh: ['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12'],
mm:['00','10','20','30','40','50','60'] mm: ['00', '10', '20', '30', '40', '50', '60']
} }
}, },
methods:{ methods: {
// 确认提交 // 确认提交
confirmSubmission(){ confirmSubmission () {
if(this.formInline.model1==''||this.formInline.model2==''||this.formInline.Inviter==''||this.formInline.date==''||this.formInline.time===''||this.formInline.position==''||this.formInline.phoneNUmber==''||this.formInline.name==''){ if (this.formInline.model1 == '' || this.formInline.model2 == '' || this.formInline.Inviter == '' || this.formInline.date == '' || this.formInline.time === '' || this.formInline.position == '' || this.formInline.phoneNUmber == '' || this.formInline.name == '') {
this.$Message.error('请填写完整的信息') this.$Message.error('请填写完整的信息')
return return
} }
if(!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.phoneNUmber))){ if (!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.phoneNUmber))) {
this.$Message.error('请输入正确的手机号') this.$Message.error('请输入正确的手机号')
return return
} }
if(this.formInline.InviterPhoneNumber!==''&&!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))){ if (this.formInline.InviterPhoneNumber !== '' && !(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))) {
this.$Message.error('请输入正确的手机号') this.$Message.error('请输入正确的手机号')
return return
} }
let parmars={ const parmars = {
invitePerson:this.formInline.Inviter, invitePerson: this.formInline.Inviter,
inviterMobile:this.formInline.InviterPhoneNumber, inviterMobile: this.formInline.InviterPhoneNumber,
dateTime:moment(this.formInline.date).format('YYYY-MM-DD') + ' ' + this.formInline.time, dateTime: moment(this.formInline.date).format('YYYY-MM-DD') + ' ' + this.formInline.time,
interviewTitle:this.formInline.position, interviewTitle: this.formInline.position,
source:this.formInline.model1, source: this.formInline.model1,
name:this.formInline.name, name: this.formInline.name,
mobile:this.formInline.phoneNUmber, mobile: this.formInline.phoneNUmber,
takeResume:this.formInline.model2 takeResume: this.formInline.model2
} }
this.loading = true this.loading = true
submitMassage(parmars).then(res=>{ submitMassage(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.loading = false this.loading = false
this.formInline.model1='' this.formInline.model1 = ''
this.formInline.model2='' this.formInline.model2 = ''
this.formInline.Inviter='' this.formInline.Inviter = ''
this.formInline.InviterPhoneNumber='' this.formInline.InviterPhoneNumber = ''
this.formInline.time='' this.formInline.time = ''
this.formInline.position='' this.formInline.position = ''
this.formInline.name='' this.formInline.name = ''
this.formInline.phoneNUmber='' this.formInline.phoneNUmber = ''
this.modal4=true this.modal4 = true
} }
}) })
}, },
selectDate(a){ selectDate (a) {
this.formInline.date=a this.formInline.date = a
}, },
selectTime(b){ selectTime (b) {
this.formInline.time=b this.formInline.time = b
}, },
welconme(){ welconme () {
this.modal3=true this.modal3 = true
}, },
jedugePhone(){ jedugePhone () {
if(this.formInline.InviterPhoneNumber==''){ if (this.formInline.InviterPhoneNumber == '') {
this.isV=false this.isV = false
return return
} }
if(!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))){ if (!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))) {
this.isV=true this.isV = true
} }
if((/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))){ if ((/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.InviterPhoneNumber))) {
this.isV=false this.isV = false
} }
}, },
// 阻止弹出键盘 // 阻止弹出键盘
defaultRRRR(){ defaultRRRR () {
document.activeElement.blur() document.activeElement.blur()
}
}, },
}, mounted () {
mounted(){
this.welconme() this.welconme()
const myDate = new Date(); const myDate = new Date()
const year = myDate.getFullYear(); // 获取当前年份 const year = myDate.getFullYear() // 获取当前年份
const month = myDate.getMonth() + 1; // 获取当前月份(0-11,0代表1月所以要加1); const month = myDate.getMonth() + 1 // 获取当前月份(0-11,0代表1月所以要加1);
const day = myDate.getDate(); // 获取当前日(1-31) const day = myDate.getDate() // 获取当前日(1-31)
this.saleDate = `${year}/${month}/${day}`; this.saleDate = `${year}/${month}/${day}`
this.formInline.date=this.saleDate this.formInline.date = this.saleDate
function getRem() { function getRem () {
var html = document.getElementsByTagName("html")[0]; var html = document.getElementsByTagName('html')[0]
var oWidth = document.body.clientWidth || document.documentElement.clientWidth; var oWidth = document.body.clientWidth || document.documentElement.clientWidth
html.style.fontSize = oWidth / 7.5 + "px"; html.style.fontSize = oWidth / 7.5 + 'px'
} }
this.$nextTick(()=>{ this.$nextTick(() => {
getRem() getRem()
}) })
window.onresize = ()=>{ window.onresize = () => {
return(()=>{  return (() => {
getRem() getRem()
if (!this.isResize) {    if (!this.isResize) {
this.docmHeight=document.documentElement.clientHeight                               this.docmHeight = document.documentElement.clientHeight
 this.isResize = true                      this.isResize = true
 }                        }
this.showHeight = document.body.clientHeight          this.showHeight = document.body.clientHeight
})()    })()
} }
}, },
beforeDestroy() { beforeDestroy () {
document.getElementsByTagName("html")[0].removeAttribute("style"); document.getElementsByTagName('html')[0].removeAttribute('style')
}, },
watch :{ watch: {
showHeight:function() {  showHeight: function () {
if(this.docmHeight > this.showHeight){            if (this.docmHeight > this.showHeight) {
 this.hidshow=false        this.hidshow = false
}else{ } else {
this.hidshow=true     this.hidshow = true
}     }
} }
} }
} }
......
...@@ -16,32 +16,32 @@ ...@@ -16,32 +16,32 @@
</div> </div>
</template> </template>
<script> <script>
import {getErcode,downloadErcode} from '../../api/stystem.server.js' import { getErcode, downloadErcode } from '../../api/stystem.server.js'
import { import {
sapi sapi
} from '../../config' } from '../../config'
export default { export default {
data(){ data () {
return { return {
url:'', url: '',
url2:'' url2: ''
} }
}, },
methods:{ methods: {
//取到二维码 // 取到二维码
getercode(){ getercode () {
getErcode().then(res=>{ getErcode().then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.url=res.data.body this.url = res.data.body
} }
}) })
}, },
downPic (img) { downPic (img) {
window.location.href=`${sapi}/api/qrCode/downQrCode` window.location.href = `${sapi}/api/qrCode/downQrCode`
} }
}, },
mounted(){ mounted () {
this.getercode() this.getercode()
} }
} }
......
...@@ -124,325 +124,322 @@ ...@@ -124,325 +124,322 @@
</div> </div>
</template> </template>
<script> <script>
import { queryaccountList,addAccount,Delateaccount,delateAllAccount,recoveryPassword,updateAccount} from '../../api/stystem.server.js' import { queryaccountList, addAccount, Delateaccount, delateAllAccount, recoveryPassword, updateAccount } from '../../api/stystem.server.js'
export default { export default {
data(){ data () {
return { return {
modal1:false, modal1: false,
modal2:false, modal2: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
modal6:false, modal6: false,
checkboxList:[], checkboxList: [],
checked: false, checked: false,
updateAccountId:'', updateAccountId: '',
pageT:'', pageT: '',
userName:'', userName: '',
userCode:'', userCode: '',
Massage:'', Massage: '',
spinShow:true, spinShow: true,
delateARR:[], delateARR: [],
id:'', id: '',
I:'', I: '',
pageIndex:1, pageIndex: 1,
pageSize:30, pageSize: 30,
totalSize:null, totalSize: null,
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
id:'' id: ''
}, },
formInline: { formInline: {
PhoneNumber: '', PhoneNumber: '',
PerName: '', PerName: '',
emailNumber:'', emailNumber: '',
updatePhoneNumber: '', updatePhoneNumber: '',
updatePerName: '', updatePerName: '',
updateemailNumber:'' updateemailNumber: ''
}, },
ruleInline: { ruleInline: {
PhoneNumber: [ PhoneNumber: [
{ required: true, pattern:/^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' } { required: true, pattern: /^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' }
], ],
PerName: [ PerName: [
{ required: true, message: '请输入真实的姓名', trigger: 'blur' }, { required: true, message: '请输入真实的姓名', trigger: 'blur' },
{ type: 'string', message: '', trigger: 'blur' } { type: 'string', message: '', trigger: 'blur' }
], ],
updateemailNumber: [ updateemailNumber: [
{ required: true, pattern:/^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' } { required: true, pattern: /^[1][3,4,5,7,8,6,9][0-9]{9}$/, message: '请输入正确的手机号', trigger: 'blur' }
], ],
updatePerName: [ updatePerName: [
{ required: true, message: '请输入真实的姓名', trigger: 'blur' }, { required: true, message: '请输入真实的姓名', trigger: 'blur' },
{ type: 'string', message: '', trigger: 'blur' } { type: 'string', message: '', trigger: 'blur' }
], ],
emailNumber: [ emailNumber: [
{ required: true, pattern:/\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' } { required: true, pattern: /\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' }
], ]
}, },
ajaxData:[], ajaxData: [],
checkData: [] ,// 双向数据绑定的数组 checkData: [] // 双向数据绑定的数组
} }
}, },
methods:{ methods: {
handleSelectAll (status) { handleSelectAll (status) {
this.$refs.selection.selectAll(status); this.$refs.selection.selectAll(status)
}, },
ok () { ok () {
this.$Message.info('Clicked ok'); this.$Message.info('Clicked ok')
}, },
cancel () { cancel () {
this.$Message.info('Clicked cancel'); this.$Message.info('Clicked cancel')
}, },
// //
delateArr(DElateID){ delateArr (DElateID) {
this.delateARR.push(DElateID) this.delateARR.push(DElateID)
}, },
//全选与反选 // 全选与反选
checkedAll: function() { checkedAll: function () {
if (this.checked) {//实现反选 if (this.checked) { // 实现反选
this.checkboxList = []; this.checkboxList = []
this.checkboxList.push(item.id) this.checkboxList.push(item.id)
this.delateARR.push(item.id) this.delateARR.push(item.id)
} else { //实现全选 } else { // 实现全选
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.checkboxList.push(item.id); this.checkboxList.push(item.id)
this.delateARR.push(item.id) this.delateARR.push(item.id)
}); })
} }
}, },
// 修改 // 修改
updateModal(item){ updateModal (item) {
this.modal6=true this.modal6 = true
this.updateAccountId=item.id this.updateAccountId = item.id
this.formInline.updateemailNumber=item.userCode this.formInline.updateemailNumber = item.userCode
this.formInline.updatePhoneNumber=item.phone this.formInline.updatePhoneNumber = item.phone
this.formInline.updatePerName=item.userName this.formInline.updatePerName = item.userName
}, },
// 确认修改 // 确认修改
confireUpdate(){ confireUpdate () {
let parmars={ const parmars = {
id:this.updateAccountId, id: this.updateAccountId,
userCode:this.formInline.updateemailNumber, userCode: this.formInline.updateemailNumber,
userName:this.formInline.updatePerName, userName: this.formInline.updatePerName,
phone:this.formInline.updatePhoneNumber phone: this.formInline.updatePhoneNumber
} }
if(this.formInline.updatePhoneNumber==''||this.formInline.updatePerName==''){ if (this.formInline.updatePhoneNumber == '' || this.formInline.updatePerName == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写正确的手机号码或姓名', desc: '请您填写正确的手机号码或姓名',
duration:2 duration: 2
}); })
return return
} }
if(!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.updatePhoneNumber))){ if (!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.updatePhoneNumber))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写正确的手机号', desc: '请您填写正确的手机号',
duration:2 duration: 2
}); })
return return
} }
updateAccount(parmars).then(res=>{ updateAccount(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '修改成功', desc: '修改成功',
duration:2 duration: 2
}); })
this.modal6=false this.modal6 = false
this.SearchList() this.SearchList()
} }
if(res.data.success==false){ if (res.data.success == false) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: res.data.body.message, desc: res.data.body.message,
duration:2 duration: 2
}); })
this.modal6=false this.modal6 = false
} }
}) })
}, },
//添加账户 // 添加账户
addacount(){ addacount () {
let parmars={ const parmars = {
userCode:this.formInline.emailNumber, userCode: this.formInline.emailNumber,
userName:this.formInline.PerName, userName: this.formInline.PerName,
phone:this.formInline.PhoneNumber phone: this.formInline.PhoneNumber
} }
if(this.formInline.PhoneNumber==''||this.formInline.PerName==''||this.formInline.emailNumber==''){ if (this.formInline.PhoneNumber == '' || this.formInline.PerName == '' || this.formInline.emailNumber == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写正确的账号或姓名', desc: '请您填写正确的账号或姓名',
duration:2 duration: 2
}); })
return return
} }
if(!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.PhoneNumber))){ if (!(/^[1][3,4,5,7,8,6,9][0-9]{9}$/.test(this.formInline.PhoneNumber))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写正确的手机号', desc: '请您填写正确的手机号',
duration:2 duration: 2
}); })
return return
} }
if(!(/\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/.test(this.formInline.emailNumber))){ if (!(/\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/.test(this.formInline.emailNumber))) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写正确邮箱账号', desc: '请您填写正确邮箱账号',
duration:2 duration: 2
}); })
return return
} }
addAccount(parmars).then(res=>{ addAccount(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '添加成功', desc: '添加成功',
duration:2 duration: 2
}); })
this.SearchList() this.SearchList()
this.formInline.PhoneNumber='' this.formInline.PhoneNumber = ''
this.formInline.PerName='' this.formInline.PerName = ''
this.formInline.emailNumber='' this.formInline.emailNumber = ''
} }
if(res.data.body.code==0){ if (res.data.body.code == 0) {
this.Massage=res.data.body.message this.Massage = res.data.body.message
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc:this.Massage, desc: this.Massage,
duration:2 duration: 2
}); })
this.formInline.PhoneNumber='' this.formInline.PhoneNumber = ''
this.formInline.PerName='' this.formInline.PerName = ''
this.formInline.emailNumber='' this.formInline.emailNumber = ''
return
} }
}) })
},
} , // 查询账户列表
//查询账户列表 SearchList (page) {
SearchList(page){ page = typeof (page) === 'number' ? page : 1
page = typeof(page)=='number'?page:1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex
} }
queryaccountList(parmars).then(res=>{ queryaccountList(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.spinShow=false this.spinShow = false
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.ajaxData=res.data.body.items.map((item,index)=>{ this.ajaxData = res.data.body.items.map((item, index) => {
item.id=item.id item.id = item.id
item.userName=item.userName item.userName = item.userName
item.userCode=item.userCode item.userCode = item.userCode
item.createTime=item.createTime item.createTime = item.createTime
return item return item
}) })
} }
}) })
}, },
//删除单条账户弹框 // 删除单条账户弹框
delateMaodal(DID){ delateMaodal (DID) {
this.I=DID this.I = DID
this.modal2=true this.modal2 = true
}, },
//删除单条账户 // 删除单条账户
delateAccount(){ delateAccount () {
let parmars={ const parmars = {
id:this.I id: this.I
} }
Delateaccount(parmars).then(res=>{ Delateaccount(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal2=false this.modal2 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
} }
this.SearchList(this.pageT) this.SearchList(this.pageT)
}) })
}, },
// 批量删除弹出框 // 批量删除弹出框
delateall(){ delateall () {
if(this.checkboxList.length==0||this.delateArr.length==0){ if (this.checkboxList.length == 0 || this.delateArr.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空', desc: '选项不能为空',
duration:'2' duration: '2'
}); })
return return
} }
this.modal3=true this.modal3 = true
}, },
//批量删除账户 // 批量删除账户
delateAll(){ delateAll () {
delateAllAccount(this.delateARR).then(res=>{ delateAllAccount(this.delateARR).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '删除成功', desc: '删除成功',
duration:'2' duration: '2'
}); })
this.modal3=false this.modal3 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
} }
}) })
}, },
//恢复初始密码弹窗 // 恢复初始密码弹窗
recoveryModal(ID){ recoveryModal (ID) {
this.I=ID this.I = ID
this.modal1=true this.modal1 = true
}, },
//确认恢复初始密码 // 确认恢复初始密码
recovery(){ recovery () {
let parmars={ const parmars = {
id:this.I id: this.I
} }
recoveryPassword(parmars).then(res=>{ recoveryPassword(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '恢复密码成功', desc: '恢复密码成功',
duration:'2' duration: '2'
}); })
this.modal1=false this.modal1 = false
} }
}) })
}, },
//改变页码 // 改变页码
pageChange(page){ pageChange (page) {
this.pageT=page this.pageT = page
this.SearchList(page) this.SearchList(page)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.SearchList() this.SearchList()
}, }
}, },
watch: { watch: {
checkboxList: { checkboxList: {
handler: function (val, oldVal) { handler: function (val, oldVal) {
if(this.ajaxData.length==0){ if (this.ajaxData.length == 0) {
this.checked=false this.checked = false
return return
} }
if (this.checkboxList.length === this.ajaxData.length) { if (this.checkboxList.length === this.ajaxData.length) {
this.checked=true; this.checked = true
} else { } else {
this.checked=false; this.checked = false
} }
}, },
deep: true deep: true
} }
}, },
mounted(){ mounted () {
this.SearchList() this.SearchList()
} }
} }
</script> </script>
<style scoped> <style scoped>
......
...@@ -132,289 +132,288 @@ ...@@ -132,289 +132,288 @@
</div> </div>
</template> </template>
<script> <script>
import { queryemailList,Synchronization,jiebangEmail,updateemailTWO,UntyingAll} from '../../api/stystem.server.js' import { queryemailList, Synchronization, jiebangEmail, updateemailTWO, UntyingAll } from '../../api/stystem.server.js'
import moment from 'moment' import moment from 'moment'
export default { export default {
data(){ data () {
return { return {
modal1:false, modal1: false,
modal2:false, modal2: false,
modal3:false, modal3: false,
modal4:false, modal4: false,
modal5:false, modal5: false,
modal6:false, modal6: false,
condition:'', condition: '',
Massage:'', Massage: '',
pageT:'', pageT: '',
spinShow:true, spinShow: true,
idAdmin:'', idAdmin: '',
admin:'', admin: '',
NAme:"", NAme: '',
DATA:"", DATA: '',
Tname:'', Tname: '',
options3: { options3: {
disabledDate (date) { disabledDate (date) {
return date && date.valueOf() > Date.now()|| date.valueOf()<Date.now()-3600*1000*30*24; return date && date.valueOf() > Date.now() || date.valueOf() < Date.now() - 3600 * 1000 * 30 * 24
} }
}, },
UpassWord:'', UpassWord: '',
Uusername:'', Uusername: '',
decisionStartTime:'', decisionStartTime: '',
Ublengs:'', Ublengs: '',
Uid:'', Uid: '',
UntyingAllARR:[], UntyingAllARR: [],
Tblengs:'', Tblengs: '',
checkboxList:[], checkboxList: [],
checked: false, checked: false,
disabled:false, disabled: false,
pageIndex:1, pageIndex: 1,
pageSize:30, pageSize: 30,
totalSize:null, totalSize: null,
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1,
id:'', id: ''
}, },
formInline: { formInline: {
emailNumber: '', emailNumber: '',
emailPsd: '', emailPsd: '',
UserName:'' UserName: ''
}, },
ruleInline: { ruleInline: {
emailNumber: [ emailNumber: [
// derong.zhang@quantgroup.cn // derong.zhang@quantgroup.cn
{ required: true, pattern:/\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' } { required: true, pattern: /\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\.)+[A-Za-z]{2,14}/, message: '请输入正确的邮箱账号', trigger: 'blur' }
], ],
emailPsd: [ emailPsd: [
{ required: true, message: '请输入正确的密码', trigger: 'blur' }, { required: true, message: '请输入正确的密码', trigger: 'blur' }
], ],
UserName:[ UserName: [
{ required: true, message: '请输入正确的姓名', trigger: 'blur' }, { required: true, message: '请输入正确的姓名', trigger: 'blur' }
] ]
}, },
ajaxData: [], ajaxData: [],
checkData: [] ,// 双向数据绑定的数组 checkData: [] // 双向数据绑定的数组
} }
}, },
methods:{ methods: {
//全选与反选 // 全选与反选
checkedAll: function() { checkedAll: function () {
if (this.checked) {//实现反选 if (this.checked) { // 实现反选
this.checkboxList = []; this.checkboxList = []
} else { //实现全选 } else { // 实现全选
this.checkboxList = []; this.checkboxList = []
this.ajaxData.forEach( (item) => { this.ajaxData.forEach((item) => {
this.checkboxList.push(item.id); this.checkboxList.push(item.id)
this.UntyingAllARR.push(item.id) this.UntyingAllARR.push(item.id)
}); })
} }
}, },
//绑定同步邮箱 // 绑定同步邮箱
bindingSynchronizat(){ bindingSynchronizat () {
if(this.formInline.emailNumber==''||this.formInline.emailPsd==''||this.formInline.UserName==''||this.DATA==''){ if (this.formInline.emailNumber == '' || this.formInline.emailPsd == '' || this.formInline.UserName == '' || this.DATA == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写完整的信息', desc: '请您填写完整的信息',
duration:'2' duration: '2'
}); })
return return
} }
this.disabled=true this.disabled = true
this.modal3=true this.modal3 = true
let parmars={ const parmars = {
emailName:this.formInline.emailNumber, emailName: this.formInline.emailNumber,
emailPassword:this.formInline.emailPsd, emailPassword: this.formInline.emailPsd,
belongs:this.formInline.UserName, belongs: this.formInline.UserName,
syncStartDate:moment(this.DATA).format('YYYY-MM-DD HH:mm:ss') syncStartDate: moment(this.DATA).format('YYYY-MM-DD HH:mm:ss')
} }
Synchronization(parmars).then(res=>{ Synchronization(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal3=false this.modal3 = false
this.modal2=true this.modal2 = true
this.formInline.emailNumber='' this.formInline.emailNumber = ''
this.formInline.emailPsd='' this.formInline.emailPsd = ''
this.formInline.UserName='' this.formInline.UserName = ''
this.DATA='' this.DATA = ''
this.SearchList() this.SearchList()
// this.disabled=false // this.disabled=false
} }
if(res.data.success==false){ if (res.data.success == false) {
this.modal3=false this.modal3 = false
this.disabled=false this.disabled = false
this.Massage=res.data.body.message this.Massage = res.data.body.message
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: this.Massage, desc: this.Massage,
duration:2 duration: 2
}); })
} }
},()=>{ }, () => {
this.modal3=false this.modal3 = false
// this.modal1=true // this.modal1=true
this.formInline.emailPsd='' this.formInline.emailPsd = ''
}) })
}, },
iKnow(){ iKnow () {
this.modal2=false, this.modal2 = false,
this.disabled=false this.disabled = false
}, },
//选择同步的时间 // 选择同步的时间
selectTime(b){ selectTime (b) {
this.DATA=b this.DATA = b
}, },
//查询邮箱列表 // 查询邮箱列表
SearchList(page){ SearchList (page) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex
} }
queryemailList(parmars).then(res=>{ queryemailList(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.spinShow=false this.spinShow = false
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.ajaxData=res.data.body.items.map((item,index)=>{ this.ajaxData = res.data.body.items.map((item, index) => {
item.syncStartDate=item.syncStartDate item.syncStartDate = item.syncStartDate
item.syncFlag=item.syncFlag item.syncFlag = item.syncFlag
item.createTime=item.createTime item.createTime = item.createTime
item.belongs=item.belongs item.belongs = item.belongs
item.emailName=item.emailName item.emailName = item.emailName
item.id=item.id item.id = item.id
item.STA=false item.STA = false
item.syncFlag=item.syncFlag item.syncFlag = item.syncFlag
item.syncMailMsg=item.syncMailMsg item.syncMailMsg = item.syncMailMsg
item.c= item.syncMailMsg==null? item.syncMailMsg:item.syncMailMsg.substring(0,2) item.c = item.syncMailMsg == null ? item.syncMailMsg : item.syncMailMsg.substring(0, 2)
return item return item
}) })
} }
}) })
}, },
//改变页码 // 改变页码
pageChange(page){ pageChange (page) {
this.pageT=page this.pageT = page
this.SearchList(page) this.SearchList(page)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.SearchList() this.SearchList()
}, },
// 修改邮箱弹出框 // 修改邮箱弹出框
UpdateEMAIL(Tname,Tblengs,Tid){ UpdateEMAIL (Tname, Tblengs, Tid) {
this.modal4=true this.modal4 = true
this.Uusername=Tname this.Uusername = Tname
this.Ublengs=Tblengs this.Ublengs = Tblengs
this.Uid=Tid this.Uid = Tid
}, },
// 修改后重新绑定邮箱并保存 // 修改后重新绑定邮箱并保存
UpdateemailTwo(){ UpdateemailTwo () {
if(this.UpassWord==''||this.Uusername==''||this.Ublengs==''){ if (this.UpassWord == '' || this.Uusername == '' || this.Ublengs == '') {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您填写完整的信息', desc: '请您填写完整的信息',
duration:'2' duration: '2'
}); })
return return
} }
let parmars={ const parmars = {
emailName:this.Uusername, emailName: this.Uusername,
emailPassword:this.UpassWord, emailPassword: this.UpassWord,
belongs:this.Ublengs, belongs: this.Ublengs,
id:this.Uid id: this.Uid
} }
updateemailTWO(parmars).then(res=>{ updateemailTWO(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.UpassWord='' this.UpassWord = ''
this.modal4=false this.modal4 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '修改成功', desc: '修改成功',
duration:'2' duration: '2'
}); })
}else{ } else {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '你填写的密码有误', desc: '你填写的密码有误',
duration:'2' duration: '2'
}); })
this.UpassWord='' this.UpassWord = ''
} }
}) })
}, },
//解绑弹出框 // 解绑弹出框
UnbindingModal(Eid){ UnbindingModal (Eid) {
this.NAme=Eid, this.NAme = Eid,
this.modal5=true this.modal5 = true
}, },
//确认解绑邮箱 // 确认解绑邮箱
Unbinding(){ Unbinding () {
jiebangEmail(this.NAme).then(res=>{ jiebangEmail(this.NAme).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '解绑成功', desc: '解绑成功',
duration:2 duration: 2
}); })
this.modal5=false this.modal5 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
} }
}) })
}, },
//批量解绑弹出框 // 批量解绑弹出框
UntyingAllmodeal(){ UntyingAllmodeal () {
if(this.UntyingAllARR.length==0){ if (this.UntyingAllARR.length == 0) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '选项不能为空', desc: '选项不能为空',
duration:2 duration: 2
}); })
return return
} }
this.modal6=true this.modal6 = true
}, },
// 选择批量解绑的项 // 选择批量解绑的项
selectUntyingEle(id){ selectUntyingEle (id) {
this.UntyingAllARR.push(id) this.UntyingAllARR.push(id)
}, },
// 批量解绑邮箱 // 批量解绑邮箱
UntyingAll(){ UntyingAll () {
UntyingAll(this.UntyingAllARR).then(res=>{ UntyingAll(this.UntyingAllARR).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.$Notice.success({ this.$Notice.success({
title: '提示', title: '提示',
desc: '解绑成功', desc: '解绑成功',
duration:2 duration: 2
}); })
this.modal6=false this.modal6 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
} }
}) })
}, },
pushlist(){ pushlist () {
this.modal2=false this.modal2 = false
this.SearchList(this.pageT) this.SearchList(this.pageT)
}, },
pushlistModal6(){ pushlistModal6 () {
this.modal6=false this.modal6 = false
this.UntyingAllARR=[] this.UntyingAllARR = []
this.SearchList(this.pageT) this.SearchList(this.pageT)
}, },
isadminmethods(){ isadminmethods () {
this.admin=localStorage.getItem('isADMIN') this.admin = localStorage.getItem('isADMIN')
let c=JSON.parse(this.admin) const c = JSON.parse(this.admin)
this.idAdmin=c.isAdmin this.idAdmin = c.isAdmin
}, },
updatapassT(){ updatapassT () {
this.modal4=false this.modal4 = false
this.UpassWord='' this.UpassWord = ''
}, },
changeStartTime: function (e,b) { changeStartTime: function (e, b) {
this.DATA=b this.DATA = b
var time = e var time = e
var that = this var that = this
var days = new Date(new Date().getFullYear(), (new Date().getMonth() + 1), 0).getDate() - 1 var days = new Date(new Date().getFullYear(), (new Date().getMonth() + 1), 0).getDate() - 1
...@@ -443,21 +442,20 @@ export default { ...@@ -443,21 +442,20 @@ export default {
checkboxList: { checkboxList: {
handler: function (val, oldVal) { handler: function (val, oldVal) {
if (this.checkboxList.length === this.ajaxData.length) { if (this.checkboxList.length === this.ajaxData.length) {
this.checked=true; this.checked = true
} else { } else {
this.checked=false; this.checked = false
} }
}, },
deep: true deep: true
} }
}, },
mounted(){ mounted () {
this.isadminmethods() this.isadminmethods()
this.SearchList() this.SearchList()
} }
} }
</script> </script>
<style> <style>
......
...@@ -207,68 +207,68 @@ ...@@ -207,68 +207,68 @@
</div> </div>
</template> </template>
<script> <script>
import {getuploadNumber,uploadfile,serchList,serchRESUMEdetail,deleteREsumeUPLOad} from '../../api/upload.server' import { getuploadNumber, uploadfile, serchList, serchRESUMEdetail, deleteREsumeUPLOad } from '../../api/upload.server'
import { import {
sapi sapi
} from '../../config' } from '../../config'
import {uploadFile} from '../../service/ajax' import { uploadFile } from '../../service/ajax'
export default { export default {
data () { data () {
return { return {
uploadList: [], uploadList: [],
dataList: [], dataList: [],
fileName: '', fileName: '',
ajaxData:[], ajaxData: [],
delateARRALL:[], delateARRALL: [],
replaceArr: [], replaceArr: [],
downloadId:'', downloadId: '',
pageIndex:1, pageIndex: 1,
pageSize:30, pageSize: 30,
isReplace: true, isReplace: true,
newArr: [], newArr: [],
replaceName:'', replaceName: '',
searchInfo:{ searchInfo: {
pageSize:30, pageSize: 30,
pageIndex:1, pageIndex: 1
}, },
Sid:'', Sid: '',
single: true, single: true,
checkboxList: [], checkboxList: [],
filetile:'上传中请稍后...', filetile: '上传中请稍后...',
totalSize:null, totalSize: null,
uploadModal: false, uploadModal: false,
accept: '.doc,.docx,.pdf', accept: '.doc,.docx,.pdf',
fileSize:2048, fileSize: 2048,
progressStatus: { progressStatus: {
'0': 'active', 0: 'active',
'2': 'wrong', 2: 'wrong',
'1': 'wrong', 1: 'wrong'
}, },
files: null, files: null,
activeT:false, activeT: false,
change:false, change: false,
massage:'', massage: '',
Massage:'', Massage: '',
Code:'', Code: '',
action: `${sapi}/api/resume/upload`, action: `${sapi}/api/resume/upload`,
batchNum: '', batchNum: '',
modal3:false, modal3: false,
modal1:false, modal1: false,
modal2:false, modal2: false,
modal6:false, modal6: false,
Filename:'', Filename: '',
uploadNUmber:'', uploadNUmber: '',
// uploadList:[], // uploadList:[],
a:[], a: [],
files:null, files: null,
b:'', b: '',
uploadFile: [], uploadFile: [],
resume:{},//简历基本详情 resume: {}, // 简历基本详情
riList:[],//实习经历列表 riList: [], // 实习经历列表
roList:[],//工作经历列表 roList: [], // 工作经历列表
rpList:[],//项目经历列表 rpList: [], // 项目经历列表
reList:[],//教育经历列表 reList: [], // 教育经历列表
serchID:'' serchID: ''
} }
}, },
...@@ -276,44 +276,44 @@ import {uploadFile} from '../../service/ajax' ...@@ -276,44 +276,44 @@ import {uploadFile} from '../../service/ajax'
handleChange (e) { handleChange (e) {
this.fileName = '' this.fileName = ''
this.dataList = [] this.dataList = []
const files = e.target.files; const files = e.target.files
this.files = e.target.files this.files = e.target.files
for (let key in files){ for (const key in files) {
if (key!='length' && key!='item'){ if (key != 'length' && key != 'item') {
let file = files[key] const file = files[key]
let temp = { const temp = {
name: file.name, name: file.name,
data: file, data: file,
percentage: 0, percentage: 0,
type: file.type, type: file.type,
size: file.size, size: file.size,
title:null, title: null,
status: "active" status: 'active'
} }
this.dataList.push(temp) this.dataList.push(temp)
this.fileName += files[key].name + ';' this.fileName += files[key].name + ';'
} }
} }
if (!files) { if (!files) {
return; return
} }
this.$refs.input.value = null; this.$refs.input.value = null
}, },
uploadBtn() { uploadBtn () {
if (this.dataList.length < 1) { if (this.dataList.length < 1) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '请您选择文件在上传', desc: '请您选择文件在上传',
duration:2 duration: 2
}); })
return return
} }
if (this.dataList.length > 20){ if (this.dataList.length > 20) {
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '批量上传文件不能大于20份', desc: '批量上传文件不能大于20份',
duration:2 duration: 2
}); })
this.$refs.input.value = '' this.$refs.input.value = ''
this.fileName = '' this.fileName = ''
this.dataList = [] this.dataList = []
...@@ -323,15 +323,15 @@ import {uploadFile} from '../../service/ajax' ...@@ -323,15 +323,15 @@ import {uploadFile} from '../../service/ajax'
this.$Notice.error({ this.$Notice.error({
title: '提示', title: '提示',
desc: '单份文件不能大于2MB', desc: '单份文件不能大于2MB',
duration:2 duration: 2
}); })
this.$refs.input.value = '' this.$refs.input.value = ''
this.fileName = '' this.fileName = ''
this.dataList = [] this.dataList = []
return return
} }
this.uploadModal = true this.uploadModal = true
this.filetile='上传中请稍后...' this.filetile = '上传中请稍后...'
uploadFile({ uploadFile({
headers: this.headers, headers: this.headers,
data: this.dataList, data: this.dataList,
...@@ -342,26 +342,26 @@ import {uploadFile} from '../../service/ajax' ...@@ -342,26 +342,26 @@ import {uploadFile} from '../../service/ajax'
appendFile: 'recFile', appendFile: 'recFile',
onProgress: e => { onProgress: e => {
setTimeout(() => { setTimeout(() => {
this.handleProgress(e); this.handleProgress(e)
}, 200) }, 200)
}, },
onSuccess: res => { onSuccess: res => {
setTimeout(() => { setTimeout(() => {
this.handleSuccess(res, this.files); this.handleSuccess(res, this.files)
this.activeT=true this.activeT = true
}, 1000) }, 1000)
}, },
onError: (err, response) => { onError: (err, response) => {
this.handleError(err, response, this.files); this.handleError(err, response, this.files)
} }
}) })
}, },
handleProgress(e) { handleProgress (e) {
this.dataList.map(item => { this.dataList.map(item => {
item.percentage = e.percent-5 item.percentage = e.percent - 5
}) })
}, },
selectfile (data,name) { selectfile (data, name) {
this.replaceName = name this.replaceName = name
if (data == false) { if (data == false) {
this.replaceArr = this.replaceArr.filter(item => item !== this.replaceName) this.replaceArr = this.replaceArr.filter(item => item !== this.replaceName)
...@@ -370,23 +370,23 @@ import {uploadFile} from '../../service/ajax' ...@@ -370,23 +370,23 @@ import {uploadFile} from '../../service/ajax'
} }
}, },
handleSuccess (res, files) { handleSuccess (res, files) {
let data = res.body const data = res.body
this.filetile='上传完成' this.filetile = '上传完成'
for(let key in data){ for (const key in data) {
let code = data[key].code const code = data[key].code
this.Code=data[key].code this.Code = data[key].code
this.Massage=data[key].message this.Massage = data[key].message
if (data[key].code==1 ){ if (data[key].code == 1) {
this.replaceArr.push(key) this.replaceArr.push(key)
} }
this.dataList.map(item => { this.dataList.map(item => {
item.sStatus=true item.sStatus = true
if (key == item.name) { if (key == item.name) {
item.title = this.Massage item.title = this.Massage
if(item.Code==2){progressStatus={'2':'wrong'}} if (item.Code == 2) { progressStatus = { 2: 'wrong' } }
item.status = this.progressStatus[code] item.status = this.progressStatus[code]
item.Code=this.Code item.Code = this.Code
item.percentage=100 item.percentage = 100
} }
}) })
} }
...@@ -397,9 +397,8 @@ import {uploadFile} from '../../service/ajax' ...@@ -397,9 +397,8 @@ import {uploadFile} from '../../service/ajax'
handleMaxSize () { handleMaxSize () {
let isLimit = false let isLimit = false
this.dataList.map(item => { this.dataList.map(item => {
if (item.size/1024 > this.fileSize) { if (item.size / 1024 > this.fileSize) {
isLimit = true isLimit = true
return
} }
}) })
return isLimit return isLimit
...@@ -407,111 +406,111 @@ import {uploadFile} from '../../service/ajax' ...@@ -407,111 +406,111 @@ import {uploadFile} from '../../service/ajax'
selFiles () { selFiles () {
this.$refs.input.click() this.$refs.input.click()
}, },
closeModal(){ closeModal () {
this.uploadModal = false this.uploadModal = false
this.$refs.input.value = '' this.$refs.input.value = ''
this.dataList = [] this.dataList = []
// this.replaceArr = [] // this.replaceArr = []
this.fileName = '' this.fileName = ''
this.activeT=false this.activeT = false
this.filetile='上传中请稍后...' this.filetile = '上传中请稍后...'
this.serchlist() this.serchlist()
}, },
//下载单条简历 // 下载单条简历
downloadONE(downID){ downloadONE (downID) {
window.location.href=`${sapi}/api/resume/download/formatted/one?resumeId=${downID}` window.location.href = `${sapi}/api/resume/download/formatted/one?resumeId=${downID}`
}, },
// 获取上传批次号 // 获取上传批次号
getnumber(){ getnumber () {
return getuploadNumber().then(res=>{ return getuploadNumber().then(res => {
this.batchNum= res.data.body this.batchNum = res.data.body
}) })
}, },
//改变页码 // 改变页码
pageChange(page){ pageChange (page) {
this.SearchList(page) this.SearchList(page)
}, },
pageSizeChange(page){ pageSizeChange (page) {
this.searchInfo.pageSize=page this.searchInfo.pageSize = page
this.pageSize=page this.pageSize = page
this.SearchList() this.SearchList()
}, },
// 查询记录列表 // 查询记录列表
serchlist(page){ serchlist (page) {
page = typeof(page)=='number'?page:1 page = typeof (page) === 'number' ? page : 1
this.searchInfo.pageIndex = page this.searchInfo.pageIndex = page
this.pageIndex = page this.pageIndex = page
let parmars={ const parmars = {
pageSize:this.searchInfo.pageSize, pageSize: this.searchInfo.pageSize,
pageIndex:this.searchInfo.pageIndex, pageIndex: this.searchInfo.pageIndex,
parameter: { parameter: {
batchNum:this.batchNum, batchNum: this.batchNum,
replaceFileNameList: this.replaceArr replaceFileNameList: this.replaceArr
} }
} }
serchList(parmars).then(res=>{ serchList(parmars).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.replaceArr = [] this.replaceArr = []
this.totalSize=res.data.body.totalNumber this.totalSize = res.data.body.totalNumber
this.ajaxData=res.data.body.items.map((item,index)=>{ this.ajaxData = res.data.body.items.map((item, index) => {
item.resumeId=item.resumeId item.resumeId = item.resumeId
item.name=item.name item.name = item.name
item.mobile=item.mobile item.mobile = item.mobile
item.age=item.age item.age = item.age
item.gender=item.gender item.gender = item.gender
item.workYears=item.workYears item.workYears = item.workYears
item.degree=item.degree item.degree = item.degree
item.expectedTitle=item.expectedTitle item.expectedTitle = item.expectedTitle
item.status=item.status item.status = item.status
item.uid=item.uid item.uid = item.uid
item.creator=item.creator==''?item.creator:item.creator.split('_')[0] item.creator = item.creator == '' ? item.creator : item.creator.split('_')[0]
item.createTime=item.createTime item.createTime = item.createTime
return item return item
}) })
} }
}) })
}, },
// 获取简历详情页数据 // 获取简历详情页数据
getResumeData(sid,Uid){ getResumeData (sid, Uid) {
this.downloadId=sid this.downloadId = sid
let parmars={ const parmars = {
uid:Uid uid: Uid
} }
serchRESUMEdetail(parmars).then(res=>{ serchRESUMEdetail(parmars).then(res => {
this.resume=res.data.body.resume this.resume = res.data.body.resume
this.riList=res.data.body.riList this.riList = res.data.body.riList
this.roList=res.data.body.roList this.roList = res.data.body.roList
this.reList=res.data.body.reList this.reList = res.data.body.reList
this.rpList=res.data.body.rpList this.rpList = res.data.body.rpList
}) })
}, },
// 删除提示 // 删除提示
delateONEModal(vid){ delateONEModal (vid) {
this.Sid=vid this.Sid = vid
this.modal6=true this.modal6 = true
}, },
// 删除单条简历 // 删除单条简历
delateONE(){ delateONE () {
this.delateARRALL.push(this.Sid) this.delateARRALL.push(this.Sid)
deleteREsumeUPLOad(this.delateARRALL).then(res=>{ deleteREsumeUPLOad(this.delateARRALL).then(res => {
if(res.data.success==true){ if (res.data.success == true) {
this.modal6=false this.modal6 = false
this.resume={} this.resume = {}
this.riList=[] this.riList = []
this.roList=[] this.roList = []
this.rpList=[] this.rpList = []
this.reList=[] this.reList = []
this.downloadId='' this.downloadId = ''
this.serchlist() this.serchlist()
} }
}) })
}
}, },
}, async mounted () {
async mounted(){
await this.getnumber() await this.getnumber()
this.serchlist() this.serchlist()
} }
} }
</script> </script>
<style lang='less' scoped> <style lang='less' scoped>
.upload{ .upload{
......
import Vue from 'vue'; import Vue from 'vue'
import Router from 'vue-router'; import Router from 'vue-router'
const home = r => require.ensure([], () => r(require('@/components/home.vue')), 'home'); const home = r => require.ensure([], () => r(require('@/components/home.vue')), 'home')
// const changepsd = r => require.ensure([], () => r(require('@/components/changepsd.vue')), 'changepsd'); // const changepsd = r => require.ensure([], () => r(require('@/components/changepsd.vue')), 'changepsd');
const login = r => require.ensure([], () => r(require('@/page/login/login.vue')), 'login'); const login = r => require.ensure([], () => r(require('@/page/login/login.vue')), 'login')
const update = r => require.ensure([], () => r(require('@/page/login/update.vue')), 'update'); const update = r => require.ensure([], () => r(require('@/page/login/update.vue')), 'update')
const pdfdetail = r =>require.ensure([], () => r(require('@/page/resume/pdfdetail.vue')),'pdfdetail') const pdfdetail = r => require.ensure([], () => r(require('@/page/resume/pdfdetail.vue')), 'pdfdetail')
const resumeDetail = r =>require.ensure([], () => r(require('@/page/resume/resumeDetail.vue')),'resumeDetail') const resumeDetail = r => require.ensure([], () => r(require('@/page/resume/resumeDetail.vue')), 'resumeDetail')
const interview = r => require.ensure([], () => r(require('@/page/interview/interview.vue')), 'interview'); const interview = r => require.ensure([], () => r(require('@/page/interview/interview.vue')), 'interview')
const allResume = r => require.ensure([], () => r(require('@/page/resume/allResume.vue')), 'allResume'); const allResume = r => require.ensure([], () => r(require('@/page/resume/allResume.vue')), 'allResume')
const channel = r => require.ensure([], () => r(require('@/page/resume/channel.vue')), 'channel'); const channel = r => require.ensure([], () => r(require('@/page/resume/channel.vue')), 'channel')
const account = r => require.ensure([], () => r(require('@/page/system/account.vue')), 'account'); const account = r => require.ensure([], () => r(require('@/page/system/account.vue')), 'account')
const emailMange = r => require.ensure([], () => r(require('@/page/system/emailMange.vue')), 'emailMange'); const emailMange = r => require.ensure([], () => r(require('@/page/system/emailMange.vue')), 'emailMange')
const QRcode = r => require.ensure([], () => r(require('@/page/system/QRcode.vue')), 'QRcode'); const QRcode = r => require.ensure([], () => r(require('@/page/system/QRcode.vue')), 'QRcode')
const upload = r => require.ensure([], () => r(require('@/page/upload/upload.vue')), 'upload'); const upload = r => require.ensure([], () => r(require('@/page/upload/upload.vue')), 'upload')
const sweepCode = r => require.ensure([], () => r(require('@/page/sweepCode/sweepCode.vue')), 'sweepCode'); const sweepCode = r => require.ensure([], () => r(require('@/page/sweepCode/sweepCode.vue')), 'sweepCode')
const editor = r => require.ensure([], () => r(require('@/components/editor.vue')), 'editor'); const editor = r => require.ensure([], () => r(require('@/components/editor.vue')), 'editor')
const getimage = r => require.ensure([], () => r(require('@/components/getimage.vue')), 'getimage'); const getimage = r => require.ensure([], () => r(require('@/components/getimage.vue')), 'getimage')
//z注释 // z注释
Vue.use(Router); Vue.use(Router)
export default new Router({ export default new Router({
mode: 'history', mode: 'history',
routes: [ routes: [
{ {
path: '/', path: '/',
redirect: '/home', redirect: '/home'
}, { }, {
path: '/login', path: '/login',
name: 'login', name: 'login',
...@@ -36,19 +36,19 @@ export default new Router({ ...@@ -36,19 +36,19 @@ export default new Router({
} }
}, },
{ {
path:'/sweepCode', path: '/sweepCode',
name:'sweepCode', name: 'sweepCode',
component:sweepCode component: sweepCode
}, },
{ {
path:'/update', path: '/update',
name:'update', name: 'update',
component:update component: update
}, },
{ {
path:'/getimage', path: '/getimage',
name:'getimage', name: 'getimage',
component:getimage component: getimage
}, },
{ {
path: '/resumeDetail', path: '/resumeDetail',
...@@ -106,6 +106,6 @@ export default new Router({ ...@@ -106,6 +106,6 @@ export default new Router({
component: upload component: upload
} }
] ]
}, }
], ]
}); })
// https://github.com/ElemeFE/element/blob/dev/packages/upload/src/ajax.js // https://github.com/ElemeFE/element/blob/dev/packages/upload/src/ajax.js
import axios from './http.service.js' import axios from './http.service.js'
function getError(action, option, xhr) { function getError (action, option, xhr) {
const msg = `fail to post ${action} ${xhr.status}'`; const msg = `fail to post ${action} ${xhr.status}'`
const err = new Error(msg); const err = new Error(msg)
err.status = xhr.status; err.status = xhr.status
err.method = 'post'; err.method = 'post'
err.url = action; err.url = action
return err; return err
} }
function getBody(xhr) { function getBody (xhr) {
const text = xhr.responseText || xhr.response; const text = xhr.responseText || xhr.response
if (!text) { if (!text) {
return text; return text
} }
try { try {
return JSON.parse(text); return JSON.parse(text)
} catch (e) { } catch (e) {
return text; return text
} }
} }
export function uploadFile (option) { export function uploadFile (option) {
const action = option.action; const action = option.action
const formData = new FormData(); const formData = new FormData()
if (option.data) { if (option.data) {
option.data.map(item => { option.data.map(item => {
formData.append(option.appendFile, item.data) formData.append(option.appendFile, item.data)
}) })
} }
formData.append(option.appendName, option.batchNum); formData.append(option.appendName, option.batchNum)
axios.post(action, formData, { axios.post(action, formData, {
onUploadProgress: function(progressEvent){ onUploadProgress: function (progressEvent) {
if (progressEvent.total > 0) { if (progressEvent.total > 0) {
progressEvent.percent = (progressEvent.loaded / progressEvent.total * 100); progressEvent.percent = (progressEvent.loaded / progressEvent.total * 100)
} }
option.onProgress(progressEvent); option.onProgress(progressEvent)
} }
}).then((res) => { }).then((res) => {
option.onSuccess(res.data) option.onSuccess(res.data)
}).catch((error) => { }).catch((error) => {
option.onError(error) option.onError(error)
}) })
} }
export default function upload(option) { export default function upload (option) {
if (typeof XMLHttpRequest === 'undefined') { if (typeof XMLHttpRequest === 'undefined') {
return; return
} }
const xhr = new XMLHttpRequest(); const xhr = new XMLHttpRequest()
const action = option.action ; const action = option.action
if (xhr.upload) { if (xhr.upload) {
xhr.upload.onprogress = function progress(e) { xhr.upload.onprogress = function progress (e) {
if (e.total > 0) { if (e.total > 0) {
e.percent = (e.loaded / e.total * 100 -10 ); e.percent = (e.loaded / e.total * 100 - 10)
}
option.onProgress(e)
} }
option.onProgress(e);
};
} }
const formData = new FormData(); const formData = new FormData()
if (option.data) { if (option.data) {
option.data.map(item => { option.data.map(item => {
formData.append(option.appendFile, item.data); formData.append(option.appendFile, item.data)
}) })
} }
formData.append(option.appendName, option.batchNum); formData.append(option.appendName, option.batchNum)
xhr.onerror = function error(e) { xhr.onerror = function error (e) {
option.onError(e); option.onError(e)
}; }
xhr.onload = function onload() { xhr.onload = function onload () {
if (xhr.status < 200 || xhr.status >= 300) { if (xhr.status < 200 || xhr.status >= 300) {
return option.onError(getError(action, option, xhr), getBody(xhr)); return option.onError(getError(action, option, xhr), getBody(xhr))
} }
option.onSuccess(getBody(xhr)); option.onSuccess(getBody(xhr))
}; }
xhr.open('post', action, true); xhr.open('post', action, true)
if ('withCredentials' in xhr) { if ('withCredentials' in xhr) {
xhr.withCredentials = true; xhr.withCredentials = true
} }
const headers = option.headers || {}; const headers = option.headers || {}
if (headers['X-Requested-With'] !== null) { if (headers['X-Requested-With'] !== null) {
xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest')
} }
for (let item in headers) { for (const item in headers) {
if (headers.hasOwnProperty(item) && headers[item] !== null) { if (headers.hasOwnProperty(item) && headers[item] !== null) {
xhr.setRequestHeader(item, headers[item]); xhr.setRequestHeader(item, headers[item])
} }
} }
xhr.send(formData); xhr.send(formData)
} }
import Cookie from 'js-cookie' import Cookie from 'js-cookie'
export default{ export default {
set: function (name, value) {Cookie.set(name, value)}, set: function (name, value) { Cookie.set(name, value) },
get: function (name) { get: function (name) {
return Cookie.get(name) return Cookie.get(name)
}, },
remove: function (name) {Cookie.remove(name)} remove: function (name) { Cookie.remove(name) }
} }
import axios from 'axios' import axios from 'axios'
import Promise from './promise.service.js' import Promise from './promise.service.js'
import {Notice} from 'iview' import { Notice } from 'iview'
import Vue from 'vue' import Vue from 'vue'
import router from '../router/index.js' import router from '../router/index.js'
import store from '../store' import store from '../store'
var instance = axios.create({}); var instance = axios.create({})
instance.defaults.timeout = 3600000; instance.defaults.timeout = 3600000
instance.defaults.withCredentials = true; instance.defaults.withCredentials = true
instance.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded'; instance.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded'
instance.defaults.headers['X-Requested-With'] = 'XMLHttpRequest' instance.defaults.headers['X-Requested-With'] = 'XMLHttpRequest'
let needLoadingRequestCount = 0 let needLoadingRequestCount = 0
function startLoading() { function startLoading () {
store.state.loading = true store.state.loading = true
} }
function endLoading() { function endLoading () {
store.state.loading = false store.state.loading = false
} }
function showFullScreenLoading () { function showFullScreenLoading () {
...@@ -24,7 +24,7 @@ function showFullScreenLoading () { ...@@ -24,7 +24,7 @@ function showFullScreenLoading () {
} }
needLoadingRequestCount++ needLoadingRequestCount++
} }
function tryHideFullScreenLoading() { function tryHideFullScreenLoading () {
if (needLoadingRequestCount <= 0) return if (needLoadingRequestCount <= 0) return
needLoadingRequestCount-- needLoadingRequestCount--
if (needLoadingRequestCount === 0) { if (needLoadingRequestCount === 0) {
...@@ -32,62 +32,67 @@ function tryHideFullScreenLoading() { ...@@ -32,62 +32,67 @@ function tryHideFullScreenLoading() {
endLoading() endLoading()
}, 200) }, 200)
} }
} }
let needLoading = ['resume/findListByQueryVO', 'sendMail/sendEmailTemplate', 'resume/forwardResume', 'interview/findListByQueryVO','resume/delete'] const needLoading = ['resume/findListByQueryVO', 'sendMail/sendEmailTemplate', 'resume/forwardResume', 'interview/findListByQueryVO', 'resume/delete']
instance.interceptors.request.use(function (config) { instance.interceptors.request.use(function (config) {
// 在发送请求之前做些什么 // 在发送请求之前做些什么
if (!config.headers['Content-Type']) { if (!config.headers['Content-Type']) {
config.headers['Content-Type'] = 'application/x-www-form-urlencoded' config.headers['Content-Type'] = 'application/x-www-form-urlencoded'
} }
let url = config.url.split('api/')[1] const url = config.url.split('api/')[1]
let headers = config.headers const headers = config.headers
if (headers.status!='init'&&needLoading.includes(url)){ if (headers.status != 'init' && needLoading.includes(url)) {
showFullScreenLoading() showFullScreenLoading()
} }
delete headers.status delete headers.status
return config; return config
}, function (error) { }, function (error) {
// 对请求错误做些什么 // 对请求错误做些什么
return Promise.reject(error); return Promise.reject(error)
}); })
instance.interceptors.response.use(function (response) { instance.interceptors.response.use(function (response) {
// 在发送请求之前做些什么 // 在发送请求之前做些什么
let errorInfo = { const errorInfo = {
'900': 'cookie已失效,请重新登录', 900: 'cookie已失效,请重新登录',
'901': '', 901: '',
'902': '您的账号已在其他地方登录,如不是您个人操作,请及时修改密码' 902: '您的账号已在其他地方登录,如不是您个人操作,请及时修改密码'
} }
tryHideFullScreenLoading() tryHideFullScreenLoading()
if(response.status >= 200 && response.status < 300){ if (response.status >= 200 && response.status < 300) {
let code = response.data&&response.data.body&&response.data.body.code || '' const code = response.data && response.data.body && response.data.body.code || ''
if (code == '900' || code == '901' || code == '902'){ if (code == '900' || code == '901' || code == '902') {
if (!store.state.cookieTips && code != '901') { if (!store.state.cookieTips && code != '901') {
store.dispatch('cookieTipsShow', true) store.dispatch('cookieTipsShow', true)
Notice.error({render:(h) => {return h('div', {style: { Notice.error({
render: (h) => {
return h('div', {
style: {
paddingRight: '5px', paddingRight: '5px',
fontSize: '14px', fontSize: '14px',
lineHeight: '20px', lineHeight: '20px',
color: '#17233d' color: '#17233d'
}}, errorInfo[code])}}) }
}, errorInfo[code])
}
})
setTimeout(() => { setTimeout(() => {
store.dispatch('cookieTipsHide', false) store.dispatch('cookieTipsHide', false)
}, 2000) }, 2000)
} }
router.replace({name: 'login'}) router.replace({ name: 'login' })
} }
if(response.data.success){ if (response.data.success) {
return Promise.resolve(response)
} else {
return Promise.resolve(response) return Promise.resolve(response)
}
else {
return Promise.resolve(response);
} }
} else { } else {
// return Promise.resolve(response); // return Promise.resolve(response);
} }
return response; return response
}, error => { }, error => {
tryHideFullScreenLoading() tryHideFullScreenLoading()
// Notice.error({desc:`${error.response.data.body.message}`}) // Notice.error({desc:`${error.response.data.body.message}`})
}); })
export default instance export default instance
// export default axios // export default axios
import localstorage from './localstorage.service.js' import localstorage from './localstorage.service.js'
export default{ export default {
init: function (router) { init: function (router) {
router.beforeEach((to, form, next) => { router.beforeEach((to, form, next) => {
let token = localstorage.get('token') const token = localstorage.get('token')
if (to.meta && !to.meta.allowBack && window.history && window.history.pushState) { //登录页面不能后退 if (to.meta && !to.meta.allowBack && window.history && window.history.pushState) { // 登录页面不能后退
history.pushState(null, null, document.URL) history.pushState(null, null, document.URL)
} }
if (to.name =='login' || to.name =='update' || to.name =='sweepCode'|| to.name== 'resumeDetail'|| to.name== 'pdfdetail'){ if (to.name == 'login' || to.name == 'update' || to.name == 'sweepCode' || to.name == 'resumeDetail' || to.name == 'pdfdetail') {
next() next()
return return
} }
if(!token){ if (!token) {
window.location.href = `${window.location.origin}/login` window.location.href = `${window.location.origin}/login`
return return
} }
......
export default{ export default {
set: function (name, value) {window.localStorage.setItem(name, value)}, set: function (name, value) { window.localStorage.setItem(name, value) },
get: function (name) { get: function (name) {
return window.localStorage.getItem(name) return window.localStorage.getItem(name)
}, },
remove: function (name) {window.localStorage.removeItem(name)} remove: function (name) { window.localStorage.removeItem(name) }
} }
module.exports = require('es6-promise'); module.exports = require('es6-promise')
\ No newline at end of file
...@@ -3,7 +3,7 @@ export function _debounce (fn, delay) { ...@@ -3,7 +3,7 @@ export function _debounce (fn, delay) {
delay = delay || 200 delay = delay || 200
return function () { return function () {
let args = arguments const args = arguments
if (timer) { if (timer) {
clearTimeout(timer) clearTimeout(timer)
...@@ -21,9 +21,9 @@ export function _throttle (fn, interval) { ...@@ -21,9 +21,9 @@ export function _throttle (fn, interval) {
let timer = null let timer = null
interval = interval || 200 interval = interval || 200
return function () { return function () {
let self = this const self = this
let args = arguments const args = arguments
let now = +new Date() const now = +new Date()
if (last && now - last < interval) { if (last && now - last < interval) {
clearTimeout(timer) clearTimeout(timer)
timer = setTimeout(function () { timer = setTimeout(function () {
...@@ -36,90 +36,86 @@ export function _throttle (fn, interval) { ...@@ -36,90 +36,86 @@ export function _throttle (fn, interval) {
} }
} }
} }
export function emailValidata (rule, value, callback){ export function emailValidata (rule, value, callback) {
let field = rule.field const field = rule.field
let reg = rule.pattern const reg = rule.pattern
switch(field){ switch (field) {
case 'receiveEmail': case 'receiveEmail':
if (!value) { if (!value) {
this.tip = true this.tip = true
this.isDisable=false this.isDisable = false
callback(new Error('收件人不能为空')) callback(new Error('收件人不能为空'))
} } else if (rule.pattern && !rule.pattern.test(value)) {
else if (rule.pattern&&!rule.pattern.test(value)) {
this.tip = true this.tip = true
this.isDisable=false this.isDisable = false
callback(new Error('请输入正确收件人地址')) callback(new Error('请输入正确收件人地址'))
}else { } else {
this.tip = false this.tip = false
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
case 'theme': case 'theme':
if (!value) { if (!value) {
this.isDisable=false this.isDisable = false
callback(new Error('主题能为空')) callback(new Error('主题能为空'))
} else { } else {
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
case 'copyname': case 'copyname':
if (value&&reg&&!reg.test(value)) { if (value && reg && !reg.test(value)) {
this.isDisable=false this.isDisable = false
callback(new Error('请输入正确抄送地址')) callback(new Error('请输入正确抄送地址'))
} else { } else {
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
case 'UpdateOWER': case 'UpdateOWER':
if (!value) { if (!value) {
this.isDisable=false this.isDisable = false
callback(new Error('邀约人不能为空')) callback(new Error('邀约人不能为空'))
} else { } else {
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
case 'UpdateTIME': case 'UpdateTIME':
if (!value) { if (!value) {
this.isDisable=false this.isDisable = false
callback(new Error('面试时间不能为空')) callback(new Error('面试时间不能为空'))
} else { } else {
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
case 'UpdateVIEW': case 'UpdateVIEW':
if (!value) { if (!value) {
this.isDisable=false this.isDisable = false
callback(new Error('面试官不能为空')) callback(new Error('面试官不能为空'))
} else { } else {
this.isDisable=true this.isDisable = true
callback() callback()
} }
break; break
default: default:
callback() callback()
break; break
}
} }
}
export const emailRule = /^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/ export const emailRule = /^((([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6}\;))*(([a-z0-9_\.-]+)@([\da-z\.-]+)\.([a-z\.]{2,6})))$/
export function vidte(rule,value,callback){ export function vidte (rule, value, callback) {
if(this.emailMassage==true){ if (this.emailMassage == true) {
callback(new Error('你尚未选择简历,请先选择简历')) callback(new Error('你尚未选择简历,请先选择简历'))
} } else if (this.allEmailVilitor == true) {
else if(this.allEmailVilitor==true){
callback(new Error('不能选择多份简历,请选择单份简历')) callback(new Error('不能选择多份简历,请选择单份简历'))
} } else {
else{
callback ()
}
}
export function validator (rule, value, callback){
if (!value)this.$Notice.warning({title: '提示',desc: '请输入您要通知的面试官'})
callback() callback()
} }
}
export function validator (rule, value, callback) {
if (!value) this.$Notice.warning({ title: '提示', desc: '请输入您要通知的面试官' })
callback()
}
// // action.js // // action.js
import * as types from './muationsType' import * as types from './muationsType'
let action = { const action = {
cookieTipsShow({commit}, value) { cookieTipsShow ({ commit }, value) {
commit(types.COOKIE_SHOW, value) commit(types.COOKIE_SHOW, value)
}, },
addInterviewee ({commit}, value) { addInterviewee ({ commit }, value) {
commit(types.ADD_INTERVIEWEE, value) commit(types.ADD_INTERVIEWEE, value)
}, },
removeInterviewee ({commit}, value) { removeInterviewee ({ commit }, value) {
commit(types.REMOVE_INTERVIEWEE, value) commit(types.REMOVE_INTERVIEWEE, value)
}, },
clearInterviewee ({commit}, value) { clearInterviewee ({ commit }, value) {
commit(types.CLEAR_INTERVIEWEE, value) commit(types.CLEAR_INTERVIEWEE, value)
} }
} }
......
...@@ -3,5 +3,3 @@ export const COOKIE_HIDE = 'COOKIE_HIDE' ...@@ -3,5 +3,3 @@ export const COOKIE_HIDE = 'COOKIE_HIDE'
export const ADD_INTERVIEWEE = 'ADD_INTERVIEWEE' export const ADD_INTERVIEWEE = 'ADD_INTERVIEWEE'
export const REMOVE_INTERVIEWEE = 'REMOVE_INTERVIEWEE' export const REMOVE_INTERVIEWEE = 'REMOVE_INTERVIEWEE'
export const CLEAR_INTERVIEWEE = 'CLEAR_INTERVIEWEE' export const CLEAR_INTERVIEWEE = 'CLEAR_INTERVIEWEE'
import {COOKIE_SHOW, COOKIE_HIDE,ADD_INTERVIEWEE,REMOVE_INTERVIEWEE, CLEAR_INTERVIEWEE} from './muationsType' import { COOKIE_SHOW, COOKIE_HIDE, ADD_INTERVIEWEE, REMOVE_INTERVIEWEE, CLEAR_INTERVIEWEE } from './muationsType'
export default { export default {
[COOKIE_SHOW] (state, value) { [COOKIE_SHOW] (state, value) {
state.cookieTips = value || true state.cookieTips = value || true
}, },
[COOKIE_HIDE](state, value) { [COOKIE_HIDE] (state, value) {
state.cookieTips = value || false state.cookieTips = value || false
}, },
[ADD_INTERVIEWEE] (state, object) { [ADD_INTERVIEWEE] (state, object) {
let flag = false let flag = false
let data = object.data const data = object.data
if (object.type=='channel') { if (object.type == 'channel') {
console.log(data) console.log(data)
state.channelInterviewee.map(item => { state.channelInterviewee.map(item => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
flag = true flag = true
return
} }
}) })
if (!flag) { if (!flag) {
...@@ -22,36 +21,33 @@ export default { ...@@ -22,36 +21,33 @@ export default {
} }
} else { } else {
state.interviewee.map(item => { state.interviewee.map(item => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
flag = true flag = true
return
} }
}) })
if (!flag) { if (!flag) {
state.interviewee.push(data) state.interviewee.push(data)
} }
} }
}, },
[REMOVE_INTERVIEWEE](state, object) { [REMOVE_INTERVIEWEE] (state, object) {
let data = object.data const data = object.data
if (object.type=='channel') { if (object.type == 'channel') {
state.channelInterviewee.map((item, index) => { state.channelInterviewee.map((item, index) => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
state.channelInterviewee.splice(index, 1) state.channelInterviewee.splice(index, 1)
} }
}) })
} else { } else {
state.interviewee.map((item, index) => { state.interviewee.map((item, index) => {
if (data&&item.id == data.id) { if (data && item.id == data.id) {
state.interviewee.splice(index, 1) state.interviewee.splice(index, 1)
} }
}) })
} }
}, },
[CLEAR_INTERVIEWEE](state, object) { [CLEAR_INTERVIEWEE] (state, object) {
let type = object.type const type = object.type
if (type == 'channel') { if (type == 'channel') {
state.channelInterviewee = [] state.channelInterviewee = []
console.log('===') console.log('===')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment