@@ -82,7 +82,11 @@ export const getUserInfo = (query) => { | |||||
return request({ | return request({ | ||||
url: '/admin/user/info', | url: '/admin/user/info', | ||||
method: 'get', | method: 'get', | ||||
params:query | |||||
params:{ | |||||
orgCode:localStorage.getItem('orgCode'), | |||||
agentId:localStorage.getItem('agentId'), | |||||
...query, | |||||
} | |||||
}) | }) | ||||
} | } | ||||
@@ -42,7 +42,7 @@ | |||||
>{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | >{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | ||||
> | > | ||||
</div> | </div> | ||||
<div class="text-3">{{ item.address|| "暂无" }}</div> | |||||
<div class="text-3">{{ (item.provinceName||'-')+'-'+(item.cityName|| "-") }}</div> | |||||
</div> | </div> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -107,7 +107,7 @@ | |||||
>{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | >{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | ||||
> | > | ||||
</div> --> | </div> --> | ||||
<div class="text-3">区域位置:{{ item.address || "暂无" }}</div> | |||||
<div class="text-3">区域位置:{{ (item.provinceName||'-')+'-'+(item.cityName|| "-") }}</div> | |||||
</div> | </div> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -172,7 +172,7 @@ | |||||
>{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | >{{ item.residueTime > 0 ? "服务中" : "已过期" }}</span | ||||
> | > | ||||
</div> | </div> | ||||
<div class="text-3">{{ item.address|| "暂无" }}</div> | |||||
<div class="text-3">{{ (item.provinceName||'-')+'-'+(item.cityName|| "-") }}</div> | |||||
</div> | </div> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -95,7 +95,7 @@ export default { | |||||
}, | }, | ||||
openMenu(item = {}) { | openMenu(item = {}) { | ||||
this.$store.dispatch("GetMenu", {type: true, id: item.id}).then(data => { | this.$store.dispatch("GetMenu", {type: true, id: item.id}).then(data => { | ||||
console.log(data,'这里是data'); | |||||
// console.log(data,'这里是data'); | |||||
if (data.length !== 0) { | if (data.length !== 0) { | ||||
this.$router.$avueRouter.formatRoutes(data, true); | this.$router.$avueRouter.formatRoutes(data, true); | ||||
} | } | ||||
@@ -107,9 +107,9 @@ | |||||
content="用户头像" | content="用户头像" | ||||
placement="bottom" | placement="bottom" | ||||
> | > | ||||
<img id="thumbnail" class="top-bar__img" /> | |||||
<!-- <img id="thumbnail" class="top-bar__img" /> --> | |||||
</el-tooltip> | </el-tooltip> | ||||
<el-dropdown> | |||||
<el-dropdown style="cursor: pointer;"> | |||||
<span class="el-dropdown-link"> | <span class="el-dropdown-link"> | ||||
{{ userInfo.username }} | {{ userInfo.username }} | ||||
<i class="el-icon-arrow-down el-icon--right" /> | <i class="el-icon-arrow-down el-icon--right" /> | ||||
@@ -118,9 +118,9 @@ | |||||
<el-dropdown-item divided> | <el-dropdown-item divided> | ||||
<router-link to="/">首页</router-link> | <router-link to="/">首页</router-link> | ||||
</el-dropdown-item> | </el-dropdown-item> | ||||
<!-- <el-dropdown-item divided> | |||||
<el-dropdown-item divided> | |||||
<router-link to="/info/index">个人信息</router-link> | <router-link to="/info/index">个人信息</router-link> | ||||
</el-dropdown-item> --> | |||||
</el-dropdown-item> | |||||
<el-dropdown-item divided @click.native="$refs.seting.open()" | <el-dropdown-item divided @click.native="$refs.seting.open()" | ||||
>界面设置 | >界面设置 | ||||
</el-dropdown-item> | </el-dropdown-item> | ||||
@@ -162,7 +162,7 @@ | |||||
</div> | </div> | ||||
<el-dialog title="新增代理" :visible.sync="dialogVisible" > | |||||
<el-dialog title="新增代理" :visible.sync="dialogVisible" @close='reset1'> | |||||
<el-form :model="addagentobj" label-position="labelPosition" :rules="rules" ref="addagentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | <el-form :model="addagentobj" label-position="labelPosition" :rules="rules" ref="addagentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | ||||
<el-form-item label="代理商名称:" prop="agentName"> | <el-form-item label="代理商名称:" prop="agentName"> | ||||
<el-input v-model="addagentobj.agentName" maxlength="30" clearable></el-input> | <el-input v-model="addagentobj.agentName" maxlength="30" clearable></el-input> | ||||
@@ -239,7 +239,7 @@ | |||||
</el-dialog> | </el-dialog> | ||||
<el-dialog title="编辑" :visible.sync="dialogVisible2" > | |||||
<el-dialog title="编辑" :visible.sync="dialogVisible2" @close='reset2'> | |||||
<el-form :model="editoragentobj" label-position="labelPosition" :rules="editorrules" ref="editoragentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | <el-form :model="editoragentobj" label-position="labelPosition" :rules="editorrules" ref="editoragentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | ||||
<el-form-item label="代理商名称:" prop="agentName"> | <el-form-item label="代理商名称:" prop="agentName"> | ||||
<el-input v-model="editoragentobj.agentName" maxlength="30" clearable></el-input> | <el-input v-model="editoragentobj.agentName" maxlength="30" clearable></el-input> | ||||
@@ -387,17 +387,19 @@ export default { | |||||
orgCode:localStorage.getItem('orgCode'), | orgCode:localStorage.getItem('orgCode'), | ||||
}) | }) | ||||
.then(res1=>{ | .then(res1=>{ | ||||
callback(); | |||||
this.resetFlag=true | |||||
this.passFlag=true | this.passFlag=true | ||||
if(this.dialogVisible3){ | if(this.dialogVisible3){ | ||||
this.replaceagentobj.managerPassword=res.data.sysUser.resultPwd | this.replaceagentobj.managerPassword=res.data.sysUser.resultPwd | ||||
}else{ | }else{ | ||||
this.addagentobj.managerPassword=res.data.sysUser.resultPwd | this.addagentobj.managerPassword=res.data.sysUser.resultPwd | ||||
} | } | ||||
callback(); | |||||
}) | }) | ||||
.catch(err=>{ | .catch(err=>{ | ||||
console.log(err) | console.log(err) | ||||
this.resetFlag=false | |||||
callback(new Error(err)); | callback(new Error(err)); | ||||
}) | }) | ||||
} else { | } else { | ||||
@@ -409,6 +411,7 @@ export default { | |||||
}else{ | }else{ | ||||
this.addagentobj.managerPassword='' | this.addagentobj.managerPassword='' | ||||
} | } | ||||
this.resetFlag=false | |||||
this.passFlag=false | this.passFlag=false | ||||
callback(); | callback(); | ||||
@@ -434,6 +437,7 @@ export default { | |||||
passFlag:false, | passFlag:false, | ||||
dialogVisible:false, | dialogVisible:false, | ||||
dialogVisible2:false, | dialogVisible2:false, | ||||
resetFlag:false, | |||||
dialogVisible3:false, | dialogVisible3:false, | ||||
operaVisible:false, | operaVisible:false, | ||||
timelist:'', | timelist:'', | ||||
@@ -671,8 +675,18 @@ export default { | |||||
this.optionscityId= res.data | this.optionscityId= res.data | ||||
}); | }); | ||||
}, | }, | ||||
reset1(){ | |||||
this.$refs.addagentobj.resetFields(); | |||||
}, | |||||
reset2(){ | |||||
this.$refs.editoragentobj.resetFields(); | |||||
}, | |||||
//确认编辑 | //确认编辑 | ||||
editor(){ | editor(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.editoragentobj.validate((valid) => { | this.$refs.editoragentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.http.editorAgent(this.editoragentobj).then((res) => { | this.$api.http.editorAgent(this.editoragentobj).then((res) => { | ||||
@@ -736,6 +750,10 @@ export default { | |||||
}, | }, | ||||
//确认更换 | //确认更换 | ||||
replace(){ | replace(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.replaceagentobj.validate((valid) => { | this.$refs.replaceagentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.http.updateManagerPhone(this.replaceagentobj).then((res) => { | this.$api.http.updateManagerPhone(this.replaceagentobj).then((res) => { | ||||
@@ -767,6 +785,10 @@ export default { | |||||
}, | }, | ||||
//确认新增 | //确认新增 | ||||
add(){ | add(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.addagentobj.validate((valid) => { | this.$refs.addagentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.http.AddAgent(this.addagentobj).then((res) => { | this.$api.http.AddAgent(this.addagentobj).then((res) => { | ||||
@@ -120,7 +120,7 @@ | |||||
</div> | </div> | ||||
<el-dialog title="新增公司" :visible.sync="dialogVisible" @close='reset'> | |||||
<el-dialog title="新增公司" :visible.sync="dialogVisible" @close='reset1'> | |||||
<el-form :model="addagentobj" label-position="labelPosition" :rules="rules" ref="addagentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | <el-form :model="addagentobj" label-position="labelPosition" :rules="rules" ref="addagentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | ||||
<!-- <el-form-item label="代理商名称:" prop="agentId"> --> | <!-- <el-form-item label="代理商名称:" prop="agentId"> --> | ||||
<!-- <el-select v-model="addagentobj.agentId" placeholder="请选择" @change='clickagentId()'> --> | <!-- <el-select v-model="addagentobj.agentId" placeholder="请选择" @change='clickagentId()'> --> | ||||
@@ -183,7 +183,7 @@ | |||||
</el-dialog> | </el-dialog> | ||||
<el-dialog title="编辑" :visible.sync="dialogVisible2" > | |||||
<el-dialog title="编辑" :visible.sync="dialogVisible2" @close='reset2'> | |||||
<el-form :model="editoragentobj" label-position="labelPosition" :rules="editorrules" ref="editoragentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | <el-form :model="editoragentobj" label-position="labelPosition" :rules="editorrules" ref="editoragentobj" label-width="140px" style="width:60%; margin: 0 auto;"> | ||||
<!-- <el-form-item label="代理商名称:" prop="operator"> --> | <!-- <el-form-item label="代理商名称:" prop="operator"> --> | ||||
<!-- <el-select v-model="editoragentobj.operator" placeholder="请选择" @change='clickagentId22()'> --> | <!-- <el-select v-model="editoragentobj.operator" placeholder="请选择" @change='clickagentId22()'> --> | ||||
@@ -323,17 +323,19 @@ export default { | |||||
orgCode:localStorage.getItem('orgCode'), | orgCode:localStorage.getItem('orgCode'), | ||||
}) | }) | ||||
.then(res1=>{ | .then(res1=>{ | ||||
callback(); | |||||
this.passFlag=true | this.passFlag=true | ||||
this.resetFlag=false | |||||
if(this.dialogVisible3){ | if(this.dialogVisible3){ | ||||
this.replaceagentobj.managerPassword=res.data.sysUser.resultPwd | this.replaceagentobj.managerPassword=res.data.sysUser.resultPwd | ||||
}else{ | }else{ | ||||
this.addagentobj.managerPassword=res.data.sysUser.resultPwd | this.addagentobj.managerPassword=res.data.sysUser.resultPwd | ||||
} | } | ||||
callback(); | |||||
}) | }) | ||||
.catch(err=>{ | .catch(err=>{ | ||||
console.log(err) | console.log(err) | ||||
this.resetFlag=false | |||||
callback(new Error(err)); | callback(new Error(err)); | ||||
}) | }) | ||||
} else { | } else { | ||||
@@ -345,6 +347,7 @@ export default { | |||||
}else{ | }else{ | ||||
this.addagentobj.managerPassword='' | this.addagentobj.managerPassword='' | ||||
} | } | ||||
this.resetFlag=false | |||||
this.passFlag=false | this.passFlag=false | ||||
callback(); | callback(); | ||||
@@ -432,6 +435,7 @@ export default { | |||||
dialogVisible3:false, | dialogVisible3:false, | ||||
operaVisible:false, | operaVisible:false, | ||||
agentVisible:false, | agentVisible:false, | ||||
resetFlag:false, | |||||
passFlag:false, | passFlag:false, | ||||
currentPage4:1, | currentPage4:1, | ||||
operatorName:'',//代理商名称 | operatorName:'',//代理商名称 | ||||
@@ -559,9 +563,6 @@ export default { | |||||
} | } | ||||
}) | }) | ||||
}, | }, | ||||
reset(){ | |||||
this.$refs.addagentobj.resetFields(); | |||||
}, | |||||
saveOpera(){ | saveOpera(){ | ||||
this.$refs.operaForm.validate(valid=>{ | this.$refs.operaForm.validate(valid=>{ | ||||
if(valid){ | if(valid){ | ||||
@@ -665,6 +666,10 @@ export default { | |||||
}, | }, | ||||
//确认编辑 | //确认编辑 | ||||
editor(){ | editor(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.editoragentobj.validate((valid) => { | this.$refs.editoragentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.http.updateOrg(this.editoragentobj).then((res) => { | this.$api.http.updateOrg(this.editoragentobj).then((res) => { | ||||
@@ -683,7 +688,7 @@ export default { | |||||
}); | }); | ||||
}, | }, | ||||
toDisable(row){ | toDisable(row){ | ||||
this.$confirm(`确定${row.lockFlag==0?'禁用':'启用'}此代理商么?`, '提示', { | |||||
this.$confirm(`确定${row.lockFlag==0?'禁用':'启用'}此公司么?`, '提示', { | |||||
confirmButtonText: '确定', | confirmButtonText: '确定', | ||||
cancelButtonText: '取消', | cancelButtonText: '取消', | ||||
type: 'warning' | type: 'warning' | ||||
@@ -710,7 +715,12 @@ export default { | |||||
reset1(){ | |||||
this.$refs.addagentobj.resetFields(); | |||||
}, | |||||
reset2(){ | |||||
this.$refs.editoragentobj.resetFields(); | |||||
}, | |||||
//更换 | //更换 | ||||
inforeplace(row){ | inforeplace(row){ | ||||
this.replaceagentobj.id=row.id; | this.replaceagentobj.id=row.id; | ||||
@@ -724,6 +734,10 @@ export default { | |||||
}, | }, | ||||
//确认更换 | //确认更换 | ||||
replace(){ | replace(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.replaceagentobj.validate((valid) => { | this.$refs.replaceagentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.http.changeAccount(this.replaceagentobj).then((res) => { | this.$api.http.changeAccount(this.replaceagentobj).then((res) => { | ||||
@@ -853,6 +867,10 @@ export default { | |||||
//确认新增 | //确认新增 | ||||
add(){ | add(){ | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.addagentobj.validate((valid) => { | this.$refs.addagentobj.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.addagentobj.pid=0; | this.addagentobj.pid=0; | ||||
@@ -364,6 +364,7 @@ export default { | |||||
dialogVisible:false, | dialogVisible:false, | ||||
dialogVisible2:false, | dialogVisible2:false, | ||||
dialogVisible3:false, | dialogVisible3:false, | ||||
resetFlag:false, | |||||
operaVisible:false, | operaVisible:false, | ||||
agentVisible:false, | agentVisible:false, | ||||
currentPage4:1, | currentPage4:1, | ||||
@@ -527,13 +527,8 @@ export default { | |||||
}else{ | }else{ | ||||
this.searchForm.projectId = res.data[0].id; | this.searchForm.projectId = res.data[0].id; | ||||
} | } | ||||
// 获取接待记录列表 | |||||
this.findbypage(); | |||||
// 获取客户意向 | |||||
// this.findKeywords(); | |||||
// 获取置业顾问列表 | |||||
this.findUserListByHouseId(); | |||||
this.tabtimetap(0); | |||||
this.houseChange(); | |||||
// this.tabtimetap(0); | |||||
}); | }); | ||||
}, | }, | ||||
// 置业顾问列表 | // 置业顾问列表 | ||||
@@ -560,23 +555,22 @@ export default { | |||||
this.searchForm.endDate = ""; | this.searchForm.endDate = ""; | ||||
// this.$set(this, "time", null); | // this.$set(this, "time", null); | ||||
this.searchForm.dateType = idx; | this.searchForm.dateType = idx; | ||||
let num = 24 * 3600 * 1000; | |||||
// 获取当前时间戳转换为日期格式 | |||||
if (idx == 0) { | |||||
num = 24 * 3600 * 1000 * 0; | |||||
} | |||||
if (idx == 2) { | |||||
num = 24 * 3600 * 1000 * 6; | |||||
} | |||||
if (idx == 6) { | |||||
num = 24 * 3600 * 1000 * 29; | |||||
} | |||||
this.time = [ | |||||
this.timestampToTime(new Date().getTime() - num), | |||||
this.timestampToTime(new Date().getTime()), | |||||
]; | |||||
this.findKeywords() | |||||
// let num = 24 * 3600 * 1000; | |||||
// // 获取当前时间戳转换为日期格式 | |||||
// if (idx == 0) { | |||||
// num = 24 * 3600 * 1000 * 0; | |||||
// } | |||||
// if (idx == 2) { | |||||
// num = 24 * 3600 * 1000 * 6; | |||||
// } | |||||
// if (idx == 6) { | |||||
// num = 24 * 3600 * 1000 * 29; | |||||
// } | |||||
// this.time = [ | |||||
// this.timestampToTime(new Date().getTime() - num), | |||||
// this.timestampToTime(new Date().getTime()), | |||||
// ]; | |||||
this.houseChange(); | |||||
}, | }, | ||||
timestampToTime(timestamp) { | timestampToTime(timestamp) { | ||||
var date = new Date(timestamp); //时间戳为10位需*1000,时间戳为13位的话不需乘1000 | var date = new Date(timestamp); //时间戳为10位需*1000,时间戳为13位的话不需乘1000 | ||||
@@ -674,7 +674,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
details: { | details: { | ||||
@@ -380,7 +380,7 @@ export default { | |||||
this.rec_index_voice = this.permissions["rec_index_voice"]; | this.rec_index_voice = this.permissions["rec_index_voice"]; | ||||
}, | }, | ||||
mounted() { | mounted() { | ||||
this.tabtimetap(0); | |||||
// 获取楼盘列表 | // 获取楼盘列表 | ||||
this.zkhousePage(); | this.zkhousePage(); | ||||
}, | }, | ||||
@@ -484,13 +484,15 @@ export default { | |||||
} else { | } else { | ||||
this.searchForm.projectId = res.data[0].id; | this.searchForm.projectId = res.data[0].id; | ||||
} | } | ||||
this.houseChange(); | |||||
// this.searchForm.projectId = res.data[0].id; | // this.searchForm.projectId = res.data[0].id; | ||||
// 获取接待记录列表 | |||||
this.findbypage(); | |||||
// 获取客户意向 | |||||
this.findKeywords(); | |||||
// 获取置业顾问列表 | |||||
this.findUserListByHouseId(); | |||||
// this.tabtimetap(0); | |||||
// // 获取接待记录列表 | |||||
// this.findbypage(); | |||||
// // 获取客户意向 | |||||
// this.findKeywords(); | |||||
// // 获取置业顾问列表 | |||||
// this.findUserListByHouseId(); | |||||
}); | }); | ||||
}, | }, | ||||
// 置业顾问列表 | // 置业顾问列表 | ||||
@@ -517,22 +519,22 @@ export default { | |||||
this.searchForm.endDate = ""; | this.searchForm.endDate = ""; | ||||
// this.$set(this, "time", null); | // this.$set(this, "time", null); | ||||
this.searchForm.dateType = idx; | this.searchForm.dateType = idx; | ||||
let num = 24 * 3600 * 1000; | |||||
// 获取当前时间戳转换为日期格式 | |||||
if (idx == 0) { | |||||
num = 24 * 3600 * 1000 * 0; | |||||
} | |||||
if (idx == 1) { | |||||
num = 24 * 3600 * 1000 * 1; | |||||
} | |||||
if (idx == 2) { | |||||
num = 24 * 3600 * 1000 * 7; | |||||
} | |||||
this.time = [ | |||||
this.timestampToTime(new Date().getTime() - num), | |||||
this.timestampToTime(new Date().getTime()), | |||||
]; | |||||
// let num = 24 * 3600 * 1000; | |||||
// // 获取当前时间戳转换为日期格式 | |||||
// if (idx == 0) { | |||||
// num = 24 * 3600 * 1000 * 0; | |||||
// } | |||||
// if (idx == 1) { | |||||
// num = 24 * 3600 * 1000 * 1; | |||||
// } | |||||
// if (idx == 2) { | |||||
// num = 24 * 3600 * 1000 * 7; | |||||
// } | |||||
// this.time = [ | |||||
// this.timestampToTime(new Date().getTime() - num), | |||||
// this.timestampToTime(new Date().getTime()), | |||||
// ]; | |||||
this.houseChange(); | |||||
}, | }, | ||||
timestampToTime(timestamp) { | timestampToTime(timestamp) { | ||||
var date = new Date(timestamp); //时间戳为10位需*1000,时间戳为13位的话不需乘1000 | var date = new Date(timestamp); //时间戳为10位需*1000,时间戳为13位的话不需乘1000 | ||||
@@ -245,7 +245,7 @@ export default { | |||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
// console.log(time.toLocaleDateString()); | // console.log(time.toLocaleDateString()); | ||||
return time.getTime() > Date.now() - 8.64e6 | |||||
// return time.getTime() > Date.now() - 8.64e6 | |||||
}, | }, | ||||
}, | }, | ||||
role:'', | role:'', | ||||
@@ -252,7 +252,7 @@ export default { | |||||
timeType: 4, | timeType: 4, | ||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
time: "",//对比时间的数组 | time: "",//对比时间的数组 | ||||
@@ -310,7 +310,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
firstTab: {}, | firstTab: {}, | ||||
@@ -283,7 +283,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
firstTab: {}, | firstTab: {}, | ||||
@@ -308,7 +308,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
firstTab: {}, | firstTab: {}, | ||||
@@ -229,7 +229,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
firstTab: {}, | firstTab: {}, | ||||
@@ -373,7 +373,7 @@ export default { | |||||
pickerOptions: { | pickerOptions: { | ||||
disabledDate(time) { | disabledDate(time) { | ||||
//根据当前日期 --- 禁止选中之后的日期 | //根据当前日期 --- 禁止选中之后的日期 | ||||
return time.getTime() > Date.now(); | |||||
// return time.getTime() > Date.now(); | |||||
}, | }, | ||||
}, | }, | ||||
firstTab: {}, | firstTab: {}, | ||||
@@ -4,7 +4,7 @@ | |||||
<div class="app-top"> | <div class="app-top"> | ||||
<div class="app-titel" style="margin-top: 5px"> | <div class="app-titel" style="margin-top: 5px"> | ||||
<div class="div-lab"> | <div class="div-lab"> | ||||
<div class="label">添加时间</div> | |||||
<div class="label">登录时间:</div> | |||||
<el-date-picker | <el-date-picker | ||||
v-model="time" | v-model="time" | ||||
type="daterange" | type="daterange" | ||||
@@ -4,7 +4,7 @@ | |||||
<div class="app-top"> | <div class="app-top"> | ||||
<div class="app-titel" style="margin-top: 5px"> | <div class="app-titel" style="margin-top: 5px"> | ||||
<div class="div-lab"> | <div class="div-lab"> | ||||
<div class="label">添加时间:</div> | |||||
<div class="label">登录时间:</div> | |||||
<el-date-picker | <el-date-picker | ||||
v-model="time" | v-model="time" | ||||
type="daterange" | type="daterange" | ||||
@@ -1,10 +1,10 @@ | |||||
<template> | <template> | ||||
<div class="user"> | <div class="user"> | ||||
<div style="background: #ffff; padding: 10px"> | <div style="background: #ffff; padding: 10px"> | ||||
<div class="tabcenbox" v-if="systemFlag"> | |||||
<div class="tabcenbox" v-if="systemFlag" style="cursor: pointer;"> | |||||
<div | <div | ||||
:class="choseFlag ? 'ch1' : 'ch2'" | :class="choseFlag ? 'ch1' : 'ch2'" | ||||
style="border-right: 1px solid #ccc" | |||||
style="border-right: 1px solid #ccc;" | |||||
@click="choseFlag = true" | @click="choseFlag = true" | ||||
> | > | ||||
注册用户 | 注册用户 | ||||
@@ -1,19 +1,3 @@ | |||||
<!-- | |||||
- Copyright (c) 2018-2025, lengleng All rights reserved. | |||||
- | |||||
- Redistribution and use in source and binary forms, with or without | |||||
- modification, are permitted provided that the following conditions are met: | |||||
- | |||||
- Redistributions of source code must retain the above copyright notice, | |||||
- this list of conditions and the following disclaimer. | |||||
- Redistributions in binary form must reproduce the above copyright | |||||
- notice, this list of conditions and the following disclaimer in the | |||||
- documentation and/or other materials provided with the distribution. | |||||
- Neither the name of the pig4cloud.com developer nor the names of its | |||||
- contributors may be used to endorse or promote products derived from | |||||
- this software without specific prior written permission. | |||||
- Author: lengleng (wangiegie@gmail.com) | |||||
--> | |||||
<template> | <template> | ||||
<div class="app-container calendar-list-container"> | <div class="app-container calendar-list-container"> | ||||
@@ -29,7 +13,7 @@ | |||||
> | > | ||||
<el-col :span="12"> | <el-col :span="12"> | ||||
<div class="grid-content bg-purple"> | <div class="grid-content bg-purple"> | ||||
<el-form-item label="头像"> | |||||
<!-- <el-form-item label="头像"> | |||||
<el-upload | <el-upload | ||||
:headers="headers" | :headers="headers" | ||||
:show-file-list="false" | :show-file-list="false" | ||||
@@ -40,20 +24,20 @@ | |||||
<img v-if="ruleForm.avatar" id="avatar" :src="avatarUrl" class="avatar" /> | <img v-if="ruleForm.avatar" id="avatar" :src="avatarUrl" class="avatar" /> | ||||
<i v-else class="el-icon-plus avatar-uploader-icon" /> | <i v-else class="el-icon-plus avatar-uploader-icon" /> | ||||
</el-upload> | </el-upload> | ||||
</el-form-item> | |||||
</el-form-item> --> | |||||
<el-form-item label="用户名" prop="username"> | <el-form-item label="用户名" prop="username"> | ||||
<el-input v-model="ruleForm.username" type="text" disabled /> | <el-input v-model="ruleForm.username" type="text" disabled /> | ||||
</el-form-item> | </el-form-item> | ||||
<el-form-item label="手机号" prop="phone"> | <el-form-item label="手机号" prop="phone"> | ||||
<el-input v-model="ruleForm.phone" placeholder="验证码登录使用" /> | |||||
<el-input v-model="ruleForm.phone" disabled placeholder="验证码登录使用" /> | |||||
</el-form-item> | </el-form-item> | ||||
<!-- | |||||
<el-form-item label="社交登录" prop="social"> | <el-form-item label="社交登录" prop="social"> | ||||
<a href="#" class="icon-weixin1" @click="handleClick('wechat')"></a>| | <a href="#" class="icon-weixin1" @click="handleClick('wechat')"></a>| | ||||
<a href="#" class="icon-qq" @click="handleClick('tencent')"></a> | | <a href="#" class="icon-qq" @click="handleClick('tencent')"></a> | | ||||
<a href="#" class="icon-gitee-fill-round" @click="handleClick('gitee')"></a> | | <a href="#" class="icon-gitee-fill-round" @click="handleClick('gitee')"></a> | | ||||
<a href="#" class="icon-C" @click="handleClick('osc')"></a> | <a href="#" class="icon-C" @click="handleClick('osc')"></a> | ||||
</el-form-item> | |||||
</el-form-item> --> | |||||
<el-form-item label="原密码" prop="password"> | <el-form-item label="原密码" prop="password"> | ||||
<el-input v-model="ruleForm.password" type="password" auto-complete="off" /> | <el-input v-model="ruleForm.password" type="password" auto-complete="off" /> | ||||
</el-form-item> | </el-form-item> | ||||
@@ -116,6 +100,7 @@ export default { | |||||
newpassword2: "", | newpassword2: "", | ||||
avatar: "", | avatar: "", | ||||
phone: "", | phone: "", | ||||
userId:'', | |||||
}, | }, | ||||
rules: { | rules: { | ||||
phone: [{ required: false, validator: validatePhone, trigger: "blur" }], | phone: [{ required: false, validator: validatePhone, trigger: "blur" }], | ||||
@@ -155,13 +140,25 @@ export default { | |||||
if (!valid) { | if (!valid) { | ||||
return false; | return false; | ||||
} | } | ||||
editInfo(this.ruleForm).then((response) => { | |||||
this.$notify.success("修改成功"); | |||||
// 修改后注销当前token,重新登录 | |||||
this.$store.dispatch("LogOut").then(() => { | |||||
this.$api.api.resetPassword({ | |||||
userId:this.ruleForm.userId, | |||||
password:this.ruleForm.newpassword1 | |||||
}).then((res) => { | |||||
// console.log(res); | |||||
this.$notify.success("修改成功"); | |||||
this.$store.dispatch("LogOut").then(() => { | |||||
location.reload(); | location.reload(); | ||||
}); | |||||
}); | }); | ||||
}); | |||||
// editInfo(this.ruleForm).then((response) => { | |||||
// this.$notify.success("修改成功"); | |||||
// // 修改后注销当前token,重新登录 | |||||
// this.$store.dispatch("LogOut").then(() => { | |||||
// location.reload(); | |||||
// }); | |||||
// }); | |||||
}); | }); | ||||
}, | }, | ||||
resetForm() { | resetForm() { | ||||
@@ -171,6 +168,7 @@ export default { | |||||
this.ruleForm.username = this.userInfo.username; | this.ruleForm.username = this.userInfo.username; | ||||
this.ruleForm.phone = this.userInfo.phone; | this.ruleForm.phone = this.userInfo.phone; | ||||
this.ruleForm.avatar = this.userInfo.avatar; | this.ruleForm.avatar = this.userInfo.avatar; | ||||
this.ruleForm.userId = this.userInfo.userId; | |||||
handleImg(this.userInfo.avatar, "avatar"); | handleImg(this.userInfo.avatar, "avatar"); | ||||
//判断是否选择了租户ID | //判断是否选择了租户ID | ||||
const TENANT_ID = getStore({ name: "tenantId" }); | const TENANT_ID = getStore({ name: "tenantId" }); | ||||
@@ -65,6 +65,8 @@ | |||||
v-model="searchForm.houseType" | v-model="searchForm.houseType" | ||||
placeholder="请选择" | placeholder="请选择" | ||||
class="div-inp" | class="div-inp" | ||||
filterable | |||||
clearable | |||||
> | > | ||||
<el-option | <el-option | ||||
v-for="item in options" | v-for="item in options" | ||||
@@ -81,6 +83,8 @@ | |||||
v-model="searchForm.serviceStatus" | v-model="searchForm.serviceStatus" | ||||
placeholder="请选择" | placeholder="请选择" | ||||
class="div-inp" | class="div-inp" | ||||
filterable | |||||
clearable | |||||
> | > | ||||
<el-option | <el-option | ||||
v-for="item in options1" | v-for="item in options1" | ||||
@@ -298,7 +302,7 @@ | |||||
</el-select> | </el-select> | ||||
</el-form-item> | </el-form-item> | ||||
<el-form-item label="楼盘类型" prop="houseType" v-if="orgType != 2"> | <el-form-item label="楼盘类型" prop="houseType" v-if="orgType != 2"> | ||||
<el-radio-group v-model="ruleForm.houseType"> | |||||
<el-radio-group v-model="ruleForm.houseType" style="width:400px;"> | |||||
<el-radio :label="0">正式</el-radio> | <el-radio :label="0">正式</el-radio> | ||||
<el-radio :label="1">试用</el-radio> | <el-radio :label="1">试用</el-radio> | ||||
<el-radio :label="2">演示</el-radio> | <el-radio :label="2">演示</el-radio> | ||||
@@ -583,16 +587,19 @@ export default { | |||||
orgCode:localStorage.getItem('orgCode'), | orgCode:localStorage.getItem('orgCode'), | ||||
}) | }) | ||||
.then(res1=>{ | .then(res1=>{ | ||||
callback(); | |||||
this.resetFlag=true | |||||
this.passFlag=true | this.passFlag=true | ||||
if(this.changeFlag){ | if(this.changeFlag){ | ||||
this.accountForm.managerPassword=res.data.sysUser.resultPwd | this.accountForm.managerPassword=res.data.sysUser.resultPwd | ||||
}else{ | }else{ | ||||
this.ruleForm.managerPassword=res.data.sysUser.resultPwd | this.ruleForm.managerPassword=res.data.sysUser.resultPwd | ||||
} | } | ||||
callback(); | |||||
}) | }) | ||||
.catch(err=>{ | .catch(err=>{ | ||||
console.log(err) | console.log(err) | ||||
// | |||||
this.resetFlag=false | |||||
callback(new Error(err)); | callback(new Error(err)); | ||||
}) | }) | ||||
} else { | } else { | ||||
@@ -604,6 +611,7 @@ export default { | |||||
}else{ | }else{ | ||||
this.ruleForm.managerPassword='' | this.ruleForm.managerPassword='' | ||||
} | } | ||||
this.resetFlag=false | |||||
this.passFlag=false | this.passFlag=false | ||||
callback(); | callback(); | ||||
@@ -647,6 +655,7 @@ export default { | |||||
editFlag: false, | editFlag: false, | ||||
changeFlag: false, | changeFlag: false, | ||||
operaVisible: false, | operaVisible: false, | ||||
resetFlag:false, | |||||
passFlag:false, | passFlag:false, | ||||
starTime: [], | starTime: [], | ||||
searchForm: { | searchForm: { | ||||
@@ -912,6 +921,10 @@ export default { | |||||
}, | }, | ||||
// 添加楼盘 | // 添加楼盘 | ||||
addSure() { | addSure() { | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
// console.log(this.addressOptions) | // console.log(this.addressOptions) | ||||
this.$refs.ruleForm.validate((valid) => { | this.$refs.ruleForm.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
@@ -1019,6 +1032,10 @@ export default { | |||||
this.accountForm.id = row.id; | this.accountForm.id = row.id; | ||||
}, | }, | ||||
changeSure() { | changeSure() { | ||||
if(!this.resetFlag){ | |||||
this.$message.error('平台用户与楼盘用户不能重复添加!') | |||||
return | |||||
} | |||||
this.$refs.accountForm.validate((valid) => { | this.$refs.accountForm.validate((valid) => { | ||||
if (valid) { | if (valid) { | ||||
this.$api.api.updateManagerPhone(this.accountForm).then((res) => { | this.$api.api.updateManagerPhone(this.accountForm).then((res) => { | ||||