Просмотр исходного кода

fix: 5649、5748、5703、5667、5778、5646

xieyonghong 3 лет назад
Родитель
Сommit
8c94b325e1

+ 2 - 2
src/components/ProTableCard/CardItems/AccessConfig/index.less

@@ -3,8 +3,8 @@
 .access-config-card-item {
   &.active {
     position: relative;
-    color: @primary-color-active;
-    border: 1px solid @primary-color-active;
+    color: #2f54eb;
+    border: 1px solid #2f54eb;
 
     .checked-icon {
       display: block;

+ 13 - 10
src/components/ProTableCard/index.less

@@ -143,16 +143,6 @@
   width: 100%;
   background-color: #fff;
 
-  &.item-active {
-    position: relative;
-    color: #2f54eb;
-    border: 1px solid #2f54eb;
-
-    .checked-icon {
-      display: block;
-    }
-  }
-
   .checked-icon {
     position: absolute;
     right: -22px;
@@ -268,6 +258,19 @@
     }
   }
 
+  &.item-active {
+    position: relative;
+    color: #2f54eb;
+
+    .checked-icon {
+      display: block;
+    }
+
+    .card-warp {
+      border: 1px solid #2f54eb;
+    }
+  }
+
   .card-tools {
     display: flex;
     margin-top: 8px;

+ 2 - 1
src/pages/device/Instance/Save/index.tsx

@@ -220,6 +220,7 @@ const Save = (props: Props) => {
                   ),
                 },
               ]}
+              tooltip={'只能选择“正常”状态的产品'}
               required
             >
               <Select
@@ -231,7 +232,7 @@ const Save = (props: Props) => {
                     productName: node.label,
                   });
                 }}
-                placeholder={'请选择状态为正常的产品'}
+                placeholder={'请选择状态为正常的产品'}
                 filterOption={(input, option) => option.label.includes(input)}
               />
             </Form.Item>

+ 4 - 4
src/pages/link/AccessConfig/Detail/Access/index.less

