1.0.23 • Published 3 years ago

intelligent-recommend-cs v1.0.23

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

intelligent-recommend-cs

智能推荐组件

组件依赖:此组件依赖了系统中的Vue对象以及Vue.prototype上挂载的$request方法

微服务API:VUE_APP_IRSC_API

git 仓库

http://g.lenovo.com.cn/cloudservice/packages/intelligent-recommend

Install

npm install intelligent-recommend-cs --save

Usage

全局注册组件

// 全局注册(注意,要在 $request 之后)

import IntelligentRecommend from 'intelligent-recommend-cs'

Vue.use(IntelligentRecommend)

组件中使用

<IntelligentRecommend
  ref="recommend"
  project-code="CHC"
  project-sn="ZZJ0001"
  soid="PJD201028149637889"
  cust-phone="15811019382"
  :is-lenovo-project="false"
/>

...

// 打开智能推荐弹窗
this.$refs.recommend.openRecommendDialog()

// 手动关闭智能推荐弹窗
this.$refs.recommend.closeRecommendDialog()

props 参数

  1. project-code: 项目 code
  2. project-sn: 设备 sn 码
  3. soid: 工单号
  4. is-lenovo-project: 当前项目是否为联想项目
  5. cust-phone: 工单对应客户电话

对外暴露的方法

  1. 打开智能推荐弹窗: openRecommendDialog
  2. 手动关闭智能推荐弹窗: closeRecommendDialog

Publish

  • 打包

npm run build
  • 调试

使用npm link进行组件联调

  • 创建/解除 intelligent-recommend-cs 的全局链接
    // 进入模块目录
    npm link // 创建链接
    npm unlink // 解除链接
  • 创建/解除项目和模块的链接

    // 进入项目目录
    npm link intelligent-recommend-cs // 创建链接
    npm unlink intelligent-recommend-cs // 解除引用链接
  • npm发布

// 登录时若长时间未响应,可将淘宝镜像先停用
npm login // 账号:jiaxiaopeng 密码:8214!xuan@  Email:1043438486@qq.com  每天登陆一次就行,不需要每次发版登陆

npm publish // 发布到npm
  • 发布完后一定记得push代码

1.0.23

3 years ago

1.0.22

3 years ago

1.0.21

3 years ago

1.0.20

3 years ago

1.0.19

3 years ago

1.0.18

3 years ago

1.0.17

3 years ago

1.0.16

3 years ago

1.0.15

3 years ago

1.0.14

3 years ago

1.0.13

3 years ago

1.0.12

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago