From 0e9eb6db03a4894493bd46f35e7bdd407bb9bc69 Mon Sep 17 00:00:00 2001 From: Chengliang <1546584672@qq.com> Date: Wed, 2 Aug 2023 17:12:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B2=97=E4=BD=8D=E6=96=B0=E5=A2=9E=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/company/CompanyExtend.js | 3 +- .../components/company/company.js | 20 ++++-- .../components/department/NewPopconfirm.js | 12 +++- .../components/department/department.js | 28 ++++++-- .../components/detach/ManagerDetach.js | 4 +- .../components/fieldDefinedSet/FieldDef.js | 8 ++- .../components/fieldDefinedSet/FormInfo.js | 4 +- .../components/import/datasImport.js | 20 ++++-- .../components/importresource/Import.js | 20 ++++-- .../components/importresource/ImportLog.js | 16 +++-- .../components/importresource/ImportResult.js | 4 +- pc4mobx/organization/components/job/Job.js | 71 ++++++++++++++----- .../organization/components/log/LogView.js | 12 +++- .../components/newImport/stepContent.js | 8 ++- .../components/postionrank/JobGrade.js | 4 +- .../components/postionrank/JobLevel.js | 4 +- .../components/postionrank/RankScheme.js | 4 +- .../components/resource/ResourceBasicInfo.js | 4 +- .../components/resource/ResourceCard.js | 28 ++++++-- .../components/resource/resource.js | 4 +- .../components/sequence/Sequence.js | 4 +- .../organization/components/staff/Staff.js | 4 +- .../components/staff/StaffScheme.js | 4 +- pc4mobx/organization/stores/fieldDefined.js | 6 +- pc4mobx/organization/stores/job.js | 26 ++++++- pc4mobx/organization/util/index.js | 4 +- 26 files changed, 248 insertions(+), 78 deletions(-) diff --git a/pc4mobx/organization/components/company/CompanyExtend.js b/pc4mobx/organization/components/company/CompanyExtend.js index b49a5f4..9ae029f 100644 --- a/pc4mobx/organization/components/company/CompanyExtend.js +++ b/pc4mobx/organization/components/company/CompanyExtend.js @@ -311,8 +311,7 @@ export default class CompanyExtend extends React.Component { onAnimationEnd={() => console.log('onAnimationEnd')} /> ) - } - catch (e) { + } catch (e) { return
{i18n.message.authFailed()}
diff --git a/pc4mobx/organization/components/company/company.js b/pc4mobx/organization/components/company/company.js index 3caa28b..6ea1f48 100644 --- a/pc4mobx/organization/components/company/company.js +++ b/pc4mobx/organization/components/company/company.js @@ -355,16 +355,24 @@ export default class Company extends React.Component { const menu = ( - { _this.doDel(record.id) }}>删除 + { + _this.doDel(record.id) +}}>删除 - { _this.select(record.id) }}>联查部门 + { + _this.select(record.id) +}}>联查部门 - { _this.view(record.id) }}>查看 + { + _this.view(record.id) +}}>查看 - { _this.transfer(record.id) }}>转移 + { + _this.transfer(record.id) +}}>转移 {/* { _this.version(record) }}>另存为版本 @@ -435,7 +443,9 @@ export default class Company extends React.Component { } = company; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/department/NewPopconfirm.js b/pc4mobx/organization/components/department/NewPopconfirm.js index 650c21e..57e7887 100644 --- a/pc4mobx/organization/components/department/NewPopconfirm.js +++ b/pc4mobx/organization/components/department/NewPopconfirm.js @@ -97,8 +97,12 @@ export default class NewPopconfirm extends React.Component { } = this.props const a = form.getFormParams(); const buttons = [ - (), - () + (), + () ]; return ( @@ -109,7 +113,9 @@ export default class NewPopconfirm extends React.Component { visible={visible} closable={true} hasScroll={true} - onCancel={() => {this.setState({value:"0"});onCancel()}} + onCancel={() => { +this.setState({value:"0"});onCancel() +}} buttons={buttons} style={{ width: width, height: height }} > diff --git a/pc4mobx/organization/components/department/department.js b/pc4mobx/organization/components/department/department.js index a98b901..2895141 100644 --- a/pc4mobx/organization/components/department/department.js +++ b/pc4mobx/organization/components/department/department.js @@ -384,22 +384,34 @@ export default class Department extends React.Component { const menu = ( - { _this.view(record.id) }}>查看 + { + _this.view(record.id) +}}>查看 - { _this.doDel(record.id) }}>删除 + { + _this.doDel(record.id) +}}>删除 - { _this.merge(record.id) }}>合并 + { + _this.merge(record.id) +}}>合并 - { _this.transfer(record.id) }}>转移 + { + _this.transfer(record.id) +}}>转移 - { _this.select(record.id) }}>联查岗位 + { + _this.select(record.id) +}}>联查岗位 - { _this.copy(record.id) }}>复制 + { + _this.copy(record.id) +}}>复制 {/* { _this.version(record) }}>另存为版本 @@ -459,7 +471,9 @@ export default class Department extends React.Component { } = department; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/detach/ManagerDetach.js b/pc4mobx/organization/components/detach/ManagerDetach.js index 08ba43c..d2fd98b 100644 --- a/pc4mobx/organization/components/detach/ManagerDetach.js +++ b/pc4mobx/organization/components/detach/ManagerDetach.js @@ -199,7 +199,9 @@ export default class ManagerDetach extends React.Component { } = managerDetach; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/fieldDefinedSet/FieldDef.js b/pc4mobx/organization/components/fieldDefinedSet/FieldDef.js index 53040f8..ffb3bd2 100644 --- a/pc4mobx/organization/components/fieldDefinedSet/FieldDef.js +++ b/pc4mobx/organization/components/fieldDefinedSet/FieldDef.js @@ -64,8 +64,8 @@ export default class FieldDef extends Component { isJobTreeNode } = store; const classes = classnames({ - ['tabPane']: true, - ['tabPane-include']: resetClass + 'tabPane': true, + 'tabPane-include': resetClass }) const { groupInfoFrom, @@ -105,7 +105,9 @@ export default class FieldDef extends Component { } const rMenu = [...rightMenu, ...store.getBasicMenus(this.props.logSmallType, this.props.targetId)] return ( -
{ this.tabDom = dom }}> +
{ + this.tabDom = dom +}}> setEditTable(editTable, 'fieldDef')} diff --git a/pc4mobx/organization/components/fieldDefinedSet/FormInfo.js b/pc4mobx/organization/components/fieldDefinedSet/FormInfo.js index 0c626ba..605dcb9 100644 --- a/pc4mobx/organization/components/fieldDefinedSet/FormInfo.js +++ b/pc4mobx/organization/components/fieldDefinedSet/FormInfo.js @@ -64,7 +64,9 @@ export default class FormInfo extends Component { const showCheckbox = field.checkbox || false; let label = field.label; if (showCheckbox) - label = {field.checkboxValue = v === '1'; onSelectedChangeHandle && onSelectedChangeHandle(field, v)}}/> + label = { +field.checkboxValue = v === '1'; onSelectedChangeHandle && onSelectedChangeHandle(field, v) +}}/> let coms; if (customerRender == null) { diff --git a/pc4mobx/organization/components/import/datasImport.js b/pc4mobx/organization/components/import/datasImport.js index e46e097..99e3015 100644 --- a/pc4mobx/organization/components/import/datasImport.js +++ b/pc4mobx/organization/components/import/datasImport.js @@ -146,7 +146,9 @@ export default class DatasImport extends React.Component { } else if (domkey[0] === 'exportData') { const href = datasImport.operateType === 'add' ? field.otherParams.fileVal[0].add : field.otherParams.fileVal[0].update; if (datasImport.importType === 'matrix') { - dom = { getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType, importParams) }}>{i18n.label.importTemplate()} + dom = { + getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType, importParams) +}}>{i18n.label.importTemplate()} } else dom = {i18n.label.importTemplate()}; } else if (domkey[0] == 'excelfile' || domkey[0] == 'importfile') { @@ -179,14 +181,18 @@ export default class DatasImport extends React.Component { style={{ width: 200 }} options={field.options} value={datasImport.importParams[domkey[0]] || field.value || val} - onChange={(v) => { datasImport.setParam(domkey[0], v) }} + onChange={(v) => { + datasImport.setParam(domkey[0], v) +}} /> } else if (domkey[0] == 'importType') { dom = { datasImport.operateType = v }} + onChange={(v) => { + datasImport.operateType = v +}} /> } else { dom = @@ -209,13 +215,17 @@ export default class DatasImport extends React.Component { const href = datasImport.operateType === 'add' ? url.add : url.update; let dom; if (datasImport.importType === 'matrix') { - dom = { getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType, importParams) }}>{i18n.label.importTemplate()} + dom = { + getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType, importParams) +}}>{i18n.label.importTemplate()} } else dom = {i18n.label.importTemplate()}; p = (

{i18n.label.downLoadTemplete()}:{dom}

); } else if (url != null) { if (datasImport.importType === 'matrix') { - p = (

{i18n.label.downLoadTemplete()}: { getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType) }}>{i18n.label.importTemplate()}

); + p = (

{i18n.label.downLoadTemplete()}: { + getTemplateUrl(datasImport.otherParams.matrixid, datasImport.operateType) +}}>{i18n.label.importTemplate()}

); } else p = (

{i18n.label.downLoadTemplete()}:{i18n.label.importTemplate()}

); } else { diff --git a/pc4mobx/organization/components/importresource/Import.js b/pc4mobx/organization/components/importresource/Import.js index 1386d31..eb40b3d 100644 --- a/pc4mobx/organization/components/importresource/Import.js +++ b/pc4mobx/organization/components/importresource/Import.js @@ -147,7 +147,9 @@ export default class ImportResource extends React.Component { } else if (domkey[0] === 'exportData') { const href = hrmImportResource.operateType === 'add' ? field.otherParams.fileVal[0].add : field.otherParams.fileVal[0].update; if(hrmImportResource.importType === 'matrix'){ - dom = {getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType, importParams)}}>{i18n.label.importTemplate()} + dom = { +getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType, importParams) +}}>{i18n.label.importTemplate()} }else dom = {i18n.label.importTemplate()}; } else if (domkey[0] == 'excelfile' || domkey[0] == 'importfile') { @@ -180,14 +182,18 @@ export default class ImportResource extends React.Component { style={{width: 200}} options={field.options} value={hrmImportResource.importParams[domkey[0]] || field.value || val} - onChange={(v) => { hrmImportResource.setParam(domkey[0], v)}} + onChange={(v) => { + hrmImportResource.setParam(domkey[0], v) +}} /> } else if (domkey[0] == 'importType') { dom = { hrmImportResource.operateType = v }} + onChange={(v) => { + hrmImportResource.operateType = v +}} /> } else { dom = @@ -210,13 +216,17 @@ export default class ImportResource extends React.Component { const href = hrmImportResource.operateType === 'add' ? url.add : url.update; let dom; if(hrmImportResource.importType === 'matrix'){ - dom = {getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType, importParams)}}>{i18n.label.importTemplate()} + dom = { +getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType, importParams) +}}>{i18n.label.importTemplate()} }else dom = {i18n.label.importTemplate()}; p = (

{i18n.label.downLoadTemplete()}:{dom}

); } else if (url != null) { if(hrmImportResource.importType === 'matrix'){ - p = (

{i18n.label.downLoadTemplete()}: {getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType)}}>{i18n.label.importTemplate()}

); + p = (

{i18n.label.downLoadTemplete()}: { +getTemplateUrl(hrmImportResource.otherParams.matrixid, hrmImportResource.operateType) +}}>{i18n.label.importTemplate()}

); }else p = (

{i18n.label.downLoadTemplete()}:{i18n.label.importTemplate()}

); } else { diff --git a/pc4mobx/organization/components/importresource/ImportLog.js b/pc4mobx/organization/components/importresource/ImportLog.js index 38a6484..09393cd 100644 --- a/pc4mobx/organization/components/importresource/ImportLog.js +++ b/pc4mobx/organization/components/importresource/ImportLog.js @@ -121,8 +121,12 @@ class ImportLog extends React.Component { showSearchAd } = hrmImportResource; const btn = [ - (), - (), + (), + (), () ] return ( @@ -135,7 +139,9 @@ class ImportLog extends React.Component { iconBgcolor="#217346" visible={visibleImportLog} closable={true} - onCancel={() => { this.cancel()} } + onCancel={() => { + this.cancel() +} } //buttons={buttons} style={{width: 970, height: 510}} > @@ -151,7 +157,9 @@ class ImportLog extends React.Component { } } >{this.getSearchs()}
} - setShowSearchAd={bool => {hrmImportResource.showSearchAd = bool}} + setShowSearchAd={bool => { +hrmImportResource.showSearchAd = bool +}} hideSearchAd={() => hrmImportResource.showSearchAd = false} advanceHeight={200} hasMask={false} diff --git a/pc4mobx/organization/components/importresource/ImportResult.js b/pc4mobx/organization/components/importresource/ImportResult.js index e3e1ed2..db6a9f5 100644 --- a/pc4mobx/organization/components/importresource/ImportResult.js +++ b/pc4mobx/organization/components/importresource/ImportResult.js @@ -150,7 +150,9 @@ class ImportResult extends React.Component {
}
- {hrmImportResource.setScrollTarget(scroll)}}> + { +hrmImportResource.setScrollTarget(scroll) +}}> diff --git a/pc4mobx/organization/components/job/Job.js b/pc4mobx/organization/components/job/Job.js index cb2c5a1..e15d141 100644 --- a/pc4mobx/organization/components/job/Job.js +++ b/pc4mobx/organization/components/job/Job.js @@ -1,7 +1,7 @@ /** * @Author: 程亮 * @Date: 2022-05-26 14:05:59 - * @LastEditTime: 2022-12-16 16:36:59 + * @LastEditTime: 2023-08-02 17:09:24 * @Description: * @FilePath: /trunk/src4js/pc4mobx/organization/components/job/Job.js */ @@ -18,7 +18,7 @@ import { WeaRightMenu, WeaTable, WeaLeftRightLayout, - WeaOrgTree + WeaOrgTree, WeaDialog } from 'ecCom' import { Row, @@ -42,7 +42,7 @@ import '../../style/common.less'; import NewAndEditDialog from '../NewAndEditDialog'; import NewWeaTableDialog from '../NewWeaTableDialog'; -import { renderNoright } from '../../util'; +import { renderNoright } from '../../util'; @@ -156,7 +156,7 @@ export default class Job extends React.Component { } = this.props; confirm({ title: i18n.confirm.defaultTitle(), - content: this.getCopyForm({isCopy:false}), + content: this.getCopyForm({ isCopy: false }), okText: i18n.button.ok(), cancelText: i18n.button.cancel(), onOk() { @@ -169,7 +169,7 @@ export default class Job extends React.Component { } - copy(id) { + copy(id) { const { job } = this.props; @@ -180,7 +180,7 @@ export default class Job extends React.Component { job.setIds(keys); confirm({ title: i18n.confirm.defaultTitle(), - content: this.getCopyForm({isCopy:true}), + content: this.getCopyForm({ isCopy: true }), okText: i18n.button.ok(), cancelText: i18n.button.cancel(), onOk() { @@ -205,7 +205,7 @@ export default class Job extends React.Component { let formParams = form2.getFormParams(); let condition = params.isCopy ? copyCondition : mergeCondition; const { - isFormInit + isFormInit } = form2; let arr = []; isFormInit && condition.map(c => { @@ -350,13 +350,19 @@ export default class Job extends React.Component { const menu = ( - { _this.view(record.id) }}>查看 + { + _this.view(record.id) + }}>查看 - - { _this.doDel(record.id) }}>删除 + + { + _this.doDel(record.id) + }}>删除 - { _this.select(record.id) }}>联查人员 + { + _this.select(record.id) + }}>联查人员 {/* { _this.merge(record.id) }}>合并 @@ -414,7 +420,9 @@ export default class Job extends React.Component { } = job; const btn = [ - (), + (), (), (), ]; @@ -563,8 +571,8 @@ export default class Job extends React.Component { const { isPanelShow, jobTitleName, conditionNum, visible, condition, form, tableStore, dataSource, columns, loading, date, nEdialogTitle, dialogLoading, - form1, isEdit, newVisible,selectedRowKeys, total, current, pageSize, init, - defaultShowLeft,form2,hasRight + form1, isEdit, newVisible, selectedRowKeys, total, current, pageSize, init, + defaultShowLeft, form2, hasRight, jobtitleVisible } = job; if (hasRight === false) { @@ -573,7 +581,7 @@ export default class Job extends React.Component { const rowSelection = { - selectedRowKeys:selectedRowKeys, + selectedRowKeys: selectedRowKeys, onChange(selectedRowKeys, selectedRows) { job.setSelectedRowKeys(selectedRowKeys); }, @@ -673,9 +681,40 @@ export default class Job extends React.Component { conditionLen={2} save={() => this.handleSave()} onCancel={() => job.setNewVisible(false)} - saveAndSetting = {() => this.handleSaveAndSetting()} + saveAndSetting={() => this.handleSaveAndSetting()} moduleName={"job"} /> + job.jobtitleVisible = false} + icon='icon-coms-hrm' + iconBgcolor='#217346' + title={"添加岗位"} + callback={ + datas => { + const { + id, + jobtitlemark + } = datas; + + form1.updateFields({ + ec_jobTitle: { + value: id, + valueSpan: jobtitlemark, + valueObj: [{ + id, + name: jobtitlemark + }] + } + }); + + job.jobtitleVisible = false; + + } + } + url={'/spa/hrm/engine.html#/hrmengine/posts?type=0'} + visible={jobtitleVisible} + style={{ width: 600, height: 500 }} + /> ) } diff --git a/pc4mobx/organization/components/log/LogView.js b/pc4mobx/organization/components/log/LogView.js index 77df038..dd3faca 100644 --- a/pc4mobx/organization/components/log/LogView.js +++ b/pc4mobx/organization/components/log/LogView.js @@ -79,7 +79,9 @@ export default class LogView extends React.Component { columns.forEach((c, index) => { if (c.dataIndex == 'message') { c.render = function (text, record) { - return { _this.doView(record) }}>查看 + return { + _this.doView(record) +}}>查看 } }; }) @@ -141,7 +143,9 @@ export default class LogView extends React.Component { } = logViewStore; const btn = [ - (), + (), (), (), ]; @@ -176,7 +180,9 @@ export default class LogView extends React.Component { { this.setState({ showSearchAd: bool }) }} + setShowSearchAd={bool => { + this.setState({ showSearchAd: bool }) +}} advanceHeight={161} searchsAd={showSearchAd ? this.getPanelComponents() :
} buttonsAd={this.getTabBtn()} diff --git a/pc4mobx/organization/components/newImport/stepContent.js b/pc4mobx/organization/components/newImport/stepContent.js index 072975f..c8ae746 100644 --- a/pc4mobx/organization/components/newImport/stepContent.js +++ b/pc4mobx/organization/components/newImport/stepContent.js @@ -149,14 +149,18 @@ export default class StepDialog extends React.Component { style={{ width: 200 }} options={field.options} value={newImport.importParams[domkey[0]] || field.value || val} - onChange={(v) => { newImport.setParam(domkey[0], v) }} + onChange={(v) => { + newImport.setParam(domkey[0], v) +}} /> } else if (domkey[0] == 'importType') { dom = { newImport.operateType = v }} + onChange={(v) => { + newImport.operateType = v +}} /> } else if (domkey[0] == 'excelfile' || domkey[0] == 'importfile') { dom = (
diff --git a/pc4mobx/organization/components/postionrank/JobGrade.js b/pc4mobx/organization/components/postionrank/JobGrade.js index b1c4e3c..e695d49 100644 --- a/pc4mobx/organization/components/postionrank/JobGrade.js +++ b/pc4mobx/organization/components/postionrank/JobGrade.js @@ -211,7 +211,9 @@ export default class JobGrade extends React.Component { } = jobGrade; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/postionrank/JobLevel.js b/pc4mobx/organization/components/postionrank/JobLevel.js index 2ae2a7b..baf0c35 100644 --- a/pc4mobx/organization/components/postionrank/JobLevel.js +++ b/pc4mobx/organization/components/postionrank/JobLevel.js @@ -196,7 +196,9 @@ export default class JobLevel extends React.Component { } = jobLevel; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/postionrank/RankScheme.js b/pc4mobx/organization/components/postionrank/RankScheme.js index cd06e10..0ff4370 100644 --- a/pc4mobx/organization/components/postionrank/RankScheme.js +++ b/pc4mobx/organization/components/postionrank/RankScheme.js @@ -200,7 +200,9 @@ export default class RankScheme extends React.Component { } = rankScheme; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/resource/ResourceBasicInfo.js b/pc4mobx/organization/components/resource/ResourceBasicInfo.js index 305a0a2..bd771b2 100644 --- a/pc4mobx/organization/components/resource/ResourceBasicInfo.js +++ b/pc4mobx/organization/components/resource/ResourceBasicInfo.js @@ -256,7 +256,9 @@ export default class ResourceBasicInfo extends React.Component { } = resourceBasicInfo; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/resource/ResourceCard.js b/pc4mobx/organization/components/resource/ResourceCard.js index 020b927..9e3907d 100644 --- a/pc4mobx/organization/components/resource/ResourceCard.js +++ b/pc4mobx/organization/components/resource/ResourceCard.js @@ -187,7 +187,9 @@ export default class ResourceCard extends React.Component { // 找到锚点 let anchorElement = document.getElementById(anchorName); // 如果对应id的锚点存在,就跳转到锚点 - if (anchorElement) { anchorElement.scrollIntoView({ block: 'start', behavior: 'smooth' }); } + if (anchorElement) { + anchorElement.scrollIntoView({ block: 'start', behavior: 'smooth' }); +} } } @@ -263,7 +265,9 @@ export default class ResourceCard extends React.Component { { data.buttons.slice(0,3).map((item,index) => { return ( - + ) }) } @@ -279,35 +283,45 @@ export default class ResourceCard extends React.Component {
-
{ window.open(`/spa/workflow/static/index.html#/main/workflow/listDoing?resourceid=${data.user.ecId}`)}}> + { + window.open(`/spa/workflow/static/index.html#/main/workflow/listDoing?resourceid=${data.user.ecId}`) +}}>

流程总数

{data.statistical.workflowCount}

- { window.open(`/spa/document/static/index.html#/main/document/search?viewcondition=2&doccreaterid=${data.user.ecId}`)}}> + { + window.open(`/spa/document/static/index.html#/main/document/search?viewcondition=2&doccreaterid=${data.user.ecId}`) +}}>

文档总数

{data.statistical.docCount}

- { window.open(`/spa/crm/static/index.html#/main/crm/customer/hrmView?searchHrmId=${data.user.ecId}`)}}> + { + window.open(`/spa/crm/static/index.html#/main/crm/customer/hrmView?searchHrmId=${data.user.ecId}`) +}}>

我的客户

{data.statistical.cusCount}

- { window.open(`/spa/cowork/static/index.html#/main/cowork/hrmview?searchHrmid=${data.user.ecId}`) }}> + { + window.open(`/spa/cowork/static/index.html#/main/cowork/hrmview?searchHrmid=${data.user.ecId}`) +}}>

我的协作

{data.statistical.collaborationCount}

- { window.open(`/spa/blog/static/index.html#/user/${data.user.ecId}`) }}> + { + window.open(`/spa/blog/static/index.html#/user/${data.user.ecId}`) +}}>

微博总数

diff --git a/pc4mobx/organization/components/resource/resource.js b/pc4mobx/organization/components/resource/resource.js index 2525c81..f7b94aa 100644 --- a/pc4mobx/organization/components/resource/resource.js +++ b/pc4mobx/organization/components/resource/resource.js @@ -328,7 +328,9 @@ export default class Resource extends React.Component { } = resource; const btn = [ - (), + (), (), (), (), diff --git a/pc4mobx/organization/components/sequence/Sequence.js b/pc4mobx/organization/components/sequence/Sequence.js index 61af8ac..adb6171 100644 --- a/pc4mobx/organization/components/sequence/Sequence.js +++ b/pc4mobx/organization/components/sequence/Sequence.js @@ -195,7 +195,9 @@ export default class Sequence extends React.Component { } = sequence; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/staff/Staff.js b/pc4mobx/organization/components/staff/Staff.js index 928feb8..673c641 100644 --- a/pc4mobx/organization/components/staff/Staff.js +++ b/pc4mobx/organization/components/staff/Staff.js @@ -217,7 +217,9 @@ export default class Staff extends React.Component { } = staff; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/components/staff/StaffScheme.js b/pc4mobx/organization/components/staff/StaffScheme.js index cc24a11..ab931b8 100644 --- a/pc4mobx/organization/components/staff/StaffScheme.js +++ b/pc4mobx/organization/components/staff/StaffScheme.js @@ -195,7 +195,9 @@ export default class StaffScheme extends React.Component { } = staffScheme; const btn = [ - (), + (), (), (), ]; diff --git a/pc4mobx/organization/stores/fieldDefined.js b/pc4mobx/organization/stores/fieldDefined.js index 0aa675f..ebe72a2 100644 --- a/pc4mobx/organization/stores/fieldDefined.js +++ b/pc4mobx/organization/stores/fieldDefined.js @@ -710,7 +710,9 @@ export class FieldDefinedStore extends HrmBaseStore { this.refreshMainTabComponent = new Date().getTime(); this.spinning = false; this.refreshMainTabComponent = new Date().getTime(); - }, error => {this.spinning = false;}) + }, error => { +this.spinning = false; +}) } @@ -873,7 +875,7 @@ export class FieldDefinedStore extends HrmBaseStore { this.formTarget.typeInfoFrom.validateForm().then(f => { if (f.isValid) { let params = { - ... this.formTarget.typeInfoFrom.getFormParams(), + ...this.formTarget.typeInfoFrom.getFormParams(), id: this.selectedTreeNodeInfo.domid } api.changeTypeInfo(this.moduleName, params).then(response => { diff --git a/pc4mobx/organization/stores/job.js b/pc4mobx/organization/stores/job.js index f17ebf0..5555b1c 100644 --- a/pc4mobx/organization/stores/job.js +++ b/pc4mobx/organization/stores/job.js @@ -68,6 +68,8 @@ export class JobStore { @observable selectTreeNodeInfo; saveAndSetting = false; + @observable jobtitleVisible = false; + @action initData() { this.getHasRight(); this.refresh(); @@ -208,8 +210,11 @@ export class JobStore { Api.getJobForm(this.selectTreeNodeInfo).then(res => { if (res.code === 200) { this.setDialogLoadingStatus(false); - res.data.condition && this.setCondition(res.data.condition); - res.data.condition && this.form1.initFormFields(res.data.condition); + if(res.data.condition) { + let condition = this.processCondition(res.data.condition) + this.setCondition(condition); + this.form1.initFormFields(condition); + } } else { message.warning(res.msg); } @@ -218,6 +223,19 @@ export class JobStore { }) } + processCondition = (condition) => { + condition.map(c => c.items.map(item => { + if (item.domkey[0] === "ec_jobTitle") { + item.otherParams = { + addOnClick: () => { + this.setJobtitleVisible(true); + } + } + } + })); + return condition; + } + @action("复制表单") getCopyForm() { let params = {}; Api.getCopyForm(params).then(res => { @@ -351,6 +369,10 @@ export class JobStore { this.jobTitleName = val; } + setJobtitleVisible(val) { + this.jobtitleVisible = val; + } + isEmptyObject(obj) { for (let key in obj) { return false; diff --git a/pc4mobx/organization/util/index.js b/pc4mobx/organization/util/index.js index f1e4790..ee339f5 100644 --- a/pc4mobx/organization/util/index.js +++ b/pc4mobx/organization/util/index.js @@ -98,7 +98,9 @@ export const renderNoData = () => ( //对象非空判断 export const isEmpty = (obj) =>{ - for(var n in obj){return false} + for(var n in obj){ +return false +} return true; }