Browse Source

fix: 修改bug

bill 2 years ago
parent
commit
5d3e6ef216
3 changed files with 12 additions and 3 deletions
  1. 7 2
      src/components/upload/index.vue
  2. 4 0
      src/store/project.ts
  3. 1 1
      src/views/project/edit.vue

+ 7 - 2
src/components/upload/index.vue

@@ -94,13 +94,18 @@ const onBeforeUpload: UploadProps['beforeUpload'] = file => {
     word-break: break-all;
   }
   .icon {
+    font-size: 1.2em;
     margin-left: 10px;
-    color: #c8c8c8;
+    color: #ff4d4f;
     cursor: pointer;
     transition: color 0.3s ease;
 
     &:hover {
-      color: inherit;
+      color: #ff7875;
+    }
+
+    &:active {
+      color: #d9363e;
     }
   }
 }

+ 4 - 0
src/store/project.ts

@@ -92,6 +92,10 @@ export const useProject = defineStore('project', {
     async update(data: PartialPart<UpdateProjectData, 'projectId'>) {
       const id = data.projectId || this.current?.projectId
       if (id) {
+        console.log({
+          ...data,
+          projectId: id
+        })
         await updateProject({
           ...data,
           projectId: id

+ 1 - 1
src/views/project/edit.vue

@@ -61,7 +61,7 @@
         <Upload
           v-model:file="project.bimFile"
           :max-size="3 * 1024"
-          :extnames="['dwg', 'dxf', 'dwf', 'ifc']"
+          :extnames="['ifc']"
         />
       </a-form-item>
     </a-form>