1. 【新增】售后单售后原因类型支持搜索

2. 【新增】手工创建订单折扣可输入正数

3. 【优化】盘点申请单确认

4. 【修复】采购退货单模拟出库失败问题

5. 【新增】订单金额客户实付与结算金额

6. 【优化】仓库发货统计报表物料名称显示

7. 【优化】自有仓储虚拟发货逻辑

8. 【修复】基础物料分类管理问题
This commit is contained in:
chenping
2026-04-01 11:59:17 +08:00
parent 9341122827
commit 61783b7d01
754 changed files with 46179 additions and 5700 deletions

View File

@@ -0,0 +1,193 @@
<div class="tableform">
<div class="division">
<form method="post" action="index.php?app=ome&ctl=admin_platform_set&act=save" id="frm">
<{input type="hidden" name="id" value=$data.id}>
<table border="0" cellspacing="0" cellpadding="0" >
<tbody>
<tr>
<th>平台编码:</th>
<td><{input issearch="fuzzy-search" type="select" required="true" options=$optShopType name="shop_type" value=$data.shop_type id="shop_type" }></td>
</tr>
<tr>
<th>场景:</th>
<td>
<select name="scene" id="scene" required="true">
<option value="">请先选择平台</option>
</select>
</td>
</tr>
</tbody>
<tbody id="scene_fields">
<!-- 动态加载的场景相关字段 -->
</tbody>
<tbody>
<tr>
<th>备注:</th>
<td><{input type="textarea" name="memo" value=$data.memo style="height: 100px;"}></td>
</tr>
</tbody>
</table>
</form>
</div>
</div>
<{area inject=".mainFoot"}>
<div class="table-action">
<table width="100%" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td>
<{button type="button" id='submit_btn' class="btn-primary" label='保存' }>
<{button type="button" id='close_btn' class="btn-secondary" label='关闭' isCloseDialogBtn="true"}>
</td>
</tr>
</tbody>
</table>
</div>
<{/area}>
<script type="text/javascript">
(function(){
var _form = $('frm');//表单ID
var btn = $('submit_btn');//按钮ID
var finder = finderGroup['<{$env.get.finder_id}>'];
var shopTypeSelect = $('shop_type');
var sceneSelect = $('scene');
var sceneFieldsContainer = $('scene_fields');
// 根据平台获取场景列表
function loadScenes(shopType) {
if (!shopType) {
sceneSelect.innerHTML = '<option value="">请先选择平台</option>';
sceneFieldsContainer.innerHTML = '';
return;
}
// 显示加载状态
sceneSelect.innerHTML = '<option value="">加载中...</option>';
sceneSelect.disabled = true;
// 获取初始值(编辑时使用)
var initialScene = '<{$data.scene}>';
var initialKname = '<{$data.kname}>';
var initialKvalue = '<{$data.kvalue}>';
// 异步请求获取场景列表
new Request({
url: 'index.php?app=ome&ctl=admin_platform_set&act=getScenes',
method: 'get',
data: {
shop_type: shopType
},
onSuccess: function(response) {
sceneSelect.innerHTML = '<option value="">请选择场景</option>' + response;
sceneSelect.disabled = false;
// 如果有初始值设置场景并加载HTML
if (initialScene) {
sceneSelect.value = initialScene;
loadSceneHtml(shopType, initialScene, initialKname, initialKvalue);
}
},
onFailure: function() {
sceneSelect.innerHTML = '<option value="">加载失败</option>';
sceneSelect.disabled = false;
}
}).send();
}
// 根据平台和场景获取HTML
function loadSceneHtml(shopType, scene, initialKname, initialKvalue) {
if (!shopType || !scene) {
sceneFieldsContainer.innerHTML = '';
return;
}
// 显示加载状态
sceneFieldsContainer.innerHTML = '<tr><td colspan="2" style="text-align:center;color:#999;">加载中...</td></tr>';
// 获取当前表单值(如果有),优先使用传入的初始值
var currentKname = initialKname || '';
var currentKvalue = initialKvalue || '';
var knameInput = $('kname');
var kvalueInput = $('kvalue');
if (knameInput && !currentKname) currentKname = knameInput.value;
if (kvalueInput && !currentKvalue) currentKvalue = kvalueInput.value;
// 异步请求获取HTML
new Request({
url: 'index.php?app=ome&ctl=admin_platform_set&act=getSceneHtml',
method: 'get',
data: {
shop_type: shopType,
scene: scene,
kname: currentKname,
kvalue: currentKvalue
},
onSuccess: function(response) {
sceneFieldsContainer.innerHTML = response;
},
onFailure: function() {
sceneFieldsContainer.innerHTML = '<tr><td colspan="2" style="color:red;">加载失败,请刷新页面重试</td></tr>';
}
}).send();
}
// 监听平台编码变化
if (shopTypeSelect) {
shopTypeSelect.addEvent('change', function(){
var selectedValue = this.value;
loadScenes(selectedValue);
sceneFieldsContainer.innerHTML = '';
});
// 页面加载时,如果有初始值,加载场景
var initialShopType = shopTypeSelect.value;
if (initialShopType) {
loadScenes(initialShopType);
}
}
// 监听场景变化
if (sceneSelect) {
sceneSelect.addEvent('change', function(){
var selectedScene = this.value;
var shopType = shopTypeSelect ? shopTypeSelect.value : '';
// 场景变化时,不传递初始值(使用空值,让用户重新输入)
loadSceneHtml(shopType, selectedScene, '', '');
});
}
tail.select('select[issearch="fuzzy-search"]', {
search: true,
width: 150,
height: 660,
searchMinLength: 0
});
_form.store('target',{
onRequest:function(){
btn.setAttribute('disabled', 'disabled');
},
onComplete:function(){
btn.removeAttribute('disabled');
},
onSuccess:function(response){
var hash_res_obj = JSON.decode(response);
if (hash_res_obj.success != undefined && hash_res_obj.success != ""){
try{
var _dialogIns = btn.getParent('.dialog').retrieve('instance');
}catch(e){}
if(_dialogIns){
setTimeout(finder.refresh(),30000);
_dialogIns.close();
}
}
}
});
btn.addEvent('click',function(){
_form.fireEvent('submit',{stop:$empty});
});
})();
</script>

