|
|
@@ -74,6 +74,7 @@ class PurchaseOrderController extends BaseController
|
|
|
{
|
|
|
$get = Yii::$app->request->get();
|
|
|
$id = $get['id'] ?? 0;
|
|
|
+ $type = $get['type'] ?? 0;
|
|
|
$item = PurchaseOrderItemClass::getById($id, true);
|
|
|
if (empty($item)) {
|
|
|
util::fail('没有找到花材');
|
|
|
@@ -110,16 +111,19 @@ class PurchaseOrderController extends BaseController
|
|
|
|
|
|
$p->times = $num;
|
|
|
$content = '<TEXT x="360" y="30" font="12" w="2" h="2" r="90">' . $name . '</TEXT>';
|
|
|
- $content .= '<BC128 x="260" y="30" h="70" s="1" r="90" n="4" w="11">' . $ptItemId . '</BC128>';
|
|
|
- if (in_array($mainId, [52, 1459])) {
|
|
|
- $content .= '<TEXT x="80" y="30" font="12" w="2" h="2" r="90">惠雅鲜花</TEXT>';
|
|
|
+
|
|
|
+ if ($type == 0) {
|
|
|
+ $content .= '<BC128 x="260" y="30" h="70" s="1" r="90" n="4" w="11">' . $ptItemId . '</BC128>';
|
|
|
+ if (in_array($mainId, [52, 1459])) {
|
|
|
+ $content .= '<TEXT x="80" y="30" font="12" w="2" h="2" r="90">惠雅鲜花</TEXT>';
|
|
|
+ } else {
|
|
|
+ $content .= '<TEXT x="80" y="30" font="12" w="2" h="2" r="90">' . $unit . '</TEXT>';
|
|
|
+ }
|
|
|
} else {
|
|
|
- $content .= '<TEXT x="80" y="30" font="12" w="2" h="2" r="90">' . $unit . '</TEXT>';
|
|
|
+ $content .= '<QR x="260" y="30" e="L" w="5">' . Yii::$app->params['mallHost'] . "/item/show-info?id=" . $productId . '</QR>';
|
|
|
+ $content .= '<TEXT x="80" y="30" font="12" w="1" h="1" r="90">扫码看价格</TEXT>';
|
|
|
}
|
|
|
|
|
|
- //$content .= '<QR x="30" y="390" e="L" w="5">' . Yii::$app->params['mallHost'] . "/item/show-info?id=" . $productId . '</QR>';
|
|
|
- //$content .= '<TEXT x="220" y="400" font="12" w="1" h="1" r="90">扫码看价格</TEXT>';
|
|
|
-
|
|
|
$p->printLabelMsg($content);
|
|
|
util::complete();
|
|
|
}
|