4个文件已添加
11个文件已修改
361 ■■■■■ 已修改文件
.env.development 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
.env.tp 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
config/config.ts 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package.json 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/assets/home/icon-taiping-logo.png 补丁 | 查看 | 原始文档 | blame | 历史
src/components/Preview/PreviewOffice.vue 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/constants/temp.ts 53 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/services/api/typings.d.ts 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/storage/storage.ts 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/Home/Home.vue 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/Home/components/InsureInstructionsDialog.vue 153 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/Home/components/InsureOrderInfoView.vue 29 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/InsuranceClaim/components/InsuranceClaimView.vue 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
types/global.d.ts 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
vite.config.ts 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
.env.development
@@ -2,7 +2,7 @@
VITE_PORT = 8698
# 开发环境读取配置文件路径
VITE_PUBLIC_PATH = /
VITE_PUBLIC_PATH = /front/
# 开发环境代理
VITE_PROXY_DOMAIN = /api
.env.tp
New file
@@ -0,0 +1,24 @@
NODE_ENV=production
# 线上环境项目打包路径
VITE_PUBLIC_PATH = /front/
# 线上环境路由历史模式
VITE_ROUTER_HISTORY = "h5"
# 线上环境后端地址
# VITE_PROXY_DOMAIN_REAL = "https://testrlywx.boleyuma.com/"
# VITE_PROXY_DOMAIN_REAL = "https://jygbapi.jx818.com/"
VITE_PROXY_DOMAIN_REAL = "https://ecss.hhbxjj.com/"
# 是否为打包后的文件提供传统浏览器兼容性支持 支持 true 不支持 false
VITE_LEGACY = true
VITE_COMPRESSION = "none"
# OSS上传地址
VITE_OSS_URL = "https://parkmanagement.oss-cn-hangzhou.aliyuncs.com/"
VITE_OSS_URL_BUCKET = "parkmanagement"
VITE_WEMAP_KEY = "DYRBZ-ZGPCF-X3OJN-N2AA3-JWUCE-HEBXJ"
VITE_CLIENT_ORIGIN = "http://118.178.252.28:8740"
config/config.ts
@@ -11,7 +11,8 @@
  loginFormTitle: '乐遇保云服务',
});
type AppType = 'one' | 'rz' | 'jx' | 'jy' | 'other' | 'backup';
//tp:太平
type AppType = 'one' | 'rz' | 'jx' | 'jy' | 'other' | 'backup' | 'tp';
const AppSettingMap = {
  one: {
@@ -44,6 +45,11 @@
    loginFormTitle: '江佑保备用',
    MenuTitle: '江佑保备用',
  },
  tp: {
    title: '江佑共保后台管理系统',
    loginFormTitle: '江佑共保后台管理系统',
    MenuTitle: '江佑共保',
  },
};
export function getAppSetting(appType: AppType) {
package.json
@@ -10,10 +10,11 @@
    "build": "cross-env NODE_OPTIONS=--max_old_space_size=16000 vite build",
    "build:rz": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=rz vite build --mode rz",
    "build:jx": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=jx vite build --mode jx",
    "build:tp": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=tp vite build --mode tp",
    "build:jy": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=jy vite build --mode jy",
    "build:other": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=other vite build --mode other",
    "build:backup": "cross-env NODE_OPTIONS=--max_old_space_size=16000 VITE_AppType=backup vite build --mode backup",
    "build:all": "run-p build:jx build:jy build:other build:backup",
    "build:all": "run-p build:jx build:tp",
    "build:staging": "cross-env vite build --mode staging",
    "build:staging:yx": "cross-env vite build --mode stagingone",
    "build:staging:other": "cross-env VITE_AppType=other vite build --mode staging",
src/assets/home/icon-taiping-logo.png
src/components/Preview/PreviewOffice.vue
New file
@@ -0,0 +1,25 @@
<template>
  <div class="office-wrapper">
    <iframe :src="url" class="previewBody"></iframe>
  </div>
</template>
<script lang="ts">
export default {
  name: 'PreviewOffice',
};
</script>
<script setup lang="ts">
import { computed } from 'vue';
type Props = {
  fileUrl: string;
};
const props = defineProps<Props>();
const url = computed(
  () => `https://view.officeapps.live.com/op/view.aspx?src=${props.fileUrl}?${Date.now()}`
);
</script>
src/constants/temp.ts
@@ -7,3 +7,56 @@
export const InsuranceAddOrReduceTempPath = `${TempFolderPath}/%E5%8A%A0%E5%87%8F%E4%BA%BA%E6%A8%A1%E6%9D%BF.xlsx`;
// 替换人
export const InsuranceChangeTempPath = `${TempFolderPath}/%E6%9B%BF%E6%8D%A2%E4%BA%BA%E6%A8%A1%E6%9D%BF%20.xlsx`;
// 职业类型对照表
export const InsuranceOccupationTypeTempPath = `${TempFolderPath}/%E8%81%8C%E4%B8%9A%E7%B1%BB%E5%9E%8B%E5%AF%B9%E7%85%A7%E8%A1%A8.xls`;
// 产品保障方案
export const InsuranceProtocolTempPath1 = `${TempFolderPath}/%E4%BA%A7%E5%93%81%E4%BF%9D%E9%9A%9C%E6%96%B9%E6%A1%88.pdf`;
// 免责条款
export const InsuranceProtocolTempPath2 = `${TempFolderPath}/%E5%85%8D%E8%B4%A3%E6%9D%A1%E6%AC%BE.pdf`;
// 理赔须知
export const InsuranceProtocolTempPath3 = `${TempFolderPath}/%E7%90%86%E8%B5%94%E9%A1%BB%E7%9F%A5.pdf`;
// 投保须知及声明
export const InsuranceProtocolTempPath4 = `${TempFolderPath}/%E6%8A%95%E4%BF%9D%E9%A1%BB%E7%9F%A5%E5%8F%8A%E5%A3%B0%E6%98%8E.pdf`;
// 太平财产保险有限公司个人人身意外伤害保险(互联网专属2022版)-条款
export const InsuranceProtocolTempPath5 = `${TempFolderPath}/%E5%A4%AA%E5%B9%B3%E8%B4%A2%E4%BA%A7%E4%BF%9D%E9%99%A9%E6%9C%89%E9%99%90%E5%85%AC%E5%8F%B8%E4%B8%AA%E4%BA%BA%E4%BA%BA%E8%BA%AB%E6%84%8F%E5%A4%96%E4%BC%A4%E5%AE%B3%E4%BF%9D%E9%99%A9%EF%BC%88%E4%BA%92%E8%81%94%E7%BD%91%E4%B8%93%E5%B1%9E2022%E7%89%88%EF%BC%89-%E6%9D%A1%E6%AC%BE.pdf`;
// 太平财产保险有限公司公共交通工具乘客意外伤害保险(互联网专属2022版)-条款
export const InsuranceProtocolTempPath6 = `${TempFolderPath}/%E5%A4%AA%E5%B9%B3%E8%B4%A2%E4%BA%A7%E4%BF%9D%E9%99%A9%E6%9C%89%E9%99%90%E5%85%AC%E5%8F%B8%E5%85%AC%E5%85%B1%E4%BA%A4%E9%80%9A%E5%B7%A5%E5%85%B7%E4%B9%98%E5%AE%A2%E6%84%8F%E5%A4%96%E4%BC%A4%E5%AE%B3%E4%BF%9D%E9%99%A9%EF%BC%88%E4%BA%92%E8%81%94%E7%BD%91%E4%B8%93%E5%B1%9E2022%E7%89%88%EF%BC%89-%E6%9D%A1%E6%AC%BE.pdf`;
// 太平财产保险有限公司附加意外伤害住院津贴保险(互联网专属)-条款
export const InsuranceProtocolTempPath7 = `${TempFolderPath}/%E5%A4%AA%E5%B9%B3%E8%B4%A2%E4%BA%A7%E4%BF%9D%E9%99%A9%E6%9C%89%E9%99%90%E5%85%AC%E5%8F%B8%E9%99%84%E5%8A%A0%E6%84%8F%E5%A4%96%E4%BC%A4%E5%AE%B3%E4%BD%8F%E9%99%A2%E6%B4%A5%E8%B4%B4%E4%BF%9D%E9%99%A9%EF%BC%88%E4%BA%92%E8%81%94%E7%BD%91%E4%B8%93%E5%B1%9E%EF%BC%89-%E6%9D%A1%E6%AC%BE.pdf`;
// 太平财产保险有限公司附加意外伤害医疗保险(互联网专属2022版)-条款
export const InsuranceProtocolTempPath8 = `${TempFolderPath}/%E5%A4%AA%E5%B9%B3%E8%B4%A2%E4%BA%A7%E4%BF%9D%E9%99%A9%E6%9C%89%E9%99%90%E5%85%AC%E5%8F%B8%E9%99%84%E5%8A%A0%E6%84%8F%E5%A4%96%E4%BC%A4%E5%AE%B3%E5%8C%BB%E7%96%97%E4%BF%9D%E9%99%A9%EF%BC%88%E4%BA%92%E8%81%94%E7%BD%91%E4%B8%93%E5%B1%9E2022%E7%89%88%EF%BC%89-%E6%9D%A1%E6%AC%BE.pdf`;
export const InsuranceTempList = [
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath1,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath2,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath3,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath4,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath5,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath6,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath7,
  },
  {
    type: 'pdf',
    url: InsuranceProtocolTempPath8,
  },
];
src/services/api/typings.d.ts
@@ -959,6 +959,10 @@
    certType?: string;
    certNo?: string;
    jobName?: string;
    /** 职业类型 */
    occupationType?: string;
    /** 职业码值 */
    occupationCode?: string;
    userEmploer?: string;
    address?: string;
    age?: number;
