花名册页面增加配置文件判断跳转是否为标准卡片还是聚才林卡片
This commit is contained in:
parent
1842906c83
commit
342e12820b
|
|
@ -381,13 +381,18 @@ export default class Resource extends React.Component {
|
||||||
|
|
||||||
reRenderColumns(columns) {
|
reRenderColumns(columns) {
|
||||||
let _this = this;
|
let _this = this;
|
||||||
|
const {
|
||||||
|
resource
|
||||||
|
} = _this.props,{
|
||||||
|
url
|
||||||
|
} = resource;
|
||||||
columns.forEach((c, index) => {
|
columns.forEach((c, index) => {
|
||||||
c.className = "wea-table-indent"
|
c.className = "wea-table-indent"
|
||||||
c.oldWidth = (100 / columns.length).toFixed(2) + '%';
|
c.oldWidth = (100 / columns.length).toFixed(2) + '%';
|
||||||
if (c.dataIndex == 'lastname') {
|
if (c.dataIndex == 'lastname') {
|
||||||
c.render = function (text, record) {
|
c.render = function (text, record) {
|
||||||
return <a href='javascript:void(0);' onClick={() => {
|
return <a href='javascript:void(0);' onClick={() => {
|
||||||
window.open(`/spa/organization/static/index.html#/main/organization/resourceCard/${record.id}`);
|
window.open(url+record.id);
|
||||||
}}>{text}</a>
|
}}>{text}</a>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -404,7 +409,12 @@ export default class Resource extends React.Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
view(id) {
|
view(id) {
|
||||||
window.open(`/spa/organization/static/index.html#/main/organization/resourceCard/${id}`);
|
const {
|
||||||
|
resource
|
||||||
|
} = this.props,{
|
||||||
|
url
|
||||||
|
} = resource;
|
||||||
|
window.open(url+id);
|
||||||
}
|
}
|
||||||
|
|
||||||
version(record) {
|
version(record) {
|
||||||
|
|
|
||||||
|
|
@ -65,6 +65,7 @@ export class ResourceStore extends HrmBaseStore{
|
||||||
@observable loginId = '';
|
@observable loginId = '';
|
||||||
|
|
||||||
@observable selectTreeNodeInfo;
|
@observable selectTreeNodeInfo;
|
||||||
|
@observable url = '';
|
||||||
|
|
||||||
@observable enable = false;
|
@observable enable = false;
|
||||||
@observable _showRadioGroup = false;
|
@observable _showRadioGroup = false;
|
||||||
|
|
@ -240,6 +241,11 @@ export class ResourceStore extends HrmBaseStore{
|
||||||
this.getHSearchTemplate(res.data.searchTemplateId);
|
this.getHSearchTemplate(res.data.searchTemplateId);
|
||||||
//2.获取列定制内容
|
//2.获取列定制内容
|
||||||
this.getSearchTemplate(res.data.customTemplateId);
|
this.getSearchTemplate(res.data.customTemplateId);
|
||||||
|
let url = '/spa/organization/static/index.html#/main/organization/resourceCard/';
|
||||||
|
if(res.data.cardType == "2") {
|
||||||
|
url = '/spa/hrm/index_mobx.html#/main/hrm/card/cardInfo/';
|
||||||
|
}
|
||||||
|
this.url = url;
|
||||||
} else {
|
} else {
|
||||||
message.warning(res.msg);
|
message.warning(res.msg);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue