{"size": 20149, "ext": "js", "max_stars_repo_path": "Public/js/build/home/episodes.min.js", "max_stars_repo_name": "cgpipline/strack3", "max_stars_repo_stars_event_min_datetime": "2019-06-14T10:52:52.000Z", "max_stars_repo_stars_event_max_datetime": "2021-12-11T20:49:12.000Z", "max_issues_repo_path": "Public/js/build/home/episodes.min.js", "max_issues_repo_name": "cine-use/strack3", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "Public/js/build/home/episodes.min.js", "max_forks_repo_name": "cine-use/strack3", "max_forks_repo_forks_event_min_datetime": "2019-06-14T09:35:13.000Z", "max_forks_repo_forks_event_max_datetime": "2021-04-16T15:39:09.000Z"}
{"max_stars_count": 24, "max_issues_count": null, "max_forks_count": 17, "avg_line_length": 20149.0, "max_line_length": 20149, "alphanum_fraction": 0.7160653134}
$(function(){function e(e,i,a,s,n){t(Strack.build_filter({project_id:["eq",e],active:["eq",1]},{},{},{},"and",{},{},[{sortName:"created",sortOrder:"desc"}]),e,i,a,s,n),m()}function t(e,a,n,o,d,c){var r=$("#lseq_list");Strack.G.Gfilter_list.episodes=e,$.ajax({type:"POST",url:EpisodeVariable.episodeData,data:{filter:JSON.stringify(e),project_id:a,type:n,pagenum:o,pagesize:d},beforeSend:function(){$(".seq-left-wrap").append(Strack.loading_dom("white","","lseq"))},success:function(l){var p=JSON.parse(l),u=p.total,h="";if(u>0)if(w)switch(p.rows.forEach(function(e){h+=i(e)}),c){case"new":r.on("scroll",function(){if((this.scrollTop||this.scrollTop)==(this.scrollHeight||this.scrollHeight)-(this.clientHeight||this.clientHeight)){o++;var i=Math.ceil(u/d);o<=i&&t(e,a,n,o,d,"more")}}),r.empty().append(h);break;case"more":r.append(h)}else{var m=e.sort[0].sortName,f="";switch(m){case"status_id":f="status_name";break;default:f=m}var _=Strack.array_group(p.rows,f);for(var g in _){var S="";_[g].forEach(function(e){S+=i(e)}),h+=s(g,S)}r.off("scroll"),r.empty().append(h)}else r.empty().append('<div class="datagrid-empty-no">'+Strack.DataNullTip(5020)+"</div>");$("#st-load_lseq").remove()}})}function i(e){var t="";return t+='<div class="seq-left-items"><a href="javascript:;" class="list-item-main" onclick="obj.ShowItem(this)" data-epsid="'+e.epis_id+'"><div id="thumb_left_50_'+e.epis_id+'" class="sleft-items-thumb">'+a(e.thumb)+'</div><div class="sleft-items-content"><div class="sleft-items-ctop"><span class="items-ctop-icon aign-left"><i class="icon-small_shots icon-left-p"></i></span><span class="items-ctop-title aign-left text-ellipsis">'+e.epis_name+'</span></div><div class="sleft-items-cbottom"><span class="items-ctop-status aign-left"><i class="'+e.status_icon+' icon-left" style="color:#'+e.status_color+'"></i>'+e.status_name+"</span></div></div></a></div>"}function a(e){var t=JSON.parse(e);return t.thumb?'<img src="'+StrackPHP.UPLOADS+"/EpisodesThumb/"+t.thumb+'_min.jpg">':'<div class="task-thumb-null">'+Strack.ProjTaskIcon(P)+"</div>"}function s(e,t){var i="";return i+='<div class="seq-left-group"><a href="javascript:;" class="sleft-ghead" onclick="obj.ToggleGroup(this)"><i class="icon-uniF106 sidebar-icon icon-left"></i>'+e+'</a><div class="sleft-gitem">'+t+"</div></div>"}function n(e,t,i){var a=Strack.build_filter({project_id:["eq",e],active:["eq",1]},{},{},{},"and",{},{},[{sortName:"created",sortOrder:"desc"}]);Strack.G.Gfilter_data.episodes=a,$("#data_epis").datagrid({url:EpisodeVariable.DataEpisodes,fitColumns:!1,height:Strack.panel_height(".pseqlist",0),rowheight:49,differhigh:!1,singleSelect:!1,adaptive:{dom:".pseqlist",min_width:510,exth:0,domresize:1},DragSelect:!0,DataNull:Strack.DataNullTip(t),queryParams:{filter:JSON.stringify(a),ptype:t,pid:e},frozenColumns:[[{field:"epis_id",title:StrackPHP.SequenceId,checkbox:!0}]],columns:[i],toolbar:"#tb_list",pagination:!0,pageSize:100,pageList:[100,200,300,400,500,"All"],pageNumber:1,pagePosition:"bottom",remoteSort:!1,onDblClickRow:function(t,i){Strack.SideColumnOpen(i.epis_id,50,50,e,"data_epis")},onRowContextMenu:function(e,t,i){Strack.grid_clipboard(e.target),e.preventDefault(),$("#st_menu_episodes").menu("show",{left:e.pageX,top:e.pageY})}})}function o(e,t){$.ajax({type:"POST",url:StrackPHP.DynamicFields,data:{project_id:e,type:t},dataType:"json",success:function(i){var a=[];i.forEach(function(e,t){e&&a.push(Strack.DynamicFieldset(50,e,t,""))}),n(e,t,a)}})}function d(e,t,i){c(e,t,i),r(e,t,i),Strack.AjaxHfields(i,t,e,StrackPHP.DomEPHfields,"episodes",50,0),$(".special.cards .image").dimmer({on:"hover"})}function c(e,t,i){$.ajax({type:"POST",url:EpisodeVariable.LoadItemImg,data:{seq_id:t,project_id:e,type:i},beforeSend:function(){$(".item-thumb-warp").prepend(Strack.loading_dom("white","","thumb"))},success:function(e){var a=JSON.parse(e),s=$("#thumb_show_"+i+"_"+t),n="";$("#st-load_thumb").remove(),"no"==PARSE_VAR.rules.upload_thumb.allow&&$("#epis_up_thumb").empty().html(StrackPHP.Thumbnail),400==parseInt(a.status)?(n='<div class="task-thumb-null">'+Strack.ProjTaskIcon(i)+"</div>",s.empty().append(n)):(n=StrackPHP.UPLOADS+"/EpisodesThumb/"+a.thumb+"_max.jpg",s.empty().append('<img src="'+n+'">'))}})}function r(e,t,i){$.ajax({type:"POST",url:EpisodeVariable.LoadItemBase,data:{seq_id:t,project_id:e,type:i},success:function(e){var i=JSON.parse(e),a="",s="";a+=Strack.ProjTaskIcon(i.type),a+='<span class="taskm_content eb_epis_name_'+t+'">'+i.epis_name+"</span>",$("#seq_d_name").empty().append(a);var n=l(i.type,i.project_id,i.epis_name);$(".item-breadcrumb-left").empty().append(n),"yes"==PARSE_VAR.rules.episodes_action.allow&&(s=' <a href="javascript:;" class="mini ui button details-icon down-panel ah_tiemlog_add" onclick="Strack.ClientAction(this)" data-type="50" data-linkid="'+t+'"> <i class="icon-uniE6BB down-panel"></i> </a>'),$(".item-breadcrumb-right").empty().append(s)}})}function l(e,t,i){var a="";return a+='<div class="ui small breadcrumb">',a+=Strack.ProjSubName(e),a+='<i class="right angle icon divider"></i>',a+='<div class="active section">'+i+"</div>",a+="</div>",a+="</div>",a+="</div>"}function p(e,t,i,a){var s=Strack.build_filter({project_id:["eq",t],epis_id:["eq",i],active:["eq",1]},{},{},{},"and",{},{},[{sortName:"created",sortOrder:"desc"}]);Strack.G.Gfilter_data.sequences=s,$("#data_seqs").datagrid({url:EpisodeVariable.EpisSepList,fitColumns:!1,height:Strack.panel_height(".pseq_shots",0),rowheight:49,differhigh:!1,singleSelect:!1,DragSelect:!0,adaptive:{dom:".pseq_shots",min_width:510,exth:0,domresize:1},DataNull:Strack.DataNullTip(6020),queryParams:{filter:JSON.stringify(s)},frozenColumns:[[{field:"sequenceid",checkbox:!0}]],columns:[a],toolbar:"#seq_tb",pagination:!0,pageSize:100,pageList:[100,200],pageNumber:1,pagePosition:"bottom",remoteSort:!1,onDblClickRow:function(e,i){Strack.SideColumnOpen(i.sequenceid,60,60,t,"data_seqs")},onRowContextMenu:function(e,t,i){Strack.grid_clipboard(e.target),e.preventDefault(),$("#st_menu_sequences").menu("show",{left:e.pageX,top:e.pageY})}})}function u(e,t,i){$.ajax({type:"POST",url:StrackPHP.DynamicFields,dataType:"json",data:{project_id:e,type:t},success:function(a){var s=[];a.forEach(function(e,t){e&&s.push(Strack.DynamicFieldset(60,e,t,""))}),p(t,e,i,s)}})}function h(e,t,i){$("#seq_history").datagrid({url:EpisodeVariable.EpisHistory,height:Strack.panel_height(".pseq_history",0),differhigh:!1,singleSelect:!0,fitColumns:!0,striped:!0,adaptive:{dom:".pseq_history",min_width:510,exth:0},DataNull:StrackPHP.DataNoHis,queryParams:{op_type:e,pid:i,seq_id:t,tab:"history",log_type:40},frozenColumns:[[{field:"log_id",checkbox:!0}]],columns:[[{field:"operate",title:StrackPHP.Operate,align:"center",width:120,frozen:"frozen",findex:0},{field:"projname",title:StrackPHP.Project,align:"center",width:180,frozen:"frozen",findex:1},{field:"summary",title:StrackPHP.EventLog_Summary,align:"center",width:450,frozen:"frozen",findex:2},{field:"log_val",title:StrackPHP.TMeta,align:"center",width:650,frozen:"frozen",findex:3},{field:"log_link",title:StrackPHP.EventLog_Link_Id,align:"center",width:80,frozen:"frozen",findex:4},{field:"log_type",title:StrackPHP.EventLog_Type,align:"center",width:120,frozen:"frozen",findex:5},{field:"user_id",title:StrackPHP.User,align:"center",width:160,frozen:"frozen",findex:6},{field:"created",title:StrackPHP.Created,align:"center",width:180,frozen:"frozen",findex:7}]],pagination:!0,pageSize:100,pageList:[100,200],pageNumber:1,pagePosition:"bottom",remoteSort:!1})}function m(){var e,t,i=$(".seq-left-wrap"),a=$(".proj-seq-left"),s=$(".items-ctop-title"),n=$(".proj-seq-right");$("#myhome_handle").on("mousedown",function(o){o.preventDefault(),e=680,$(document).on("mousemove",function(o){t=o.pageX<140?7:o.pageX>=e?e:o.pageX,t<140?i.hide():i.show(),s.css("width",t-200),a.css("width",t),n.css("width","calc(100% - "+t+"px)"),t<230?$(".sleft-items-content").hide():$(".sleft-items-content").show()}).on("mouseup",function(e){$(this).off("mousemove")})})}function f(){$(".item-breadcrumb-left").empty(),$(".item-breadcrumb-right").empty(),$(".task-thumb-show").empty(),$("#seq_d_name").empty(),$("#seq_d_fields").empty(),$(".seq-right-wrap").hide(),$("#noseq_selected").removeClass("seq_selected").show()}function _(e){var t=[];"yes"==D.batch_update.allow&&t.push({name:"eedit",text:StrackPHP.Edit_Selected,iconCls:"icon-uniF044",type:"function",click:"obj.EpisUpdate(this)",attr_data:{grid:"data_epis",page:"episodes"}}),"yes"==D.import_excel.allow&&t.push({name:"eimport_excel",text:StrackPHP.Import_ExcelT,iconCls:"icon-uniE986",type:"function",click:"Strack.import_excel_data(this)",attr_data:{pid:e,type:50,done:"episodes",grid:"epis_grid"}}),"yes"==D.export_excel.allow&&t.push({name:"eexcel",text:StrackPHP.Export_Excel,iconCls:"icon-uniE6082",type:"function",click:"Strack.ExportExcel(this)",attr_data:{pid:e,type:50,done:"episodes",mode:"grid"}}),"yes"==D.episodes_action.allow&&t.push({name:"eaction",text:StrackPHP.Action,iconCls:"icon-uniE6BB",type:"function",click:"Strack.ClientActionBatch(this)",attr_data:{type:50,grid:"data_epis",field:"epis_id"}}),t.push({name:"ereset",text:StrackPHP.Reset,iconCls:"icon-uniE682",type:"function",click:"Strack.ResetDatagrid(this)",attr_data:{type:5020,pid:e,grid:"data_epis"}}),"yes"==D.episodes_del.allow&&t.push({name:"tdelete",text:StrackPHP.DeleteSelect,iconCls:"icon-uniE9D5",type:"function",click:"obj.EpistoTrash(this)",attr_data:{tab:"list"}}),t.push({name:"ecopy_cell",text:StrackPHP.Copy_Grip_Cell,iconCls:"icon-uniE943",type:"function",click:"Strack.copy_clipboard(this)",attr_data:{"clipboard-action":"copy","clipboard-target":"#grid_clipboard"}}),Strack.InitMenuItem("st_menu_episodes",t),new Clipboard("#st_menu_ecopy_cell")}function g(e){var t=[];"yes"==D.batch_update.allow&&t.push({name:"sedit",text:StrackPHP.Edit_Selected,iconCls:"icon-uniF044",type:"function",click:"obj.BathEditSeqs(this)",attr_data:{grid:"data_seqs",page:"sequences"}}),"yes"==D.export_excel.allow&&t.push({name:"sexcel",text:StrackPHP.Export_Excel,iconCls:"icon-uniE6082",type:"function",click:"Strack.ExportExcel(this)",attr_data:{pid:e,type:60,done:"sequences",mode:"grid"}}),"yes"==D.sequence_action.allow&&t.push({name:"saction",text:StrackPHP.Action,iconCls:"icon-uniE6BB",type:"function",click:"Strack.ClientActionBatch(this)",attr_data:{type:60,grid:"data_seqs",field:"sequenceid"}}),t.push({name:"ereset",text:StrackPHP.Reset,iconCls:"icon-uniE682",type:"function",click:"Strack.ResetDatagrid(this)",attr_data:{type:6020,pid:e,grid:"data_seqs"}}),"yes"==D.sequence_del.allow&&t.push({name:"sdelete",text:StrackPHP.DeleteSelect,iconCls:"icon-uniE9D5",type:"function",click:"obj.SeqstoTrash(this)",attr_data:{}}),t.push({name:"scopy_cell",text:StrackPHP.Copy_Grip_Cell,iconCls:"icon-uniE943",type:"function",click:"Strack.copy_clipboard(this)",attr_data:{"clipboard-action":"copy","clipboard-target":"#grid_clipboard"}}),Strack.InitMenuItem("st_menu_sequences",t),new Clipboard("#st_menu_scopy_cell")}function S(t,i,a){switch($("#m_tab_"+t).find("a").each(function(){$(this).data("tab")==t&&$(this).addClass("active-list")}),$(".proj-seq-wrap").removeClass("seqs-active"),$("#table_"+t).addClass("seqs-active"),Strack.SideColumnClose(),t){case"column":e(i,a,E,q,"new"),$("#noseq_selected").show().removeClass("seq_selected"),$(".seq-right-wrap").hide(),Strack.SortDown(i,5010,"leftlist",{SortChange:"obj.sort_change",SortAdv:"obj.DataSortAdv",SortItem:"obj.DataSortItem"}),f();break;case"list":Strack.LoadFieldsList(5020,i,"data_epis",PARSE_VAR.rules.custom_fields.allow),Strack.getViewSet(i,5020,"data_epis",PARSE_VAR.rules,""),Strack.GroupDown(i,5020,"data_epis",{SortChange:"Strack.sort_change",SortAdv:"Strack.DataSortAdv",SortItem:"Strack.DataSortItem"}),_(i),o(i,5020)}}function k(e,t){var i="";return i+='<div id="thumb_show_'+e+"_"+t+'" class="task-thumb-show"></div>'}function v(e){var t=$("#current_sid").val();switch($(".mitem-wrap").removeClass("active").each(function(){$(this).data("tab")==e&&$(this).addClass("active")}),e){case"sequences":g(y),u(y,6020,t);break;case"info":Strack.AjaxMfields(P,t,y,StrackPHP.DomEPMfields,"episodes",50,"epis_info_list");break;case"history":h(P,t,y)}}obj={showList:function(e){var t=$(e).data("tab");if($(".p-wrap-filter").length>0)switch(t){case"list":Strack.DoFilterClose(6020,$("#data_seqs"));break;case"column":Strack.DoFilterClose(5020,$("#data_epis"))}$(".tab-item").removeClass("active"),$(".menu-tab").removeClass("active-list"),Strack.save_storage("datagridEpisode",t),S(t,y,P)},ToggleGroup:function(e){var t=$(e).next(".sleft-gitem");t.hasClass("group-fold")?(t.show().removeClass("group-fold"),$(e).find("i").removeClass("icon-uniF107").addClass("icon-uniF106")):(t.hide().addClass("group-fold"),$(e).find("i").removeClass("icon-uniF106").addClass("icon-uniF107"))},ShowItem:function(e){var t=$(e).data("epsid"),i=$("#noseq_selected");Strack.SideColumnClose(),$(".list-item-main").removeClass("sleft-items-active"),$(e).addClass("sleft-items-active"),d(y,t,P),$("#current_sid").val(t),$("#add_sequence").data("episid",t),i.hasClass("seq_selected")?$(".tab-item").removeClass("active"):(i.hide().addClass("seq_selected"),$(".seq-right-wrap").show()),$("#tab_sequences").addClass("active"),$("#thumb_swrap").find(".task-thumb-show").remove(),$("#thumb_swrap").append(k(50,t)),v("sequences"),Strack.getViewSet(y,6020,"data_seqs",PARSE_VAR.rules,""),Strack.LoadFieldsList(6020,y,"data_seqs",PARSE_VAR.rules.custom_fields.allow),Strack.GroupDown(y,6020,"data_seqs",{SortChange:"Strack.sort_change",SortAdv:"Strack.DataSortAdv",SortItem:"Strack.DataSortItem"})},SwitchTabs:function(e){var t=$(e).data("tab");$(".tab-item").removeClass("active"),$(e).addClass("active"),v(t)},sort_change:function(e){if($(e).hasClass("field-disable")&&C){var i,a,s=$(e).data("sort"),n=$(e).data("ptype");switch(C.sort[0].sortOrder=s,w=!1,t(C,y,P,1,"All","group"),s){case"asc":i="asc",a="desc";break;case"desc":i="desc",a="asc"}$("#"+i+"_sort_"+n).removeClass("field-disable").find("i").removeClass("icon-unchecked").addClass("icon-checked"),$("#"+a+"_sort_"+n).addClass("field-disable").find("i").removeClass("icon-checked").addClass("icon-unchecked"),f()}},DataSortItem:function(e){var i=($(e).data("grid"),$(e).data("ptype")),a=$(e).data("pid"),s=$(e).data("field");C=Strack.build_filter({project_id:["eq",a],active:["eq",1]},{},{},{},"and",{},{},[{sortName:s,sortOrder:"asc"}]),w=!1,t(C,a,P,1,"All","group"),$("#edit_sort_"+i).find(".sort_fields").each(function(){$(this).data("field")==s?$(this).find("i").removeClass("icon-unchecked").addClass("icon-checked"):$(this).find("i").removeClass("icon-checked").addClass("icon-unchecked")}),$("#asc_sort_"+i).removeClass("field-disable").find("i").removeClass("icon-unchecked").addClass("icon-checked"),$("#desc_sort_"+i).addClass("field-disable").find("i").removeClass("icon-checked").addClass("icon-unchecked"),f()},EpisUpdate:function(e){var t=$(e).data("grid"),i=Strack.GetTaskDatagrid(t,"epis_id",!1);switch(i.verify){case-3:layer.msg(StrackPHP.Please_Select_One,{icon:2,time:1200,anim:6});break;case 200:Strack.BatchUpDialog("#"+t,EpisodeVariable.TUpdateEditEpis,i.ids.join(","),{type:"episodes",pid:y,custom:"yes",etype:5020,upmod:"episodes",multi:"no"},StrackPHP.EditFields,i)}},FilterAction:function(e){var i=$(e).data("pid"),a=$(e).data("filter"),s=($(e).data("grid"),$("#search_val_"+a).val());C=Strack.build_filter({project_id:["eq",i],active:["eq",1]},{epis_name:["LIKE","%"+s+"%"]}),w=!0,t(C,i,P,1,100,"new")},Modify_Thumb:function(){var e=$("#current_sid").val();Strack.change_item_thumb(P,e,y,"epislist")},addEpisodes:function(e){var t=$(e).data("pid"),i=$(e).data("grid"),a={type:"episodes",pid:t,custom:"yes",multi:"no",etype:5020,upmod:"newEpisodes"};Strack.open_dialog("dialog",{title:EpisodeVariable.Add_Episodes,width:560,height:360,content:Strack.dialog_dom({type:1,hidden:[{case:101,id:"Mup_type",type:"hidden",name:"up_type",valid:1,value:a.upmod},{case:101,id:"Mproject_id",type:"hidden",name:"project_id",valid:1,value:t},{case:101,id:"Mtype",type:"hidden",name:"type",valid:1,value:a.etype},{case:101,id:"Mitype",type:"hidden",name:"type",valid:1,value:"new"}],items:[{case:1,id:"Mup_fields",type:"text",lang:StrackPHP.Fields,name:"fields",valid:1,value:""}],update:!0,footer:[{obj:"BatchUpdate",type:5,title:StrackPHP.Update},{obj:"dialog_cancel",type:8,title:StrackPHP.Cancel},{obj:"save_dialog_setting",type:8,title:StrackPHP.Save_Setting}]}),inits:function(){var e,i=[5501,5506,5502],s=Strack.G.DialogAddSetting[a.etype];e=s&&200==parseInt(s.status)?s.optionValue:i,$("#Mup_fields").combobox({url:StrackPHP.EditFields,width:350,valueField:"id",textField:"lang",multiple:!0,value:"",queryParams:a,onSelect:function(e){if(0==$("#dgup_i_"+e.id).length){var i=Strack.BatchUpItem(e,"new");$("#st_dgup").append(i.item_dom),Strack.BatchItemInit(e,t,5020,i.id,a.type,e)}},onUnselect:function(e){$.inArray(e.id,i)<0?$("#dgup_i_"+e.id).remove():($(this).combobox("select",e.id),layer.msg(StrackPHP.Must_Field,{icon:2,time:1200,anim:6}))},onLoadSuccess:function(){var t=$(this);e.forEach(function(e){t.combobox("select",e)})}})},close:function(){switch(i){case"left_epis":obj.DoEpisReset(t,P,i);break;case"data_epis":$("#"+i).datagrid("reload")}}})},EpisReset:function(e){var t=$(e).data("type"),i=$(e).data("grid"),a=$(e).data("pid");obj.DoEpisReset(a,t,i)},DoEpisReset:function(e,i,a){C=Strack.build_filter({project_id:["eq",e],active:["eq",1]},{},{},{},"and",{},{},[{sortName:"created",sortOrder:"desc"}]),w=!0,$("#lseq_list").off("scroll"),t(C,e,i,1,100,"new"),Strack.SortDown(e,5010,"leftlist",{SortChange:"obj.sort_change",SortAdv:"obj.DataSortAdv",SortItem:"obj.DataSortItem"}),f()},EpistoTrash:function(e){var t,i=$(e).data("tab"),a=0;switch(i){case"column":var s=$("#lseq_list").find(".sleft-items-active");a=s.length,t=s.data("epsid");break;case"list":var n=$("#data_epis").datagrid("getSelections"),o=[];n.forEach(function(e){o.push(e.epis_id)}),a=n.length,t=o.join(",")}a>0?obj.DeleteEpis(t,i):layer.msg(StrackPHP.Please_Select_One,{icon:2,time:1200,anim:6})},DeleteEpis:function(e,i){$.messager.confirm(StrackPHP.Confirmation_Box,EpisodeVariable.CM_DeEpis,function(a){a&&$.ajax({type:"POST",url:EpisodeVariable.DeleteEpis,dataType:"json",data:{eps_ids:e,pid:y},beforeSend:function(){$.messager.progress({title:StrackPHP.Waiting,msg:StrackPHP.loading})},success:function(e){switch(Strack.top_message({bg:"g",msg:EpisodeVariable.DeEpisodesSC}),i){case"column":w=!0,t(Strack.G.Gfilter_list.episodes,y,P,1,100,"new"),f();break;case"list":$("#data_epis").datagrid("reload")}$.messager.progress("close")}})})},SeqstoTrash:function(e){var t=$("#data_seqs").datagrid("getSelections"),i=[];t.forEach(function(e){i.push(e.sequenceid)}),Strack.ajax_grid_delete(t,EpisodeVariable.DeSeqs_notice,EpisodeVariable.DeleteSeqs,{seq_ids:i.join(","),pid:y},"#data_seqs",EpisodeVariable.DeEpisodesSC)},BathEditSeqs:function(e){var t=$(e).data("grid"),i=Strack.GetTaskDatagrid(t,"sequenceid",!1);switch(i.verify){case-3:layer.msg(StrackPHP.Please_Select_One,{icon:2,time:1200,anim:6});break;case 200:Strack.BatchUpDialog("#"+t,EpisodeVariable.TUpdateEditEeqs,i.ids.join(","),{type:"sequences",pid:y,custom:"yes",etype:6020,upmod:"seqdetails",multi:"no"},StrackPHP.EditFields,i)}}};var b=$("#epis_main");if(PARSE_VAR.auth.authority){var y=$("input[name=proj_id]").val(),P=$("input[name=p_type]").val(),C=null,w=!0,E=1,q=100,T=Strack.verify_project_data(y),D={};if(T>0){!function(e){for(var t in e){var i=e[t];switch(D[i.alias]=i,i.alias){case"batch_update":case"import_excel":case"export_excel":case"episodes_del":case"episodes_add":case"sequence_add":case"sequence_del":case"sequence_action":"no"==i.allow&&$(".ah_"+i.alias).remove()}}}(PARSE_VAR.rules),b.show(),Strack.save_storage("projid",[y,P]),Strack.project_sub_menu(y,50);var x=Strack.read_storage("datagridEpisode");x||(x="column"),S(x,y,P);var H={};H["epis_name-1"]=EpisodeVariable.EpisName_Length,H["epis_status-1"]=EpisodeVariable.EpisStatusNULL}else b.empty().append(Strack.ProjWarn(StrackPHP.Project_None_Warning)).show()}else b.empty().append(Strack.ProjWarn(StrackPHP.NoPermission)).show()});