@@ -1295,6 +1299,10 @@
    useEmploer?: string;
    /** 雇员工种 */
    jobName?: string;
    /** 职业类型 */
    occupationType?: string;
    /** 职业码值 */
    occupationCode?: string;
    /** 用工地点 */
    address?: string;
    phone?: string;
src/utils/storage/storage.ts
@@ -1,9 +1,13 @@
import { loadEnv } from '@build/index';
interface ProxyStorage {
  getItem(key: string): any;
  setItem(Key: string, value: string): void;
  removeItem(key: string): void;
  clear(): void;
}
const { VITE_PUBLIC_PATH } = loadEnv();
//sessionStorage operate
class sessionStorageProxy implements ProxyStorage {
@@ -13,19 +17,23 @@
    this.storage = storageModel;
  }
  getKey(key: string): string {
    return `${VITE_PUBLIC_PATH}_${key}`;
  }
  // 存
  public setItem(key: string, value: any): void {
    this.storage.setItem(key, JSON.stringify(value));
    this.storage.setItem(this.getKey(key), JSON.stringify(value));
  }
  // 取
  public getItem<T = any>(key: string): null | T {
    return JSON.parse(this.storage.getItem(key));
    return JSON.parse(this.storage.getItem(this.getKey(key)));
  }
  // 删
  public removeItem(key: string): void {
    this.storage.removeItem(key);
    this.storage.removeItem(this.getKey(key));
  }
  // 清空
