Browse Source

维保订单,报价金额

lizhen_gitee 6 months ago
parent
commit
c9534fc65b

+ 1 - 0
application/admin/lang/zh-cn/maintain.php

@@ -40,6 +40,7 @@ return [
     'Status 100'          => '验收通过已完成',
     'Set status to 100'   => '设为验收通过已完成',
     'Canceltime'          => '取消时间',
+    'Price'               => '报价金额',
     'Finishtime'          => '验收/完成时间',
     'Baojia_confirmtime'  => '报价确认时间',
     'Worker_id'           => '维修师傅ID',

+ 15 - 1
application/company/controller/Maintain.php

@@ -105,7 +105,7 @@ class Maintain extends Apic
             }
         }
 
-        $field = ['mt.id','mt.orderno','uc.projectname','mt.info','uc.header','mt.status'];
+        $field = ['mt.id','mt.orderno','uc.projectname','mt.info','uc.header','mt.status','mt.price'];
         $list = Db::name($this->table)->alias('mt')
             ->join('user_company uc','mt.uc_id = uc.id','LEFT')
             ->field($field)
@@ -445,4 +445,18 @@ class Maintain extends Apic
         $this->success();
     }
 
+    //修改报价金额
+    public function set_price(){
+        $id     = input('id',0);
+        $price  = input('price',0);
+
+        $update = [
+            'price'  => $price,
+            'updatetime' => time(),
+        ];
+        $rs_update = Db::name($this->table)->where('id',$id)->update($update);
+
+        $this->success();
+    }
+
 }

+ 1 - 1
public/assets/js/backend/maintain.js

@@ -39,7 +39,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
 
                         //                        {field: 'uc_id', title: __('Uc_id')},
                         {field: 'usercompany.projectname', title: __('Usercompany.projectname'), operate: 'LIKE', table: table, class: 'autocontent', formatter: Table.api.formatter.content},
-
+                        {field: 'price', title: __('Price'), operate:false},
 
                         {field: 'createtime', title: __('Createtime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
 //                        {field: 'updatetime', title: __('Updatetime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},