7个文件已添加
9个文件已修改
450 ■■■■ 已修改文件
src/assets/images/about/adress.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/chuanzhen.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/email.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/map-marker.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/phone.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/webpeizhi.png 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/js/config.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/layout/components/footerPage.vue 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/layout/components/login.vue 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/aboutUs/components/map.vue 145 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/aboutUs/index.vue 70 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/bookStore/detail.vue 74 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/bookStore/index.vue 18 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/bookStore/textBookApply.vue 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/home/index.vue 81 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/personalCenter/myApply.vue 43 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/images/about/adress.png
src/assets/images/about/chuanzhen.png
src/assets/images/about/email.png
src/assets/images/about/map-marker.png
src/assets/images/about/phone.png
src/assets/images/about/webpeizhi.png
src/assets/js/config.js
@@ -12,7 +12,7 @@
export const goodsStore = `defaultGoodsStore${appId}` // 默认商品库(书城)
export const publicStore = `defaultPublicStore${appId}` // 默认资源开放仓储
export const publicRepository = `defaultPublicRepository${appId}` // 默认资源开放库
export const textBookResourceUrl = 'https://yxjy.pumcp.com/books/resource/'
export const textBookResourceUrl = 'https://yxjy.pumcp.com/testBookReader/#/home'
export const reg_tel =
  /^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/ // 电话号正则
src/layout/components/footerPage.vue
@@ -40,6 +40,9 @@
        </div>
      </div>
    </div>
    <el-divider
      style="border-color: rgba(255, 255, 255, 0.25); width: 1369px; margin: auto"
    ></el-divider>
    <div class="copyrightBox">
      <span
        >中国协和医科大学出版社有限公司 丨 备案序号:<span class="beian" @click="toLink"
@@ -310,7 +313,7 @@
    height: 80px;
    line-height: 40px;
    font-size: 14px;
    border-top: 1px solid #ccc;
    // border-top: 1px solid #ccc;
    .beian {
      cursor: pointer;
    }
src/layout/components/login.vue
@@ -304,7 +304,12 @@
        })
      }
    }
    router.go(0)
    if (localStorage.getItem('loginBack')) {
      window.location.href = localStorage.getItem('loginBack')
      localStorage.removeItem('loginBack')
    } else {
      router.go(0)
    }
  })
}
src/views/aboutUs/components/map.vue
New file
@@ -0,0 +1,145 @@
<script setup>
import { onMounted, onUnmounted, defineProps, ref } from 'vue'
import AMapLoader from '@amap/amap-jsapi-loader'
import posImg from '@/assets/images/about/adress.png'
const props = defineProps({
  contactUsData: {
    type: Object,
  },
})
let dataStr = props.contactUsData
let map = null
let showDailog = ref(true)
const clearMarker = (e) => {
  showDailog.value = true
}
const close = (e) => {
  showDailog.value = false
}
onMounted(() => {
  AMapLoader.load({
    key: '328ca554937f0d1c9f79ea3621136eed', // 申请好的Web端开发者Key,首次调用 load 时必填
    version: '2.0', // 指定要加载的 JSAPI 的版本,缺省时默认为 1.4.15
    plugins: ['AMap.Scale'], // 需要使用的的插件列表,如比例尺'AMap.Scale'等
  })
    .then((AMap) => {
      map = new AMap.Map('container', {
        // 设置地图容器id
        viewMode: '3D', // 是否为3D地图模式
        zoom: 15.5, // 初始化地图级别
        center: [116.413823, 39.912052], // 初始化地图中心点位置
      })
      const position = new AMap.LngLat(116.413823, 39.912052) //Marker 经纬度
      const markerContent = `<div class="custom-content-marker" onclick="clearMarker()"><img style="width:40px" src="${posImg}"></div>`
      const marker = new AMap.Marker({
        position: position,
        content: markerContent, //将 html 传给 content
        offset: new AMap.Pixel(-13, -30), //以 icon 的 [center bottom] 为原点
      })
      map.add(marker)
      document.querySelector('.custom-content-marker').onclick = clearMarker
    })
    .catch((e) => {
      console.log(e)
    })
})
onUnmounted(() => {
  map?.destroy()
})
</script>
<template>
  <div id="container">
    <div class="content" id="con" v-show="showDailog">
      <div class="title">
        <span class="text">联系我们</span>
        <el-icon class="icon" @click="close"><Close /></el-icon>
      </div>
      <div class="tips">
        <img src="@/assets/images/about/map-marker.png" alt="" />
        <span>地址:{{ dataStr?.address ?? '-' }}</span>
      </div>
      <div class="tips">
        <img src="@/assets/images/about/email.png" alt="" />
        <span>邮编:{{ dataStr?.postalCode ?? '-' }}</span>
      </div>
      <div class="tips">
        <img src="@/assets/images/about/phone.png" alt="" />
        <span>总机:{{ dataStr?.telphone ?? '-' }}</span>
      </div>
      <div class="tips">
        <img src="@/assets/images/about/chuanzhen.png" alt="" />
        <span>邮箱:{{ dataStr?.mailbox ?? '-' }}</span>
      </div>
      <div class="tips">
        <img src="@/assets/images/about/webpeizhi.png" alt="" />
        <span>网站:{{ dataStr?.website ?? '-' }}</span>
      </div>
    </div>
  </div>
