Browse Source

·········

liangweifeng 6 years ago
parent
commit
8586b81555

+ 39 - 11
page/bigDataOut/css/tableChange.css

@ -10,7 +10,7 @@ body {
.nav {
    width: 420px;
    margin: 30px auto;
    margin: 20px auto;
}
.tabNav {
@ -18,13 +18,14 @@ body {
}
.el-table .cell {
    text-align: center
    text-align: center;
}
.has-gutter{
    background-color: #f8f8f8;
.el-radio-button__inner {}
}
.main {
    margin: -30px 30px;
    margin: -5px 22px;
}
.span {
@ -34,17 +35,32 @@ body {
}
.el-input__inner {
    height: 35px;
    width: 135px;
    margin-right: 15px;
    margin-bottom: 15px;
}
.el-range-editor.el-input__inner {
    height: 30px;
    padding: 0;
}
.el-input__inner:nth:first-child(1) {
    width: 100px;
.el-input__inner:nth-last-child(1){
    width: 30px;
}
.el-input__icon {
    line-height: 30px
.el-icon-arrow-up{
    position: relative;
    left: -10px;
   top: -8px;
}
.el-icon-date{
    position: relative;
    top: -8px;
}
.search {
    display: inline-block;
    background-color: #409EFF;
@ -77,9 +93,21 @@ body {
    left: 30px;
}
.modelSearch {
    display: inline-block
}
.modelSearch .el-input__inner {
    width: 200px;
    height: 30px;
}
a {
    text-decoration: none;
    margin-right: 15px;
    margin-bottom: 15px;
}
.content .el-input__inner{
    width: 150px;
.el-input__icon el-range__icon el-icon-date{
    position: relative;
    top: 10px;
}

+ 2 - 3
page/bigDataOut/html/tableChange.html

@ -9,7 +9,6 @@
    <link rel="stylesheet" href="../../../css/element.css">
    <link rel="stylesheet" href="../css/tableChange.css">
</head>
<body>
    <div id="app">
        <!-- tab切换 -->
@ -40,11 +39,11 @@
        new Vue({
            el: "#app",
            methods: {
                handleClick(row) {
                handleClick:function(row) {
                    console.log(row);
                },
            },
            data() {
            data:function() {
                return {
                    tabPosition: 'top',
                    currentView: 'comA',

+ 73 - 55
page/bigDataOut/js/handleChangeViewA.js

@ -1,79 +1,97 @@
Vue.component('comA',{
    template:'<div class="tab1">\
Vue.component('comA', {
    template: '<div class="tab1">\
    <template>\
    <el-date-picker  v-model="value1" type="date" placeholder="选择日期">\
  </el-date-picker>\
    <div class="search" @click="searchClick">搜  索</div>\
        <span class="span">一周就医次数>=3次的患者记录</span>\
           <el-table :data="tableData" border style="width: 100%" :data.native="tableData.slice((currentPage-1)*pagesize,currentPage*pagesize)">\
                        <el-table-column prop="name" label="姓名" width="140">\
           <el-table :data="tableData" border style="width: 100%" :data.native="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)"">\
                        <el-table-column prop="patient_name" label="姓名">\
                        </el-table-column>\
                        <el-table-column prop="province" label="就医次数" width="140">\
                        <el-table-column prop="result" label="就医次数">\
                        </el-table-column>\
                        <el-table-column prop="address" label="身份证号" width="380">\
                        <el-table-column prop="demographic_id" label="身份证号" >\
                        </el-table-column>\
                        <el-table-column prop="province" label="性别" width="140">\
                            <el-table-column label="性别" >\
                            <template slot-scope="scope">\
                            <span v-if="scope.row.patient_sex == 1">男</span>\
                            <span v-else>女</span>\
                            </template>\
                        </el-table-column>\
                        <el-table-column prop="province" label="年龄" width="140">\
                        <el-table-column prop="patient_age" label="年龄">\
                        </el-table-column>\
                        <el-table-column prop="address" label="地址" width="380">\
                        <el-table-column prop="address" label="家庭地址" >\
                        </el-table-column>\
                        <el-table-column fixed="right" label="操作" width="140">\
                        <el-table-column fixed="right" label="操作" >\
                            <template slot-scope="scope">\
                                <el-button @click="handleClick(scope.row)" type="text" size="small">查看详情</el-button>\
                            </template>\
                        </el-table-column>\
           </el-table>\
           <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"\
                        :page-sizes="[2,10, 20, 40]" :page-size="pagesize" layout="total,sizes,prev, pager, next, jumper"\
                        :total="tableData.length">\
           </el-pagination>\
           <el-pagination \
                @size-change="handleSizeChange"\
                @current-change="handleCurrentChange" \
                :current-page="currentPage"\
                :page-sizes="pageSizeArr"\
                :page-size="pageSize" \
                layout="total,sizes,prev, pager, next, jumper"\
                :total="total">\
        </el-pagination>\
    </template>\
</div> ',
    data:function(){
        return{
    data: function () {
        return {
            currentPage: 1, //初始页
            pagesize:2,    //    每页的数据 
            tableData: [{
                date: '2016-05-03',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-02',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-04',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-01',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }],
            pageSize: 10,    //    每页的数据 
            tableData: [],
            pageSizeArr: [10, 20, 30, 50],
            total: 0,
            value1: '2018-08-30',
        }
    
    },
    mounted: function () {
        this.getData()
    },
    methods: {
        handleSizeChange: function (size) {
            this.pagesize = size;
            console.log(this.pagesize)  //每页下拉显示数据
        handleCurrentChange: function (val) {
            this.currentPage = val;
            this.getData()
        },
        handleSizeChange: function (val) {
            this.pageSize = val;
            this.initData()
        },
        handleCurrentChange: function (currentPage) {
            this.currentPage = currentPage;
            console.log(this.currentPage)  //点击第几页
        initData: function () { //初始化
            this.currentPage = 1;
            this.getData()
        },
        handleClick(row) {
        searchClick: function () {
            this.initData()
        },
        getData: function () {
            var vm = this;
            var params = {
                time: this.value1,
                size: 15,
                page: 1,
            }
            GlobalEventBus.$emit('setLoading', {
                loading: true
            }); //等待效果
            bigDataOutApi.getOftenIllList(params).then(function (res) {
                console.log(res)
                GlobalEventBus.$emit('setLoading');
                vm.tableData = res.detailModelList;
                vm.total = res.totalCount;
            }).catch(function (err) {
                console.log(err)
                GlobalEventBus.$emit('setLoading');
            })
        },
        handleClick:function() {
            console.log(row);
          }
        }
    }
})

+ 115 - 65
page/bigDataOut/js/handleChangeViewB.js

@ -1,52 +1,45 @@
Vue.component('comB', {
    template: '<div class="tab2" >\
    <template>\
      <div class="content">\
      <span>就诊类型:</span>  \
      <el-select v-model="value" placeholder="请选择">\
            <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value">\
            </el-option>\
        </el-select>\
        <span>机构等级:</span>  \
        <el-select v-model="items" placeholder="请选择">\
                <el-option v-for="item in option" :key="item.value" :label="item.label" :value="item.value">\
                </el-option>\
        </el-select>\
        <el-select v-model="item" placeholder="请选择">\
                <el-option v-for="item in option" :key="item.value" :label="item.label" :value="item.value">\
                </el-option>\
        </el-select>\
        <span class="demonstration">时间:</span>\
        <el-date-picker\
        v-model="value4"\
        type="month"\
        placeholder="选择月">\
      </el-date-picker>\
        <div class="search">搜  索</div>\
      <div>\
    </template>\
    <span class="span">门急诊费>=999,000.00(999,000.00=上月门急诊次均费用*3)/住院费用>=999,000.00(999,000.00=上月住院次均费用*3)</span>\
    <el-table :data="tableData" border style="width: 100%" :data.native="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)">\
        <el-table-column prop="patient_name" label="姓名" width="140">\
        </el-table-column>\
        <el-table-column prop="demographic_id" label="身份证号" width="380">\
        </el-table-column>\
        <el-table-column label="性别">\
        <template slot-scope="scope">\
          <span v-if="scope.row.patient_sex == 1">男</span>\
          <span v-else>女</span>\
        </template>\
      </el-table-column>\
        <el-table-column prop="patient_age" label="年龄" width="140">\
        </el-table-column>\
        <el-table-column prop="EHR_000045" label="家庭地址" width="380">\
        </el-table-column>\
        <el-table-column fixed="right" label="操作" width="140">\
        <template slot-scope="scope">\
        <el-button @click="handleClick(scope.row)" type="text" size="small">查看详情</el-button>\
    </template>\
        </el-table-column>\
    </el-table>\
          <template>\
                      <span>就诊类型:</span>  \
                      <el-select v-model="eventType" placeholder="请选择">\
                            <el-option v-for="item in event_type" :key="item.code" :label="item.name" :value="item.code">\
                            </el-option>\
                      </el-select>\
                      <span>机构等级:</span>  \
                      <el-select v-model="level" placeholder="请选择" @change="selectChange">\
                          <el-option v-for="item in level_id" :key="item.code" :label="item.name" :value="item.code">\
                          </el-option>\
                      </el-select>\
                      <el-select v-model="hos" placeholder="请选择">\
                          <el-option v-for="item in hos_hierarchy" :key="item.code" :label="item.name" :value="item.code">\
                          </el-option>\
                      </el-select>\
                      <el-date-picker v-model="value4" type="month" placeholder="选择时间">\
                      </el-date-picker>\
                    <div class="search" @click="searchClick">搜  索</div>\
                    <span class="span">门急诊费>=999,000.00(999,000.00=上月门急诊次均费用*3)/住院费用>=999,000.00(999,000.00=上月住院次均费用*3)</span>\
                <el-table :data="tableData"  border style="width: 100%"  :data.native="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)">\
                    <el-table-column prop="patient_name" label="姓名">\
                    </el-table-column>\
                    <el-table-column prop="demographic_id" label="身份证号" >\
                    </el-table-column>\
                    <el-table-column label="性别">\
                    <template slot-scope="scope">\
                        <span v-if="scope.row.patient_sex == 1">男</span>\
                        <span v-else>女</span>\
                    </template>\
                    </el-table-column>\
                    <el-table-column prop="patient_age" label="年龄">\
                    </el-table-column>\
                    <el-table-column prop="EHR_000045" label="家庭地址" \
                    </el-table-column>\
                    <el-table-column fixed="right" label="操作">\
                        <template slot-scope="scope">\
                            <el-button @click="handleClick(scope.row)" type="text" size="small">查看详情</el-button>\
                        </template>\
                    </el-table-column>\
                </el-table>\
        <el-pagination \
                @size-change="handleSizeChange"\
                @current-change="handleCurrentChange" \
@ -57,7 +50,7 @@ Vue.component('comB', {
                :total="total">\
        </el-pagination>\
        </template>\
</div> ',
</div>',
    data: function () {
        return {
            currentPage: 1, //初始页
@ -65,29 +58,74 @@ Vue.component('comB', {
            pageSizeArr: [10, 20, 30, 50],
            tableData: [],
            total: 0,
            value: '门急诊',
            item:'',
            items:'',
            eventType: '0',
            item: '',
            hosLevel: '',
            option: [],
            options: [{
                value: '1',
                label: '门急诊'
            level: "",
            hos: "",
            value4:'2018-08',
            event_type: [{
                "code": '0',
                "name": '门急诊'
            }, {
                value: '2',
                label: '住院'
                "code": '1',
                "name": '住院'
            }],
            value4: '',
            
            hos_hierarchy: [{
                "code": '',
                "name": '全部'
            }, {
                "code": "1",
                "name": '甲等'
            }, {
                "code": "2",
                "name": '乙等'
            }, {
                "code": "3",
                "name": '丙等'
            }],
            level_id: [{
                "code": "",
                "name": '全部',
            }, {
                "code": "1",
                "name": '一级'
            }, {
                "code": "2",
                "name": '二级'
            }, {
                "code": "3",
                "name": '三级'
            },
            ]
        }
    },
    watch: {
       
    },
    mounted: function () {
        this.getData()
    },
    methods: {
        handleClick(row) {
        handleClick: function (row) {
            console.log(row);
        },
        selectChange(value) {
            console.log(value);
            if(value==3){
                this.hos_hierarchy.push({'code':'9',"name": '特等'})
                this.hos=''
            }else{
               if(this.level.code==3){
             this.hos=''
               }else{
                this.hos=''
                var vm=this.hos_hierarchy[0].code
                console.log(vm)
                this.hos_hierarchy.splice(4)
               }
            }
        },
        handleCurrentChange: function (val) { //page 当前页
            this.currentPage = val;
            this.getData()
@ -96,6 +134,13 @@ Vue.component('comB', {
            this.pageSize = val;
            this.initData()
        },
        searchClick: function () {
            console.log(this.eventType)
            console.log(this.level)
            console.log(this.hos)
            this.initData()
        },
        initData: function () {  //初始化数据
            this.currentPage = 1;
            this.getData()
@ -103,20 +148,25 @@ Vue.component('comB', {
        getData: function () {
            var vm = this;
            var params = {
                month: '2018-08',
                eventType: 0,
                hosLevel: this.hosLevel,
                hosHierarchy: this.hosHierarchy,
                month: this.value4,
                eventType: this.eventType,
                hosLevel: this.level,
                hosHierarchy:this.hos,
                size: 15,
                page: 1,
            }
            debugger
            GlobalEventBus.$emit('setLoading', {
                loading: true
            });
            bigDataOutApi.getHighCostList(params).then(function (res) {
                console.log(res)
                GlobalEventBus.$emit('setLoading');
                vm.tableData = res.detailModelList;
                vm.total = res.totalCount;
            }).catch(function (err) {
                console.log(err)
                GlobalEventBus.$emit('setLoading');
            })
        }
    }

+ 101 - 80
page/bigDataOut/js/handleChangeViewD.js

@ -1,109 +1,130 @@
Vue.component('comD',{
    template:' <div class="tab4">\
    <template>\
      <span>就诊类型:</span>  <el-select v-model="value" placeholder="请选择">\
            <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value">\
            </el-option>\
        </el-select>\
        <span>机构等级:</span>  \
        <el-select v-model="value" placeholder="请选择">\
                <el-option v-for="item in option" :key="item.value" :label="item.label" :value="item.value">\
                </el-option> \
        </el-select> \
        <a href="">查看药品字典     </a>\
        <el-select v-model="value" placeholder="请选择">\
                <el-option v-for="item in option" :key="item.value" :label="item.label" :value="item.value">\
                </el-option>\
        </el-select>\
        <div class="search">搜索</div>\
      <span>就诊时间:</span>    \
      <el-date-picker v-model="value6"type="daterange" range-separator="至" start-placeholder="开始日期"end-placeholder="结束日期">\
      </el-date-picker>\
      <span>药品名称:</span>  \
      <div class="modelSearch" >\
      <el-input paceholder="请输入药品名称"  v-model="drugName" clearable>\
      </el-input>\
      </div>\
        <a href="">  查看药品字典  </a>\
        <span>就诊类型:</span>  \
                      <el-select v-model="eventType" placeholder="请选择">\
                            <el-option v-for="item in event_type" :key="item.code" :label="item.name" :value="item.code">\
                            </el-option>\
                      </el-select>\
        <div class="search" @click="searchClick">搜索</div>\
    </template>\
    <el-table :data="tableData" border style="width: 100%"  :data.native="tableData.slice((currentPage-1)*pagesize,currentPage*pagesize)">\
            <el-table-column prop="province" label="就诊时间" width="180">\
    <el-table :data="tableData" border style="width: 100%"   :data.native="tableData.slice((currentPage-1)*pageSize,currentPage*pageSize)">\
            <el-table-column prop="event_date" label="就诊时间">\
                </el-table-column>\
        <el-table-column prop="name" label="姓名" width="140">\
        <el-table-column prop="patient_name" label="姓名">\
        </el-table-column>\
        <el-table-column prop="province" label="就诊类型" width="180">\
        <el-table-column label="就诊类型" width="140">\
                    <template slot-scope="scope">\
                        <span v-if="scope.row.every_type == 0">门急诊</span>\
                        <span v-else>住院</span>\
                    </template>\
                    </el-table-column>\
        <el-table-column prop="HDSD00_04_021" label="规格">\
        </el-table-column>\
        <el-table-column prop="province" label="规格" width="180">\
        <el-table-column prop="HDSD00_04_027" label="用法" >\
        </el-table-column>\
        <el-table-column prop="address" label="用法" width="380">\
        <el-table-column prop="HDSD00_04_028" label="总量">\
        </el-table-column>\
        <el-table-column prop="province" label="总量" width="180">\
        </el-table-column>\
        <el-table-column fixed="right" label="操作" width="180">\
        <el-table-column fixed="right" label="操作">\
            <template slot-scope="scope">\
            <el-button @click="handleClick(scope.row)" type="text" size="small">查看详情</el-button>\
            </template>\
        </el-table-column>\
    </el-table>\
    <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"\
    :page-sizes="[2,10, 20, 40]" :page-size="pagesize" layout="total,sizes,prev, pager, next, jumper"\
    :total="tableData.length">\
    <el-pagination \
    @size-change="handleSizeChange"\
    @current-change="handleCurrentChange" \
    :current-page="currentPage"\
    :page-sizes="pageSizeArr"\
    :page-size="pageSize" \
    layout="total,sizes,prev, pager, next, jumper"\
    :total="total">\
</el-pagination>\
</template>\
</div>\
    </div> ',
    data:function(){
        return{
    data: function () {
        return {
            currentPage: 1, //初始页
            pagesize:2,    //    每页的数据 
            tableData: [{
                date: '2016-05-03',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-02',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-04',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }, {
                date: '2016-05-01',
                name: '王小虎',
                province: '上海',
                city: '普陀区',
                address: '上海市普陀区金沙江路 1518 弄',
                zip: 200333
            }],
            options: [{
                value: '选项1',
                label: '外科'
            }, {
                value: '选项2',
                label: '住院'
            }],
            option: [{
                value: '选项1',
                label: '全部'
            pageSize: 10,    //    每页的数据 
            tableData: [],
            pageSizeArr: [10, 20, 30, 50],
            total: 0,
            pickerOptions1: {
                disabledDate(time) {
                  return time.getTime() > Date.now();
                },
              },
              event_type: [{
                "code": '0',
                "name": '门急诊'
            }, {
                value: '选项2',
                label: '选线一'
                "code": '1',
                "name": '住院'
            }],
            value: '全部'
              value6: '',
              drugName:'',
            eventType: '0',
        }
    },
    mounted: function () {
        this.getData()
    },
    methods: {
        handleSizeChange: function (size) {
            this.pagesize = size;
            console.log(this.pagesize)  //每页下拉显示数据
        handleCurrentChange: function (val) {
            this.currentPage = val;
            this.getData()
        },
        handleSizeChange: function (val) {
            this.pageSize = val;
            this.initData()
        },
        handleCurrentChange: function (currentPage) {
            this.currentPage = currentPage;
            console.log(this.currentPage)  //点击第几页
        initData: function () { //初始化
            this.currentPage = 1;
            this.getData()
        },
        handleClick(row) {
        searchClick: function () {
            console.log(this.eventType)
            console.log(this.drugName)
            this.initData()
        },
        getData: function () {
            var vm = this;
            var params = {
               start:'2018-08-01',
               end:'2018-08-31',
               drugName:this.drugName,
               eventType:this.eventType,
               size:15,
               page:1,
            }
            // GlobalEventBus.$emit('setLoading', {
            //     loading: true
            // }); //缓存效果
            bigDataOutApi.drugAnalysis(params).then(function (res) {
                console.log(res)
                GlobalEventBus.$emit('setLoading');
                vm.tableData = res.detailModelList;
                vm.total = res.totalCount;
            }).catch(function (err) {
                console.log(err)
                GlobalEventBus.$emit('setLoading');
            })
        },
        handleClick:function() {
            console.log(row);
          }
        }
    }
})

+ 1 - 1
page/bigDataOut/js/index.js

@ -78,7 +78,7 @@ new Vue({
				window.open('../../bigData/html/home.html')
				break;
				case '2-4':
				activeObj = 	{url:'../html/yibiaofenxi.html',text:'医保控费分析'};
				activeObj = 	{url:'../html/tableChange.html',text:'医保控费分析'};
				break;
				}
				if(!activeObj)return