src/views/Home/Home.vue
@@ -53,6 +53,13 @@
          </QueryFilterItem>
        </template>
        <template #btn>
          <el-button
            @click="handleDownloadOccupationType()"
            type="primary"
            style="margin-right: 10px"
            link
            >职业类型对照表</el-button
          >
          <el-button @click="handleDownload()" type="primary" style="margin-right: 10px" link
            >模板下载</el-button
          >
@@ -87,7 +94,7 @@
            class="box-item"
            effect="dark"
            :content="row.auditRemark"
            placement="top-start"
            placement="top"
            v-if="row.auditStatus === InsurancePolicyAuditStatusEnum.Reject && row.auditRemark"
            popper-class="max-width-popper"
          >
@@ -104,6 +111,7 @@
    </AppContainer>
    <UploadInsurePersonDialog v-bind="dialogProps" />
    <UploadStampFileDialog v-bind="dialogStampFileProps" />
    <InsureInstructionsDialog v-bind="dialogInstructionsProps" />
  </LoadingLayout>
</template>
@@ -122,6 +130,7 @@
  SearchInput,
  FieldRadio,
  XLSXUtils,
  useDialog,
} from '@bole-core/components';
import * as insuranceOrderServices from '@/services/api/InsuranceOrder';
import { Message, OrderInputType, downloadFileByUrl } from '@bole-core/core';
@@ -141,9 +150,11 @@
  InsurancePolicyProductIdNumberEnum,
  InsurancePolicyListPayStatusEnum,
  InsurancePolicyListPayStatusEnumText,
  InsuranceOccupationTypeTempPath,
} from '@/constants';
import dayjs from 'dayjs';
import _ from 'lodash';
import InsureInstructionsDialog from './components/InsureInstructionsDialog.vue';
defineOptions({
  name: 'Home',
@@ -182,7 +193,6 @@
    },
    extraProps: {
      hide: (row: API.GetInsurancePageOutput) =>
        row.auditStatus !== InsurancePolicyAuditStatusEnum.Pass ||
        row.status !== InsurancePolicyStatusEnum.WaitEffect,
    },
  },