</template>
<style lang="less" scoped>
#container {
  width: 100%;
  height: 557px;
  position: relative;
  .content {
    width: 260px;
    height: 230px;
    background: #525252;
    border-radius: 10px 10px 10px 10px;
    position: absolute;
    z-index: 99;
    top: 35%;
    left: 55%;
    color: #fff;
    padding: 20px;
    font-family: Microsoft YaHei UI;
    .title {
      width: 100%;
      display: flex;
      justify-content: space-between;
      align-items: center;
      margin-bottom: 20px;
      .text {
        font-weight: 600;
        font-size: 20px;
        color: #ffffff;
      }
      .icon {
        font-size: 18px;
        cursor: pointer;
      }
    }
    .tips {
      font-size: 14px;
      line-height: 18px;
      margin-bottom: 10px;
      display: flex;
      justify-content: flex-start;
      align-items: flex-start;
      span{
        line-height: 24px;
      }
      img {
        width: 20px;
        margin-right: 8px;
      }
    }
  }
}
</style>
src/views/aboutUs/index.vue
@@ -31,7 +31,9 @@
            <div class="statisticsTitle">专注医学出版</div>
          </div>
          <div class="statisticsItem">
            <div class="statisticsNum">{{ publisherData.topExpertDatabase }}+ 位</div>
            <div class="statisticsNum">
              {{ publisherData.topExpertDatabase }}+ <span class="circleBox">位</span>
            </div>
            <div class="statisticsTitle">顶级专家库</div>
          </div>
          <div class="statisticsItem">
@@ -60,7 +62,9 @@
        <div class="CultureBox">
          <div class="brandCultureTitle">
            <div>理念与品牌文化</div>
            <div class="enText">PHILOSOPHY & BRAND CULTURE</div>
            <div class="enText" style="color: #348c6e; font-size: 48px">
              PHILOSOPHY & BRAND CULTURE
            </div>
          </div>
          <div class="cultureList" v-loading="loading">
            <div class="cultureItem firstItem">
@@ -128,7 +132,7 @@
      </div>
    </div>
    <div class="page-container">
      <MapContainer />
      <Map v-if="contactUsData" :contactUsData="contactUsData" />
    </div>
  </div>
