Commit a6be700e authored by 程恺文's avatar 程恺文

feat:节水主题一支持传参背景图

parent 5844f0fc
Pipeline #60095 passed with stages
......@@ -16,9 +16,11 @@ import LoginAction from '../../login';
import styles from './index.less';
import { defaultApp } from '@/micro';
import { log } from 'kit_utils';
let big='广州大.png'
class HuaNongLogin extends Component {
constructor(props) {
super(props);
console.log(props);
this.state = {
time: '16:00',
week: '星期一',
......@@ -33,6 +35,14 @@ class HuaNongLogin extends Component {
};
this.fromRef = React.createRef();
this.sliVerify = React.createRef();
props.loginParams.map(v=>{
let item= v.split('=')
if(item.length>0){
if(item[0]=='big'){
big=item[1]
}
}
})
}
handleSubmit = values => {
const { action, type, autoLogin } = this.state;
......@@ -193,7 +203,7 @@ _createGuid() {
.toUpperCase();
}
componentDidMount() {
console.log(this.props);
console.log(this.props,this.props.global.logo);
console.log(this);
this.onActinoChange(this.state.action);
this.getCurrentTime(this.showTime);
......@@ -215,9 +225,10 @@ _createGuid() {
this.clearTime();
}
render() {
return (
<HelmetProvider>
<div className={styles.quota}>
<div className={styles.quota} style={{'background': `url(${require("@/assets/images/login/节水/"+big)})`}}>
<div className={styles.head}>
<div className={styles.title}>
<img src={this.props.global && this.props.global.transformDevAssetsBaseURL && this.props.global.transformDevAssetsBaseURL(this.props.global.logo)} alt="" />
......
......@@ -15,8 +15,7 @@
position: relative;
width: 100%;
height: 100%;
background: url('@/assets/images/login/节水/广州大.png') no-repeat;
// background: url('@/assets/images/login/节水/广州大.png') no-repeat;
background-size: cover;
.head {
position: absolute;
......
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