<?php $add_button = $this->block->generate_add_icon('order/setting/add_stmp_sender'); $head = array(lang('paypal_email'), lang('sender_name'), lang('stmp_account'), lang('options') . $add_button); $data = array(); $sender_update_url = site_url('order/setting/update_stmp_sender'); $data = array(); foreach ($paypal_senders as $sender) { $sender_id = $sender->id; $drop_button = block_drop_icon('order/setting/drop_stmp_sender', "{id: {$sender_id}}", TRUE); $sender_accounts = $this->stmp_model->fetch_paypal_sender_accounts($sender_id); $account_html = ''; foreach ($sender_accounts as $account) { $account_html .= $account->stmp_host . ': ' . $account->stmp_account . block_status_image($account->account_status) . '<br/>'; } $edit_button = block_edit_link(site_url('order/setting/update_stmp_sender_accounts', array($sender_id))); $account_html .= $edit_button; $data[] = array($this->block->generate_div("paypal_email_{$sender_id}", $sender->paypal_email), $this->block->generate_div("sender_name_{$sender_id}", $sender->sender_name), $account_html, $drop_button); echo block_editor("paypal_email_{$sender_id}", 'sender_form', $sender_update_url, "{id: {$sender_id}, type: 'paypal_email'}"); echo block_editor("sender_name_{$sender_id}", 'sender_form', $sender_update_url, "{id: {$sender_id}, type: 'sender_name'}"); } echo block_header(lang('notification_email_account_setting')); echo block_table($head, $data);
<?php $url = site_url('seo/resource/add_resource_category'); $add_button = $this->block->generate_add_icon($url); $head = array(lang('resource_catalog'), lang('integral'), lang('release_limit'), lang('release_limit_wholelife'), lang('creator'), lang('created_date')); if ('edit' == $action) { $head[] = lang('options') . $add_button; } $data = array(); $code_url = site_url('seo/resource/verify_resource_category'); foreach ($resource_categories as $category) { $drop_button = $this->block->generate_drop_icon('seo/resource/drop_resource_category', "{id: {$category->id}}", TRUE); $item = array($this->block->generate_div("name_{$category->id}", isset($category) ? $category->name : '[edit]'), $this->block->generate_div("integral_{$category->id}", isset($category) ? $category->integral : '[0]'), $this->block->generate_div("release_limit_{$category->id}", isset($category) ? $category->release_limit : '[0]'), $this->block->generate_div("release_limit_wholelife_{$category->id}", isset($category) ? $category->release_limit_wholelife : '[0]'), $category->creator, $category->created_date); if ('edit' == $action) { $item[] = $drop_button; echo $this->block->generate_editor("name_{$category->id}", 'resource_category_form', $code_url, "{id: {$category->id}, type: 'name'}"); echo $this->block->generate_editor("integral_{$category->id}", 'resource_category_form', $code_url, "{id: {$category->id}, type: 'integral'}"); echo block_editor("release_limit_{$category->id}", 'resource_category_form', $code_url, "{id: {$category->id}, type: 'release_limit'}"); echo block_editor("release_limit_wholelife_{$category->id}", 'resource_category_form', $code_url, "{id: {$category->id}, type: 'release_limit_wholelife'}"); } $data[] = $item; } if ('edit' == $action) { $title = lang('resource_category_manage'); } else { $title = lang('resource_category_view'); } echo block_header($title); echo form_open(); echo $this->block->generate_table($head, $data); echo form_close();
$shelf_code_str .= ' -> ' . block_div($shelf_code_div_id, $product->new_shelf_code); echo block_editor($shelf_code_div_id, 'name_form', $update_instock_url, "{id: {$apply_id}, type: 'shelf_code'}"); } else { $shelf_code_str = block_div($shelf_code_div_id, $product->shelf_code); echo block_editor($shelf_code_div_id, 'name_form', $update_instock_url, "{id: {$apply_id}, type: 'old_shelf_code', sku: '{$product->sku}'}"); } $item = array($this->block->generate_select_checkbox($apply_id), get_status_image($product->sku) . $product->sku, $shelf_code_str, $this->block->generate_image($product->image_url), $product->name_cn . '<br/>' . $product->name_en, $product->u_name, $product->stock_count); if (isset($product->order_sku_id)) { $apply_user = fetch_user_name_by_id($product->user_id); $item[] = $apply_user; } else { $item[] = ''; } $change_count_div_id = 'change_count_' . $apply_id; $item[] = block_div($change_count_div_id, $product->change_count); echo block_editor($change_count_div_id, 'name_form', $update_instock_url, "{id: {$apply_id}, type: 'change_count'}"); $item[] = $product->updated_time; $item[] = $options; $data[] = $item; } $options = array(); $options[''] = lang('all'); foreach ($purchase_users as $purchase_user) { $options[$purchase_user->u_id] = $purchase_user->u_name; } $filters = array(NULL, array('type' => 'input', 'field' => 'sku', 'method' => '='), array('type' => 'input', 'field' => 'shelf_code'), NULL, array('type' => 'input', 'field' => 'product_basic.name_cn|product_basic.name_en'), array('type' => 'dropdown', 'field' => 'user.id', 'options' => $options, 'method' => '='), array('type' => 'input', 'field' => 'product_more.stock_count', 'size' => 6), NUll); $config = array('filters' => $filters); echo block_header(lang('product_instock_verify')); echo $this->block->generate_pagination('product_apply'); echo form_open(); echo $this->block->generate_reset_search($config);
<?php $url = site_url('admin/crontab/crontab_add_row'); $add_button = $this->block->generate_add_icon($url); $head = array(lang('on'), lang('job'), lang('description'), lang('creator'), lang('created_date'), lang('options') . $add_button); $data = array(); $crontab_url = site_url('admin/crontab/verify_crontab'); foreach ($crontabresult as $show_result) { $drop_button = $this->block->generate_drop_icon('admin/crontab/crontab_delete', "{id: {$show_result->id}}", TRUE); $data[] = array($this->block->generate_div("on_{$show_result->id}", empty($show_result->on) ? '[edit]' : $show_result->on), $this->block->generate_div("job_{$show_result->id}", empty($show_result->job) ? '[edit]' : $show_result->job), $this->block->generate_div("description_{$show_result->id}", empty($show_result->description) ? '[edit]' : $show_result->description), fetch_user_name_by_id($show_result->creator), $show_result->created_date, $drop_button); echo $this->block->generate_editor("on_{$show_result->id}", 'crontab_view_form', $crontab_url, "{id: {$show_result->id} ,type: 'on'}"); echo $this->block->generate_editor("job_{$show_result->id}", 'crontab_view_form', $crontab_url, "{id: {$show_result->id} ,type: 'job'}"); echo block_editor("description_{$show_result->id}", 'crontab_view_form', $crontab_url, "{id: {$show_result->id} ,type: 'description'}"); } $title = lang('admin_crontab'); echo block_header($title); echo $this->block->generate_table($head, $data); $activate_crontab_url = site_url('admin/crontab/activate_crontab'); $view_crontab_url = site_url('admin/crontab/view_crontab_list'); $config = array('name' => 'activate_crontab', 'id' => 'activate_crontab', 'value' => lang('activate_crontab_again'), 'type' => 'button', 'onclick' => "helper.ajax('{$activate_crontab_url}', {}, 1);"); $activate_crontab = '<div style="float: right; ">'; echo br(); $activate_crontab .= block_button($config); $attributes = "onclick=\"helper.update_content('{$view_crontab_url}', {}, 'crontab_list_div'); return false;\""; $activate_crontab .= ' ' . anchor(current_url(), lang('view_crontab_list'), $attributes); $activate_crontab .= '</div>'; echo $activate_crontab; echo '<div style="clear:both;"></div>'; echo '<div id="crontab_list_div" style="display:none;"></div>';