@@ -20,7 +20,7 @@
 }
 
 .title {
-  width: '100%';
+  width: 100%;
   overflow: hidden;
   font-weight: 800;
   white-space: nowrap;
@@ -118,7 +118,7 @@
     height: 44px;
     color: #fff;
     background-color: red;
-    background-color: @primary-color-active;
+    background-color: #2f54eb;
     transform: rotate(-45deg);
 
     > div {
@@ -136,8 +136,8 @@
   }
   &.checked {
     position: relative;
-    color: @primary-color-active;
-    border-color: @primary-color-active;
+    color: #2f54eb;
+    border-color: #2f54eb;
 
     .checkedIcon {
       display: block;

+ 8 - 8
src/pages/notice/Template/Detail/index.tsx

@@ -581,10 +581,10 @@ const Detail = observer(() => {
                         title: '收信部门',
                         'x-component': 'Select',
                         'x-decorator': 'FormItem',
-                        'x-decorator-props': {
-                          tooltip: '如果不填写该字段,将在使用此模版发送通知时进行指定。',
-                          gridSpan: 1,
-                        },
+                        // 'x-decorator-props': {
+                        //   tooltip: '如果不填写该字段,将在使用此模版发送通知时进行指定。',
+                        //   gridSpan: 1,
+                        // },
                         'x-component-props': {
                           placeholder: '请选择收信部门',
                         },
@@ -788,10 +788,10 @@ const Detail = observer(() => {
                         required: true,
                         'x-component': 'Select',
                         'x-decorator': 'FormItem',
-                        'x-decorator-props': {
-                          tooltip: '如果不填写该字段,将在使用此模板发送通知时进行指定',
-                          gridSpan: 1,
-                        },
+                        // 'x-decorator-props': {
+                        //   tooltip: '如果不填写该字段,将在使用此模板发送通知时进行指定',
+                        //   gridSpan: 1,
+                        // },
                         'x-component-props': {
                           placeholder: '请选择收信部门',
                         },

+ 1 - 1
src/pages/rule-engine/Alarm/Configuration/Save/index.tsx

@@ -129,7 +129,7 @@ const Save = (props: Props) => {
 
     const resp: any = await service.update({
       ...data,
-      state: 'disabled',
+      // state: 'disabled',
       sceneTriggerType: scene.triggerType,
       sceneName: scene.name,
     });

+ 1 - 1
src/pages/rule-engine/Scene/Save/action/VariableItems/builtIn.tsx

@@ -64,7 +64,7 @@ export default (props: BuiltInProps) => {
     if (source === 'upper') {
       sourceChangeEvent();
     }
-  }, [source, props.trigger, props.parallel]);
+  }, [source, props.trigger, props.parallel, props.type]);
 
   useEffect(() => {
     if (props.trigger?.trigger?.device?.productId && source === 'upper') {

+ 2 - 3
src/pages/rule-engine/Scene/Save/action/device/index.tsx

@@ -111,8 +111,6 @@ export default (props: DeviceProps) => {
         handleMetadata(productItem.metadata);
       }
     }
-
-    props.onProductIdChange(productId);
   }, [productId]);
 
   useEffect(() => {
@@ -179,13 +177,14 @@ export default (props: DeviceProps) => {
             placeholder={'请选择产品'}
             style={{ width: '100%' }}
             listHeight={220}
-            onChange={() => {
+            onChange={(value) => {
               // setMessageType(MessageTypeEnum.WRITE_PROPERTY)
               props.form?.setFields([
                 { name: ['actions', name, 'device', 'selector'], value: SourceEnum.fixed },
                 { name: ['actions', name, 'device', 'selectorValues'], value: undefined },
                 { name: ['actions', name, 'device', 'message', 'functionId'], value: undefined },
               ]);
+              props.onProductIdChange(value);
             }}
             fieldNames={{ label: 'name', value: 'id' }}
             filterOption={(input: string, option: any) =>

+ 1 - 1
src/pages/rule-engine/Scene/Save/index.tsx

@@ -367,7 +367,7 @@ export default () => {
                                 move(name, name + 1);
                               }
                             }}
-                            actionItemData={actionDataCount && actionsData[name]}
+                            actionItemData={actionsData[name]}
                             isLast={!actionDataCount || actionDataCount - 1 === name}
                             parallel={parallel}
                           />

+ 3 - 3
src/pages/system/Department/Assets/deivce/bind.tsx

@@ -138,9 +138,9 @@ const Bind = observer((props: Props) => {
     ];
     if (Object.keys(params).length) {
       _params.push({
-        column: 'parentId$product-info',
-        termType: 'eq',
-        value: 'accessId is ' + params.productId[0],
+        type: 'and',
+        column: 'productId$product-info',
+        value: 'id is ' + params.productId[0],
       });
     }
     return _params;

+ 1 - 0
src/pages/system/Platforms/Api/leftTree.tsx

@@ -90,6 +90,7 @@ export default (props: LeftTreeType) => {
           from(service.getApiNextLevel(item.name)).pipe(
             map((resp: any) => {
               if (resp && resp.components) {
+                ApiModel.components = { ...ApiModel.components, ...resp.components.schemas };
                 return handleTreeData(resp);
               }
               return undefined;

+ 1 - 1
src/pages/system/Platforms/Api/swagger-ui/base.tsx

@@ -77,7 +77,7 @@ export default observer(() => {
         const entityName = refUrl.split('/').pop();
         const entityType = ObjectFindValue('type', ApiModel.swagger.requestBody.content);
         const entityRequired = ApiModel.swagger.requestBody.required;
-        console.log(entityName);
+        console.log(entityName, ApiModel.components);
         const entity: any = ApiModel.components[entityName];
         const file = ObjectFindValue('file', ApiModel.swagger.requestBody.content);
         // 是否为文件上传