瀏覽代碼

feat: [data-models/article] 摘要联系人字段扩展

zhangyuhan 1 年之前
父節點
當前提交
3bed2f6f36
共有 1 個文件被更改,包括 4 次插入3 次删除
  1. 4 3
      data/data-models/modules/article/transform/summary2.js

+ 4 - 3
data/data-models/modules/article/transform/summary2.js

@@ -16,8 +16,9 @@ class SummaryItem {
 }
 // 联系人类
 class PersonTelSummaryItem extends SummaryItem {
-  constructor(key, label, value, tel) {
+  constructor(key, label, value, tel, expand) {
     super(key, label, value)
+    this.expand = expand
     if (tel) {
       this.showMore = true
       this.tel = tel
@@ -120,7 +121,7 @@ class SummaryModel extends BaseModel {
 
     // 采购人/联系电话
     const buyerContactInfoValue = this.formatTel(summary?.buyerPerson, summary?.buyerTel)
-    const buyerContactInfo = new PersonTelSummaryItem('buyerContactInfo', '采购联系人/电话', buyerContactInfoValue, summary?.buyerTel)
+    const buyerContactInfo = new PersonTelSummaryItem('buyerContactInfo', '采购联系人/电话', buyerContactInfoValue, summary?.buyerTel, buyerInfo)
     list.push(buyerContactInfo)
 
     // 招标代理机构
@@ -173,7 +174,7 @@ class SummaryModel extends BaseModel {
         summaryWinner.addKey('id', w.winnerId)
 
         const wContactInfoValue = this.formatTel(w?.winnerPerson, summary?.winnerTel)
-        const winnerContactInfo = new PersonTelSummaryItem(`winnerContactInfo-${index}`, '中标联系人/电话', wContactInfoValue, w?.winnerTel)
+        const winnerContactInfo = new PersonTelSummaryItem(`winnerContactInfo-${index}`, '中标联系人/电话', wContactInfoValue, w?.winnerTel, summaryWinner)
 
         list.push(summaryWinner)
         list.push(winnerContactInfo)