App.vue 14 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430
<!--
 * @Description:
 * @LastEditors: Please set LastEditors
 * @Date: 2021-01-28 23:29:19
-->

<template>
  <div>
    <XrkBi
      :print="false"
      :cantEdit="2"
      projectType="20"
      from="cso"
      v-bind="config"
      :getTemplateList="getTemplateList"
    ></XrkBi>
  </div>
  <!-- <ul class="pervie">
    <li name="任务记录">
      <h1>任务记录</h1>
      <TaskDetail :config="taskDetailOptions"></TaskDetail>
    </li>
    <li name="滑动组件">
      <h1>滑动组件</h1>
      <div style="padding:300px 0 30px 100px;width:350px;" class="block">
        <input type="text" v-model="form.phone" />
        <button @click="showVerify">submit</button>
        <XrkSlideVerify
          ref="verify"
          title="12"
          :options="options"
        ></XrkSlideVerify>
      </div>
    </li>
  </ul> -->
</template>

<script>
import { getQueryVariable } from './packages/bi/src/chart-type/common';

export default {
  name: 'App',
  data() {
    return {
      isMobile: +getQueryVariable('mobile') === 1,
      isPrint: +getQueryVariable('print') === 1,
      projectType: +getQueryVariable('projectType') || 6,
      componentName: getQueryVariable('componentName') || 'XrkBi',
      config: {
        getBaseInfo() {
          return {
            data: {
              data: [
                {
                  styleConfigureSettlementTime: '2022-04-13',
                  createUserId: 11,
                  createFullName: '钱思远',
                  projectType: 20,
                  endDt: null,
                  isAuditCso: 1,
                  dataCollectNumber: 1,
                  type: 1,
                  title:
                    '关于标签演示园区个体01产品全国区域可配置场景项目数据报告',
                  isAuditGongye: 1,
                  aspEnterpriseNameWrite:
                    '服务商:康师傅方便面投资(中国)有限公司-乙方',
                  aspEnterpriseName: '康师傅方便面投资(中国)有限公司-乙方',
                  examinePeopleNumber: 1,
                  executePeopleNumber: 1,
                  taskSum: 1,
                  clickNum: null,
                  id: 2614,
                  aspNamePosition: null,
                  titlePosition: null,
                  reportId: null,
                  coverTemplateUrl:
                    'https://cdn.yxvzb.com/sunflower/invoice/1648173119057.jpeg',
                  isContrainGroupAnalyse: 0,
                  nameShowType: 3,
                  patternType: 12,
                  videoNum: null,
                  isContrainSingleAnalyse: 1,
                  createDt: 1649821497000,
                  coverTemplateId: 1,
                  enterpriseType: null,
                  isAuditAllince: 1,
                  settlementTime: '2022-04-13',
                  chooseTopicNum: 1,
                  startDt: null,
                  enterpriseId: null,
                  projectName:
                    '关于标签演示园区个体01产品全国区域可配置场景项目',
                  fenpeiId: 5636,
                  sendEnterpriseName: null,
                  projectId: 122,
                  styleConfigureId: 120,
                  styleConfigureSettlementTimePosition: null,
                  totalTopicNum: 1,
                  csoAuditUser: '孟祥龙'
                }
              ],
              message: '操作成功',
              status: '1'
            }
          };
        },
        getFixedInfo() {
          return {
            data: {
              data: [
                {
                  resultSystem:
                    '项目执行总人数1人,其中男性0人,占比0%;女性1,占比100.00%',
                  resultUser: null,
                  analyseDescribe:
                    '执行人数1,18-30岁的男性占比0% ,女性100.00%;31-40岁的男性占比0% ,女性0%;41-50岁的男性占比0% ,女性0%;51岁以上的男性占比0% ,女性0%',
                  chartType: null,
                  colourGroup: null,
                  id: 465,
                  fixedCountInfos: [
                    {
                      id: 1753,
                      fixedDetaileId: 465,
                      num: 0,
                      passType: null,
                      genderType: '男',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1754,
                      fixedDetaileId: 465,
                      num: 1,
                      passType: null,
                      genderType: '女',
                      ageType: null,
                      taskNumType: null
                    }
                  ],
                  type: 1,
                  createDt: 1649821497000
                },
                {
                  resultSystem:
                    '项目执行总人数1人,其中18-30岁的1人,占比100.00%; 31-40岁的0人,占比0%;41-50岁的0人,占比0%;50岁及其以上0人 ,占比0%',
                  resultUser: null,
                  analyseDescribe:
                    '执行人数1,18-30岁的男性占比0% ,女性100.00%;31-40岁的男性占比0% ,女性0%;41-50岁的男性占比0% ,女性0%;51岁以上的男性占比0% ,女性0%',
                  chartType: null,
                  colourGroup: null,
                  id: 466,
                  fixedCountInfos: [
                    {
                      id: 1755,
                      fixedDetaileId: 466,
                      num: 1,
                      passType: null,
                      genderType: '18-30岁',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1756,
                      fixedDetaileId: 466,
                      num: 0,
                      passType: null,
                      genderType: '31-40岁',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1757,
                      fixedDetaileId: 466,
                      num: 0,
                      passType: null,
                      genderType: '41-50岁',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1758,
                      fixedDetaileId: 466,
                      num: 0,
                      passType: null,
                      genderType: '51岁以上',
                      ageType: null,
                      taskNumType: null
                    }
                  ],
                  type: 2,
                  createDt: 1649821497000
                },
                {
                  resultSystem:
                    '项目执行总人数1人:完成1-10单的有1人,占比100.00%;完成11-20单的有0人,占比0%;完成21-30单的有0人,占比0%;完成31-40单的有0人,占比0%;完成41单以上的有0人,占比0%',
                  resultUser: null,
                  analyseDescribe: null,
                  chartType: null,
                  colourGroup: null,
                  id: 467,
                  fixedCountInfos: [
                    {
                      id: 1759,
                      fixedDetaileId: 467,
                      num: 1,
                      passType: null,
                      genderType: '1-10',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1760,
                      fixedDetaileId: 467,
                      num: 0,
                      passType: null,
                      genderType: '11-20',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1761,
                      fixedDetaileId: 467,
                      num: 0,
                      passType: null,
                      genderType: '21-30',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1762,
                      fixedDetaileId: 467,
                      num: 0,
                      passType: null,
                      genderType: '31-40',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1763,
                      fixedDetaileId: 467,
                      num: 0,
                      passType: null,
                      genderType: '41个以上',
                      ageType: null,
                      taskNumType: null
                    }
                  ],
                  type: 3,
                  createDt: 1649821497000
                },
                {
                  resultSystem:
                    '项目执行总任务数:0次,其中通过任务数0,占比0%;未通过任务数0,占比0%',
                  resultUser: null,
                  analyseDescribe: null,
                  chartType: null,
                  colourGroup: null,
                  id: 468,
                  fixedCountInfos: [
                    {
                      id: 1764,
                      fixedDetaileId: 468,
                      num: 0,
                      passType: null,
                      genderType: '通过',
                      ageType: null,
                      taskNumType: null
                    },
                    {
                      id: 1765,
                      fixedDetaileId: 468,
                      num: 0,
                      passType: null,
                      genderType: '未通过',
                      ageType: null,
                      taskNumType: null
                    }
                  ],
                  type: 4,
                  createDt: 1649821497000
                }
              ],
              message: '操作成功',
              status: '1'
            }
          };
        },
        getTopicInfo() {
          return {
            data: {
              data: [
                {
                  resultSystem:
                    '参与【此题为单选题(点击编辑题干)】调查的1个样本。选择答案【选项1】有1个,占比100.00%;选择答案【选项2】有0个,占比0%;选择答案【选项yyy3】有0个,占比0%;选择答案【选项4】有0个,占比0%',
                  resultUser: null,
                  isDelete: 0,
                  type: 1,
                  createDt: 1649821497000,
                  topicTitle: '此题为单选题(点击编辑题干)',
                  topicId: 1195,
                  showSort: null,
                  chartType: null,
                  topicCountInfos: [
                    {
                      xTopicName: '选项1',
                      topicDetaileId: 248,
                      countNum: 1,
                      id: 696
                    },
                    {
                      xTopicName: '选项2',
                      topicDetaileId: 248,
                      countNum: 0,
                      id: 697
                    },
                    {
                      xTopicName: '选项yyy3',
                      topicDetaileId: 248,
                      countNum: 0,
                      id: 698
                    },
                    {
                      xTopicName: '选项4',
                      topicDetaileId: 248,
                      countNum: 0,
                      id: 699
                    }
                  ],
                  colourGroup: null,
                  id: 248,
                  resultIsShow: 1
                }
              ],
              message: '操作成功',
              status: '1'
            }
          };
        },
        getGroupInfo() {
          return {
            data: { data: [], message: '操作成功', status: '1' }
          };
        },
        // 当期BI-保持选择的图片
        saveBiPicList() {
          return {
            data: { data: [], message: '操作成功', status: '1' }
          };
        },
        // 当期BI-保持选择的图片
        getTaskPicList() {
          return {
            data: {
              data: {
                taskImages: [
                  {
                    biInfoId: 123, //BI主键
                    taskId: 123, //任务记录ID
                    imageUrl: '图片地址'
                  }
                ]
              },
              message: '操作成功',
              status: '1'
            }
          };
        },
        // 累计BI、自定义BI获取随机50张图片
        getImageList() {
          return {
            data: {
              data: {
                imageStyle: 1, //展示样式 1 流式   2平铺
                imageSize: 2, //图片大小 1 大  2中  3小
                imageUrls: [
                  {
                    id: 1,
                    biInfoId: 123, //BI主键
                    taskId: 123, //任务记录ID
                    imageUrl: '图片地址'
                  }
                ]
              },
              message: '操作成功',
              status: '1'
            }
          };
        },
        saveInfo() {
          return null;
        },
        exportBi() {
          return null;
        }
      }
    };
  },
  methods: {
    getTemplateList() {
      return {
        data: {
          data: [
            {
              id: 2,
              templateCode: null,
              templateName: '2022050711',
              templatePicUrl:
                'https://cdn.yxvzb.com/sunflower/invoice/1651894583988.png',
              status: null,
              isDelete: null,
              createDt: null
            }
          ],
          message: '操作成功',
          status: '1'
        }
      };
    }
  }
};
</script>

<style>
.block {
  box-sizing: border-box;
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
}
</style>