update
@@ -38,7 +38,9 @@
|
||||
"Bash(curl -L \"https://www.figma.com/api/mcp/asset/f8150959-3677-4d5c-85d9-70310533fb75\" -o \"c:/Users/APC/Downloads/work/agent_test/export_to_html/image/search_promo_banner.png\" --silent)",
|
||||
"WebFetch(domain:www.figma.com)",
|
||||
"Bash(curl -s -H \"X-Figma-Token: figd_uiWTwLaZj6DQBU16r7t9r8Ei9zOhD-fevGWEBPwp\" \"https://api.figma.com/v1/files/JmbJxl6r2KMggCtiJOc0gZ/nodes?ids=7-6456\")",
|
||||
"Bash(python -m json.tool)"
|
||||
"Bash(python -m json.tool)",
|
||||
"Bash(curl -s -o /dev/null -w \"%{http_code}\" http://local.agent_test/)",
|
||||
"Bash(curl -sk http://local.agent_test/)"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
|
Before Width: | Height: | Size: 594 KiB |
|
Before Width: | Height: | Size: 524 KiB |
|
Before Width: | Height: | Size: 216 KiB |
|
Before Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 154 KiB |
|
Before Width: | Height: | Size: 173 KiB |
112
convert_article.php
Normal file
@@ -0,0 +1,112 @@
|
||||
<?php
|
||||
// Read the full home.php
|
||||
$lines = file('c:/Users/tiepb/Downloads/Company/agent_test/data/home/home.php');
|
||||
$totalLines = count($lines);
|
||||
|
||||
// Find "article_home" line
|
||||
$articleHomeStart = null;
|
||||
foreach ($lines as $i => $line) {
|
||||
if (strpos($line, '"article_home"') !== false) {
|
||||
$articleHomeStart = $i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
echo "article_home starts at line: " . ($articleHomeStart + 1) . "\n";
|
||||
|
||||
// Extract everything from article_home to end (before ");")
|
||||
$rawSection = implode('', array_slice($lines, $articleHomeStart + 1, $totalLines - $articleHomeStart - 2));
|
||||
echo "Raw section length: " . strlen($rawSection) . "\n";
|
||||
|
||||
// Find all category keys with their positions
|
||||
preg_match_all('/^ *(\d+) *=>\s*\n/m', $rawSection, $matches, PREG_OFFSET_CAPTURE);
|
||||
echo "Category keys found: ";
|
||||
foreach ($matches[1] as $m) {
|
||||
echo $m[0] . " ";
|
||||
}
|
||||
echo "\n";
|
||||
|
||||
// Build sections
|
||||
$catKeys = [];
|
||||
$catPositions = [];
|
||||
foreach ($matches[1] as $i => $m) {
|
||||
$catKeys[] = (int)$m[0];
|
||||
// Find the [ after this position
|
||||
$afterHeader = $matches[0][$i][1] + strlen($matches[0][$i][0]);
|
||||
$catPositions[] = $afterHeader;
|
||||
}
|
||||
|
||||
$sections = [];
|
||||
for ($i = 0; $i < count($catKeys); $i++) {
|
||||
$start = $catPositions[$i];
|
||||
$end = isset($catPositions[$i+1]) ? $catPositions[$i+1] - strlen($matches[0][$i+1][0]) : strlen($rawSection);
|
||||
$chunk = trim(substr($rawSection, $start, $end - $start));
|
||||
|
||||
$data = json_decode($chunk, true);
|
||||
if (json_last_error() === JSON_ERROR_NONE) {
|
||||
$sections[$catKeys[$i]] = $data;
|
||||
echo "Category " . $catKeys[$i] . ": " . count($data) . " articles\n";
|
||||
} else {
|
||||
echo "Category " . $catKeys[$i] . ": JSON ERROR - " . json_last_error_msg() . "\n";
|
||||
// Show first 200 chars of chunk
|
||||
echo "Chunk: " . substr($chunk, 0, 200) . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($sections)) {
|
||||
echo "No sections parsed, exiting\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Helper function to export value as PHP array
|
||||
function phpExport($val, $indent = 0) {
|
||||
$pad = str_repeat(' ', $indent);
|
||||
$padInner = str_repeat(' ', $indent + 1);
|
||||
|
||||
if (is_null($val)) return 'NULL';
|
||||
if (is_bool($val)) return $val ? 'true' : 'false';
|
||||
if (is_int($val)) return (string)$val;
|
||||
if (is_float($val)) return (string)$val;
|
||||
if (is_string($val)) {
|
||||
$escaped = str_replace("\\", "\\\\", $val);
|
||||
$escaped = str_replace("'", "\\'", $escaped);
|
||||
return "'" . $escaped . "'";
|
||||
}
|
||||
if (is_array($val)) {
|
||||
if (empty($val)) return "array (\n$pad)";
|
||||
$items = [];
|
||||
foreach ($val as $k => $v) {
|
||||
$keyStr = is_int($k) ? "$k => " : "'" . addcslashes($k, "'\\") . "' => ";
|
||||
$items[] = $padInner . $keyStr . phpExport($v, $indent + 1);
|
||||
}
|
||||
return "array (\n" . implode(",\n", $items) . ",\n$pad)";
|
||||
}
|
||||
return var_export($val, true);
|
||||
}
|
||||
|
||||
// Keep lines 1 to articleHomeStart (0-indexed = lines 1..articleHomeStart)
|
||||
$header = implode('', array_slice($lines, 0, $articleHomeStart));
|
||||
|
||||
// Build article_home PHP array
|
||||
$output = $header;
|
||||
$output .= " 'article_home' => \n";
|
||||
$output .= " array (\n";
|
||||
|
||||
foreach ($sections as $catId => $articles) {
|
||||
$output .= " $catId => \n";
|
||||
$output .= " array (\n";
|
||||
foreach ($articles as $idx => $article) {
|
||||
$output .= " $idx => \n";
|
||||
$output .= " " . phpExport($article, 3) . ",\n";
|
||||
}
|
||||
$output .= " ),\n";
|
||||
}
|
||||
|
||||
$output .= " ),\n";
|
||||
$output .= ");\n";
|
||||
|
||||
file_put_contents('c:/Users/tiepb/Downloads/Company/agent_test/data/home/home.php', $output);
|
||||
echo "Done! Written " . strlen($output) . " bytes\n";
|
||||
|
||||
$result = shell_exec('php -l "c:/Users/tiepb/Downloads/Company/agent_test/data/home/home.php" 2>&1');
|
||||
echo "PHP syntax: $result\n";
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -5,8 +5,8 @@ return [
|
||||
"banner_slider_homepage_mobile" => [
|
||||
[
|
||||
"id" => 148,
|
||||
"display" => '<img border=0 src="/media/banner/banner_mobile.png" width="414" height="159" alt=""/>',
|
||||
"fileUrl" => "/media/banner/banner_mobile.png",
|
||||
"display" => '<img border=0 src="http://miq.vn/media/banner/banner_mobile.png" width="414" height="159" alt=""/>',
|
||||
"fileUrl" => "http://miq.vn/media/banner/banner_mobile.png",
|
||||
"desUrl" => "/ad.php?id=148",
|
||||
"title" => "",
|
||||
"width" => 414,
|
||||
@@ -16,8 +16,8 @@ return [
|
||||
],
|
||||
[
|
||||
"id" => 149,
|
||||
"display" => '<img border=0 src="/media/banner/banner_mobile.png" width="414" height="159" alt=""/>',
|
||||
"fileUrl" => "/media/banner/banner_mobile.png",
|
||||
"display" => '<img border=0 src="http://miq.vn/media/banner/banner_mobile.png" width="414" height="159" alt=""/>',
|
||||
"fileUrl" => "http://miq.vn/media/banner/banner_mobile.png",
|
||||
"desUrl" => "/ad.php?id=149",
|
||||
"title" => "",
|
||||
"width" => 414,
|
||||
@@ -30,8 +30,8 @@ return [
|
||||
"banner_slider_homepage" => [
|
||||
[
|
||||
"id" => 150,
|
||||
"display" => '<img border=0 src="/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "/media/banner/bannerslider.png",
|
||||
"display" => '<img border=0 src="http://miq.vn/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "http://miq.vn/media/banner/bannerslider.png",
|
||||
"desUrl" => "/ad.php?id=150",
|
||||
"title" => "",
|
||||
"width" => 2400,
|
||||
@@ -41,8 +41,8 @@ return [
|
||||
],
|
||||
[
|
||||
"id" => 150,
|
||||
"display" => '<img border=0 src="/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "/media/banner/bannerslider.png",
|
||||
"display" => '<img border=0 src="http://miq.vn/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "http://miq.vn/media/banner/bannerslider.png",
|
||||
"desUrl" => "/ad.php?id=150",
|
||||
"title" => "",
|
||||
"width" => 2400,
|
||||
@@ -52,8 +52,8 @@ return [
|
||||
],
|
||||
[
|
||||
"id" => 150,
|
||||
"display" => '<img border=0 src="/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "/media/banner/bannerslider.png",
|
||||
"display" => '<img border=0 src="http://miq.vn/media/banner/bannerslider.png" width="2400" height="920" alt=""/>',
|
||||
"fileUrl" => "http://miq.vn/media/banner/bannerslider.png",
|
||||
"desUrl" => "/ad.php?id=150",
|
||||
"title" => "",
|
||||
"width" => 2400,
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
9006
data/home/home.php
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
250
data/menu.php
@@ -1,60 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Nội dung",
|
||||
"icon_class" => 'users',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'article',
|
||||
'view' => 'home',
|
||||
'id' => 'article/home',
|
||||
'name' => 'Tin bài',
|
||||
"icon_class" => '',
|
||||
'url' => '/article',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'media',
|
||||
'view' => 'home',
|
||||
'id' => 'media/home',
|
||||
'name' => 'Thư viện file Media',
|
||||
"icon_class" => '',
|
||||
'url' => '/media',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'page',
|
||||
'view' => 'home',
|
||||
'id' => 'page/home',
|
||||
'name' => 'Nội dung cố định',
|
||||
"icon_class" => '',
|
||||
'url' => '/page',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'album',
|
||||
'view' => 'home',
|
||||
'id' => 'album/home',
|
||||
'name' => 'Thư viện ảnh',
|
||||
"icon_class" => '',
|
||||
'url' => '/album',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'video',
|
||||
'view' => 'home',
|
||||
'id' => 'video/home',
|
||||
'name' => 'Video',
|
||||
"icon_class" => '',
|
||||
'url' => '/video',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,36 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
|
||||
"name" => "Hỏi đáp",
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
0 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'ask',
|
||||
'view' => 'home',
|
||||
'id' => 'ask/home',
|
||||
'name' => 'Danh sách câu hỏi',
|
||||
'url' => '/ask',
|
||||
),
|
||||
|
||||
1 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'ask',
|
||||
'view' => 'answer-list',
|
||||
'id' => 'ask/answer-list',
|
||||
'name' => 'Danh sách trả lời',
|
||||
'url' => '/ask/answer-list',
|
||||
),
|
||||
|
||||
2 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'ask',
|
||||
'view' => 'category',
|
||||
'id' => 'ask/ask',
|
||||
'name' => 'Danh mục hỏi đáp',
|
||||
'url' => '/ask/category',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,80 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Khách hàng",
|
||||
"icon_class" => 'user',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'home',
|
||||
'id' => 'customer/home',
|
||||
'name' => 'Danh sách khách hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer',
|
||||
),
|
||||
|
||||
/*array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'customer-group',
|
||||
'id' => 'customer/customer-group',
|
||||
'name' => 'Nhóm khách hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/customer-group',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'customer-contact',
|
||||
'id' => 'customer/customer-contact',
|
||||
'name' => 'Khách hàng liên hệ',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/customer-contact',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'comment',
|
||||
'id' => 'customer/comment',
|
||||
'name' => 'Tổng hợp trao đổi',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/comment',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'review',
|
||||
'id' => 'customer/review',
|
||||
'name' => 'Tổng hợp Đánh giá',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/review',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'customer-review',
|
||||
'id' => 'customer/customer-review',
|
||||
'name' => 'Khách hàng góp ý',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/customer-review',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'customer',
|
||||
'view' => 'customer-newsletter',
|
||||
'id' => 'customer/customer-newsletter',
|
||||
'name' => 'Khách hàng nhận bản tin',
|
||||
"icon_class" => '',
|
||||
'url' => '/customer/customer-newsletter',
|
||||
),
|
||||
|
||||
),
|
||||
);
|
||||
@@ -1,19 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Đại lý",
|
||||
"icon_class" => 'shopping-bag',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
0 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'distributor',
|
||||
'view' => 'home',
|
||||
'id' => 'distributor/home',
|
||||
'name' => 'Danh sách',
|
||||
"icon_class" => '',
|
||||
'url' => '/distributor',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,73 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Quan hệ cổ đông",
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'annual_report',
|
||||
'name' => 'Báo cáo thường niên',
|
||||
'id' => 'investor_relation/annual_report',
|
||||
'url' => '/investor_relation/annual_report',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'charter',
|
||||
'name' => 'Điều lệ hoạt động',
|
||||
'id' => 'investor_relation/charter',
|
||||
'url' => '/investor_relation/charter',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'governance',
|
||||
'name' => 'Quy chế quản trị',
|
||||
'id' => 'investor_relation/governance',
|
||||
'url' => '/investor_relation/governance',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'financial_reports',
|
||||
'name' => 'Báo cáo tài chính',
|
||||
'id' => 'investor_relation/financial_reports',
|
||||
'url' => '/investor_relation/financial_reports',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'info_disclosure',
|
||||
'name' => 'Công bố thông tin',
|
||||
'id' => 'investor_relation/info_disclosure',
|
||||
'url' => '/investor_relation/info_disclosure',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'management_report',
|
||||
'name' => 'Báo cáo quản trị',
|
||||
'id' => 'investor_relation/management_report',
|
||||
'url' => '/investor_relation/management_report',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'shareholder_meeting',
|
||||
'name' => 'Đại hội cổ đông',
|
||||
'id' => 'investor_relation/shareholder_meeting',
|
||||
'url' => '/investor_relation/shareholder_meeting',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'investor_relation',
|
||||
'view' => 'whitepaper',
|
||||
'name' => 'Báo cáo bạch',
|
||||
'id' => 'investor_relation/whitepaper',
|
||||
'url' => '/investor_relation/whitepaper',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,27 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Tuyển dụng",
|
||||
"icon_class" => 'megaphone',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'job',
|
||||
'view' => 'home',
|
||||
'id' => 'job/home',
|
||||
'name' => 'Vị trí tuyển',
|
||||
'url' => '/job',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'job',
|
||||
'view' => 'home',
|
||||
'id' => 'job/home',
|
||||
'name' => 'Quản lý hồ sơ',
|
||||
'url' => '/job/applicants',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,179 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Marketing",
|
||||
"icon_class" => 'newspaper',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'promotion',
|
||||
'id' => 'marketing/promotion',
|
||||
'name' => 'Khuyến mại theo sản phẩm',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/promotion',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'coupon',
|
||||
'id' => 'marketing/coupon',
|
||||
'name' => 'Phiếu giảm giá - Voucher',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/coupon',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'banner',
|
||||
'view' => 'home',
|
||||
'id' => 'banner/home',
|
||||
'name' => 'Danh sách banner',
|
||||
"icon_class" => '',
|
||||
'url' => '/banner',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'store-design',
|
||||
'id' => 'system/store-design',
|
||||
'name' => 'Banner pop-up',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/store-design?section=popup',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'poster-upload',
|
||||
'id' => 'marketing/poster-upload',
|
||||
'name' => 'Poster',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/poster-upload',
|
||||
),
|
||||
|
||||
/* array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'store-design',
|
||||
'id' => 'system/store-design',
|
||||
'name' => 'Hình nền website',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/store-design?section=background',
|
||||
),*/
|
||||
|
||||
/* array(
|
||||
'enable' => true,
|
||||
'module' => 'email',
|
||||
'view' => 'home',
|
||||
'id' => 'email/home',
|
||||
'name' => 'Email',
|
||||
"icon_class" => '',
|
||||
'url' => '/email',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true,
|
||||
'module' => 'url',
|
||||
'view' => 'meta-list',
|
||||
'id' => 'url/meta-list',
|
||||
'name' => 'Sửa thông tin URL',
|
||||
"icon_class" => '',
|
||||
'url' => '/url/meta-list',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true,
|
||||
'module' => 'url',
|
||||
'view' => 'url-seo',
|
||||
'id' => 'url/url-seo',
|
||||
'name' => 'Link SEO',
|
||||
"icon_class" => '',
|
||||
'url' => '/url/url-seo',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'feed',
|
||||
'id' => 'marketing/feed',
|
||||
'name' => 'Facebook/Google Feed',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/feed',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'product-offer',
|
||||
'id' => 'marketing/product-offer',
|
||||
'name' => 'Cài biểu tượng giảm giá',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/product-offer',
|
||||
),
|
||||
|
||||
/*array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'lead-program',
|
||||
'id' => 'marketing/lead-program',
|
||||
'name' => 'Thu thập khách hàng',
|
||||
'url' => '/marketing/lead-program',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'program',
|
||||
'id' => 'marketing/program',
|
||||
'name' => 'Chương trình khuyến mại',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/program',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'deal',
|
||||
'view' => 'home',
|
||||
'id' => 'deal/home',
|
||||
'name' => 'Deal/giờ vàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/deal',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'combo-deal',
|
||||
'id' => 'marketing/combo-deal',
|
||||
'name' => 'Bán Combo',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/combo-deal',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'conditional-promotion',
|
||||
'id' => 'marketing/conditional-promotion',
|
||||
'name' => 'Khuyến mại BuildPC',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/conditional-promotion',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'marketing',
|
||||
'view' => 'live-support-per-category',
|
||||
'id' => 'marketing/live-support-per-category',
|
||||
'name' => 'Hỗ trợ theo từng danh mục',
|
||||
"icon_class" => '',
|
||||
'url' => '/marketing/live-support-per-category',
|
||||
),
|
||||
|
||||
),
|
||||
);
|
||||
@@ -1,59 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Bán hàng",
|
||||
"icon_class" => "store",
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'order',
|
||||
'view' => 'home',
|
||||
'id' => 'order/home',
|
||||
'name' => 'Danh sách đơn hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/order', // &list=new
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'order',
|
||||
'view' => 'bargain',
|
||||
'id' => 'order/bargain',
|
||||
'name' => 'Mặc cả giá',
|
||||
"icon_class" => '',
|
||||
'url' => '/order/bargain',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'order',
|
||||
'view' => 'wait-order',
|
||||
'id' => 'order/wait-order',
|
||||
'name' => 'Chờ mua sản phẩm',
|
||||
"icon_class" => '',
|
||||
'url' => '/order/wait-order',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'order',
|
||||
'view' => 'paygate',
|
||||
'id' => 'order/paygate',
|
||||
'name' => 'Thanh toán qua cổng dịch vụ',
|
||||
"icon_class" => '',
|
||||
'url' => '/order/paygate',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'order',
|
||||
'view' => 'price-quote',
|
||||
'id' => 'order/price-quote',
|
||||
'name' => 'Lập báo giá',
|
||||
"icon_class" => '',
|
||||
'url' => '/order/price-quote',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,36 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Trả góp",
|
||||
"icon_class" => "handshake",
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'payinstall',
|
||||
'view' => 'order',
|
||||
'id' => 'payinstall/order',
|
||||
'name' => 'Danh sách đơn hàng',
|
||||
'url' => '/payinstall/order',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'payinstall',
|
||||
'view' => 'home',
|
||||
'id' => 'payinstall/home',
|
||||
'name' => 'Cài đặt trả góp',
|
||||
'url' => '/payinstall',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'payinstall',
|
||||
'view' => 'category',
|
||||
'id' => 'payinstall/category',
|
||||
'name' => 'Danh mục sản phẩm',
|
||||
'url' => '/payinstall/category',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,29 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Xây dựng máy tính",
|
||||
"icon_class" => 'monitor-smartphone',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'pcbuilder',
|
||||
'view' => 'home',
|
||||
'id' => 'pcbuilder/home',
|
||||
'name' => 'Linh kiện xây dựng',
|
||||
'url' => '/pcbuilder',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'pcbuilder',
|
||||
'view' => 'preconfig',
|
||||
'id' => 'pcbuilder/preconfig',
|
||||
'name' => 'Bộ máy tính mẫu',
|
||||
'url' => '/pcbuilder/preconfig',
|
||||
),
|
||||
),
|
||||
|
||||
|
||||
);
|
||||
@@ -1,175 +0,0 @@
|
||||
<?php
|
||||
|
||||
// set 'enable' => true|false per client instead of commenting out
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Sản phẩm",
|
||||
"icon_class" => 'package',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'home',
|
||||
'id' => 'product/home',
|
||||
'name' => 'Sản phẩm',
|
||||
"icon_class" => '',
|
||||
'url' => '/product',
|
||||
),
|
||||
|
||||
/* array(
|
||||
'enable' => false ,
|
||||
'module' => 'product',
|
||||
'view' => 'user-rating',
|
||||
'id' => 'product/user-rating',
|
||||
'name' => 'Đánh giá ',
|
||||
'url' => '/product/user-rating',
|
||||
),*/
|
||||
|
||||
/*array(
|
||||
'enable' => false ,
|
||||
'module' => 'product',
|
||||
'view' => 'product-customer-image',
|
||||
'id' => 'product/product-customer-image',
|
||||
'name' => 'Ảnh người dùng gửi',
|
||||
'url' => '/product/product-customer-image',
|
||||
),*/
|
||||
|
||||
/*array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'product-list-update',
|
||||
'id' => 'product/product-list-update',
|
||||
'name' => 'Bảng giá cập nhật',
|
||||
'url' => '/product/product-list-update',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'category',
|
||||
'id' => 'product/category',
|
||||
'name' => 'Danh mục',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/category',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'brand',
|
||||
'view' => 'home',
|
||||
'id' => 'brand/home',
|
||||
'name' => 'Thương hiệu',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/brand',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'attribute',
|
||||
'id' => 'product/attribute',
|
||||
'name' => 'Thuộc tính ',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/attribute',
|
||||
),
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'collection',
|
||||
'id' => 'product/collection',
|
||||
'name' => 'Bộ sưu tập',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/collection',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => false ,
|
||||
'module' => 'product',
|
||||
'view' => 'product-wait-list',
|
||||
'id' => 'product/product-wait-list',
|
||||
'name' => 'Chờ mua sản phẩm',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/product-wait-list',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'addon',
|
||||
'view' => 'home',
|
||||
'id' => 'addon/home',
|
||||
'name' => 'SP/Dịch vụ mua kèm',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/addon',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'config_group',
|
||||
'view' => 'home',
|
||||
'id' => 'config_group/home',
|
||||
'name' => 'Nhóm cấu hình',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/config_group',
|
||||
),
|
||||
|
||||
/*array(
|
||||
'enable' => false ,
|
||||
'module' => 'supplier',
|
||||
'view' => 'home',
|
||||
'id' => 'supplier/home',
|
||||
'name' => 'Nhà cung cấp',
|
||||
"icon_class" => '',
|
||||
'url' => '/supplier',
|
||||
),*/
|
||||
|
||||
/* array(
|
||||
'enable' => false ,
|
||||
'module' => 'product',
|
||||
'view' => 'set-promotion-price',
|
||||
'id' => 'product/set-promotion-price',
|
||||
'name' => 'Cài đặt giá khuyến mại',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/set-promotion-price',
|
||||
),*/
|
||||
|
||||
/*array(
|
||||
'enable' => false ,
|
||||
'module' => 'product',
|
||||
'view' => 'product-per-customer-group',
|
||||
'id' => 'product/product-per-customer-group',
|
||||
'name' => 'Giá theo nhóm khách hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/product-per-customer-group',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'set',
|
||||
'id' => 'product/set',
|
||||
'name' => 'Set sản phẩm',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/set',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'spec-group',
|
||||
'id' => 'product/spec-group',
|
||||
'name' => 'Nhóm thông số kỹ thuật',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/spec-group',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'product',
|
||||
'view' => 'list-competitor',
|
||||
'id' => 'product/list-competitor',
|
||||
'name' => 'So sánh giá đối thủ',
|
||||
"icon_class" => '',
|
||||
'url' => '/product/list-competitor',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,90 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
|
||||
"name" => "Thống kê",
|
||||
"icon_class" => 'pie-chart',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'visitor',
|
||||
'id' => 'report/visitor',
|
||||
'name' => 'Thống kê truy cập',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/visitor',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'customer',
|
||||
'id' => 'report/customer',
|
||||
'name' => 'Thống kê khách hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/customer',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'order',
|
||||
'id' => 'report/order',
|
||||
'name' => 'Thống kê đơn hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/order',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'product-buy',
|
||||
'id' => 'report/product-buy',
|
||||
'name' => 'Sản phẩm mua nhiều',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/product-buy',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'product-visit',
|
||||
'id' => 'report/product-visit',
|
||||
'name' => 'Sản phẩm xem nhiều',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/product-visit',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'referer',
|
||||
'id' => 'report/referer',
|
||||
'name' => 'Web giới thiệu',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/referer',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'search',
|
||||
'id' => 'report/search',
|
||||
'name' => 'Từ khóa tìm kiếm',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/search',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'report',
|
||||
'view' => 'error-page',
|
||||
'id' => '',
|
||||
'name' => 'Lỗi website',
|
||||
"icon_class" => '',
|
||||
'url' => '/report/error-page',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,192 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
"name" => "Hệ thống",
|
||||
"icon_class" => 'settings',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'settings',
|
||||
'id' => 'system/settings',
|
||||
'name' => 'Cài đặt chung',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/settings',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'template',
|
||||
'view' => 'home',
|
||||
'id' => 'template/home',
|
||||
'name' => 'Sửa file template',
|
||||
"icon_class" => '',
|
||||
'url' => '/template',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'admin',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Quản trị viên',
|
||||
"icon_class" => '',
|
||||
'url' => '/admin',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'store-address',
|
||||
'id' => '',
|
||||
'name' => 'Địa chỉ cửa hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/store-address',
|
||||
),
|
||||
|
||||
4 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'domain',
|
||||
'id' => 'system/domain',
|
||||
'name' => 'Cài đặt tên miền',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/domain',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'ban-ip',
|
||||
'id' => '',
|
||||
'name' => 'Chặn IP truy cập website',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/ban-ip',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'change-info',
|
||||
'id' => '',
|
||||
'name' => 'Thông tin website',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/change-info',
|
||||
),
|
||||
|
||||
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'province-list',
|
||||
'id' => '',
|
||||
'name' => 'Cài đặt tỉnh thành',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/province-list',
|
||||
),
|
||||
|
||||
9 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Tình trạng đơn hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/order-status',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'online_support',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Hỗ trợ bán hàng',
|
||||
"icon_class" => '',
|
||||
'url' => '/online_support',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'country',
|
||||
'id' => '',
|
||||
'name' => 'Quốc gia',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/country',
|
||||
),
|
||||
|
||||
12 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'report_out',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Cài đặt thông báo ngoài',
|
||||
"icon_class" => '',
|
||||
'url' => '/report_out',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'shipping2',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Cài đặt phí vận chuyển',
|
||||
"icon_class" => '',
|
||||
'url' => '/shipping2',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'url',
|
||||
'view' => 'redirect',
|
||||
'id' => 'url/redirect',
|
||||
'name' => 'Url Redirect',
|
||||
"icon_class" => '',
|
||||
'url' => '/url/redirect',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'tool',
|
||||
'view' => 'home',
|
||||
'id' => 'tool/home',
|
||||
'name' => 'Công cụ',
|
||||
"icon_class" => '',
|
||||
'url' => '/tool',
|
||||
),
|
||||
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'menu',
|
||||
'view' => 'home',
|
||||
'id' => 'menu/home',
|
||||
'name' => 'Quản trị menu',
|
||||
"icon_class" => '',
|
||||
'url' => '/menu',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'system',
|
||||
'view' => 'keyword-suggest',
|
||||
'id' => 'system/keyword-suggest',
|
||||
'name' => 'Từ khóa gợi ý',
|
||||
"icon_class" => '',
|
||||
'url' => '/system/keyword-suggest',
|
||||
),
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'tag',
|
||||
'view' => 'home',
|
||||
'id' => 'tag/home',
|
||||
'name' => 'Quản trị Tag',
|
||||
"icon_class" => '',
|
||||
'url' => '/tag',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1,28 +0,0 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'enable' => true ,
|
||||
|
||||
"name" => "Bảo hành sản phẩm",
|
||||
"icon_class" => '',
|
||||
"url" => "",
|
||||
"menu" => array(
|
||||
/*0 => array(
|
||||
'enable' => true ,
|
||||
'module' => 'warranty',
|
||||
'view' => 'home',
|
||||
'id' => '',
|
||||
'name' => 'Khách hàng đăng ký',
|
||||
'url' => '/warranty/customer-register',
|
||||
),*/
|
||||
|
||||
array(
|
||||
'enable' => true ,
|
||||
'module' => 'warranty',
|
||||
'view' => 'home',
|
||||
'id' => 'warranty/home',
|
||||
'name' => 'Danh sách bảo hành',
|
||||
'url' => '/warranty',
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1,55 +0,0 @@
|
||||
<?php
|
||||
|
||||
|
||||
use Hura8\Components\Order\AdminController\AOrderController;
|
||||
use Hura8\Components\Order\Controller\OrderStatus;
|
||||
use Hura8\System\Paging;
|
||||
|
||||
$numPerPage = 30;
|
||||
|
||||
$conditions = array(
|
||||
'orderCode' => getRequest('orderCode', ''),
|
||||
'q' => getRequest('q', ''),
|
||||
//'coupon' => getRequest('coupon', ''),
|
||||
'cus_id' => getRequest('cus_id', ''),
|
||||
'province' => getRequest('province', ''),
|
||||
//'district' => getRequest('district', ''),
|
||||
'folder' => getRequest('folder', ''),
|
||||
'view_status' => getRequest('view_status', ''),
|
||||
'update_by' => getRequest('update_by', ''),
|
||||
//'shipping_status' => getRequest('shipping_status', ''),
|
||||
'assign_to' => getRequest('assign_to', ''),
|
||||
'from_date' => getRequest('from_date', ''),
|
||||
'to_date' => getRequest('to_date', ''),
|
||||
//'from_hour' => getRequest('from_hour', ''),
|
||||
//'to_hour' => getRequest('to_hour', ''),
|
||||
'payment' => getRequest('payment', ''),
|
||||
'fullfillment' => getRequest('fullfillment', ''),
|
||||
'status' => getRequest('status', ''),
|
||||
//'excluded_ids' => getRequest('', ''),
|
||||
//'included_ids' => getRequest('', ''),
|
||||
'list' => getRequest('list', ''),
|
||||
'numPerPage' => $numPerPage,
|
||||
'page' => getPageId(),
|
||||
);
|
||||
|
||||
$objAOrderController = new AOrderController();
|
||||
$totalResults = $objAOrderController->getTotal($conditions);
|
||||
$item_list = $objAOrderController->getList($conditions);
|
||||
|
||||
//debug_var($item_list);
|
||||
|
||||
list($page_collection, $tb_page, $total_pages) = Paging::paging_template($totalResults, $numPerPage);
|
||||
|
||||
return [
|
||||
"total" => $totalResults,
|
||||
"item_list" => $item_list,
|
||||
"pagination" => [
|
||||
'collection' => $page_collection,
|
||||
'html' => $tb_page,
|
||||
'total_pages' => $total_pages,
|
||||
],
|
||||
"order_status_list" => OrderStatus::ORDER_STATUS ,
|
||||
"payment_status_list" => OrderStatus::PAYMENT_STATUS,
|
||||
"fullfillment_status_list" => OrderStatus::FULFILLMENT_STATUS ,
|
||||
];
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
|
||||
|
||||
use Hura8\Components\Product\AdminController\AProductCategoryController;
|
||||
|
||||
$objAProductCategoryController = new AProductCategoryController();
|
||||
|
||||
|
||||
$id = (int) getRequest("id");
|
||||
$item_info = ($id > 0) ? $objAProductCategoryController->getFullInfo($id) : null;
|
||||
if(!$item_info) $item_info = $objAProductCategoryController->getEmptyInfo([]);
|
||||
|
||||
|
||||
return [
|
||||
'item_info' => $item_info,
|
||||
'categoryDropBox' => $objAProductCategoryController->getDropBox( $item_info['parent_id'], 0, 1),
|
||||
'update_status' => getRequest("us"),
|
||||
];
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
353
data/product/detail.php
Normal file
@@ -1,174 +0,0 @@
|
||||
<?php
|
||||
|
||||
|
||||
use Hura8\Components\Product\AdminController\AProductController;
|
||||
|
||||
|
||||
$objAProductController = new AProductController();
|
||||
$product_id = getRequestInt('id', 0);
|
||||
|
||||
$product_info = $objAProductController->getFullInfo($product_id);
|
||||
|
||||
$view_part = getRequest("part", "basic");
|
||||
|
||||
$view_part_file = str_replace("-", "_", $view_part);
|
||||
|
||||
$part_file = __DIR__."/form_components/". $view_part_file .".php";
|
||||
if(@file_exists($part_file)) {
|
||||
include $part_file;
|
||||
}else{
|
||||
die("File: /form_components/". $view_part_file .".php does not exist!");
|
||||
}
|
||||
|
||||
|
||||
return [
|
||||
"product_info" => $product_info,
|
||||
"product_menu" => _get_product_menu(),
|
||||
"view_part" => $view_part,
|
||||
];
|
||||
|
||||
// helpers
|
||||
|
||||
function _get_product_menu() {
|
||||
$current_selected = getRequest('part', 'basic');
|
||||
$product_menu = array(
|
||||
array(
|
||||
'id' => 'basic',
|
||||
"name" => "Cơ bản",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'store',
|
||||
"name" => "Cửa hàng",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'category',
|
||||
"name" => "Danh mục",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'seo',
|
||||
"name" => "SEO",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'description',
|
||||
"name" => "Mô tả",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'spec-group',
|
||||
"name" => "Thông số kỹ thuật",//"Thông số",
|
||||
),
|
||||
|
||||
/*"spec" => array(
|
||||
"name" => "Thông số kỹ thuật nhập text", //"Bộ lọc thuộc tính", //"Thông số",
|
||||
"must_have_id" => true,
|
||||
"change_language" => true,
|
||||
),*/
|
||||
|
||||
/*"image-spec" => array(
|
||||
"name" => "Ảnh thông số",
|
||||
"must_have_id" => true,
|
||||
"change_language" => true,
|
||||
),*/
|
||||
|
||||
array(
|
||||
'id' => 'instruction',
|
||||
"name" => "Hướng dẫn sử dụng",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'image',
|
||||
"name" => "Ảnh",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'variant',
|
||||
"name" => "Cấu hình",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'accessory',
|
||||
"name" => "Phụ kiện",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'addon',
|
||||
"name" => "Dịch vụ/SP đi kèm",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'video',
|
||||
"name" => "Youtube",
|
||||
),
|
||||
|
||||
/* "video-list" => array(
|
||||
"name" => "Thư viện Youtube",
|
||||
"must_have_id" => true,
|
||||
"change_language" => false,
|
||||
),*/
|
||||
|
||||
/*"relate-article" => array(
|
||||
"name" => "Nội dung liên quan",
|
||||
"must_have_id" => true,
|
||||
"change_language" => false,
|
||||
),*/
|
||||
|
||||
/*"web-link" => array(
|
||||
"name" => "So sánh giá",
|
||||
"must_have_id" => true,
|
||||
"change_language" => false,
|
||||
),*/
|
||||
|
||||
array(
|
||||
'id' => 'tag',
|
||||
"name" => "Tags",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'relation',
|
||||
"name" => "Nội dung liên quan",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'customer-group',
|
||||
"name" => "Giá theo nhóm khách hàng",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'component',
|
||||
"name" => "Thành phần",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'configurable',
|
||||
"name" => "Tùy chọn thành phần",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'compatible',
|
||||
"name" => "Sp tương thích",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'similar',
|
||||
"name" => "Sp tương tự",
|
||||
),
|
||||
|
||||
array(
|
||||
'id' => 'combo-set',
|
||||
"name" => "Combo Set",
|
||||
),
|
||||
|
||||
);
|
||||
|
||||
return array_map(function ($item) use ($current_selected){
|
||||
$copy = $item;
|
||||
$copy['is_current'] = $item['id'] == $current_selected ? 1 : 0;
|
||||
|
||||
return $copy;
|
||||
|
||||
}, $product_menu);
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1,228 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Hura8\Components\Product\AdminController\AProductController;
|
||||
use Hura8\System\Paging;
|
||||
|
||||
$objAProductController = new AProductController();
|
||||
|
||||
//Paging setting
|
||||
$numPerPage = getPageSize(15);
|
||||
$conditions = [
|
||||
"category" => explode("-", getRequest("category", '')),
|
||||
"brand" => explode("-", getRequest("brand", '')),
|
||||
"hotType" => explode("-", getRequest("hotType", '')),
|
||||
"other_filter" => [getRequest("other_filter", '')],
|
||||
"q" => getRequest("q", ''),
|
||||
'numPerPage' => $numPerPage,
|
||||
'page' => getPageId(),
|
||||
'translated' => getRequestInt('translated', 0),
|
||||
//... more extended filters
|
||||
];
|
||||
//debug_var($objAProductController->getFilterConditions());
|
||||
|
||||
$totalResults = $objAProductController->getTotal($conditions);
|
||||
$item_list = $objAProductController->getList($conditions);
|
||||
|
||||
list($page_collection, $tb_page, $total_pages) = Paging::paging_template($totalResults, $numPerPage);
|
||||
|
||||
return [
|
||||
"total" => $totalResults,
|
||||
"item_list" => $item_list,
|
||||
"pagination" => [
|
||||
'collection' => $page_collection,
|
||||
'html' => $tb_page,
|
||||
'total_pages' => $total_pages,
|
||||
],
|
||||
|
||||
"list_category" => [
|
||||
[
|
||||
'id' => 1,
|
||||
'title' => 'Màn hình máy tính',
|
||||
'url' => '/admin/product?category=9',
|
||||
'parentId' => 0,
|
||||
'isParent' => 1,
|
||||
'children' => [
|
||||
[
|
||||
'id' => 10,
|
||||
'title' => 'Màn hình theo khoảng giá',
|
||||
'url' => '/admin/product?category=148',
|
||||
'parentId' => 1,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 0,
|
||||
'children' => [
|
||||
|
||||
]
|
||||
],
|
||||
[
|
||||
'id' => 11,
|
||||
'title' => 'Màn Hình Theo Kích Thước',
|
||||
'url' => '/admin/product?category=54',
|
||||
'parentId' => 1,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 0,
|
||||
'children' => [
|
||||
[
|
||||
'id' => 148,
|
||||
'title' => '17 inch - 21.5 inch',
|
||||
'url' => '/admin/product?category=148',
|
||||
'parentId' => 11,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 5,
|
||||
],
|
||||
[
|
||||
'id' => 66,
|
||||
'title' => '22 inch - 24 inch',
|
||||
'url' => '/admin/product?category=66',
|
||||
'parentId' => 11,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 41,
|
||||
],
|
||||
[
|
||||
'id' => 67,
|
||||
'title' => '25 inch - 27 inch',
|
||||
'url' => '/admin/product?category=67',
|
||||
'parentId' => 11,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 42,
|
||||
],
|
||||
[
|
||||
'id' => 68,
|
||||
'title' => '28 inch - 32 inch',
|
||||
'url' => '/admin/product?category=68',
|
||||
'parentId' => 11,
|
||||
'isParent' => 0,
|
||||
'totalProduct' => 11,
|
||||
]
|
||||
]
|
||||
]
|
||||
|
||||
]
|
||||
],
|
||||
[
|
||||
'id' => 65,
|
||||
'title' => 'PC, Workstation',
|
||||
'url' => '/admin/product?category=65',
|
||||
'parentId' => 0,
|
||||
'isParent' => 1,
|
||||
'children' => []
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'title' => 'Gaming Gear',
|
||||
'url' => '/admin/product?category=3',
|
||||
'parentId' => 0,
|
||||
'isParent' => 1,
|
||||
'children' => []
|
||||
],[
|
||||
'id' => 4,
|
||||
'title' => 'CPU - Bộ Vi Xử Lý',
|
||||
'url' => '/admin/product?category=4',
|
||||
'parentId' => 0,
|
||||
'isParent' => 1,
|
||||
'children' => []
|
||||
]
|
||||
|
||||
],
|
||||
|
||||
"brand_letters" => [
|
||||
[
|
||||
'key' => 'A',
|
||||
'url' => '/ajax/brand.php?action=show-brand-list&letter=A&popup=1',
|
||||
'total' => 13,
|
||||
],
|
||||
[
|
||||
'key' => 'B',
|
||||
'url' => '/ajax/brand.php?action=show-brand-list&letter=B&popup=1',
|
||||
'total' => 2,
|
||||
],
|
||||
[
|
||||
'key' => 'C',
|
||||
'url' => '/ajax/brand.php?action=show-brand-list&letter=C&popup=1',
|
||||
'total' => 5,
|
||||
]
|
||||
|
||||
],
|
||||
|
||||
"list_brands" => [
|
||||
|
||||
'A' => [
|
||||
[
|
||||
'id' => 1,
|
||||
'name' => 'ABS',
|
||||
'letter' => 'A',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 1,
|
||||
],
|
||||
[
|
||||
'id' => 2,
|
||||
'name' => 'ACE GAMING',
|
||||
'letter' => 'A',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'ADATA',
|
||||
'letter' => 'A',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 15,
|
||||
]
|
||||
],
|
||||
|
||||
'B' => [
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'BE QUIET ',
|
||||
'letter' => 'B',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 2,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'BENQ',
|
||||
'letter' => 'B',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
],
|
||||
|
||||
'C' => [
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'CISCO',
|
||||
'letter' => 'C',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 2,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'Colorful',
|
||||
'letter' => 'C',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'COOLER MASTER',
|
||||
'letter' => 'C',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'COOLMOON',
|
||||
'letter' => 'C',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
[
|
||||
'id' => 3,
|
||||
'name' => 'CORSAIR',
|
||||
'letter' => 'C',
|
||||
'url' => '/admin/?brand=83&opt=product',
|
||||
'product' => 6,
|
||||
],
|
||||
]
|
||||
]
|
||||
|
||||
];
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||
@@ -1 +0,0 @@
|
||||
<?php
|
||||