diff --git a/pc4mobx/organization/components/resource/FormItem.js b/pc4mobx/organization/components/resource/FormItem.js
new file mode 100644
index 0000000..571b717
--- /dev/null
+++ b/pc4mobx/organization/components/resource/FormItem.js
@@ -0,0 +1,59 @@
+import {
+ WeaFormItem,
+} from 'ecCom'
+
+import {
+ Spin,
+ Button,
+} from 'antd'
+
+import {
+ i18n
+} from '../../public/i18n';
+
+import '../../style/common.less';
+import Group from '../group/Group';
+import { chunk } from 'lodash';
+
+export default class FormItem extends React.Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ }
+ }
+
+ render() {
+ const {
+ groupInfo
+ } = this.props, {
+ } = this.state;
+ const newData = chunk(groupInfo.items, 3);
+
+ return (
+
+
+
+ {newData.map((item, index) => {
+ return (
+
+ {item.map((subItem) => {
+ return (
+
+ {subItem.fieldId}
+ {subItem.fieldValue}
+
+
+ );
+ })}
+
+ );
+ })}
+
+
+
+ )
+ }
+}
diff --git a/pc4mobx/organization/components/resource/IframeItem.js b/pc4mobx/organization/components/resource/IframeItem.js
new file mode 100644
index 0000000..1f17337
--- /dev/null
+++ b/pc4mobx/organization/components/resource/IframeItem.js
@@ -0,0 +1,44 @@
+import {
+ WeaFormItem,
+} from 'ecCom'
+
+import {
+ Spin,
+ Button,
+} from 'antd'
+
+import {
+ i18n
+} from '../../public/i18n';
+
+import '../../style/common.less';
+import Group from '../group/Group';
+import { chunk } from 'lodash';
+
+export default class IframeItem extends React.Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ }
+ }
+
+ render() {
+ const {
+ iframeInfo
+ } = this.props, {
+ } = this.state;
+
+ return (
+
+ )
+ }
+}
diff --git a/pc4mobx/organization/components/resource/ResourceCard.js b/pc4mobx/organization/components/resource/ResourceCard.js
index 752dd06..244aa1f 100644
--- a/pc4mobx/organization/components/resource/ResourceCard.js
+++ b/pc4mobx/organization/components/resource/ResourceCard.js
@@ -9,7 +9,8 @@ import {
WeaTab,
WeaFormItem,
WeaRightMenu,
- WeaAlertPage
+ WeaAlertPage,
+ WeaNewScrollPagination
} from 'ecCom'
import {
Row,
@@ -18,7 +19,8 @@ import {
Modal,
Button,
message,
- Switch
+ Switch,
+ Menu, Dropdown,Icon
} from 'antd'
import {
WeaSwitch,
@@ -28,12 +30,11 @@ import {
i18n
} from '../../public/i18n';
-import '../../style/common.less';
-
+import '../../style/card.less';
+import FormItem from './FormItem';
+import IframeItem from './IframeItem';
import { renderNoright } from '../../util'; // 从util文件引入公共的方法
-
-
const toJS = mobx.toJS;
const confirm = Modal.confirm;
@@ -65,12 +66,173 @@ export default class ResourceCard extends React.Component {
const {
resourceCard
} = this.props;
+ resourceCard.init();
}
- render(){
- return(
- 111
+ onScrollEnd = () => {
+ const {
+ resourceCard
+ } = this.props;
+ resourceCard.scrollLoading = true;
+ resourceCard.iframeList.push({
+ id:"job",
+ title:"岗位管理",
+ url:'/spa/organization/static/index.html#/main/organization/companyExtend/7'
+ })
+ setTimeout(() => {
+ resourceCard.scrollLoading = false;
+ }, 2000);
+ };
+
+ scrollToAnchor = (anchorName) => {
+ if (anchorName) {
+ // 找到锚点
+ let anchorElement = document.getElementById(anchorName);
+ // 如果对应id的锚点存在,就跳转到锚点
+ if (anchorElement) { anchorElement.scrollIntoView({ block: 'start', behavior: 'smooth' }); }
+ }
+ }
+
+ handleMenuClick = (e) => {
+ console.log('click', e);
+ }
+
+ render() {
+ const {
+ resourceCard
+ } = this.props, {
+ height,
+ scrollLoading,
+ offset,
+ overtime,
+ intervalTime,
+ data,
+ iframeList
+ } = resourceCard;
+
+ const menu = (
+
+ );
+
+ return (
+ {
+ // console.log(e)
+ // }}
+ >
+
+
+
+
})
+
+
{data.user.name}
+ {data.user.sex == 0 ? : }
+
+
+
+
+
+
+
+
+
+
+ {data.user.email}
+
+ {data.user.phone}
+
+
+ 账号类型:
+ {data.user.belongTo}
+ 状态:
+ {data.user.status}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
流程总数
+
{data.statistical.workflowCount}
+
+
+
+
+
+
文档总数
+
{data.statistical.docCount}
+
+
+
+
+
+
我的客户
+
{data.statistical.cusCount}
+
+
+
+
+
+
我的协作
+
{data.statistical.collaborationCount}
+
+
+
+
+
+
微博总数
+
{data.statistical.weiboCount}
+
+
+
+
+ {
+ data.formItems.map((item,index)=>{
+ return(
+
+ )
+ })
+ }
+ {
+ iframeList.map((item,index) => {
+ return(
+
+ )
+ })
+ }
+
+
+
+
+
+
+
+
)
}
-
+
}
\ No newline at end of file
diff --git a/pc4mobx/organization/images/resource.png b/pc4mobx/organization/images/resource.png
new file mode 100644
index 0000000..ba06404
Binary files /dev/null and b/pc4mobx/organization/images/resource.png differ
diff --git a/pc4mobx/organization/stores/resourceCard.js b/pc4mobx/organization/stores/resourceCard.js
index baa4ecd..84e96a2 100644
--- a/pc4mobx/organization/stores/resourceCard.js
+++ b/pc4mobx/organization/stores/resourceCard.js
@@ -7,5 +7,120 @@ import * as Api from '../apis/resourceCard'; // 引入API接口文件
export class ResourceCardStore {
-
+ @observable height = 2000;
+ @observable scrollLoading = true;
+ @observable offset = 20;
+ @observable overtime = 1000;
+ @observable intervalTime = 500;
+
+
+ @action("初始化") init = () => {
+
+ }
+
+
+ /************** json数据*****************/
+ @observable data = {
+ user: {
+ image: "",
+ name: "萧言",
+ sex:"0",
+ email: "1546584672@qq.com",
+ phone: "18822349878",
+ belongTo: "主账号",
+ status: "正式"
+ },
+ statistical: {
+ workflowCount:190,
+ docCount:134,
+ cusCount:28,
+ collaborationCount:28,
+ weiboCount:166
+ },
+ formItems:[
+ {
+ id:'userInfo',
+ title:'员工信息',
+ items:[
+ {
+ fieldId:'姓名',
+ fieldValue:'萧言'
+ },{
+ fieldId:'性别',
+ fieldValue:'男'
+ },{
+ fieldId:'出生日期',
+ fieldValue:'1987年9月1日'
+ },{
+ fieldId:'个人邮箱',
+ fieldValue:'1546875925@qq.com'
+ },{
+ fieldId:'电话号码',
+ fieldValue:'18925689752'
+ },{
+ fieldId:'岗位级别',
+ fieldValue:'-'
+ },{
+ fieldId:'职务信息',
+ fieldValue:'产品运营'
+ }
+ ]
+ },
+ {
+ id:'workInfo',
+ title:'工作信息',
+ items:[
+ {
+ fieldId:'姓名',
+ fieldValue:'萧言'
+ },{
+ fieldId:'性别',
+ fieldValue:'男'
+ },{
+ fieldId:'出生日期',
+ fieldValue:'1987年9月1日'
+ },{
+ fieldId:'个人邮箱',
+ fieldValue:'1546875925@qq.com'
+ }
+ ]
+ },
+ {
+ id:'educationInfo',
+ title:'教育经历',
+ items:[
+ {
+ fieldId:'本科',
+ fieldValue:'南京大学'
+ },{
+ fieldId:'研究生',
+ fieldValue:'北京大学'
+ },{
+ fieldId:'毕业时间',
+ fieldValue:'1987-09-21'
+ },{
+ fieldId:'获得奖项',
+ fieldValue:'优秀毕业生'
+ },{
+ fieldId:'备注',
+ fieldValue:'无'
+ }
+ ]
+ }
+ ],
+
+ }
+
+ @observable iframeList = [
+ {
+ id:"comp",
+ title:"分部管理",
+ url:'/spa/organization/static/index.html#/main/organization/companyExtend/7'
+ },
+ {
+ id:"dept",
+ title:"部门管理",
+ url:'/spa/organization/static/index.html#/main/organization/companyExtend/7'
+ },
+ ]
}
diff --git a/pc4mobx/organization/style/card.less b/pc4mobx/organization/style/card.less
new file mode 100644
index 0000000..19c5943
--- /dev/null
+++ b/pc4mobx/organization/style/card.less
@@ -0,0 +1,192 @@
+
+// #container {
+// background-color: #e5eaf2;
+// }
+//我的卡片样式
+.gutter-resource-card {
+ display: flex;
+ background-color: #e5eaf2;
+ padding-bottom: 15px;
+ .gutter-row:first-child{
+ width: 89%;
+ .top {
+ width: 100%;
+ height: 150px;
+ background-color: #ffffff;
+ padding: 12px;
+ img{
+ float: left;
+ width: 102px;
+ height: 100%;
+ }
+ .user{
+ float: left;
+ margin-left: 20px;
+ .name {
+ font-size: 15px;
+ font-weight: bold;
+ margin-top: 10px;
+ span {
+ margin-left: 15px;
+ .icon-coms-men {
+ color: #6d9fff;
+ }
+ .icon-coms-women {
+ color: #ff6dfa;
+ }
+ }
+ }
+ .icon-info {
+ margin-top: 10px;
+ i {
+ cursor: pointer;
+ color: #6d9fff;
+ margin-left: 15px;
+ }
+ .icon-coms-Send-message{
+ margin-left: 0;
+ }
+ }
+ .content{
+ margin-top: 10px;
+ .label{
+ color: #999999;
+ }
+ .value {
+ margin-left: 5px;
+ }
+ }
+ .content > div span:nth-child(3){
+ margin-left: 30px;
+ }
+ }
+ .right-button{
+ float: right;
+ line-height: 75px;
+ .item {
+ background-color: #2b68f0;
+ color: #ffffff;
+ margin-left: 10px;
+ }
+ }
+ }
+
+ .data {
+ width: 100%;
+ height: 135px;
+ background-color: #ffffff;
+ padding: 12px 25px;
+ margin-top: 20px;
+ .ant-col {
+ -webkit-box-shadow: #eeeeee 0px 0px 10px;
+ -moz-box-shadow: #eeeeee 0px 0px 10px;
+ box-shadow: #eeeeee 0px 0px 10px;
+ padding: 0 10px;
+ img{
+ margin-top: 20px
+ }
+ div{
+ width: 100%;
+ :first-child{
+ float: left;
+ color: #999999;
+ line-height: 35px;
+ }
+ :last-child{
+ float: right;
+ font-weight: 800;
+ font-size: 16px;
+ }
+ }
+
+ }
+
+ }
+
+ .form-item {
+ margin-top: 20px;
+ width: 100%;
+ background-color: #ffffff;
+ .title {
+ width: 100%;
+ height: 30px;
+ div {
+ height: 20px;
+ border: 2px solid #2b68f0;
+ margin-left: 5px;
+ margin-top: 5px;
+ float: left;
+ }
+ p{
+ margin-left: 15px;
+ font-size: 13px;
+ font-weight: 900;
+ line-height: 30px;
+ }
+ }
+ .content {
+ width: 100%;
+ padding: 15px;
+ .item{
+ display: flex;
+ div{
+ width: 33.3%;
+ display: inline-block;
+ height: 40px;
+ span:first-child{
+ color: #999999;
+ width: 60px;
+ display: inline-block;
+ text-align: right;
+ }
+ span:last-child{
+ margin-left: 20px;
+ }
+ }
+ }
+ }
+ }
+
+ .iframe-item {
+ margin-top: 20px;
+ width: 100%;
+ background-color: #ffffff;
+ .title {
+ width: 100%;
+ height: 30px;
+ div {
+ height: 20px;
+ border: 2px solid #2b68f0;
+ margin-left: 5px;
+ margin-top: 5px;
+ float: left;
+ }
+ p{
+ margin-left: 15px;
+ font-size: 13px;
+ font-weight: 900;
+ line-height: 30px;
+ }
+ }
+ .content {
+ width: 100%;
+ padding: 15px;
+ }
+ }
+
+
+ }
+ .gutter-row:last-child{
+ width: 10%;
+ background-color: #ffffff;
+ margin-left: 20px;
+ }
+ }
+
+ .scroll-spin {
+ margin-left: 50%;
+ }
+
+
+
+
\ No newline at end of file
diff --git a/pc4mobx/organization/style/common.less b/pc4mobx/organization/style/common.less
index 024cb19..b5002b0 100644
--- a/pc4mobx/organization/style/common.less
+++ b/pc4mobx/organization/style/common.less
@@ -88,5 +88,3 @@
}
}
-//我的卡片样式
-