1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- var template = ''
- $.ajax('../../../component/statistics/LascCervicalPreliminaryScreenEntity/index.html', {
- data: {},
- dataType: 'html',
- cache: false,
- timeout: 60000,
- async: false,
- error: function (res) {},
- success: function (res) {
- template = res
- }
- })
- Vue.component('lasc-cervical-preliminary-screen-entity', {
- template: template,
- props: ['data'],
- data: function () {
- return {
- readonlyTwo: 1,
- readonly: true,
- isShowPicker: false,
- columns: [],
- pickType: '',
- curItem: '',
- isShowDatePicker: false,
- activeDateField: '',
- date: '',
- minDate: moment().add(-100, 'year').toDate(),
- form: {
- screenId: '', //两癌筛查id
- preliminaryScreenResults: '', //
- preliminaryScreenOrg: docInfo.hospitalName, //检查机构
- preliminaryScreenUser: docInfo.name, //检查人员
- preliminaryScreenTime: '' //检查时间
- }
- }
- },
- methods: {},
- watch:{
- data:{
- handler(newVal,oldVal){
-
- var vm = this
- if (this.readonly && !this.form.preliminaryScreenOrg) {
- this.form = {
- screenId: '', //两癌筛查id
- preliminaryScreenResults: '', //
- preliminaryScreenOrg: '', //检查机构
- preliminaryScreenUser: '', //检查人员
- preliminaryScreenTime: '' //检查时间
- }
- } else {
- this.form = _.assign(this.form, this.data.value[0])
- this.form.screenId = this.data.value[0] && this.data.value[0].screenId
- }
-
- httpRequest
- .get('doctor/twoCancers/getPreliminaryScreenResults', {
- data: {
- screenId: this.form.screenId
- }
- })
- .then(function (ress) {
- vm.form.preliminaryScreenResults = ress.data || '1'
- })
- },
- deep:true
- }
- },
- mounted() {
- var vm = this
- if (this.readonly && !this.form.preliminaryScreenOrg) {
- this.form = {
- screenId: '', //两癌筛查id
- preliminaryScreenResults: '', //
- preliminaryScreenOrg: '', //检查机构
- preliminaryScreenUser: '', //检查人员
- preliminaryScreenTime: '' //检查时间
- }
- } else {
- this.form = _.assign(this.form, this.data.value[0])
- this.form.screenId = this.data.value[0] && this.data.value[0].screenId
- }
- httpRequest
- .get('doctor/twoCancers/getPreliminaryScreenResults', {
- data: {
- screenId: this.form.screenId
- }
- })
- .then(function (ress) {
- vm.form.preliminaryScreenResults = ress.data || '1'
- })
- }
- })
|