</template>
@@ -137,6 +141,7 @@
import moment from 'moment'
import MapContainer from '@/components/MapContainer.vue'
import { ref, onBeforeMount, inject, reactive, onMounted } from 'vue'
import Map from './components/map.vue'
let screenheight = ref(document.documentElement.clientHeight / 2)
const MG = inject('MG')
const config = inject('config')
@@ -146,6 +151,7 @@
let publisherData = ref('')
let ideaBrandCulture = ref([])
let loading = ref(false)
let contactUsData = ref(null)
const getBanner = () => {
  MG.resource
@@ -204,11 +210,44 @@
    })
}
// 获取联系我们
const getConectText = () => {
  MG.resource
    .getItem({
      path: 'aboutUs\\contactUs',
      fields: {
        postalCode: [],
        address: [],
        telphone: [],
        faxNumber: [],
        website: [],
        mailbox: [],
      },
      sort: {
        LinkOrder: 'Asc',
      },
      paging: {
        start: 0,
        size: 999,
      },
      coverSize: {
        height: 430,
      },
    })
    .then((res) => {
      const { datas } = res
      if (datas?.length > 0) {
        contactUsData.value = datas[0]
      }
    })
}
onMounted(() => {
  getBanner()
  getPublisherIntroduction()
  getPublisherData()
  getIdeaBrandCulture()
  getConectText()
})
</script>
@@ -230,7 +269,7 @@
  .enText {
    font-size: 28px;
    opacity: 0.45;
    margin-top: 20px;
    margin-top: 10px;
  }
}
.homePage {
@@ -312,6 +351,7 @@
    }
    .statisticsTitle {
      margin-top: 10px;
      font-size: 14px;
    }
    .circleBox {
      width: 26px;
@@ -327,38 +367,43 @@
}
.brandCultureTop {
  background-image: url(@/assets/images/xiehe/about/wenhua_bg.png);
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: center;
  width: 100%;
  height: 500px;
  padding-top: 55px;
  height: 580px;
  padding-top: 30px;
}
.brandCultureTitle {
  font-size: 36px;
  color: #fff;
  font-weight: 700;
  text-align: center;
  line-height: 70px;
}
.cultureList {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: 60px;
  margin-top: 50px;
}
.cultureItem {
  width: 320px;
  width: 324px;
  height: 320px;
  background-color: #fff;
  margin-left: 30px;
  margin-left: 10px;
  padding: 20px;
  box-sizing: border-box;
}
.firstItem {
  background-color: #144941;
  color: #fff;
  width: 320px;
  width: 324px;
  height: 320px;
  text-align: center;
  text-align: left;
  margin-left: 0px;
}
.CultureBox {
@@ -376,7 +421,7 @@
  padding-bottom: 16px;
}
.titleTextInfo {
  margin-left: 20px;
  margin-left: 10px;
  text-align: left;
}
.itemTitle {
@@ -387,6 +432,7 @@
}
.itemSubTitle {
  color: #000;
  font-size: 12px;
  opacity: 0.5;
}
.itemText {
src/views/bookStore/detail.vue
@@ -168,10 +168,29 @@
              <el-button v-if="currentRoute == 'teachingServices'" plain @click="addPaperBook"
                >纸质样书</el-button
              >
              <el-button plain @click="applyTextBook" v-if="!bookInfo.alreadyBuy"
              <el-button
                size="large"
                type="primary"
                @click="useCode"
                v-if="!bookInfo.alreadyBuy && currentBook?.state !== 'Normal'"
                >使用购书码</el-button
              >
              <el-button
                style="background-color: #144941; color: #fff"
                @click="applyTextBook"
                size="large"
                type="primary"
                v-if="!bookInfo.alreadyBuy && currentBook?.state !== 'Normal'"
                >申请试用</el-button
              >
              <el-button plain @click="useCode" v-if="!bookInfo.alreadyBuy">使用购书码</el-button>
              <el-button
                plain
                size="large"
                @click="read"
                v-if="bookInfo.alreadyBuy || currentBook?.state == 'Normal'"
                >开始阅读</el-button
              >
            </div>
          </div>
        </div>
@@ -296,8 +315,7 @@
import VRIcon from '@/assets/images/digitalTextbooks/VR.png'
import ziliaoIcon from '@/assets/images/digitalTextbooks/ziliao.png'
import teacherCertification from '@/views/personalCenter/teacherCertification.vue'
import { ElMessage } from 'element-plus'
import { ElMessage, ElMessageBox } from 'element-plus'
import { ref, onBeforeMount, inject, reactive, onMounted, watchEffect } from 'vue'
const MG = inject('MG')
const config = inject('config')
@@ -317,6 +335,7 @@
let editableTabsValue = ref('1')
let activateCode = ref('')
let resourceHave = ref(true)
let currentBook = ref(null)
let loading = ref(false)
let buyBookCodeDialog = ref(false)
var chartDom = null
@@ -354,6 +373,7 @@
  digitalTextId.value = route.query.bookId
  getBookDetail(digitalTextId.value)
  getRecommendBookList()
  getTextBookList()
})
watchEffect(() => {
@@ -361,6 +381,34 @@
    getBookResource()
  }
})
const getTextBookList = async () => {
  const data = {
    start: 0,
    size: 9999,
    topicIdOrRefCode: 'applyDigitalBook',
    appRefCode: config.appRefCode,
    sort: {
      type: 'Desc',
      field: 'CreateDate',
    },
  }
  const res = await MG.ugc.getTopicMessageList(data)
  if (res.datas && res.datas.length > 0) {
    for (let i = 0; i < res.datas.length; i++) {
      const item = res.datas[i]
      item.content = JSON.parse(item.content)[0]
      item.productId = item.content.id
    }
    currentBook.value = res.datas.find((item) => item.productId == digitalTextId.value)
  }
}
const read = () => {
  let token = localStorage.getItem(config.tokenKey)
  const url = config.textBookResourceUrl + '?bookId=' + bookInfo.value.refCode + '&token=' + token
  window.open(url)
}
const userActiveCodeGet = () => {
  let lock = true
@@ -462,9 +510,23 @@
}
//申请试用
const applyTextBook = () => {
  console.log(userStore.userInfo, 'userInfo')
const applyTextBook = async () => {
  if (currentBook.value?.state == 'WaitAudit') {
    ElMessageBox.confirm('您已申请试用该书,是否前往查看', '提示', {
      confirmButtonText: '确定',
      cancelButtonText: '取消',
      type: 'warning',
    }).then(() => {
      router.push({
        path: '/myApply',
      })
    })
  } else {
    toApply()
  }
}
const toApply = () => {
  if (localStorage.getItem(config.tokenKey)) {
    if (userStore.userInfo && userStore.userInfo.role == 'Teacher') {
      localStorage.setItem('applyBookInfo', JSON.stringify(bookInfo.value))
src/views/bookStore/index.vue
@@ -33,7 +33,7 @@
            <div style="width: 340px">
              <el-input
                v-model="input3"
                placeholder="输入教材名称、作者姓名、出品方名称搜索"
                placeholder="输入书名、作者、书号搜索"
                class="input-with-select"
              >
                <template #append>
@@ -56,9 +56,7 @@
                </div>
                <div class="infoBox">
                  <div class="bookName">{{ item.name }}</div>
                  <div class="author">
                    作者:{{ item.authorcaupress_author ? item.caupress_author : '-' }}
                  </div>
                  <div class="author">作者:{{ item.author ? item.author : '-' }}</div>
                  <div class="priceBox">
                    <span class="oldPrice" v-if="item.oldPrice">原价:¥{{ item.oldPrice }}</span>
                    <span class="price" v-if="item.price && item.price > 0">
@@ -100,9 +98,7 @@
              </div>
              <div class="infoBox">
                <div class="bookName">{{ item.name }}</div>
                <div class="author">
                  作者:{{ item.authorcaupress_author ? item.caupress_author : '-' }}
                </div>
                <div class="author">作者:{{ item.author ? item.author : '-' }}</div>
                <div class="priceBox">
                  <span class="oldPrice" v-if="item.oldPrice">原价:¥{{ item.oldPrice }}</span>
                  <span class="price" v-if="item.price && item.price > 0">
@@ -197,13 +193,17 @@
      start: (currentPage1.value - 1) * 20,
      size: 20,
    },
    fields: {},
    fields: {
      author: [],
    },
  }
  if (currentLevel.value !== 'all') {
    query.fields['teachingLevel='] = currentLevel.value
  }
  if (input3.value) {
    query.fields['Name*'] = input3.value
    query.fields['||Name*'] = input3.value
    query.fields['||author*'] = input3.value
    query.fields['||isbn*'] = input3.value
  }
  MG.store.getProductList(query).then((res) => {
    console.log(res, '11111111111')
src/views/bookStore/textBookApply.vue
@@ -118,9 +118,10 @@
        id: textBookInfo.value.id,
        title: textBookInfo.value.name,
        icon: textBookInfo.value.icon,
        isbn: textBookInfo.value.tourism_ISBN,
        author: textBookInfo.value.tourism_author,
        isbn: textBookInfo.value.isbn,
        author: textBookInfo.value.author,
        price: textBookInfo.value.price,
        refCode: textBookInfo.value.refCode,
      }
      const data = {
        topicIdOrRefCode: 'applyDigitalBook',
src/views/home/index.vue
@@ -1,12 +1,8 @@
<template>
  <div class="homePage">
    <el-carousel :height="screenheight + 'px'">
      <el-carousel-item v-for="(item, index) in banner" :key="index">
        <div class="bannerBox imgBox">
          <img id="autoHeight" class="bannerImg" :src="item.icon" @click="bannerLink(item)" />
        </div>
      </el-carousel-item>
    </el-carousel>
    <div class="bannerBox imgBox">
      <img class="bannerImg" :src="banner[0]?.icon" @click="bannerLink(item)" />
    </div>
    <div v-if="informationList.length > 0" class="contentBox" style="margin-top: 50px">
      <div class="informationBox">
        <div class="bookListTitle">
@@ -43,9 +39,7 @@
            </div>
            <div class="infoBox">
              <div class="bookName">{{ item.name }}</div>
              <div class="author">
                作者:{{ item.authorcaupress_author ? item.caupress_author : '-' }}
              </div>
              <div class="author">作者:{{ item.author ? item.author : '-' }}</div>
              <div class="priceBox">
                <span class="price" v-if="item.price && item.price > 0">
                  <span> ¥{{ item.price }}</span>
@@ -88,7 +82,9 @@
              />
            </el-tabs>
          </div>
          <div class="more" style="margin-left: 20px" @click="toMore">更多></div>
          <div class="more" style="margin-left: 30px; font-weight: normal" @click="toMore">
            更多>
          </div>
        </div>
      </div>
      <div class="recommendList">
@@ -103,9 +99,7 @@
          </div>
          <div class="infoBox">
            <div class="bookName">{{ item.name }}</div>
            <div class="author">
              作者:{{ item.authorcaupress_author ? item.caupress_author : '-' }}
            </div>
            <div class="author">作者:{{ item.author ? item.author : '-' }}</div>
            <div class="priceBox">
              <span class="price" v-if="item.price && item.price > 0">
                <span>¥{{ item.price }}</span>
@@ -155,7 +149,27 @@
  }
})
// 获取url参数
const getUrlParams = () => {
  let url = window.location.href
  let params = url.split('?')[1]
  let paramsObj = {}
  if (params) {
    paramsObj = params.split('&').reduce((pre, cur) => {
      pre[cur.split('=')[0]] = cur.split('=')[1]
      return pre
    }, {})
  }
  return paramsObj
}
onMounted(() => {
  // 监听是否来自数字阅读
  const params = getUrlParams()
  if (params.login) {
    localStorage.setItem('loginBack', decodeURIComponent(params.callBackUrl))
    logIn()
  }
  getBanner()
  classifList()
  getInformationList()
@@ -227,6 +241,7 @@
      },
      fields: {
        'teachingLevel=': activeName.value,
        author: [],
      },
    })
    .then((res) => {
@@ -340,6 +355,27 @@
  min-height: calc(100vh - 61.8%);
  background-color: #fff;
  padding-bottom: 100px;
  .bannerBox {
    height: 615px;
    position: relative;
    .bannerText {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      font-size: 36px;
      font-weight: 700;
      color: #fff;
      text-shadow: 0px 0px 10px #000000;
      text-align: center;
    }
    .enText {
      font-size: 28px;
      opacity: 0.45;
      margin-top: 10px;
    }
  }
}
.el-carousel__item h3 {
  color: #475669;
@@ -411,7 +447,6 @@
.bookListBox {
  width: 100%;
  padding: 80px 0;
  margin-top: 30px;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  background-image: url('@/assets/images/tuijian-bg.png');
@@ -484,18 +519,18 @@
  margin-top: 60px;
  margin-bottom: 60px;
  .authentication {
    width: 40%;
    height: 100px;
    width: 48%;
    height: 123px;
    background-repeat: no-repeat;
    background-size: 100% 100%;
    background-image: url('@/assets/images/xiehe/home/jiaoshirenzheng.png');
  }
  .manual {
    width: 40%;
    height: 100px;
    width: 48%;
    height: 123px;
    background-repeat: no-repeat;
    background-size: 100% 100%;
    background-image: url('@/assets/images/xiehe/home/jiaoshirenzheng.png');
    background-image: url('@/assets/images/xiehe/home/caozuoshouce.png');
  }
}
@@ -535,13 +570,15 @@
    font-size: 14px;
    color: #ccc;
    margin-top: 10px;
    line-height: 20px;
  }
}
::v-deep(.el-tabs__item) {
  align-items: stretch;
  height: 50px !important;
  height: 60px !important;
  line-height: 20px;
  text-align: center;
  white-space: pre-wrap !important;
  width: 40% !important;
}
</style>
src/views/personalCenter/myApply.vue
@@ -108,7 +108,6 @@
import { reactive, ref, onMounted, inject } from 'vue'
import { getPublicImage } from '@/assets/js/middleGround/tool'
import { useRouter } from 'vue-router'
import tool from '@/assets/js/toolClass'
import defaultImg from '@/assets/images/default-book-img.png'
const MG: any = inject('MG')
const config: any = inject('config')
@@ -193,17 +192,39 @@
    },
  })
}
const read = (pItem: any) => {
  /** 暂无教材阅读器,跳转至详情 */
  // let token = localStorage.getItem(config.tokenKey)
  // const url = config.textBookResourceUrl + '#/home' + '?bookId=' + pItem.id + '&token=' + token
  // window.open(url)
  router.push({
    path: '/bookdetail',
    query: {
      bookId: pItem.id,
// 获取教材详情
const getBookDetail = async (id: string) => {
  const query = {
    path: '*',
    queryType: '*',
    productId: id,
    coverSize: {
      height: 300,
      width: 210,
    },
  })
    fields: {
      author: [],
      isbn: [],
    },
  }
  const res = await MG.store.getProductDetail(query)
  return res.datas ?? null
}
const read = async (pItem: any) => {
  /** 暂无教材阅读器,跳转至详情 */
  const detail = await getBookDetail(pItem.id)
  let token = localStorage.getItem(config.tokenKey)
  const url =
    config.textBookResourceUrl + '#/home' + '?bookId=' + detail.refCode + '&token=' + token
  window.open(url)
  // router.push({
  //   path: '/bookdetail',
  //   query: {
  //     bookId: pItem.id,
  //   },
  // })
}
const handleSizeChange = (val: number) => {
  paginationData.limit = val