Chensc 20 hours ago
parent
commit
241f2a3d62

+ 34 - 17
component/statistics/LascCervical/index.js

@ -286,6 +286,7 @@ Vue.component('lasc-cervical', {
          { label: '同安区', value: '350212' },
          { label: '翔安区', value: '350213' }
        ]
        this.getHospital()
      } else if (selectedRole.code.length == 6) {
        this.level = 2 // 区管理
        this.areaOptions = [{ label: selectedRole.name.substring(0, 3), value: selectedRole.code }]
@ -365,11 +366,10 @@ Vue.component('lasc-cervical', {
        params.startTime = this.chooseTime[0]
        params.endTime = this.chooseTime[1]
      }
      
      var fileName = `宫颈癌质控统计表${new Date().getTime()}.xls`
      httpRequest.downLoadFileForAjax('doctor/twoCancers/count/exportCervicalQualityCount', fileName, params).then(function () {
        vm.$message.success('导出成功')
   
      })
    },
    eliminateClick() {
@ -406,23 +406,40 @@ Vue.component('lasc-cervical', {
    },
    getHospital(code, flag = true) {
      var vm = this
      if (flag) {
        delete this.form.hospital
        delete this.form.team
      }
      var params = {
        type: 5,
        code: code
      // if (flag) {
      //   delete this.form.hospital
      //   delete this.form.team
      // }
      // var params = {
      //   type: 5,
      //   code: code
      // }
      // if (!code) {
      //   params = {
      //     type: 6,
      //     code: '350200'
      //   }
      // }
      // httpRequest.post('common/district', { data: params }).then(function (res) {
      //   vm.hospitalOptions = [{ name: '全部', value: '' }]
      //   vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      // })
      var data = {
        town: code ? code : this.form.town ? this.form.town : '',
        hospital: ''
      }
      if (!code) {
        params = {
          type: 6,
          code: '350200'
      httpRequest.get('doctor/twoCancers/count/hospitalList', { data }).then(function (res) {
        vm.hospitalOptions = []
        // vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
        if (res.status == 200) {
          vm.hospitalOptions = [{ code: '', name: '全部' }]
          res.data.forEach(item => {
            vm.hospitalOptions.push({
              name: item.hospital_name,
              code: item.hospital
            })
          })
        }
      }
      httpRequest.post('common/district', { data: params }).then(function (res) {
        vm.hospitalOptions = [{ name: '全部', value: '' }]
        vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      })
    },
    getTeam(code, flag = true) {

+ 30 - 15
component/statistics/LascPatient/index.js

@ -105,6 +105,7 @@ Vue.component('lasc-patient', {
          { label: '同安区', value: '350212' },
          { label: '翔安区', value: '350213' }
        ]
        this.getHospital()
      } else if (selectedRole.code.length == 6) {
        // console.log('区管理')
        this.level = 2 // 区管理
@ -115,7 +116,7 @@ Vue.component('lasc-patient', {
        }
        this.getHospital(selectedRole.code)
      } else {
        // console.log('社区管理')
        console.log('社区管理')
        this.level = 3 // 社区管理
        this.rangeOptions = [{ label: '机构', value: '2' }]
        this.areaOptions = [{ label: selectedRole.name.substring(0, 3), value: selectedRole.code.substring(0, 6) }]
@ -215,7 +216,7 @@ Vue.component('lasc-patient', {
          params.endTime = this.chooseTime1[1]
        }
      }
 
      var fileName = `两癌筛查居民档案${new Date().getTime()}.xls`
      httpRequest.downLoadFileForAjax('doctor/twoCancers/count/exportPatientArchive', fileName, params).then(function () {
        vm.$message.success('导出成功')
@ -258,21 +259,35 @@ Vue.component('lasc-patient', {
    },
    getHospital(code) {
      var vm = this
      delete this.form.hospital
      delete this.form.team
      var params = {
        type: 5,
        code: code
      // delete this.form.hospital
      // delete this.form.team
      // var params = {
      //   type: 5,
      //   code: code
      // }
      // if (!code) {
      //   params = {
      //     type: 6,
      //     code: '350200'
      //   }
      // }
      var data = {
        town: code ? code : this.form.town ? this.form.town : '',
        hospital: ''
      }
      if (!code) {
        params = {
          type: 6,
          code: '350200'
      // common/district
      httpRequest.get('doctor/twoCancers/count/hospitalList', { data }).then(function (res) {
        vm.hospitalOptions = []
        // vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
        if (res.status == 200) {
          vm.hospitalOptions = [{ code: '', name: '全部' }]
          res.data.forEach(item => {
            vm.hospitalOptions.push({
              name: item.hospital_name,
              code: item.hospital
            })
          })
        }
      }
      httpRequest.post('common/district', { data: params }).then(function (res) {
        vm.hospitalOptions = [{ code: '', name: '全部' }]
        vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      })
    },
    getTeam(code) {

+ 52 - 33
component/statistics/LascProgress/index.js

@ -109,6 +109,7 @@ Vue.component('lasc-progress', {
          { label: '同安区', value: '350212' },
          { label: '翔安区', value: '350213' }
        ]
        this.getHospital()
      } else if (selectedRole.code.length == 6) {
        this.level = 2 // 区管理
        this.areaOptions = [{ label: selectedRole.name.substring(0, 3), value: selectedRole.code }]
@ -207,7 +208,7 @@ Vue.component('lasc-progress', {
        params.startTime = this.chooseTime[0]
        params.endTime = this.chooseTime[1]
      }
  
      var fileName = `两癌筛查进度统计${new Date().getTime()}.xls`
      httpRequest.downLoadFileForAjax('doctor/twoCancers/count/exportTwoCancerProgress', fileName, params).then(function () {
        vm.$message.success('导出成功')
@ -248,24 +249,42 @@ Vue.component('lasc-progress', {
    },
    getHospital(code, flag = true) {
      var vm = this
      if (flag) {
        delete this.form.hospital
        delete this.form.team
      }
      var params = {
        type: 5,
        code: code
      // if (flag) {
      //   delete this.form.hospital
      //   delete this.form.team
      // }
      // var params = {
      //   type: 5,
      //   code: code
      // }
      // if (!code) {
      //   params = {
      //     type: 6,
      //     code: '350200'
      //   }
      // }
      var data = {
        town: code ? code : this.form.town ? this.form.town : '',
        hospital: ''
      }
      if (!code) {
        params = {
          type: 6,
          code: '350200'
      httpRequest.get('doctor/twoCancers/count/hospitalList', { data }).then(function (res) {
        vm.hospitalOptions = []
        // vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
        if (res.status == 200) {
          vm.hospitalOptions = [{ code: '', name: '全部' }]
          res.data.forEach(item => {
            vm.hospitalOptions.push({
              name: item.hospital_name,
              code: item.hospital
            })
          })
        }
      }
      httpRequest.post('common/district', { data: params }).then(function (res) {
        vm.hospitalOptions = [{ code: '', name: '全部' }]
        vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      })
      // httpRequest.post('common/district', { data: params }).then(function (res) {
      //   vm.hospitalOptions = [{ code: '', name: '全部' }]
      //   vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      // })
    },
    handleCurrentChange(val) {
@ -297,23 +316,23 @@ Vue.component('lasc-progress', {
        } else if (selectedRole.code.length == 6) {
          type = 2
        }
        statisticAPI
          .hospitalsByType({
            type: type,
            code: selectedRole.code
          })
          .then(function (res) {
            if (res.status == 200) {
              vm.hospitalOptions = [{ name: '全部', code: '' }]
              res.list.forEach(function (v) {
                vm.hospitalOptions.push(v)
              })
              console.log('22222222222222222222', vm)
            }
          })
          .catch(function (err) {
            console.log(err, 'Errr')
          })
        // statisticAPI
        //   .hospitalsByType({
        //     type: type,
        //     code: selectedRole.code
        //   })
        //   .then(function (res) {
        //     if (res.status == 200) {
        //       vm.hospitalOptions = [{ name: '全部', code: '' }]
        //       res.list.forEach(function (v) {
        //         vm.hospitalOptions.push(v)
        //       })
        //       console.log('22222222222222222222', vm)
        //     }
        //   })
        //   .catch(function (err) {
        //     console.log(err, 'Errr')
        //   })
      }
    },

+ 35 - 16
component/statistics/breastCancerPatient/index.js

@ -5,7 +5,7 @@ $.ajax('../../../component/statistics/breastCancerPatient/index.html', {
  cache: false,
  timeout: 60000,
  async: false,
  error: function (res) { },
  error: function (res) {},
  success: function (res) {
    template = res
  }
@ -224,9 +224,9 @@ Vue.component('breast-cancer-patient', {
          label: '随访状态',
          children: [
            { prop: 'followupNum', label: '已随访' },
            { prop: 'unFollowupNum', label: '未随访' },
            { prop: 'unFollowupNum', label: '未随访' }
          ]
        },
        }
      ],
      dialogLoading: false
    }
@ -253,6 +253,7 @@ Vue.component('breast-cancer-patient', {
          { label: '同安区', value: '350212' },
          { label: '翔安区', value: '350213' }
        ]
        this.getHospital()
      } else if (selectedRole.code.length == 6) {
        this.level = 2 // 区管理
        this.areaOptions = [{ label: selectedRole.name.substring(0, 3), value: selectedRole.code }]
@ -373,21 +374,39 @@ Vue.component('breast-cancer-patient', {
    },
    getHospital(code) {
      var vm = this
      delete this.form.hospital
      delete this.form.team
      var params = {
        type: 5,
        code: code
      // delete this.form.hospital
      // delete this.form.team
      // var params = {
      //   type: 5,
      //   code: code
      // }
      // if (!code) {
      //   params = {
      //     type: 6,
      //     code: '350200'
      //   }
      // }
      // httpRequest.post('common/district', { data: params }).then(function (res) {
      //   vm.hospitalOptions = [{ code: '', name: '全部' }]
      //   vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      // })
      var data = {
        town: code ? code : this.form.town ? this.form.town : '',
        hospital: ''
      }
      if (!code) {
        params = {
          type: 6,
          code: '350200'
      // common/district
      httpRequest.get('doctor/twoCancers/count/hospitalList', { data }).then(function (res) {
        vm.hospitalOptions = []
        // vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
        if (res.status == 200) {
          vm.hospitalOptions = [{ code: '', name: '全部' }]
          res.data.forEach(item => {
            vm.hospitalOptions.push({
              name: item.hospital_name,
              code: item.hospital
            })
          })
        }
      }
      httpRequest.post('common/district', { data: params }).then(function (res) {
        vm.hospitalOptions = [{ code: '', name: '全部' }]
        vm.hospitalOptions = vm.hospitalOptions.concat(res.list)
      })
    },
    getTeam(code) {