( async function(){

    Vue.prototype.$types = window.ctp.types;
    Vue.prototype.$accounts = window.ctp.accounts;

    let app = new Vue({
        el : '#dashboard',
        data :{
            jobCard : {}
        },
        computed: {
            getStatus: function() {
                return `badge-${this.jobCard.status}`;
            },
            getInvStatus: function() {
                return `badge-${this.jobCard.inventoryStatus}`;
            }
        },
        methods : {
            onCardSelect : function ( id, card ) {
//               $.ajax({
//                   url: `/ctp/rest/job-cards/find/${id}`,
//                   method: 'GET',
//                   contentType: 'application/json',
//                   dataType: 'json',
//                   success: ( data )  => {
//                     this.jobCard = data;
//                   },
//                   error : function ( err ){
//                       alert( err );
//                   }
//               })
console.log("hello")

            }
        },
        mounted : function () {

        }
    })


})(jQuery);