12 |
- (function(e){function t(t){for(var n,r,i=t[0],c=t[1],d=t[2],u=0,h=[];u<i.length;u++)r=i[u],Object.prototype.hasOwnProperty.call(o,r)&&o[r]&&h.push(o[r][0]),o[r]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);s&&s(t);while(h.length)h.shift()();return l.push.apply(l,d||[]),a()}function a(){for(var e,t=0;t<l.length;t++){for(var a=l[t],n=!0,i=1;i<a.length;i++){var c=a[i];0!==o[c]&&(n=!1)}n&&(l.splice(t--,1),e=r(r.s=a[0]))}return e}var n={},o={app:0},l=[];function r(t){if(n[t])return n[t].exports;var a=n[t]={i:t,l:!1,exports:{}};return e[t].call(a.exports,a,a.exports,r),a.l=!0,a.exports}r.m=e,r.c=n,r.d=function(e,t,a){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},r.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(r.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(a,n,function(t){return e[t]}.bind(null,n));return a},r.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="";var i=window["webpackJsonp"]=window["webpackJsonp"]||[],c=i.push.bind(i);i.push=t,i=i.slice();for(var d=0;d<i.length;d++)t(i[d]);var s=c;l.push([0,"chunk-vendors"]),a()})({0:function(e,t,a){e.exports=a("56d7")},"56d7":function(e,t,a){"use strict";a.r(t);a("e260"),a("e6cf"),a("cca6"),a("a79d");var n=a("2b0e"),o=a("5c96"),l=a.n(o),r=(a("0fae"),a("bc3a")),i=a.n(r),c=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{attrs:{id:"app"}},[a("index")],1)},d=[],s=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"main"},[a("div",{staticStyle:{"margin-bottom":"15px"}},[a("el-select",{staticStyle:{"margin-right":"15px"},attrs:{placeholder:"选择排班周"},model:{value:e.Schedulingtime,callback:function(t){e.Schedulingtime=t},expression:"Schedulingtime"}},e._l(e.options,(function(e){return a("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1),a("el-select",{staticStyle:{"margin-right":"15px"},attrs:{disabled:!1,placeholder:"选择机构"},on:{change:e.selectmechanism},model:{value:e.mechanism,callback:function(t){e.mechanism=t},expression:"mechanism"}},e._l(e.mechanismList,(function(e){return a("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1),a("el-select",{attrs:{disabled:e.isdocter,placeholder:"选择医生"},on:{change:e.selectdocter},model:{value:e.docter,callback:function(t){e.docter=t},expression:"docter"}},e._l(e.docterList,(function(e){return a("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1),a("el-button",{staticStyle:{"margin-left":"15px"},attrs:{type:"primary"},on:{click:e.submitsave}},[e._v("保存")])],1),a("el-table",{staticStyle:{width:"1200px"},attrs:{data:e.dataList,border:""}},[a("el-table-column",{attrs:{prop:"date",label:"时段"}}),a("el-table-column",{attrs:{label:"周一"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{attrs:{disabled:"other"==e.tableData[t.$index].monday},on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].monday,callback:function(a){e.$set(e.tableData[t.$index],"monday",a)},expression:"tableData[scope.$index].monday"}})]}}])}),a("el-table-column",{attrs:{prop:"name",label:"周二"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].tuesday,callback:function(a){e.$set(e.tableData[t.$index],"tuesday",a)},expression:"tableData[scope.$index].tuesday"}})]}}])}),a("el-table-column",{attrs:{prop:"name",label:"周三"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].wednesday,callback:function(a){e.$set(e.tableData[t.$index],"wednesday",a)},expression:"tableData[scope.$index].wednesday"}})]}}])}),a("el-table-column",{attrs:{prop:"name",label:"周四"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].thursday,callback:function(a){e.$set(e.tableData[t.$index],"thursday",a)},expression:"tableData[scope.$index].thursday"}})]}}])}),a("el-table-column",{attrs:{prop:"name",label:"周五"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].friday,callback:function(a){e.$set(e.tableData[t.$index],"friday",a)},expression:"tableData[scope.$index].friday"}})]}}])}),a("el-table-column",{attrs:{prop:"name",label:"周六"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].saturday,callback:function(a){e.$set(e.tableData[t.$index],"saturday",a)},expression:"tableData[scope.$index].saturday"}})]}}])}),a("el-table-column",{attrs:{prop:"address",label:"周日"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-checkbox",{on:{change:function(a){return e.mondaychange(t.$index,t.row)}},model:{value:e.tableData[t.$index].sunday,callback:function(a){e.$set(e.tableData[t.$index],"sunday",a)},expression:"tableData[scope.$index].sunday"}})]}}])})],1)],1)},u=[],h=(a("b0c0"),{name:"index",data:function(){return{org_id:"",isorg:!1,isdocter:!1,mechanismList:[],docterList:[],options:[],mechanism:"",Schedulingtime:"",docter:"",docter_id:"",tableData:[{date:"上午",monday:!1,tuesday:!1,wednesday:!1,thursday:!1,friday:!1,saturday:!1,sunday:!1},{date:"下午",monday:!1,tuesday:!1,wednesday:!1,thursday:!1,friday:!1,saturday:!1,sunday:!1},{date:"晚上",monday:!1,tuesday:!1,wednesday:!1,thursday:!1,friday:!1,saturday:!1,sunday:!1}]}},computed:{dataList:function(){var e=this.tableData;return e}},beforeCreate:function(){},created:function(){this.getComSchedule();var e=new Date;e.setTime(e.getTime()+864e5*(7-e.getDay()));for(var t=0;t<4;t++){e.setTime(e.getTime()+864e5);var a=e.getFullYear()+"-"+(e.getMonth()+1<10?"0"+(e.getMonth()+1):e.getMonth()+1)+"-"+(e.getDate()<10?"0"+e.getDate():e.getDate());e.setTime(e.getTime()+864e5*(e.getDay()+5));var n=e.getFullYear()+"-"+(e.getMonth()+1<10?"0"+(e.getMonth()+1):e.getMonth()+1)+"-"+(e.getDate()<10?"0"+e.getDate():e.getDate());this.options.push({value:a+"至"+n,label:a+"至"+n})}},methods:{selectmechanism:function(e){var t=this;if(""==this.Schedulingtime){this.mechanism="";var a=this.$createElement;return this.$notify({title:"提示",message:a("i",{style:"color: red"},"请先选择排班周时间"),duration:2500}),!1}this.org_id=e,this.http.get("/getComSchedule",{params:{docter_id:this.docter_id,org_id:e,time:this.Schedulingtime}}).then((function(e){console.log(e),200==e.data.code&&(t.tableData=e.data.data.docter,console.log(t.tableData))}))},selectdocter:function(e){},mondaychange:function(e,t){console.log(e),console.log(t)},submitsave:function(){console.log(this.tableData),console.log(this.org_id),console.log(this.docter_id),console.log(this.Schedulingtime),this.http.get("/setDocChedule",{params:{docter_id:this.docter_id,org_id:this.org_id,time:this.Schedulingtime,schedulingtime:this.tableData}}).then((function(e){console.log(e)}))},getComSchedule:function(){var e=this;this.http.get("/cdms/getScheduleInfo",{params:{docter_id:47}}).then((function(t){console.log(t),200==t.data.code&&(2==t.data.data.role?(e.docterList.push({label:t.data.data.name,value:t.data.data.user_id}),e.docter=t.data.data.name,e.docter_id=t.data.data.user_id,e.isdocter=!0,e.mechanismList=t.data.data.list):e.isorg=!0)}))}}}),f=h,p=a("2877"),m=Object(p["a"])(f,s,u,!1,null,"6a801327",null),b=m.exports,y={name:"App",components:{index:b}},g=y,x=(a("5c0b"),Object(p["a"])(g,c,d,!1,null,null,null)),v=x.exports;n["default"].use(l.a),n["default"].prototype.http=i.a,n["default"].config.productionTip=!1,new n["default"]({render:function(e){return e(v)}}).$mount("#app")},"5c0b":function(e,t,a){"use strict";a("9c0c")},"9c0c":function(e,t,a){}});
- //# sourceMappingURL=app.e96ab16e.js.map
|