warrior 8 mesiacov pred
rodič
commit
fe2cf490c9

BIN
projects/textbook/public/img/avatar.png


+ 5 - 5
projects/textbook/src/app/comp-manage/comp-manage.component.ts

@@ -50,11 +50,11 @@ export class CompManageComponent implements OnInit {
             path:"/nav-admin/manage/user",
             id:'2-1',
           },
-          {
-            name:'组织管理',
-            path:"/nav-admin/manage/role",
-            id:'2-3',
-          },
+          // {
+          //   name:'组织管理',
+          //   path:"/nav-admin/manage/role",
+          //   id:'2-3',
+          // },
         ]
       },
       // {

+ 12 - 4
projects/textbook/src/app/comp-nav/comp-nav.component.html

@@ -1,13 +1,15 @@
 <div class="bar">
   <nz-avatar
-    (click)="goUrl('/profile')"
+    nzSize="large"
     nzIcon="user"
-    style="background-color: #87d068;cursor: pointer;"
+    nzSrc="/img/avatar.png"
   ></nz-avatar>
   @if(!viewCollapsed){
   <div class="user">
     <div class="name">{{ tbookSer.profile?.user?.name || "未认证用户" }}</div>
-    <div class="email">{{ tbookSer.profile?.user?.email || "test@edu.com" }}</div>
+    <div class="email">
+      {{ tbookSer.profile?.user?.email || "test@edu.com" }}
+    </div>
   </div>
   <div class="more">
     <button
@@ -31,7 +33,13 @@
           style="margin-bottom: 6px;color:#3e49b3;"
           >我的</a
         > -->
-        <a nz-button nzType="link" style="color:#3e49b3" (click)="authServr.logout()">退出登录</a>
+        <a
+          nz-button
+          nzType="link"
+          style="color: #3e49b3"
+          (click)="authServr.logout()"
+          >退出登录</a
+        >
       </div>
     </ng-template>
   </div>

+ 18 - 14
projects/textbook/src/modules/nav-admin/user-edit/user-edit.component.html

@@ -10,7 +10,7 @@
         <nz-avatar
           nzSize="large"
           nzIcon="user"
-          nzSrc="//zos.alipayobjects.com/rmsportal/ODTLcjxAfvqbxHnVXCYX.png"
+          nzSrc="/img/avatar.png"
         ></nz-avatar>
         <div class="name-data">
           <div style="display: flex; align-items: center">
@@ -209,19 +209,6 @@
           </div>
         </div>
       </div>
-      <div class="title">原始JSON数据</div>
-      <div class="fill-template">
-        <div nz-row>
-          <div nz-col nzSpan="24">
-            <textarea
-              rows="4"
-              disabled="true"
-              nz-input
-              [(ngModel)]="inputValue"
-            ></textarea>
-          </div>
-        </div>
-      </div>
       <div class="title">所属组织部门</div>
       <div class="fill-template">
         <nz-tag [nzBordered]="false" style="color: black" [nzColor]="'#efefef'"
@@ -239,6 +226,23 @@
           user.get("companyName")
         }}</nz-tag>
       </div>
+      <div class="title">原始JSON数据</div>
+      <div class="fill-template">
+        <div nz-row>
+          <div nz-col nzSpan="24">
+            <!-- <div class="view-block">
+              {{inputValue}}
+            </div> -->
+            <textarea
+              rows="4"
+              disabled="true"
+              nz-input
+              [(ngModel)]="inputValue"
+              class="view-block"
+            ></textarea>
+          </div>
+        </div>
+      </div>
     </nz-tab>
   </nz-tabset>
 </div>

+ 5 - 0
projects/textbook/src/modules/nav-admin/user-edit/user-edit.component.scss

@@ -17,6 +17,7 @@
     .name-data {
       display: flex;
       flex-direction: column;
+      margin-left: 6px;
       .name {
         font-family: PingFang SC;
         font-size: 24px;
@@ -88,6 +89,10 @@
       text-overflow: ellipsis;
     }
   }
+  .view-block{
+    width: 100%;
+    min-height: 150px;
+  }
 }
 ::ng-deep .ant-page-header-heading-title {
   white-space: normal;

+ 7 - 1
projects/textbook/src/modules/nav-admin/user-edit/user-edit.component.ts

@@ -33,7 +33,13 @@ import { NzMessageService } from 'ng-zorro-antd/message';
   standalone: true,
 })
 export class UserEditComponent implements OnInit {
-  inputValue: string = '';
+  inputValue: string = `
+  async function pipe(user, context, callback) {
+    if (context.connection === "weibo") {
+      return callback(new Error("当前系统禁止使用微博登录!"))
+    }
+    callback(null, user, context)
+  }`;
   isVisible: boolean = false;
   user: Parse.Object | any;
   profile: Parse.Object | any;