diff --git a/components/u-parse/components/wxParseAudio.vue b/components/u-parse/components/wxParseAudio.vue
new file mode 100644
index 0000000..86df246
--- /dev/null
+++ b/components/u-parse/components/wxParseAudio.vue
@@ -0,0 +1,27 @@
+
+
+
+
+
+
diff --git a/components/u-parse/components/wxParseImg.vue b/components/u-parse/components/wxParseImg.vue
new file mode 100644
index 0000000..00747e4
--- /dev/null
+++ b/components/u-parse/components/wxParseImg.vue
@@ -0,0 +1,86 @@
+
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate0.vue b/components/u-parse/components/wxParseTemplate0.vue
new file mode 100644
index 0000000..0c76e74
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate0.vue
@@ -0,0 +1,107 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate1.vue b/components/u-parse/components/wxParseTemplate1.vue
new file mode 100644
index 0000000..a864f23
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate1.vue
@@ -0,0 +1,99 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate10.vue b/components/u-parse/components/wxParseTemplate10.vue
new file mode 100644
index 0000000..9a8d8b6
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate10.vue
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate11.vue b/components/u-parse/components/wxParseTemplate11.vue
new file mode 100644
index 0000000..1402d11
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate11.vue
@@ -0,0 +1,87 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
+
+ \n
+
+
+
+
+
+ {{node.text}}
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate2.vue b/components/u-parse/components/wxParseTemplate2.vue
new file mode 100644
index 0000000..d6d027d
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate2.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate3.vue b/components/u-parse/components/wxParseTemplate3.vue
new file mode 100644
index 0000000..f899edd
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate3.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate4.vue b/components/u-parse/components/wxParseTemplate4.vue
new file mode 100644
index 0000000..9bd558c
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate4.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate5.vue b/components/u-parse/components/wxParseTemplate5.vue
new file mode 100644
index 0000000..4f6cc27
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate5.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate6.vue b/components/u-parse/components/wxParseTemplate6.vue
new file mode 100644
index 0000000..4781c64
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate6.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate7.vue b/components/u-parse/components/wxParseTemplate7.vue
new file mode 100644
index 0000000..1efc4dc
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate7.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate8.vue b/components/u-parse/components/wxParseTemplate8.vue
new file mode 100644
index 0000000..2ac546f
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate8.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseTemplate9.vue b/components/u-parse/components/wxParseTemplate9.vue
new file mode 100644
index 0000000..c771e5f
--- /dev/null
+++ b/components/u-parse/components/wxParseTemplate9.vue
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ \n
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{node.text}}
+
+
+
+
diff --git a/components/u-parse/components/wxParseVideo.vue b/components/u-parse/components/wxParseVideo.vue
new file mode 100644
index 0000000..a952f58
--- /dev/null
+++ b/components/u-parse/components/wxParseVideo.vue
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
diff --git a/components/u-parse/libs/html2json.js b/components/u-parse/libs/html2json.js
new file mode 100644
index 0000000..0927382
--- /dev/null
+++ b/components/u-parse/libs/html2json.js
@@ -0,0 +1,261 @@
+/**
+ * html2Json 改造来自: https://github.com/Jxck/html2json
+ *
+ *
+ * author: Di (微信小程序开发工程师)
+ * organization: WeAppDev(微信小程序开发论坛)(http://weappdev.com)
+ * 垂直微信小程序开发交流社区
+ *
+ * github地址: https://github.com/icindy/wxParse
+ *
+ * for: 微信小程序富文本解析
+ * detail : http://weappdev.com/t/wxparse-alpha0-1-html-markdown/184
+ */
+
+import wxDiscode from './wxDiscode';
+import HTMLParser from './htmlparser';
+
+function makeMap(str) {
+ const obj = {};
+ const items = str.split(',');
+ for (let i = 0; i < items.length; i += 1) obj[items[i]] = true;
+ return obj;
+}
+
+// Block Elements - HTML 5
+const block = makeMap('br,code,address,article,applet,aside,audio,blockquote,button,canvas,center,dd,del,dir,div,dl,dt,fieldset,figcaption,figure,footer,form,frameset,h1,h2,h3,h4,h5,h6,header,hgroup,hr,iframe,ins,isindex,li,map,menu,noframes,noscript,object,ol,output,p,pre,section,script,table,tbody,td,tfoot,th,thead,tr,ul,video');
+
+// Inline Elements - HTML 5
+const inline = makeMap('a,abbr,acronym,applet,b,basefont,bdo,big,button,cite,del,dfn,em,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,select,small,span,strike,strong,sub,sup,textarea,tt,u,var');
+
+// Elements that you can, intentionally, leave open
+// (and which close themselves)
+const closeSelf = makeMap('colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr');
+
+function removeDOCTYPE(html) {
+ const isDocument = /
([^]*)<\/body>/.test(html);
+ return isDocument ? RegExp.$1 : html;
+}
+
+function trimHtml(html) {
+ return html
+ .replace(//gi, '')
+ .replace(/\/\*.*?\*\//gi, '')
+ .replace(/[ ]+/gi, '')
+ .replace(/
+```
+
+
+## 渲染 Markdown
+
+> 先将 markdown 转换为 html 即可
+
+```
+npm install marked
+```
+
+``` js
+import marked from 'marked'
+import uParse from '@/components/u-parse/u-parse.vue'
+
+export default {
+ components: {
+ uParse
+ },
+ data () {
+ return {
+ article: marked(`#hello, markdown!`)
+ }
+ }
+}
+```
diff --git a/components/u-parse/u-parse.css b/components/u-parse/u-parse.css
new file mode 100644
index 0000000..691993a
--- /dev/null
+++ b/components/u-parse/u-parse.css
@@ -0,0 +1,232 @@
+/**
+ * author: Di (微信小程序开发工程师)
+ * organization: WeAppDev(微信小程序开发论坛)(http://weappdev.com)
+ * 垂直微信小程序开发交流社区
+ *
+ * github地址: https://github.com/icindy/wxParse
+ *
+ * for: 微信小程序富文本解析
+ * detail : http://weappdev.com/t/wxparse-alpha0-1-html-markdown/184
+ */
+
+.wxParse {
+ width: 100%;
+ font-family: Helvetica, sans-serif;
+ font-size: 30upx;
+ color: #666;
+ line-height: 1.8;
+}
+
+.wxParse view {
+ word-break: hyphenate;
+}
+
+.wxParse .inline {
+ display: inline;
+ margin: 0;
+ padding: 0;
+}
+
+.wxParse .div {
+ margin: 0;
+ padding: 0;
+}
+
+.wxParse .h1 .text {
+ font-size: 2em;
+ margin: 0.67em 0;
+}
+.wxParse .h2 .text {
+ font-size: 1.5em;
+ margin: 0.83em 0;
+}
+.wxParse .h3 .text {
+ font-size: 1.17em;
+ margin: 1em 0;
+}
+.wxParse .h4 .text {
+ margin: 1.33em 0;
+}
+.wxParse .h5 .text {
+ font-size: 0.83em;
+ margin: 1.67em 0;
+}
+.wxParse .h6 .text {
+ font-size: 0.67em;
+ margin: 2.33em 0;
+}
+
+.wxParse .h1 .text,
+.wxParse .h2 .text,
+.wxParse .h3 .text,
+.wxParse .h4 .text,
+.wxParse .h5 .text,
+.wxParse .h6 .text,
+.wxParse .b,
+.wxParse .strong {
+ font-weight: bolder;
+}
+
+
+.wxParse .p {
+ margin: 1em 0;
+}
+
+.wxParse .i,
+.wxParse .cite,
+.wxParse .em,
+.wxParse .var,
+.wxParse .address {
+ font-style: italic;
+}
+
+.wxParse .pre,
+.wxParse .tt,
+.wxParse .code,
+.wxParse .kbd,
+.wxParse .samp {
+ font-family: monospace;
+}
+.wxParse .pre {
+ overflow: auto;
+ background: #f5f5f5;
+ padding: 16upx;
+ white-space: pre;
+ margin: 1em 0upx;
+}
+.wxParse .code {
+ display: inline;
+ background: #f5f5f5;
+}
+
+.wxParse .big {
+ font-size: 1.17em;
+}
+
+.wxParse .small,
+.wxParse .sub,
+.wxParse .sup {
+ font-size: 0.83em;
+}
+
+.wxParse .sub {
+ vertical-align: sub;
+}
+.wxParse .sup {
+ vertical-align: super;
+}
+
+.wxParse .s,
+.wxParse .strike,
+.wxParse .del {
+ text-decoration: line-through;
+}
+
+.wxParse .strong,
+.wxParse .s {
+ display: inline;
+}
+
+.wxParse .a {
+ color: deepskyblue;
+}
+
+.wxParse .video {
+ text-align: center;
+ margin: 22upx 0;
+}
+
+.wxParse .video-video {
+ width: 100%;
+}
+
+.wxParse .img {
+ display: inline-block;
+ width: 0;
+ height: 0;
+ max-width: 100%;
+ overflow: hidden;
+}
+
+.wxParse .blockquote {
+ margin: 10upx 0;
+ padding: 22upx 0 22upx 22upx;
+ font-family: Courier, Calibri, "宋体";
+ background: #f5f5f5;
+ border-left: 6upx solid #dbdbdb;
+}
+.wxParse .blockquote .p {
+ margin: 0;
+}
+
+.wxParse .ul, .wxParse .ol {
+ display: block;
+ margin: 1em 0;
+ padding-left: 33upx;
+}
+.wxParse .ol {
+ list-style-type: disc;
+}
+.wxParse .ol {
+ list-style-type: decimal;
+}
+.wxParse .ol>weixin-parse-template,.wxParse .ul>weixin-parse-template {
+ display: list-item;
+ align-items: baseline;
+ text-align: match-parent;
+}
+
+.wxParse .ol>.li,.wxParse .ul>.li {
+ display: list-item;
+ align-items: baseline;
+ text-align: match-parent;
+}
+.wxParse .ul .ul, .wxParse .ol .ul {
+ list-style-type: circle;
+}
+.wxParse .ol .ol .ul, .wxParse .ol .ul .ul, .wxParse .ul .ol .ul, .wxParse .ul .ul .ul {
+ list-style-type: square;
+}
+
+.wxParse .u {
+ text-decoration: underline;
+}
+.wxParse .hide {
+ display: none;
+}
+.wxParse .del {
+ display: inline;
+}
+.wxParse .figure {
+ overflow: hidden;
+}
+
+.wxParse .table {
+ width: 100%;
+}
+.wxParse .thead, .wxParse .tfoot, .wxParse .tr {
+ display: flex;
+ flex-direction: row;
+}
+.wxParse .tr {
+ width:100%;
+ display: flex;
+ border-right: 2upx solid #e0e0e0;
+ border-bottom: 2upx solid #e0e0e0;
+}
+.wxParse .th,
+.wxParse .td {
+ display: flex;
+ width: 1276upx;
+ overflow: auto;
+ flex: 1;
+ padding: 11upx;
+ border-left: 2upx solid #e0e0e0;
+}
+.wxParse .td:last {
+ border-top: 2upx solid #e0e0e0;
+}
+.wxParse .th {
+ background: #f0f0f0;
+ border-top: 2upx solid #e0e0e0;
+}
diff --git a/components/u-parse/u-parse.vue b/components/u-parse/u-parse.vue
new file mode 100644
index 0000000..494e60c
--- /dev/null
+++ b/components/u-parse/u-parse.vue
@@ -0,0 +1,118 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/hooks/useGuard.js b/hooks/useGuard.js
index 7d0f41b..827d882 100644
--- a/hooks/useGuard.js
+++ b/hooks/useGuard.js
@@ -34,7 +34,9 @@ export default function useGuard() {
async function useLoad(fn) {
await promise;
- fn(options.value);
+ if (typeof fn === 'function') {
+ fn(options.value);
+ }
}
async function triggleShowEvents() {
diff --git a/pages.json b/pages.json
index 9db7834..71172d8 100644
--- a/pages.json
+++ b/pages.json
@@ -301,6 +301,13 @@
"navigationBarTitleText": "添加好友",
"disableScroll": true
}
+ },
+ {
+ "path": "business-card",
+ "style": {
+ "navigationBarTitleText": "个人名片",
+ "disableScroll": true
+ }
}
]
}
diff --git a/pages/login/redirect-page.vue b/pages/login/redirect-page.vue
index 02fe908..cc70517 100644
--- a/pages/login/redirect-page.vue
+++ b/pages/login/redirect-page.vue
@@ -94,7 +94,7 @@ async function changeTeam({ teamId, corpId, corpUserId, externalUserId, qrid, re
qrid,
referenceCustomerId: referenceCustomerId || ''
});
- await login()
+ await login('', { forceVerify: true })
if (account.value && account.value.mobile) {
bindTeam({ corpUserId, externalUserId })
} else {
diff --git a/pages/team/business-card.vue b/pages/team/business-card.vue
new file mode 100644
index 0000000..14a1376
--- /dev/null
+++ b/pages/team/business-card.vue
@@ -0,0 +1,1373 @@
+
+
+
+
+
+
+
+
+
+
+
+ 全周期管理
+
+
+
+
+ 门诊预约
+
+
+
+
+ 联系电话
+
+
+
+
+ 邮箱
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 暂无医院介绍信息
+
+
+
+
+
+
+
+
+
+
+
+ {{ businessCard.memberTroduce }}
+
+ 暂无个人简介
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ businessCard.externalContact }}
+
+
+ 复制
+
+ 拨打
+
+
+
+ 暂无电话信息
+ 📞
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ businessCard.externalEmail }}
+
+ 复制
+
+
+
+ 暂无邮箱信息
+ ✉️
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pages/team/components/BusinessCard.vue b/pages/team/components/BusinessCard.vue
new file mode 100644
index 0000000..3128da0
--- /dev/null
+++ b/pages/team/components/BusinessCard.vue
@@ -0,0 +1,312 @@
+
+
+
+
+
+
+
+
+
+ {{ card.externalContact || '' }}
+
+
+
+ {{ card.externalEmail || '' }}
+
+
+
+
+
+
+
+
+
diff --git a/pages/team/components/teams-popup.vue b/pages/team/components/teams-popup.vue
new file mode 100644
index 0000000..4c37d21
--- /dev/null
+++ b/pages/team/components/teams-popup.vue
@@ -0,0 +1,97 @@
+
+
+
+
+ 全周期管理
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/team/team-detail.vue b/pages/team/team-detail.vue
index 3633342..8f8afab 100644
--- a/pages/team/team-detail.vue
+++ b/pages/team/team-detail.vue
@@ -96,7 +96,6 @@ const teammate = computed(() => {
const friendlyMember = computed(() => {
const friendlyMembers = team.value && Array.isArray(team.value.friendlyMembers) ? team.value.friendlyMembers : [];
- debugger
return friendlyMembers.reduce((data, item) => {
data[item] = true;
return data
@@ -107,8 +106,13 @@ function toFriend(userid) {
uni.navigateTo({ url: `/pages/team/friend?corpId=${corpId.value}&userid=${userid}` })
}
-function toHomePage(userid) {
- uni.navigateTo({ url: `/pages/team/homepage?corpId=${corpId.value}&userid=${userid}&showQrcode=${friendlyMember.value[userid] ? 'YES' : ''}` })
+async function toHomePage(userid) {
+ const res = await api('getCorpBusinessCardStatus', { corpId: corpId.value });
+ if (res && res.data) {
+ uni.navigateTo({ url: `/pages/team/business-card?corpId=${corpId.value}&userid=${userid}` })
+ } else {
+ uni.navigateTo({ url: `/pages/team/homepage?corpId=${corpId.value}&userid=${userid}&showQrcode=${friendlyMember.value[userid] ? 'YES' : ''}` })
+ }
}
async function getTeam() {
diff --git a/routes/index.js b/routes/index.js
index e2b1844..db6426b 100644
--- a/routes/index.js
+++ b/routes/index.js
@@ -84,6 +84,10 @@ export default [
path: 'pages/team/friend',
meta: { title: '添加好友', login: true }
},
+ {
+ path: 'pages/team/business-card',
+ meta: { title: '电子名片', login: true }
+ },
{
path: 'pages/web-view/web-view',
meta: { title: '' }
diff --git a/static/card/avatar.png b/static/card/avatar.png
new file mode 100644
index 0000000..ffe37c8
Binary files /dev/null and b/static/card/avatar.png differ
diff --git a/static/card/card-bg2.png b/static/card/card-bg2.png
new file mode 100644
index 0000000..36ee9b1
Binary files /dev/null and b/static/card/card-bg2.png differ
diff --git a/static/card/edit-card.png b/static/card/edit-card.png
new file mode 100644
index 0000000..ac23552
Binary files /dev/null and b/static/card/edit-card.png differ
diff --git a/static/card/email.png b/static/card/email.png
new file mode 100644
index 0000000..0825e4c
Binary files /dev/null and b/static/card/email.png differ
diff --git a/static/card/email.svg b/static/card/email.svg
new file mode 100644
index 0000000..f7aa7e5
--- /dev/null
+++ b/static/card/email.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/static/card/gwBack.png b/static/card/gwBack.png
new file mode 100644
index 0000000..c99b99a
Binary files /dev/null and b/static/card/gwBack.png differ
diff --git a/static/card/gwIcon.png b/static/card/gwIcon.png
new file mode 100644
index 0000000..56bc48a
Binary files /dev/null and b/static/card/gwIcon.png differ
diff --git a/static/card/gzhBack.png b/static/card/gzhBack.png
new file mode 100644
index 0000000..b6611a1
Binary files /dev/null and b/static/card/gzhBack.png differ
diff --git a/static/card/jzfwBack.png b/static/card/jzfwBack.png
new file mode 100644
index 0000000..5eaadb3
Binary files /dev/null and b/static/card/jzfwBack.png differ
diff --git a/static/card/jzfwIcon.png b/static/card/jzfwIcon.png
new file mode 100644
index 0000000..2aa537e
Binary files /dev/null and b/static/card/jzfwIcon.png differ
diff --git a/static/card/phone.png b/static/card/phone.png
new file mode 100644
index 0000000..e315057
Binary files /dev/null and b/static/card/phone.png differ
diff --git a/static/card/sphBack.png b/static/card/sphBack.png
new file mode 100644
index 0000000..5e1c212
Binary files /dev/null and b/static/card/sphBack.png differ
diff --git a/static/card/telephone.svg b/static/card/telephone.svg
new file mode 100644
index 0000000..915bac0
--- /dev/null
+++ b/static/card/telephone.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/store/account.js b/store/account.js
index 08be0f4..34b5fdf 100644
--- a/store/account.js
+++ b/store/account.js
@@ -24,9 +24,9 @@ export default defineStore("accountStore", () => {
});
const teamsPromise = ref(null);
- async function login(phoneCode = '') {
+ async function login(phoneCode = '', options = {}) {
if (loading.value) return;
- if (account.value && account.value.mobile) {
+ if (account.value && account.value.mobile && !options.forceVerify) {
return account.value
}
loading.value = true;
@@ -54,11 +54,17 @@ export default defineStore("accountStore", () => {
// initIMAfterLogin(openid.value)
return normalizedAccount
+ } else {
+ account.value = null;
+ openid.value = '';
+ uni.removeStorageSync('account');
+ uni.removeStorageSync('openid');
+ return
}
}
- toast('登录失败,请重新登录');
+ if (!options.silent) toast('登录失败,请重新登录');
} catch (e) {
- toast('登录失败,请重新登录');
+ if (!options.silent) toast('登录失败,请重新登录');
}
loading.value = false
}
@@ -154,9 +160,9 @@ export default defineStore("accountStore", () => {
const unionid = account.value?.unionid;
const openid = account.value?.openid;
if (!(normalizedCorpId && unionid && openid)) {
- externalUserId.value = '';
- return
- };
+ externalUserId.value = '';
+ return
+ };
const res = await api('getUnionidToExternalUserid', { unionid, openid, corpId: normalizedCorpId }, false);
const id = res && res.success && typeof res.data === 'string' && res.data.trim() ? res.data.trim() : '';
externalUserId.value = id;
diff --git a/utils/api-base-config.js b/utils/api-base-config.js
index 444ecfd..d0e5706 100644
--- a/utils/api-base-config.js
+++ b/utils/api-base-config.js
@@ -4,6 +4,8 @@ export const API_CONTEXT_CACHE_KEY = "ykt_team_api_context";
export const CORP_API_BASE_URL_MAP = {
wwa54dfba0b5441ef1: "https://crm.gykqyy.com/ykt/",
+ wpLgjyawAAxKtBH5GVT5DVhLefg246Ag: "https://hlwyy.6thhosp.com:4443/",
+
};
export const CORP_ID_ALIAS_MAP = {
diff --git a/utils/api.js b/utils/api.js
index c3a7536..3daa5fa 100644
--- a/utils/api.js
+++ b/utils/api.js
@@ -16,7 +16,11 @@ const urlsConfig = {
getAllCorpMemberIncludeDeleted: "getAllCorpMemberIncludeDeleted",
getMiniAppHomeStats: "getMiniAppHomeStats",
getResponsiblePerson: 'getTeamResponsiblePerson',
- relateWxappTeamByExternalUserId: 'relateWxappTeamByExternalUserId'
+ relateWxappTeamByExternalUserId: 'relateWxappTeamByExternalUserId',
+ getBusinessCard: 'getBusinessCard',
+ recordBusinessCardBehavior: 'recordBusinessCardBehavior',
+ getJoinedTeams: 'getJoinedTeams',
+ getCorpBusinessCardStatus: 'getCorpBusinessCardStatus',
},
knowledgeBase: {