Changeset 42
- Timestamp:
- Sep 13, 2011, 2:10:45 PM (13 years ago)
- Location:
- addons/isp
- Files:
-
- 5 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
addons/isp/__init__.py
r16 r42 21 21 22 22 import isp 23 import res_partner 23 24 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: 24 25 -
addons/isp/__openerp__.py
r41 r42 27 27 'depends': [ 'base_tools' ], 28 28 'init_xml': [ ], 29 'update_xml': [ 'isp_view.xml' ],29 'update_xml': [ 'isp_view.xml', 'res_partner.xml' ], 30 30 'demo_xml': [ 'isp_demo.xml' ], 31 31 'installable': True, -
addons/isp/i18n/cs.po
r41 r42 8 8 "Report-Msgid-Bugs-To: support@openerp.com\n" 9 9 "POT-Creation-Date: 2011-09-13 07:48+0000\n" 10 "PO-Revision-Date: 2011-09-13 09:54+0100\n"10 "PO-Revision-Date: 2011-09-13 10:35+0100\n" 11 11 "Last-Translator: Chronos <robie@centrum.cz>\n" 12 12 "Language-Team: \n" … … 49 49 #: model:network.service.type,name:isp.service_internet 50 50 msgid "Internet" 51 msgstr " Rozhraní"51 msgstr "Internet" 52 52 53 53 #. module: isp … … 168 168 #: field:network.device.type,running_permanent:0 169 169 msgid "Running permanent" 170 msgstr "B 2žící nepřetržitě"170 msgstr "Běžící nepřetržitě" 171 171 172 172 #. module: isp -
addons/isp/isp.py
r41 r42 81 81 _columns = { 82 82 'name': fields.char('Name', size=32, required=True, translate=True), 83 'type_id': fields.many2one('network.interface.type', 'Type' , required=True),83 'type_id': fields.many2one('network.interface.type', 'Type'), 84 84 'interface_ids': fields.one2many('network.interface', 'link_id', 'Interfaces'), 85 85 'points_ids': fields.many2many('network.point', 'network_link_point_rel', 'link_id', 'point_id', 'Points'), … … 106 106 _columns = { 107 107 'name': fields.char('Name', size=32, required=True), 108 'parent ': fields.many2one('network.domain', 'Parent'),108 'parent_id': fields.many2one('network.domain', 'Parent'), 109 109 'alias': fields.char('Alias', size=32), 110 110 } … … 142 142 network_service_type() 143 143 144 class network_service_internet(osv.osv): 145 _name = "network.service.internet" 146 _columns = { 147 'name': fields.char('Name', size=32, required=True, translate=True), 148 'download_min_speed': fields.integer('Download min. speed', required=True), 149 'download_max_speed': fields.integer('Download max. speed', required=True), 150 'upload_min_speed': fields.integer('Upload min. speed', required=True), 151 'upload_max_speed': fields.integer('Upload max. speed', required=True), 152 } 153 network_service_internet() 154 155 class network_service_hosting_vps(osv.osv): 156 _name = "network.service.hosting.vps" 157 _columns = { 158 'name': fields.char('Name', size=32, required=True, translate=True), 159 'memory_capacity': fields.integer('Memory capacity', required=True, help='Total memory capacity of virtual machine in MB'), 160 'storage_capacity': fields.integer('Storage capacity', required=True, help='Total storage capacity of virtual machine in GB'), 161 } 162 network_service_hosting_vps() 163 144 164 class network_service(osv.osv): 145 165 _name = "network.service" … … 150 170 'price_period_id': fields.many2one('network.billing.period', 'Price period'), 151 171 'available': fields.boolean('Available', help='Define if service is available for customers'), 172 'standard': fields.boolean('Standard', help='Define if service is standard offer for customers'), 173 'partner_ids': fields.many2many('res_partner', 'network_service_partner_rel', 'service_id', 'partner_id', 'Partners'), 152 174 } 153 175 network_service() 154 176 155 177 class network_service_instance(osv.osv): 178 _name = "network.service" 179 _columns = { 180 'name': fields.char('Name', size=32, required=True, translate=True), 181 'type_id': fields.many2one('network.service.type', 'Type'), 182 'price': fields.integer('Price', help='Price per period'), 183 'price_period_id': fields.many2one('network.billing.period', 'Price period'), 184 'available': fields.boolean('Available', help='Define if service is available for customers'), 185 'standard': fields.boolean('Standard', help='Define if service is standard offer for customers'), 186 } 187 network_service() -
addons/isp/isp_demo.xml
r41 r42 5 5 <record model="network.device.type" id="device_type_desktop_pc"> 6 6 <field name="name">Desktop computer</field> 7 <field name="running_permanent" >0</field>7 <field name="running_permanent" eval="False"/> 8 8 </record> 9 9 <record model="network.device.type" id="device_type_notebook"> 10 10 <field name="name">Notebook</field> 11 <field name="running_permanent" >0</field>11 <field name="running_permanent" eval="False"/> 12 12 </record> 13 13 <record model="network.device.type" id="device_type_ipcam"> 14 14 <field name="name">IP camera</field> 15 <field name="running_permanent" >1</field>15 <field name="running_permanent" eval="True"/> 16 16 </record> 17 17 <record model="network.device.type" id="device_type_printer"> 18 18 <field name="name">Printer</field> 19 <field name="running_permanent" >0</field>19 <field name="running_permanent" eval="False"/> 20 20 </record> 21 21 <record model="network.device.type" id="device_type_server"> 22 22 <field name="name">Server</field> 23 <field name="running_permanent" >1</field>23 <field name="running_permanent" eval="True"/> 24 24 </record> 25 25 <record model="network.device.type" id="device_type_switch"> 26 26 <field name="name">Switch</field> 27 <field name="running_permanent" >1</field>27 <field name="running_permanent" eval="True"/> 28 28 </record> 29 29 <record model="network.device.type" id="device_type_router"> 30 30 <field name="name">Router</field> 31 <field name="running_permanent" >1</field>31 <field name="running_permanent" eval="True"/> 32 32 </record> 33 33 <record model="network.device.type" id="device_type_tv"> 34 34 <field name="name">Television</field> 35 <field name="running_permanent" >0</field>35 <field name="running_permanent" eval="False"/> 36 36 </record> 37 37 <record model="network.device.type" id="device_type_thermometer"> 38 38 <field name="name">Thermometer</field> 39 <field name="running_permanent" >1</field>39 <field name="running_permanent" eval="True"/> 40 40 </record> 41 41 <record model="network.device.type" id="device_type_voip"> 42 42 <field name="name">VoIP device</field> 43 <field name="running_permanent" >1</field>43 <field name="running_permanent" eval="True"/> 44 44 </record> 45 45 … … 47 47 <record model="network.interface.type" id="interface_type_ethernet_metalic"> 48 48 <field name="name">Metalic ethernet</field> 49 <field name="full_duplex" >1</field>49 <field name="full_duplex" eval="True"/> 50 50 </record> 51 51 <record model="network.interface.type" id="interface_type_ethernet_wifi_b"> 52 52 <field name="name">Wi-Fi 802.11b 11Mbit</field> 53 <field name="full_duplex" >0</field>53 <field name="full_duplex" eval="False"/> 54 54 </record> 55 55 <record model="network.interface.type" id="interface_type_ethernet_wifi_g"> 56 56 <field name="name">Wi-Fi 802.11g 54Mbit</field> 57 <field name="full_duplex" >0</field>57 <field name="full_duplex" eval="False"/> 58 58 </record> 59 59 <record model="network.interface.type" id="interface_type_ethernet_wifi_a"> 60 60 <field name="name">Wi-Fi 802.11a 54Mbit</field> 61 <field name="full_duplex" >0</field>61 <field name="full_duplex" eval="False"/> 62 62 </record> 63 63 <record model="network.interface.type" id="interface_type_ethernet_wifi_n_150"> 64 64 <field name="name">Wi-Fi 802.11n 150Mbit</field> 65 <field name="full_duplex" >0</field>65 <field name="full_duplex" eval="False"/> 66 66 </record> 67 67 <record model="network.interface.type" id="interface_type_ethernet_wifi_n_300"> 68 68 <field name="name">Wi-Fi 802.11n 300Mbit</field> 69 <field name="full_duplex" >0</field>69 <field name="full_duplex" eval="False"/> 70 70 </record> 71 71 <record model="network.interface.type" id="interface_type_optics"> 72 72 <field name="name">Optic ethernet</field> 73 <field name="full_duplex" >1</field>73 <field name="full_duplex" eval="True"/> 74 74 </record> 75 75 <record model="network.interface.type" id="interface_type_wireless_10G"> 76 76 <field name="name">Wireless 10 GHz</field> 77 <field name="full_duplex" >1</field>77 <field name="full_duplex" eval="True"/> 78 78 </record> 79 79 <record model="network.interface.type" id="interface_type_wireless_24G"> 80 80 <field name="name">Wireless 24 GHz</field> 81 <field name="full_duplex" >1</field>81 <field name="full_duplex" eval="True"/> 82 82 </record> 83 83 <record model="network.interface.type" id="interface_type_wireless_80G"> 84 84 <field name="name">Wireless 80 GHz</field> 85 <field name="full_duplex" >1</field>85 <field name="full_duplex" eval="True"/> 86 86 </record> 87 87 <record model="network.interface.type" id="interface_type_cdma"> 88 88 <field name="name">CDMA 450 MHz</field> 89 <field name="full_duplex" >0</field>89 <field name="full_duplex" eval="False"/> 90 90 </record> 91 91 <record model="network.interface.type" id="interface_type_homeplug"> 92 92 <field name="name">Homeplug over 230V</field> 93 <field name="full_duplex" >0</field>93 <field name="full_duplex" eval="False"/> 94 94 </record> 95 95 <record model="network.interface.type" id="interface_type_adsl"> 96 96 <field name="name">ADSL</field> 97 <field name="full_duplex" >0</field>97 <field name="full_duplex" eval="False"/> 98 98 </record> 99 99 <record model="network.interface.type" id="interface_type_vdsl"> 100 100 <field name="name">VDSL</field> 101 <field name="full_duplex" >0</field>101 <field name="full_duplex" eval="False"/> 102 102 </record> 103 103 <record model="network.interface.type" id="interface_type_3g"> 104 104 <field name="name">3G (UTMS, HSDPA)</field> 105 <field name="full_duplex" >0</field>105 <field name="full_duplex" eval="False"/> 106 106 </record> 107 107 <record model="network.interface.type" id="interface_type_wimax"> 108 108 <field name="name">WiMax</field> 109 <field name="full_duplex" >0</field>109 <field name="full_duplex" eval="False"/> 110 110 </record> 111 111 <record model="network.interface.type" id="interface_type_lte"> 112 112 <field name="name">LTE</field> 113 <field name="full_duplex" >0</field>113 <field name="full_duplex" eval="False"/> 114 114 </record> 115 115 … … 186 186 187 187 188 <record model="network.device" id="device_router ">189 <field name="name">Router </field>188 <record model="network.device" id="device_router_praha"> 189 <field name="name">Router Praha</field> 190 190 <field name="type_id" ref="device_type_router"/> 191 191 <field name="position" ref="point_praha"/> 192 <field name="partner_id" search="[]" model="res.partner"/> 193 </record> 194 <record model="network.device" id="device_router_brno"> 195 <field name="name">Router Brno</field> 196 <field name="type_id" ref="device_type_router"/> 197 <field name="position" ref="point_brno"/> 192 198 <field name="partner_id" search="[]" model="res.partner"/> 193 199 </record> … … 214 220 <field name="ipv6">2001:2442:C422::1</field> 215 221 </record> 222 <record model="network.address" id="address_router4"> 223 <field name="name">router4</field> 224 <field name="ipv4">10.0.0.2</field> 225 <field name="ipv6">2001:2442:C422::2</field> 226 </record> 216 227 217 228 218 229 <record model="network.link" id="interface_link1"> 219 230 <field name="name">link1</field> 231 <field name="point_ids" eval="[(4, ref('point_praha')), 232 (4, ref('point_ostrava'))]"/> 220 233 </record> 221 234 <record model="network.link" id="interface_link2"> … … 227 240 <field name="name">eth0</field> 228 241 <field name="type_id" ref="interface_type_optics"/> 229 <field name="device_id" ref="device_router "/>242 <field name="device_id" ref="device_router_praha"/> 230 243 <field name="mac">00:01:FE:32:56:26</field> 231 244 <field name="local_address_id" ref="address_router1"/> … … 235 248 <field name="name">eth1</field> 236 249 <field name="type_id" ref="interface_type_wireless_10G"/> 237 <field name="device_id" ref="device_router "/>250 <field name="device_id" ref="device_router_praha"/> 238 251 <field name="mac">00:01:FE:32:56:27</field> 239 252 <field name="local_address_id" ref="address_router3"/> 240 253 <field name="link_id" ref="interface_link2"/> 254 </record> 255 <record model="network.interface" id="interface_eth0"> 256 <field name="name">eth0</field> 257 <field name="type_id" ref="interface_type_optics"/> 258 <field name="device_id" ref="device_router_brno"/> 259 <field name="mac">00:01:FE:32:54:22</field> 260 <field name="local_address_id" ref="address_router2"/> 261 <field name="link_id" ref="interface_link1"/> 241 262 </record> 242 263 … … 246 267 <field name="type_id" ref="service_internet"/> 247 268 <field name="price">200</field> 248 <field name="available" >1</field>269 <field name="available" eval="True"/> 249 270 </record> 250 271 <record model="network.service" id="service_internet_2M"> … … 252 273 <field name="type_id" ref="service_internet"/> 253 274 <field name="price">300</field> 254 <field name="available">1</field> 275 <field name="available" eval="True"/> 276 </record> 277 278 279 <record model="network.domain" id="domain_company"> 280 <field name="name">company.com</field> 281 </record> 282 283 284 <record model="network.subnet" id="service_subnet_main"> 285 <field name="name">Main subnet</field> 286 <field name="address">192.168.0.0</field> 287 <field name="prefix">24</field> 288 <field name="dhcp_id" ref="address_router3"/> 289 <field name="dns_ids" eval="[(4, ref('address_router1')), 290 (4, ref('address_router2'))]"/> 291 <field name="gateway_id" ref="address_router2"/> 292 <field name="wins_id" ref="address_router3"/> 293 <field name="domain_id" ref="domain_company"/> 294 <field name="partner_id" search="[]" model="res.partner"/> 255 295 </record> 256 296 </data> -
addons/isp/isp_view.xml
r41 r42 3 3 <data> 4 4 5 <menuitem name="ISP" id="menu_isp" sequence="1" /> 5 <menuitem name="ISP" id="menu_isp" sequence="1" 6 web_icon="images/isp.png" web_icon_hover="images/isp-hover.png"/> 6 7 <menuitem name="Network" parent="menu_isp" 7 8 id="base.menu_isp_network" sequence="1"/> … … 58 59 59 60 <record model="ir.actions.act_window" id="action_isp_device_type_form"> 60 <field name="res_model">network.device </field>61 <field name="res_model">network.device.type</field> 61 62 <field name="domain">[]</field> 62 63 </record> … … 243 244 <tree string="Address"> 244 245 <field name="name" select="1" /> 246 <field name="ipv4" select="1" /> 245 247 <field name="ipv6" select="1" /> 246 248 </tree> … … 255 257 <form string="Address"> 256 258 <field name="name" select="1" /> 259 <field name="ipv4" select="1" /> 257 260 <field name="ipv6" select="1" /> 258 261 </form> … … 297 300 <field name="price_period_id" select="1" /> 298 301 <field name="available" select="1" /> 302 <field name="partner_ids" select="1" /> 299 303 </form> 300 304 </field> … … 387 391 <tree string="Domain"> 388 392 <field name="name" select="1" /> 389 <field name="parent " select="1" />393 <field name="parent_id" select="1" /> 390 394 <field name="alias" select="1" /> 391 395 </tree> … … 400 404 <form string="Domain"> 401 405 <field name="name" select="1" /> 402 <field name="parent " select="1" />406 <field name="parent_id" select="1" /> 403 407 <field name="alias" select="1" /> 404 408 </form>
Note:
See TracChangeset
for help on using the changeset viewer.