Quellcode durchsuchen

Merge branch 'develop' of http://120.55.44.4:10080/xujunjie/gt_client_pad into develop

Renxy vor 1 Jahr
Ursprung
Commit
1ce8bcc29e

+ 1 - 1
public/rem.js

@@ -9,7 +9,7 @@
     var width = docEl.getBoundingClientRect().width;
 
     //与淘宝做法不同,直接采用简单的rem换算方法1rem=100px
-    var rem = (width * 100) / 2560;
+    var rem = (2560 * 100) / 2560;
     //兼容UC开始
     rootStyle = 'html{font-size:' + rem + 'px !important}';
     rootItem =

+ 2 - 2
src/components/PageContent/index.js

@@ -1,5 +1,5 @@
 import { UnityAction } from '@/utils/utils';
-import { CloseOutlined, LeftOutlined } from '@ant-design/icons';
+import { CloseCircleFilled, LeftOutlined } from '@ant-design/icons';
 import { history } from '@umijs/max';
 import { ConfigProvider } from 'antd';
 import locale from 'antd/es/locale/zh_CN';
@@ -32,7 +32,7 @@ export default (props) => {
           />
         )}
         {closeable && (
-          <CloseOutlined
+          <CloseCircleFilled
             onClick={handleClose}
             className={styles.close}
             style={{ top: tabs ? 42.5 : '' }}

+ 3 - 3
src/components/PageContent/index.less

@@ -6,9 +6,9 @@
 
   .close {
     position: absolute;
-    top: 26px;
-    right: 20px;
-    font-size: 34px;
+    top: 0.26rem;
+    right: 0.2rem;
+    font-size: 0.34rem;
 
     color: #4a4a4a;
     cursor: pointer;

+ 8 - 3
src/components/PageTitle/index.js

@@ -1,4 +1,4 @@
-import { LeftOutlined } from '@ant-design/icons';
+import { CaretLeftFilled } from '@ant-design/icons';
 import { history } from '@umijs/max';
 import styles from './index.less';
 
@@ -19,8 +19,13 @@ export default (props) => {
       onClick={handleOnClick}
     >
       {returnable || onReturn ? (
-        <LeftOutlined
-          style={{ fontSize: 36, cursor: 'pointer', marginRight: '20px' }}
+        <CaretLeftFilled
+          style={{
+            fontSize: '0.3rem',
+            cursor: 'pointer',
+            marginRight: '0.15rem',
+            color: '#0139F1',
+          }}
         />
       ) : (
         <span className={styles.titleBar} />

+ 14 - 6
src/components/PageTitle/index.less

@@ -7,15 +7,23 @@
   height: 35px;
   background: #4a90e2;
   float: left;
-  margin-right: 18px;
+  margin-right: 0.1rem;
 }
 .title {
   display: inline-block;
-  width: 100%;
-  font-size: 36px;
-  font-weight: 400;
-  color: #000000;
-  line-height: 50px;
+  padding: 0.05rem;
+  // width: 100%;
+  font-size: 0.36rem;
+  font-weight: 500;
+  color: #0139f1;
+  line-height: 0.36rem;
+  background: linear-gradient(
+    to bottom,
+    transparent 0%,
+    transparent 60%,
+    #ffe500 61%,
+    #ffe500 100%
+  );
 }
 .tabs {
   position: absolute;

+ 27 - 14
src/components/TabsContent/index.js

@@ -1,10 +1,11 @@
+import { Divider } from 'antd';
 import { useMemo, useState } from 'react';
 import styles from './index.less';
 
 const TabsContent = (props) => {
   const {
     defaultActiveKey = '1',
-    center = true,
+    center = false,
     small = false,
     items = {},
     onChange,
@@ -19,19 +20,31 @@ const TabsContent = (props) => {
         className={`${styles.tabsTitle} ${small ? styles.small : ''}`}
         style={center ? { justifyContent: 'center' } : {}}
       >
-        {items.map((item) => (
-          <div
-            key={item.key}
-            className={`${styles.tabsItem} ${
-              active == item.key ? styles.active : ''
-            }`}
-            onClick={() => {
-              setActive(item.key);
-              onChange(item.key);
-            }}
-          >
-            {item.label}
-          </div>
+        {items.map((item, index) => (
+          <>
+            <div
+              key={item.key}
+              className={`${styles.tabsItem} ${
+                active == item.key ? styles.active : ''
+              }`}
+              onClick={() => {
+                setActive(item.key);
+                onChange(item.key);
+              }}
+            >
+              {item.label}
+            </div>
+            {index !== items.length - 1 && (
+              <Divider
+                type="vertical"
+                style={{
+                  height: '0.5rem',
+                  width: '1.5px',
+                  backgroundColor: '#BCBABA',
+                }}
+              />
+            )}
+          </>
         ))}
       </div>
       <div>{renderContent}</div>

+ 14 - 11
src/components/TabsContent/index.less

@@ -1,30 +1,33 @@
 .tabsTitle {
   display: flex;
+  justify-content: space-evenly;
   align-items: center;
-  height: 80px;
-  margin-bottom: 10px;
-  width: 100%;
+  height: 0.8rem;
+  margin-bottom: 0.1rem;
+  padding-left: 0.4rem;
+  width: calc(100% - 0.4rem);
   overflow-x: auto;
   overflow-y: hidden;
+  border-bottom: 1.5px solid #bcbaba;
   &::-webkit-scrollbar {
     display: none;
   }
 
-  > .tabsItem {
-    border-right: 1px solid #979797;
-  }
-  :last-child {
-    border-right: none;
-  }
+  // > .tabsItem {
+  //   border-right: 1px solid #979797;
+  // }
+  // :last-child {
+  //   border-right: none;
+  // }
 }
 .tabsItem {
   padding: 0 40px;
-  color: #4a4a4a;
+  color: #3f3f40;
   font-size: 36px;
   white-space: nowrap;
 }
 .active {
-  color: #4a90e2;
+  color: #1755ff;
 }
 
 .small {

+ 5 - 3
src/services/TaskManage.js

@@ -51,9 +51,11 @@ export async function setTaskAutomation(params, mandate) {
     // res = await SetVarValues(mandate.MandateChild[0].Payload);
     const query = {
       mandate_id: item.Id,
-      mandate_type: 1
-    }
-    res = await request(`${baseURL}/v1/mandate/do?${stringify(query)}`)
+      mandate_type: 1,
+      // source 2 标识为pad端
+      source: 2,
+    };
+    res = await request(`${baseURL}/v1/mandate/do?${stringify(query)}`);
     if (res) {
       return res;
     } else {