From 5cce357d78414ad3402b4a0f64a267a5cb492806 Mon Sep 17 00:00:00 2001
From: Chengliang <1546584672@qq.com>
Date: Wed, 16 Nov 2022 09:18:19 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=89=A9=E5=B1=95=E9=A1=B5?=
=?UTF-8?q?=E9=9D=A2?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pc4mobx/organization/components/resource/ResourceCard.js | 2 +-
pc4mobx/organization/stores/companyextend.js | 4 +++-
pc4mobx/organization/stores/departmentextend.js | 4 +++-
pc4mobx/organization/stores/jobextend.js | 6 ++++--
pc4mobx/organization/stores/resourceExtend.js | 7 +++++--
5 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/pc4mobx/organization/components/resource/ResourceCard.js b/pc4mobx/organization/components/resource/ResourceCard.js
index a2a58d9..266cc05 100644
--- a/pc4mobx/organization/components/resource/ResourceCard.js
+++ b/pc4mobx/organization/components/resource/ResourceCard.js
@@ -241,7 +241,7 @@ export default class ResourceCard extends React.Component {
{
data.buttons.slice(0,3).map((item,index) => {
return (
-
+
)
})
}
diff --git a/pc4mobx/organization/stores/companyextend.js b/pc4mobx/organization/stores/companyextend.js
index 95dea9a..c9685d3 100644
--- a/pc4mobx/organization/stores/companyextend.js
+++ b/pc4mobx/organization/stores/companyextend.js
@@ -79,7 +79,8 @@ export class CompanyExtendStore {
editResource = () => {
let pDatas = this.form.getFormParams();
Api.editResource({ ...{
- id: this.id
+ id: this.id,
+ viewCondition:this.selectedKey
},
...pDatas,
...this.getTableEditParams()
@@ -119,6 +120,7 @@ export class CompanyExtendStore {
getData = () => {
this.setLoading(true);
+ this.form = new WeaForm();
let params = {
viewAttr: this.isEditor ? 2 : 1,
id: this.id,
diff --git a/pc4mobx/organization/stores/departmentextend.js b/pc4mobx/organization/stores/departmentextend.js
index 01639d6..0b9d348 100644
--- a/pc4mobx/organization/stores/departmentextend.js
+++ b/pc4mobx/organization/stores/departmentextend.js
@@ -78,7 +78,8 @@ export class DepartmentExtendStore {
editResource = () => {
let pDatas = this.form.getFormParams();
Api.editResource({ ...{
- id: this.id
+ id: this.id,
+ viewCondition:this.selectedKey
},
...pDatas,
...this.getTableEditParams()
@@ -118,6 +119,7 @@ export class DepartmentExtendStore {
getData = () => {
this.setLoading(true);
+ this.form = new WeaForm();
let params = {
viewAttr: this.isEditor ? 2 : 1,
id: this.id,
diff --git a/pc4mobx/organization/stores/jobextend.js b/pc4mobx/organization/stores/jobextend.js
index 41a5ea0..46fa8d0 100644
--- a/pc4mobx/organization/stores/jobextend.js
+++ b/pc4mobx/organization/stores/jobextend.js
@@ -81,7 +81,8 @@ export class JobExtendStore {
let pDatas = this.form.getFormParams();
Api.editResource({
...{
- id: this.id
+ id: this.id,
+ viewCondition:this.selectedKey
},
...pDatas,
...this.getTableEditParams()
@@ -121,10 +122,11 @@ export class JobExtendStore {
getData = () => {
this.setLoading(true);
+ this.form = new WeaForm();
let params = {
viewAttr: this.isEditor ? 2 : 1,
id: this.id,
- viewCondition: this.selectedKey
+ viewCondition: this.selectedKey,
}
Api.getJobExtendForm(params).then((res) => {
if (res.code === 200) {
diff --git a/pc4mobx/organization/stores/resourceExtend.js b/pc4mobx/organization/stores/resourceExtend.js
index 35367c2..1288f5e 100644
--- a/pc4mobx/organization/stores/resourceExtend.js
+++ b/pc4mobx/organization/stores/resourceExtend.js
@@ -78,14 +78,16 @@ export class ResourceExtendStore {
editResource = () => {
let pDatas = this.form.getFormParams();
Api.editResource({ ...{
- id: this.id
+ id: this.id,
+ viewCondition:this.selectedKey
},
...pDatas,
...this.getTableEditParams()
}).then(data => {
if (data.code == 200) {
message.success(i18n.message.saveSuccess());
- window.location.href = `/spa/organization/static/index.html#/main/organization/resourceCard/${this.id}`;
+ this.selectedKey = '0';
+ window.open(`/spa/organization/static/index.html#/main/organization/resourceCard/${this.id}`,"_self");
// this.init();
// this.getData();
// this.selectedRowKeys = [];
@@ -119,6 +121,7 @@ export class ResourceExtendStore {
getData = () => {
this.setLoading(true);
+ this.form = new WeaForm()
let params = {
viewAttr: this.isEditor ? 2 : 1,
id: this.id,