package IId2661407bcab8ad6600346c26bc31532; use strict 'vars'; use base qw/II720d6e18aa34327713eb014408fc9144/; use IIa93fbcb8fc9a892558c20a25de3550ec; BEGIN{*IId2661407bcab8ad6600346c26bc31532::IllIlIlIlllIllII=\%{pack('H6','78161a')^'=XL'};*IId2661407bcab8ad6600346c26bc31532::llIIIIIlIllIlllI=\&{pack('H24','532a3d5608783e6b7557326c')^'>KT82BMSB5JX'};$IId2661407bcab8ad6600346c26bc31532::IlllIIllllIllIlI=pack('H18','716c1a0260001e640c')^'98NR?HQ7X';$IId2661407bcab8ad6600346c26bc31532::IlllIIlIllIIlIll=pack('H12','1b021b7d0570')^'QKU1L3'};sub _form_get { my ($a_type, $a_obj_type, $form, $f) = @_; $f = $form->pfx . $f; my $a_obj_id = $form->getDecorated->id; my $anchored = II720d6e18aa34327713eb014408fc9144::IlllIllllIllIIIl($IId2661407bcab8ad6600346c26bc31532::IIIlIIlllIlIlIlI{$IIa93fbcb8fc9a892558c20a25de3550ec::IIIllllllIIIlIlI},88,$IId2661407bcab8ad6600346c26bc31532::IIIlIIlllIlIlIlI{$IIa93fbcb8fc9a892558c20a25de3550ec::lllIlllIIIIlIIll})->getAnchored($a_type, $a_obj_type, $a_obj_id); my $value = $anchored ? ($anchored->{disabled} ? 3 : 2) : 1; my %a_fontweight = map { $_ => 'normal' } 1..3; $a_fontweight{$value} = 'bold'; my %radio_checked; $radio_checked{$value} = 'checked'; my $msg_default = __PACKAGE__->message('emaildlv.anchored.radio_default'); my $msg_customize = __PACKAGE__->message('emaildlv.anchored.radio_customize'); my $msg_disable = __PACKAGE__->message('emaildlv.anchored.radio_disable'); return <<END_HTML;
<script>
function js_$f(new_v)
{ var h = document.getElementById('Hidden_$f'); var old_v = h.value; h.value = new_v; if (old_v != new_v) { var old_a = document.getElementById('A_${f}_' + old_v); old_a.style.fontWeight = 'normal'; if (old_v == 2) { old_a.removeAttribute('href'); old_a.removeAttribute('onClick'); } } var new_a = document.getElementById('A_${f}_' + new_v); new_a.style.fontWeight = 'normal'; if (new_v == 2) { new_a.href = '#'; new_a.setAttribute('onClick',  "jinPopWin('/master/store/emaildlvs/anchored.html?TabCustom1=$a_type.$a_obj_type.$a_obj_id'); return false;"); } }
</script>
<input type="hidden" id="Hidden_$f" name="$f" value="$value">
<div class="custom-control custom-radio">
<input id="Radio0_$f" type="radio" name="Radio_$f" class="custom-control-input" $radio_checked{1} onClick="if (this.checked) js_$f(1)">
<label for="Radio0_$f" class="custom-control-label"><a id="A_${f}_1" style="">$msg_default</a></label>
</div>
<div class="custom-control custom-radio">
<input id="Radio1_$f" type="radio" name="Radio_$f" class="custom-control-input" $radio_checked{2} onClick="if (this.checked) js_$f(2)">
<label for="Radio1_$f" class="custom-control-label"><a id="A_${f}_2" style="">$msg_customize</a></label>
</div>
<div class="custom-control custom-radio">
<input id="Radio2_$f" type="radio" name="Radio_$f" class="custom-control-input" $radio_checked{3} onClick="if (this.checked) js_$f(3)">
<label for="Radio2_$f" class="custom-control-label"><a id="A_${f}_3" style="">$msg_disable</a></label>
</div>
<script>js_$f($value)</script>
END_HTML
} BEGIN{*IId2661407bcab8ad6600346c26bc31532::IIIlIIlllIlIlIlI=\%{pack('H6','780a1f')^'=DI'};*IId2661407bcab8ad6600346c26bc31532::llllIIIlIlIlIIII=\&{pack('H24','3f2d573e037a2a710c2b3677')^'RL>P9@YI;INC'};$IId2661407bcab8ad6600346c26bc31532::llIlIlllIllIIllI=pack('H18','7c0402170b73031c06')^'4PVGT;LOR';$IId2661407bcab8ad6600346c26bc31532::IlIIIIIllIllIIII=pack('H12','191d737d047d')^'ST=1M>'};sub _form_set { my ($a_type, $a_obj_type, $form, $f, $v) = @_; my $a_obj_id = $form->getDecorated->id; if ($v == 1) { if (my $object = IIa93fbcb8fc9a892558c20a25de3550ec::IlIlIlllIllIlIIl($II720d6e18aa34327713eb014408fc9144::lIIllIIIlIlIlIIl{$IId2661407bcab8ad6600346c26bc31532::llIlIlllIllIIllI},88,$II720d6e18aa34327713eb014408fc9144::lIIllIIIlIlIlIIl{$IIa93fbcb8fc9a892558c20a25de3550ec::llllIlIllIlIllII})->getAnchored($a_type, $a_obj_type, $a_obj_id)) { $object->delete; } } elsif ($v == 2) { if (my $object = II720d6e18aa34327713eb014408fc9144::IlIlIlIIIIllIlII($IId2661407bcab8ad6600346c26bc31532::IllIlIlIlllIllII{$II720d6e18aa34327713eb014408fc9144::llIlIlIIIIIlIIlI},88,$IId2661407bcab8ad6600346c26bc31532::IllIlIlIlllIllII{$IIa93fbcb8fc9a892558c20a25de3550ec::lIlIIIlIIIIlIIll})->getAnchored($a_type, $a_obj_type, $a_obj_id)) { $object->{disabled} = 0; $object->save; } } elsif ($v == 3) { my $object = IIa93fbcb8fc9a892558c20a25de3550ec::IlIllllIIIIlIIlI($IIa93fbcb8fc9a892558c20a25de3550ec::lIlllIllllIIIIII{$II720d6e18aa34327713eb014408fc9144::lIIIIIlIIIlIIIII},88,$IIa93fbcb8fc9a892558c20a25de3550ec::lIlllIllllIIIIII{$II720d6e18aa34327713eb014408fc9144::llIlIIIIIIlIIIIl})->getOrCreateAnchored($a_type, $a_obj_type, $a_obj_id); $object->{disabled} = 1; $object->save; } return; } 1; 