hwy 2 månader sedan
förälder
incheckning
b721c8657e

+ 7 - 0
app/statistics/js/comprehensive-query.js

@ -6,6 +6,7 @@ new Vue({
    height: '',
    isloading: false, //加载中
    start: '',
    searchStr:1,
    end: '',
    tabledata: [], //表格数据
    levelList: [
@ -570,6 +571,12 @@ new Vue({
  mounted: function () {
    var vm = this;
    //初始化数据
    var searchStr = location.search;
if(searchStr){
   vm.searchStr=0
   vm.tabsList=[{id: '7', text: '疾控慢阻肺监测', show: true}]
   vm.tabsClick({id: '7', text: '疾控慢阻肺监测', show: true})
}
    initData(vm);
    vm.getQuotaStr()
    vm.getDiseaseTypeList();

+ 33 - 0
component/statistics/CopdPatientRecord/index.html

@ -91,6 +91,39 @@
              <el-input class="pr20 formWidth wd160" v-model="firstOrg" placeholder="请输入医院名称查询"></el-input>
            </div>
            <!--=======================================================-->
            <div class="searchDiv pb20">
              <label class="c-333 c-f14">
                数据范围:
              </label>
              <el-select class="pr20 formWidth" v-model="rangeCode"  placeholder="请选择">
                <el-option v-for="(option, index) in rangeList" :label="option.name"
                           :value="option.code"></el-option>
              </el-select>
            </div>
              <!--=======================================================-->
    <template v-if="rangeCode!='city'">
      <div class="searchDiv pb20">
        <label class="c-333 c-f14">
          地区:
        </label>
        <el-select v-model="areaCode" style="width: 100px" class="pr10">
        <el-option v-for="(item , index) in areaList" :key="index" :label="item.name"
          :value="item.code"></el-option>
      </el-select>
      </div>
      <!--=======================================================-->
      <div class="searchDiv pb20" v-show="rangeCode!='town'&&rangeCode!='specHos'">
        <label class="c-333 c-f14">
          社区:
        </label>
        <el-select v-model="communityCode" style="width: 200px" class="pr10">
        <el-option v-for="(item , index) in communityArr" :key="index" :label="item.name"
          :value="item.code"></el-option>
      </el-select>
      </div>
    </template>
    <!--=======================================================-->
            <div class="searchDiv pb20">
              <el-button type="primary" size="mini" @click="queryDate">查询</el-button>
              <!-- <el-upload

+ 72 - 2
component/statistics/CopdPatientRecord/index.js

@ -26,6 +26,7 @@ Vue.component('copd-patient-record', {
      currentEditData: null,
      // 编辑页面是否显示
      editViewVisable: false,
      userRoleCode:'',
      //服务记录是否显示
      serviceRecordVisable: false,
      transferStatusOptions:[{code:'',value:'全部'}],
@ -40,6 +41,8 @@ Vue.component('copd-patient-record', {
      size: 50,
      currentSize:50,
      currentPage: 1,
      rangeList:[  {name: '按区', code: 'town'}],
      rangeCode:'town',
      totalPage: 0,
      totalCount: 0,
      name:'',
@ -60,6 +63,9 @@ Vue.component('copd-patient-record', {
      endTime:'',
      chooseYear: '',
      nowyear:'',
      areaList:[],
      areaCode:"",
      communityCode:'',
            fileList: [],
            file: undefined,
            isProgressShow: false,
@ -93,7 +99,10 @@ Vue.component('copd-patient-record', {
  },
  mounted() {
    var vm = this
    var userRole = window.sessionStorage.getItem('selectedRole');
    vm.userRoleCode = JSON.parse(userRole).code;
    this.initTime(vm)
    this.initScope(this)
    this.hospitalList()
    EventBus.$on('copd-reset-select', function () {
      vm.currentEditData = null
@ -141,6 +150,40 @@ Vue.component('copd-patient-record', {
    vm.years.push(i);
  }
},    
    // 数据范围初始化
    initScope(vm) {
      //获得缓存中缓存的角色权限
      var userRole = window.sessionStorage.getItem('selectedRole');
      if (!userRole) {
        return false;
      }
      vm.userRole = JSON.parse(userRole);
      //level:2、市,3、区,4、社区,5、团队
      vm.initareaLevel = vm.areaLevel = vm.userRole.code == '350200' ? 2 : vm.userRole.code.length == 6 ? 3 : 4;
      vm.initlevel = vm.level = vm.userRole.code == '350200' ? 4 : vm.userRole.code.length == 6 ? 3 : 2;
      //	vm.lowLevel = vm.initlowLevel = vm.userRole.code == '350200' ? 3 : vm.userRole.code.length == 6 ? 2 : 1;
    
      vm.initarea = vm.area = vm.userRole.code;
      vm.areaTitle = vm.userRole.name;
    
      if (vm.initlevel == 4) {
        //市获取区
        vm.getDistrict(3, vm.initarea, vm.areaTitle.substr(0, 3));
        vm.rangeCode = vm.rangeList[0].code;
      } else if (vm.initlevel == 3) {
        //区获取社区
        vm.areaList = [{code: vm.initarea, name: vm.areaTitle}];
        vm.areaCode = vm.initarea;
        vm.rangeCode = vm.rangeList[0].code;
      } else if (vm.initlevel == 2) {
        //社区获取团队
        vm.communityList = [{code: vm.initarea, name: vm.areaTitle}];
        vm.communityCode = vm.initarea;
        vm.rangeList.shift();
        vm.rangeCode = vm.rangeList[0].code;
      }
      vm.range = vm.rangeCode;
    },
    handlePreview(value) {
      var vm = this
			var file = value.target.files[0]
@ -178,9 +221,34 @@ Vue.component('copd-patient-record', {
            // })
          }
    },
        //获取省市区  type:区3
        getDistrict: function (type, code, name) {
          var vm = this,
            list = [],
            param = '';
          if (type == 3) {
            list = [{code: code, name: name}];
            param = 'area';
          } else if (type == 5) {
            list = [{code: '', name: '全部'}];
            param = 'community';
          }
          var params = {
            type: type,
            code: code
          };
          homeAPI.getDistrict(params).then(function (res) {
            if (res.status == 200) {
              vm[param + 'List'] = list.concat(res.list);
              vm[param + 'Code'] = vm[param + 'List'][0].code;
            } else {
              vm.$message.error(res.msg);
            }
          });
        },
    hospitalList(){
      var vm=this
    statisticAPI.hospitalList().then(function(res){
    statisticAPI.hospitalList({queryArea:vm.userRoleCode}).then(function(res){
      vm.receivingHospitalList=vm.receivingHospitalList&& vm.receivingHospitalList.concat(res.detailModelList)
    })
    },
@ -197,7 +265,8 @@ Vue.component('copd-patient-record', {
        hospital:this.hospital,
        doctorName:this.doctorName,
        isLive: this.isLive,
        firstOrg: this.firstOrg
        firstOrg: this.firstOrg,
        queryArea:this.userRoleCode
      }
      statisticAPI.exportJkCopdAchives(params,'居民档案.xls').then(
         function(res){
@ -376,6 +445,7 @@ openURL (url) {
        hospital:this.hospital,
        doctorName:this.doctorName,
        isLive: this.isLive,
        queryArea:this.userRoleCode,
        firstOrg: this.firstOrg,
        startTime: this.chooseYear=='全部'?"": this.chooseYear+'-01-01',
        endTime:this.chooseYear=='全部'?"": this.chooseYear+'-12-31',

+ 1 - 1
component/statistics/CopdRecordSearch/index.html

@ -169,7 +169,7 @@
          社区:
        </label>
        <el-select v-model="communityCode" style="width: 200px" class="pr10">
        <el-option v-for="(item , index) in communityList" :key="index" :label="item.name"
        <el-option v-for="(item , index) in communityArr" :key="index" :label="item.name"
          :value="item.code"></el-option>
      </el-select>
      </div>

+ 15 - 2
component/statistics/CopdRecordSearch/index.js

@ -1,4 +1,3 @@
// 慢阻肺患者档案-服务档案
var template = '';
$.ajax('../../../component/statistics/CopdRecordSearch/index.html', {
@ -20,6 +19,7 @@ Vue.component('copd-record-search', {
  data() {
    return {
      // 当前显示的字段
      communityArr:[],
      tableFieldList: [],
      quotaStrArr:[],
      value1:[],
@ -84,7 +84,8 @@ Vue.component('copd-record-search', {
      communityList: [{code: '', name: '全部'}],
      communityCode: '',
      teamList: [{code: '', name: '全部'}],
      teamCode: ''
      teamCode: '',
      userRoleCode:''
    };
  },
  watch:{
@ -111,6 +112,15 @@ Vue.component('copd-record-search', {
    },
  },
  methods: {
    getCommunityList(){
     var vm=this
     statisticAPI.hospitalList({queryArea:vm.userRoleCode}).then(function(res){
      if(res.status==200){
       vm.communityArr= res.detailModelList
      }
     })
    },
     //字典
     getDictByDictName(value){
      var vm=this
@ -386,8 +396,11 @@ initScope(vm) {
  },
  mounted() {
    var vm = this
    var userRole = window.sessionStorage.getItem('selectedRole');
    vm.userRoleCode = JSON.parse(userRole).code;
    this.initTime(this)
    this.initScope(this)
    this.getCommunityList()
    EventBus.$on('copd-record-filter-change', function (event) {
      vm.quotaStrArr = event
      console.log(vm.quotaStrArr,'999sd8s9a8d9s8ad9sa89')