antdp | 导航右上角修改, 修改用户名、头像

导航右上角修改,用户名、头像信息:

// 代码中会兼容本地 service mock 以及部署站点的静态数据
export default {
  // 支持值为 Object 和 Array
  'GET /api/currentUser': (req: Request, res: Response) => {
    if (!getAccess()) {
      res.status(401).send({
        data: {
          isLogin: false,
        },
        errorCode: '401',
        errorMessage: '请先登录!',
        success: true,
      });
      return;
    }
    res.send({
      success: true,
      data: {
        name: 'jeremy j',
        avatar: 'https://img2.baidu.com/it/u=832598850,1446126028&fm=253&fmt=auto&app=138&f=PNG?w=480&h=270',   // 悟空
        userid: '00000001',
        email: 'antdesign@alipay.com',
        signature: '海纳百川,有容乃大',
        title: '交互专家',
        group: '蚂蚁金服-某某某事业群-某某平台部-某某技术部-UED',
        tags: [
          {
            key: '0',
            label: '好',
          },
          {
            key: '1',
            label: '很好',
          },
          {
            key: '2',
            label: '非常好',
          },
          {
            key: '3',
            label: '你真棒',
          },
          {
            key: '4',
            label: '极好的',
          },
          {
            key: '5',
            label: '可以',
          },
        ],
        notifyCount: 12,
        unreadCount: 11,
        country: 'China',
        access: getAccess(),
        geographic: {
          province: {
            label: '浙江省',
            key: '330000',
          },
          city: {
            label: '杭州市',
            key: '330100',
          },
        },
        address: '西湖区工专路 77 号',
        phone: '0752-268888888',
      },
    });
  },

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值