{set:$this->startDate = IFilter::act(IReq::get('startDate'));$this->endDate = IFilter::act(IReq::get('endDate'));$countData = statistics::sellerAmount($this->seller['seller_id'],$this->startDate,$this->endDate);}
{js:my97date}
{js:chart}

<article class="col-lg-12">
	<div class="module_content card">
		<div class="card-body">
			<form class="form-inline" action="{url:}" method="get">
				<input type='hidden' name='controller' value='seller' />
				<input type='hidden' name='action' value='account' />
				<div class="form-group">
					<input type="text" name='startDate' value='{$this->startDate}' class="mr-3 form-control" placeholder="开始日期" pattern='date' onFocus="WdatePicker()" empty />
				</div>
				<div class="form-group">
					<input type="text" name='endDate' value='{$this->endDate}' class="mr-3 form-control" pattern='date' placeholder="结束日期" onFocus="WdatePicker()" empty />
				</div>
				<div class="form-group">
					<input type="submit" class="btn btn-primary" value="查询" />
				</div>
			</form>
		</div>
		<div class="card-footer">
			<div class="col-xl-12 col-sm-12">
				<div class="item d-flex align-items-center">
					<div id="myChart" style="width:100%;min-height:320px;"></div>
				</div>
			</div>
		</div>
	</div>
</article>

<script type='text/javascript'>
//图表生成
$(function()
{
	//图标模板
	var option = {
		title:
		{
			text:''
		},
		xAxis:
		{
			name:'时间',
			data:{echo:JSON::encode(array_keys($countData))},
		},
		yAxis:
		{
			name:'销售额(元)',
		},
		series:
		[
			{
				name:'销售额',
				type: 'line',
				data:{echo:JSON::encode(array_values($countData))}
			}
		],
		tooltip:
		{
			show:true
		}
	};
	echarts.init(document.getElementById('myChart')).setOption(option);
})
</script>