View File

@@ -0,0 +1,13 @@
<tr>
<th>配置键名:</th>
<td>
<input type="text" name="kname" value="delivery_hour" id="kname" readonly="readonly" style="background-color:#f5f5f5;" />
</td>
</tr>
<tr>
<th>配置值:</th>
<td>
<input type="text" name="kvalue" value="<{$kvalue}>" id="kvalue" placeholder="请输入时效时间(小时)" required="required" />
</td>
</tr>

View File

@@ -0,0 +1,4 @@
<{foreach from=$scenes key=key item=value}>
<option value="<{$key}>"><{$value}></option>
<{/foreach}>

View File

@@ -0,0 +1,19 @@
<tr>
<th>配置键名:</th>
<td>
<input type="text" name="kname" value="commission" id="kname" readonly="readonly" style="background-color:#f5f5f5;" />
</td>
</tr>
<tr>
<th>配置值:</th>
<td>
<input type="text" name="kvalue" value="<{$kvalue}>" id="kvalue" placeholder="例如0.02" required="required" />
</td>
</tr>
<tr id="tmsd_tip">
<th></th>
<td style="color:#999;font-size:12px;">
提示:天猫喵速达佣金配置,配置键名固定为"commission",配置值填写 0.02
</td>
</tr>

View File

@@ -0,0 +1,19 @@
<tr>
<th>配置键名:</th>
<td>
<input type="text" name="kname" value="<{$kname}>" id="kname" placeholder="例如615060900218" required="required" />
</td>
</tr>
<tr>
<th>配置值:</th>
<td>
<input type="text" name="kvalue" value="<{$kvalue}>" id="kvalue" placeholder="例如0.02" required="required" />
</td>
</tr>
<tr id="tmyp_tip">
<th></th>
<td style="color:#999;font-size:12px;">
提示:天猫优品佣金配置,配置键名填写 615060900218配置值填写 0.02
</td>
</tr>

View File

@@ -0,0 +1,83 @@
<div class="tableform">
<div class="division">
<form method="post" action="index.php?app=ome&ctl=admin_platform_timeliness&act=save" id="frm">
<{input type="hidden" name="id" value=$data.id}>
<table border="0" cellspacing="0" cellpadding="0" >
<tbody>
<tr>
<th>平台编码:</th>
<td><{input issearch="fuzzy-search" type="select" required="true" options=$optShopType name="shop_type" value=$data.shop_type }></td>
</tr>
<tr>
<th>场景:</th>
<td>
<{assign var="opt" value=array('delivery'=>'发货')}>
<{input type="select" name="scene" value=$data.scene options=$opt required="true"}>
</td>
</tr>
<tr>
<th>时效时间(小时)</th>
<td><{input type="number" vtype="required" name="hour" value=$data.hour min="0" }></td>
</tr>
<tr>
<th>备注:</th>
<td><{input type="textarea" name="memo" value=$data.memo style="height: 100px;"}></td>
</tr>
</tbody>
</table>
</form>
</div>
</div>
<{area inject=".mainFoot"}>
<div class="table-action">
<table width="100%" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td>
<{button type="button" id='submit_btn' class="btn-primary" label='保存' }>
<{button type="button" id='close_btn' class="btn-secondary" label='关闭' isCloseDialogBtn="true"}>
</td>
</tr>
</tbody>
</table>
</div>
<{/area}>
<script type="text/javascript">
(function(){
var _form = $('frm');//表单ID
var btn = $('submit_btn');//按钮ID
var finder = finderGroup['<{$env.get.finder_id}>'];
tail.select('select[issearch="fuzzy-search"]', {
search: true,
width: 150,
height: 660,
searchMinLength: 0
});
_form.store('target',{
onRequest:function(){
btn.setAttribute('disabled', 'disabled');
},
onComplete:function(){
btn.removeAttribute('disabled');
},
onSuccess:function(response){
var hash_res_obj = JSON.decode(response);
if (hash_res_obj.success != undefined && hash_res_obj.success != ""){
try{
var _dialogIns = btn.getParent('.dialog').retrieve('instance');
}catch(e){}
if(_dialogIns){
setTimeout(finder.refresh(),30000);
_dialogIns.close();
}
}
}
});
btn.addEvent('click',function(){
_form.fireEvent('submit',{stop:$empty});
});
})();
</script>