/* * @Author: lusx * @Date: 2020-04-21 15:15:20 * @Last Modified by: lusx * @Last Modified time: 2020-04-23 13:56:26 */ import { Row, Col, Button } from 'antd'; import { WeaBrowser, WeaLocaleProvider, WeaTextarea } from 'ecCom'; const getLabel = WeaLocaleProvider.getLabel; let browserParam = { hasAddBtn: false, hasAdvanceSerach: true, idSeparator: ",", isAutoComplete: 1, isDetail: 0, isMultCheckbox: false, isSingle: true, linkUrl: "/hrm/resource/HrmResource.jsp?id=", pageSize: 10, quickSearchName: "", title: getLabel(383424, "人力资源"), type: "1", viewAttr: 1, } const Log = (item) => { return ( window.pointerXY(e)} > {item.creater.name} : {item.content} {item.details && item.details.map((c, index) => { const arrow = c.original ? '>' : '' return
" + c.fieldname + "" + '   ' + "" + c.original + "" + arrow + "" + c.modified + "" }}>
; })}
{item.time}
) } const Daily = (props) => { const { item, showReply, submitType, setReply, huifuHandle, shanchuHandle, bianjiHandle, tijiaoHandle } = props; return ( window.pointerXY(e)} > {item.creater.name}:   {item.createdate + ' ' + item.createtime} shanchuHandle()}>删除 bianjiHandle()}>编辑 huifuHandle(item)}>{getLabel('128123', '回复')} { item.replys && item.replys.map((item, index) => { return
window.pointerXY(e)} > {item.creater.name}   {item.createdate + ' ' + item.createtime}
}) } {showReply[item.id] && { setReply(v) }} /> }
) } const JlChild = (props) => { const { element, replaceDatas, sortid, wf_auth_url, doc_auth_url, acc_auth_url } = props; return (
:   { element.projectids&&element.projectids.length > 0 ? element.projectids.map((e, _index) => {//相关项目 return
openProjectAppLink('project', e.id, sortid)} ondblclick={() => false} unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.name}
}) : '' } { element.relatedcus&&element.relatedcus.length > 0 ? element.relatedcus.map((e, _index) => {//客户 return
openProjectAppLink('crm', e.id, sortid)} ondblclick={() => false} unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.name}
}) : '' } { element.relateddoc&&element.relateddoc.length > 0 ? element.relateddoc.map((e, _index) => {//修改成附件 if (e.showLoad) { return
openProjectDiscussDoc(this, e.fileid, sortid, acc_auth_url)} href='javascript:void(0);' unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.filename} {`${getLabel(258, "下载")}(${e.filesize})`}
} else { return
openProjectDiscussDoc(this, e.fileid, sortid, acc_auth_url)} href='javascript:void(0);' unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.filename}
} }) : '' } { element.relatedprj&&element.relatedprj.length > 0 ? element.relatedprj.map((e, _index) => { return
openProjectAppLink('task', e.id, sortid)} ondblclick={() => false} unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.name}
}) : '' } { element.relatedwf&&element.relatedwf.length > 0 ? element.relatedwf.map((e, _index) => {//流程 return
openProjectAppLink('workflow', e.id, sortid, wf_auth_url)} ondblclick={() => false} unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.name}
}) : '' } { element.docids&&element.docids.length > 0 ? element.docids.map((e, _index) => {//文档 return
openProjectAppLink('doc', e.id, sortid, doc_auth_url)} ondblclick={() => false} unselectable='off' contenteditable='false' style={{ cursor: 'pointer', textDecoration: 'underline !important', marginRight: '8px' }}>{e.name}
}) : '' }
) }; const jlParamsHandle = (_exchangeList) => { let bottomBarConfig = []; let mirror = { Document: { type: 37, name: getLabel(126529, "文档"), icon: 'icon-blog-Document' }, Flow: { type: 152, name: getLabel(131692, "流程"), icon: 'icon-blog-Process' }, Customer: { type: 18, name: getLabel(30043, "客户"), icon: 'icon-blog-Personnel' }, Project: { type: 135, name: getLabel(30046, "项目"), icon: 'icon-blog-Project' }, Task: { type: 'prjtsk', name: getLabel(383349, "任务"), icon: 'icon-blog-Task' }, } let objDocument = { name: 'Browser', show:
{mirror['Document'].name}
, type: mirror['Document'].type, title: mirror['Document'].name, }; let objFlow = { name: 'Browser', show:
{mirror['Flow'].name}
, type: mirror['Flow'].type, title: mirror['Flow'].name, }; let objCustomer = { name: 'Browser', show:
{mirror['Customer'].name}
, type: mirror['Customer'].type, title: mirror['Customer'].name, }; let objProject = { name: 'Browser', show:
{mirror['Project'].name}
, type: mirror['Project'].type, title: mirror['Project'].name, }; let objTask = { name: 'Browser', show:
{mirror['Task'].name}
, type: mirror['Task'].type, title: mirror['Task'].name, }; _exchangeList.docids && bottomBarConfig.push(objDocument);//相关文档 _exchangeList.relatedwf && bottomBarConfig.push(objFlow);//相关流程 _exchangeList.relatedcus && bottomBarConfig.push(objCustomer);//相关客户 _exchangeList.projectids && bottomBarConfig.push(objProject);//相关项目 _exchangeList.relatedprj && bottomBarConfig.push(objTask);//相关任务 _exchangeList.relateddoc && bottomBarConfig.push({ name: 'Upload', show:
{getLabel(128158, "附件")}
, uploadId: 'project_edit', uploadUrl: `${_exchangeList.relateddoc.uploadUrl}?category=${_exchangeList.relateddoc.category}`, category: _exchangeList.relateddoc.category, maxUploadSize: _exchangeList.relateddoc.maxSize, style: { display: "inline-block", padding: 0 } }) return bottomBarConfig; } export { JlChild, jlParamsHandle, Daily, Log };