2022-04-21 21:12:34 +08:00
|
|
|
/* global I18n */
|
|
|
|
|
|
|
|
import TurbolinksAdapter from 'vue-turbolinks';
|
|
|
|
import Vue from 'vue/dist/vue.esm';
|
|
|
|
import ProtocolContainer from '../../vue/protocol/container.vue';
|
|
|
|
|
|
|
|
Vue.use(TurbolinksAdapter);
|
|
|
|
Vue.prototype.i18n = window.I18n;
|
2022-05-13 19:07:50 +08:00
|
|
|
Vue.prototype.ActiveStoragePreviews = window.ActiveStoragePreviews;
|
2022-04-21 21:12:34 +08:00
|
|
|
|
|
|
|
window.initProtocolComponent = () => {
|
|
|
|
Vue.prototype.dateFormat = $('#protocolContainer').data('date-format');
|
2022-05-03 21:18:48 +08:00
|
|
|
|
2022-04-21 21:12:34 +08:00
|
|
|
new Vue({
|
|
|
|
el: '#protocolContainer',
|
|
|
|
components: {
|
|
|
|
'protocol-container': ProtocolContainer
|
|
|
|
},
|
|
|
|
data() {
|
|
|
|
return {
|
2022-06-03 17:52:10 +08:00
|
|
|
protocolUrl: $('#protocolContainer').data('protocol-url')
|
2022-04-21 21:12:34 +08:00
|
|
|
};
|
|
|
|
}
|
|
|
|
});
|
|
|
|
};
|
|
|
|
|
|
|
|
initProtocolComponent();
|