@@ -256,6 +266,7 @@
onMounted(async () => {
  await getList();
  state.loading = false;
  handleOpenInstructions();
});
const {
@@ -383,6 +394,12 @@
  } catch (error) {}
}
const { dialogProps: dialogInstructionsProps, dialogState: dialogInstructionsState } = useDialog();
function handleOpenInstructions() {
  dialogInstructionsState.dialogVisible = true;
}
function handleUpload() {
  handleAdd({
    serialNum: `${dayjs().format('YYYYMMDD')}${_.random(0, 9999).toString().padStart(4, '0')}`,
@@ -426,6 +443,10 @@
  } catch (error) {}
}
function handleDownloadOccupationType() {
  downloadFileByUrl(InsuranceOccupationTypeTempPath, '职业类型对照表');
}
function handleDownload() {
  downloadFileByUrl(InsuranceOrderTempPath, '保单导入模板');
}
src/views/Home/components/InsureInstructionsDialog.vue
New file
@@ -0,0 +1,153 @@
<template>
  <el-dialog
    v-model="visible"
    destroy-on-close
    draggable
    center
    class="insureInstructionsDialog"
    width="600px"
    :close-on-click-modal="false"
    :close-on-press-escape="false"
  >
    <div class="insureInstructionsDialog-content">
      <!-- <img :src="IconTaipingLogo" alt="" class="logo" /> -->
      <div class="tips-title">温馨提示,您已进入投保流程:</div>
      <div class="tips-item">
        请仔细阅读保险条款,投保须知等内容,为了保障您的合法权益,您的操作轨迹将被记录
      </div>
    </div>
    <template #footer>
      <span class="dialog-footer">
        <el-button type="primary" @click="handleInstructionsNext">同意并继续</el-button>
      </span>
    </template>
  </el-dialog>
  <ProDialog
    v-model="visibleFiles"
    destroy-on-close
    draggable
    center
    class="insureInstructionsFilesDialog"
    width="1000px"
    :close-on-click-modal="false"
    :close-on-press-escape="false"
    top="5vh"
  >
    <div class="insureInstructionsFilesDialog-content">
      <template v-for="(item, index) in InsuranceTempList" :key="item.url">
        <iframe
          :src="item.url"
          class="preview-pdf"
          v-if="item.type === 'pdf'"
          :style="{ display: isCurrent(`step${index}`) ? 'block' : 'none' }"
        ></iframe>
        <PreviewOffice
          :file-url="item.url"
          v-else
          :style="{ display: isCurrent(`step${index}`) ? 'block' : 'none' }"
        />
      </template>
    </div>
    <template #footer>
      <span class="dialog-footer">
        <el-button @click="goToPrevious()" v-if="!isFirst">上一页</el-button>
        <el-button type="primary" @click="goToNext()" v-if="!isLast">下一页</el-button>
        <el-button type="primary" @click="handleConfirm" v-if="isLast">我已阅读并同意</el-button>
      </span>
    </template>
  </ProDialog>
</template>
<script setup lang="ts">
import {
  ProDialog,
  ProForm,
  ProFormItemV2,
  ProFormText,
  UploadUserFile,
} from '@bole-core/components';
import IconTaipingLogo from '@/assets/home/icon-taiping-logo.png';
import { useStepper } from '@vueuse/core';
import { InsuranceTempList } from '@/constants';
defineOptions({
  name: 'InsureInstructionsDialog',
});
// type Props = {};
// const props = withDefaults(defineProps<Props>(), {});
const visible = defineModel({ type: Boolean });
const emit = defineEmits<{
  (e: 'onConfirm'): void;
  (e: 'onCancel'): void;
}>();
function handleInstructionsNext() {
  visible.value = false;
  visibleFiles.value = true;
}
function handleConfirm() {
  visibleFiles.value = false;
  emit('onConfirm');
}
const visibleFiles = ref(false);
const { isCurrent, goToNext, goToPrevious, isLast, isFirst } = useStepper(
  InsuranceTempList.map((x, index) => `step${index}`)
);
</script>
<style lang="scss">
@use '@/style/common.scss' as *;
.insureInstructionsDialog {
  header {
    display: none;
  }
  .insureInstructionsDialog-content {
    .logo {
      display: block;
      margin: 0 auto 32px;
      height: 55px;
    }
    .tips-title {
      margin-bottom: 8px;
      font-size: 18px;
      text-align: center;
      color: getCssVar('text-color', 'primary');
      line-height: 24px;
    }
    .tips-item {
      font-size: 16px;
      text-align: center;
      color: getCssVar('text-color', 'secondary');
      line-height: 20px;
    }
  }
}
.insureInstructionsFilesDialog {
  header {
    display: none;
  }
  .insureInstructionsFilesDialog-content {
    height: 600px;
    .office-wrapper,
    .preview-pdf,
    .office-wrapper iframe {
      width: 100%;
      height: 100%;
    }
  }
}
</style>
src/views/Home/components/InsureOrderInfoView.vue
@@ -6,7 +6,16 @@
          <ProFormCol>
            <ProFormColItem :span="8">
              <ProFormItemV2 label="保单号:" prop="insureBillNo">
                <ProFormText v-model.trim="detail.insureBillNo" />
                <div class="pro-from-item-read-content-wrapper" v-if="!!detail.insureBillNo">
                  {{ detail.insureBillNo }}
                  <el-button
                    type="primary"
                    link
                    @click="handleGoStampFiles"
                    v-if="detail.productOnline && detail.anyPayComplete"
                    >详情</el-button
                  >
                </div>
              </ProFormItemV2>
            </ProFormColItem>
            <ProFormColItem :span="8">
@@ -101,9 +110,11 @@
            </template>
            <template v-else>
              <el-button @click="handleDownloadPerson()" type="primary">下载人员清单</el-button>
              <el-button v-if="detail.productOnline" @click="handleGoStampFiles()" type="primary"
                >下载保单</el-button
              >
              <template v-if="detail.productOnline">
                <el-button v-if="detail.anyPayComplete" @click="handleGoStampFiles()" type="primary"
                  >下载保单</el-button
                >
              </template>
              <el-button v-else @click="handleDownloadOrder()" type="primary">下载保单</el-button>
            </template>
          </template>
@@ -198,6 +209,16 @@
    name: '雇员工种',
  },
  {
    id: '51',
    enCode: 'occupationType',
    name: '职业类型',
  },
  {
    id: '52',
    enCode: 'occupationCode',
    name: '职业码值',
  },
  {
    id: '6',
    enCode: 'userEmploer',
    name: '用工单位',
src/views/InsuranceClaim/components/InsuranceClaimView.vue
@@ -459,14 +459,10 @@
        idIdNumber: form.idNumber,
        reportedTime: form.reportedTime,
      };
      let existedInsuranceOrderList = await queryClient.ensureQueryData({
        queryKey: ['insuranceOrderServices/getInsuranceOrderListByOrderRelevance', params],
        queryFn: async () => {
          return await insuranceOrderServices.getInsuranceOrderListByOrderRelevance(params, {
            showLoading: false,
          });
        },
      });
      let existedInsuranceOrderList =
        await insuranceOrderServices.getInsuranceOrderListByOrderRelevance(params, {
          showLoading: false,
        });
      if (existedInsuranceOrderList.length == 1) {
        form.insuranceOrderId = existedInsuranceOrderList[0].id;
      } else if (existedInsuranceOrderList.length > 1) {
types/global.d.ts
@@ -112,7 +112,7 @@
    VITE_COMPRESSION: ViteCompression;
    VITE_WEMAP_KEY:string;
    VITE_CLIENT_ORIGIN:string;
    VITE_AppType: 'one' | 'rz'| 'jx' | 'jy' | 'other' | 'backup';
    VITE_AppType: 'one' | 'rz' | 'jx' | 'jy' | 'other' | 'backup' | 'tp';
  }
  interface AppConfig {
vite.config.ts
@@ -2,6 +2,7 @@
import { warpperEnv } from './build';
import { getPluginsList } from './build/plugins';
import { UserConfigExport, ConfigEnv, loadEnv, AliasOptions } from 'vite';
import dayjs from 'dayjs';
export const projRoot = resolve(__dirname, '..', '..');
export const pkgRoot = resolve(projRoot, 'packages');
@@ -96,7 +97,7 @@
      __INTLIFY_PROD_DEVTOOLS__: false,
    },
    build: {
      outDir: `dist/dist-jybfront-${VITE_AppType}-${mode}`,
      outDir: `dist/dist-jybfront-${VITE_AppType}-${mode}-${dayjs().format('YYYYMMDD')}`,
    },
    optimizeDeps: {
      include: [