<!DOCTYPE html>

{%load static%}

<head>		
	<!-- 外部库 -->
	<script src="https://cdn.staticfile.org/vue/2.2.2/vue.min.js"></script>
	<script src="https://cdn.bootcdn.net/ajax/libs/animejs/3.2.0/anime.min.js"></script>
	<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.5.1/jquery.min.js"></script>

	<link rel = "stylesheet" href = {% static "/layui/css/layui.css" %} type = "text/css" />
	<link rel = "stylesheet" href = {% static "/experiment/css/scrollbar.css" %} type = "text/css" />

	<!--YUI-->
	<link rel = "stylesheet" href = {% static "YUI/css/YUI.css" %} type = "text/css" />
	<script src = "{% static "YUI/YUI.js" %}"></script>
	<script src = "{% static "YUI/YUI-components.js" %}"></script>
	<script src = "{% static "YUI/YUI-css-complement.js" %}"></script>

	<!--speical css-->
	<link rel = "stylesheet" href = {% static "/experiment/css/project/create/create.css" %} type = "text/css" />
	<link rel = "stylesheet" href = {% static "/experiment/css/project/header.css" %} type = "text/css" />
	<link rel = "stylesheet" href = {% static "/experiment/css/project/project.css" %} type = "text/css" />

</head>

<script>
	YUI_init()
</script>

<body> <div id = "main">
	<!--顶部界面-->
	<div class = "header"> 
		<div class = "left-header">
			<p class = "project-name Y-text-center Y-font-title">【项目】{{project.name}}</p>
		</div>

		<div class = "middle-header">
			<input 
				class 		= "path-input" 
				name 		= "project-path" 
				placeholder = "项目位置" 
				value 		= "{{project.path}}"
				autocomplete= "off"
				readonly 	="true" 
			/>

			<textarea 
				class 		= "project-intro-input" 
				name 		= "project-intro" 
				placeholder = "项目介绍"				
				readonly 	="true" 
			>{{project.intro}}</textarea>
		</div>
		
		<div class = "right-header">

			<div class = "button-box Y-stack-x">
				<y-button class = "header-a Y-text-center layui-icon" title = "返回" 
					onclick = "javascript:window.location.href = '{{last_page_path}}'">&#xe65c;</y-button>
				<y-button class = "header-a Y-text-center layui-icon" title = "建立实验" 
					@y-button-click.self = "finish_create()">&#xe605;</y-button>

			</div>
		</div>
	</div>


	<div class = "middle">
		<p>新建实验</p>
	</div>

	<div class = "content">

		<div class = "left-part">
			<input class = "left-inp to-save" name = "__prefix"  value = "{{project.config.cmd_pref}}" placeholder = "前缀"></input>
			<input class = "left-inp to-save" name = "__command" value = "{{project.config.cmd_comm}}" placeholder = "命令"></input>
			<input class = "left-inp to-save" name = "__file"    value = "{{project.config.cmd_entr}}" placeholder = "主文件"></input>
			<input class = "left-inp to-save" name = "__suffix"  value = "{{project.config.cmd_suff}}" placeholder = "后缀"></input>
		</div>


		<div class = "right-part">
			<div class = "arg-line"> 
				<p class = "title-type the-title">Type</p>
				<p class = "title-name the-title">Name</p>
				<p class = "title-default the-title">Value</p>
			</div>
			<div class = "inner-line"> </div>

			{% for type , name , default in args%}

			{% if type == "_FITTER_SPLITTER" %}
				<div class = "inner-line"> </div>
			{% else %}
				<div class = "arg-line"> 
					<p class = "inner-type">{{type}}</p>
					<p class = "inner-name">{{name}}</p>
					<p class = "inner-eq">=</p>
					<input class = "inner-default to-save" name = "{{name}}" value = "{{default}}"></input>
				</div>
			{% endif %}

			{% endfor %}
		</div>

		<div class = "outer-line"></div>

	</div>
</div></body>
	
<!--其他脚本-->
<script src = {% static "/layui/layui.js" %}></script>

<script src = "{% static "experiment/js/utils.js" %} "></script>
<script src = "{% static "experiment/js/project/create/create.js" %} "></script>
{% include "./scripts.html" %}
