瀏覽代碼

用户自动注册

master
xuqm 1 年之前
父節點
當前提交
325df65950
共有 11 個檔案被更改,包括 43 行新增13 行删除
  1. +10
    -0
      npm/index.d.ts
  2. +1
    -1
      npm/index.js
  3. +1
    -1
      npm/package.json
  4. +10
    -0
      npmSzyx/index.d.ts
  5. +1
    -1
      npmSzyx/index.js
  6. +1
    -1
      npmSzyx/package.json
  7. +1
    -1
      web/package.json
  8. +2
    -2
      web/src/main.js
  9. +10
    -0
      web/src/src/szyx-push-sdk.d.ts
  10. +2
    -2
      web/src/view/Home.vue
  11. +4
    -4
      web/yarn.lock

+ 10
- 0
npm/index.d.ts 查看文件

@@ -72,6 +72,10 @@ export declare interface ISzyxPush {
*/
init(tenantNo: string, osType: OsType, url?: string): Promise<void>;

/**
* 注册IM服务
* @param userId 用户id,从业务服务器获取
*/
register(userId: string): Promise<void>;

/**
@@ -87,5 +91,11 @@ export declare interface ISzyxPush {
*/
unMessage(callId): void;

/**
* 发送文本消息
* @param userId 接收者的id
* @param text 文本内容
* @param describe 描述信息,用户自定义信息
*/
sendTextMsg(userId: string, text: string, describe?: string): Promise<Message>;
}

+ 1
- 1
npm/index.js
文件差異過大導致無法顯示
查看文件


+ 1
- 1
npm/package.json 查看文件

@@ -1,6 +1,6 @@
{
"name": "@szyx/szyx-push-web",
"version": "0.0.23",
"version": "0.0.24",
"description": "数字医信-即时通讯-im-js-sdk",
"main": "index.js",
"scripts": {


+ 10
- 0
npmSzyx/index.d.ts 查看文件

@@ -72,6 +72,10 @@ export declare interface ISzyxPush {
*/
init(tenantNo: string, osType: OsType, url?: string): Promise<void>;

/**
* 注册IM服务
* @param userId 用户id,从业务服务器获取
*/
register(userId: string): Promise<void>;

/**
@@ -87,5 +91,11 @@ export declare interface ISzyxPush {
*/
unMessage(callId): void;

/**
* 发送文本消息
* @param userId 接收者的id
* @param text 文本内容
* @param describe 描述信息,用户自定义信息
*/
sendTextMsg(userId: string, text: string, describe?: string): Promise<Message>;
}

+ 1
- 1
npmSzyx/index.js
文件差異過大導致無法顯示
查看文件


+ 1
- 1
npmSzyx/package.json 查看文件

@@ -1,6 +1,6 @@
{
"name": "@szyx/szyx-push-web",
"version": "0.0.1",
"version": "0.0.2",
"description": "数字医信-即时通讯-im-js-sdk",
"main": "index.js",
"scripts": {


+ 1
- 1
web/package.json 查看文件

@@ -8,7 +8,7 @@
"lint": "vue-cli-service lint"
},
"dependencies": {
"@szyx/szyx-push-web": "^0.0.1",
"@szyx/szyx-push-web": "^0.0.2",
"@typescript-eslint/parser": "^5.57.0",
"axios": "^1.3.4",
"babel-eslint": "^10.1.0",


+ 2
- 2
web/src/main.js 查看文件

@@ -3,7 +3,7 @@ import App from './App.vue'
import router from "@/router"
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import SzyxPush, {OsType} from "@/src/szyx-push-sdk"
// import SzyxPush, {OsType} from "@szyx/szyx-push-web"
// import SzyxPush, {OsType} from "@/src/szyx-push-sdk"
import SzyxPush, {OsType} from "@szyx/szyx-push-web"

createApp(App).use(router).use(ElementPlus).use(SzyxPush, '123456', OsType.web).mount('#app')

+ 10
- 0
web/src/src/szyx-push-sdk.d.ts 查看文件

@@ -72,6 +72,10 @@ export declare interface ISzyxPush {
*/
init(tenantNo: string, osType: OsType, url?: string): Promise<void>;

/**
* 注册IM服务
* @param userId 用户id,从业务服务器获取
*/
register(userId: string): Promise<void>;

/**
@@ -87,5 +91,11 @@ export declare interface ISzyxPush {
*/
unMessage(callId): void;

/**
* 发送文本消息
* @param userId 接收者的id
* @param text 文本内容
* @param describe 描述信息,用户自定义信息
*/
sendTextMsg(userId: string, text: string, describe?: string): Promise<Message>;
}

+ 2
- 2
web/src/view/Home.vue 查看文件

@@ -8,8 +8,8 @@
</template>

<script>
// import {MsgType} from "@szyx/szyx-push-web"
import {MsgType} from "@/src/szyx-push-sdk"
import {MsgType} from "@szyx/szyx-push-web"
// import {MsgType} from "@/src/szyx-push-sdk"

export default {
name: "HelloWorld",


+ 4
- 4
web/yarn.lock 查看文件

@@ -1224,10 +1224,10 @@
resolved "https://registry.npmmirror.com/@soda/get-current-script/-/get-current-script-1.0.2.tgz#a53515db25d8038374381b73af20bb4f2e508d87"
integrity sha512-T7VNNlYVM1SgQ+VsMYhnDkcGmWhQdL0bDyGm5TlQ3GBXnJscEClUUOKduWTmm2zCnvNLC1hc3JpuXjs/nFOc5w==

"@szyx/szyx-push-web@^0.0.1":
version "0.0.1"
resolved "http://nexus.51trust.net/repository/npm-group/@szyx/szyx-push-web/-/szyx-push-web-0.0.1.tgz#3bd183256f2c19de39fc8a4ad068a5fdcb588e45"
integrity sha512-/+l5XMLPRQLJb+ygeFJDYIysCqF9gDr+gKmzu0k+OODi2unBTtaNEhbXevvzOI3DHesTAVYcPvdeQRhyDfC7rA==
"@szyx/szyx-push-web@^0.0.2":
version "0.0.2"
resolved "http://nexus.51trust.net/repository/npm-group/@szyx/szyx-push-web/-/szyx-push-web-0.0.2.tgz#0f4605d1c12e8e9f8dcc2a950d6ff4f6459a58e8"
integrity sha512-y3EofrjbJHEA2D76T+TwQlz311Q3qnNzdel0vlQj/1FtXZ5yBP4CVMI8kYyGEF70t9SSfgd+ZFH5PJZusll22g==
dependencies:
axios "^1.3.4"
fingerprintjs2 "^2.1.4"


Loading…
取消
儲存