@@ -53,6 +53,7 @@
<button onclick="update(5)" class="btn-sm btn btn-gradient-dark">{{ __('auto.充减提') }}</button>
@endif
+ <a href="{{ url('/admin/stock-mode#snapshot-tab') }}" class="btn-sm btn btn-gradient-info" style="margin-left: 10px;">库存快照历史</a>
<div id="main" style="width: 100%;height:600px;"></div>
</div>
@@ -479,6 +479,11 @@
<script>
$(function() {
+ // 如果通过哈希访问快照历史,自动切换到对应标签页
+ if (window.location.hash === '#snapshot-tab') {
+ $('a[href="#snapshot-tab"]').tab('show');
+ }
+
// 保存系统配置
$('#save-system-config').click(function() {
const $btn = $(this);