Merge remote-tracking branch 'origin/master'

This commit is contained in:
wangzhijiang
2022-06-15 10:57:21 +08:00
8 changed files with 44 additions and 28 deletions
@@ -211,7 +211,7 @@ public class SyncDataServiceImpl implements ISyncDataService{
if (!localUserMap.containsKey(ppEmployee.getId())) { if (!localUserMap.containsKey(ppEmployee.getId())) {
//删除数据库中与该账户相同的数据 //删除数据库中与该账户相同的数据
if(StringUtils.isNotBlank(ppEmployee.getId())) { if(StringUtils.isNotBlank(ppEmployee.getId())) {
sysUserService.removeById(ppEmployee.getId()); // sysUserService.removeById(ppEmployee.getId()); // 这个为什么是逻辑删除
log.info("需要新增的用户信息为:" + JSONObject.toJSONString(ppEmployee)); log.info("需要新增的用户信息为:" + JSONObject.toJSONString(ppEmployee));
SysUser newUser = sysUserService.addPPUserInfo(ppEmployee); SysUser newUser = sysUserService.addPPUserInfo(ppEmployee);
localUserMap.put(ppEmployee.getId(), newUser); localUserMap.put(ppEmployee.getId(), newUser);
@@ -260,16 +260,16 @@ public class SyncDataServiceImpl implements ISyncDataService{
} }
List<PPEmployee> userEmailInfoList = JSONObject.parseArray(user.get("people_contact_email").toString(), PPEmployee.class); List<PPEmployee> userEmailInfoList = JSONObject.parseArray(user.get("people_contact_email").toString(), PPEmployee.class);
if (CollectionUtil.isNotEmpty(userEmailInfoList)) { if (CollectionUtil.isNotEmpty(userEmailInfoList)) {
PPEmployee userEmailInfo = userEmailInfoList.stream().filter(e->"WORK".equals(e.getEmail_type())).collect(Collectors.toList()).get(0); List<PPEmployee> userEmailInfo = userEmailInfoList.stream().filter(e->"WORK".equals(e.getEmail_type())).collect(Collectors.toList());
if (ObjectUtil.isNotEmpty(userEmailInfo)) { if (CollectionUtil.isNotEmpty(userEmailInfo)) {
userMainInfo.setEmail_address(userEmailInfo.getEmail_address()); userMainInfo.setEmail_address(userEmailInfo.get(0).getEmail_address());
} }
} }
List<PPEmployee> userPhoneInfoList = JSONObject.parseArray(user.get("people_contact_phone").toString(), PPEmployee.class); List<PPEmployee> userPhoneInfoList = JSONObject.parseArray(user.get("people_contact_phone").toString(), PPEmployee.class);
if (CollectionUtil.isNotEmpty(userPhoneInfoList)) { if (CollectionUtil.isNotEmpty(userPhoneInfoList)) {
PPEmployee userPhoneInfo = userPhoneInfoList.stream().filter(e->"WORK".equals(e.getPhone_type()) && "Mobile".equals(e.getPhone_device_type())).collect(Collectors.toList()).get(0); List<PPEmployee> userPhoneInfo = userPhoneInfoList.stream().filter(e->"WORK".equals(e.getPhone_type()) && "Mobile".equals(e.getPhone_device_type())).collect(Collectors.toList());
if (ObjectUtil.isNotEmpty(userPhoneInfo)) { if (CollectionUtil.isNotEmpty(userPhoneInfo)) {
userMainInfo.setFormatted_phone_number(userPhoneInfo.getFormatted_phone_number()); userMainInfo.setFormatted_phone_number(userPhoneInfo.get(0).getFormatted_phone_number());
} }
} }
+1
View File
@@ -712,6 +712,7 @@ module.exports = {
uploadTime: 'Upload time', uploadTime: 'Upload time',
enclosure: 'Enclosure', enclosure: 'Enclosure',
// 认证 // 认证
Theselectedconfiguration: 'The selected item has incomplete data collection, unable to add configuration',
theCurrent: 'The current status of this data is', theCurrent: 'The current status of this data is',
thisbuttonCompleted: 'This button can only be operated when the status is completed', thisbuttonCompleted: 'This button can only be operated when the status is completed',
Frozenstatus: 'Frozen status, can only be viewed', Frozenstatus: 'Frozen status, can only be viewed',
+1
View File
@@ -723,6 +723,7 @@ module.exports = {
uploadTime: '上传时间', uploadTime: '上传时间',
enclosure: '附件', enclosure: '附件',
// 认证 // 认证
Theselectedconfiguration: '所选项目有未完成收集数据,不能添加配置',
theCurrent: '此数据当前状态为', theCurrent: '此数据当前状态为',
thisbuttonCompleted: '当状态为"已完成"时,才可操作此按钮', thisbuttonCompleted: '当状态为"已完成"时,才可操作此按钮',
Frozenstatus: '冻结状态,仅可以查看', Frozenstatus: '冻结状态,仅可以查看',
+10 -7
View File
@@ -10,19 +10,19 @@
:wrapper-col='wrapperCol' :wrapper-col='wrapperCol'
> >
<a-row :gutter='24'> <a-row :gutter='24'>
<!-- <a-col :span='9'>--> <a-col :span='9'>
<!-- <a-form-model-item ref='paramsTemplateName' :label="$t('fullName')" prop='paramsTemplateName'>--> <a-form-model-item ref='paramsTemplateName' :label="$t('fullName')" prop='paramsTemplateName'>
<!-- <a-input--> <a-input
<!-- v-model='form.realname' />--> v-model='form.realname' />
<!-- </a-form-model-item>--> </a-form-model-item>
<!-- </a-col>--> </a-col>
<a-col :span='9'> <a-col :span='9'>
<a-form-model-item ref='paramsTemplateName' :label="$t('accountNumber')" prop='paramsTemplateName'> <a-form-model-item ref='paramsTemplateName' :label="$t('accountNumber')" prop='paramsTemplateName'>
<a-input <a-input
v-model='form.username' /> v-model='form.username' />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span='6'> <a-col :span='6' style='margin-top: 5px;'>
<a-button class='box-button' type='primary' @click='searchQuery'>{{ $t('query') }}</a-button> <a-button class='box-button' type='primary' @click='searchQuery'>{{ $t('query') }}</a-button>
<a-button class='box-button' style='margin-left: 8px' @click='searchReset'>{{ $t('reset') }}</a-button> <a-button class='box-button' style='margin-left: 8px' @click='searchReset'>{{ $t('reset') }}</a-button>
</a-col> </a-col>
@@ -141,6 +141,9 @@ export default {
if(this.form.username !== undefined) { if(this.form.username !== undefined) {
params.username = `*${this.form.username}*` params.username = `*${this.form.username}*`
} }
if(this.form.realname !== undefined) {
params.realname = `*${this.form.realname}*`
}
getAction(`sys/user/page`, params).then(res => { getAction(`sys/user/page`, params).then(res => {
if (res.success) { if (res.success) {
this.areaTable = [...res.result.records] this.areaTable = [...res.result.records]
@@ -60,7 +60,7 @@
<a @click="entryNameClick(record)">{{text}}</a> <a @click="entryNameClick(record)">{{text}}</a>
</span> </span>
<span slot="titleName" slot-scope="text,record" :title="text"> <span slot="titleName" slot-scope="text,record" :title="text">
{{ text && text.length > 100 ? text.slice(0, 99) + '...' : text }} {{ text && text.length > 80 ? text.slice(0, 79) + '...' : text }}
</span> </span>
<span slot="operation" slot-scope="text,record"> <span slot="operation" slot-scope="text,record">
<a class="text-operation" v-has="'params:template:edit'" @click="edit(record)">{{$t('edit')}}</a> <a class="text-operation" v-has="'params:template:edit'" @click="edit(record)">{{$t('edit')}}</a>
@@ -80,7 +80,7 @@
:projectId='this.$route.query.id'></parameter-template-add> :projectId='this.$route.query.id'></parameter-template-add>
</a-modal> </a-modal>
<!-- 配置--> <!-- 配置-->
<configure ref="configureRef" :url='url' :itemId='itemId'/> <configure ref="configureRef" :url='url' :itemId='itemId' :itemRow='itemRow'/>
<!-- 历史版本--> <!-- 历史版本-->
<a-modal v-model="historicalVisible" :title="$t('historicalVersion')" width='750px' :footer="null"> <a-modal v-model="historicalVisible" :title="$t('historicalVersion')" width='750px' :footer="null">
<historical-version v-if='historicalVisible' :historicalRow='historicalRow'></historical-version> <historical-version v-if='historicalVisible' :historicalRow='historicalRow'></historical-version>
@@ -188,7 +188,8 @@
templatetitleId: '', templatetitleId: '',
rowId: '', rowId: '',
version: 0, version: 0,
itemId: '', itemId: '', // 配置id
itemRow: {}, // 配置一行数据
historicalVisible: false, historicalVisible: false,
historicalRow: {}, // 历史版本得数据 historicalRow: {}, // 历史版本得数据
drawerVisible: false, drawerVisible: false,
@@ -239,8 +240,9 @@
}, },
// 配置 // 配置
configure(item) { configure(item) {
this.itemId = item.id this.itemId = item.id
this.$refs.configureRef.addModel(item.id) this.itemRow = item
this.$refs.configureRef.addModel(item.id)
}, },
handleCancel(val) { handleCancel(val) {
this.areaVisible = val this.areaVisible = val
@@ -40,7 +40,7 @@
v-model='form.paramsTemplateName' /> v-model='form.paramsTemplateName' />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span='6'> <a-col :span='6' style='margin-top: 5px'>
<a-button class='box-button' type='primary' @click='searchQuery'>{{ $t('query') }}</a-button> <a-button class='box-button' type='primary' @click='searchQuery'>{{ $t('query') }}</a-button>
<a-button class='box-button' style='margin-left: 8px' @click='searchReset'>{{ $t('reset') }}</a-button> <a-button class='box-button' style='margin-left: 8px' @click='searchReset'>{{ $t('reset') }}</a-button>
</a-col> </a-col>
@@ -130,6 +130,11 @@ export default {
type: Object, type: Object,
default: '', default: '',
require: true require: true
},
itemRow: {
type: Object,
default: '',
require: true
} }
}, },
data() { data() {
@@ -200,14 +205,18 @@ export default {
}) })
}, },
addConfiguration(item) { addConfiguration(item) {
this.paramsConfigEOList.splice(item.displaySeq + 1,0,{ if(this.itemRow.configFlag) {
id: '', this.paramsConfigEOList.splice(item.displaySeq + 1,0,{
configName: '', // 配置名称 id: '',
version: '', // 版本 configName: '', // 配置名称
carType: '', // 车型 version: '', // 版本
battery: '', // 电池 carType: '', // 车型
motor: '', // 电机 battery: '', // 电池
}) motor: '', // 电机
})
} else {
this.$message.warning(this.$t('Theselectedconfiguration'))
}
}, },
deleteConfiguration(displaySeq,index) { deleteConfiguration(displaySeq,index) {
if(this.paramsConfigEOList.length === 1) { if(this.paramsConfigEOList.length === 1) {