Browse Source

样式修改

samhoo 6 years ago
parent
commit
ea832e3d13

+ 20 - 16
uas-office-web/wxuasapproval/src/pages/useStatus/UseStatus.jsx

@@ -15,18 +15,18 @@ import {
     isObjEmpty
 } from '@/utils/common'
 
-let DEPART, USERCOUNT,dataLength;
+let DEPART, USERCOUNT, dataLength;
 let DURATIONLIST = [];
 let DAILYCOUNT = [];
 let columnWidth = 300;
-let mBaseUrl =  window.location.origin+'/office';
+let mBaseUrl = window.location.origin + '/office';
 
 
 export default class Basic extends Component {
     constructor() {
         super()
 
-        this.state = { 
+        this.state = {
             loading: true    //更改
         }
     }
@@ -51,7 +51,7 @@ export default class Basic extends Component {
         }
 
     }
-    // mBaseUrl+'/api/analysis/getAnalysisByWeek'
+    
     getData = (instanceId) => {
         fetchPost(mBaseUrl+'/api/analysis/getAnalysisByWeek', {
             'instanceid': instanceId,
@@ -59,16 +59,16 @@ export default class Basic extends Component {
             // 'Cookie': 'JSESSIONID=' + mSessionId,
             // "Content-Type": "application/json; charset=UTF-8"
         }).then((response) => {
-            if(response.success){
+            if (response.success) {
                 let dataSource = response.data[0];
                 DEPART = dataSource.DEPART;
                 USERCOUNT = dataSource.USERCOUNT;
                 DURATIONLIST = dataSource.DURATIONLIST;
                 DAILYCOUNT = dataSource.DAILYCOUNT;
                 dataLength = DURATIONLIST.length;
-                if(dataLength>0){
-                    columnWidth = dataLength*55;
-                }else{
+                if (dataLength > 0) {
+                    columnWidth = dataLength * 55;
+                } else {
                     columnWidth = 300
                 }
                 this.setState({
@@ -123,23 +123,24 @@ export default class Basic extends Component {
                     <div className='useNum'>使用人数{USERCOUNT}人</div>
                     <div className='lineCharts'>
                         <div className='useAnaly'>成员使用分析</div>
-                        <Chart padding={['12%','10%','12%','8%']} height={200} data={DAILYCOUNT} scale={cols} forceFit>
+                        <Chart padding={['12%', '10%', '12%', '8%']} height={200} data={DAILYCOUNT} scale={cols} forceFit>
                             <Axis
                                 name="DATE_TIME"
                                 label={{
                                     offset: 18,
                                     textStyle: {
-                                        fontSize: '16',
+                                        fontSize: '14',
                                         fill: '#959595'
                                     }
                                 }} />
                             <Axis
                                 name="EMCOUNT"
                                 position="right"
+                                grid={null}
                                 label={{
                                     offset: 10,
                                     textStyle: {
-                                        fontSize: '16',
+                                        fontSize: '14',
                                         fill: '#959595'
                                     }
                                 }}
@@ -149,7 +150,10 @@ export default class Basic extends Component {
                                     type: "y"
                                 }}
                             />
-                            <Geom type="line" position="DATE_TIME*EMCOUNT" size={2} />
+                            <Geom
+                                color="l (270) 0:rgba(100,149,237,1) .5:rgba(135,206,250, 1) 1:rgba(0,191,255, 1)"
+                                shape="smooth" type="line" position="DATE_TIME*EMCOUNT" size={2}
+                            />
                             <Geom
                                 type="point"
                                 position="DATE_TIME*EMCOUNT"
@@ -166,7 +170,7 @@ export default class Basic extends Component {
                         <div className='useTime'>成员使用时间(分钟)</div>
                         <Chart
                             onPlotClick={this.handleClick}
-                            padding={['auto','12%','auto','20%']}
+                            padding={['auto', '12%', 'auto', '20%']}
                             height={columnWidth}
                             data={dv}
                             forceFit
@@ -177,12 +181,12 @@ export default class Basic extends Component {
                                 label={{
                                     offset: 10,
                                     textStyle: {
-                                        fontSize: '16',
+                                        fontSize: '14',
                                         fill: '#000'
                                     }
                                 }}
                             />
-                            <Axis name="DURATION" label={null} />
+                            <Axis grid={null} name="DURATION" label={null} />
                             <Tooltip />
                             <Geom type="interval" position="EMNAME*DURATION" >
                                 <Label
@@ -190,7 +194,7 @@ export default class Basic extends Component {
                                     content="DURATION"
                                     textStyle={{
                                         fill: '#000', // 文本的颜色
-                                        fontSize: '16', // 文本大小
+                                        fontSize: '14', // 文本大小
                                     }} />
                             </Geom>
                         </Chart>

+ 4 - 4
uas-office-web/wxuasapproval/src/pages/useStatus/useStatus.css

@@ -18,7 +18,7 @@
     padding:4%;
     padding-bottom: 0;
     color:#000;
-    font-size:24px;
+    font-size:18px;
     background:#fff;
     text-align:center;
 }
@@ -32,7 +32,7 @@
 }
 .useStatusRoot .content .useNum{
     background:#fff;
-    font-size:20px;
+    font-size:16px;
     padding-left:4%;
     color:#000;
 }
@@ -40,10 +40,10 @@
     margin:0 !important;
     padding:4%;
     padding-bottom:0%;
-    font-size:16px;
+    font-size:14px;
 }
 .useStatusRoot .content .columnCharts .useTime{
     margin:0 !important;
     padding:4%;
-    font-size:16px;
+    font-size:14px;
 }

+ 3 - 4
uas-office-web/wxuasapproval/src/pages/workSummary/WorkSummary.jsx

@@ -74,7 +74,6 @@ export default class Basic extends Component {
         obj = obj.substring(index + 1, obj.length);
         return obj;
     }
-    // mBaseUrl+'/api/analysis/getAnalysisByPerson'
     getData = (emCode, instanceId) => {
         fetchPost(mBaseUrl+'/api/analysis/getAnalysisByPerson', {
             'emCode': emCode,
@@ -153,17 +152,17 @@ export default class Basic extends Component {
                                     textStyle: {
                                         textAlign: 'end', // 文本对齐方向,可取值为: start center end
                                         fill: '#000',
-                                        fontSize: '16'
+                                        fontSize: '14'
                                     }
                                 }}
                             />
-                            <Axis name="DURATION" label={null} />
+                            <Axis grid={null} name="DURATION" label={null} />
                             <Tooltip />
                             <Geom type="interval" position="MODELNAME*DURATION" >
                                 <Label label={{
                                     textStyle: {
                                         fill: '#000',
-                                        fontSize: '16'
+                                        fontSize: '14'
                                     }
                                 }} offset={5} content="DURATION" />
                             </Geom>

+ 7 - 4
uas-office-web/wxuasapproval/src/pages/workSummary/workSummary.css

@@ -37,7 +37,7 @@
 }
 .workSummaryRoot .content .selfMess .self .summary{
     margin-left:5%;
-    font-size:16px;
+    font-size:14px;
     color:#333333;
 }
 .workSummaryRoot .content .workSummary {
@@ -48,15 +48,18 @@
     padding:2%;
     padding-left:5%;
     color: rgba(0, 0, 0, 0.65);
-    font-size:16px;
+    font-size:14px;
     background:#fff;
 }
+.am-list-item .am-list-line .am-list-content{
+    font-size: 16px !important;
+}
 .workSummaryRoot .content .columnCharts{
     margin:3% 0 0 0;
     background:#fff;
 }
 .workSummaryRoot .content .columnCharts .useTime{
     margin:0 !important;
-    padding:4% 4% 0 4%;
-    font-size: 16px;
+    padding:4% 4% 0 5%;
+    font-size: 14px;
 }