Commit 38ccd26c by 杨树贤

修复disable逻辑

parent 848474ed
......@@ -12,8 +12,7 @@
layDate.render({
elem: '#established_time'
, type: 'month'
, format: 'yyyy-MM'
, format: 'yyyy-MM-dd'
});
const supplierId = getQueryVariable('supplier_id');
......@@ -120,8 +119,6 @@
@if(!empty($supplier))
@if($supplier['region']==2)
$('.city-div').show();
$('#established_time').attr('disabled', true);
$('#established_time').addClass('layui-disabled');
@endif
@if($supplier['supplier_group']==\App\Model\SupplierChannelModel::SUPPLIER_GROUP_MIX)
$('#agency_brands_div').show();
......@@ -152,8 +149,8 @@
$('#tax_number_required_span').show();
$('#tax_number_div').show();
$('.city-div').show();
//同时还要判断权限,有忽略公司校验权限的,成立时间可以不disabled
if (!ignoreCompanyCheck) {
//同时还要判断权限,有忽略公司校验权限的,成立时间可以不disabled,以及还有一个条件,修改的时候不能disable
if (!ignoreCompanyCheck && !supplierId) {
$('#established_time').attr('disabled', true);
$('#established_time').addClass('layui-disabled');
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment