chunk-49ed9468.064e25d7.js 12 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-49ed9468","chunk-49ed9468","chunk-01d1e578","chunk-2d0df437"],{"13d6":function(e,t,r){"use strict";r("8e69")},"56d7d":function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e._self._c;return t("div",{staticClass:"group-wraper"},[t("div",{staticClass:"row"},[t("a-button",{attrs:{type:"primary",icon:"plus"},on:{click:e.addTeam}},[e._v("添加队")])],1),e._l(e.teams,(function(r,a){return t("div",{key:a,staticClass:"team"},[t("div",{staticClass:"row spacebw"},[t("span",[e._v("小队"+e._s(a+1))]),t("div",[t("a-button",{attrs:{type:"primary",icon:"plus",size:"small"},on:{click:function(t){return e.addGroup(a)}}},[e._v("添加小组")])],1)]),e._l(r.groups,(function(o,n){return t("div",{key:n,staticClass:"group"},[t("div",{staticClass:"row spacebw"},[t("span",[e._v("小组"+e._s(n+1))]),t("div",[t("a-button",{attrs:{type:"primary",icon:"plus",size:"small"},on:{click:function(t){return e.addRole(a,n)}}},[e._v("添加角色")]),r.groups.length>1?t("a-button",{staticClass:"del-btn",attrs:{type:"outline",size:"small"},on:{click:function(t){return e.delGroup(a,n)}}},[e._v("删除")]):e._e()],1)]),t("div",{staticClass:"roles"},e._l(o.roles,(function(r,o){return t("div",{key:o,staticClass:"role"},[e._v("\n "+e._s(e._f("rolestr")(r))+"\n\n "),t("a-icon",{staticClass:"close",attrs:{type:"close"},on:{click:function(t){return e.delRole(a,n,o)}}})],1)})),0)])})),t("a-icon",{staticClass:"close",attrs:{type:"close"},on:{click:function(t){return e.delTeam(a)}}})],2)})),t("role-modal",{ref:"modalForm",on:{ok:e.modalFormOk}})],2)},o=[],n=r("b1d8"),i=r("b441"),l={components:{roleModal:n["default"]},filters:{rolestr:function(e){i["a"].AddableNames,i["a"].VehicleIds;var t=i["a"].VehicleNames;return-1!=e.vehicleid?t[e.vehicleid]+"x"+e.count:i["a"].Roles[e.role+""]+"x"+e.count}},props:{value:{type:Array,default:function(){return[]},required:!1}},watch:{value:function(e){e&&e instanceof Array&&(this.teams=this.ParseTeams(e))}},data:function(){return{teams:[{groups:[{roles:[]}]}]}},computed:{maxOptions:function(){var e=2,t=2,r=2,a=2,o=2,n=2,i=2;return{MaxCoPilot:e,MaxCrew:t,MaxZ8:r,MaxZ9:a,MaxZ10:o,MaxM171:n,MaxY12:i}}},methods:{ParseTeams:function(e){for(var t=[],r=e.length,a={},o=0;o<r;o++){var n=e[o],i=a[n.team];if(void 0==i){t.push({groups:[]});var l=t.length-1;a[n.team]={index:l,gmap:{}},i=a[n.team]}var s=t[i.index],c=i.gmap[n.group];if(void 0==c){var u={roles:[]};s.groups.push(u),i.gmap[n.group]=s.groups.length-1,c=i.gmap[n.group]}var p=s.groups[c];if(void 0!=n.num){var d=!1,h=p.roles.length;while(h--)if(p.roles[h].role==n.role&&p.roles[h].vehicleid==n.vehicleid){d=!0,p.roles[h].count+=1;break}d||p.roles.push({role:n.role,count:1,vehicleid:n.vehicleid})}}return t},addTeam:function(){this.teams.length;this.teams.push({groups:[{roles:[]}]}),this.emitChange()},emitChange:function(){this.$emit("change",this.getTeamArr(this.teams))},getTeamArr:function(e){var t=[];return e.forEach((function(e,r){e.groups.forEach((function(e,a){if(e.roles.length>0)e.roles.forEach((function(e,o){for(var n=e.count,i=0;i<n;i++){var l={team:r+1,group:a+1,role:e.role,num:i+1,vehicleid:e.vehicleid};t.push(l)}}));else{var o={team:r+1,group:a+1,role:void 0,num:void 0,vehicleid:-1};t.push(o)}}))})),t},delTeam:function(e){this.teams.splice(e,1),this.emitChange()},addGroup:function(e){var t=this.teams;t[e].groups.push({roles:[]})},addRole:function(e,t){this.addingTid=e,this.addingGid=t,this.$refs.modalForm.show(this.maxOptions)},delRole:function(e,t,r){var a=this.teams[e].groups[t].roles;a.splice(r,1),this.emitChange()},delGroup:function(e,t){this.teams[e].groups.splice(t,1),this.emitChange()},modalFormOk:function(e){for(var t=this.teams[this.addingTid].groups[this.addingGid].roles,r=e.length,a=0;a<r;a++){for(var o=e[a],n=t.length,i=!1,l=0;l<n;l++){var s=t[l];if(s.role==o.role&&s.vehicleid==o.vehicleid){s.count+=o.count,i=!0;break}}i||t.push(o)}this.emitChange()}}},s=l,c=(r("13d6"),r("2877")),u=Object(c["a"])(s,a,o,!1,null,"14bf1562",null);t["default"]=u.exports},"88bc":function(e,t,r){(function(t){var r=1/0,a=9007199254740991,o="[object Arguments]",n="[object Function]",i="[object GeneratorFunction]",l="[object Symbol]",s="object"==typeof t&&t&&t.Object===Object&&t,c="object"==typeof self&&self&&self.Object===Object&&self,u=s||c||Function("return this")();function p(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function d(e,t){var r=-1,a=e?e.length:0,o=Array(a);while(++r<a)o[r]=t(e[r],r,e);return o}function h(e,t){var r=-1,a=t.length,o=e.length;while(++r<a)e[o+r]=t[r];return e}var m=Object.prototype,f=m.hasOwnProperty,v=m.toString,b=u.Symbol,g=m.propertyIsEnumerable,w=b?b.isConcatSpreadable:void 0,C=Math.max;function y(e,t,r,a,o){var n=-1,i=e.length;r||(r=j),o||(o=[]);while(++n<i){var l=e[n];t>0&&r(l)?t>1?y(l,t-1,r,a,o):h(o,l):a||(o[o.length]=l)}return o}function x(e,t){return e=Object(e),k(e,t,(function(t,r){return r in e}))}function k(e,t,r){var a=-1,o=t.length,n={};while(++a<o){var i=t[a],l=e[i];r(l,i)&&(n[i]=l)}return n}function _(e,t){return t=C(void 0===t?e.length-1:t,0),function(){var r=arguments,a=-1,o=C(r.length-t,0),n=Array(o);while(++a<o)n[a]=r[t+a];a=-1;var i=Array(t+1);while(++a<t)i[a]=r[a];return i[t]=n,p(e,this,i)}}function j(e){return A(e)||O(e)||!!(w&&e&&e[w])}function M(e){if("string"==typeof e||S(e))return e;var t=e+"";return"0"==t&&1/e==-r?"-0":t}function O(e){return R(e)&&f.call(e,"callee")&&(!g.call(e,"callee")||v.call(e)==o)}var A=Array.isArray;function z(e){return null!=e&&N(e.length)&&!T(e)}function R(e){return G(e)&&z(e)}function T(e){var t=F(e)?v.call(e):"";return t==n||t==i}function N(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=a}function F(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function G(e){return!!e&&"object"==typeof e}function S(e){return"symbol"==typeof e||G(e)&&v.call(e)==l}var $=_((function(e,t){return null==e?{}:x(e,d(y(t,1),M))}));e.exports=$}).call(this,r("c8ba"))},"8e69":function(e,t,r){},a726:function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e._self._c;return t("a-checkbox-group",e._b({attrs:{options:e.options,value:e.checkboxArray},on:{change:e.onChange}},"a-checkbox-group",e.$attrs,!1))},o=[],n={name:"JCheckbox",props:{value:{type:String,required:!1},options:{type:Array,required:!0}},data:function(){return{checkboxArray:this.value?this.value.split(","):[]}},watch:{value:function(e){this.checkboxArray=e?this.value.split(","):[]}},methods:{onChange:function(e){this.$emit("change",e.join(","))}},model:{prop:"value",event:"change"}},i=n,l=r("2877"),s=Object(l["a"])(i,a,o,!1,null,null,null);t["default"]=s.exports},b1d8:function(e,t,r){"use strict";r.r(t);var a=function(){var e=this,t=e._self._c;return t("j-modal",{attrs:{title:e.title,width:e.width,visible:e.visible,cancelText:"关闭"},on:{ok:e.handleOk,cancel:e.handleCancel}},[t("a-spin",{attrs:{spinning:e.confirmLoading}},[t("a-form",{attrs:{form:e.form}},[t("a-row",{attrs:{gutter:24}},[t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"机务",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["Crew"],expression:"['Crew']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"直8飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["z8"],expression:"['z8']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"直9飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["z9"],expression:"['z9']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"直11飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["z10"],expression:"['z10']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"米171飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["m171"],expression:"['m171']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"运12飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["y12"],expression:"['y12']"}]})],1)],1),t("a-col",{attrs:{span:8}},[t("a-form-item",{attrs:{label:"运7飞行员",labelCol:e.labelCol,wrapperCol:e.wrapperRowCol}},[t("a-input-number",{directives:[{name:"decorator",rawName:"v-decorator",value:["y7"],expression:"['y7']"}]})],1)],1)],1)],1)],1)],1)},o=[],n=(r("0fea"),r("88bc"),r("ca00"),r("a726")),i=r("b441"),l={name:"UserModal",components:{JCheckbox:n["default"]},data:function(){return{form:this.$form.createForm(this),title:"选择参训角色",width:705,visible:!1,model:{},labelCol:{xs:{span:24},sm:{span:12}},wrapperRowCol:{xs:{span:24},sm:{span:12}},confirmLoading:!1,maxOptoins:{MaxCoPilot:0,MaxCrew:0,MaxZ8:0,MaxZ9:0,MaxZ10:0,MaxM171:0,MaxY12:0}}},created:function(){},methods:{show:function(e){this.maxOptoins=e,this.form.resetFields(),this.visible=!0},close:function(e){this.$emit("close",e),this.visible=!1},handleOk:function(){var e=this;this.form.validateFields((function(t,r){t||(e.$emit("ok",e.parseType(r)),e.visible=!1)}))},parseType:function(e){var t=[],r=i["a"].AddableNames,a=i["a"].VehicleIds;for(var o in e)e[o]&&t.push({role:r[o],vehicleid:a[o],count:e[o]});return t},handleCancel:function(){this.close()}}},s=l,c=r("2877"),u=Object(c["a"])(s,a,o,!1,null,null,null);t["default"]=u.exports},b441:function(e,t,r){"use strict";var a=["舟山普陀机场","喀什机场","阿坝红原机场","太谷机场","博鳌机场","昌都机场","山东聊城军事机场","湘阴县军事机场","中江机场","吉林通化机场","泸州机场","山西临汾机场","山西运城机场","新疆乌鲁木齐水磨沟机场","宁夏回族自治区银川市魏家桥机场","北京首都国际机场","云南普尔机场"],o=["雨天","晴天","雪天","沙尘","雷暴"],n=["白天","黑夜"],i=["未定义","总参谋长","支队长","融合力量","远航终端","参谋终端","航管员","气象员","战勤","导调","领航","未定义","未定义","未定义","未定义","未定义","未定义","未定义","未定义","未定义","飞行员","机务"],l={Crew:21,z8:20,z9:20,z10:20,m171:20,y12:20,y7:20},s={z8:0,z9:1,z10:2,m171:3,y12:4,y7:5,Crew:-1},c=["直8","直9","直11","米171","运12","运7"],u=["岛礁起降","跟进飞行","编队飞行","航行转场飞行","空中投送飞行","巡逻侦查飞行","跟踪追击飞行","海上搜索飞行","灭火飞行","战斗起飞","静止着舰飞行","行进着舰飞行","全轮着陆机降飞行","悬停跳下机降飞行","悬停索降飞行","小速度掠地跳下机降飞行","舱门射击飞行","海上维权执法取证","宣传震慑飞行","跟踪追捕飞行","以执勤为背景的联合演练","以处突为背景的联合演练","以反恐为背景的联合演练","以海上维权执法为背景的联合演练","以抢险救援为背景的联合演练","以防卫作战为背景的联合演练","人员突发情况指挥协同","直升机突发情况指挥协同","环境突发情况指挥协同","航管突发情况指挥协同","任务中突发情况指挥协同"],p=[0,-1,-1,[0,8],-1,1,3,0,-1,-1,0,0,-1,-1,-1,-1,0,0,1,0,1,1,1,0,0,1];t["a"]={Maps:a,Weathers:o,Roles:i,VehicleNames:c,VehicleIds:s,Subjects:u,Subject2Map:p,AddableNames:l,TimeName:function(e){return 14==e?n[0]:21==e?n[1]:void 0}}}}]);