You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

112 lines
2.6 KiB
PHTML

@extends('temp.admin')
@php
use NN\Module\DB;
use NN\Module\Perusahaan as perush;
$demo = perush::datalogin()['data'][0]->demo;
$set = [
"title" => "Setting"
, "subtitle" => "Profile Perusahaan"
, "thead" => [
"#","Kode","Nilai"
]
];
@endphp
@section("content")
@include("temp.temp1", $set)
<noscript id="datainternal">{!! json_encode(DB::query_result_object("SELECT kode id, keterangan text FROM dept")) !!}</noscript>
@endsection
@section('script')
<script>
if(_select('.new') != null){
document.querySelector('.new').style.display = 'none';
};
var objectForm = {
title : function(){
return 'Profile';
},
table :"profile",
idform :"containerforms",
newkode: ``,
kode: 'kode',
view: ['kode','data'],
custome: {
kode : function(a){
if(a == 'shublusp'){
return `Kode akun SHU belum dibagi USP `;
}
else if(a == 'shubluinduk'){
return `Kode akun SHU belum dibagi Induk `;
}
else
{
return a;
}
},
data: function(a, b){
if(b.kode != 'shublusp' && b.kode != 'shublinduk'){
return _textArea(a,b,'kode','data', '100%', 'text', '');
}else{
return b.data;
}
}
},
disableEditor: function(a,b,c){
return c+1;
},
oncreate: function(a){
},
onupdate: function(dt){
},
dataSelect: ["*"],
queryTemp: "SELECT {select} FROM profile || ",
validasiForm: [],
data: [
{
title: 'Kode',
type: 'text',
name: 'kode',
row: 12,
readonly: false,
action: function(){
},
}
,{
title: 'Nilai',
type: 'text',
name: 'data',
row: 12,
readonly: false,
action: function(){
},
}
]
};
@if($demo == 1)
objectForm.disableEditor = true;
objectForm.custome = {};
@endif
</script>
@include('temp.crudpinjaman')
@endsection
@section('css')
<style>
.dataTable tr td:nth-child(1){
white-space: nowrap;
max-width: 10px;
width: 10px;
}
</style>
<style>
.dataTable tr td:nth-child(2){
white-space: nowrap;
}
</style>
@endsection