default.js 823 Bytes
Newer Older
fukai committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
import Api from '~/service/Api';
import commonFunctions from '~/mixin/commonFunctions.js';
import commonDepend from "~/mixin/commonDepend";
import { cloneDeep } from "lodash";
import Pts from '~/components/business/commonModel/Pts.js';

export default {
	mixins: [commonFunctions,commonDepend],
	methods: {
    docprbrolDefault() {
			if (this.model.btdgrp.rec.docprbrol == "ADT"){
				this.model.btdgrp.prb = cloneDeep(this.model.ltdgrp.adt);
				this.model.btdgrp.prb.pts.rol = "PRB";
				
			}else if (this.model.btdgrp.rec.docprbrol == "BE2"){
				this.model.btdgrp.prb = cloneDeep(this.model.ltdgrp.be2);
				this.model.btdgrp.prb.pts.rol = "PRB";
			}else{
				const restObj = {
					pts: new Pts().data,
				}
				this.model.btdgrp.prb = cloneDeep(restObj);
				this.model.btdgrp.prb.pts.rol = "PRB";
			}
		},

	}
}