function erp_ac_get_bank_accounts()
{
    return WeDevs\ERP\Accounting\Model\Ledger::bank()->active()->get()->toArray();
}
Beispiel #2
0
<div class="wrap erp-ac-form-wrap">
    <h2><?php 
_e('New Invoice', '$domain');
?>
</h2>

    <?php 
$accounts_receivable_id = WeDevs\ERP\Accounting\Model\Ledger::code('120')->first()->id;
$dropdown = erp_ac_get_chart_dropdown(['exclude' => [1, 2, 3, 5], 'required' => true, 'name' => 'line_account[]']);
?>

    <form action="" method="post" class="erp-form" style="margin-top: 30px;">

        <ul class="form-fields block" style="width:50%;">

            <li>
                <ul class="erp-form-fields two-col block">
                    <li class="erp-form-field">
                        <?php 
erp_html_form_input(array('label' => __('Customer', 'erp-accounting'), 'name' => 'user_id', 'placeholder' => __('Select a payee', 'erp-accounting'), 'type' => 'select', 'class' => 'select2', 'options' => ['' => __('&mdash; Select &mdash;', 'erp-accounting')] + erp_get_peoples_array(['type' => 'customer', 'number' => 100])));
?>
                    </li>

                    <li class="erp-form-field">
                        <?php 
erp_html_form_input(array('label' => __('Reference', 'erp-accounting'), 'name' => 'ref', 'type' => 'text', 'addon' => '#'));
?>
                    </li>
                </ul>
            </li>
Beispiel #3
0
<div class="wrap erp-ac-bank-account-wrap">
    <h2><?php 
_e('Bank Account', 'accounting');
?>
</h2>

    <div class="bank-accounts">
    <?php 
$banks = WeDevs\ERP\Accounting\Model\Ledger::bank()->with('bank_details')->get();
foreach ($banks as $bank) {
    ?>
        <div class="bank-account postbox">
            <h3 class="hndle">
                <span class="title erp-ac-bank-name" data-bank_id="<?php 
    echo $bank->id;
    ?>
"><?php 
    echo esc_html($bank->name);
    ?>
</span>

                <span class="pull-right">
                    <a class="add-new-h2" href="<?php 
    echo admin_url('admin.php?page=erp-accounting-sales&action=new&type=payment&receive_payment=true&bank=' . $bank->id);
    ?>
"><?php 
    _e('Receive Money', 'erp-accounting');
    ?>
</a>
                    <a class="add-new-h2" href="<?php 
    echo admin_url('admin.php?page=erp-accounting-expense&action=new&type=payment_voucher&spend_money=true&bank=' . $bank->id);
<div class="wrap erp-ac-form-wrap">
    <h2><?php 
_e('Vendor Credit', 'erp-accounting');
?>
</h2>


    <?php 
$accounts_payable_id = WeDevs\ERP\Accounting\Model\Ledger::code('200')->first()->id;
$dropdown = erp_ac_get_chart_dropdown(['exclude' => [1, 4, 5], 'required' => true, 'name' => 'line_account[]']);
?>

    <form action="" method="post" class="erp-form" style="margin-top: 30px;">

        <ul class="form-fields block" style="width:50%;">

            <li>
                <ul class="erp-form-fields two-col block">
                    <li class="erp-form-field">
                        <?php 
erp_html_form_input(array('label' => __('Vendor', 'erp-accounting'), 'name' => 'user_id', 'type' => 'select', 'class' => 'select2', 'options' => ['' => __('&mdash; Select &mdash;', 'erp-accounting')] + erp_get_peoples_array(['type' => 'vendor', 'number' => 100]), 'custom_attr' => ['data-placeholder' => __('Select a payee', 'erp-accounting')]));
?>
                    </li>

                    <li class="erp-form-field">
                        <?php 
erp_html_form_input(array('label' => __('Reference', 'erp-accounting'), 'name' => 'ref', 'type' => 'text', 'addon' => '#'));
?>
                    </li>
                </ul>
            </li>