Commit 19ebdb02 authored by superman's avatar superman

1.3.4

parent 6b70e98a
This diff is collapsed.
This diff is collapsed.
...@@ -95,6 +95,8 @@ ...@@ -95,6 +95,8 @@
height: 100%; height: 100%;
flex: 1 0 auto; flex: 1 0 auto;
overflow: hidden; overflow: hidden;
//background: url(/src/containers/App/images/bg.png) no-repeat bottom right;
background-size:120px 66px;
h1 { h1 {
font-size: 18px; font-size: 18px;
color: #444; color: #444;
......
...@@ -41,12 +41,24 @@ export default class AddItem extends Component { ...@@ -41,12 +41,24 @@ export default class AddItem extends Component {
} }
} }
componentWillMount(){
this.props.dispatch({
type: 'CLEAR_MESSAGE_ITEM'
});
}
componentWillReceiveProps(nextProps) { componentWillReceiveProps(nextProps) {
if (nextProps && nextProps.item && nextProps.item.id) { if (nextProps && nextProps.item && nextProps.item.id) {
this.props.history.replace('/customMessages/' + nextProps.item.id); this.props.history.replace('/customMessages/' + nextProps.item.id);
} }
} }
// componentWillUnmount(){
// this.props.dispatch({
// type: 'CLEAR_MESSAGE_ITEM'
// });
// }
handleSubmit(e) { handleSubmit(e) {
e.preventDefault(); e.preventDefault();
const data = this.props.form.getFieldsValue(); const data = this.props.form.getFieldsValue();
......
...@@ -27,7 +27,6 @@ export default class Item extends Component { ...@@ -27,7 +27,6 @@ export default class Item extends Component {
}; };
render() { render() {
const {item, loading, dispatch} = this.props; const {item, loading, dispatch} = this.props;
const styles = require('../Trade/Item.less'); const styles = require('../Trade/Item.less');
...@@ -35,7 +34,7 @@ export default class Item extends Component { ...@@ -35,7 +34,7 @@ export default class Item extends Component {
const vw = 16; const vw = 16;
const operation = ( const operation = (
<HeaderOperation history={this.props.history} buttons={[{key:'rollback'}]}/> <HeaderOperation history={this.props.history} buttons={[{key: 'rollback'}]}/>
); );
const header = ( const header = (
...@@ -57,54 +56,78 @@ export default class Item extends Component { ...@@ -57,54 +56,78 @@ export default class Item extends Component {
<Col span={vw}>{item.id}</Col> <Col span={vw}>{item.id}</Col>
</Row> </Row>
<Row type="flex" justify="space-around" align="middle"> <Row type="flex" justify="space-around" align="middle">
<Col span={tw}>消息标题</Col> <Col span={tw}>推送渠道</Col>
<Col span={vw}>{item.title}</Col> <Col
</Row> span={vw}>{item.channelName}</Col>
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>消息摘要</Col>
<Col span={vw}>{item.abstracts}</Col>
</Row> </Row>
{
item.channelType !== 1 &&
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>消息标题</Col>
<Col span={vw}>{item.title}</Col>
</Row>
}
{
item.channelType !== 1 &&
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>消息摘要</Col>
<Col span={vw}>
<div style={{maxWidth: 600}}>{item.abstracts}</div>
</Col>
</Row>
}
<Row type="flex" justify="space-around" align="middle"> <Row type="flex" justify="space-around" align="middle">
<Col span={tw}>消息正文</Col> <Col span={tw}>消息正文</Col>
<Col span={vw}>{item.contents}</Col>
</Row>
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>跳转内容</Col>
<Col span={vw}> <Col span={vw}>
<span>{'类型:'+(item.redirectName||'')}</span> <div style={{maxWidth: 600}}>{item.contents}</div>
{
item.redirect &&
<span style={{marginLeft:'1em'}}>{'内容:'+item.redirect}</span>
}
</Col> </Col>
</Row> </Row>
<Row type="flex" justify="space-around" align="middle"> {
<Col span={tw}>推送渠道</Col> item.channelType !== 1 &&
<Col <Row type="flex" justify="space-around" align="middle">
span={vw}>{item.channelName}</Col> <Col span={tw}>跳转内容</Col>
</Row> <Col span={vw}>
<span>{'类型:' + (item.redirectName || '')}</span>
{
item.redirect &&
<span style={{marginLeft: '1em'}}>{'内容:' + item.redirect}</span>
}
</Col>
</Row>
}
{
item.channelType !== 1 &&
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送人数</Col>
<Col span={vw}>{item.count}</Col>
</Row>
}
{
item.channelType !== 1 &&
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送类型</Col>
<Col span={vw}>{item.sendName}</Col>
</Row>
}
<Row type="flex" justify="space-around" align="middle"> <Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送时间</Col> <Col span={tw}>推送时间</Col>
<Col <Col
span={vw}>{item.dateCreated && (item.dateCreated+'').replace(/[年月]/g, '-').replace(/日/g, '')}</Col> span={vw}>{item.dateCreated && (item.dateCreated + '').replace(/[年月]/g, '-').replace(/日/g, '')}</Col>
</Row>
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送人数</Col>
<Col span={vw}>{item.count}</Col>
</Row>
<Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送类型</Col>
<Col span={vw}>{item.sendName}</Col>
</Row> </Row>
<Row type="flex" justify="space-around" align="middle"> <Row type="flex" justify="space-around" align="middle">
<Col span={tw}>推送对象</Col> <Col span={tw}>推送对象</Col>
<Col span={vw}>{item.send}</Col> <Col span={vw}>
<div style={{maxWidth: 600}}>{item.send}</div>
</Col>
</Row> </Row>
</div> </div>
<p> <p>
<Button onClick={e=>{e.preventDefault(); this.props.history.goBack();}} <Button onClick={e=> {
style={{marginLeft:'1em'}}> e.preventDefault();
this.props.history.goBack();
}}
style={{marginLeft: '1em'}}>
<Icon type="rollback"/>返回 <Icon type="rollback"/>返回
</Button> </Button>
</p> </p>
......
...@@ -8,6 +8,12 @@ const Home = ({location}) => { ...@@ -8,6 +8,12 @@ const Home = ({location}) => {
<div className={styles.home}> <div className={styles.home}>
<h1 style={{marginBottom: 50}}>欢迎使用枢纽科技后台</h1> <h1 style={{marginBottom: 50}}>欢迎使用枢纽科技后台</h1>
<h3>2016-08-19 更新 1.3.4</h3>
<p>
1. BUG修复: 订单合同物流单号设置。<br/>
2. BUG修复: 自定义消息推送BUG; 自定义消息详情展示时微信渠道去除多余字段<br/>
</p>
<h3>2016-08-18 更新 1.3.3</h3> <h3>2016-08-18 更新 1.3.3</h3>
<p> <p>
1. 菜单栏增加"设置"; "管理员"菜单只分配给管理员角色。<br/> 1. 菜单栏增加"设置"; "管理员"菜单只分配给管理员角色。<br/>
......
...@@ -52,11 +52,11 @@ export default class Contract extends Component { ...@@ -52,11 +52,11 @@ export default class Contract extends Component {
handleSubmit(e) { handleSubmit(e) {
e.preventDefault(); e.preventDefault();
const data = this.props.form.getFieldsValue(); const data = this.props.form.getFieldsValue();
data.id = this.props.trade.id; data.id = this.props.params.id;
console.log(data); console.log(data);
this.props.dispatch({ this.props.dispatch({
type: 'UPDATE_CONTRACT_ITEM', type: 'UPDATE_CONTRACT_ITEM',
data item: data
}); });
} }
......
...@@ -28,7 +28,12 @@ const message = handleActions({ ...@@ -28,7 +28,12 @@ const message = handleActions({
}, },
['CREATE_MESSAGE_ITEM_FAILED'](state, action){ ['CREATE_MESSAGE_ITEM_FAILED'](state, action){
return {...state, err: action.err, loading: false, item: null} return {...state, err: action.err, loading: false, item: null}
},
['CLEAR_MESSAGE_ITEM'](state){
console.log('CLEAR_MESSAGE_ITEM');
return {...state, item: null};
} }
}, { }, {
items: [], items: [],
loading: false, loading: false,
......
...@@ -79,6 +79,8 @@ export const userStatusToString = status => { ...@@ -79,6 +79,8 @@ export const userStatusToString = status => {
export const tradeStatusToString = status => { export const tradeStatusToString = status => {
switch (status) { switch (status) {
case 0 :
return '已删除';
case 1 : case 1 :
return '未报单'; return '未报单';
case 10: case 10:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment