Merge remote-tracking branch 'origin/dev_third_stage' into dev_third_stage
This commit is contained in:
+1
-1
@@ -2586,7 +2586,7 @@ public class FileSpiltService {
|
||||
String path = splitUrl+"/jero-boot/sys/split/file/getImage?fileUrl="+filepathandname;
|
||||
CosBootUtil.uploadByte(bytev, filepathandname);
|
||||
String imgCon = path;
|
||||
String imgConVal = "<img class=\"wordImg\" src=\"" + path + "\">";
|
||||
String imgConVal = "<img class=\"wordImg\" style=\"width:100%;height:100%\" src=\"" + path + "\">";
|
||||
message.getItemsCondi().add(imgConVal);
|
||||
message.setItermsConditions(message.getItermsConditions() + imgConVal);
|
||||
itemsValList.add(getSplitItemsValObject(message.getId(), SplitFilePragraTypeEnum.IMG.getValue(), imgCon, message.getItemsCondi().size(), null));
|
||||
|
||||
+33
-5
@@ -158,7 +158,7 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
} else if ("IMG".equals(valEO.getType())) {
|
||||
String imgUrl = valEO.getItemContent();
|
||||
valEO.setItemContent(imgUrl);
|
||||
valContent = "<img class=\"wordImg\" src=\""+ valEO.getItemContent() +"\">";
|
||||
valContent = "<img class=\"wordImg\" style=\"width:100%;height:100%\" src=\""+ valEO.getItemContent() +"\">";
|
||||
// valContent = valEO.getItemContent();
|
||||
} else if ("TABLE".equals(valEO.getType())) {
|
||||
valContent = valEO.getItemContent();
|
||||
@@ -233,7 +233,7 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
} else if ("IMG".equals(valEO.getType())) {
|
||||
String imgUrl = valEO.getItemContent();
|
||||
valEO.setItemContent(imgUrl);
|
||||
valContent = "<img class=\"wordImg\" src=\"" + valEO.getItemContent() + "\">";
|
||||
valContent = "<img class=\"wordImg\" style=\"width:100%;height:100%\" src=\"" + valEO.getItemContent() + "\">";
|
||||
// valContent = valEO.getItemContent();
|
||||
} else if ("TABLE".equals(valEO.getType())) {
|
||||
valContent = valEO.getItemContent();
|
||||
@@ -1693,7 +1693,7 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
return mFile;
|
||||
}
|
||||
|
||||
private List<Map<String, Object>> read(File file, List<String> dbfieldList, String[] titles, String cut) throws IOException, InvalidFormatException {
|
||||
private List<Map<String, Object>> read(File file, List<String> dbfieldList, String[] titles, String cut) throws Exception {
|
||||
|
||||
//最终返回数据
|
||||
List<Map<String, Object>> list = new ArrayList<>();
|
||||
@@ -1744,10 +1744,38 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
}
|
||||
}
|
||||
}
|
||||
Row rowDescription= sheet.getRow(1);
|
||||
if (rowDescription != null) {
|
||||
Cell cell = rowDescription.getCell(0);
|
||||
if(ObjectUtil.isNotNull(cell)){
|
||||
//设置单元格类型
|
||||
cell.setCellType(CellType.STRING);
|
||||
String cellValue = cell.getStringCellValue();
|
||||
if(!cellValue.contains("填写说明")){
|
||||
if(CutEnum.CN.getValue().equals(cut)){
|
||||
throw new JeroBootException("请导入正确模板!");
|
||||
} else {
|
||||
throw new JeroBootException("Please import the correct template");
|
||||
}
|
||||
}
|
||||
} else{
|
||||
if(CutEnum.CN.getValue().equals(cut)){
|
||||
throw new JeroBootException("请导入正确模板!");
|
||||
} else {
|
||||
throw new JeroBootException("Please import the correct template");
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(CutEnum.CN.getValue().equals(cut)){
|
||||
throw new JeroBootException("请导入正确模板!");
|
||||
} else {
|
||||
throw new JeroBootException("Please import the correct template");
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, Object> map = null;
|
||||
//获得所有数据
|
||||
//从第x行开始获取
|
||||
//从第3行开始获取,第一行是表头,第二行是填写说明
|
||||
for (int x = 2; x <= totalRowNum; x++) {
|
||||
map = new HashMap<String, Object>();
|
||||
//获得第i行对象
|
||||
@@ -2461,7 +2489,7 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl<FileSplitItemsEOMap
|
||||
if ("TEXT".equals(valEO.getType())) {
|
||||
valContent += "<p>" + valEO.getItemContent() + "</p>";
|
||||
} else if ("IMG".equals(valEO.getType())) {
|
||||
valContent += "<img class=\"wordImg\" src=\""+ valEO.getItemContent() +"\">";
|
||||
valContent += "<img class=\"wordImg\" style=\"width:100%;height:100%\" src=\""+ valEO.getItemContent() +"\">";
|
||||
// valContent += valEO.getItemContent();
|
||||
} else if ("TABLE".equals(valEO.getType())) {
|
||||
valContent += valEO.getItemContent();
|
||||
|
||||
+2
-2
@@ -64,8 +64,8 @@ public class LawsWarnController {
|
||||
@ApiOperation(value = "推送")
|
||||
@GetMapping(value = "/warnPullMessage")
|
||||
// @RequiresPermissions("document:pullMessage")
|
||||
public Result<?> pullMessage(String departIds,String userIds,String documentIds) {
|
||||
lawsWarnService.warnPullMessage(departIds,userIds,documentIds);
|
||||
public Result<?> pullMessage(String departIds,String userIds,String documentIds,String flag) {
|
||||
lawsWarnService.warnPullMessage(departIds,userIds,documentIds,flag);
|
||||
return Result.OK("推送成功");
|
||||
}
|
||||
}
|
||||
|
||||
+129
-6
@@ -338,7 +338,7 @@ public class LawsWarnService {
|
||||
}
|
||||
|
||||
|
||||
public String warnPullMessage(String departIds, String userIds, String documentIds) {
|
||||
public String warnPullMessage(String departIds, String userIds, String documentIds,String flag) {
|
||||
Set<String> allDepartIds = new HashSet<>();
|
||||
//查询当前部门下所有部门
|
||||
if (StringUtils.isNotEmpty(departIds)) {
|
||||
@@ -379,6 +379,25 @@ public class LawsWarnService {
|
||||
List<String> urlList = new ArrayList<>();
|
||||
List<String> hrefList = new ArrayList<>();
|
||||
for (Map<String, Object> map : mapList) {
|
||||
//1-->新车型实施日期, 2-->在产车实施日期
|
||||
String timeContent = "";
|
||||
if("1".equals(flag)){
|
||||
String value = StringUtils.valueOf(map.get("xin1_che1_xing2_shi2_shi1_ri4_qi1"));
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
if(value.contains(" ")){
|
||||
value = value.split(" ")[0];
|
||||
}
|
||||
timeContent =" to you as the implementation date of the new model is " +value;
|
||||
}
|
||||
}else if("2".equals(flag)){
|
||||
String value = StringUtils.valueOf(map.get("implement_time"));
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
if(value.contains(" ")){
|
||||
value = value.split(" ")[0];
|
||||
}
|
||||
timeContent =" to you as the implementation date of vehicle production is " +value;
|
||||
}
|
||||
}
|
||||
serialNumberList.add(StringUtils.valueOf(map.get("serial_number")));
|
||||
String url = backUrl + "/docManage/library/detail?id=" + map.get("id") +
|
||||
"&title=" + map.get("title") +
|
||||
@@ -388,13 +407,16 @@ public class LawsWarnService {
|
||||
"&title=" + map.get("title") +
|
||||
"&serial_number=" + map.get("serial_number") + "'" + " target='_blank'>" + map.get("serial_number") + "</a>";
|
||||
urlList.add(url);
|
||||
hrefList.add(href);
|
||||
hrefList.add(href+timeContent);
|
||||
}
|
||||
|
||||
|
||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
String content = sysUser.getUsername() + " pushed " + StringUtils.join(serialNumberList, ",") + " to you. Please be reminded to check it out.";
|
||||
String contentInfo = sysUser.getUsername() + " pushed " + StringUtils.join(hrefList, ",") + " to you. Please be reminded to check it out.";
|
||||
String content = StringUtils.join(serialNumberList, ",") + " has been shared with you, please check.";
|
||||
//消息详情模板
|
||||
// XXX has pushed GB 7258 to you as the implementation date of vehicle production is XXXX-XX-XX,
|
||||
// GB 7258 to you as the implementation date of vehicle production is XXXX-XX-XX, Please be reminded to check it out.
|
||||
String contentInfo = sysUser.getUsername() + " has pushed " + StringUtils.join(hrefList, ",") + ", Please be reminded to check it out.";
|
||||
String title = content;
|
||||
|
||||
//封装消息的实体类
|
||||
@@ -409,10 +431,28 @@ public class LawsWarnService {
|
||||
mapList.stream().forEach(e->{
|
||||
if(s.contains((String)e.get("id"))){
|
||||
String serialNumber = StringUtils.valueOf(e.get("serial_number"));
|
||||
list.add(serialNumber);
|
||||
String timeContent = "";
|
||||
if("1".equals(flag)){
|
||||
String value = StringUtils.valueOf(e.get("xin1_che1_xing2_shi2_shi1_ri4_qi1"));
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
if(value.contains(" ")){
|
||||
value = value.split(" ")[0];
|
||||
}
|
||||
timeContent =" to you as the implementation date of the new model is " +value;
|
||||
}
|
||||
}else if("2".equals(flag)){
|
||||
String value = StringUtils.valueOf(e.get("implement_time"));
|
||||
if(StringUtils.isNotBlank(value)){
|
||||
if(value.contains(" ")){
|
||||
value = value.split(" ")[0];
|
||||
}
|
||||
timeContent =" to you as the implementation date of vehicle production is " +value;
|
||||
}
|
||||
}
|
||||
list.add(serialNumber + timeContent);
|
||||
}
|
||||
});
|
||||
String contentTemp = sysUser.getUsername() + " pushed " + StringUtils.join(list, ",") + " to you. Please be reminded to check it out.";
|
||||
String contentTemp = sysUser.getUsername() + " has pushed " + StringUtils.join(list, ",") + ", Please be reminded to check it out.";
|
||||
iFeishuService.batchSendMessage(thirdIdList.toArray(new String[]{}), contentTemp, MessageTypeEnum.PUSH.getName(), encode);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
@@ -421,4 +461,87 @@ public class LawsWarnService {
|
||||
bussDocumentLibraryEOService.sendWebsocket(documentIds, contentInfo);
|
||||
return "推送成功";
|
||||
}
|
||||
// public String warnPullMessage(String departIds, String userIds, String documentIds,String flag) {
|
||||
// Set<String> allDepartIds = new HashSet<>();
|
||||
// //查询当前部门下所有部门
|
||||
// if (StringUtils.isNotEmpty(departIds)) {
|
||||
// String[] departIdArr = departIds.split(",");
|
||||
// for (String departId : departIdArr) {
|
||||
// List<String> subDepIdsByDepId = sysDepartService.getSubDepIdsByDepId(departId);
|
||||
// allDepartIds.addAll(subDepIdsByDepId);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// List<String> userIdList = new ArrayList<>();
|
||||
// List<String> thirdIdList = new ArrayList<>();
|
||||
// if (StringUtils.isNotBlank(departIds)) {
|
||||
// //查询部门下的人员
|
||||
// List<SysUser> userList = new ArrayList<>();
|
||||
// if(allDepartIds.size() != 0){
|
||||
// userList = sysUserService.getUserListByDepIds(new ArrayList<>(allDepartIds));
|
||||
// }
|
||||
//
|
||||
// if (userList.size() != 0) {
|
||||
// userIdList = userList.stream().map(SysUser::getId).distinct().collect(Collectors.toList());
|
||||
// thirdIdList = userList.stream().map(SysUser::getThirdId).distinct().collect(Collectors.toList());
|
||||
// }
|
||||
// }
|
||||
// if(userIdList.size() == 0 && StringUtils.isNotBlank(userIds)){
|
||||
// List<SysUser> sysUsers = sysUserService.listByIds(Arrays.asList(userIds.split(",")));
|
||||
// if(sysUsers.size() != 0){
|
||||
// List<String> userId = sysUsers.stream().map(SysUser::getId).collect(Collectors.toList());
|
||||
// List<String> thirdId = sysUsers.stream().map(SysUser::getThirdId).collect(Collectors.toList());
|
||||
// userIdList.addAll(userId);
|
||||
// thirdIdList.addAll(thirdId);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// //查询文档
|
||||
// List<Map<String, Object>> mapList = bussDocumentLibraryEOMapper.selectMapsAll(documentIds);
|
||||
// List<String> serialNumberList = new ArrayList<>();
|
||||
// List<String> urlList = new ArrayList<>();
|
||||
// List<String> hrefList = new ArrayList<>();
|
||||
// for (Map<String, Object> map : mapList) {
|
||||
// serialNumberList.add(StringUtils.valueOf(map.get("serial_number")));
|
||||
// String url = backUrl + "/docManage/library/detail?id=" + map.get("id") +
|
||||
// "&title=" + map.get("title") +
|
||||
// "&serial_number=" + map.get("serial_number");
|
||||
//
|
||||
// String href = "<a href='/docManage/library/detail?id=" + map.get("id") +
|
||||
// "&title=" + map.get("title") +
|
||||
// "&serial_number=" + map.get("serial_number") + "'" + " target='_blank'>" + map.get("serial_number") + "</a>";
|
||||
// urlList.add(url);
|
||||
// hrefList.add(href);
|
||||
// }
|
||||
//
|
||||
//
|
||||
// LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
// String content = sysUser.getUsername() + " pushed " + StringUtils.join(serialNumberList, ",") + " to you. Please be reminded to check it out.";
|
||||
// String contentInfo = sysUser.getUsername() + " pushed " + StringUtils.join(hrefList, ",") + " to you. Please be reminded to check it out.";
|
||||
// String title = content;
|
||||
//
|
||||
// //封装消息的实体类
|
||||
// SysAnnouncement sysAnnouncement = bussDocumentLibraryEOService.getSysAnnouncement(userIdList, title, content, contentInfo,MessageTypeEnum.PUSH.getValue(),MessageTypeEnum.SYSTEMATIC_NOTIFICATION.getName());
|
||||
// sysAnnouncementService.saveAnnouncement(sysAnnouncement);
|
||||
// bussDocumentLibraryEOService.sendWebsocket(StringUtils.join(thirdIdList, ","), contentInfo);
|
||||
// //飞书
|
||||
// try {
|
||||
// for (String s : urlList) {
|
||||
// String encode = UriEncoder.encode(s);
|
||||
// List<String> list = new ArrayList<>();
|
||||
// mapList.stream().forEach(e->{
|
||||
// if(s.contains((String)e.get("id"))){
|
||||
// String serialNumber = StringUtils.valueOf(e.get("serial_number"));
|
||||
// list.add(serialNumber);
|
||||
// }
|
||||
// });
|
||||
// String contentTemp = sysUser.getUsername() + " pushed " + StringUtils.join(list, ",") + " to you. Please be reminded to check it out.";
|
||||
// iFeishuService.batchSendMessage(thirdIdList.toArray(new String[]{}), contentTemp, MessageTypeEnum.PUSH.getName(), encode);
|
||||
// }
|
||||
// } catch (IOException e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
// bussDocumentLibraryEOService.sendWebsocket(documentIds, contentInfo);
|
||||
// return "推送成功";
|
||||
// }
|
||||
}
|
||||
|
||||
@@ -124,6 +124,10 @@
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
eventBUs.$on('searchGetData', target => {
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
this.userData = this.userInfo()
|
||||
|
||||
@@ -0,0 +1,318 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="box-title-text" v-if="!isInput">
|
||||
<a-input class="box-input" :value="value" @input="indexclick($event)"
|
||||
:disabled="true"
|
||||
:title="value"
|
||||
:placeholder="$t('PleaseSelect')+query.db_field_txt"/>
|
||||
<a-button type="primary" class="button-box" :disabled="disabled" @click="standardClick">
|
||||
{{this.$t('PersonnelSelection')}}
|
||||
</a-button>
|
||||
<a-button type="primary" v-if='isDelete' class="button-box" @click="standardDelete">
|
||||
{{this.$t('delete')}}
|
||||
</a-button>
|
||||
</div>
|
||||
<div class="box-title-text" v-if="isInput">
|
||||
<a-input :class="{'box-input':!isClass}" :value="value"
|
||||
readonly
|
||||
:title="value"
|
||||
@click.native="standardClick"
|
||||
:placeholder="$t('PleaseSelect')+query.db_field_txt"/>
|
||||
</div>
|
||||
<a-drawer
|
||||
:title="$t('PersonnelSelection')"
|
||||
:maskClosable="false"
|
||||
:width="600"
|
||||
placement="right"
|
||||
:closable="true"
|
||||
@close="handleCancel"
|
||||
:visible="visible"
|
||||
style="height: 100%;overflow: auto;padding-bottom: 53px;">
|
||||
<a-input-search style="margin-bottom: 8px" :placeholder="$t('NodeQuickLookup')"
|
||||
v-model="searchModel" @search="onSearch"/>
|
||||
<div class="drawer-content">
|
||||
<!-- checkStrictly-->
|
||||
<a-tree
|
||||
style="margin-bottom: 60px;height: 600px"
|
||||
v-if="treeVisible"
|
||||
checkable
|
||||
|
||||
:loading="loading"
|
||||
:tree-data="gData"
|
||||
@check="onCheck"
|
||||
@expand="onExpand"
|
||||
v-model:checkedKeys="defaultCheckedKeys"
|
||||
:defaultExpandedKeys="defaultExpandedKeys"
|
||||
>
|
||||
</a-tree>
|
||||
</div>
|
||||
|
||||
<div class="drawer-bootom-button">
|
||||
<a-button @click="handleCancel" type="danger" style="margin-right: 16px">{{$t('cancel')}}</a-button>
|
||||
<a-button @click="handleSubmit" type="primary">{{$t('submit')}}</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getAction, postAction } from '@/api/manage'
|
||||
|
||||
export default {
|
||||
name: 'index',
|
||||
props: ['query', 'value', 'personneQuery', 'isSingleChoice', 'isInput', 'isClass', 'isDelete', 'disabled'],
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
gData: [],
|
||||
autoExpandParent: true,
|
||||
expandedKeys: [],
|
||||
visible: false,
|
||||
treeVisible: false,
|
||||
confirmLoading: false,
|
||||
departId: '',
|
||||
selectedKey: [],
|
||||
userIds: [],
|
||||
searchModel: '',
|
||||
defaultExpandedKeys: [],
|
||||
defaultCheckedKeys: [],
|
||||
defaultCheckedKeysName: [],
|
||||
content: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
standardClick() {
|
||||
this.treeVisible = false
|
||||
this.departId = ''
|
||||
this.searchModel = ''
|
||||
this.userIds = []
|
||||
this.userName = []
|
||||
this.queryDepartUserTreeList(1)
|
||||
this.visible = true
|
||||
},
|
||||
standardDelete() {
|
||||
this.$emit('input', null)
|
||||
this.$forceUpdate()
|
||||
this.$emit('deleteData', this.query.db_field_name)
|
||||
},
|
||||
// onSelect(selectedKeys, info) {
|
||||
// console.log(selectedKeys)
|
||||
// this.selectedKey = selectedKeys
|
||||
// },
|
||||
|
||||
onCheck(checkedKeys, info) {
|
||||
console.log(checkedKeys, info)
|
||||
this.userIds = checkedKeys
|
||||
this.userName = []
|
||||
if (this.userIds.length > 0) {
|
||||
for (let i = 0; i < this.userIds.length; i++) {
|
||||
for (let j = 0; j < this.defaultCheckedKeysName.length; j++) {
|
||||
if (this.userIds[i] == this.defaultCheckedKeysName[j].id) {
|
||||
this.userName.push(this.defaultCheckedKeysName[j].name)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (info.checkedNodes && info.checkedNodes.length > 0) {
|
||||
info.checkedNodes.forEach(res => {
|
||||
if (res.data.props.dataRef.key) {
|
||||
this.content.push({
|
||||
id: res.data.props.dataRef.key,
|
||||
title: res.data.props.dataRef.title
|
||||
})
|
||||
} else {
|
||||
this.content.push({
|
||||
id: res.data.props.id,
|
||||
title: res.data.props.title
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
if (this.content && this.content.length > 0) {
|
||||
for (let i = 0; i < this.content.length; i++) {
|
||||
for (let j = i + 1; j < this.content.length; j++) {
|
||||
if (this.content[i].id == this.content[j].id) {
|
||||
this.content.splice(j, 1)
|
||||
j--
|
||||
}
|
||||
}
|
||||
}
|
||||
this.userIds.forEach(res => {
|
||||
this.content.forEach(val => {
|
||||
if (res == val.id) {
|
||||
this.userName.push(val.title)
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
if (this.userName.length > 0) {
|
||||
for (let i = 0; i < this.userName.length; i++) {
|
||||
for (let j = i + 1; j < this.userName.length; j++) {
|
||||
if (this.userName[i] == this.userName[j]) {
|
||||
this.userName.splice(j, 1)
|
||||
j--
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
handleCancel() {
|
||||
this.visible = false
|
||||
this.treeVisible = false
|
||||
},
|
||||
handleSubmit() {
|
||||
// if (this.userIds && this.userIds.length > 0) {
|
||||
if (this.isSingleChoice) {
|
||||
if (this.userIds.length > 1) {
|
||||
this.$message.warning(this.$t('onlyOnePersonCanBeSelected'))
|
||||
return
|
||||
}
|
||||
}
|
||||
console.log(this,userIds)
|
||||
console.log(this,userName)
|
||||
let userIds = JSON.parse(JSON.stringify(this.userIds))
|
||||
let userName = JSON.parse(JSON.stringify(this.userName))
|
||||
this.$emit('input', userName.join(','))
|
||||
this.$emit('change', this.query.db_field_name, userIds.join(','), this.query.subscript)
|
||||
this.visible = false
|
||||
this.treeVisible = false
|
||||
// } else {
|
||||
// this.$message.warning(this.$t('pleaseSelectPersonFirst'))
|
||||
// }
|
||||
},
|
||||
indexclick(event) {
|
||||
this.$emit('input', event.target.value)
|
||||
this.departId = ''
|
||||
this.searchModel = ''
|
||||
this.userIds = []
|
||||
this.userName = []
|
||||
this.defaultCheckedKeys = []
|
||||
},
|
||||
onSearch(e) {
|
||||
this.gData = []
|
||||
this.departId = ''
|
||||
this.visibleTree = false
|
||||
if (e) {
|
||||
this.getUserAndDepart()
|
||||
} else {
|
||||
this.treeVisible = false
|
||||
this.queryDepartUserTreeList(2)
|
||||
}
|
||||
},
|
||||
getUserAndDepart() {
|
||||
getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => {
|
||||
if (res) {
|
||||
this.gData = res.filter(ele => ele.flag === 'DEPART')
|
||||
} else {
|
||||
this.gData = []
|
||||
}
|
||||
this.visibleTree = true
|
||||
})
|
||||
},
|
||||
onExpand(selectedKeys, val) {
|
||||
if (this.searchModel == '' || !this.searchModel) {
|
||||
if (val.expanded) {
|
||||
if (this.departId == val.node.value) {
|
||||
} else {
|
||||
this.departId = val.node.value
|
||||
this.queryDepartUserTreeList(2)
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
queryDepartUserTreeList(num) {
|
||||
let gData = JSON.parse(JSON.stringify(this.gData))
|
||||
if (gData && gData.length > 0) {
|
||||
gData = JSON.stringify(gData)
|
||||
} else {
|
||||
gData = ''
|
||||
}
|
||||
this.confirmLoading = true
|
||||
postAction('sys/user/queryDepartUserTreeList', {
|
||||
departId: this.departId,
|
||||
json: gData,
|
||||
}).then((res) => {
|
||||
this.confirmLoading = false
|
||||
if (res.success) {
|
||||
this.gData = res.result
|
||||
this.defaultExpandedKeys = [this.departId]
|
||||
if (num == 1) {
|
||||
if (this.userName && this.userName.length == 0) {
|
||||
if (this.personneQuery[this.query.db_field_name + 'Name']) {
|
||||
this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',')
|
||||
} else if (this.personneQuery[this.query.db_field_name]) {
|
||||
this.userName = this.personneQuery[this.query.db_field_name].split(',')
|
||||
} else {
|
||||
this.userName = []
|
||||
}
|
||||
}
|
||||
if (this.userIds && this.userIds.length == 0) {
|
||||
if (this.personneQuery[this.query.db_field_name + '_id']) {
|
||||
this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',')
|
||||
} else if (this.personneQuery[this.query.db_field_name]) {
|
||||
this.userIds = this.personneQuery[this.query.db_field_name].split(',')
|
||||
} else {
|
||||
this.userIds = []
|
||||
}
|
||||
}
|
||||
this.defaultCheckedKeys = this.userIds
|
||||
this.defaultCheckedKeysName = []
|
||||
if (this.defaultCheckedKeys.length > 0) {
|
||||
for (let i = 0; i < this.defaultCheckedKeys.length; i++) {
|
||||
this.defaultCheckedKeysName.push({
|
||||
id: this.defaultCheckedKeys[i],
|
||||
name: this.userName[i]
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
this.treeVisible = true
|
||||
} else {
|
||||
this.gData = []
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.box-title-text {
|
||||
line-height: 1.4;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.box-input {
|
||||
display: inline-block;
|
||||
height: 38px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.button-box {
|
||||
margin-left: 10px;
|
||||
height: 38px;
|
||||
line-height: 38px;
|
||||
|
||||
}
|
||||
|
||||
.drawer-bootom-button {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
z-index: 100;
|
||||
border-top: 1px solid #e8e8e8;
|
||||
padding: 10px 16px;
|
||||
text-align: right;
|
||||
left: 0;
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
|
||||
.drawer-content {
|
||||
height: calc(100% - 60px);
|
||||
overflow: auto;
|
||||
}
|
||||
</style>
|
||||
@@ -136,6 +136,11 @@
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
eventBUs.$on('searchGetData', target => {
|
||||
this.selectedRowKeys = []
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
},
|
||||
|
||||
@@ -129,6 +129,11 @@
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
eventBUs.$on('searchGetData', target => {
|
||||
this.selectedRowKeys = []
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
})
|
||||
this.getData()
|
||||
this.getTableList()
|
||||
this.userData = this.userInfo()
|
||||
|
||||
@@ -285,7 +285,7 @@
|
||||
.then( (res) =>{
|
||||
if (res.data.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
eventBUs.$emit('searchReset')
|
||||
eventBUs.$emit('searchGetData')
|
||||
}else{
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
@@ -362,7 +362,7 @@
|
||||
getAction(`ocr/ocrRecord/delete`,params).then(res=> {
|
||||
if(res.success){
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
eventBUs.$emit('searchReset')
|
||||
eventBUs.$emit('searchGetData')
|
||||
}else{
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
|
||||
@@ -152,6 +152,11 @@
|
||||
}
|
||||
getAction(`split/sarFileSplitInfo/page`,params).then(res=>{
|
||||
if(res.success){
|
||||
if (res.result.current > 1 && res.result.records.length == 0) {
|
||||
this.queryParams.pageNo = res.result.current - 1
|
||||
this.loadData()
|
||||
return
|
||||
}
|
||||
this.tableData=[...res.result.records]
|
||||
this.loading=false
|
||||
this.total=res.result.total
|
||||
@@ -206,7 +211,7 @@
|
||||
// this.queryParams.pageNo=this.queryParams.pageNo-1
|
||||
// }
|
||||
this.selectedRowKeys=[]
|
||||
eventBUs.$emit('searchReset')
|
||||
eventBUs.$emit('searchGetData')
|
||||
// this.loadData()
|
||||
}else{
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
@@ -232,7 +237,7 @@
|
||||
// if (this.tableData && this.tableData.length == 1 && this.queryParams.pageNo != 1) {
|
||||
// this.queryParams.pageNo = this.queryParams.pageNo - 1
|
||||
// }
|
||||
eventBUs.$emit('searchReset')
|
||||
eventBUs.$emit('searchGetData')
|
||||
// this.loadData()
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
|
||||
@@ -235,7 +235,7 @@
|
||||
},
|
||||
//模板下载
|
||||
downLoad(){
|
||||
let name = this.$t('documentSplitTemplate')+'.xls'
|
||||
let name = this.$t('documentSplitTemplate')+'.xlsx'
|
||||
downloadFile('split/sarFileSplitItems/exportTemplate',name, {})
|
||||
},
|
||||
//保存
|
||||
|
||||
@@ -819,7 +819,7 @@
|
||||
},
|
||||
//模板下载
|
||||
handleDownManage() {
|
||||
let name = this.$t('documentSplitTemplate') + '.xls'
|
||||
let name = this.$t('documentSplitTemplate') + '.xlsx'
|
||||
downloadFile('split/sarFileSplitItems/exportTemplate', name, {})
|
||||
},
|
||||
//合并条款
|
||||
@@ -853,7 +853,7 @@
|
||||
info_id: this.infoId
|
||||
|
||||
}
|
||||
eventBUs.$emit('searchQuery', JSON.parse(JSON.stringify(queryParam)))
|
||||
eventBUs.$emit('searchGetData', JSON.parse(JSON.stringify(queryParam)))
|
||||
// eventBUs.$emit('searchReset')
|
||||
this.selectedRowKeys = []
|
||||
} else {
|
||||
@@ -895,7 +895,7 @@
|
||||
info_id: this.infoId
|
||||
|
||||
}
|
||||
eventBUs.$emit('searchQuery', JSON.parse(JSON.stringify(queryParam)))
|
||||
eventBUs.$emit('searchGetData', JSON.parse(JSON.stringify(queryParam)))
|
||||
},
|
||||
//批量删除
|
||||
handleBatCancel() {
|
||||
@@ -934,7 +934,7 @@
|
||||
info_id: this.infoId
|
||||
|
||||
}
|
||||
eventBUs.$emit('searchQuery', JSON.parse(JSON.stringify(queryParam)))
|
||||
eventBUs.$emit('searchGetData', JSON.parse(JSON.stringify(queryParam)))
|
||||
this.selectClear()
|
||||
// eventBUs.$emit('searchReset')
|
||||
} else {
|
||||
@@ -1004,7 +1004,7 @@
|
||||
info_id: this.infoId
|
||||
|
||||
}
|
||||
eventBUs.$emit('searchQuery', JSON.parse(JSON.stringify(queryParam)))
|
||||
eventBUs.$emit('searchGetData', JSON.parse(JSON.stringify(queryParam)))
|
||||
// eventBUs.$emit('searchReset')
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
|
||||
@@ -196,6 +196,11 @@
|
||||
|
||||
getAction(`sys/dictItem/page`, params).then(res => {
|
||||
if (res.success) {
|
||||
if (res.result.current > 1 && res.result.records.length == 0) {
|
||||
this.queryParams.pageNo = 1
|
||||
this.loadData()
|
||||
return
|
||||
}
|
||||
this.total = res.result.total
|
||||
this.tableData = [...res.result.records]
|
||||
this.dataFlag = true
|
||||
@@ -210,6 +215,11 @@
|
||||
sysDictId: this.record.id,
|
||||
isTagDict: 1
|
||||
}).then(res => {
|
||||
if (res.result.current > 1 && res.result.records.length == 0) {
|
||||
this.queryParams.pageNo = 1
|
||||
this.loadData()
|
||||
return
|
||||
}
|
||||
this.tabletreeDataSource = [...res.result.records]
|
||||
this.total = res.result.total
|
||||
let data = this.toTree(this.tabletreeDataSource)
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
show-size-changer
|
||||
:page-size.sync="queryParams.pageSize"
|
||||
:total="total"
|
||||
:current="pageNo"
|
||||
:current="queryParams.pageNo"
|
||||
@change="onChangePage"
|
||||
@showSizeChange="SizeChange"
|
||||
/>
|
||||
@@ -233,12 +233,21 @@
|
||||
// sys/dict/page
|
||||
postAction(`sys/dict/tagDictPage`, params).then(res => {
|
||||
if (res.success) {
|
||||
if (res.result.current > 1 && res.result.records.length == 0) {
|
||||
this.queryParams.pageNo = 1
|
||||
this.loadData()
|
||||
return
|
||||
}
|
||||
this.loading = false
|
||||
this.total = res.result.total
|
||||
this.tableData = [...res.result.records]
|
||||
}else{
|
||||
this.loading = false
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
// .finally(() => {
|
||||
// this.loading = false
|
||||
//})
|
||||
},
|
||||
//查询
|
||||
searchQuery() {
|
||||
@@ -260,7 +269,7 @@
|
||||
},
|
||||
hideModal() {
|
||||
this.form.dictName = this.form.dictName.trim()
|
||||
if (this.form.description){
|
||||
if (this.form.description) {
|
||||
this.form.description = this.form.description.trim()
|
||||
}
|
||||
let params = {
|
||||
|
||||
@@ -305,6 +305,16 @@
|
||||
}
|
||||
postAction(`tag/onlCgformTag/page`, paramsItem).then(res => {
|
||||
if (res.success) {
|
||||
if (res.result.current > 1 && res.result.records.length == 0) {
|
||||
if (this.key == 1) {
|
||||
this.queryParamOne.pageNo = 1
|
||||
this.loadData(1)
|
||||
} else if (this.key == 2) {
|
||||
this.queryParamTwo.pageNo = 1
|
||||
this.loadData(0)
|
||||
}
|
||||
return
|
||||
}
|
||||
this.total = res.result.total
|
||||
this.tableData = [...res.result.records]
|
||||
this.spinning = false
|
||||
|
||||
@@ -206,7 +206,7 @@
|
||||
:title="$t('Administrativeprivileges')">{{$t('Administrativeprivileges')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="authManageIdsName">
|
||||
<PersonnelSelection class="box-input add-input"
|
||||
<PersonnelSelectionAll class="box-input add-input"
|
||||
:personneQuery="form"
|
||||
:query="{db_field_name:'authManageIds',db_field_txt:$t('Administrativeprivileges')}"
|
||||
@change="PersonnelSelectionChange"
|
||||
@@ -223,7 +223,7 @@
|
||||
:title="$t('Checkthepermissions')">{{$t('Checkthepermissions')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="authViewIdsName">
|
||||
<PersonnelSelection
|
||||
<PersonnelSelectionAll
|
||||
class="box-input add-input"
|
||||
:personneQuery="form"
|
||||
:query="{db_field_name:'authViewIds',db_field_txt:$t('Checkthepermissions')}"
|
||||
@@ -274,14 +274,14 @@ import Vue from 'vue'
|
||||
import moment from 'moment'
|
||||
import eventBUs from '@/common/event'
|
||||
import { mapGetters } from 'vuex'
|
||||
import PersonnelSelection from '@/components/PersonnelSelection/index'
|
||||
import PersonnelSelectionAll from '@/components/PersonnelSelectionAll/index'
|
||||
|
||||
export default {
|
||||
name: 'SplitDetail',
|
||||
components: {
|
||||
addModel,
|
||||
handleModel,
|
||||
PersonnelSelection,
|
||||
PersonnelSelectionAll,
|
||||
globalAdvancedQuery
|
||||
// ImportFile
|
||||
},
|
||||
|
||||
@@ -81,9 +81,11 @@
|
||||
<!-- {{ $t('batSetting') }}-->
|
||||
<!-- </div>-->
|
||||
<div @click="BatchMaintenanceProgress" class="operator-text">
|
||||
<a-icon type="setting"/>
|
||||
{{$t('BatchMaintenanceProgress')}}
|
||||
</div>
|
||||
<div @click="BatchChangeStatus" class="operator-text">
|
||||
<a-icon type="setting"/>
|
||||
{{$t('BatchChangeStatus')}}
|
||||
</div>
|
||||
<div @click="CertificationDirectory" class="operator-text">
|
||||
|
||||
Reference in New Issue
Block a user