/
home
/
techb158
/
ileadtechnology.com
/
SSM
/
public
/
js
/
student
/
idCard
/
/home/techb158/ileadtechnology.com/SSM/public/js/student/idCard
mkdir
upload
Name
Size
Mode
Actions
index.js
4578
0644
edit
dl
rm
index.js.map
150
0644
edit
dl
rm
Edit:
/home/techb158/ileadtechnology.com/SSM/public/js/student/idCard/index.js
(4578B)
(window.webpackJsonp=window.webpackJsonp||[]).push([[334],{dLQh:function(t,e,a){"use strict";a.r(e);var i={components:{},data:function(){return{idCardForm:new Form({batch_id:"",id_card_template_id:""},!1),batches:[],selected_batch:null,id_card_templates:[],selected_id_card_template:null,help_topic:""}},mounted:function(){helper.hasPermission("generate-student-id-card")||(helper.notAccessibleMsg(),this.$router.push("/dashboard")),this.getPreRequisite(),helper.showDemoNotification(["student"])},methods:{getPreRequisite:function(){var t=this,e=this.$loading.show();axios.get("/api/student/id-card/pre-requisite").then((function(a){t.batches=a.batches,t.id_card_templates=a.id_card_templates,e.hide()})).catch((function(t){e.hide(),helper.showErrorMsg(t)}))},onBatchSelect:function(t){var e=this.$loading.show();this.idCardForm.batch_id=t.id,e.hide()},onBatchRemove:function(t){this.idCardForm.batch_id=""},onIdCardTemplateSelect:function(t){var e=this.$loading.show();this.idCardForm.id_card_template_id=t.id,e.hide()},onIdCardTemplateRemove:function(t){this.idCardForm.id_card_template_id=""}},filters:{moment:function(t){return helper.formatDate(t)},momentDateTime:function(t){return helper.formatDateTime(t)}},computed:{authToken:function(){return helper.getAuthToken()},getURL:function(){return"/student/id-card/print?batch_id="+this.idCardForm.batch_id+"&token="+this.authToken+"&id_card_template_id="+this.idCardForm.id_card_template_id}}},r=a("KHd+"),s=Object(r.a)(i,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("div",{staticClass:"page-titles"},[a("div",{staticClass:"row"},[a("div",{staticClass:"col-12 col-sm-6"},[a("h3",{staticClass:"text-themecolor"},[t._v(t._s(t.trans("student.id_card")))])]),t._v(" "),a("div",{staticClass:"col-12 col-sm-6"},[a("div",{staticClass:"action-buttons pull-right"},[a("help-button",{on:{clicked:function(e){t.help_topic=""}}})],1)])])]),t._v(" "),a("div",{staticClass:"container-fluid"},[a("div",{staticClass:"row"},[a("div",{staticClass:"col-12"},[a("div",{staticClass:"card"},[a("div",{staticClass:"card-body p-4"},[a("form",{on:{submit:function(e){return e.preventDefault(),t.submit(e)},keydown:function(e){return t.idCardForm.errors.clear(e.target.name)}}},[a("div",{staticClass:"row"},[a("div",{staticClass:"col-12 col-sm-4"},[a("div",{staticClass:"form-group"},[a("label",{attrs:{for:""}},[t._v(t._s(t.trans("academic.batch")))]),t._v(" "),a("v-select",{attrs:{label:"name","group-values":"batches","group-label":"course_group","group-select":!1,name:"batch_id",id:"batch_id",options:t.batches,placeholder:t.trans("academic.select_batch")},on:{select:t.onBatchSelect,close:function(e){return t.idCardForm.errors.clear("batch_id")},remove:t.onBatchRemove},model:{value:t.selected_batch,callback:function(e){t.selected_batch=e},expression:"selected_batch"}},[t.batches.length?t._e():a("div",{staticClass:"multiselect__option",attrs:{slot:"afterList"},slot:"afterList"},[t._v("\n\t\t\t\t\t\t "+t._s(t.trans("general.no_option_found"))+"\n\t\t\t\t\t\t ")])]),t._v(" "),a("show-error",{attrs:{"form-name":t.idCardForm,"prop-name":"batch_id"}})],1)]),t._v(" "),a("div",{staticClass:"col-12 col-sm-4"},[a("div",{staticClass:"form-group"},[a("label",{attrs:{for:""}},[t._v(t._s(t.trans("academic.id_card_template")))]),t._v(" "),a("v-select",{attrs:{label:"name",name:"id_card_template_id",id:"id_card_template_id",options:t.id_card_templates,placeholder:t.trans("academic.select_id_card_template")},on:{select:t.onIdCardTemplateSelect,close:function(e){return t.idCardForm.errors.clear("id_card_template_id")},remove:t.onIdCardTemplateRemove},model:{value:t.selected_id_card_template,callback:function(e){t.selected_id_card_template=e},expression:"selected_id_card_template"}},[t.id_card_templates.length?t._e():a("div",{staticClass:"multiselect__option",attrs:{slot:"afterList"},slot:"afterList"},[t._v("\n\t\t\t\t\t\t "+t._s(t.trans("general.no_option_found"))+"\n\t\t\t\t\t\t ")])]),t._v(" "),a("show-error",{attrs:{"form-name":t.idCardForm,"prop-name":"id_card_template_id"}})],1)])]),t._v(" "),t.idCardForm.batch_id&&t.idCardForm.id_card_template_id?a("div",{staticClass:"form-group"},[a("a",{staticClass:"btn btn-info",attrs:{href:t.getURL,target:"_blank"}},[t._v(t._s(t.trans("student.generate_id_card")))])]):t._e()])])])])])]),t._v(" "),a("right-panel",{attrs:{topic:t.help_topic}})],1)}),[],!1,null,null,null);e.default=s.exports}}]); //# sourceMappingURL=index.js.map?id=8bd38e90f443cd29fd44
Save
cmd:
run